Class: RouteNGNClient::RouteTable
- Inherits:
-
RemoteModel
- Object
- Model
- RemoteModel
- RouteNGNClient::RouteTable
- Defined in:
- lib/routengn_client/models/route_table.rb
Constant Summary
Constants inherited from RemoteModel
RouteNGNClient::RemoteModel::DEFAULT_RESOURCE_ATTRIBUTES
Instance Attribute Summary
Attributes included from RouteNGNClient::RemoteModel::ClassMethods
Attributes inherited from Model
#attributes, #request_account_id
Attributes included from Model::ClassMethods
#children, #only_children, #parents
Instance Method Summary collapse
Methods included from RouteNGNClient::RemoteModel::ClassMethods
#all, #collection_name, #create!, #find, #index_method, #path_base, #path_ext, #set_resource_attributes, #where
Methods inherited from Model
#initialize, #to_hash, #to_json, #to_log
Methods included from Model::ClassMethods
#belongs_to, #from_hash, #from_json, #has_many, #has_one
Methods included from Logging
Constructor Details
This class inherits a constructor from RouteNGNClient::Model
Instance Method Details
#route_containers(params = {}, options = {}, &callback) ⇒ Object
15 16 17 18 19 20 21 22 23 24 25 26 27 |
# File 'lib/routengn_client/models/route_table.rb', line 15 def route_containers(params = {}, = {}, &callback) [:klass] ||= RouteContainer [:account_id] ||= self.request_account_id models = [] response = Request.new(self.class.resource_attributes.merge(:collection_name => 'route_containers'), :get, [self.class.path_base, self.attributes.id, 'route_containers'], self.class.path_ext, params, ).execute(RouteNGNClient.connection) models = response.to_models callback.call(models) if callback models end |