lib/process/cloud/providers/hpcloud/network.rb in lorj_cloud-0.1.3 vs lib/process/cloud/providers/hpcloud/network.rb in lorj_cloud-0.1.4

- old
+ new

@@ -15,27 +15,18 @@ # limitations under the License. # HPcloud network class module HPNetwork # Network driver - def self.query_network(oNetworkConnect, sQuery) - oNetworkConnect.networks.all(sQuery) - end - def self.create_network(oNetworkConnect, name) oNetworkConnect.networks.create(:name => name) end def self.delete_network(oNetworkConnect, oNetwork) oNetworkConnect.networks.get(oNetwork.id).destroy end - # SubNetwork driver - def self.query_subnetwork(oNetworkConnect, sQuery) - oNetworkConnect.subnets.all(sQuery) - end - def self.create_subnetwork(oNetworkConnect, oNetwork, name) oNetworkConnect.subnets.create( :network_id => oNetwork.id, :name => name, :cidr => get_next_subnet(oNetworkConnect), @@ -88,13 +79,10 @@ rescue => e Logging.error("%s\n%s", e.message, e.backtrace.join("\n")) end # router driver - def self.query_router(oNetworkConnect, sQuery) - oNetworkConnect.routers.all(sQuery) - end def self.update_router(oRouters) oRouters.save end @@ -104,12 +92,7 @@ # router interface def self.add_interface(oRouter, oSubNetwork) oRouter.add_interface(oSubNetwork.id, nil) - end - - # Port driver - def self.query_port(oNetworkConnect, sQuery) - oNetworkConnect.ports.all(sQuery) end end