Class: Fog::Compute::Packet::Ips

Inherits:
Fog::Collection
  • Object
show all
Defined in:
lib/fog/compute/packet/models/ips.rb

Overview

Ips Collection

Instance Method Summary collapse

Instance Method Details

#all(project_id) ⇒ Object



10
11
12
13
# File 'lib/fog/compute/packet/models/ips.rb', line 10

def all(project_id)
  response = service.list_ips(project_id)
  load(response.body["ip_addresses"])
end

#get(id) ⇒ Object



15
16
17
18
# File 'lib/fog/compute/packet/models/ips.rb', line 15

def get(id)
  response = service.get_ip(id)
  new(response.body)
end