Class: Fog::OpenStack::Network::Router
- Defined in:
- lib/fog/openstack/network/models/router.rb
Overview
The Layer-3 Networking Extensions (router)
A logical entity for forwarding packets across internal subnets and NATting them on external networks through an appropriate external gateway.
Instance Attribute Summary
Attributes inherited from Model
Instance Method Summary collapse
Methods inherited from Model
Constructor Details
This class inherits a constructor from Fog::OpenStack::Model
Instance Method Details
#create ⇒ Object
22 23 24 25 26 27 28 29 |
# File 'lib/fog/openstack/network/models/router.rb', line 22 def create requires :name response = service.create_router(name, ) merge_attributes(response.body['router']) self end |
#destroy ⇒ Object
38 39 40 41 42 |
# File 'lib/fog/openstack/network/models/router.rb', line 38 def destroy requires :id service.delete_router(id) true end |
#update ⇒ Object
31 32 33 34 35 36 |
# File 'lib/fog/openstack/network/models/router.rb', line 31 def update requires :id response = service.update_router(id, ) merge_attributes(response.body['router']) self end |