Class: Yema::Virtus::Builder

Inherits:
Object
  • Object
show all
Defined in:
lib/yema/virtus/builder.rb,
lib/yema/virtus/builder/format.rb,
lib/yema/virtus/builder/length.rb,
lib/yema/virtus/builder/required.rb,
lib/yema/virtus/builder/inclusion.rb,
lib/yema/virtus/builder/strong_type.rb

Direct Known Subclasses

Format, Inclusion, Length, Required, StrongType

Defined Under Namespace

Classes: Format, Inclusion, Length, Required, StrongType

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(attribute) ⇒ Builder

Returns a new instance of Builder.



7
8
9
# File 'lib/yema/virtus/builder.rb', line 7

def initialize(attribute)
  @attribute = attribute
end

Instance Attribute Details

#attributeObject (readonly)

Returns the value of attribute attribute.



5
6
7
# File 'lib/yema/virtus/builder.rb', line 5

def attribute
  @attribute
end

Instance Method Details

#optionsObject



11
12
13
# File 'lib/yema/virtus/builder.rb', line 11

def options
  attribute.options
end