Methods

Class/Module Index [+]

Quicksearch

Fog::Compute::Joyent::Snapshots

Public Instance Methods

all(machine_id) click to toggle source
# File lib/fog/joyent/models/compute/snapshots.rb, line 16
def all(machine_id)
  data = service.list_machine_snapshots(machine_id).body.map do |m|
    m["machine_id"] = machine_id
    m
  end
  load(data)
end
create(machine_id, snapshot_name) click to toggle source
# File lib/fog/joyent/models/compute/snapshots.rb, line 10
def create(machine_id, snapshot_name)
  data = self.service.create_machine_snapshot(machine_id, snapshot_name).body
  data['machine_id'] = machine_id
  new(data)
end
get(machine_id, snapshot_name) click to toggle source
# File lib/fog/joyent/models/compute/snapshots.rb, line 24
def get(machine_id, snapshot_name)
  data = service.get_machine_snapshot(machine_id, snapshot_name).body
  if data
    data["machine_id"] = machine_id
    new(data)
  else
    nil
  end
end

[Validate]

Generated with the Darkfish Rdoc Generator 2.