Class: StringEnumPropertyType
- Inherits:
-
SwiftPropertyType
- Object
- SwiftPropertyType
- StringEnumPropertyType
- Defined in:
- lib/swift_generator/code_generation/swift_types.rb
Instance Attribute Summary collapse
-
#enum ⇒ Object
Returns the value of attribute enum.
Attributes inherited from SwiftPropertyType
#auto_bridged, #custom_equality_test, #custom_marshaling, #custom_unmarshaling, #hashable_value_lambda, #serialized_json_type, #swift_kind, #swift_type_name, #swift_type_symbol, #test_value_lambda
Instance Method Summary collapse
-
#initialize(enum, serialized_json_type, test_value: lambda{|num| 'undefined' }) ⇒ StringEnumPropertyType
constructor
A new instance of StringEnumPropertyType.
Methods inherited from SwiftPropertyType
all_swift_kinds, #hashable_value, #make_test_value
Constructor Details
#initialize(enum, serialized_json_type, test_value: lambda{|num| 'undefined' }) ⇒ StringEnumPropertyType
Returns a new instance of StringEnumPropertyType.
59 60 61 62 |
# File 'lib/swift_generator/code_generation/swift_types.rb', line 59 def initialize( enum, serialized_json_type, test_value:lambda{|num| 'undefined' } ) super( enum.swift_type_symbol, serialized_json_type, swift_kind: :enum, test_value:test_value ) @enum = enum end |
Instance Attribute Details
#enum ⇒ Object
Returns the value of attribute enum.
57 58 59 |
# File 'lib/swift_generator/code_generation/swift_types.rb', line 57 def enum @enum end |