code
stringlengths
1
18.2k
def get_vnetwork_dvs_output_vnetwork_dvs_interface_type(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") get_vnetwork_dvs = ET.Element("get_vnetwork_dvs") config = get_vnetwork_dvs output = ET.SubElement(get_vnetwork_dvs, "output") vnetwork_dvs = ET.SubElement(output, "vnetwork-dvs") interface_...
def get_vnetwork_dvs_output_vnetwork_dvs_interface_name(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") get_vnetwork_dvs = ET.Element("get_vnetwork_dvs") config = get_vnetwork_dvs output = ET.SubElement(get_vnetwork_dvs, "output") vnetwork_dvs = ET.SubElement(output, "vnetwork-dvs") interface_...
def get_vnetwork_dvs_output_has_more(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") get_vnetwork_dvs = ET.Element("get_vnetwork_dvs") config = get_vnetwork_dvs output = ET.SubElement(get_vnetwork_dvs, "output") has_more = ET.SubElement(output, "has-more") has_more.text = kwargs.pop('has_more'...
def get_vnetwork_dvs_output_instance_id(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") get_vnetwork_dvs = ET.Element("get_vnetwork_dvs") config = get_vnetwork_dvs output = ET.SubElement(get_vnetwork_dvs, "output") instance_id = ET.SubElement(output, "instance-id") instance_id.text = kwargs.po...
def get_vnetwork_vswitches_input_name(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") get_vnetwork_vswitches = ET.Element("get_vnetwork_vswitches") config = get_vnetwork_vswitches input = ET.SubElement(get_vnetwork_vswitches, "input") name = ET.SubElement(input, "name") name.text = kwargs.pop(...
def get_vnetwork_vswitches_input_vcenter(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") get_vnetwork_vswitches = ET.Element("get_vnetwork_vswitches") config = get_vnetwork_vswitches input = ET.SubElement(get_vnetwork_vswitches, "input") vcenter = ET.SubElement(input, "vcenter") vcenter.text =...
def get_vnetwork_vswitches_input_datacenter(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") get_vnetwork_vswitches = ET.Element("get_vnetwork_vswitches") config = get_vnetwork_vswitches input = ET.SubElement(get_vnetwork_vswitches, "input") datacenter = ET.SubElement(input, "datacenter") datac...
def get_vnetwork_vswitches_input_last_rcvd_instance(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") get_vnetwork_vswitches = ET.Element("get_vnetwork_vswitches") config = get_vnetwork_vswitches input = ET.SubElement(get_vnetwork_vswitches, "input") last_rcvd_instance = ET.SubElement(input, "la...
def get_vnetwork_vswitches_output_vnetwork_vswitches_name(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") get_vnetwork_vswitches = ET.Element("get_vnetwork_vswitches") config = get_vnetwork_vswitches output = ET.SubElement(get_vnetwork_vswitches, "output") vnetwork_vswitches = ET.SubElement(ou...
def get_vnetwork_vswitches_output_vnetwork_vswitches_host(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") get_vnetwork_vswitches = ET.Element("get_vnetwork_vswitches") config = get_vnetwork_vswitches output = ET.SubElement(get_vnetwork_vswitches, "output") vnetwork_vswitches = ET.SubElement(ou...
def get_vnetwork_vswitches_output_vnetwork_vswitches_datacenter(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") get_vnetwork_vswitches = ET.Element("get_vnetwork_vswitches") config = get_vnetwork_vswitches output = ET.SubElement(get_vnetwork_vswitches, "output") vnetwork_vswitches = ET.SubElem...
def get_vnetwork_vswitches_output_vnetwork_vswitches_pnic(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") get_vnetwork_vswitches = ET.Element("get_vnetwork_vswitches") config = get_vnetwork_vswitches output = ET.SubElement(get_vnetwork_vswitches, "output") vnetwork_vswitches = ET.SubElement(ou...
def get_vnetwork_vswitches_output_vnetwork_vswitches_interface_type(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") get_vnetwork_vswitches = ET.Element("get_vnetwork_vswitches") config = get_vnetwork_vswitches output = ET.SubElement(get_vnetwork_vswitches, "output") vnetwork_vswitches = ET.Sub...
def get_vnetwork_vswitches_output_vnetwork_vswitches_interface_name(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") get_vnetwork_vswitches = ET.Element("get_vnetwork_vswitches") config = get_vnetwork_vswitches output = ET.SubElement(get_vnetwork_vswitches, "output") vnetwork_vswitches = ET.Sub...
def get_vnetwork_vswitches_output_has_more(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") get_vnetwork_vswitches = ET.Element("get_vnetwork_vswitches") config = get_vnetwork_vswitches output = ET.SubElement(get_vnetwork_vswitches, "output") has_more = ET.SubElement(output, "has-more") has_mor...
def get_vnetwork_vswitches_output_instance_id(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") get_vnetwork_vswitches = ET.Element("get_vnetwork_vswitches") config = get_vnetwork_vswitches output = ET.SubElement(get_vnetwork_vswitches, "output") instance_id = ET.SubElement(output, "instance-id"...
def get_vnetwork_portgroups_input_name(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") get_vnetwork_portgroups = ET.Element("get_vnetwork_portgroups") config = get_vnetwork_portgroups input = ET.SubElement(get_vnetwork_portgroups, "input") name = ET.SubElement(input, "name") name.text = kwargs...
def get_vnetwork_portgroups_input_vcenter(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") get_vnetwork_portgroups = ET.Element("get_vnetwork_portgroups") config = get_vnetwork_portgroups input = ET.SubElement(get_vnetwork_portgroups, "input") vcenter = ET.SubElement(input, "vcenter") vcenter.t...
def get_vnetwork_portgroups_input_datacenter(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") get_vnetwork_portgroups = ET.Element("get_vnetwork_portgroups") config = get_vnetwork_portgroups input = ET.SubElement(get_vnetwork_portgroups, "input") datacenter = ET.SubElement(input, "datacenter") ...
def get_vnetwork_portgroups_input_last_rcvd_instance(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") get_vnetwork_portgroups = ET.Element("get_vnetwork_portgroups") config = get_vnetwork_portgroups input = ET.SubElement(get_vnetwork_portgroups, "input") last_rcvd_instance = ET.SubElement(input...
def get_vnetwork_portgroups_output_vnetwork_pgs_name(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") get_vnetwork_portgroups = ET.Element("get_vnetwork_portgroups") config = get_vnetwork_portgroups output = ET.SubElement(get_vnetwork_portgroups, "output") vnetwork_pgs = ET.SubElement(output, "...
def get_vnetwork_portgroups_output_vnetwork_pgs_datacenter(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") get_vnetwork_portgroups = ET.Element("get_vnetwork_portgroups") config = get_vnetwork_portgroups output = ET.SubElement(get_vnetwork_portgroups, "output") vnetwork_pgs = ET.SubElement(out...
def get_vnetwork_portgroups_output_vnetwork_pgs_vs_nn(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") get_vnetwork_portgroups = ET.Element("get_vnetwork_portgroups") config = get_vnetwork_portgroups output = ET.SubElement(get_vnetwork_portgroups, "output") vnetwork_pgs = ET.SubElement(output, ...
def get_vnetwork_portgroups_output_vnetwork_pgs_vlan(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") get_vnetwork_portgroups = ET.Element("get_vnetwork_portgroups") config = get_vnetwork_portgroups output = ET.SubElement(get_vnetwork_portgroups, "output") vnetwork_pgs = ET.SubElement(output, "...
def get_vnetwork_portgroups_output_vnetwork_pgs_host_nn(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") get_vnetwork_portgroups = ET.Element("get_vnetwork_portgroups") config = get_vnetwork_portgroups output = ET.SubElement(get_vnetwork_portgroups, "output") vnetwork_pgs = ET.SubElement(output...
def get_vnetwork_portgroups_output_has_more(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") get_vnetwork_portgroups = ET.Element("get_vnetwork_portgroups") config = get_vnetwork_portgroups output = ET.SubElement(get_vnetwork_portgroups, "output") has_more = ET.SubElement(output, "has-more") ha...
def get_vnetwork_portgroups_output_instance_id(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") get_vnetwork_portgroups = ET.Element("get_vnetwork_portgroups") config = get_vnetwork_portgroups output = ET.SubElement(get_vnetwork_portgroups, "output") instance_id = ET.SubElement(output, "instanc...
def get_vmpolicy_macaddr_input_mac(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") get_vmpolicy_macaddr = ET.Element("get_vmpolicy_macaddr") config = get_vmpolicy_macaddr input = ET.SubElement(get_vmpolicy_macaddr, "input") mac = ET.SubElement(input, "mac") mac.text = kwargs.pop('mac') callbac...
def get_vmpolicy_macaddr_input_vcenter(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") get_vmpolicy_macaddr = ET.Element("get_vmpolicy_macaddr") config = get_vmpolicy_macaddr input = ET.SubElement(get_vmpolicy_macaddr, "input") vcenter = ET.SubElement(input, "vcenter") vcenter.text = kwargs.po...
def get_vmpolicy_macaddr_input_datacenter(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") get_vmpolicy_macaddr = ET.Element("get_vmpolicy_macaddr") config = get_vmpolicy_macaddr input = ET.SubElement(get_vmpolicy_macaddr, "input") datacenter = ET.SubElement(input, "datacenter") datacenter.text...
def get_vmpolicy_macaddr_input_last_rcvd_instance(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") get_vmpolicy_macaddr = ET.Element("get_vmpolicy_macaddr") config = get_vmpolicy_macaddr input = ET.SubElement(get_vmpolicy_macaddr, "input") last_rcvd_instance = ET.SubElement(input, "last-rcvd-in...
def get_vmpolicy_macaddr_output_vmpolicy_macaddr_mac(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") get_vmpolicy_macaddr = ET.Element("get_vmpolicy_macaddr") config = get_vmpolicy_macaddr output = ET.SubElement(get_vmpolicy_macaddr, "output") vmpolicy_macaddr = ET.SubElement(output, "vmpolicy...
def get_vmpolicy_macaddr_output_vmpolicy_macaddr_name(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") get_vmpolicy_macaddr = ET.Element("get_vmpolicy_macaddr") config = get_vmpolicy_macaddr output = ET.SubElement(get_vmpolicy_macaddr, "output") vmpolicy_macaddr = ET.SubElement(output, "vmpolic...
def get_vmpolicy_macaddr_output_vmpolicy_macaddr_datacenter(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") get_vmpolicy_macaddr = ET.Element("get_vmpolicy_macaddr") config = get_vmpolicy_macaddr output = ET.SubElement(get_vmpolicy_macaddr, "output") vmpolicy_macaddr = ET.SubElement(output, "v...
def get_vmpolicy_macaddr_output_vmpolicy_macaddr_dvpg_nn(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") get_vmpolicy_macaddr = ET.Element("get_vmpolicy_macaddr") config = get_vmpolicy_macaddr output = ET.SubElement(get_vmpolicy_macaddr, "output") vmpolicy_macaddr = ET.SubElement(output, "vmpo...
def get_vmpolicy_macaddr_output_vmpolicy_macaddr_port_nn(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") get_vmpolicy_macaddr = ET.Element("get_vmpolicy_macaddr") config = get_vmpolicy_macaddr output = ET.SubElement(get_vmpolicy_macaddr, "output") vmpolicy_macaddr = ET.SubElement(output, "vmpo...
def get_vmpolicy_macaddr_output_vmpolicy_macaddr_port_prof(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") get_vmpolicy_macaddr = ET.Element("get_vmpolicy_macaddr") config = get_vmpolicy_macaddr output = ET.SubElement(get_vmpolicy_macaddr, "output") vmpolicy_macaddr = ET.SubElement(output, "vm...
def get_vmpolicy_macaddr_output_has_more(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") get_vmpolicy_macaddr = ET.Element("get_vmpolicy_macaddr") config = get_vmpolicy_macaddr output = ET.SubElement(get_vmpolicy_macaddr, "output") has_more = ET.SubElement(output, "has-more") has_more.text = k...
def get_vmpolicy_macaddr_output_instance_id(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") get_vmpolicy_macaddr = ET.Element("get_vmpolicy_macaddr") config = get_vmpolicy_macaddr output = ET.SubElement(get_vmpolicy_macaddr, "output") instance_id = ET.SubElement(output, "instance-id") instance...
def vcenter_id(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") vcenter = ET.SubElement(config, "vcenter", xmlns="urn:brocade.com:mgmt:brocade-vswitch") id = ET.SubElement(vcenter, "id") id.text = kwargs.pop('id') callback = kwargs.pop('callback', self._callback) return callback(config)
def vcenter_credentials_url(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") vcenter = ET.SubElement(config, "vcenter", xmlns="urn:brocade.com:mgmt:brocade-vswitch") id_key = ET.SubElement(vcenter, "id") id_key.text = kwargs.pop('id') credentials = ET.SubElement(vcenter, "credentials") url = ET...
def vcenter_credentials_username(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") vcenter = ET.SubElement(config, "vcenter", xmlns="urn:brocade.com:mgmt:brocade-vswitch") id_key = ET.SubElement(vcenter, "id") id_key.text = kwargs.pop('id') credentials = ET.SubElement(vcenter, "credentials") use...
def vcenter_credentials_password(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") vcenter = ET.SubElement(config, "vcenter", xmlns="urn:brocade.com:mgmt:brocade-vswitch") id_key = ET.SubElement(vcenter, "id") id_key.text = kwargs.pop('id') credentials = ET.SubElement(vcenter, "credentials") pas...
def vcenter_credentials_vrf_name(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") vcenter = ET.SubElement(config, "vcenter", xmlns="urn:brocade.com:mgmt:brocade-vswitch") id_key = ET.SubElement(vcenter, "id") id_key.text = kwargs.pop('id') credentials = ET.SubElement(vcenter, "credentials") vrf...
def vcenter_activate(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") vcenter = ET.SubElement(config, "vcenter", xmlns="urn:brocade.com:mgmt:brocade-vswitch") id_key = ET.SubElement(vcenter, "id") id_key.text = kwargs.pop('id') activate = ET.SubElement(vcenter, "activate") callback = kwargs.pop...
def vcenter_interval(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") vcenter = ET.SubElement(config, "vcenter", xmlns="urn:brocade.com:mgmt:brocade-vswitch") id_key = ET.SubElement(vcenter, "id") id_key.text = kwargs.pop('id') interval = ET.SubElement(vcenter, "interval") interval.text = kwarg...
def vcenter_discovery_ignore_delete_all_response_ignore_value(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") vcenter = ET.SubElement(config, "vcenter", xmlns="urn:brocade.com:mgmt:brocade-vswitch") id_key = ET.SubElement(vcenter, "id") id_key.text = kwargs.pop('id') discovery = ET.SubElement(...
def vcenter_discovery_ignore_delete_all_response_always(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") vcenter = ET.SubElement(config, "vcenter", xmlns="urn:brocade.com:mgmt:brocade-vswitch") id_key = ET.SubElement(vcenter, "id") id_key.text = kwargs.pop('id') discovery = ET.SubElement(vcente...
def fcoe_fcoe_map_fcoe_map_fabric_map_fcoe_map_fabric_map_name(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") fcoe = ET.SubElement(config, "fcoe", xmlns="urn:brocade.com:mgmt:brocade-fcoe") fcoe_map = ET.SubElement(fcoe, "fcoe-map") fcoe_map_name_key = ET.SubElement(fcoe_map, "fcoe-map-name")...
def fcoe_fcoe_fcf_map_fcf_map_name(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") fcoe = ET.SubElement(config, "fcoe", xmlns="urn:brocade.com:mgmt:brocade-fcoe") fcoe_fcf_map = ET.SubElement(fcoe, "fcoe-fcf-map") fcf_map_name = ET.SubElement(fcoe_fcf_map, "fcf-map-name") fcf_map_name.text = k...
def fcoe_fcoe_fcf_map_fcf_map_fcoe_map_fcf_map_fcoe_map_leaf(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") fcoe = ET.SubElement(config, "fcoe", xmlns="urn:brocade.com:mgmt:brocade-fcoe") fcoe_fcf_map = ET.SubElement(fcoe, "fcoe-fcf-map") fcf_map_name_key = ET.SubElement(fcoe_fcf_map, "fcf-ma...
def fcoe_fcoe_fcf_map_fcf_map_ag_rbid(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") fcoe = ET.SubElement(config, "fcoe", xmlns="urn:brocade.com:mgmt:brocade-fcoe") fcoe_fcf_map = ET.SubElement(fcoe, "fcoe-fcf-map") fcf_map_name_key = ET.SubElement(fcoe_fcf_map, "fcf-map-name") fcf_map_name_k...
def gfm(text): """Processes Markdown according to GitHub Flavored Markdown spec.""" extractions = {} def extract_pre_block(matchobj): match = matchobj.group(0) hashed_match = hashlib.md5(match.encode('utf-8')).hexdigest() extractions[hashed_match] = match result = "{gfm-extraction-%s}" % hashed_match return result def ...
def markdown(text): """Processes GFM then converts it to HTML.""" text = gfm(text) text = markdown_lib.markdown(text) return text
def get_port_channel_detail_input_last_aggregator_id(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") get_port_channel_detail = ET.Element("get_port_channel_detail") config = get_port_channel_detail input = ET.SubElement(get_port_channel_detail, "input") last_aggregator_id = ET.SubElement(input...
def get_mac_address_table_input_request_type_get_interface_based_request_forwarding_interface_interface_type(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") get_mac_address_table = ET.Element("get_mac_address_table") config = get_mac_address_table input = ET.SubElement(get_mac_address_table, "...
def get_mac_address_table_input_request_type_get_interface_based_request_forwarding_interface_interface_name(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") get_mac_address_table = ET.Element("get_mac_address_table") config = get_mac_address_table input = ET.SubElement(get_mac_address_table, "...
def get_mac_address_table_input_request_type_get_interface_based_request_mac_type(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") get_mac_address_table = ET.Element("get_mac_address_table") config = get_mac_address_table input = ET.SubElement(get_mac_address_table, "input") request_type = ET.S...
def get_mac_address_table_input_request_type_get_next_request_forwarding_interface_type(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") get_mac_address_table = ET.Element("get_mac_address_table") config = get_mac_address_table input = ET.SubElement(get_mac_address_table, "input") request_type ...
def get_mac_address_table_input_request_type_get_next_request_forwarding_interface_name(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") get_mac_address_table = ET.Element("get_mac_address_table") config = get_mac_address_table input = ET.SubElement(get_mac_address_table, "input") request_type ...
def get_mac_address_table_input_request_type_get_next_request_mac_address_type(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") get_mac_address_table = ET.Element("get_mac_address_table") config = get_mac_address_table input = ET.SubElement(get_mac_address_table, "input") request_type = ET.SubE...
def mac_access_list_standard_name(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") mac = ET.SubElement(config, "mac", xmlns="urn:brocade.com:mgmt:brocade-mac-access-list") access_list = ET.SubElement(mac, "access-list") standard = ET.SubElement(access_list, "standard") name = ET.SubElement(stan...
def mac_access_list_standard_hide_mac_acl_std_seq_seq_id(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") mac = ET.SubElement(config, "mac", xmlns="urn:brocade.com:mgmt:brocade-mac-access-list") access_list = ET.SubElement(mac, "access-list") standard = ET.SubElement(access_list, "standard") na...
def mac_access_list_standard_hide_mac_acl_std_seq_action(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") mac = ET.SubElement(config, "mac", xmlns="urn:brocade.com:mgmt:brocade-mac-access-list") access_list = ET.SubElement(mac, "access-list") standard = ET.SubElement(access_list, "standard") na...
def mac_access_list_extended_name(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") mac = ET.SubElement(config, "mac", xmlns="urn:brocade.com:mgmt:brocade-mac-access-list") access_list = ET.SubElement(mac, "access-list") extended = ET.SubElement(access_list, "extended") name = ET.SubElement(exte...
def mac_access_list_extended_hide_mac_acl_ext_seq_seq_id(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") mac = ET.SubElement(config, "mac", xmlns="urn:brocade.com:mgmt:brocade-mac-access-list") access_list = ET.SubElement(mac, "access-list") extended = ET.SubElement(access_list, "extended") na...
def mac_access_list_extended_hide_mac_acl_ext_seq_action(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") mac = ET.SubElement(config, "mac", xmlns="urn:brocade.com:mgmt:brocade-mac-access-list") access_list = ET.SubElement(mac, "access-list") extended = ET.SubElement(access_list, "extended") na...
def get_mac_acl_for_intf_input_interface_type(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") get_mac_acl_for_intf = ET.Element("get_mac_acl_for_intf") config = get_mac_acl_for_intf input = ET.SubElement(get_mac_acl_for_intf, "input") interface_type = ET.SubElement(input, "interface-type") int...
def get_mac_acl_for_intf_input_interface_name(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") get_mac_acl_for_intf = ET.Element("get_mac_acl_for_intf") config = get_mac_acl_for_intf input = ET.SubElement(get_mac_acl_for_intf, "input") interface_name = ET.SubElement(input, "interface-name") int...
def get_mac_acl_for_intf_input_direction(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") get_mac_acl_for_intf = ET.Element("get_mac_acl_for_intf") config = get_mac_acl_for_intf input = ET.SubElement(get_mac_acl_for_intf, "input") direction = ET.SubElement(input, "direction") direction.text = k...
def get_mac_acl_for_intf_output_interface_interface_type(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") get_mac_acl_for_intf = ET.Element("get_mac_acl_for_intf") config = get_mac_acl_for_intf output = ET.SubElement(get_mac_acl_for_intf, "output") interface = ET.SubElement(output, "interface")...
def get_mac_acl_for_intf_output_interface_interface_name(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") get_mac_acl_for_intf = ET.Element("get_mac_acl_for_intf") config = get_mac_acl_for_intf output = ET.SubElement(get_mac_acl_for_intf, "output") interface = ET.SubElement(output, "interface")...
def get_mac_acl_for_intf_output_interface_ingress_policy_policy_name(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") get_mac_acl_for_intf = ET.Element("get_mac_acl_for_intf") config = get_mac_acl_for_intf output = ET.SubElement(get_mac_acl_for_intf, "output") interface = ET.SubElement(output, ...
def add_log_options(self, verbose_func=None, quiet_func=None): """ A helper for setting up log options """ if not verbose_func: def verbose_func(): return log.config(verbose=True) if not quiet_func: def quiet_func(): return log.config(quiet=True) self.option('-v, --verbose', 'show more logs', verbose_func) self.option(...
def local_asn(self, **kwargs): """Set BGP local ASN. Args: local_as (str): Local ASN of NOS deice. rbridge_id (str): The rbridge ID of the device on which BGP will be configured in a VCS fabric. get (bool): Get config instead of editing config. (True, False) callback (function): A function executed upon completion of t...
rbridge_id = kwargs.pop('rbridge_id', '1') callback = kwargs.pop('callback', self._callback) local_as_args = dict(local_as=local_as, rbridge_id=rbridge_id) enable_bgp = getattr(self._rbridge, 'rbridge_id_router_router_bgp_router_bgp_' 'attributes_local_as')(**local_as_args) bgp = enable_bgp.find('.//*.//*.//*') bgp.rem...
def as4_capability(self, **kwargs): """Set Spanning Tree state. Args: enabled (bool): Is AS4 Capability enabled? (True, False) callback (function): A function executed upon completion of the method. The only parameter passed to `callback` will be the ``ElementTree`` `config`. Returns: Return value of `callback`. Raises...
getattr(self._rbridge, 'rbridge_id_router_router_bgp_router_bgp' '_attributes_capability_as4_enable') config = as4_capability(**as4_capability_args) if not enabled: capability = config.find('.//*capability') capability.set('operation', 'delete') # shutdown = capability.find('.//*as4-enable') # shutdown.set('operation',...
def remove_bgp(self, **kwargs): """Remove BGP process completely. Args: vrf (str): The VRF for this BGP process. rbridge_id (str): The rbridge ID of the device on which BGP will be configured in a VCS fabric. callback (function): A function executed upon completion of the method. The only parameter passed to `callback`...
def neighbor(self, **kwargs): """Add BGP neighbor. Args: ip_addr (str): IP Address of BGP neighbor. remote_as (str): Remote ASN of BGP neighbor. rbridge_id (str): The rbridge ID of the device on which BGP will be configured in a VCS fabric. delete (bool): Deletes the neighbor if `delete` is ``True``. get (bool): Get co...
output = dev.bgp.neighbor(remote_as='65535', ... rbridge_id='225', ... ip_addr='2001:4818:f000:1ab:cafe:beef:1000:1') ... output = dev.bgp.neighbor(ip_addr='10.10.10.10', ... delete=True, rbridge_id='225') ... output = dev.bgp.neighbor(remote_as='65535', ... rbridge_id='225', ... ip_addr='2001:4818:f000:1ab:cafe:beef:1...
'delete') elif ip_addr.version == 6: config.find(ip_addr_path).set('operation', 'delete') config.find('.//*router-bgp-neighbor-ipv6-address').set( 'operation', 'delete') else: if ip_addr.version == 6: callback(config) activate_args = dict(rbridge_id=rbridge_id, af_ipv6_neighbor_address=str(ip_addr.ip)) activate_neighbo...
def redistribute(self, **kwargs): """Set BGP redistribute properties. Args: vrf (str): The VRF for this BGP process. rbridge_id (str): The rbridge ID of the device on which BGP will be configured in a VCS fabric. source (str): Source for redistributing. (connected) afi (str): Address family to configure. (ipv4, ipv6) g...
... rbridge_id='225', delete=True) ... dev.bgp.redistribute() # doctest: +IGNORE_EXCEPTION_DETAIL Traceback (most recent call last): KeyError ... dev.bgp.redistribute(source='connected', rbridge_id='225', ... afi='hodor') # doctest: +IGNORE_EXCEPTION_DETAIL Traceback (most recent call last): AttributeError ... dev.bgp....
def _redistribute_builder(self, afi='ipv4', source=None): """Build BGP redistribute method. Do not use this method directly. You probably want ``redistribute``. Args: source (str): Source for redistributing. (connected) afi (str): Address family to configure. (ipv4, ipv6) Returns: Method to redistribute desired source....
def max_paths(self, **kwargs): """Set BGP max paths property. Args: vrf (str): The VRF for this BGP process. rbridge_id (str): The rbridge ID of the device on which BGP will be configured in a VCS fabric. paths (str): Number of paths for BGP ECMP (default: 8). afi (str): Address family to configure. (ipv4, ipv6) get (b...
dev.bgp.max_paths(paths='8', ... rbridge_id='225', get=True) ... output = dev.bgp.max_paths(paths='8', ... rbridge_id='225', delete=True) ... output = dev.bgp.max_paths(paths='8', afi='ipv6', ... rbridge_id='225') ... output = dev.bgp.max_paths(paths='8', afi='ipv6', ... rbridge_id='225', get=True) ... output = dev.bgp...
def _multihop_xml(self, **kwargs): """Build BGP multihop XML. Do not use this method directly. You probably want ``multihop``. Args: rbridge_id (str): The rbridge ID of the device on which BGP will be configured in a VCS fabric. neighbor (ipaddress.ip_interface): `ip_interface` object containing peer IP address (IPv4 o...
config = ET.Element('config') ele = ET.SubElement(config, 'rbridge-id', xmlns=rbr_ns) ET.SubElement(ele, 'rbridge-id').text = kwargs.pop('rbridge_id') ele = ET.SubElement(ele, 'router') ele = ET.SubElement(ele, 'router-bgp', xmlns=bgp_ns) ele = ET.SubElement(ele, 'router-bgp-attributes') ele = ET.SubElement(ele, 'neigh...
def return_xml(element_tree): """Return an XML Element. Args: element_tree (Element): XML Element to be returned. If sent as a ``str``, this function will attempt to convert it to an ``Element``. Returns: Element: An XML Element. Raises: TypeError: if `element_tree` is not of type ``Element`` and it cannot be converted...
def valid_vlan_id(vlan_id, extended=True): """Validates a VLAN ID. Args: vlan_id (integer): VLAN ID to validate. If passed as ``str``, it will be cast to ``int``. extended (bool): If the VLAN ID range should be considered extended for Virtual Fabrics. Returns: bool: ``True`` if it is a valid VLAN ID. ``False`` if not. ...
def merge_xml(first_doc, second_doc): """Merges two XML documents. Args: first_doc (str): First XML document. `second_doc` is merged into this document. second_doc (str): Second XML document. It is merged into the first. Returns: XML Document: The merged document. Raises: None Example: >>> import pynos.utilities >>> im...
KeyError: # The element doesn't exist # add it to the mapping and the root document mapping[element.tag] = element first_doc.append(element) else: # This element has children. Recurse. try: merge_xml(mapping[element.tag], element) except KeyError: # The element doesn't exist # add it to the mapping and the root documen...
def terminal_cfg_line_sessionid(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") terminal_cfg = ET.SubElement(config, "terminal-cfg", xmlns="urn:brocade.com:mgmt:brocade-terminal") line = ET.SubElement(terminal_cfg, "line") sessionid = ET.SubElement(line, "sessionid") sessionid.text = kwargs.po...
def terminal_cfg_line_exec_timeout(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") terminal_cfg = ET.SubElement(config, "terminal-cfg", xmlns="urn:brocade.com:mgmt:brocade-terminal") line = ET.SubElement(terminal_cfg, "line") sessionid_key = ET.SubElement(line, "sessionid") sessionid_key.text ...
def get_scss_files(self, skip_partials=True, with_source_path=False): """Gets all SCSS files in the source directory. :param bool skip_partials: If True, partials will be ignored. Otherwise, all SCSS files, including ones that begin with '_' will be returned. :param boom with_source_path: If true, the `source_path` wil...
def _or_join(self, terms): """ Joins terms using OR operator. Args: terms (list): terms to join Examples: self._or_join(['term1', 'term2']) -> 'term1 | term2' Returns: str """ from six import text_type if isinstance(terms, (tuple, list)): if len(terms) > 1: return ' | '.join(text_type(t) for t in terms) else: return te...
def search(self, search_phrase, limit=None): """ Finds datasets by search phrase. Args: search_phrase (str or unicode): limit (int, optional): how many results to return. None means without limit. Returns: list of DatasetSearchResult instances. """ query, query_params = self._make_query_from_terms(search_phrase, limit=...
def all(self): """ Returns list with all indexed datasets. """ datasets = [] query = text(""" SELECT vid FROM dataset_index;""") for result in self.execute(query): res = DatasetSearchResult() res.vid = result[0] res.b_score = 1 datasets.append(res) return datasets
def _index_document(self, document, force=False): """ Adds dataset document to the index. """ query = text(""" INSERT INTO dataset_index(vid, title, keywords, doc) VALUES(:vid, :title, string_to_array(:keywords, ' '), to_tsvector('english', :doc)); """) self.execute(query, **document)