Instance depends on the API version:

           * 2018-04-01: :class:`VpnGatewaysOperations<azure.mgmt.network.v2018_04_01.operations.VpnGatewaysOperations>`
489031
def vpn_gateways(self):
        
        api_version = self._get_api_version('vpn_gateways')
        if api_version == '2018-04-01':
            from .v2018_04_01.operations import VpnGatewaysOperations as OperationClass
        else:
            raise NotImplementedError("APIVersion {} is not available".format(api_version))
        return OperationClass(self._client, self.config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)))
881014
public static vpnglobal_staserver_binding[] get(nitro_service service) throws Exception{
		vpnglobal_staserver_binding obj = new vpnglobal_staserver_binding();
		vpnglobal_staserver_binding response[] = (vpnglobal_staserver_binding[]) obj.get_resources(service);
		return response;
	}
75614
def check_version(cls):
        """"""
        super(SimpleCpnrDriver, cls).check_version()
        model.configure_pnr()
        cls.recover_networks()
        ver = model.get_version()
        if ver < cls.MIN_VERSION:
            LOG.warning("CPNR version does not meet minimum requirements, "
                        "expected: %(ever)f, actual: %(rver)f",
                        {'ever': cls.MIN_VERSION, 'rver': ver})
        return ver
596290
def available_resource_group_delegations(self):
        
        api_version = self._get_api_version('available_resource_group_delegations')
        if api_version == '2018-08-01':
            from .v2018_08_01.operations import AvailableResourceGroupDelegationsOperations as OperationClass
        else:
            raise NotImplementedError("APIVersion {} is not available".format(api_version))
        return OperationClass(self._client, self.config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)))
897865
public static vpnglobal_vpnsessionpolicy_binding[] get(nitro_service service) throws Exception{
		vpnglobal_vpnsessionpolicy_binding obj = new vpnglobal_vpnsessionpolicy_binding();
		vpnglobal_vpnsessionpolicy_binding response[] = (vpnglobal_vpnsessionpolicy_binding[]) obj.get_resources(service);
		return response;
	}
1228999
def get_network_instances(self, name=''):
        """"""

        output = self._show_vrf()
        vrfs = {}
        all_vrf_interfaces = {}
        for vrf in output:
            if (vrf.get('route_distinguisher', '') == "<not set>" or
                    vrf.get('route_distinguisher', '') == 'None'):
                vrf['route_distinguisher'] = u''
            else:
                vrf['route_distinguisher'] = py23_compat.text_type(vrf['route_distinguisher'])
            interfaces = {}
            for interface_raw in vrf.get('interfaces', []):
                interface = interface_raw.split(',')
                for line in interface:
                    if line.strip() != '':
                        interfaces[py23_compat.text_type(line.strip())] = {}
                        all_vrf_interfaces[py23_compat.text_type(line.strip())] = {}

            vrfs[py23_compat.text_type(vrf['name'])] = {
                          u'name': py23_compat.text_type(vrf['name']),
                          u'type': u'L3VRF',
                          u'state': {
                              u'route_distinguisher': vrf['route_distinguisher'],
                          },
                          u'interfaces': {
                              u'interface': interfaces,
                          },
            }
        all_interfaces = self.get_interfaces_ip().keys()
        vrfs[u'default'] = {
            u'name': u'default',
            u'type': u'DEFAULT_INSTANCE',
            u'state': {
                u'route_distinguisher': u'',
            },
            u'interfaces': {
                u'interface': {
                    k: {} for k in all_interfaces if k not in all_vrf_interfaces.keys()
                },
            },
        }

        if name:
            if name in vrfs:
                return {py23_compat.text_type(name): vrfs[name]}
            return {}
        else:
            return vrfs
614157
def virtual_network_taps(self):
        
        api_version = self._get_api_version('virtual_network_taps')
        if api_version == '2018-08-01':
            from .v2018_08_01.operations import VirtualNetworkTapsOperations as OperationClass
        else:
            raise NotImplementedError("APIVersion {} is not available".format(api_version))
        return OperationClass(self._client, self.config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)))
832334
public static vpnglobal_vpnintranetapplication_binding[] get_filtered(nitro_service service, String filter) throws Exception{
		vpnglobal_vpnintranetapplication_binding obj = new vpnglobal_vpnintranetapplication_binding();
		options option = new options();
		option.set_filter(filter);
		vpnglobal_vpnintranetapplication_binding[] response = (vpnglobal_vpnintranetapplication_binding[]) obj.getfiltered(service, option);
		return response;
	}
1226922
def _require_min_api_version(self, version):
    
    actual_version = self._get_resource_root().version
    version = max(version, self._api_version())
    if actual_version < version:
      raise Exception("API version %s is required but %s is in use."
          % (version, actual_version))
973542
def route_exists(destination_cidr_block, route_table_name=None, route_table_id=None,
                 gateway_id=None, instance_id=None, interface_id=None, tags=None,
                 region=None, key=None, keyid=None, profile=None, vpc_peering_connection_id=None):
    '''
    

    '''

    if not any((route_table_name, route_table_id)):
        raise SaltInvocationError('At least one of the following must be specified: route table name or route table id.')

    if not any((gateway_id, instance_id, interface_id, vpc_peering_connection_id)):
        raise SaltInvocationError('At least one of the following must be specified: gateway id, instance id, '
                                  'interface id or VPC peering connection id.')

    try:
        conn = _get_conn(region=region, key=key, keyid=keyid, profile=profile)
        filter_parameters = {'filters': {}}

        if route_table_id:
            filter_parameters['route_table_ids'] = [route_table_id]

        if route_table_name:
            filter_parameters['filters']['tag:Name'] = route_table_name

        if tags:
            for tag_name, tag_value in six.iteritems(tags):
                filter_parameters['filters']['tag:{0}'.format(tag_name)] = tag_value

        route_tables = conn.get_all_route_tables(**filter_parameters)

        if len(route_tables) != 1:
            raise SaltInvocationError('Found more than one route table.')

        route_check = {'destination_cidr_block': destination_cidr_block,
                       'gateway_id': gateway_id,
                       'instance_id': instance_id,
                       'interface_id': interface_id,
                       'vpc_peering_connection_id': vpc_peering_connection_id
                       }

        for route_match in route_tables[0].routes:

            route_dict = {'destination_cidr_block': route_match.destination_cidr_block,
                          'gateway_id': route_match.gateway_id,
                          'instance_id': route_match.instance_id,
                          'interface_id': route_match.interface_id,
                          'vpc_peering_connection_id': vpc_peering_connection_id
                          }
            route_comp = set(route_dict.items()) ^ set(route_check.items())
            if not route_comp:
                log.info('Route %s exists.', destination_cidr_block)
                return {'exists': True}

        log.warning('Route %s does not exist.', destination_cidr_block)
        return {'exists': False}
    except BotoServerError as e:
        return {'error': __utils__['boto.get_error'](e)}
493183
def resource_api_version(self, resource_id):
        

        namespace = ResourceIdParser.get_namespace(resource_id)
        resource_type = ResourceIdParser.get_resource_type(resource_id)

        cache_id = namespace + resource_type

        if cache_id in self._provider_cache:
            return self._provider_cache[cache_id]

        resource_client = self.client('azure.mgmt.resource.ResourceManagementClient')
        provider = resource_client.providers.get(namespace)

        rt = next((t for t in provider.resource_types
            if StringUtils.equal(t.resource_type, resource_type)), None)

        if rt and rt.api_versions:
            versions = [v for v in rt.api_versions if 'preview' not in v.lower()]
            api_version = versions[0] if versions else rt.api_versions[0]
            self._provider_cache[cache_id] = api_version
            return api_version
68370
public static vpnglobal_vpnnexthopserver_binding[] get(nitro_service service) throws Exception{
		vpnglobal_vpnnexthopserver_binding obj = new vpnglobal_vpnnexthopserver_binding();
		vpnglobal_vpnnexthopserver_binding response[] = (vpnglobal_vpnnexthopserver_binding[]) obj.get_resources(service);
		return response;
	}
1260033
public static vpnglobal_vpnnexthopserver_binding[] get_filtered(nitro_service service, String filter) throws Exception{
		vpnglobal_vpnnexthopserver_binding obj = new vpnglobal_vpnnexthopserver_binding();
		options option = new options();
		option.set_filter(filter);
		vpnglobal_vpnnexthopserver_binding[] response = (vpnglobal_vpnnexthopserver_binding[]) obj.getfiltered(service, option);
		return response;
	}
1136265
def _provision_network(self, port_id, net_uuid, network_type,
                           physical_network, segmentation_id):
        """"""
        LOG.info("Provisioning network %s", net_uuid)

        vswitch_name = self._get_vswitch_name(network_type, physical_network)
        vswitch_map = {
            'network_type': network_type,
            'vswitch_name': vswitch_name,
            'ports': [],
            'vlan_id': segmentation_id}
        self._network_vswitch_map[net_uuid] = vswitch_map
638737
function getInstanceRoute(machineName, versionKey, instanceKey){

        let manifest = getManifest();

        let machine = manifest.machines[machineName];
        if (!machine) {
            throw new Error("Machine does not exists");
        }

        let version = machine.versions[versionKey];
        if (!version) {
            throw new Error("Version does not exists");
        }

        let instance = version.instances[instanceKey];
        if (!instance) {
            throw new Error("Instance does not exists");
        }

        return instance.route;
    }
847842
def show_vpnservice(self, vpnservice, **kwargs):
        '''
        
        '''
        vpnservice_id = self._find_vpnservice_id(vpnservice)
        return self.network_conn.show_vpnservice(vpnservice_id, **kwargs)
691928
def from_api_repr(cls, resource):
        
        version = resource.get("version")
        etag = resource.get("etag")
        policy = cls(etag, version)
        for binding in resource.get("bindings", ()):
            role = binding["role"]
            members = sorted(binding["members"])
            policy[role] = members
        return policy