Class: Fog::Network::StormOnDemand::NetworkIPs
- Inherits:
-
Collection
- Object
- Array
- Collection
- Fog::Network::StormOnDemand::NetworkIPs
show all
- Defined in:
- lib/fog/storm_on_demand/models/network/network_ips.rb
Instance Attribute Summary
Attributes inherited from Collection
#service
Instance Method Summary
collapse
Methods inherited from Collection
#clear, #create, #destroy, #initialize, #inspect, #load, model, #model, #new, #reload, #table, #to_json
#_load, #aliases, #attribute, #attributes, #identity, #ignore_attributes, #ignored_attributes
#connection, #connection=, #prepare_service_value
#_dump, #attributes, #dup, #identity, #identity=, #merge_attributes, #new_record?, #persisted?, #requires, #requires_one
Instance Method Details
#add(options) ⇒ Object
11
12
13
14
|
# File 'lib/fog/storm_on_demand/models/network/network_ips.rb', line 11
def add(options)
service.add_ip_to_server(options)
true
end
|
#all(options = {}) ⇒ Object
21
22
23
24
|
# File 'lib/fog/storm_on_demand/models/network/network_ips.rb', line 21
def all(options={})
data = service.list_network_ips(options).body['items']
load(data)
end
|
#all_public(options = {}) ⇒ Object
30
31
32
33
|
# File 'lib/fog/storm_on_demand/models/network/network_ips.rb', line 30
def all_public(options={})
data = service.list_network_public_ips(options).body['items']
load(data)
end
|
#get(server_id, ip) ⇒ Object
16
17
18
19
|
# File 'lib/fog/storm_on_demand/models/network/network_ips.rb', line 16
def get(server_id, ip)
data = service.get_ip_details(:uniq_id => server_id, :ip => ip).body
new(data)
end
|
#get_public_accounts(options = {}) ⇒ Object
26
27
28
|
# File 'lib/fog/storm_on_demand/models/network/network_ips.rb', line 26
def get_public_accounts(options={})
service.list_ip_public_accounts(options).body['items']
end
|
#remove(options) ⇒ Object
35
36
37
38
|
# File 'lib/fog/storm_on_demand/models/network/network_ips.rb', line 35
def remove(options)
service.remove_ip_from_server(options)
true
end
|
#request_new_ips(options) ⇒ Object
40
41
42
43
|
# File 'lib/fog/storm_on_demand/models/network/network_ips.rb', line 40
def request_new_ips(options)
service.request_new_ips(options)
true
end
|