Class: Brujula::TypeExtender::RamlType
- Inherits:
-
Object
- Object
- Brujula::TypeExtender::RamlType
- Defined in:
- lib/brujula/type_extender/raml_type.rb
Constant Summary collapse
- RAML_TYPES =
%w( object number string integer boolean date file array )
Instance Attribute Summary collapse
-
#definition ⇒ Object
readonly
Returns the value of attribute definition.
Instance Method Summary collapse
- #call ⇒ Object
-
#initialize(definition:) ⇒ RamlType
constructor
A new instance of RamlType.
Constructor Details
#initialize(definition:) ⇒ RamlType
Returns a new instance of RamlType.
9 10 11 |
# File 'lib/brujula/type_extender/raml_type.rb', line 9 def initialize(definition:) @definition = definition end |
Instance Attribute Details
#definition ⇒ Object (readonly)
Returns the value of attribute definition.
7 8 9 |
# File 'lib/brujula/type_extender/raml_type.rb', line 7 def definition @definition end |
Instance Method Details
#call ⇒ Object
13 14 15 16 17 |
# File 'lib/brujula/type_extender/raml_type.rb', line 13 def call return definition unless custom_type? end |