Class: Shale::Builder::Value

Inherits:
Object
  • Object
show all
Extended by:
T::Sig
Defined in:
lib/shale/builder/value.rb

Overview

Represents a value of a particular shale attribute. Hold the value and a reference to the attribute definition.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(attribute, value) ⇒ Value

: (Shale::Attribute, untyped) -> void



24
25
26
27
# File 'lib/shale/builder/value.rb', line 24

def initialize(attribute, value)
  @attribute = attribute
  @value = value
end

Instance Attribute Details

#attributeObject (readonly)

Shale attribute definition

: Shale::Attribute



16
17
18
# File 'lib/shale/builder/value.rb', line 16

def attribute
  @attribute
end

#valueObject (readonly)

Value of the attribute.

: untyped



21
22
23
# File 'lib/shale/builder/value.rb', line 21

def value
  @value
end