Class: AliOts::Metas::TablePrimaryKey
- Inherits:
-
Object
- Object
- AliOts::Metas::TablePrimaryKey
- Defined in:
- lib/ali_ots/metas/table_primary_key.rb
Instance Attribute Summary collapse
-
#name ⇒ Object
Returns the value of attribute name.
-
#type ⇒ Object
Returns the value of attribute type.
Instance Method Summary collapse
-
#initialize(name, type) ⇒ TablePrimaryKey
constructor
A new instance of TablePrimaryKey.
- #to_s ⇒ Object
Constructor Details
#initialize(name, type) ⇒ TablePrimaryKey
Returns a new instance of TablePrimaryKey.
7 8 9 10 |
# File 'lib/ali_ots/metas/table_primary_key.rb', line 7 def initialize(name, type) self.name = name self.type = type end |
Instance Attribute Details
#name ⇒ Object
Returns the value of attribute name.
4 5 6 |
# File 'lib/ali_ots/metas/table_primary_key.rb', line 4 def name @name end |
#type ⇒ Object
Returns the value of attribute type.
5 6 7 |
# File 'lib/ali_ots/metas/table_primary_key.rb', line 5 def type @type end |
Instance Method Details
#to_s ⇒ Object
12 13 14 15 16 17 18 |
# File 'lib/ali_ots/metas/table_primary_key.rb', line 12 def to_s %Q{primary_key { name: "#{name}" type: #{type} } } end |