Sha256: af61b6d37145e33ad6bcbaeabf0cf159dcb72beef00293cf8659a10e215f547b

Contents?: true

Size: 1.1 KB

Versions: 46

Compression:

Stored size: 1.1 KB

Contents

module Fog
  module Network
    class AzureRM
      # VirtualNetworkGateways collection class for Network Service
      class VirtualNetworkGateways < Fog::Collection
        model Fog::Network::AzureRM::VirtualNetworkGateway
        attribute :resource_group

        def all
          requires :resource_group
          network_gateways = []
          service.list_virtual_network_gateways(resource_group).each do |gateway|
            network_gateways << Fog::Network::AzureRM::VirtualNetworkGateway.parse(gateway)
          end
          load(network_gateways)
        end

        def get(resource_group_name, name)
          network_gateway = service.get_virtual_network_gateway(resource_group_name, name)
          virtual_network_gateway = Fog::Network::AzureRM::VirtualNetworkGateway.new(service: service)
          virtual_network_gateway.merge_attributes(Fog::Network::AzureRM::VirtualNetworkGateway.parse(network_gateway))
        end

        def check_vnet_gateway_exists(resource_group_name, name)
          service.check_vnet_gateway_exists(resource_group_name, name)
        end
      end
    end
  end
end

Version data entries

46 entries across 46 versions & 4 rubygems

Version Path
fog-azure-rm-0.4.1 lib/fog/azurerm/models/network/virtual_network_gateways.rb
fog-azure-rm-0.4.0 lib/fog/azurerm/models/network/virtual_network_gateways.rb
fog-azure-rm-0.3.9 lib/fog/azurerm/models/network/virtual_network_gateways.rb
fog-azure-rm-0.3.8 lib/fog/azurerm/models/network/virtual_network_gateways.rb
fog-azure-rm-0.3.7 lib/fog/azurerm/models/network/virtual_network_gateways.rb
fog-azure-rm-0.3.6 lib/fog/azurerm/models/network/virtual_network_gateways.rb
fog-azure-rm-0.3.5 lib/fog/azurerm/models/network/virtual_network_gateways.rb
fog-azure-rm-0.3.4 lib/fog/azurerm/models/network/virtual_network_gateways.rb
fog-azure-rm-temp-0.0.4 lib/fog/azurerm/models/network/virtual_network_gateways.rb
fog-azure-rm-temp-0.0.3 lib/fog/azurerm/models/network/virtual_network_gateways.rb
fog-azure-rm-0.3.3 lib/fog/azurerm/models/network/virtual_network_gateways.rb
fog-azure-rm-temp-0.0.2 lib/fog/azurerm/models/network/virtual_network_gateways.rb
fog-azure-rm-temp-0.0.1 lib/fog/azurerm/models/network/virtual_network_gateways.rb
fog-azure-rm-0.3.2 lib/fog/azurerm/models/network/virtual_network_gateways.rb
fog-azure-rm-downgraded-0.3.1 lib/fog/azurerm/models/network/virtual_network_gateways.rb
fog-azure-rm-0.3.1 lib/fog/azurerm/models/network/virtual_network_gateways.rb
fog-azure-rm-downgraded-0.3.0 lib/fog/azurerm/models/network/virtual_network_gateways.rb
fog-azure-rm-0.3.0 lib/fog/azurerm/models/network/virtual_network_gateways.rb
fog-azure-rm-0.2.7 lib/fog/azurerm/models/network/virtual_network_gateways.rb
fog-azure-rm-0.2.6 lib/fog/azurerm/models/network/virtual_network_gateways.rb