Class: Fog::Volume::OpenStack::Transfer
Instance Attribute Summary
#project
Instance Method Summary
collapse
#create, #update
Constructor Details
#initialize(attributes) ⇒ Transfer
Returns a new instance of Transfer.
20
21
22
23
24
|
# File 'lib/fog/openstack/models/volume/transfer.rb', line 20
def initialize(attributes)
prepare_service_value(attributes)
super
end
|
Instance Method Details
#destroy ⇒ Object
14
15
16
17
18
|
# File 'lib/fog/openstack/models/volume/transfer.rb', line 14
def destroy
requires :id
service.delete_transfer(id)
true
end
|
#save ⇒ Object
7
8
9
10
11
12
|
# File 'lib/fog/openstack/models/volume/transfer.rb', line 7
def save
requires :name, :volume_id
data = service.create_transfer(volume_id, :name => name)
merge_attributes(data.body['transfer'])
true
end
|