Class: Virtus::TypeDefinition
- Inherits:
-
Object
- Object
- Virtus::TypeDefinition
- Defined in:
- lib/virtus/attribute/builder.rb
Overview
Extracts the actual type primitive from input type
Instance Attribute Summary collapse
- #primitive ⇒ Object readonly
- #type ⇒ Object readonly
Instance Method Summary collapse
-
#initialize(type) ⇒ TypeDefinition
constructor
private
A new instance of TypeDefinition.
- #pending? ⇒ Boolean private
Constructor Details
#initialize(type) ⇒ TypeDefinition
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Returns a new instance of TypeDefinition.
43 44 45 46 |
# File 'lib/virtus/attribute/builder.rb', line 43 def initialize(type) @type = type initialize_primitive end |
Instance Attribute Details
#primitive ⇒ Object (readonly)
40 41 42 |
# File 'lib/virtus/attribute/builder.rb', line 40 def primitive @primitive end |
#type ⇒ Object (readonly)
40 41 42 |
# File 'lib/virtus/attribute/builder.rb', line 40 def type @type end |
Instance Method Details
#pending? ⇒ Boolean
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
49 50 51 |
# File 'lib/virtus/attribute/builder.rb', line 49 def pending? @pending if defined?(@pending) end |