class Fog::Compute::Gridscale::Network
Public Instance Methods
delete()
click to toggle source
# File lib/fog/compute/gridscale/models/network.rb, line 26 def delete requires :object_uuid response = service.network_delete object_uuid response.body end
destroy()
click to toggle source
# File lib/fog/compute/gridscale/models/network.rb, line 32 def destroy requires :object_uuid response = service.network_delete object_uuid response.body end
save()
click to toggle source
# File lib/fog/compute/gridscale/models/network.rb, line 38 def save raise Fog::Errors::Error.new('Re-saving an existing object may create a duplicate') if persisted? requires :name options = {} if attributes[:labels] options[:labels] = labels end if attributes[:l2security] options[:l2security] = l2security end if attributes[:location_uuid] options[:location_uuid] = location_uuid end data = service.network_create(name, options) merge_attributes(data.body) true end
update()
click to toggle source
# File lib/fog/compute/gridscale/models/network.rb, line 61 def update requires :object_uuid payload = {} data = service.network_update(object_uuid, payload) merge_attributes(data.body) true end