class Fog::Hetznercloud::Compute::Locations

Public Instance Methods

all(filters = {}) click to toggle source
# File lib/fog/hetznercloud/models/compute/locations.rb, line 7
def all(filters = {})
  locations = service.list_locations(filters).body['locations'] || []
  load(locations)
end
get(identity) click to toggle source
# File lib/fog/hetznercloud/models/compute/locations.rb, line 12
def get(identity)
  if (location = service.get_location(identity).body['location'])
    new(location)
  end
rescue Fog::Hetznercloud::Compute::UnknownResourceError
  nil
end