Sha256: a9936f7ec6ea463967db940fcc0dfb160082b0e4cf5009095672e9b254948aa9

Contents?: true

Size: 445 Bytes

Versions: 34

Compression:

Stored size: 445 Bytes

Contents

# frozen_string_literal: true

module Grumlin
  module Expressions
    module Expression
      def define_steps(steps, tool_name)
        steps.each do |step|
          define_method step do
            name = "@#{step}"
            return instance_variable_get(name) if instance_variable_defined?(name)

            instance_variable_set(name, TypedValue.new(type: tool_name, value: step))
          end
        end
      end
    end
  end
end

Version data entries

34 entries across 34 versions & 1 rubygems

Version Path
grumlin-0.18.1 lib/grumlin/expressions/expression.rb
grumlin-0.18.0 lib/grumlin/expressions/expression.rb
grumlin-0.17.0 lib/grumlin/expressions/expression.rb
grumlin-0.16.1 lib/grumlin/expressions/expression.rb
grumlin-0.16.0 lib/grumlin/expressions/expression.rb
grumlin-0.15.6 lib/grumlin/expressions/expression.rb
grumlin-0.15.4 lib/grumlin/expressions/expression.rb
grumlin-0.15.3 lib/grumlin/expressions/expression.rb
grumlin-0.15.2 lib/grumlin/expressions/expression.rb
grumlin-0.15.1 lib/grumlin/expressions/expression.rb
grumlin-0.15.0 lib/grumlin/expressions/expression.rb
grumlin-0.14.5 lib/grumlin/expressions/expression.rb
grumlin-0.14.4 lib/grumlin/expressions/expression.rb
grumlin-0.14.3 lib/grumlin/expressions/expression.rb