Class: Larrow::Qingcloud::KeyPair
- Defined in:
- lib/larrow/qingcloud/key_pair.rb
Constant Summary
Constants inherited from Base
Instance Attribute Summary collapse
-
#id ⇒ Object
Returns the value of attribute id.
-
#name ⇒ Object
Returns the value of attribute name.
Attributes inherited from Base
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(id, name) ⇒ KeyPair
constructor
A new instance of KeyPair.
Methods inherited from Base
#conn, conn, describe, destroy_action, #method_missing, #model_name, model_name, #param_by, param_by, plural_name, #show, singular_name, #wait_for
Methods included from Logger
Constructor Details
#initialize(id, name) ⇒ KeyPair
Returns a new instance of KeyPair.
11 12 13 14 |
# File 'lib/larrow/qingcloud/key_pair.rb', line 11 def initialize id,name self.id = id self.name = name end |
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class Larrow::Qingcloud::Base
Instance Attribute Details
#id ⇒ Object
Returns the value of attribute id.
4 5 6 |
# File 'lib/larrow/qingcloud/key_pair.rb', line 4 def id @id end |
#name ⇒ Object
Returns the value of attribute name.
4 5 6 |
# File 'lib/larrow/qingcloud/key_pair.rb', line 4 def name @name end |
Class Method Details
.list ⇒ Object
5 6 7 8 9 |
# File 'lib/larrow/qingcloud/key_pair.rb', line 5 def self.list() describe([],{}) do |hash| new hash['keypair_id'],hash['keypair_name'] end end |