function stringlengths 11 56k | repo_name stringlengths 5 60 | features list |
|---|---|---|
def get_flavor(self, flavor_id):
return self.api_get('/flavors/%s' % flavor_id).body['flavor'] | cernops/nova | [
5,
2,
5,
2,
1418819480
] |
def post_flavor(self, flavor):
return self.api_post('/flavors', flavor).body['flavor'] | cernops/nova | [
5,
2,
5,
2,
1418819480
] |
def post_extra_spec(self, flavor_id, spec):
return self.api_post('/flavors/%s/os-extra_specs' %
flavor_id, spec) | cernops/nova | [
5,
2,
5,
2,
1418819480
] |
def get_volumes(self, detail=True):
rel_url = '/os-volumes/detail' if detail else '/os-volumes'
return self.api_get(rel_url).body['volumes'] | cernops/nova | [
5,
2,
5,
2,
1418819480
] |
def delete_volume(self, volume_id):
return self.api_delete('/os-volumes/%s' % volume_id) | cernops/nova | [
5,
2,
5,
2,
1418819480
] |
def get_snapshots(self, detail=True):
rel_url = '/os-snapshots/detail' if detail else '/os-snapshots'
return self.api_get(rel_url).body['snapshots'] | cernops/nova | [
5,
2,
5,
2,
1418819480
] |
def delete_snapshot(self, snap_id):
return self.api_delete('/os-snapshots/%s' % snap_id) | cernops/nova | [
5,
2,
5,
2,
1418819480
] |
def get_server_volumes(self, server_id):
return self.api_get('/servers/%s/os-volume_attachments' %
(server_id)).body['volumeAttachments'] | cernops/nova | [
5,
2,
5,
2,
1418819480
] |
def delete_server_volume(self, server_id, attachment_id):
return self.api_delete('/servers/%s/os-volume_attachments/%s' %
(server_id, attachment_id)) | cernops/nova | [
5,
2,
5,
2,
1418819480
] |
def get_server_groups(self, all_projects=None):
if all_projects:
return self.api_get(
'/os-server-groups?all_projects').body['server_groups']
else:
return self.api_get('/os-server-groups').body['server_groups'] | cernops/nova | [
5,
2,
5,
2,
1418819480
] |
def post_server_groups(self, group):
response = self.api_post('/os-server-groups', {"server_group": group})
return response.body['server_group'] | cernops/nova | [
5,
2,
5,
2,
1418819480
] |
def resource_setup(cls):
super(CrossdomainTest, cls).resource_setup()
cls.xml_start = '<?xml version="1.0"?>\n' \
'<!DOCTYPE cross-domain-policy SYSTEM ' \
'"http://www.adobe.com/xml/dtds/cross-domain-policy.' \
'dtd" >\n<cross-dom... | cisco-openstack/tempest | [
2,
2,
2,
1,
1410968777
] |
def __init__(self, width, num_classes,
variant='ResNet50',
which_norm='BatchNorm', norm_kwargs=None,
activation='relu', drop_rate=0.0,
fc_init=jnp.zeros, conv_kwargs=None,
preactivation=True, use_se=False, se_ratio=0.25,
name='Res... | deepmind/deepmind-research | [
11519,
2366,
11519,
161,
1547546053
] |
def __init__(self, out_ch, stride=1, use_projection=False,
activation=jax.nn.relu, which_norm=hk.BatchNorm,
which_conv=hk.Conv2D, use_se=False, se_ratio=0.25,
name=None):
super().__init__(name=name)
self.out_ch = out_ch
self.stride = stride
self.use_projectio... | deepmind/deepmind-research | [
11519,
2366,
11519,
161,
1547546053
] |
def parse_args():
parser = argparse.ArgumentParser()
parser.add_argument(
"--expected",
"-e",
dest="expected",
type=str,
default="",
help="Comma separated list of frameworks to expect.\n"
"Will fail if any of these are not found",
)
return parser.... | Yelp/paasta | [
1644,
229,
1644,
129,
1445895353
] |
def __init__(self, outputs, inputs, schema, rng):
"""Initialize the CGpm.
Parameters
----------
outputs : list<int>
List of endogenous variables whose joint distribution is modeled by
the CGpm. The CGpm is required to simulate and evaluate the log
den... | probcomp/cgpm | [
24,
9,
24,
42,
1452100613
] |
def unincorporate(self, rowid):
"""Remove all incorporated observations of `rowid` from the dataset."""
raise NotImplementedError | probcomp/cgpm | [
24,
9,
24,
42,
1452100613
] |
def simulate(self, rowid, query, constraints=None, inputs=None, N=None):
"""Return N iid samples of `targets` given `constraints` and `inputs`.
(X_1, X_2, ... X_N) ~iid Pr[targets | constraints; inputs]
rowid : int, or None to indicate a hypothetical row
Specifies the identity ... | probcomp/cgpm | [
24,
9,
24,
42,
1452100613
] |
def transition(self, **kwargs):
"""Apply an inference operator transitioning the internal state of CGpm.
**kwargs : arbitrary keyword arguments Opaque binary parsed by the CGpm
to apply inference over its latents. There are no restrictions on
the learning mechanism, which may be... | probcomp/cgpm | [
24,
9,
24,
42,
1452100613
] |
def save_model(self, request, obj, form, change):
# TODO do this sync async (give celery another shot?)
obj.save()
obj.fetch_all() | texastribune/wjordpress | [
8,
1,
8,
5,
1405381508
] |
def hook(self, obj):
"""
This is where an admin can find what url to point the webhook to.
Doing it as an absolute url lets us cheat and make the browser figure
out the host for us.
Requires HookPress: http://wordpress.org/plugins/hookpress/
"""
try:
... | texastribune/wjordpress | [
8,
1,
8,
5,
1405381508
] |
def __init__(cls, what, bases=None, dict=None):
super().__init__(what, bases, dict)
cls.process() | quora/qcore | [
85,
18,
85,
5,
1468262070
] |
def __len__(self):
return len(self._members) | quora/qcore | [
85,
18,
85,
5,
1468262070
] |
def __call__(self, value, default=_no_default):
"""Instantiating an Enum always produces an existing value or throws an exception."""
return self.parse(value, default=default) | quora/qcore | [
85,
18,
85,
5,
1468262070
] |
def _make_value(self, value):
"""Instantiates an enum with an arbitrary value."""
member = self.__new__(self, value)
member.__init__(value)
return member | quora/qcore | [
85,
18,
85,
5,
1468262070
] |
def __prepare__(cls, name, bases, **kwargs):
return {} | quora/qcore | [
85,
18,
85,
5,
1468262070
] |
def __init__(self, value):
self.value = int(value) | quora/qcore | [
85,
18,
85,
5,
1468262070
] |
def short_name(self):
"""Returns the enum member's name, like "foo"."""
raise NotImplementedError | quora/qcore | [
85,
18,
85,
5,
1468262070
] |
def long_name(self):
"""Returns the enum member's name including the class name, like "MyEnum.foo"."""
return "%s.%s" % (self.__class__.__name__, self.short_name) | quora/qcore | [
85,
18,
85,
5,
1468262070
] |
def title(self):
"""Returns the enum member's name in title case, like "FooBar" for MyEnum.foo_bar."""
return self.short_name.replace("_", " ").title() | quora/qcore | [
85,
18,
85,
5,
1468262070
] |
def full_name(self):
"""Returns the enum meber's name including the module, like "mymodule.MyEnum.foo"."""
return "%s.%s" % (self.__class__.__module__, self.long_name) | quora/qcore | [
85,
18,
85,
5,
1468262070
] |
def assert_valid(self):
if not self.is_valid():
raise _create_invalid_value_error(self.__class__, self.value) | quora/qcore | [
85,
18,
85,
5,
1468262070
] |
def __call__(self):
return self.value | quora/qcore | [
85,
18,
85,
5,
1468262070
] |
def __ne__(self, other):
return self.value != other | quora/qcore | [
85,
18,
85,
5,
1468262070
] |
def __str__(self):
if self.is_valid():
return self.short_name
else:
return "%s(%s)" % (self.__class__.__name__, self.value) | quora/qcore | [
85,
18,
85,
5,
1468262070
] |
def get_names(cls):
"""Returns the names of all members of this enum."""
return [m.short_name for m in cls._members] | quora/qcore | [
85,
18,
85,
5,
1468262070
] |
def get_members(cls):
return cls._members | quora/qcore | [
85,
18,
85,
5,
1468262070
] |
def create(cls, name, members):
"""Creates a new enum type based on this one (cls) and adds newly
passed members to the newly created subclass of cls.
This method helps to create enums having the same member values as
values of other enum(s).
:param name: name of the newly crea... | quora/qcore | [
85,
18,
85,
5,
1468262070
] |
def parse(cls, value, default=_no_default):
"""Parses a value into a member of this enum."""
raise NotImplementedError | quora/qcore | [
85,
18,
85,
5,
1468262070
] |
def is_valid(self):
return self.value in self._value_to_member | quora/qcore | [
85,
18,
85,
5,
1468262070
] |
def short_name(self):
self.assert_valid()
return self._value_to_name[self.value] | quora/qcore | [
85,
18,
85,
5,
1468262070
] |
def parse(cls, value, default=_no_default):
"""Parses an enum member name or value into an enum member.
Accepts the following types:
- Members of this enum class. These are returned directly.
- Integers. If there is an enum member with the integer as a value, that member is returned.
... | quora/qcore | [
85,
18,
85,
5,
1468262070
] |
def is_valid(self):
value = self.value
for v in self._flag_values:
if (v | value) == value:
value ^= v
return value == 0 | quora/qcore | [
85,
18,
85,
5,
1468262070
] |
def short_name(self):
self.assert_valid()
result = []
l = self.value
for v in self._flag_values:
if (v | l) == l:
l ^= v
result.append(self._value_to_name[v])
if not result:
if 0 in self._value_to_name:
retur... | quora/qcore | [
85,
18,
85,
5,
1468262070
] |
def parse(cls, value, default=_no_default):
"""Parses a flag integer or string into a Flags instance.
Accepts the following types:
- Members of this enum class. These are returned directly.
- Integers. These are converted directly into a Flags instance with the given name.
- Str... | quora/qcore | [
85,
18,
85,
5,
1468262070
] |
def __or__(self, other):
return self.__class__(self.value | int(other)) | quora/qcore | [
85,
18,
85,
5,
1468262070
] |
def __xor__(self, other):
return self.__class__(self.value ^ int(other)) | quora/qcore | [
85,
18,
85,
5,
1468262070
] |
def __repr__(self):
return Enum.__repr__(self) | quora/qcore | [
85,
18,
85,
5,
1468262070
] |
def __init__(self, start=1):
self._next_value = start | quora/qcore | [
85,
18,
85,
5,
1468262070
] |
def next(self):
result = self._next_value
self._next_value += 1
return result | quora/qcore | [
85,
18,
85,
5,
1468262070
] |
def __repr__(self):
return "%s(%r)" % (self.__class__.__name__, self._next_value) | quora/qcore | [
85,
18,
85,
5,
1468262070
] |
def update(self):
for index, line in self.update_json():
self.analyze(line) | yeti-platform/yeti | [
1360,
268,
1360,
132,
1450025666
] |
def __init__(self, *args, **kwargs):
self._path_helper = False
self._extmethods = False
self.__name = YANGDynClass(base=six.text_type, is_leaf=True, yang_name="name", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, namespace='http://openconfig.net/yang/macsec'... | google/gnxi | [
229,
110,
229,
19,
1506413981
] |
def _get_name(self):
"""
Getter method for name, mapped from YANG variable /macsec/mka/policies/policy/config/name (string)
YANG Description: Name of the MKA policy.
"""
return self.__name | google/gnxi | [
229,
110,
229,
19,
1506413981
] |
def _set_name(self, v, load=False):
"""
Setter method for name, mapped from YANG variable /macsec/mka/policies/policy/config/name (string)
If this variable is read-only (config: false) in the
source YANG file, then _set_name is considered as a private
method. Backends looking to populate this variab... | google/gnxi | [
229,
110,
229,
19,
1506413981
] |
def _get_key_server_priority(self):
"""
Getter method for key_server_priority, mapped from YANG variable /macsec/mka/policies/policy/config/key_server_priority (uint8)
YANG Description: Specifies the key server priority used by the MACsec Key Agreement | google/gnxi | [
229,
110,
229,
19,
1506413981
] |
def _set_key_server_priority(self, v, load=False):
"""
Setter method for key_server_priority, mapped from YANG variable /macsec/mka/policies/policy/config/key_server_priority (uint8)
If this variable is read-only (config: false) in the
source YANG file, then _set_key_server_priority is considered as a p... | google/gnxi | [
229,
110,
229,
19,
1506413981
] |
def _unset_key_server_priority(self):
self.__key_server_priority = YANGDynClass(base=RestrictedClassType(base_type=int, restriction_dict={'range': ['0..255']}, int_size=8), default=RestrictedClassType(base_type=int, restriction_dict={'range': ['0..255']}, int_size=8)(16), is_leaf=True, yang_name="key-server-priorit... | google/gnxi | [
229,
110,
229,
19,
1506413981
] |
def _set_macsec_cipher_suite(self, v, load=False):
"""
Setter method for macsec_cipher_suite, mapped from YANG variable /macsec/mka/policies/policy/config/macsec_cipher_suite (macsec-types:macsec-cipher-suite)
If this variable is read-only (config: false) in the
source YANG file, then _set_macsec_cipher... | google/gnxi | [
229,
110,
229,
19,
1506413981
] |
def _get_confidentiality_offset(self):
"""
Getter method for confidentiality_offset, mapped from YANG variable /macsec/mka/policies/policy/config/confidentiality_offset (macsec-types:confidentiality-offset)
YANG Description: The confidentiality offset specifies a number of octets in an Ethernet | google/gnxi | [
229,
110,
229,
19,
1506413981
] |
def _set_confidentiality_offset(self, v, load=False):
"""
Setter method for confidentiality_offset, mapped from YANG variable /macsec/mka/policies/policy/config/confidentiality_offset (macsec-types:confidentiality-offset)
If this variable is read-only (config: false) in the
source YANG file, then _set_c... | google/gnxi | [
229,
110,
229,
19,
1506413981
] |
def _unset_confidentiality_offset(self):
self.__confidentiality_offset = YANGDynClass(base=RestrictedClassType(base_type=six.text_type, restriction_type="dict_key", restriction_arg={'0_BYTES': {}, '30_BYTES': {}, '50_BYTES': {}},), default=six.... | google/gnxi | [
229,
110,
229,
19,
1506413981
] |
def _set_delay_protection(self, v, load=False):
"""
Setter method for delay_protection, mapped from YANG variable /macsec/mka/policies/policy/config/delay_protection (boolean)
If this variable is read-only (config: false) in the
source YANG file, then _set_delay_protection is considered as a private
... | google/gnxi | [
229,
110,
229,
19,
1506413981
] |
def _unset_delay_protection(self):
self.__delay_protection = YANGDynClass(base=YANGBool, default=YANGBool("false"), is_leaf=True, yang_name="delay-protection", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, namespace='http://openconfig.net/yang/macsec', defining_module... | google/gnxi | [
229,
110,
229,
19,
1506413981
] |
def _set_include_icv_indicator(self, v, load=False):
"""
Setter method for include_icv_indicator, mapped from YANG variable /macsec/mka/policies/policy/config/include_icv_indicator (boolean)
If this variable is read-only (config: false) in the
source YANG file, then _set_include_icv_indicator is conside... | google/gnxi | [
229,
110,
229,
19,
1506413981
] |
def _unset_include_icv_indicator(self):
self.__include_icv_indicator = YANGDynClass(base=YANGBool, default=YANGBool("true"), is_leaf=True, yang_name="include-icv-indicator", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, namespace='http://openconfig.net/yang/macsec', d... | google/gnxi | [
229,
110,
229,
19,
1506413981
] |
def _set_sak_rekey_interval(self, v, load=False):
"""
Setter method for sak_rekey_interval, mapped from YANG variable /macsec/mka/policies/policy/config/sak_rekey_interval (uint32)
If this variable is read-only (config: false) in the
source YANG file, then _set_sak_rekey_interval is considered as a priv... | google/gnxi | [
229,
110,
229,
19,
1506413981
] |
def _unset_sak_rekey_interval(self):
self.__sak_rekey_interval = YANGDynClass(base=RestrictedClassType(base_type=RestrictedClassType(base_type=long, restriction_dict={'range': ['0..4294967295']}, int_size=32), restriction_dict={'range': ['0', '30..65535']}), default=RestrictedClassType(base_type=long, restriction_d... | google/gnxi | [
229,
110,
229,
19,
1506413981
] |
def _set_sak_rekey_on_live_peer_loss(self, v, load=False):
"""
Setter method for sak_rekey_on_live_peer_loss, mapped from YANG variable /macsec/mka/policies/policy/config/sak_rekey_on_live_peer_loss (boolean)
If this variable is read-only (config: false) in the
source YANG file, then _set_sak_rekey_on_l... | google/gnxi | [
229,
110,
229,
19,
1506413981
] |
def _get_use_updated_eth_header(self):
"""
Getter method for use_updated_eth_header, mapped from YANG variable /macsec/mka/policies/policy/config/use_updated_eth_header (boolean)
YANG Description: Use updated ethernet header for ICV calculation. In case the Ethernet | google/gnxi | [
229,
110,
229,
19,
1506413981
] |
def _set_use_updated_eth_header(self, v, load=False):
"""
Setter method for use_updated_eth_header, mapped from YANG variable /macsec/mka/policies/policy/config/use_updated_eth_header (boolean)
If this variable is read-only (config: false) in the
source YANG file, then _set_use_updated_eth_header is con... | google/gnxi | [
229,
110,
229,
19,
1506413981
] |
def _unset_use_updated_eth_header(self):
self.__use_updated_eth_header = YANGDynClass(base=YANGBool, default=YANGBool("false"), is_leaf=True, yang_name="use-updated-eth-header", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, namespace='http://openconfig.net/yang/macsec... | google/gnxi | [
229,
110,
229,
19,
1506413981
] |
def __init__(self, *args, **kwargs):
self._path_helper = False
self._extmethods = False
self.__name = YANGDynClass(base=six.text_type, is_leaf=True, yang_name="name", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, namespace='http://openconfig.net/yang/macsec'... | google/gnxi | [
229,
110,
229,
19,
1506413981
] |
def _get_name(self):
"""
Getter method for name, mapped from YANG variable /macsec/mka/policies/policy/state/name (string)
YANG Description: Name of the MKA policy.
"""
return self.__name | google/gnxi | [
229,
110,
229,
19,
1506413981
] |
def _set_name(self, v, load=False):
"""
Setter method for name, mapped from YANG variable /macsec/mka/policies/policy/state/name (string)
If this variable is read-only (config: false) in the
source YANG file, then _set_name is considered as a private
method. Backends looking to populate this variabl... | google/gnxi | [
229,
110,
229,
19,
1506413981
] |
def _get_key_server_priority(self):
"""
Getter method for key_server_priority, mapped from YANG variable /macsec/mka/policies/policy/state/key_server_priority (uint8)
YANG Description: Specifies the key server priority used by the MACsec Key Agreement | google/gnxi | [
229,
110,
229,
19,
1506413981
] |
def _set_key_server_priority(self, v, load=False):
"""
Setter method for key_server_priority, mapped from YANG variable /macsec/mka/policies/policy/state/key_server_priority (uint8)
If this variable is read-only (config: false) in the
source YANG file, then _set_key_server_priority is considered as a pr... | google/gnxi | [
229,
110,
229,
19,
1506413981
] |
def _unset_key_server_priority(self):
self.__key_server_priority = YANGDynClass(base=RestrictedClassType(base_type=int, restriction_dict={'range': ['0..255']}, int_size=8), default=RestrictedClassType(base_type=int, restriction_dict={'range': ['0..255']}, int_size=8)(16), is_leaf=True, yang_name="key-server-priorit... | google/gnxi | [
229,
110,
229,
19,
1506413981
] |
def _set_macsec_cipher_suite(self, v, load=False):
"""
Setter method for macsec_cipher_suite, mapped from YANG variable /macsec/mka/policies/policy/state/macsec_cipher_suite (macsec-types:macsec-cipher-suite)
If this variable is read-only (config: false) in the
source YANG file, then _set_macsec_cipher_... | google/gnxi | [
229,
110,
229,
19,
1506413981
] |
def _get_confidentiality_offset(self):
"""
Getter method for confidentiality_offset, mapped from YANG variable /macsec/mka/policies/policy/state/confidentiality_offset (macsec-types:confidentiality-offset)
YANG Description: The confidentiality offset specifies a number of octets in an Ethernet | google/gnxi | [
229,
110,
229,
19,
1506413981
] |
def _set_confidentiality_offset(self, v, load=False):
"""
Setter method for confidentiality_offset, mapped from YANG variable /macsec/mka/policies/policy/state/confidentiality_offset (macsec-types:confidentiality-offset)
If this variable is read-only (config: false) in the
source YANG file, then _set_co... | google/gnxi | [
229,
110,
229,
19,
1506413981
] |
def _unset_confidentiality_offset(self):
self.__confidentiality_offset = YANGDynClass(base=RestrictedClassType(base_type=six.text_type, restriction_type="dict_key", restriction_arg={'0_BYTES': {}, '30_BYTES': {}, '50_BYTES': {}},), default=six.... | google/gnxi | [
229,
110,
229,
19,
1506413981
] |
def _set_delay_protection(self, v, load=False):
"""
Setter method for delay_protection, mapped from YANG variable /macsec/mka/policies/policy/state/delay_protection (boolean)
If this variable is read-only (config: false) in the
source YANG file, then _set_delay_protection is considered as a private
... | google/gnxi | [
229,
110,
229,
19,
1506413981
] |
def _unset_delay_protection(self):
self.__delay_protection = YANGDynClass(base=YANGBool, default=YANGBool("false"), is_leaf=True, yang_name="delay-protection", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, namespace='http://openconfig.net/yang/macsec', defining_module... | google/gnxi | [
229,
110,
229,
19,
1506413981
] |
def _set_include_icv_indicator(self, v, load=False):
"""
Setter method for include_icv_indicator, mapped from YANG variable /macsec/mka/policies/policy/state/include_icv_indicator (boolean)
If this variable is read-only (config: false) in the
source YANG file, then _set_include_icv_indicator is consider... | google/gnxi | [
229,
110,
229,
19,
1506413981
] |
def _unset_include_icv_indicator(self):
self.__include_icv_indicator = YANGDynClass(base=YANGBool, default=YANGBool("true"), is_leaf=True, yang_name="include-icv-indicator", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, namespace='http://openconfig.net/yang/macsec', d... | google/gnxi | [
229,
110,
229,
19,
1506413981
] |
def _set_sak_rekey_interval(self, v, load=False):
"""
Setter method for sak_rekey_interval, mapped from YANG variable /macsec/mka/policies/policy/state/sak_rekey_interval (uint32)
If this variable is read-only (config: false) in the
source YANG file, then _set_sak_rekey_interval is considered as a priva... | google/gnxi | [
229,
110,
229,
19,
1506413981
] |
def _unset_sak_rekey_interval(self):
self.__sak_rekey_interval = YANGDynClass(base=RestrictedClassType(base_type=RestrictedClassType(base_type=long, restriction_dict={'range': ['0..4294967295']}, int_size=32), restriction_dict={'range': ['0', '30..65535']}), default=RestrictedClassType(base_type=long, restriction_d... | google/gnxi | [
229,
110,
229,
19,
1506413981
] |
def _set_sak_rekey_on_live_peer_loss(self, v, load=False):
"""
Setter method for sak_rekey_on_live_peer_loss, mapped from YANG variable /macsec/mka/policies/policy/state/sak_rekey_on_live_peer_loss (boolean)
If this variable is read-only (config: false) in the
source YANG file, then _set_sak_rekey_on_li... | google/gnxi | [
229,
110,
229,
19,
1506413981
] |
def _get_use_updated_eth_header(self):
"""
Getter method for use_updated_eth_header, mapped from YANG variable /macsec/mka/policies/policy/state/use_updated_eth_header (boolean)
YANG Description: Use updated ethernet header for ICV calculation. In case the Ethernet | google/gnxi | [
229,
110,
229,
19,
1506413981
] |
def _set_use_updated_eth_header(self, v, load=False):
"""
Setter method for use_updated_eth_header, mapped from YANG variable /macsec/mka/policies/policy/state/use_updated_eth_header (boolean)
If this variable is read-only (config: false) in the
source YANG file, then _set_use_updated_eth_header is cons... | google/gnxi | [
229,
110,
229,
19,
1506413981
] |
def _unset_use_updated_eth_header(self):
self.__use_updated_eth_header = YANGDynClass(base=YANGBool, default=YANGBool("false"), is_leaf=True, yang_name="use-updated-eth-header", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, namespace='http://openconfig.net/yang/macsec... | google/gnxi | [
229,
110,
229,
19,
1506413981
] |
def __init__(self, *args, **kwargs):
self._path_helper = False
self._extmethods = False
self.__name = YANGDynClass(base=six.text_type, is_leaf=True, yang_name="name", parent=self, path_helper=self._path_helper, extmethods=self._extmethods, register_paths=True, is_keyval=True, namespace='http://openconfig.... | google/gnxi | [
229,
110,
229,
19,
1506413981
] |
def _get_name(self):
"""
Getter method for name, mapped from YANG variable /macsec/mka/policies/policy/name (leafref)
YANG Description: Reference to MKA policy name
"""
return self.__name | google/gnxi | [
229,
110,
229,
19,
1506413981
] |
def _set_name(self, v, load=False):
"""
Setter method for name, mapped from YANG variable /macsec/mka/policies/policy/name (leafref)
If this variable is read-only (config: false) in the
source YANG file, then _set_name is considered as a private
method. Backends looking to populate this variable sho... | google/gnxi | [
229,
110,
229,
19,
1506413981
] |
def _get_config(self):
"""
Getter method for config, mapped from YANG variable /macsec/mka/policies/policy/config (container)
YANG Description: Configuration of the MKA policy
"""
return self.__config | google/gnxi | [
229,
110,
229,
19,
1506413981
] |
def _set_config(self, v, load=False):
"""
Setter method for config, mapped from YANG variable /macsec/mka/policies/policy/config (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_config is considered as a private
method. Backends looking to populate this va... | google/gnxi | [
229,
110,
229,
19,
1506413981
] |
def _get_state(self):
"""
Getter method for state, mapped from YANG variable /macsec/mka/policies/policy/state (container)
YANG Description: Operational state data for MKA policy
"""
return self.__state | google/gnxi | [
229,
110,
229,
19,
1506413981
] |
def _set_state(self, v, load=False):
"""
Setter method for state, mapped from YANG variable /macsec/mka/policies/policy/state (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_state is considered as a private
method. Backends looking to populate this variab... | google/gnxi | [
229,
110,
229,
19,
1506413981
] |
def __init__(self, *args, **kwargs):
self._path_helper = False
self._extmethods = False
self.__policy = YANGDynClass(base=YANGListType("name",yc_policy_openconfig_macsec__macsec_mka_policies_policy, yang_name="policy", parent=self, is_container='list', user_ordered=False, path_helper=self._path_helper, ya... | google/gnxi | [
229,
110,
229,
19,
1506413981
] |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.