Class: Fog::Volume::OpenStack::VolumeType
Instance Attribute Summary
#project
Instance Method Summary
collapse
#initialize, #save
Instance Method Details
#create ⇒ Object
9
10
11
12
13
14
15
16
|
# File 'lib/fog/volume/openstack/models/volume_type.rb', line 9
def create
requires :name
response = service.create_volume_type(attributes)
merge_attributes(response.body['volume_type'])
self
end
|
#destroy ⇒ Object
27
28
29
30
31
|
# File 'lib/fog/volume/openstack/models/volume_type.rb', line 27
def destroy
requires :id
service.delete_volume_type(id)
true
end
|
#update ⇒ Object
18
19
20
21
22
23
24
25
|
# File 'lib/fog/volume/openstack/models/volume_type.rb', line 18
def update
requires :id
response = service.update_volume_type(id, attributes)
merge_attributes(response.body['volume_type'])
self
end
|