Class: Fog::Compute::Google::BackendServices
- Inherits:
-
Fog::Collection
- Object
- Fog::Collection
- Fog::Compute::Google::BackendServices
- Defined in:
- lib/fog/compute/google/models/backend_services.rb
Instance Method Summary collapse
Instance Method Details
#all(_filters = {}) ⇒ Object
7 8 9 10 |
# File 'lib/fog/compute/google/models/backend_services.rb', line 7 def all(_filters = {}) data = service.list_backend_services.items || [] load(data.map(&:to_h)) end |
#get(identity) ⇒ Object
12 13 14 15 16 17 18 19 20 |
# File 'lib/fog/compute/google/models/backend_services.rb', line 12 def get(identity) if identity backend_service = service.get_backend_service(identity).to_h return new(backend_service) end rescue ::Google::Apis::ClientError => e raise e unless e.status_code == 404 nil end |