Sha256: b0116817f9197e23c9df53953ee1fe083b0d7998a6a7f518ce18a283be14325c

Contents?: true

Size: 236 Bytes

Versions: 3

Compression:

Stored size: 236 Bytes

Contents

module DSL
  def weight(value = nil)
    # Set weight value for the action
    if value.nil?
      @action[:weight]
    elsif value == :default
      @action[:weight] = 1.0
    else
      @action[:weight] = value.to_f
    end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
teuton-2.9.2 lib/teuton/case/dsl/weight.rb
teuton-2.9.1 lib/teuton/case/dsl/weight.rb
teuton-2.9.0 lib/teuton/case/dsl/weight.rb