class Structured::Struct::Attribute
Constants
- UNDEFINED
Attributes
parent[R]
type[R]
Public Class Methods
new(parent, type, default_value: UNDEFINED)
click to toggle source
# File lib/structured/struct.rb, line 160 def initialize(parent, type, default_value: UNDEFINED) @parent = parent @type = type @default_value = default_value end
Public Instance Methods
default_value()
click to toggle source
# File lib/structured/struct.rb, line 170 def default_value @default_value unless @default_value == UNDEFINED end
has_default?()
click to toggle source
# File lib/structured/struct.rb, line 166 def has_default? @default_value != UNDEFINED end