repo
stringlengths
7
55
path
stringlengths
4
223
func_name
stringlengths
1
134
original_string
stringlengths
75
104k
language
stringclasses
1 value
code
stringlengths
75
104k
code_tokens
listlengths
19
28.4k
docstring
stringlengths
1
46.9k
docstring_tokens
listlengths
1
1.97k
sha
stringlengths
40
40
url
stringlengths
87
315
partition
stringclasses
3 values
summary
stringlengths
4
350
StackStorm/pybind
pybind/slxos/v17s_1_02/overlay_gateway/__init__.py
overlay_gateway._set_gw_type
def _set_gw_type(self, v, load=False): """ Setter method for gw_type, mapped from YANG variable /overlay_gateway/gw_type (overlay-gw-type) If this variable is read-only (config: false) in the source YANG file, then _set_gw_type is considered as a private method. Backends looking to populate this var...
python
def _set_gw_type(self, v, load=False): """ Setter method for gw_type, mapped from YANG variable /overlay_gateway/gw_type (overlay-gw-type) If this variable is read-only (config: false) in the source YANG file, then _set_gw_type is considered as a private method. Backends looking to populate this var...
[ "def", "_set_gw_type", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass", "(", "v", ",", "base",...
Setter method for gw_type, mapped from YANG variable /overlay_gateway/gw_type (overlay-gw-type) If this variable is read-only (config: false) in the source YANG file, then _set_gw_type is considered as a private method. Backends looking to populate this variable should do so via calling thisObj._set_gw_...
[ "Setter", "method", "for", "gw_type", "mapped", "from", "YANG", "variable", "/", "overlay_gateway", "/", "gw_type", "(", "overlay", "-", "gw", "-", "type", ")", "If", "this", "variable", "is", "read", "-", "only", "(", "config", ":", "false", ")", "in", ...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/slxos/v17s_1_02/overlay_gateway/__init__.py#L147-L170
train
Sets the type of the cluster in the cluster.
StackStorm/pybind
pybind/slxos/v17s_1_02/overlay_gateway/__init__.py
overlay_gateway._set_map_
def _set_map_(self, v, load=False): """ Setter method for map_, mapped from YANG variable /overlay_gateway/map (container) If this variable is read-only (config: false) in the source YANG file, then _set_map_ is considered as a private method. Backends looking to populate this variable should do...
python
def _set_map_(self, v, load=False): """ Setter method for map_, mapped from YANG variable /overlay_gateway/map (container) If this variable is read-only (config: false) in the source YANG file, then _set_map_ is considered as a private method. Backends looking to populate this variable should do...
[ "def", "_set_map_", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass", "(", "v", ",", "base", ...
Setter method for map_, mapped from YANG variable /overlay_gateway/map (container) If this variable is read-only (config: false) in the source YANG file, then _set_map_ is considered as a private method. Backends looking to populate this variable should do so via calling thisObj._set_map_() directly.
[ "Setter", "method", "for", "map_", "mapped", "from", "YANG", "variable", "/", "overlay_gateway", "/", "map", "(", "container", ")", "If", "this", "variable", "is", "read", "-", "only", "(", "config", ":", "false", ")", "in", "the", "source", "YANG", "fil...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/slxos/v17s_1_02/overlay_gateway/__init__.py#L215-L236
train
Sets the map property of the
StackStorm/pybind
pybind/slxos/v17s_1_02/overlay_gateway/__init__.py
overlay_gateway._set_overlay_service_policy
def _set_overlay_service_policy(self, v, load=False): """ Setter method for overlay_service_policy, mapped from YANG variable /overlay_gateway/overlay_service_policy (container) If this variable is read-only (config: false) in the source YANG file, then _set_overlay_service_policy is considered as a pri...
python
def _set_overlay_service_policy(self, v, load=False): """ Setter method for overlay_service_policy, mapped from YANG variable /overlay_gateway/overlay_service_policy (container) If this variable is read-only (config: false) in the source YANG file, then _set_overlay_service_policy is considered as a pri...
[ "def", "_set_overlay_service_policy", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass", "(", "v", ...
Setter method for overlay_service_policy, mapped from YANG variable /overlay_gateway/overlay_service_policy (container) If this variable is read-only (config: false) in the source YANG file, then _set_overlay_service_policy is considered as a private method. Backends looking to populate this variable should...
[ "Setter", "method", "for", "overlay_service_policy", "mapped", "from", "YANG", "variable", "/", "overlay_gateway", "/", "overlay_service_policy", "(", "container", ")", "If", "this", "variable", "is", "read", "-", "only", "(", "config", ":", "false", ")", "in", ...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/slxos/v17s_1_02/overlay_gateway/__init__.py#L248-L269
train
Sets the overlay service policy for the
StackStorm/pybind
pybind/slxos/v17s_1_02/ipv6/ipv6_global_cmds/__init__.py
ipv6_global_cmds._set_nd_global
def _set_nd_global(self, v, load=False): """ Setter method for nd_global, mapped from YANG variable /ipv6/ipv6_global_cmds/nd_global (container) If this variable is read-only (config: false) in the source YANG file, then _set_nd_global is considered as a private method. Backends looking to populate ...
python
def _set_nd_global(self, v, load=False): """ Setter method for nd_global, mapped from YANG variable /ipv6/ipv6_global_cmds/nd_global (container) If this variable is read-only (config: false) in the source YANG file, then _set_nd_global is considered as a private method. Backends looking to populate ...
[ "def", "_set_nd_global", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass", "(", "v", ",", "base...
Setter method for nd_global, mapped from YANG variable /ipv6/ipv6_global_cmds/nd_global (container) If this variable is read-only (config: false) in the source YANG file, then _set_nd_global is considered as a private method. Backends looking to populate this variable should do so via calling thisObj._s...
[ "Setter", "method", "for", "nd_global", "mapped", "from", "YANG", "variable", "/", "ipv6", "/", "ipv6_global_cmds", "/", "nd_global", "(", "container", ")", "If", "this", "variable", "is", "read", "-", "only", "(", "config", ":", "false", ")", "in", "the",...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/slxos/v17s_1_02/ipv6/ipv6_global_cmds/__init__.py#L92-L113
train
This method is used to set the ND global of the network.
StackStorm/pybind
pybind/slxos/v17s_1_02/protocol/spanning_tree/rpvst/__init__.py
rpvst._set_error_disable_timeout
def _set_error_disable_timeout(self, v, load=False): """ Setter method for error_disable_timeout, mapped from YANG variable /protocol/spanning_tree/rpvst/error_disable_timeout (container) If this variable is read-only (config: false) in the source YANG file, then _set_error_disable_timeout is considered...
python
def _set_error_disable_timeout(self, v, load=False): """ Setter method for error_disable_timeout, mapped from YANG variable /protocol/spanning_tree/rpvst/error_disable_timeout (container) If this variable is read-only (config: false) in the source YANG file, then _set_error_disable_timeout is considered...
[ "def", "_set_error_disable_timeout", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass", "(", "v", ...
Setter method for error_disable_timeout, mapped from YANG variable /protocol/spanning_tree/rpvst/error_disable_timeout (container) If this variable is read-only (config: false) in the source YANG file, then _set_error_disable_timeout is considered as a private method. Backends looking to populate this varia...
[ "Setter", "method", "for", "error_disable_timeout", "mapped", "from", "YANG", "variable", "/", "protocol", "/", "spanning_tree", "/", "rpvst", "/", "error_disable_timeout", "(", "container", ")", "If", "this", "variable", "is", "read", "-", "only", "(", "config"...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/slxos/v17s_1_02/protocol/spanning_tree/rpvst/__init__.py#L251-L272
train
Sets the error timeout for the
StackStorm/pybind
pybind/slxos/v17s_1_02/protocol/spanning_tree/rpvst/__init__.py
rpvst._set_port_channel
def _set_port_channel(self, v, load=False): """ Setter method for port_channel, mapped from YANG variable /protocol/spanning_tree/rpvst/port_channel (container) If this variable is read-only (config: false) in the source YANG file, then _set_port_channel is considered as a private method. Backends l...
python
def _set_port_channel(self, v, load=False): """ Setter method for port_channel, mapped from YANG variable /protocol/spanning_tree/rpvst/port_channel (container) If this variable is read-only (config: false) in the source YANG file, then _set_port_channel is considered as a private method. Backends l...
[ "def", "_set_port_channel", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass", "(", "v", ",", "b...
Setter method for port_channel, mapped from YANG variable /protocol/spanning_tree/rpvst/port_channel (container) If this variable is read-only (config: false) in the source YANG file, then _set_port_channel is considered as a private method. Backends looking to populate this variable should do so via ca...
[ "Setter", "method", "for", "port_channel", "mapped", "from", "YANG", "variable", "/", "protocol", "/", "spanning_tree", "/", "rpvst", "/", "port_channel", "(", "container", ")", "If", "this", "variable", "is", "read", "-", "only", "(", "config", ":", "false"...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/slxos/v17s_1_02/protocol/spanning_tree/rpvst/__init__.py#L284-L305
train
Sets the port_channel property.
rmohr/static3
static.py
iter_and_close
def iter_and_close(file_like, block_size): """Yield file contents by block then close the file.""" while 1: try: block = file_like.read(block_size) if block: yield block else: raise StopIteration except StopIteration: ...
python
def iter_and_close(file_like, block_size): """Yield file contents by block then close the file.""" while 1: try: block = file_like.read(block_size) if block: yield block else: raise StopIteration except StopIteration: ...
[ "def", "iter_and_close", "(", "file_like", ",", "block_size", ")", ":", "while", "1", ":", "try", ":", "block", "=", "file_like", ".", "read", "(", "block_size", ")", "if", "block", ":", "yield", "block", "else", ":", "raise", "StopIteration", "except", ...
Yield file contents by block then close the file.
[ "Yield", "file", "contents", "by", "block", "then", "close", "the", "file", "." ]
e5f88c5e91789bd4db7fde0cf59e4a15c3326f11
https://github.com/rmohr/static3/blob/e5f88c5e91789bd4db7fde0cf59e4a15c3326f11/static.py#L239-L250
train
Yields file contents by block then close the file.
rmohr/static3
static.py
cling_wrap
def cling_wrap(package_name, dir_name, **kw): """Return a Cling that serves from the given package and dir_name. This uses pkg_resources.resource_filename which is not the recommended way, since it extracts the files. I think this works fine unless you have some _very_ serious requirements for sta...
python
def cling_wrap(package_name, dir_name, **kw): """Return a Cling that serves from the given package and dir_name. This uses pkg_resources.resource_filename which is not the recommended way, since it extracts the files. I think this works fine unless you have some _very_ serious requirements for sta...
[ "def", "cling_wrap", "(", "package_name", ",", "dir_name", ",", "*", "*", "kw", ")", ":", "resource", "=", "Requirement", ".", "parse", "(", "package_name", ")", "return", "Cling", "(", "resource_filename", "(", "resource", ",", "dir_name", ")", ",", "*", ...
Return a Cling that serves from the given package and dir_name. This uses pkg_resources.resource_filename which is not the recommended way, since it extracts the files. I think this works fine unless you have some _very_ serious requirements for static content, in which case you probably shouldn't...
[ "Return", "a", "Cling", "that", "serves", "from", "the", "given", "package", "and", "dir_name", "." ]
e5f88c5e91789bd4db7fde0cf59e4a15c3326f11
https://github.com/rmohr/static3/blob/e5f88c5e91789bd4db7fde0cf59e4a15c3326f11/static.py#L253-L264
train
Return a Cling that serves from the given package and dir_name.
rmohr/static3
static.py
Cling._is_under_root
def _is_under_root(self, full_path): """Guard against arbitrary file retrieval.""" if (path.abspath(full_path) + path.sep)\ .startswith(path.abspath(self.root) + path.sep): return True else: return False
python
def _is_under_root(self, full_path): """Guard against arbitrary file retrieval.""" if (path.abspath(full_path) + path.sep)\ .startswith(path.abspath(self.root) + path.sep): return True else: return False
[ "def", "_is_under_root", "(", "self", ",", "full_path", ")", ":", "if", "(", "path", ".", "abspath", "(", "full_path", ")", "+", "path", ".", "sep", ")", ".", "startswith", "(", "path", ".", "abspath", "(", "self", ".", "root", ")", "+", "path", "....
Guard against arbitrary file retrieval.
[ "Guard", "against", "arbitrary", "file", "retrieval", "." ]
e5f88c5e91789bd4db7fde0cf59e4a15c3326f11
https://github.com/rmohr/static3/blob/e5f88c5e91789bd4db7fde0cf59e4a15c3326f11/static.py#L200-L206
train
Guard against arbitrary file retrieval.
rmohr/static3
static.py
Cling._conditions
def _conditions(self, full_path, environ): """Return a tuple of etag, last_modified by mtime from stat.""" mtime = stat(full_path).st_mtime return str(mtime), rfc822.formatdate(mtime)
python
def _conditions(self, full_path, environ): """Return a tuple of etag, last_modified by mtime from stat.""" mtime = stat(full_path).st_mtime return str(mtime), rfc822.formatdate(mtime)
[ "def", "_conditions", "(", "self", ",", "full_path", ",", "environ", ")", ":", "mtime", "=", "stat", "(", "full_path", ")", ".", "st_mtime", "return", "str", "(", "mtime", ")", ",", "rfc822", ".", "formatdate", "(", "mtime", ")" ]
Return a tuple of etag, last_modified by mtime from stat.
[ "Return", "a", "tuple", "of", "etag", "last_modified", "by", "mtime", "from", "stat", "." ]
e5f88c5e91789bd4db7fde0cf59e4a15c3326f11
https://github.com/rmohr/static3/blob/e5f88c5e91789bd4db7fde0cf59e4a15c3326f11/static.py#L212-L215
train
Return a tuple of etag last_modified by mtime from stat.
rmohr/static3
static.py
Cling._body
def _body(self, full_path, environ, file_like): """Return an iterator over the body of the response.""" way_to_send = environ.get('wsgi.file_wrapper', iter_and_close) return way_to_send(file_like, self.block_size)
python
def _body(self, full_path, environ, file_like): """Return an iterator over the body of the response.""" way_to_send = environ.get('wsgi.file_wrapper', iter_and_close) return way_to_send(file_like, self.block_size)
[ "def", "_body", "(", "self", ",", "full_path", ",", "environ", ",", "file_like", ")", ":", "way_to_send", "=", "environ", ".", "get", "(", "'wsgi.file_wrapper'", ",", "iter_and_close", ")", "return", "way_to_send", "(", "file_like", ",", "self", ".", "block_...
Return an iterator over the body of the response.
[ "Return", "an", "iterator", "over", "the", "body", "of", "the", "response", "." ]
e5f88c5e91789bd4db7fde0cf59e4a15c3326f11
https://github.com/rmohr/static3/blob/e5f88c5e91789bd4db7fde0cf59e4a15c3326f11/static.py#L233-L236
train
Return an iterator over the body of the response.
rmohr/static3
static.py
Shock._match_magic
def _match_magic(self, full_path): """Return the first magic that matches this path or None.""" for magic in self.magics: if magic.matches(full_path): return magic
python
def _match_magic(self, full_path): """Return the first magic that matches this path or None.""" for magic in self.magics: if magic.matches(full_path): return magic
[ "def", "_match_magic", "(", "self", ",", "full_path", ")", ":", "for", "magic", "in", "self", ".", "magics", ":", "if", "magic", ".", "matches", "(", "full_path", ")", ":", "return", "magic" ]
Return the first magic that matches this path or None.
[ "Return", "the", "first", "magic", "that", "matches", "this", "path", "or", "None", "." ]
e5f88c5e91789bd4db7fde0cf59e4a15c3326f11
https://github.com/rmohr/static3/blob/e5f88c5e91789bd4db7fde0cf59e4a15c3326f11/static.py#L296-L300
train
Return the first magic that matches this path.
rmohr/static3
static.py
Shock._full_path
def _full_path(self, path_info): """Return the full path from which to read.""" full_path = self.root + path_info if path.exists(full_path): return full_path else: for magic in self.magics: if path.exists(magic.new_path(full_path)): ...
python
def _full_path(self, path_info): """Return the full path from which to read.""" full_path = self.root + path_info if path.exists(full_path): return full_path else: for magic in self.magics: if path.exists(magic.new_path(full_path)): ...
[ "def", "_full_path", "(", "self", ",", "path_info", ")", ":", "full_path", "=", "self", ".", "root", "+", "path_info", "if", "path", ".", "exists", "(", "full_path", ")", ":", "return", "full_path", "else", ":", "for", "magic", "in", "self", ".", "magi...
Return the full path from which to read.
[ "Return", "the", "full", "path", "from", "which", "to", "read", "." ]
e5f88c5e91789bd4db7fde0cf59e4a15c3326f11
https://github.com/rmohr/static3/blob/e5f88c5e91789bd4db7fde0cf59e4a15c3326f11/static.py#L302-L312
train
Return the full path from which to read.
rmohr/static3
static.py
Shock._guess_type
def _guess_type(self, full_path): """Guess the mime type magically or using the mimetypes module.""" magic = self._match_magic(full_path) if magic is not None: return (mimetypes.guess_type(magic.old_path(full_path))[0] or 'text/plain') else: re...
python
def _guess_type(self, full_path): """Guess the mime type magically or using the mimetypes module.""" magic = self._match_magic(full_path) if magic is not None: return (mimetypes.guess_type(magic.old_path(full_path))[0] or 'text/plain') else: re...
[ "def", "_guess_type", "(", "self", ",", "full_path", ")", ":", "magic", "=", "self", ".", "_match_magic", "(", "full_path", ")", "if", "magic", "is", "not", "None", ":", "return", "(", "mimetypes", ".", "guess_type", "(", "magic", ".", "old_path", "(", ...
Guess the mime type magically or using the mimetypes module.
[ "Guess", "the", "mime", "type", "magically", "or", "using", "the", "mimetypes", "module", "." ]
e5f88c5e91789bd4db7fde0cf59e4a15c3326f11
https://github.com/rmohr/static3/blob/e5f88c5e91789bd4db7fde0cf59e4a15c3326f11/static.py#L314-L321
train
Guess the mime type magically or using the mimetypes module.
rmohr/static3
static.py
Shock._conditions
def _conditions(self, full_path, environ): """Return Etag and Last-Modified values defaults to now for both.""" magic = self._match_magic(full_path) if magic is not None: return magic.conditions(full_path, environ) else: mtime = stat(full_path).st_mtime ...
python
def _conditions(self, full_path, environ): """Return Etag and Last-Modified values defaults to now for both.""" magic = self._match_magic(full_path) if magic is not None: return magic.conditions(full_path, environ) else: mtime = stat(full_path).st_mtime ...
[ "def", "_conditions", "(", "self", ",", "full_path", ",", "environ", ")", ":", "magic", "=", "self", ".", "_match_magic", "(", "full_path", ")", "if", "magic", "is", "not", "None", ":", "return", "magic", ".", "conditions", "(", "full_path", ",", "enviro...
Return Etag and Last-Modified values defaults to now for both.
[ "Return", "Etag", "and", "Last", "-", "Modified", "values", "defaults", "to", "now", "for", "both", "." ]
e5f88c5e91789bd4db7fde0cf59e4a15c3326f11
https://github.com/rmohr/static3/blob/e5f88c5e91789bd4db7fde0cf59e4a15c3326f11/static.py#L323-L330
train
Return Etag and Last - Modified values defaults to now for both.
rmohr/static3
static.py
Shock._file_like
def _file_like(self, full_path): """Return the appropriate file object.""" magic = self._match_magic(full_path) if magic is not None: return magic.file_like(full_path, self.encoding) else: return open(full_path, 'rb')
python
def _file_like(self, full_path): """Return the appropriate file object.""" magic = self._match_magic(full_path) if magic is not None: return magic.file_like(full_path, self.encoding) else: return open(full_path, 'rb')
[ "def", "_file_like", "(", "self", ",", "full_path", ")", ":", "magic", "=", "self", ".", "_match_magic", "(", "full_path", ")", "if", "magic", "is", "not", "None", ":", "return", "magic", ".", "file_like", "(", "full_path", ",", "self", ".", "encoding", ...
Return the appropriate file object.
[ "Return", "the", "appropriate", "file", "object", "." ]
e5f88c5e91789bd4db7fde0cf59e4a15c3326f11
https://github.com/rmohr/static3/blob/e5f88c5e91789bd4db7fde0cf59e4a15c3326f11/static.py#L332-L338
train
Return the appropriate file object.
rmohr/static3
static.py
Shock._body
def _body(self, full_path, environ, file_like): """Return an iterator over the body of the response.""" magic = self._match_magic(full_path) if magic is not None: return [_encode(s, self.encoding) for s in magic.body(environ, ...
python
def _body(self, full_path, environ, file_like): """Return an iterator over the body of the response.""" magic = self._match_magic(full_path) if magic is not None: return [_encode(s, self.encoding) for s in magic.body(environ, ...
[ "def", "_body", "(", "self", ",", "full_path", ",", "environ", ",", "file_like", ")", ":", "magic", "=", "self", ".", "_match_magic", "(", "full_path", ")", "if", "magic", "is", "not", "None", ":", "return", "[", "_encode", "(", "s", ",", "self", "."...
Return an iterator over the body of the response.
[ "Return", "an", "iterator", "over", "the", "body", "of", "the", "response", "." ]
e5f88c5e91789bd4db7fde0cf59e4a15c3326f11
https://github.com/rmohr/static3/blob/e5f88c5e91789bd4db7fde0cf59e4a15c3326f11/static.py#L340-L348
train
Return an iterator over the body of the response.
rmohr/static3
static.py
BaseMagic.exists
def exists(self, full_path): """Check that self.new_path(full_path) exists.""" if path.exists(self.new_path(full_path)): return self.new_path(full_path)
python
def exists(self, full_path): """Check that self.new_path(full_path) exists.""" if path.exists(self.new_path(full_path)): return self.new_path(full_path)
[ "def", "exists", "(", "self", ",", "full_path", ")", ":", "if", "path", ".", "exists", "(", "self", ".", "new_path", "(", "full_path", ")", ")", ":", "return", "self", ".", "new_path", "(", "full_path", ")" ]
Check that self.new_path(full_path) exists.
[ "Check", "that", "self", ".", "new_path", "(", "full_path", ")", "exists", "." ]
e5f88c5e91789bd4db7fde0cf59e4a15c3326f11
https://github.com/rmohr/static3/blob/e5f88c5e91789bd4db7fde0cf59e4a15c3326f11/static.py#L365-L368
train
Check that the new_path exists.
rmohr/static3
static.py
BaseMagic.old_path
def old_path(self, full_path): """Remove self.extension from path or raise MagicError.""" if self.matches(full_path): return full_path[:-len(self.extension)] else: raise MagicError("Path does not match this magic.")
python
def old_path(self, full_path): """Remove self.extension from path or raise MagicError.""" if self.matches(full_path): return full_path[:-len(self.extension)] else: raise MagicError("Path does not match this magic.")
[ "def", "old_path", "(", "self", ",", "full_path", ")", ":", "if", "self", ".", "matches", "(", "full_path", ")", ":", "return", "full_path", "[", ":", "-", "len", "(", "self", ".", "extension", ")", "]", "else", ":", "raise", "MagicError", "(", "\"Pa...
Remove self.extension from path or raise MagicError.
[ "Remove", "self", ".", "extension", "from", "path", "or", "raise", "MagicError", "." ]
e5f88c5e91789bd4db7fde0cf59e4a15c3326f11
https://github.com/rmohr/static3/blob/e5f88c5e91789bd4db7fde0cf59e4a15c3326f11/static.py#L374-L379
train
Remove self. extension from path or raise MagicError.
rmohr/static3
static.py
BaseMagic.conditions
def conditions(self, full_path, environ): """Return Etag and Last-Modified values (based on mtime).""" mtime = int(time.time()) return str(mtime), rfc822.formatdate(mtime)
python
def conditions(self, full_path, environ): """Return Etag and Last-Modified values (based on mtime).""" mtime = int(time.time()) return str(mtime), rfc822.formatdate(mtime)
[ "def", "conditions", "(", "self", ",", "full_path", ",", "environ", ")", ":", "mtime", "=", "int", "(", "time", ".", "time", "(", ")", ")", "return", "str", "(", "mtime", ")", ",", "rfc822", ".", "formatdate", "(", "mtime", ")" ]
Return Etag and Last-Modified values (based on mtime).
[ "Return", "Etag", "and", "Last", "-", "Modified", "values", "(", "based", "on", "mtime", ")", "." ]
e5f88c5e91789bd4db7fde0cf59e4a15c3326f11
https://github.com/rmohr/static3/blob/e5f88c5e91789bd4db7fde0cf59e4a15c3326f11/static.py#L386-L389
train
Return Etag and Last - Modified values based on mtime.
rmohr/static3
static.py
StringMagic.body
def body(self, environ, file_like): """Pass environ and self.variables in to template. self.variables overrides environ so that suprises in environ don't cause unexpected output if you are passing a value in explicitly. """ variables = environ.copy() variables.update(sel...
python
def body(self, environ, file_like): """Pass environ and self.variables in to template. self.variables overrides environ so that suprises in environ don't cause unexpected output if you are passing a value in explicitly. """ variables = environ.copy() variables.update(sel...
[ "def", "body", "(", "self", ",", "environ", ",", "file_like", ")", ":", "variables", "=", "environ", ".", "copy", "(", ")", "variables", ".", "update", "(", "self", ".", "variables", ")", "template", "=", "string", ".", "Template", "(", "file_like", "....
Pass environ and self.variables in to template. self.variables overrides environ so that suprises in environ don't cause unexpected output if you are passing a value in explicitly.
[ "Pass", "environ", "and", "self", ".", "variables", "in", "to", "template", "." ]
e5f88c5e91789bd4db7fde0cf59e4a15c3326f11
https://github.com/rmohr/static3/blob/e5f88c5e91789bd4db7fde0cf59e4a15c3326f11/static.py#L414-L426
train
Return the body of the resource.
rmohr/static3
static.py
KidMagic.body
def body(self, environ, full_path): """Pass environ and **self.variables into the template.""" template = kid.Template(file=full_path, environ=environ, **self.variables) return [template.serialize()]
python
def body(self, environ, full_path): """Pass environ and **self.variables into the template.""" template = kid.Template(file=full_path, environ=environ, **self.variables) return [template.serialize()]
[ "def", "body", "(", "self", ",", "environ", ",", "full_path", ")", ":", "template", "=", "kid", ".", "Template", "(", "file", "=", "full_path", ",", "environ", "=", "environ", ",", "*", "*", "self", ".", "variables", ")", "return", "[", "template", "...
Pass environ and **self.variables into the template.
[ "Pass", "environ", "and", "**", "self", ".", "variables", "into", "the", "template", "." ]
e5f88c5e91789bd4db7fde0cf59e4a15c3326f11
https://github.com/rmohr/static3/blob/e5f88c5e91789bd4db7fde0cf59e4a15c3326f11/static.py#L438-L443
train
Pass environ and self. variables into the template.
rmohr/static3
static.py
GenshiMagic.body
def body(self, environ, full_path): """Pass environ and **self.variables into the template.""" template = MarkupTemplate(full_path.read()) variables = self.variables.copy() variables["environ"] = environ return [template.generate(**variables) .render('html', doct...
python
def body(self, environ, full_path): """Pass environ and **self.variables into the template.""" template = MarkupTemplate(full_path.read()) variables = self.variables.copy() variables["environ"] = environ return [template.generate(**variables) .render('html', doct...
[ "def", "body", "(", "self", ",", "environ", ",", "full_path", ")", ":", "template", "=", "MarkupTemplate", "(", "full_path", ".", "read", "(", ")", ")", "variables", "=", "self", ".", "variables", ".", "copy", "(", ")", "variables", "[", "\"environ\"", ...
Pass environ and **self.variables into the template.
[ "Pass", "environ", "and", "**", "self", ".", "variables", "into", "the", "template", "." ]
e5f88c5e91789bd4db7fde0cf59e4a15c3326f11
https://github.com/rmohr/static3/blob/e5f88c5e91789bd4db7fde0cf59e4a15c3326f11/static.py#L455-L462
train
Pass environ and self. variables into the template.
StackStorm/pybind
pybind/slxos/v17r_2_00/vrf/address_family/ipv6/unicast/route_target_container_ipv6/__init__.py
route_target_container_ipv6._set_route_target_evpn
def _set_route_target_evpn(self, v, load=False): """ Setter method for route_target_evpn, mapped from YANG variable /vrf/address_family/ipv6/unicast/route_target_container_ipv6/route_target_evpn (list) If this variable is read-only (config: false) in the source YANG file, then _set_route_target_evpn is ...
python
def _set_route_target_evpn(self, v, load=False): """ Setter method for route_target_evpn, mapped from YANG variable /vrf/address_family/ipv6/unicast/route_target_container_ipv6/route_target_evpn (list) If this variable is read-only (config: false) in the source YANG file, then _set_route_target_evpn is ...
[ "def", "_set_route_target_evpn", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass", "(", "v", ",",...
Setter method for route_target_evpn, mapped from YANG variable /vrf/address_family/ipv6/unicast/route_target_container_ipv6/route_target_evpn (list) If this variable is read-only (config: false) in the source YANG file, then _set_route_target_evpn is considered as a private method. Backends looking to popul...
[ "Setter", "method", "for", "route_target_evpn", "mapped", "from", "YANG", "variable", "/", "vrf", "/", "address_family", "/", "ipv6", "/", "unicast", "/", "route_target_container_ipv6", "/", "route_target_evpn", "(", "list", ")", "If", "this", "variable", "is", ...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/slxos/v17r_2_00/vrf/address_family/ipv6/unicast/route_target_container_ipv6/__init__.py#L92-L113
train
Set the route target EVIDENCE for the BGP vrf.
budacom/trading-bots
trading_bots/contrib/converters/base.py
Converter.get_rate_for
def get_rate_for(self, currency: str, to: str, reverse: bool=False) -> Number: """Get current market rate for currency""" # Return 1 when currencies match if currency.upper() == to.upper(): return self._format_number('1.0') # Set base and quote currencies base, quot...
python
def get_rate_for(self, currency: str, to: str, reverse: bool=False) -> Number: """Get current market rate for currency""" # Return 1 when currencies match if currency.upper() == to.upper(): return self._format_number('1.0') # Set base and quote currencies base, quot...
[ "def", "get_rate_for", "(", "self", ",", "currency", ":", "str", ",", "to", ":", "str", ",", "reverse", ":", "bool", "=", "False", ")", "->", "Number", ":", "# Return 1 when currencies match", "if", "currency", ".", "upper", "(", ")", "==", "to", ".", ...
Get current market rate for currency
[ "Get", "current", "market", "rate", "for", "currency" ]
8cb68bb8d0b5f822108db1cc5dae336e3d3c3452
https://github.com/budacom/trading-bots/blob/8cb68bb8d0b5f822108db1cc5dae336e3d3c3452/trading_bots/contrib/converters/base.py#L45-L74
train
Get current market rate for currency and to
budacom/trading-bots
trading_bots/contrib/converters/base.py
Converter.convert
def convert(self, amount: Number, currency: str, to: str, reverse: bool=False) -> Number: """Convert amount to another currency""" rate = self.get_rate_for(currency, to, reverse) if self.return_decimal: amount = Decimal(amount) return amount * rate
python
def convert(self, amount: Number, currency: str, to: str, reverse: bool=False) -> Number: """Convert amount to another currency""" rate = self.get_rate_for(currency, to, reverse) if self.return_decimal: amount = Decimal(amount) return amount * rate
[ "def", "convert", "(", "self", ",", "amount", ":", "Number", ",", "currency", ":", "str", ",", "to", ":", "str", ",", "reverse", ":", "bool", "=", "False", ")", "->", "Number", ":", "rate", "=", "self", ".", "get_rate_for", "(", "currency", ",", "t...
Convert amount to another currency
[ "Convert", "amount", "to", "another", "currency" ]
8cb68bb8d0b5f822108db1cc5dae336e3d3c3452
https://github.com/budacom/trading-bots/blob/8cb68bb8d0b5f822108db1cc5dae336e3d3c3452/trading_bots/contrib/converters/base.py#L76-L81
train
Convert amount to another currency
budacom/trading-bots
trading_bots/contrib/converters/base.py
Converter.convert_money
def convert_money(self, money: Money, to: str, reverse: bool=False) -> Money: """Convert money to another currency""" converted = self.convert(money.amount, money.currency, to, reverse) return Money(converted, to)
python
def convert_money(self, money: Money, to: str, reverse: bool=False) -> Money: """Convert money to another currency""" converted = self.convert(money.amount, money.currency, to, reverse) return Money(converted, to)
[ "def", "convert_money", "(", "self", ",", "money", ":", "Money", ",", "to", ":", "str", ",", "reverse", ":", "bool", "=", "False", ")", "->", "Money", ":", "converted", "=", "self", ".", "convert", "(", "money", ".", "amount", ",", "money", ".", "c...
Convert money to another currency
[ "Convert", "money", "to", "another", "currency" ]
8cb68bb8d0b5f822108db1cc5dae336e3d3c3452
https://github.com/budacom/trading-bots/blob/8cb68bb8d0b5f822108db1cc5dae336e3d3c3452/trading_bots/contrib/converters/base.py#L83-L86
train
Convert money to another currency
StackStorm/pybind
pybind/nos/v6_0_2f/rbridge_id/router/router_bgp/address_family/ipv6/ipv6_unicast/af_ipv6_vrf/__init__.py
af_ipv6_vrf._set_aggregate_ipv6_address
def _set_aggregate_ipv6_address(self, v, load=False): """ Setter method for aggregate_ipv6_address, mapped from YANG variable /rbridge_id/router/router_bgp/address_family/ipv6/ipv6_unicast/af_ipv6_vrf/aggregate_ipv6_address (list) If this variable is read-only (config: false) in the source YANG file, th...
python
def _set_aggregate_ipv6_address(self, v, load=False): """ Setter method for aggregate_ipv6_address, mapped from YANG variable /rbridge_id/router/router_bgp/address_family/ipv6/ipv6_unicast/af_ipv6_vrf/aggregate_ipv6_address (list) If this variable is read-only (config: false) in the source YANG file, th...
[ "def", "_set_aggregate_ipv6_address", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass", "(", "v", ...
Setter method for aggregate_ipv6_address, mapped from YANG variable /rbridge_id/router/router_bgp/address_family/ipv6/ipv6_unicast/af_ipv6_vrf/aggregate_ipv6_address (list) If this variable is read-only (config: false) in the source YANG file, then _set_aggregate_ipv6_address is considered as a private meth...
[ "Setter", "method", "for", "aggregate_ipv6_address", "mapped", "from", "YANG", "variable", "/", "rbridge_id", "/", "router", "/", "router_bgp", "/", "address_family", "/", "ipv6", "/", "ipv6_unicast", "/", "af_ipv6_vrf", "/", "aggregate_ipv6_address", "(", "list", ...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/nos/v6_0_2f/rbridge_id/router/router_bgp/address_family/ipv6/ipv6_unicast/af_ipv6_vrf/__init__.py#L253-L274
train
Sets the value of aggregate_ipv6_address mapped from YANG variable to a private .
StackStorm/pybind
pybind/slxos/v17s_1_02/routing_system/interface/loopback/ip/__init__.py
ip._set_intf_router_isis
def _set_intf_router_isis(self, v, load=False): """ Setter method for intf_router_isis, mapped from YANG variable /routing_system/interface/loopback/ip/intf_router_isis (container) If this variable is read-only (config: false) in the source YANG file, then _set_intf_router_isis is considered as a privat...
python
def _set_intf_router_isis(self, v, load=False): """ Setter method for intf_router_isis, mapped from YANG variable /routing_system/interface/loopback/ip/intf_router_isis (container) If this variable is read-only (config: false) in the source YANG file, then _set_intf_router_isis is considered as a privat...
[ "def", "_set_intf_router_isis", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass", "(", "v", ",", ...
Setter method for intf_router_isis, mapped from YANG variable /routing_system/interface/loopback/ip/intf_router_isis (container) If this variable is read-only (config: false) in the source YANG file, then _set_intf_router_isis is considered as a private method. Backends looking to populate this variable sho...
[ "Setter", "method", "for", "intf_router_isis", "mapped", "from", "YANG", "variable", "/", "routing_system", "/", "interface", "/", "loopback", "/", "ip", "/", "intf_router_isis", "(", "container", ")", "If", "this", "variable", "is", "read", "-", "only", "(", ...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/slxos/v17s_1_02/routing_system/interface/loopback/ip/__init__.py#L131-L152
train
Set the interface router isis based on isis container
StackStorm/pybind
pybind/slxos/v17s_1_02/routing_system/interface/loopback/ip/__init__.py
ip._set_interface_loopback_ospf_conf
def _set_interface_loopback_ospf_conf(self, v, load=False): """ Setter method for interface_loopback_ospf_conf, mapped from YANG variable /routing_system/interface/loopback/ip/interface_loopback_ospf_conf (container) If this variable is read-only (config: false) in the source YANG file, then _set_interf...
python
def _set_interface_loopback_ospf_conf(self, v, load=False): """ Setter method for interface_loopback_ospf_conf, mapped from YANG variable /routing_system/interface/loopback/ip/interface_loopback_ospf_conf (container) If this variable is read-only (config: false) in the source YANG file, then _set_interf...
[ "def", "_set_interface_loopback_ospf_conf", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass", "(", ...
Setter method for interface_loopback_ospf_conf, mapped from YANG variable /routing_system/interface/loopback/ip/interface_loopback_ospf_conf (container) If this variable is read-only (config: false) in the source YANG file, then _set_interface_loopback_ospf_conf is considered as a private method. Backends l...
[ "Setter", "method", "for", "interface_loopback_ospf_conf", "mapped", "from", "YANG", "variable", "/", "routing_system", "/", "interface", "/", "loopback", "/", "ip", "/", "interface_loopback_ospf_conf", "(", "container", ")", "If", "this", "variable", "is", "read", ...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/slxos/v17s_1_02/routing_system/interface/loopback/ip/__init__.py#L164-L185
train
Sets the value of interface_loopback_ospf_conf in the base tree.
StackStorm/pybind
pybind/slxos/v17s_1_02/routing_system/interface/loopback/ip/__init__.py
ip._set_pim_intf_loopback_cont
def _set_pim_intf_loopback_cont(self, v, load=False): """ Setter method for pim_intf_loopback_cont, mapped from YANG variable /routing_system/interface/loopback/ip/pim_intf_loopback_cont (container) If this variable is read-only (config: false) in the source YANG file, then _set_pim_intf_loopback_cont i...
python
def _set_pim_intf_loopback_cont(self, v, load=False): """ Setter method for pim_intf_loopback_cont, mapped from YANG variable /routing_system/interface/loopback/ip/pim_intf_loopback_cont (container) If this variable is read-only (config: false) in the source YANG file, then _set_pim_intf_loopback_cont i...
[ "def", "_set_pim_intf_loopback_cont", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass", "(", "v", ...
Setter method for pim_intf_loopback_cont, mapped from YANG variable /routing_system/interface/loopback/ip/pim_intf_loopback_cont (container) If this variable is read-only (config: false) in the source YANG file, then _set_pim_intf_loopback_cont is considered as a private method. Backends looking to populate...
[ "Setter", "method", "for", "pim_intf_loopback_cont", "mapped", "from", "YANG", "variable", "/", "routing_system", "/", "interface", "/", "loopback", "/", "ip", "/", "pim_intf_loopback_cont", "(", "container", ")", "If", "this", "variable", "is", "read", "-", "on...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/slxos/v17s_1_02/routing_system/interface/loopback/ip/__init__.py#L197-L218
train
Sets the value of the pim - intf - loopback - cont variable.
StackStorm/pybind
pybind/nos/v6_0_2f/rbridge_id/crypto/__init__.py
crypto._set_key
def _set_key(self, v, load=False): """ Setter method for key, mapped from YANG variable /rbridge_id/crypto/key (list) If this variable is read-only (config: false) in the source YANG file, then _set_key is considered as a private method. Backends looking to populate this variable should do so vi...
python
def _set_key(self, v, load=False): """ Setter method for key, mapped from YANG variable /rbridge_id/crypto/key (list) If this variable is read-only (config: false) in the source YANG file, then _set_key is considered as a private method. Backends looking to populate this variable should do so vi...
[ "def", "_set_key", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass", "(", "v", ",", "base", "...
Setter method for key, mapped from YANG variable /rbridge_id/crypto/key (list) If this variable is read-only (config: false) in the source YANG file, then _set_key is considered as a private method. Backends looking to populate this variable should do so via calling thisObj._set_key() directly.
[ "Setter", "method", "for", "key", "mapped", "from", "YANG", "variable", "/", "rbridge_id", "/", "crypto", "/", "key", "(", "list", ")", "If", "this", "variable", "is", "read", "-", "only", "(", "config", ":", "false", ")", "in", "the", "source", "YANG"...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/nos/v6_0_2f/rbridge_id/crypto/__init__.py#L94-L115
train
Set the key of the
StackStorm/pybind
pybind/nos/v6_0_2f/rbridge_id/crypto/__init__.py
crypto._set_ca
def _set_ca(self, v, load=False): """ Setter method for ca, mapped from YANG variable /rbridge_id/crypto/ca (list) If this variable is read-only (config: false) in the source YANG file, then _set_ca is considered as a private method. Backends looking to populate this variable should do so via ca...
python
def _set_ca(self, v, load=False): """ Setter method for ca, mapped from YANG variable /rbridge_id/crypto/ca (list) If this variable is read-only (config: false) in the source YANG file, then _set_ca is considered as a private method. Backends looking to populate this variable should do so via ca...
[ "def", "_set_ca", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass", "(", "v", ",", "base", "=...
Setter method for ca, mapped from YANG variable /rbridge_id/crypto/ca (list) If this variable is read-only (config: false) in the source YANG file, then _set_ca is considered as a private method. Backends looking to populate this variable should do so via calling thisObj._set_ca() directly.
[ "Setter", "method", "for", "ca", "mapped", "from", "YANG", "variable", "/", "rbridge_id", "/", "crypto", "/", "ca", "(", "list", ")", "If", "this", "variable", "is", "read", "-", "only", "(", "config", ":", "false", ")", "in", "the", "source", "YANG", ...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/nos/v6_0_2f/rbridge_id/crypto/__init__.py#L127-L148
train
Set the ca variable.
StackStorm/pybind
pybind/nos/v7_2_0/qos/ecn/red_profile/__init__.py
red_profile._set_red_profile_ecn
def _set_red_profile_ecn(self, v, load=False): """ Setter method for red_profile_ecn, mapped from YANG variable /qos/ecn/red_profile/red_profile_ecn (container) If this variable is read-only (config: false) in the source YANG file, then _set_red_profile_ecn is considered as a private method. Backend...
python
def _set_red_profile_ecn(self, v, load=False): """ Setter method for red_profile_ecn, mapped from YANG variable /qos/ecn/red_profile/red_profile_ecn (container) If this variable is read-only (config: false) in the source YANG file, then _set_red_profile_ecn is considered as a private method. Backend...
[ "def", "_set_red_profile_ecn", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass", "(", "v", ",", ...
Setter method for red_profile_ecn, mapped from YANG variable /qos/ecn/red_profile/red_profile_ecn (container) If this variable is read-only (config: false) in the source YANG file, then _set_red_profile_ecn is considered as a private method. Backends looking to populate this variable should do so via ca...
[ "Setter", "method", "for", "red_profile_ecn", "mapped", "from", "YANG", "variable", "/", "qos", "/", "ecn", "/", "red_profile", "/", "red_profile_ecn", "(", "container", ")", "If", "this", "variable", "is", "read", "-", "only", "(", "config", ":", "false", ...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/nos/v7_2_0/qos/ecn/red_profile/__init__.py#L92-L113
train
Sets the value of the RED_PROFILE_ECN variable in the tree.
jinglemansweep/lcdproc
lcdproc/screen.py
Screen.clear
def clear(self): """ Clear Screen """ w1 = StringWidget(self, ref="_w1_", text=" "*20, x=1, y=1) w2 = StringWidget(self, ref="_w2_", text=" "*20, x=1, y=2) w3 = StringWidget(self, ref="_w3_", text=" "*20, x=1, y=3) w4 = StringWidget(self, ref="_w4_", text=" "*20...
python
def clear(self): """ Clear Screen """ w1 = StringWidget(self, ref="_w1_", text=" "*20, x=1, y=1) w2 = StringWidget(self, ref="_w2_", text=" "*20, x=1, y=2) w3 = StringWidget(self, ref="_w3_", text=" "*20, x=1, y=3) w4 = StringWidget(self, ref="_w4_", text=" "*20...
[ "def", "clear", "(", "self", ")", ":", "w1", "=", "StringWidget", "(", "self", ",", "ref", "=", "\"_w1_\"", ",", "text", "=", "\" \"", "*", "20", ",", "x", "=", "1", ",", "y", "=", "1", ")", "w2", "=", "StringWidget", "(", "self", ",", "ref", ...
Clear Screen
[ "Clear", "Screen" ]
973628fc326177c9deaf3f2e1a435159eb565ae0
https://github.com/jinglemansweep/lcdproc/blob/973628fc326177c9deaf3f2e1a435159eb565ae0/lcdproc/screen.py#L129-L136
train
Clear the screen.
jinglemansweep/lcdproc
lcdproc/screen.py
Screen.add_icon_widget
def add_icon_widget(self, ref, x=1, y=1, name="heart"): """ Add Icon Widget """ if ref not in self.widgets: widget = IconWidget(screen=self, ref=ref, x=x, y=y, name=name) self.widgets[ref] = widget return self.widgets[ref]
python
def add_icon_widget(self, ref, x=1, y=1, name="heart"): """ Add Icon Widget """ if ref not in self.widgets: widget = IconWidget(screen=self, ref=ref, x=x, y=y, name=name) self.widgets[ref] = widget return self.widgets[ref]
[ "def", "add_icon_widget", "(", "self", ",", "ref", ",", "x", "=", "1", ",", "y", "=", "1", ",", "name", "=", "\"heart\"", ")", ":", "if", "ref", "not", "in", "self", ".", "widgets", ":", "widget", "=", "IconWidget", "(", "screen", "=", "self", ",...
Add Icon Widget
[ "Add", "Icon", "Widget" ]
973628fc326177c9deaf3f2e1a435159eb565ae0
https://github.com/jinglemansweep/lcdproc/blob/973628fc326177c9deaf3f2e1a435159eb565ae0/lcdproc/screen.py#L179-L186
train
Add Icon Widget
jinglemansweep/lcdproc
lcdproc/screen.py
Screen.add_scroller_widget
def add_scroller_widget(self, ref, left=1, top=1, right=20, bottom=1, direction="h", speed=1, text="Message"): """ Add Scroller Widget """ if ref not in self.widgets: widget = ScrollerWidget(screen=self, ref=ref, left=left, top=top, right=right, bottom=bottom, direc...
python
def add_scroller_widget(self, ref, left=1, top=1, right=20, bottom=1, direction="h", speed=1, text="Message"): """ Add Scroller Widget """ if ref not in self.widgets: widget = ScrollerWidget(screen=self, ref=ref, left=left, top=top, right=right, bottom=bottom, direc...
[ "def", "add_scroller_widget", "(", "self", ",", "ref", ",", "left", "=", "1", ",", "top", "=", "1", ",", "right", "=", "20", ",", "bottom", "=", "1", ",", "direction", "=", "\"h\"", ",", "speed", "=", "1", ",", "text", "=", "\"Message\"", ")", ":...
Add Scroller Widget
[ "Add", "Scroller", "Widget" ]
973628fc326177c9deaf3f2e1a435159eb565ae0
https://github.com/jinglemansweep/lcdproc/blob/973628fc326177c9deaf3f2e1a435159eb565ae0/lcdproc/screen.py#L189-L196
train
Add Scroller Widget
StackStorm/pybind
pybind/slxos/v17r_1_01a/mem_state/__init__.py
mem_state._set_mem_list
def _set_mem_list(self, v, load=False): """ Setter method for mem_list, mapped from YANG variable /mem_state/mem_list (container) If this variable is read-only (config: false) in the source YANG file, then _set_mem_list is considered as a private method. Backends looking to populate this variable sh...
python
def _set_mem_list(self, v, load=False): """ Setter method for mem_list, mapped from YANG variable /mem_state/mem_list (container) If this variable is read-only (config: false) in the source YANG file, then _set_mem_list is considered as a private method. Backends looking to populate this variable sh...
[ "def", "_set_mem_list", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass", "(", "v", ",", "base"...
Setter method for mem_list, mapped from YANG variable /mem_state/mem_list (container) If this variable is read-only (config: false) in the source YANG file, then _set_mem_list is considered as a private method. Backends looking to populate this variable should do so via calling thisObj._set_mem_list() d...
[ "Setter", "method", "for", "mem_list", "mapped", "from", "YANG", "variable", "/", "mem_state", "/", "mem_list", "(", "container", ")", "If", "this", "variable", "is", "read", "-", "only", "(", "config", ":", "false", ")", "in", "the", "source", "YANG", "...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/slxos/v17r_1_01a/mem_state/__init__.py#L135-L158
train
Sets the memory list of the current node.
StackStorm/pybind
pybind/nos/v7_2_0/rbridge_id/router/router_bgp/router_bgp_attributes/neighbor/peer_grps/neighbor_peer_grp/__init__.py
neighbor_peer_grp._set_alternate_as
def _set_alternate_as(self, v, load=False): """ Setter method for alternate_as, mapped from YANG variable /rbridge_id/router/router_bgp/router_bgp_attributes/neighbor/peer_grps/neighbor_peer_grp/alternate_as (container) If this variable is read-only (config: false) in the source YANG file, then _set_alt...
python
def _set_alternate_as(self, v, load=False): """ Setter method for alternate_as, mapped from YANG variable /rbridge_id/router/router_bgp/router_bgp_attributes/neighbor/peer_grps/neighbor_peer_grp/alternate_as (container) If this variable is read-only (config: false) in the source YANG file, then _set_alt...
[ "def", "_set_alternate_as", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass", "(", "v", ",", "b...
Setter method for alternate_as, mapped from YANG variable /rbridge_id/router/router_bgp/router_bgp_attributes/neighbor/peer_grps/neighbor_peer_grp/alternate_as (container) If this variable is read-only (config: false) in the source YANG file, then _set_alternate_as is considered as a private method. Backend...
[ "Setter", "method", "for", "alternate_as", "mapped", "from", "YANG", "variable", "/", "rbridge_id", "/", "router", "/", "router_bgp", "/", "router_bgp_attributes", "/", "neighbor", "/", "peer_grps", "/", "neighbor_peer_grp", "/", "alternate_as", "(", "container", ...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/nos/v7_2_0/rbridge_id/router/router_bgp/router_bgp_attributes/neighbor/peer_grps/neighbor_peer_grp/__init__.py#L232-L253
train
Sets the alternate_as property of the BGP node.
StackStorm/pybind
pybind/nos/v7_2_0/rbridge_id/router/router_bgp/router_bgp_attributes/neighbor/peer_grps/neighbor_peer_grp/__init__.py
neighbor_peer_grp._set_af_neighbor_capability
def _set_af_neighbor_capability(self, v, load=False): """ Setter method for af_neighbor_capability, mapped from YANG variable /rbridge_id/router/router_bgp/router_bgp_attributes/neighbor/peer_grps/neighbor_peer_grp/af_neighbor_capability (container) If this variable is read-only (config: false) in the s...
python
def _set_af_neighbor_capability(self, v, load=False): """ Setter method for af_neighbor_capability, mapped from YANG variable /rbridge_id/router/router_bgp/router_bgp_attributes/neighbor/peer_grps/neighbor_peer_grp/af_neighbor_capability (container) If this variable is read-only (config: false) in the s...
[ "def", "_set_af_neighbor_capability", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass", "(", "v", ...
Setter method for af_neighbor_capability, mapped from YANG variable /rbridge_id/router/router_bgp/router_bgp_attributes/neighbor/peer_grps/neighbor_peer_grp/af_neighbor_capability (container) If this variable is read-only (config: false) in the source YANG file, then _set_af_neighbor_capability is considered as...
[ "Setter", "method", "for", "af_neighbor_capability", "mapped", "from", "YANG", "variable", "/", "rbridge_id", "/", "router", "/", "router_bgp", "/", "router_bgp_attributes", "/", "neighbor", "/", "peer_grps", "/", "neighbor_peer_grp", "/", "af_neighbor_capability", "(...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/nos/v7_2_0/rbridge_id/router/router_bgp/router_bgp_attributes/neighbor/peer_grps/neighbor_peer_grp/__init__.py#L859-L880
train
Sets the affinity capability for the neighbor neighbor.
StackStorm/pybind
pybind/nos/v6_0_2f/interface/fortygigabitethernet/fabric/__init__.py
fabric._set_fabric_isl
def _set_fabric_isl(self, v, load=False): """ Setter method for fabric_isl, mapped from YANG variable /interface/fortygigabitethernet/fabric/fabric_isl (container) If this variable is read-only (config: false) in the source YANG file, then _set_fabric_isl is considered as a private method. Backends ...
python
def _set_fabric_isl(self, v, load=False): """ Setter method for fabric_isl, mapped from YANG variable /interface/fortygigabitethernet/fabric/fabric_isl (container) If this variable is read-only (config: false) in the source YANG file, then _set_fabric_isl is considered as a private method. Backends ...
[ "def", "_set_fabric_isl", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass", "(", "v", ",", "bas...
Setter method for fabric_isl, mapped from YANG variable /interface/fortygigabitethernet/fabric/fabric_isl (container) If this variable is read-only (config: false) in the source YANG file, then _set_fabric_isl is considered as a private method. Backends looking to populate this variable should do so via...
[ "Setter", "method", "for", "fabric_isl", "mapped", "from", "YANG", "variable", "/", "interface", "/", "fortygigabitethernet", "/", "fabric", "/", "fabric_isl", "(", "container", ")", "If", "this", "variable", "is", "read", "-", "only", "(", "config", ":", "f...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/nos/v6_0_2f/interface/fortygigabitethernet/fabric/__init__.py#L102-L125
train
Set the value of the fabric_isl property.
StackStorm/pybind
pybind/nos/v6_0_2f/interface/fortygigabitethernet/fabric/__init__.py
fabric._set_fabric_trunk
def _set_fabric_trunk(self, v, load=False): """ Setter method for fabric_trunk, mapped from YANG variable /interface/fortygigabitethernet/fabric/fabric_trunk (container) If this variable is read-only (config: false) in the source YANG file, then _set_fabric_trunk is considered as a private method. B...
python
def _set_fabric_trunk(self, v, load=False): """ Setter method for fabric_trunk, mapped from YANG variable /interface/fortygigabitethernet/fabric/fabric_trunk (container) If this variable is read-only (config: false) in the source YANG file, then _set_fabric_trunk is considered as a private method. B...
[ "def", "_set_fabric_trunk", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass", "(", "v", ",", "b...
Setter method for fabric_trunk, mapped from YANG variable /interface/fortygigabitethernet/fabric/fabric_trunk (container) If this variable is read-only (config: false) in the source YANG file, then _set_fabric_trunk is considered as a private method. Backends looking to populate this variable should do ...
[ "Setter", "method", "for", "fabric_trunk", "mapped", "from", "YANG", "variable", "/", "interface", "/", "fortygigabitethernet", "/", "fabric", "/", "fabric_trunk", "(", "container", ")", "If", "this", "variable", "is", "read", "-", "only", "(", "config", ":", ...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/nos/v6_0_2f/interface/fortygigabitethernet/fabric/__init__.py#L139-L162
train
Sets the Fabric Protocol Trunk parameters
StackStorm/pybind
pybind/nos/v6_0_2f/interface/fortygigabitethernet/fabric/__init__.py
fabric._set_neighbor_discovery
def _set_neighbor_discovery(self, v, load=False): """ Setter method for neighbor_discovery, mapped from YANG variable /interface/fortygigabitethernet/fabric/neighbor_discovery (container) If this variable is read-only (config: false) in the source YANG file, then _set_neighbor_discovery is considered as...
python
def _set_neighbor_discovery(self, v, load=False): """ Setter method for neighbor_discovery, mapped from YANG variable /interface/fortygigabitethernet/fabric/neighbor_discovery (container) If this variable is read-only (config: false) in the source YANG file, then _set_neighbor_discovery is considered as...
[ "def", "_set_neighbor_discovery", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass", "(", "v", ","...
Setter method for neighbor_discovery, mapped from YANG variable /interface/fortygigabitethernet/fabric/neighbor_discovery (container) If this variable is read-only (config: false) in the source YANG file, then _set_neighbor_discovery is considered as a private method. Backends looking to populate this varia...
[ "Setter", "method", "for", "neighbor_discovery", "mapped", "from", "YANG", "variable", "/", "interface", "/", "fortygigabitethernet", "/", "fabric", "/", "neighbor_discovery", "(", "container", ")", "If", "this", "variable", "is", "read", "-", "only", "(", "conf...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/nos/v6_0_2f/interface/fortygigabitethernet/fabric/__init__.py#L176-L199
train
Sets the neighbor discovery for the
StackStorm/pybind
pybind/slxos/v17s_1_02/acl_mirror/__init__.py
acl_mirror._set_source
def _set_source(self, v, load=False): """ Setter method for source, mapped from YANG variable /acl_mirror/source (list) If this variable is read-only (config: false) in the source YANG file, then _set_source is considered as a private method. Backends looking to populate this variable should do ...
python
def _set_source(self, v, load=False): """ Setter method for source, mapped from YANG variable /acl_mirror/source (list) If this variable is read-only (config: false) in the source YANG file, then _set_source is considered as a private method. Backends looking to populate this variable should do ...
[ "def", "_set_source", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass", "(", "v", ",", "base", ...
Setter method for source, mapped from YANG variable /acl_mirror/source (list) If this variable is read-only (config: false) in the source YANG file, then _set_source is considered as a private method. Backends looking to populate this variable should do so via calling thisObj._set_source() directly.
[ "Setter", "method", "for", "source", "mapped", "from", "YANG", "variable", "/", "acl_mirror", "/", "source", "(", "list", ")", "If", "this", "variable", "is", "read", "-", "only", "(", "config", ":", "false", ")", "in", "the", "source", "YANG", "file", ...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/slxos/v17s_1_02/acl_mirror/__init__.py#L92-L113
train
Set the source of the
StackStorm/pybind
pybind/nos/v6_0_2f/mac_address_table/__init__.py
mac_address_table._set_learning_mode
def _set_learning_mode(self, v, load=False): """ Setter method for learning_mode, mapped from YANG variable /mac_address_table/learning_mode (enumeration) If this variable is read-only (config: false) in the source YANG file, then _set_learning_mode is considered as a private method. Backends lookin...
python
def _set_learning_mode(self, v, load=False): """ Setter method for learning_mode, mapped from YANG variable /mac_address_table/learning_mode (enumeration) If this variable is read-only (config: false) in the source YANG file, then _set_learning_mode is considered as a private method. Backends lookin...
[ "def", "_set_learning_mode", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass", "(", "v", ",", "...
Setter method for learning_mode, mapped from YANG variable /mac_address_table/learning_mode (enumeration) If this variable is read-only (config: false) in the source YANG file, then _set_learning_mode is considered as a private method. Backends looking to populate this variable should do so via calling ...
[ "Setter", "method", "for", "learning_mode", "mapped", "from", "YANG", "variable", "/", "mac_address_table", "/", "learning_mode", "(", "enumeration", ")", "If", "this", "variable", "is", "read", "-", "only", "(", "config", ":", "false", ")", "in", "the", "so...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/nos/v6_0_2f/mac_address_table/__init__.py#L134-L157
train
Sets the learning mode of the
StackStorm/pybind
pybind/nos/v6_0_2f/mac_address_table/__init__.py
mac_address_table._set_mac_move
def _set_mac_move(self, v, load=False): """ Setter method for mac_move, mapped from YANG variable /mac_address_table/mac_move (container) If this variable is read-only (config: false) in the source YANG file, then _set_mac_move is considered as a private method. Backends looking to populate this var...
python
def _set_mac_move(self, v, load=False): """ Setter method for mac_move, mapped from YANG variable /mac_address_table/mac_move (container) If this variable is read-only (config: false) in the source YANG file, then _set_mac_move is considered as a private method. Backends looking to populate this var...
[ "def", "_set_mac_move", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass", "(", "v", ",", "base"...
Setter method for mac_move, mapped from YANG variable /mac_address_table/mac_move (container) If this variable is read-only (config: false) in the source YANG file, then _set_mac_move is considered as a private method. Backends looking to populate this variable should do so via calling thisObj._set_mac_...
[ "Setter", "method", "for", "mac_move", "mapped", "from", "YANG", "variable", "/", "mac_address_table", "/", "mac_move", "(", "container", ")", "If", "this", "variable", "is", "read", "-", "only", "(", "config", ":", "false", ")", "in", "the", "source", "YA...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/nos/v6_0_2f/mac_address_table/__init__.py#L208-L231
train
Sets the value of the MAC move variable in the order they are located.
idlesign/steampak
steampak/libsteam/resources/apps.py
Application.install_dir
def install_dir(self): """Returns application installation path. .. note:: If fails this falls back to a restricted interface, which can only be used by approved apps. :rtype: str """ max_len = 500 directory = self._get_str(self._iface.get_install_dir, [se...
python
def install_dir(self): """Returns application installation path. .. note:: If fails this falls back to a restricted interface, which can only be used by approved apps. :rtype: str """ max_len = 500 directory = self._get_str(self._iface.get_install_dir, [se...
[ "def", "install_dir", "(", "self", ")", ":", "max_len", "=", "500", "directory", "=", "self", ".", "_get_str", "(", "self", ".", "_iface", ".", "get_install_dir", ",", "[", "self", ".", "app_id", "]", ",", "max_len", "=", "max_len", ")", "if", "not", ...
Returns application installation path. .. note:: If fails this falls back to a restricted interface, which can only be used by approved apps. :rtype: str
[ "Returns", "application", "installation", "path", "." ]
cb3f2c737e272b0360802d947e388df7e34f50f3
https://github.com/idlesign/steampak/blob/cb3f2c737e272b0360802d947e388df7e34f50f3/steampak/libsteam/resources/apps.py#L73-L90
train
Returns application installation path.
idlesign/steampak
steampak/libsteam/resources/apps.py
Application.purchase_time
def purchase_time(self): """Date and time of app purchase. :rtype: datetime """ ts = self._iface.get_purchase_time(self.app_id) return datetime.utcfromtimestamp(ts)
python
def purchase_time(self): """Date and time of app purchase. :rtype: datetime """ ts = self._iface.get_purchase_time(self.app_id) return datetime.utcfromtimestamp(ts)
[ "def", "purchase_time", "(", "self", ")", ":", "ts", "=", "self", ".", "_iface", ".", "get_purchase_time", "(", "self", ".", "app_id", ")", "return", "datetime", ".", "utcfromtimestamp", "(", "ts", ")" ]
Date and time of app purchase. :rtype: datetime
[ "Date", "and", "time", "of", "app", "purchase", "." ]
cb3f2c737e272b0360802d947e388df7e34f50f3
https://github.com/idlesign/steampak/blob/cb3f2c737e272b0360802d947e388df7e34f50f3/steampak/libsteam/resources/apps.py#L93-L99
train
Returns the datetime of the last app purchase.
idlesign/steampak
steampak/libsteam/resources/apps.py
Dlc.get_download_progress
def get_download_progress(self): """Returns tuple with download progress (for optional DLCs): (bytes_downloaded, bytes_total) :rtype: tuple """ downloaded = CRef.cint() total = CRef.cint() result = self._iface.get_dlc_download_progress(self.app_id, download...
python
def get_download_progress(self): """Returns tuple with download progress (for optional DLCs): (bytes_downloaded, bytes_total) :rtype: tuple """ downloaded = CRef.cint() total = CRef.cint() result = self._iface.get_dlc_download_progress(self.app_id, download...
[ "def", "get_download_progress", "(", "self", ")", ":", "downloaded", "=", "CRef", ".", "cint", "(", ")", "total", "=", "CRef", ".", "cint", "(", ")", "result", "=", "self", ".", "_iface", ".", "get_dlc_download_progress", "(", "self", ".", "app_id", ",",...
Returns tuple with download progress (for optional DLCs): (bytes_downloaded, bytes_total) :rtype: tuple
[ "Returns", "tuple", "with", "download", "progress", "(", "for", "optional", "DLCs", ")", ":" ]
cb3f2c737e272b0360802d947e388df7e34f50f3
https://github.com/idlesign/steampak/blob/cb3f2c737e272b0360802d947e388df7e34f50f3/steampak/libsteam/resources/apps.py#L195-L210
train
Returns tuple with download progress for optional DLCs
StackStorm/pybind
pybind/slxos/v17s_1_02/mpls_state/ldp/tunnels/ldp_tunnels/__init__.py
ldp_tunnels._set_protocol_type
def _set_protocol_type(self, v, load=False): """ Setter method for protocol_type, mapped from YANG variable /mpls_state/ldp/tunnels/ldp_tunnels/protocol_type (mpls-protocol-type) If this variable is read-only (config: false) in the source YANG file, then _set_protocol_type is considered as a private ...
python
def _set_protocol_type(self, v, load=False): """ Setter method for protocol_type, mapped from YANG variable /mpls_state/ldp/tunnels/ldp_tunnels/protocol_type (mpls-protocol-type) If this variable is read-only (config: false) in the source YANG file, then _set_protocol_type is considered as a private ...
[ "def", "_set_protocol_type", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass", "(", "v", ",", "...
Setter method for protocol_type, mapped from YANG variable /mpls_state/ldp/tunnels/ldp_tunnels/protocol_type (mpls-protocol-type) If this variable is read-only (config: false) in the source YANG file, then _set_protocol_type is considered as a private method. Backends looking to populate this variable shoul...
[ "Setter", "method", "for", "protocol_type", "mapped", "from", "YANG", "variable", "/", "mpls_state", "/", "ldp", "/", "tunnels", "/", "ldp_tunnels", "/", "protocol_type", "(", "mpls", "-", "protocol", "-", "type", ")", "If", "this", "variable", "is", "read",...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/slxos/v17s_1_02/mpls_state/ldp/tunnels/ldp_tunnels/__init__.py#L251-L274
train
Sets the protocol type of the
StackStorm/pybind
pybind/nos/v6_0_2f/rbridge_id/snmp_server/__init__.py
snmp_server._set_engineID
def _set_engineID(self, v, load=False): """ Setter method for engineID, mapped from YANG variable /rbridge_id/snmp_server/engineID (container) If this variable is read-only (config: false) in the source YANG file, then _set_engineID is considered as a private method. Backends looking to populate thi...
python
def _set_engineID(self, v, load=False): """ Setter method for engineID, mapped from YANG variable /rbridge_id/snmp_server/engineID (container) If this variable is read-only (config: false) in the source YANG file, then _set_engineID is considered as a private method. Backends looking to populate thi...
[ "def", "_set_engineID", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass", "(", "v", ",", "base"...
Setter method for engineID, mapped from YANG variable /rbridge_id/snmp_server/engineID (container) If this variable is read-only (config: false) in the source YANG file, then _set_engineID is considered as a private method. Backends looking to populate this variable should do so via calling thisObj._set...
[ "Setter", "method", "for", "engineID", "mapped", "from", "YANG", "variable", "/", "rbridge_id", "/", "snmp_server", "/", "engineID", "(", "container", ")", "If", "this", "variable", "is", "read", "-", "only", "(", "config", ":", "false", ")", "in", "the", ...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/nos/v6_0_2f/rbridge_id/snmp_server/__init__.py#L100-L121
train
Sets the engineID of the based on the given parameters.
StackStorm/pybind
pybind/nos/v6_0_2f/rbridge_id/snmp_server/__init__.py
snmp_server._set_offline_if
def _set_offline_if(self, v, load=False): """ Setter method for offline_if, mapped from YANG variable /rbridge_id/snmp_server/offline_if (container) If this variable is read-only (config: false) in the source YANG file, then _set_offline_if is considered as a private method. Backends looking to popu...
python
def _set_offline_if(self, v, load=False): """ Setter method for offline_if, mapped from YANG variable /rbridge_id/snmp_server/offline_if (container) If this variable is read-only (config: false) in the source YANG file, then _set_offline_if is considered as a private method. Backends looking to popu...
[ "def", "_set_offline_if", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass", "(", "v", ",", "bas...
Setter method for offline_if, mapped from YANG variable /rbridge_id/snmp_server/offline_if (container) If this variable is read-only (config: false) in the source YANG file, then _set_offline_if is considered as a private method. Backends looking to populate this variable should do so via calling thisOb...
[ "Setter", "method", "for", "offline_if", "mapped", "from", "YANG", "variable", "/", "rbridge_id", "/", "snmp_server", "/", "offline_if", "(", "container", ")", "If", "this", "variable", "is", "read", "-", "only", "(", "config", ":", "false", ")", "in", "th...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/nos/v6_0_2f/rbridge_id/snmp_server/__init__.py#L199-L220
train
Sets the offline_if property of the cluster.
StackStorm/pybind
pybind/nos/v6_0_2f/rbridge_id/snmp_server/__init__.py
snmp_server._set_three_tuple_if
def _set_three_tuple_if(self, v, load=False): """ Setter method for three_tuple_if, mapped from YANG variable /rbridge_id/snmp_server/three_tuple_if (container) If this variable is read-only (config: false) in the source YANG file, then _set_three_tuple_if is considered as a private method. Backends...
python
def _set_three_tuple_if(self, v, load=False): """ Setter method for three_tuple_if, mapped from YANG variable /rbridge_id/snmp_server/three_tuple_if (container) If this variable is read-only (config: false) in the source YANG file, then _set_three_tuple_if is considered as a private method. Backends...
[ "def", "_set_three_tuple_if", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass", "(", "v", ",", ...
Setter method for three_tuple_if, mapped from YANG variable /rbridge_id/snmp_server/three_tuple_if (container) If this variable is read-only (config: false) in the source YANG file, then _set_three_tuple_if is considered as a private method. Backends looking to populate this variable should do so via ca...
[ "Setter", "method", "for", "three_tuple_if", "mapped", "from", "YANG", "variable", "/", "rbridge_id", "/", "snmp_server", "/", "three_tuple_if", "(", "container", ")", "If", "this", "variable", "is", "read", "-", "only", "(", "config", ":", "false", ")", "in...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/nos/v6_0_2f/rbridge_id/snmp_server/__init__.py#L232-L253
train
Sets the value of three - tuple - if mapped from YANG variable to a private one.
StackStorm/pybind
pybind/slxos/v17s_1_02/mpls_state/ldp/__init__.py
ldp._set_ldp_out
def _set_ldp_out(self, v, load=False): """ Setter method for ldp_out, mapped from YANG variable /mpls_state/ldp/ldp_out (container) If this variable is read-only (config: false) in the source YANG file, then _set_ldp_out is considered as a private method. Backends looking to populate this variable s...
python
def _set_ldp_out(self, v, load=False): """ Setter method for ldp_out, mapped from YANG variable /mpls_state/ldp/ldp_out (container) If this variable is read-only (config: false) in the source YANG file, then _set_ldp_out is considered as a private method. Backends looking to populate this variable s...
[ "def", "_set_ldp_out", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass", "(", "v", ",", "base",...
Setter method for ldp_out, mapped from YANG variable /mpls_state/ldp/ldp_out (container) If this variable is read-only (config: false) in the source YANG file, then _set_ldp_out is considered as a private method. Backends looking to populate this variable should do so via calling thisObj._set_ldp_out() ...
[ "Setter", "method", "for", "ldp_out", "mapped", "from", "YANG", "variable", "/", "mpls_state", "/", "ldp", "/", "ldp_out", "(", "container", ")", "If", "this", "variable", "is", "read", "-", "only", "(", "config", ":", "false", ")", "in", "the", "source"...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/slxos/v17s_1_02/mpls_state/ldp/__init__.py#L114-L135
train
Sets the ldp - out variable for the cluster.
StackStorm/pybind
pybind/slxos/v17s_1_02/qos/cpu/slot/port_group/__init__.py
port_group._set_port
def _set_port(self, v, load=False): """ Setter method for port, mapped from YANG variable /qos/cpu/slot/port_group/port (container) If this variable is read-only (config: false) in the source YANG file, then _set_port is considered as a private method. Backends looking to populate this variable shou...
python
def _set_port(self, v, load=False): """ Setter method for port, mapped from YANG variable /qos/cpu/slot/port_group/port (container) If this variable is read-only (config: false) in the source YANG file, then _set_port is considered as a private method. Backends looking to populate this variable shou...
[ "def", "_set_port", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass", "(", "v", ",", "base", ...
Setter method for port, mapped from YANG variable /qos/cpu/slot/port_group/port (container) If this variable is read-only (config: false) in the source YANG file, then _set_port is considered as a private method. Backends looking to populate this variable should do so via calling thisObj._set_port() dir...
[ "Setter", "method", "for", "port", "mapped", "from", "YANG", "variable", "/", "qos", "/", "cpu", "/", "slot", "/", "port_group", "/", "port", "(", "container", ")", "If", "this", "variable", "is", "read", "-", "only", "(", "config", ":", "false", ")", ...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/slxos/v17s_1_02/qos/cpu/slot/port_group/__init__.py#L94-L115
train
Sets the port of the based on the given port.
StackStorm/pybind
pybind/slxos/v17s_1_02/qos/cpu/slot/port_group/__init__.py
port_group._set_group
def _set_group(self, v, load=False): """ Setter method for group, mapped from YANG variable /qos/cpu/slot/port_group/group (list) If this variable is read-only (config: false) in the source YANG file, then _set_group is considered as a private method. Backends looking to populate this variable shoul...
python
def _set_group(self, v, load=False): """ Setter method for group, mapped from YANG variable /qos/cpu/slot/port_group/group (list) If this variable is read-only (config: false) in the source YANG file, then _set_group is considered as a private method. Backends looking to populate this variable shoul...
[ "def", "_set_group", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass", "(", "v", ",", "base", ...
Setter method for group, mapped from YANG variable /qos/cpu/slot/port_group/group (list) If this variable is read-only (config: false) in the source YANG file, then _set_group is considered as a private method. Backends looking to populate this variable should do so via calling thisObj._set_group() dire...
[ "Setter", "method", "for", "group", "mapped", "from", "YANG", "variable", "/", "qos", "/", "cpu", "/", "slot", "/", "port_group", "/", "group", "(", "list", ")", "If", "this", "variable", "is", "read", "-", "only", "(", "config", ":", "false", ")", "...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/slxos/v17s_1_02/qos/cpu/slot/port_group/__init__.py#L127-L148
train
Sets the group of the based on group_id.
StackStorm/pybind
pybind/nos/v6_0_2f/interface/port_channel/port_profile_to_interface_associations/port_profile_port/__init__.py
port_profile_port._set_port_to_port_profile_domain_association
def _set_port_to_port_profile_domain_association(self, v, load=False): """ Setter method for port_to_port_profile_domain_association, mapped from YANG variable /interface/port_channel/port_profile_to_interface_associations/port_profile_port/port_to_port_profile_domain_association (container) If this variabl...
python
def _set_port_to_port_profile_domain_association(self, v, load=False): """ Setter method for port_to_port_profile_domain_association, mapped from YANG variable /interface/port_channel/port_profile_to_interface_associations/port_profile_port/port_to_port_profile_domain_association (container) If this variabl...
[ "def", "_set_port_to_port_profile_domain_association", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass"...
Setter method for port_to_port_profile_domain_association, mapped from YANG variable /interface/port_channel/port_profile_to_interface_associations/port_profile_port/port_to_port_profile_domain_association (container) If this variable is read-only (config: false) in the source YANG file, then _set_port_to_port_...
[ "Setter", "method", "for", "port_to_port_profile_domain_association", "mapped", "from", "YANG", "variable", "/", "interface", "/", "port_channel", "/", "port_profile_to_interface_associations", "/", "port_profile_port", "/", "port_to_port_profile_domain_association", "(", "cont...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/nos/v6_0_2f/interface/port_channel/port_profile_to_interface_associations/port_profile_port/__init__.py#L96-L119
train
Sets the port - to - port - profile - domain association for the interface.
StackStorm/pybind
pybind/nos/v6_0_2f/interface/port_channel/port_profile_to_interface_associations/port_profile_port/__init__.py
port_profile_port._set_port_to_port_profile_associations
def _set_port_to_port_profile_associations(self, v, load=False): """ Setter method for port_to_port_profile_associations, mapped from YANG variable /interface/port_channel/port_profile_to_interface_associations/port_profile_port/port_to_port_profile_associations (list) If this variable is read-only (config:...
python
def _set_port_to_port_profile_associations(self, v, load=False): """ Setter method for port_to_port_profile_associations, mapped from YANG variable /interface/port_channel/port_profile_to_interface_associations/port_profile_port/port_to_port_profile_associations (list) If this variable is read-only (config:...
[ "def", "_set_port_to_port_profile_associations", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass", "(...
Setter method for port_to_port_profile_associations, mapped from YANG variable /interface/port_channel/port_profile_to_interface_associations/port_profile_port/port_to_port_profile_associations (list) If this variable is read-only (config: false) in the source YANG file, then _set_port_to_port_profile_associati...
[ "Setter", "method", "for", "port_to_port_profile_associations", "mapped", "from", "YANG", "variable", "/", "interface", "/", "port_channel", "/", "port_profile_to_interface_associations", "/", "port_profile_port", "/", "port_to_port_profile_associations", "(", "list", ")", ...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/nos/v6_0_2f/interface/port_channel/port_profile_to_interface_associations/port_profile_port/__init__.py#L135-L160
train
Sets the port - to - port - profile associations in the base order.
StackStorm/pybind
pybind/nos/v6_0_2f/snmp_server/__init__.py
snmp_server._set_context
def _set_context(self, v, load=False): """ Setter method for context, mapped from YANG variable /snmp_server/context (list) If this variable is read-only (config: false) in the source YANG file, then _set_context is considered as a private method. Backends looking to populate this variable should ...
python
def _set_context(self, v, load=False): """ Setter method for context, mapped from YANG variable /snmp_server/context (list) If this variable is read-only (config: false) in the source YANG file, then _set_context is considered as a private method. Backends looking to populate this variable should ...
[ "def", "_set_context", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass", "(", "v", ",", "base",...
Setter method for context, mapped from YANG variable /snmp_server/context (list) If this variable is read-only (config: false) in the source YANG file, then _set_context is considered as a private method. Backends looking to populate this variable should do so via calling thisObj._set_context() directly...
[ "Setter", "method", "for", "context", "mapped", "from", "YANG", "variable", "/", "snmp_server", "/", "context", "(", "list", ")", "If", "this", "variable", "is", "read", "-", "only", "(", "config", ":", "false", ")", "in", "the", "source", "YANG", "file"...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/nos/v6_0_2f/snmp_server/__init__.py#L114-L139
train
Set the value of context in the cluster.
StackStorm/pybind
pybind/nos/v6_0_2f/snmp_server/__init__.py
snmp_server._set_community
def _set_community(self, v, load=False): """ Setter method for community, mapped from YANG variable /snmp_server/community (list) If this variable is read-only (config: false) in the source YANG file, then _set_community is considered as a private method. Backends looking to populate this variable s...
python
def _set_community(self, v, load=False): """ Setter method for community, mapped from YANG variable /snmp_server/community (list) If this variable is read-only (config: false) in the source YANG file, then _set_community is considered as a private method. Backends looking to populate this variable s...
[ "def", "_set_community", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass", "(", "v", ",", "base...
Setter method for community, mapped from YANG variable /snmp_server/community (list) If this variable is read-only (config: false) in the source YANG file, then _set_community is considered as a private method. Backends looking to populate this variable should do so via calling thisObj._set_community() ...
[ "Setter", "method", "for", "community", "mapped", "from", "YANG", "variable", "/", "snmp_server", "/", "community", "(", "list", ")", "If", "this", "variable", "is", "read", "-", "only", "(", "config", ":", "false", ")", "in", "the", "source", "YANG", "f...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/nos/v6_0_2f/snmp_server/__init__.py#L151-L172
train
Set the community field of the
StackStorm/pybind
pybind/nos/v6_0_2f/snmp_server/__init__.py
snmp_server._set_host
def _set_host(self, v, load=False): """ Setter method for host, mapped from YANG variable /snmp_server/host (list) If this variable is read-only (config: false) in the source YANG file, then _set_host is considered as a private method. Backends looking to populate this variable should do so via ...
python
def _set_host(self, v, load=False): """ Setter method for host, mapped from YANG variable /snmp_server/host (list) If this variable is read-only (config: false) in the source YANG file, then _set_host is considered as a private method. Backends looking to populate this variable should do so via ...
[ "def", "_set_host", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass", "(", "v", ",", "base", ...
Setter method for host, mapped from YANG variable /snmp_server/host (list) If this variable is read-only (config: false) in the source YANG file, then _set_host is considered as a private method. Backends looking to populate this variable should do so via calling thisObj._set_host() directly.
[ "Setter", "method", "for", "host", "mapped", "from", "YANG", "variable", "/", "snmp_server", "/", "host", "(", "list", ")", "If", "this", "variable", "is", "read", "-", "only", "(", "config", ":", "false", ")", "in", "the", "source", "YANG", "file", "t...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/nos/v6_0_2f/snmp_server/__init__.py#L250-L271
train
Set the host field of the
StackStorm/pybind
pybind/nos/v6_0_2f/snmp_server/__init__.py
snmp_server._set_view
def _set_view(self, v, load=False): """ Setter method for view, mapped from YANG variable /snmp_server/view (list) If this variable is read-only (config: false) in the source YANG file, then _set_view is considered as a private method. Backends looking to populate this variable should do so via ...
python
def _set_view(self, v, load=False): """ Setter method for view, mapped from YANG variable /snmp_server/view (list) If this variable is read-only (config: false) in the source YANG file, then _set_view is considered as a private method. Backends looking to populate this variable should do so via ...
[ "def", "_set_view", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass", "(", "v", ",", "base", ...
Setter method for view, mapped from YANG variable /snmp_server/view (list) If this variable is read-only (config: false) in the source YANG file, then _set_view is considered as a private method. Backends looking to populate this variable should do so via calling thisObj._set_view() directly.
[ "Setter", "method", "for", "view", "mapped", "from", "YANG", "variable", "/", "snmp_server", "/", "view", "(", "list", ")", "If", "this", "variable", "is", "read", "-", "only", "(", "config", ":", "false", ")", "in", "the", "source", "YANG", "file", "t...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/nos/v6_0_2f/snmp_server/__init__.py#L382-L403
train
Set the view of the based on the given list of view names.
StackStorm/pybind
pybind/slxos/v17s_1_02/routing_system/interface/ve/ipv6/interface_ospfv3_conf/__init__.py
interface_ospfv3_conf._set_network
def _set_network(self, v, load=False): """ Setter method for network, mapped from YANG variable /routing_system/interface/ve/ipv6/interface_ospfv3_conf/network (enumeration) If this variable is read-only (config: false) in the source YANG file, then _set_network is considered as a private method. Ba...
python
def _set_network(self, v, load=False): """ Setter method for network, mapped from YANG variable /routing_system/interface/ve/ipv6/interface_ospfv3_conf/network (enumeration) If this variable is read-only (config: false) in the source YANG file, then _set_network is considered as a private method. Ba...
[ "def", "_set_network", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass", "(", "v", ",", "base",...
Setter method for network, mapped from YANG variable /routing_system/interface/ve/ipv6/interface_ospfv3_conf/network (enumeration) If this variable is read-only (config: false) in the source YANG file, then _set_network is considered as a private method. Backends looking to populate this variable should ...
[ "Setter", "method", "for", "network", "mapped", "from", "YANG", "variable", "/", "routing_system", "/", "interface", "/", "ve", "/", "ipv6", "/", "interface_ospfv3_conf", "/", "network", "(", "enumeration", ")", "If", "this", "variable", "is", "read", "-", "...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/slxos/v17s_1_02/routing_system/interface/ve/ipv6/interface_ospfv3_conf/__init__.py#L368-L391
train
Sets the network of the ICSV3 network.
StackStorm/pybind
pybind/slxos/v17s_1_02/logical_interface_state/main_interface_physical/__init__.py
main_interface_physical._set_intf_type
def _set_intf_type(self, v, load=False): """ Setter method for intf_type, mapped from YANG variable /logical_interface_state/main_interface_physical/intf_type (intf-type) If this variable is read-only (config: false) in the source YANG file, then _set_intf_type is considered as a private method. Bac...
python
def _set_intf_type(self, v, load=False): """ Setter method for intf_type, mapped from YANG variable /logical_interface_state/main_interface_physical/intf_type (intf-type) If this variable is read-only (config: false) in the source YANG file, then _set_intf_type is considered as a private method. Bac...
[ "def", "_set_intf_type", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass", "(", "v", ",", "base...
Setter method for intf_type, mapped from YANG variable /logical_interface_state/main_interface_physical/intf_type (intf-type) If this variable is read-only (config: false) in the source YANG file, then _set_intf_type is considered as a private method. Backends looking to populate this variable should do...
[ "Setter", "method", "for", "intf_type", "mapped", "from", "YANG", "variable", "/", "logical_interface_state", "/", "main_interface_physical", "/", "intf_type", "(", "intf", "-", "type", ")", "If", "this", "variable", "is", "read", "-", "only", "(", "config", "...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/slxos/v17s_1_02/logical_interface_state/main_interface_physical/__init__.py#L253-L276
train
Sets the interface type for the
StackStorm/pybind
pybind/nos/v6_0_2f/rbridge_id/vrf/address_family/ipv6/unicast/ipv6/import_/__init__.py
import_._set_routes
def _set_routes(self, v, load=False): """ Setter method for routes, mapped from YANG variable /rbridge_id/vrf/address_family/ipv6/unicast/ipv6/import/routes (list) If this variable is read-only (config: false) in the source YANG file, then _set_routes is considered as a private method. Backends look...
python
def _set_routes(self, v, load=False): """ Setter method for routes, mapped from YANG variable /rbridge_id/vrf/address_family/ipv6/unicast/ipv6/import/routes (list) If this variable is read-only (config: false) in the source YANG file, then _set_routes is considered as a private method. Backends look...
[ "def", "_set_routes", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass", "(", "v", ",", "base", ...
Setter method for routes, mapped from YANG variable /rbridge_id/vrf/address_family/ipv6/unicast/ipv6/import/routes (list) If this variable is read-only (config: false) in the source YANG file, then _set_routes is considered as a private method. Backends looking to populate this variable should do so via...
[ "Setter", "method", "for", "routes", "mapped", "from", "YANG", "variable", "/", "rbridge_id", "/", "vrf", "/", "address_family", "/", "ipv6", "/", "unicast", "/", "ipv6", "/", "import", "/", "routes", "(", "list", ")", "If", "this", "variable", "is", "re...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/nos/v6_0_2f/rbridge_id/vrf/address_family/ipv6/unicast/ipv6/import_/__init__.py#L94-L117
train
Set the routes in the current node.
StackStorm/pybind
pybind/slxos/v17r_2_00/sflow/__init__.py
sflow._set_collector_vrf
def _set_collector_vrf(self, v, load=False): """ Setter method for collector_vrf, mapped from YANG variable /sflow/collector_vrf (common-def:vrf-name) If this variable is read-only (config: false) in the source YANG file, then _set_collector_vrf is considered as a private method. Backends looking to...
python
def _set_collector_vrf(self, v, load=False): """ Setter method for collector_vrf, mapped from YANG variable /sflow/collector_vrf (common-def:vrf-name) If this variable is read-only (config: false) in the source YANG file, then _set_collector_vrf is considered as a private method. Backends looking to...
[ "def", "_set_collector_vrf", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass", "(", "v", ",", "...
Setter method for collector_vrf, mapped from YANG variable /sflow/collector_vrf (common-def:vrf-name) If this variable is read-only (config: false) in the source YANG file, then _set_collector_vrf is considered as a private method. Backends looking to populate this variable should do so via calling this...
[ "Setter", "method", "for", "collector_vrf", "mapped", "from", "YANG", "variable", "/", "sflow", "/", "collector_vrf", "(", "common", "-", "def", ":", "vrf", "-", "name", ")", "If", "this", "variable", "is", "read", "-", "only", "(", "config", ":", "false...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/slxos/v17r_2_00/sflow/__init__.py#L167-L188
train
Sets the value of the collector_vrf field.
StackStorm/pybind
pybind/nos/v6_0_2f/brocade_fabric_service_rpc/show_linkinfo/output/show_link_info/linkinfo_isl/__init__.py
linkinfo_isl._set_linkinfo_isllink_srcport_type
def _set_linkinfo_isllink_srcport_type(self, v, load=False): """ Setter method for linkinfo_isllink_srcport_type, mapped from YANG variable /brocade_fabric_service_rpc/show_linkinfo/output/show_link_info/linkinfo_isl/linkinfo_isllink_srcport_type (interfacetype-type) If this variable is read-only (config: f...
python
def _set_linkinfo_isllink_srcport_type(self, v, load=False): """ Setter method for linkinfo_isllink_srcport_type, mapped from YANG variable /brocade_fabric_service_rpc/show_linkinfo/output/show_link_info/linkinfo_isl/linkinfo_isllink_srcport_type (interfacetype-type) If this variable is read-only (config: f...
[ "def", "_set_linkinfo_isllink_srcport_type", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass", "(", ...
Setter method for linkinfo_isllink_srcport_type, mapped from YANG variable /brocade_fabric_service_rpc/show_linkinfo/output/show_link_info/linkinfo_isl/linkinfo_isllink_srcport_type (interfacetype-type) If this variable is read-only (config: false) in the source YANG file, then _set_linkinfo_isllink_srcport_typ...
[ "Setter", "method", "for", "linkinfo_isllink_srcport_type", "mapped", "from", "YANG", "variable", "/", "brocade_fabric_service_rpc", "/", "show_linkinfo", "/", "output", "/", "show_link_info", "/", "linkinfo_isl", "/", "linkinfo_isllink_srcport_type", "(", "interfacetype", ...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/nos/v6_0_2f/brocade_fabric_service_rpc/show_linkinfo/output/show_link_info/linkinfo_isl/__init__.py#L225-L251
train
Sets the source port type for the ILO link.
StackStorm/pybind
pybind/nos/v6_0_2f/interface/management/__init__.py
management._set_tcp
def _set_tcp(self, v, load=False): """ Setter method for tcp, mapped from YANG variable /interface/management/tcp (container) If this variable is read-only (config: false) in the source YANG file, then _set_tcp is considered as a private method. Backends looking to populate this variable should ...
python
def _set_tcp(self, v, load=False): """ Setter method for tcp, mapped from YANG variable /interface/management/tcp (container) If this variable is read-only (config: false) in the source YANG file, then _set_tcp is considered as a private method. Backends looking to populate this variable should ...
[ "def", "_set_tcp", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass", "(", "v", ",", "base", "...
Setter method for tcp, mapped from YANG variable /interface/management/tcp (container) If this variable is read-only (config: false) in the source YANG file, then _set_tcp is considered as a private method. Backends looking to populate this variable should do so via calling thisObj._set_tcp() directly. ...
[ "Setter", "method", "for", "tcp", "mapped", "from", "YANG", "variable", "/", "interface", "/", "management", "/", "tcp", "(", "container", ")", "If", "this", "variable", "is", "read", "-", "only", "(", "config", ":", "false", ")", "in", "the", "source", ...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/nos/v6_0_2f/interface/management/__init__.py#L151-L174
train
Sets the tcp property of the
StackStorm/pybind
pybind/nos/v6_0_2f/interface/management/__init__.py
management._set_speed
def _set_speed(self, v, load=False): """ Setter method for speed, mapped from YANG variable /interface/management/speed (enumeration) If this variable is read-only (config: false) in the source YANG file, then _set_speed is considered as a private method. Backends looking to populate this variable s...
python
def _set_speed(self, v, load=False): """ Setter method for speed, mapped from YANG variable /interface/management/speed (enumeration) If this variable is read-only (config: false) in the source YANG file, then _set_speed is considered as a private method. Backends looking to populate this variable s...
[ "def", "_set_speed", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass", "(", "v", ",", "base", ...
Setter method for speed, mapped from YANG variable /interface/management/speed (enumeration) If this variable is read-only (config: false) in the source YANG file, then _set_speed is considered as a private method. Backends looking to populate this variable should do so via calling thisObj._set_speed() ...
[ "Setter", "method", "for", "speed", "mapped", "from", "YANG", "variable", "/", "interface", "/", "management", "/", "speed", "(", "enumeration", ")", "If", "this", "variable", "is", "read", "-", "only", "(", "config", ":", "false", ")", "in", "the", "sou...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/nos/v6_0_2f/interface/management/__init__.py#L300-L324
train
Sets the speed of the
StackStorm/pybind
pybind/nos/v6_0_2f/interface/management/__init__.py
management._set_line_speed
def _set_line_speed(self, v, load=False): """ Setter method for line_speed, mapped from YANG variable /interface/management/line_speed (container) If this variable is read-only (config: false) in the source YANG file, then _set_line_speed is considered as a private method. Backends looking to popula...
python
def _set_line_speed(self, v, load=False): """ Setter method for line_speed, mapped from YANG variable /interface/management/line_speed (container) If this variable is read-only (config: false) in the source YANG file, then _set_line_speed is considered as a private method. Backends looking to popula...
[ "def", "_set_line_speed", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass", "(", "v", ",", "bas...
Setter method for line_speed, mapped from YANG variable /interface/management/line_speed (container) If this variable is read-only (config: false) in the source YANG file, then _set_line_speed is considered as a private method. Backends looking to populate this variable should do so via calling thisObj....
[ "Setter", "method", "for", "line_speed", "mapped", "from", "YANG", "variable", "/", "interface", "/", "management", "/", "line_speed", "(", "container", ")", "If", "this", "variable", "is", "read", "-", "only", "(", "config", ":", "false", ")", "in", "the"...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/nos/v6_0_2f/interface/management/__init__.py#L339-L363
train
Sets the line - speed of the node.
StackStorm/pybind
pybind/nos/v6_0_2f/interface/management/__init__.py
management._set_shutdown_management_oper
def _set_shutdown_management_oper(self, v, load=False): """ Setter method for shutdown_management_oper, mapped from YANG variable /interface/management/shutdown_management_oper (string) If this variable is read-only (config: false) in the source YANG file, then _set_shutdown_management_oper is considere...
python
def _set_shutdown_management_oper(self, v, load=False): """ Setter method for shutdown_management_oper, mapped from YANG variable /interface/management/shutdown_management_oper (string) If this variable is read-only (config: false) in the source YANG file, then _set_shutdown_management_oper is considere...
[ "def", "_set_shutdown_management_oper", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass", "(", "v",...
Setter method for shutdown_management_oper, mapped from YANG variable /interface/management/shutdown_management_oper (string) If this variable is read-only (config: false) in the source YANG file, then _set_shutdown_management_oper is considered as a private method. Backends looking to populate this variabl...
[ "Setter", "method", "for", "shutdown_management_oper", "mapped", "from", "YANG", "variable", "/", "interface", "/", "management", "/", "shutdown_management_oper", "(", "string", ")", "If", "this", "variable", "is", "read", "-", "only", "(", "config", ":", "false...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/nos/v6_0_2f/interface/management/__init__.py#L414-L437
train
Sets the shutdown_management_oper variable of the
StackStorm/pybind
pybind/slxos/v17s_1_02/isis_state/__init__.py
isis_state._set_global_isis_info
def _set_global_isis_info(self, v, load=False): """ Setter method for global_isis_info, mapped from YANG variable /isis_state/global_isis_info (container) If this variable is read-only (config: false) in the source YANG file, then _set_global_isis_info is considered as a private method. Backends loo...
python
def _set_global_isis_info(self, v, load=False): """ Setter method for global_isis_info, mapped from YANG variable /isis_state/global_isis_info (container) If this variable is read-only (config: false) in the source YANG file, then _set_global_isis_info is considered as a private method. Backends loo...
[ "def", "_set_global_isis_info", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass", "(", "v", ",", ...
Setter method for global_isis_info, mapped from YANG variable /isis_state/global_isis_info (container) If this variable is read-only (config: false) in the source YANG file, then _set_global_isis_info is considered as a private method. Backends looking to populate this variable should do so via calling ...
[ "Setter", "method", "for", "global_isis_info", "mapped", "from", "YANG", "variable", "/", "isis_state", "/", "global_isis_info", "(", "container", ")", "If", "this", "variable", "is", "read", "-", "only", "(", "config", ":", "false", ")", "in", "the", "sourc...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/slxos/v17s_1_02/isis_state/__init__.py#L110-L133
train
Sets the global_isis_info variable.
StackStorm/pybind
pybind/slxos/v17s_1_02/isis_state/__init__.py
isis_state._set_router_isis_config
def _set_router_isis_config(self, v, load=False): """ Setter method for router_isis_config, mapped from YANG variable /isis_state/router_isis_config (container) If this variable is read-only (config: false) in the source YANG file, then _set_router_isis_config is considered as a private method. Back...
python
def _set_router_isis_config(self, v, load=False): """ Setter method for router_isis_config, mapped from YANG variable /isis_state/router_isis_config (container) If this variable is read-only (config: false) in the source YANG file, then _set_router_isis_config is considered as a private method. Back...
[ "def", "_set_router_isis_config", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass", "(", "v", ","...
Setter method for router_isis_config, mapped from YANG variable /isis_state/router_isis_config (container) If this variable is read-only (config: false) in the source YANG file, then _set_router_isis_config is considered as a private method. Backends looking to populate this variable should do so via ca...
[ "Setter", "method", "for", "router_isis_config", "mapped", "from", "YANG", "variable", "/", "isis_state", "/", "router_isis_config", "(", "container", ")", "If", "this", "variable", "is", "read", "-", "only", "(", "config", ":", "false", ")", "in", "the", "s...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/slxos/v17s_1_02/isis_state/__init__.py#L147-L170
train
Sets the value of the ISA global configuration for the ISIS virtual system.
StackStorm/pybind
pybind/slxos/v17s_1_02/isis_state/__init__.py
isis_state._set_host_table
def _set_host_table(self, v, load=False): """ Setter method for host_table, mapped from YANG variable /isis_state/host_table (container) If this variable is read-only (config: false) in the source YANG file, then _set_host_table is considered as a private method. Backends looking to populate this va...
python
def _set_host_table(self, v, load=False): """ Setter method for host_table, mapped from YANG variable /isis_state/host_table (container) If this variable is read-only (config: false) in the source YANG file, then _set_host_table is considered as a private method. Backends looking to populate this va...
[ "def", "_set_host_table", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass", "(", "v", ",", "bas...
Setter method for host_table, mapped from YANG variable /isis_state/host_table (container) If this variable is read-only (config: false) in the source YANG file, then _set_host_table is considered as a private method. Backends looking to populate this variable should do so via calling thisObj._set_host_...
[ "Setter", "method", "for", "host_table", "mapped", "from", "YANG", "variable", "/", "isis_state", "/", "host_table", "(", "container", ")", "If", "this", "variable", "is", "read", "-", "only", "(", "config", ":", "false", ")", "in", "the", "source", "YANG"...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/slxos/v17s_1_02/isis_state/__init__.py#L184-L207
train
Sets the host_table property of the
StackStorm/pybind
pybind/slxos/v17s_1_02/isis_state/__init__.py
isis_state._set_ipv4_routes
def _set_ipv4_routes(self, v, load=False): """ Setter method for ipv4_routes, mapped from YANG variable /isis_state/ipv4_routes (container) If this variable is read-only (config: false) in the source YANG file, then _set_ipv4_routes is considered as a private method. Backends looking to populate thi...
python
def _set_ipv4_routes(self, v, load=False): """ Setter method for ipv4_routes, mapped from YANG variable /isis_state/ipv4_routes (container) If this variable is read-only (config: false) in the source YANG file, then _set_ipv4_routes is considered as a private method. Backends looking to populate thi...
[ "def", "_set_ipv4_routes", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass", "(", "v", ",", "ba...
Setter method for ipv4_routes, mapped from YANG variable /isis_state/ipv4_routes (container) If this variable is read-only (config: false) in the source YANG file, then _set_ipv4_routes is considered as a private method. Backends looking to populate this variable should do so via calling thisObj._set_ip...
[ "Setter", "method", "for", "ipv4_routes", "mapped", "from", "YANG", "variable", "/", "isis_state", "/", "ipv4_routes", "(", "container", ")", "If", "this", "variable", "is", "read", "-", "only", "(", "config", ":", "false", ")", "in", "the", "source", "YAN...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/slxos/v17s_1_02/isis_state/__init__.py#L221-L244
train
Sets the ipv4_routes variable in the ISIS virtual node.
StackStorm/pybind
pybind/slxos/v17s_1_02/isis_state/__init__.py
isis_state._set_ipv6_routes
def _set_ipv6_routes(self, v, load=False): """ Setter method for ipv6_routes, mapped from YANG variable /isis_state/ipv6_routes (container) If this variable is read-only (config: false) in the source YANG file, then _set_ipv6_routes is considered as a private method. Backends looking to populate thi...
python
def _set_ipv6_routes(self, v, load=False): """ Setter method for ipv6_routes, mapped from YANG variable /isis_state/ipv6_routes (container) If this variable is read-only (config: false) in the source YANG file, then _set_ipv6_routes is considered as a private method. Backends looking to populate thi...
[ "def", "_set_ipv6_routes", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass", "(", "v", ",", "ba...
Setter method for ipv6_routes, mapped from YANG variable /isis_state/ipv6_routes (container) If this variable is read-only (config: false) in the source YANG file, then _set_ipv6_routes is considered as a private method. Backends looking to populate this variable should do so via calling thisObj._set_ip...
[ "Setter", "method", "for", "ipv6_routes", "mapped", "from", "YANG", "variable", "/", "isis_state", "/", "ipv6_routes", "(", "container", ")", "If", "this", "variable", "is", "read", "-", "only", "(", "config", ":", "false", ")", "in", "the", "source", "YAN...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/slxos/v17s_1_02/isis_state/__init__.py#L258-L281
train
Sets the ipv6 routes property of the
StackStorm/pybind
pybind/slxos/v17s_1_02/isis_state/__init__.py
isis_state._set_interface_brief
def _set_interface_brief(self, v, load=False): """ Setter method for interface_brief, mapped from YANG variable /isis_state/interface_brief (container) If this variable is read-only (config: false) in the source YANG file, then _set_interface_brief is considered as a private method. Backends looking...
python
def _set_interface_brief(self, v, load=False): """ Setter method for interface_brief, mapped from YANG variable /isis_state/interface_brief (container) If this variable is read-only (config: false) in the source YANG file, then _set_interface_brief is considered as a private method. Backends looking...
[ "def", "_set_interface_brief", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass", "(", "v", ",", ...
Setter method for interface_brief, mapped from YANG variable /isis_state/interface_brief (container) If this variable is read-only (config: false) in the source YANG file, then _set_interface_brief is considered as a private method. Backends looking to populate this variable should do so via calling thi...
[ "Setter", "method", "for", "interface_brief", "mapped", "from", "YANG", "variable", "/", "isis_state", "/", "interface_brief", "(", "container", ")", "If", "this", "variable", "is", "read", "-", "only", "(", "config", ":", "false", ")", "in", "the", "source"...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/slxos/v17s_1_02/isis_state/__init__.py#L295-L318
train
Set the value of the interface_brief field.
StackStorm/pybind
pybind/slxos/v17s_1_02/isis_state/__init__.py
isis_state._set_interface_detail
def _set_interface_detail(self, v, load=False): """ Setter method for interface_detail, mapped from YANG variable /isis_state/interface_detail (container) If this variable is read-only (config: false) in the source YANG file, then _set_interface_detail is considered as a private method. Backends loo...
python
def _set_interface_detail(self, v, load=False): """ Setter method for interface_detail, mapped from YANG variable /isis_state/interface_detail (container) If this variable is read-only (config: false) in the source YANG file, then _set_interface_detail is considered as a private method. Backends loo...
[ "def", "_set_interface_detail", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass", "(", "v", ",", ...
Setter method for interface_detail, mapped from YANG variable /isis_state/interface_detail (container) If this variable is read-only (config: false) in the source YANG file, then _set_interface_detail is considered as a private method. Backends looking to populate this variable should do so via calling ...
[ "Setter", "method", "for", "interface_detail", "mapped", "from", "YANG", "variable", "/", "isis_state", "/", "interface_detail", "(", "container", ")", "If", "this", "variable", "is", "read", "-", "only", "(", "config", ":", "false", ")", "in", "the", "sourc...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/slxos/v17s_1_02/isis_state/__init__.py#L332-L355
train
Sets the interface_detail variable.
BD2KGenomics/protect
docker/pipelineWrapper.py
PipelineWrapperBuilder.run
def run(self, args, pipeline_command): """ Invokes the pipeline with the defined command. Command line arguments, and the command need to be set with arg_builder, and command_builder respectively before this method can be invoked. """ # output that must be moved but not ...
python
def run(self, args, pipeline_command): """ Invokes the pipeline with the defined command. Command line arguments, and the command need to be set with arg_builder, and command_builder respectively before this method can be invoked. """ # output that must be moved but not ...
[ "def", "run", "(", "self", ",", "args", ",", "pipeline_command", ")", ":", "# output that must be moved but not renamed", "consistentNaming", "=", "[", "'alignments/normal_dna_fix_pg_sorted.bam'", ",", "'alignments/normal_dna_fix_pg_sorted.bam.bai'", ",", "'alignments/rna_genome_...
Invokes the pipeline with the defined command. Command line arguments, and the command need to be set with arg_builder, and command_builder respectively before this method can be invoked.
[ "Invokes", "the", "pipeline", "with", "the", "defined", "command", ".", "Command", "line", "arguments", "and", "the", "command", "need", "to", "be", "set", "with", "arg_builder", "and", "command_builder", "respectively", "before", "this", "method", "can", "be", ...
06310682c50dcf8917b912c8e551299ff7ee41ce
https://github.com/BD2KGenomics/protect/blob/06310682c50dcf8917b912c8e551299ff7ee41ce/docker/pipelineWrapper.py#L51-L168
train
This method is called by the base class to run the pipeline.
BD2KGenomics/protect
docker/pipelineWrapper.py
PipelineWrapperBuilder.get_args
def get_args(self): """ Use this context manager to add arguments to an argparse object with the add_argument method. Arguments must be defined before the command is defined. Note that no-clean and resume are added upon exit and should not be added in the context manager. For mor...
python
def get_args(self): """ Use this context manager to add arguments to an argparse object with the add_argument method. Arguments must be defined before the command is defined. Note that no-clean and resume are added upon exit and should not be added in the context manager. For mor...
[ "def", "get_args", "(", "self", ")", ":", "parser", "=", "argparse", ".", "ArgumentParser", "(", "description", "=", "self", ".", "_desc", ",", "formatter_class", "=", "MyUniversalHelpFormatter", ")", "# default args", "if", "self", ".", "_no_clean", ":", "par...
Use this context manager to add arguments to an argparse object with the add_argument method. Arguments must be defined before the command is defined. Note that no-clean and resume are added upon exit and should not be added in the context manager. For more info about these default arguments see...
[ "Use", "this", "context", "manager", "to", "add", "arguments", "to", "an", "argparse", "object", "with", "the", "add_argument", "method", ".", "Arguments", "must", "be", "defined", "before", "the", "command", "is", "defined", ".", "Note", "that", "no", "-", ...
06310682c50dcf8917b912c8e551299ff7ee41ce
https://github.com/BD2KGenomics/protect/blob/06310682c50dcf8917b912c8e551299ff7ee41ce/docker/pipelineWrapper.py#L170-L188
train
Returns an argparse. ArgumentParser object that can be used to add command line arguments to the context manager.
StackStorm/pybind
pybind/nos/v6_0_2f/interface/gigabitethernet/qos/rcv_queue/__init__.py
rcv_queue._set_cos_threshold
def _set_cos_threshold(self, v, load=False): """ Setter method for cos_threshold, mapped from YANG variable /interface/gigabitethernet/qos/rcv_queue/cos_threshold (container) If this variable is read-only (config: false) in the source YANG file, then _set_cos_threshold is considered as a private met...
python
def _set_cos_threshold(self, v, load=False): """ Setter method for cos_threshold, mapped from YANG variable /interface/gigabitethernet/qos/rcv_queue/cos_threshold (container) If this variable is read-only (config: false) in the source YANG file, then _set_cos_threshold is considered as a private met...
[ "def", "_set_cos_threshold", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass", "(", "v", ",", "...
Setter method for cos_threshold, mapped from YANG variable /interface/gigabitethernet/qos/rcv_queue/cos_threshold (container) If this variable is read-only (config: false) in the source YANG file, then _set_cos_threshold is considered as a private method. Backends looking to populate this variable should ...
[ "Setter", "method", "for", "cos_threshold", "mapped", "from", "YANG", "variable", "/", "interface", "/", "gigabitethernet", "/", "qos", "/", "rcv_queue", "/", "cos_threshold", "(", "container", ")", "If", "this", "variable", "is", "read", "-", "only", "(", "...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/nos/v6_0_2f/interface/gigabitethernet/qos/rcv_queue/__init__.py#L96-L119
train
Sets the cos_threshold of the
BD2KGenomics/protect
src/protect/rankboost.py
wrap_rankboost
def wrap_rankboost(job, rsem_files, merged_mhc_calls, transgene_out, univ_options, rankboost_options): """ A wrapper for boost_ranks. :param dict rsem_files: Dict of results from rsem :param dict merged_mhc_calls: Dict of results from merging mhc peptide binding predictions :para...
python
def wrap_rankboost(job, rsem_files, merged_mhc_calls, transgene_out, univ_options, rankboost_options): """ A wrapper for boost_ranks. :param dict rsem_files: Dict of results from rsem :param dict merged_mhc_calls: Dict of results from merging mhc peptide binding predictions :para...
[ "def", "wrap_rankboost", "(", "job", ",", "rsem_files", ",", "merged_mhc_calls", ",", "transgene_out", ",", "univ_options", ",", "rankboost_options", ")", ":", "rankboost", "=", "job", ".", "addChildJobFn", "(", "boost_ranks", ",", "rsem_files", "[", "'rsem.isofor...
A wrapper for boost_ranks. :param dict rsem_files: Dict of results from rsem :param dict merged_mhc_calls: Dict of results from merging mhc peptide binding predictions :param dict transgene_out: Dict of results from running Transgene :param dict univ_options: Dict of universal options used by almost al...
[ "A", "wrapper", "for", "boost_ranks", "." ]
06310682c50dcf8917b912c8e551299ff7ee41ce
https://github.com/BD2KGenomics/protect/blob/06310682c50dcf8917b912c8e551299ff7ee41ce/src/protect/rankboost.py#L21-L42
train
A wrapper for boost_ranks.
BD2KGenomics/protect
src/protect/rankboost.py
boost_ranks
def boost_ranks(job, isoform_expression, merged_mhc_calls, transgene_out, univ_options, rankboost_options): """ Boost the ranks of the predicted peptides:MHC combinations. :param toil.fileStore.FileID isoform_expression: fsID of rsem isoform expression file :param dict merged_mhc_calls:...
python
def boost_ranks(job, isoform_expression, merged_mhc_calls, transgene_out, univ_options, rankboost_options): """ Boost the ranks of the predicted peptides:MHC combinations. :param toil.fileStore.FileID isoform_expression: fsID of rsem isoform expression file :param dict merged_mhc_calls:...
[ "def", "boost_ranks", "(", "job", ",", "isoform_expression", ",", "merged_mhc_calls", ",", "transgene_out", ",", "univ_options", ",", "rankboost_options", ")", ":", "work_dir", "=", "os", ".", "getcwd", "(", ")", "input_files", "=", "{", "'rsem_quant.tsv'", ":",...
Boost the ranks of the predicted peptides:MHC combinations. :param toil.fileStore.FileID isoform_expression: fsID of rsem isoform expression file :param dict merged_mhc_calls: Dict of results from merging mhc peptide binding predictions :param dict transgene_out: Dict of results from running Transgene ...
[ "Boost", "the", "ranks", "of", "the", "predicted", "peptides", ":", "MHC", "combinations", "." ]
06310682c50dcf8917b912c8e551299ff7ee41ce
https://github.com/BD2KGenomics/protect/blob/06310682c50dcf8917b912c8e551299ff7ee41ce/src/protect/rankboost.py#L45-L100
train
Boost the ranks of the predicted peptides of the MHC combinations.
StackStorm/pybind
pybind/nos/v6_0_2f/brocade_vcs_rpc/show_vcs/output/__init__.py
output._set_vcs_cluster_type_info
def _set_vcs_cluster_type_info(self, v, load=False): """ Setter method for vcs_cluster_type_info, mapped from YANG variable /brocade_vcs_rpc/show_vcs/output/vcs_cluster_type_info (vcs-cluster-type) If this variable is read-only (config: false) in the source YANG file, then _set_vcs_cluster_type_info is ...
python
def _set_vcs_cluster_type_info(self, v, load=False): """ Setter method for vcs_cluster_type_info, mapped from YANG variable /brocade_vcs_rpc/show_vcs/output/vcs_cluster_type_info (vcs-cluster-type) If this variable is read-only (config: false) in the source YANG file, then _set_vcs_cluster_type_info is ...
[ "def", "_set_vcs_cluster_type_info", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass", "(", "v", ...
Setter method for vcs_cluster_type_info, mapped from YANG variable /brocade_vcs_rpc/show_vcs/output/vcs_cluster_type_info (vcs-cluster-type) If this variable is read-only (config: false) in the source YANG file, then _set_vcs_cluster_type_info is considered as a private method. Backends looking to populate ...
[ "Setter", "method", "for", "vcs_cluster_type_info", "mapped", "from", "YANG", "variable", "/", "brocade_vcs_rpc", "/", "show_vcs", "/", "output", "/", "vcs_cluster_type_info", "(", "vcs", "-", "cluster", "-", "type", ")", "If", "this", "variable", "is", "read", ...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/nos/v6_0_2f/brocade_vcs_rpc/show_vcs/output/__init__.py#L178-L201
train
Sets the type of the cluster.
StackStorm/pybind
pybind/slxos/v17r_1_01a/mpls_config/router/mpls/mpls_cmds_holder/autobw_template/__init__.py
autobw_template._set_adjustment_threshold
def _set_adjustment_threshold(self, v, load=False): """ Setter method for adjustment_threshold, mapped from YANG variable /mpls_config/router/mpls/mpls_cmds_holder/autobw_template/adjustment_threshold (container) If this variable is read-only (config: false) in the source YANG file, then _set_adjustment...
python
def _set_adjustment_threshold(self, v, load=False): """ Setter method for adjustment_threshold, mapped from YANG variable /mpls_config/router/mpls/mpls_cmds_holder/autobw_template/adjustment_threshold (container) If this variable is read-only (config: false) in the source YANG file, then _set_adjustment...
[ "def", "_set_adjustment_threshold", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass", "(", "v", "...
Setter method for adjustment_threshold, mapped from YANG variable /mpls_config/router/mpls/mpls_cmds_holder/autobw_template/adjustment_threshold (container) If this variable is read-only (config: false) in the source YANG file, then _set_adjustment_threshold is considered as a private method. Backends looki...
[ "Setter", "method", "for", "adjustment_threshold", "mapped", "from", "YANG", "variable", "/", "mpls_config", "/", "router", "/", "mpls", "/", "mpls_cmds_holder", "/", "autobw_template", "/", "adjustment_threshold", "(", "container", ")", "If", "this", "variable", ...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/slxos/v17r_1_01a/mpls_config/router/mpls/mpls_cmds_holder/autobw_template/__init__.py#L171-L192
train
Sets the adjustment threshold for the
StackStorm/pybind
pybind/nos/v6_0_2f/nas/server_ip/__init__.py
server_ip._set_vrf
def _set_vrf(self, v, load=False): """ Setter method for vrf, mapped from YANG variable /nas/server_ip/vrf (list) If this variable is read-only (config: false) in the source YANG file, then _set_vrf is considered as a private method. Backends looking to populate this variable should do so via ca...
python
def _set_vrf(self, v, load=False): """ Setter method for vrf, mapped from YANG variable /nas/server_ip/vrf (list) If this variable is read-only (config: false) in the source YANG file, then _set_vrf is considered as a private method. Backends looking to populate this variable should do so via ca...
[ "def", "_set_vrf", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass", "(", "v", ",", "base", "...
Setter method for vrf, mapped from YANG variable /nas/server_ip/vrf (list) If this variable is read-only (config: false) in the source YANG file, then _set_vrf is considered as a private method. Backends looking to populate this variable should do so via calling thisObj._set_vrf() directly.
[ "Setter", "method", "for", "vrf", "mapped", "from", "YANG", "variable", "/", "nas", "/", "server_ip", "/", "vrf", "(", "list", ")", "If", "this", "variable", "is", "read", "-", "only", "(", "config", ":", "false", ")", "in", "the", "source", "YANG", ...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/nos/v6_0_2f/nas/server_ip/__init__.py#L133-L154
train
Set the vrf of the
budacom/trading-bots
trading_bots/bots/registry.py
BotRegistry._path_from_module
def _path_from_module(module): """Attempt to determine bot's filesystem path from its module.""" # Convert paths to list because Python's _NamespacePath doesn't support # indexing. paths = list(getattr(module, '__path__', [])) if len(paths) != 1: filename = getattr(mo...
python
def _path_from_module(module): """Attempt to determine bot's filesystem path from its module.""" # Convert paths to list because Python's _NamespacePath doesn't support # indexing. paths = list(getattr(module, '__path__', [])) if len(paths) != 1: filename = getattr(mo...
[ "def", "_path_from_module", "(", "module", ")", ":", "# Convert paths to list because Python's _NamespacePath doesn't support", "# indexing.", "paths", "=", "list", "(", "getattr", "(", "module", ",", "'__path__'", ",", "[", "]", ")", ")", "if", "len", "(", "paths",...
Attempt to determine bot's filesystem path from its module.
[ "Attempt", "to", "determine", "bot", "s", "filesystem", "path", "from", "its", "module", "." ]
8cb68bb8d0b5f822108db1cc5dae336e3d3c3452
https://github.com/budacom/trading-bots/blob/8cb68bb8d0b5f822108db1cc5dae336e3d3c3452/trading_bots/bots/registry.py#L58-L81
train
Attempt to determine bot s filesystem path from its module.
budacom/trading-bots
trading_bots/bots/registry.py
BotRegistry.create
def create(cls, entry): """ Factory that creates an bot config from an entry in INSTALLED_APPS. """ # trading_bots.example.bot.ExampleBot try: # If import_module succeeds, entry is a path to a bot module, # which may specify a bot class with a default_bot ...
python
def create(cls, entry): """ Factory that creates an bot config from an entry in INSTALLED_APPS. """ # trading_bots.example.bot.ExampleBot try: # If import_module succeeds, entry is a path to a bot module, # which may specify a bot class with a default_bot ...
[ "def", "create", "(", "cls", ",", "entry", ")", ":", "# trading_bots.example.bot.ExampleBot", "try", ":", "# If import_module succeeds, entry is a path to a bot module,", "# which may specify a bot class with a default_bot attribute.", "# Otherwise, entry is a path to a bot class or an err...
Factory that creates an bot config from an entry in INSTALLED_APPS.
[ "Factory", "that", "creates", "an", "bot", "config", "from", "an", "entry", "in", "INSTALLED_APPS", "." ]
8cb68bb8d0b5f822108db1cc5dae336e3d3c3452
https://github.com/budacom/trading-bots/blob/8cb68bb8d0b5f822108db1cc5dae336e3d3c3452/trading_bots/bots/registry.py#L84-L136
train
Creates an instance of the appropriate bot class based on the entry.
budacom/trading-bots
trading_bots/bots/registry.py
BotRegistry.get_config
def get_config(self, config_name, require_ready=True): """ Return the config with the given case-insensitive config_name. Raise LookupError if no config exists with this name. """ if require_ready: self.bots.check_configs_ready() else: self.bots.ch...
python
def get_config(self, config_name, require_ready=True): """ Return the config with the given case-insensitive config_name. Raise LookupError if no config exists with this name. """ if require_ready: self.bots.check_configs_ready() else: self.bots.ch...
[ "def", "get_config", "(", "self", ",", "config_name", ",", "require_ready", "=", "True", ")", ":", "if", "require_ready", ":", "self", ".", "bots", ".", "check_configs_ready", "(", ")", "else", ":", "self", ".", "bots", ".", "check_bots_ready", "(", ")", ...
Return the config with the given case-insensitive config_name. Raise LookupError if no config exists with this name.
[ "Return", "the", "config", "with", "the", "given", "case", "-", "insensitive", "config_name", ".", "Raise", "LookupError", "if", "no", "config", "exists", "with", "this", "name", "." ]
8cb68bb8d0b5f822108db1cc5dae336e3d3c3452
https://github.com/budacom/trading-bots/blob/8cb68bb8d0b5f822108db1cc5dae336e3d3c3452/trading_bots/bots/registry.py#L138-L148
train
Get a config with the given case - insensitive config_name. Raise LookupError if no config with the given case - insensitive config_name exists.
budacom/trading-bots
trading_bots/bots/registry.py
BotRegistry.get_configs
def get_configs(self): """ Return an iterable of models. """ self.bots.check_models_ready() for config in self.configs.values(): yield config
python
def get_configs(self): """ Return an iterable of models. """ self.bots.check_models_ready() for config in self.configs.values(): yield config
[ "def", "get_configs", "(", "self", ")", ":", "self", ".", "bots", ".", "check_models_ready", "(", ")", "for", "config", "in", "self", ".", "configs", ".", "values", "(", ")", ":", "yield", "config" ]
Return an iterable of models.
[ "Return", "an", "iterable", "of", "models", "." ]
8cb68bb8d0b5f822108db1cc5dae336e3d3c3452
https://github.com/budacom/trading-bots/blob/8cb68bb8d0b5f822108db1cc5dae336e3d3c3452/trading_bots/bots/registry.py#L150-L156
train
Return an iterable of models.
budacom/trading-bots
trading_bots/bots/registry.py
Bots.populate
def populate(self, installed_bots=None): """ Load bots. Import each bot module. It is thread-safe and idempotent, but not re-entrant. """ if self.ready: return # populate() might be called by two threads in parallel on servers # that create th...
python
def populate(self, installed_bots=None): """ Load bots. Import each bot module. It is thread-safe and idempotent, but not re-entrant. """ if self.ready: return # populate() might be called by two threads in parallel on servers # that create th...
[ "def", "populate", "(", "self", ",", "installed_bots", "=", "None", ")", ":", "if", "self", ".", "ready", ":", "return", "# populate() might be called by two threads in parallel on servers", "# that create threads before initializing the WSGI callable.", "with", "self", ".", ...
Load bots. Import each bot module. It is thread-safe and idempotent, but not re-entrant.
[ "Load", "bots", ".", "Import", "each", "bot", "module", ".", "It", "is", "thread", "-", "safe", "and", "idempotent", "but", "not", "re", "-", "entrant", "." ]
8cb68bb8d0b5f822108db1cc5dae336e3d3c3452
https://github.com/budacom/trading-bots/blob/8cb68bb8d0b5f822108db1cc5dae336e3d3c3452/trading_bots/bots/registry.py#L199-L254
train
Populate the internal state of the object with the current state of the AppConfig.
budacom/trading-bots
trading_bots/bots/registry.py
Bots.get_bot
def get_bot(self, bot_label): """ Import all bots and returns a bot class for the given label. Raise LookupError if no bot exists with this label. """ self.check_bots_ready() try: return self.bots[bot_label] except KeyError: message = "No i...
python
def get_bot(self, bot_label): """ Import all bots and returns a bot class for the given label. Raise LookupError if no bot exists with this label. """ self.check_bots_ready() try: return self.bots[bot_label] except KeyError: message = "No i...
[ "def", "get_bot", "(", "self", ",", "bot_label", ")", ":", "self", ".", "check_bots_ready", "(", ")", "try", ":", "return", "self", ".", "bots", "[", "bot_label", "]", "except", "KeyError", ":", "message", "=", "\"No installed bot with label '%s'.\"", "%", "...
Import all bots and returns a bot class for the given label. Raise LookupError if no bot exists with this label.
[ "Import", "all", "bots", "and", "returns", "a", "bot", "class", "for", "the", "given", "label", ".", "Raise", "LookupError", "if", "no", "bot", "exists", "with", "this", "label", "." ]
8cb68bb8d0b5f822108db1cc5dae336e3d3c3452
https://github.com/budacom/trading-bots/blob/8cb68bb8d0b5f822108db1cc5dae336e3d3c3452/trading_bots/bots/registry.py#L271-L285
train
Returns a bot class for the given label. Raise LookupError if no bot exists with the given label.
budacom/trading-bots
trading_bots/bots/registry.py
Bots.get_configs
def get_configs(self): """ Return a list of all installed configs. """ self.check_configs_ready() result = [] for bot in self.bots.values(): result.extend(list(bot.get_models())) return result
python
def get_configs(self): """ Return a list of all installed configs. """ self.check_configs_ready() result = [] for bot in self.bots.values(): result.extend(list(bot.get_models())) return result
[ "def", "get_configs", "(", "self", ")", ":", "self", ".", "check_configs_ready", "(", ")", "result", "=", "[", "]", "for", "bot", "in", "self", ".", "bots", ".", "values", "(", ")", ":", "result", ".", "extend", "(", "list", "(", "bot", ".", "get_m...
Return a list of all installed configs.
[ "Return", "a", "list", "of", "all", "installed", "configs", "." ]
8cb68bb8d0b5f822108db1cc5dae336e3d3c3452
https://github.com/budacom/trading-bots/blob/8cb68bb8d0b5f822108db1cc5dae336e3d3c3452/trading_bots/bots/registry.py#L287-L296
train
Return a list of all installed configs.
budacom/trading-bots
trading_bots/bots/registry.py
Bots.get_config
def get_config(self, bot_label, config_name=None, require_ready=True): """ Return the config matching the given bot_label and config_name. config_name is case-insensitive. Raise LookupError if no bot exists with this label, or no config exists with this name in the bot. Raise Val...
python
def get_config(self, bot_label, config_name=None, require_ready=True): """ Return the config matching the given bot_label and config_name. config_name is case-insensitive. Raise LookupError if no bot exists with this label, or no config exists with this name in the bot. Raise Val...
[ "def", "get_config", "(", "self", ",", "bot_label", ",", "config_name", "=", "None", ",", "require_ready", "=", "True", ")", ":", "if", "require_ready", ":", "self", ".", "check_configs_ready", "(", ")", "else", ":", "self", ".", "check_bots_ready", "(", "...
Return the config matching the given bot_label and config_name. config_name is case-insensitive. Raise LookupError if no bot exists with this label, or no config exists with this name in the bot. Raise ValueError if called with a single argument that doesn't contain exactly one dot.
[ "Return", "the", "config", "matching", "the", "given", "bot_label", "and", "config_name", ".", "config_name", "is", "case", "-", "insensitive", ".", "Raise", "LookupError", "if", "no", "bot", "exists", "with", "this", "label", "or", "no", "config", "exists", ...
8cb68bb8d0b5f822108db1cc5dae336e3d3c3452
https://github.com/budacom/trading-bots/blob/8cb68bb8d0b5f822108db1cc5dae336e3d3c3452/trading_bots/bots/registry.py#L298-L319
train
Get a config from the given bot and name.
budacom/trading-bots
trading_bots/bots/registry.py
Bots.is_installed
def is_installed(self, bot_name): """ Check whether a bot with this name exists in the registry. bot_name is the full name of the bot e.g. 'trading_bots.core.bot'. """ self.check_bots_ready() return any(b.name == bot_name for b in self.bots.values())
python
def is_installed(self, bot_name): """ Check whether a bot with this name exists in the registry. bot_name is the full name of the bot e.g. 'trading_bots.core.bot'. """ self.check_bots_ready() return any(b.name == bot_name for b in self.bots.values())
[ "def", "is_installed", "(", "self", ",", "bot_name", ")", ":", "self", ".", "check_bots_ready", "(", ")", "return", "any", "(", "b", ".", "name", "==", "bot_name", "for", "b", "in", "self", ".", "bots", ".", "values", "(", ")", ")" ]
Check whether a bot with this name exists in the registry. bot_name is the full name of the bot e.g. 'trading_bots.core.bot'.
[ "Check", "whether", "a", "bot", "with", "this", "name", "exists", "in", "the", "registry", ".", "bot_name", "is", "the", "full", "name", "of", "the", "bot", "e", ".", "g", ".", "trading_bots", ".", "core", ".", "bot", "." ]
8cb68bb8d0b5f822108db1cc5dae336e3d3c3452
https://github.com/budacom/trading-bots/blob/8cb68bb8d0b5f822108db1cc5dae336e3d3c3452/trading_bots/bots/registry.py#L328-L334
train
Check whether a bot with this name exists in the registry.
StackStorm/pybind
pybind/nos/v6_0_2f/logging/auditlog/__init__.py
auditlog._set_class_
def _set_class_(self, v, load=False): """ Setter method for class_, mapped from YANG variable /logging/auditlog/class (list) If this variable is read-only (config: false) in the source YANG file, then _set_class_ is considered as a private method. Backends looking to populate this variable should ...
python
def _set_class_(self, v, load=False): """ Setter method for class_, mapped from YANG variable /logging/auditlog/class (list) If this variable is read-only (config: false) in the source YANG file, then _set_class_ is considered as a private method. Backends looking to populate this variable should ...
[ "def", "_set_class_", "(", "self", ",", "v", ",", "load", "=", "False", ")", ":", "if", "hasattr", "(", "v", ",", "\"_utype\"", ")", ":", "v", "=", "v", ".", "_utype", "(", "v", ")", "try", ":", "t", "=", "YANGDynClass", "(", "v", ",", "base", ...
Setter method for class_, mapped from YANG variable /logging/auditlog/class (list) If this variable is read-only (config: false) in the source YANG file, then _set_class_ is considered as a private method. Backends looking to populate this variable should do so via calling thisObj._set_class_() directly...
[ "Setter", "method", "for", "class_", "mapped", "from", "YANG", "variable", "/", "logging", "/", "auditlog", "/", "class", "(", "list", ")", "If", "this", "variable", "is", "read", "-", "only", "(", "config", ":", "false", ")", "in", "the", "source", "Y...
44c467e71b2b425be63867aba6e6fa28b2cfe7fb
https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/nos/v6_0_2f/logging/auditlog/__init__.py#L92-L113
train
Set the class of the based on the given list of class values.
mjj4791/python-buienradar
buienradar/buienradar_json.py
__to_float
def __to_float(val, digits): """Convert val into float with digits decimal.""" try: return round(float(val), digits) except (ValueError, TypeError): return float(0)
python
def __to_float(val, digits): """Convert val into float with digits decimal.""" try: return round(float(val), digits) except (ValueError, TypeError): return float(0)
[ "def", "__to_float", "(", "val", ",", "digits", ")", ":", "try", ":", "return", "round", "(", "float", "(", "val", ")", ",", "digits", ")", "except", "(", "ValueError", ",", "TypeError", ")", ":", "return", "float", "(", "0", ")" ]
Convert val into float with digits decimal.
[ "Convert", "val", "into", "float", "with", "digits", "decimal", "." ]
a70436f54e007ce921d5210cb296cf3e4adf9d09
https://github.com/mjj4791/python-buienradar/blob/a70436f54e007ce921d5210cb296cf3e4adf9d09/buienradar/buienradar_json.py#L97-L102
train
Convert val into float with digits decimal.
mjj4791/python-buienradar
buienradar/buienradar_json.py
__getBarFC
def __getBarFC(pressure): """Parse the pressure and return FC (numerical).""" if pressure is None: return 0 press = __to_float1(pressure) if press < 974: return 1 if press < 990: return 2 if press < 1002: return 3 if press < 1010: return 4 if press...
python
def __getBarFC(pressure): """Parse the pressure and return FC (numerical).""" if pressure is None: return 0 press = __to_float1(pressure) if press < 974: return 1 if press < 990: return 2 if press < 1002: return 3 if press < 1010: return 4 if press...
[ "def", "__getBarFC", "(", "pressure", ")", ":", "if", "pressure", "is", "None", ":", "return", "0", "press", "=", "__to_float1", "(", "pressure", ")", "if", "press", "<", "974", ":", "return", "1", "if", "press", "<", "990", ":", "return", "2", "if",...
Parse the pressure and return FC (numerical).
[ "Parse", "the", "pressure", "and", "return", "FC", "(", "numerical", ")", "." ]
a70436f54e007ce921d5210cb296cf3e4adf9d09
https://github.com/mjj4791/python-buienradar/blob/a70436f54e007ce921d5210cb296cf3e4adf9d09/buienradar/buienradar_json.py#L126-L143
train
Parse the pressure and return FC ( numerical ).
mjj4791/python-buienradar
buienradar/buienradar_json.py
__getBarFCName
def __getBarFCName(pressure): """Parse the pressure and return FC (String).""" if pressure is None: return None press = __to_float1(pressure) if press < 974: return "Thunderstorms" if press < 990: return "Stormy" if press < 1002: return "Rain" if press < 1010:...
python
def __getBarFCName(pressure): """Parse the pressure and return FC (String).""" if pressure is None: return None press = __to_float1(pressure) if press < 974: return "Thunderstorms" if press < 990: return "Stormy" if press < 1002: return "Rain" if press < 1010:...
[ "def", "__getBarFCName", "(", "pressure", ")", ":", "if", "pressure", "is", "None", ":", "return", "None", "press", "=", "__to_float1", "(", "pressure", ")", "if", "press", "<", "974", ":", "return", "\"Thunderstorms\"", "if", "press", "<", "990", ":", "...
Parse the pressure and return FC (String).
[ "Parse", "the", "pressure", "and", "return", "FC", "(", "String", ")", "." ]
a70436f54e007ce921d5210cb296cf3e4adf9d09
https://github.com/mjj4791/python-buienradar/blob/a70436f54e007ce921d5210cb296cf3e4adf9d09/buienradar/buienradar_json.py#L146-L163
train
Parse the pressure and return FC ( String.
mjj4791/python-buienradar
buienradar/buienradar_json.py
get_json_data
def get_json_data(latitude=52.091579, longitude=5.119734): """Get buienradar json data and return results.""" final_result = {SUCCESS: False, MESSAGE: None, CONTENT: None, RAINCONTENT: None} log.info("Getting buienradar json data for latitude=%s, ...
python
def get_json_data(latitude=52.091579, longitude=5.119734): """Get buienradar json data and return results.""" final_result = {SUCCESS: False, MESSAGE: None, CONTENT: None, RAINCONTENT: None} log.info("Getting buienradar json data for latitude=%s, ...
[ "def", "get_json_data", "(", "latitude", "=", "52.091579", ",", "longitude", "=", "5.119734", ")", ":", "final_result", "=", "{", "SUCCESS", ":", "False", ",", "MESSAGE", ":", "None", ",", "CONTENT", ":", "None", ",", "RAINCONTENT", ":", "None", "}", "lo...
Get buienradar json data and return results.
[ "Get", "buienradar", "json", "data", "and", "return", "results", "." ]
a70436f54e007ce921d5210cb296cf3e4adf9d09
https://github.com/mjj4791/python-buienradar/blob/a70436f54e007ce921d5210cb296cf3e4adf9d09/buienradar/buienradar_json.py#L194-L238
train
Get buienradar json data and return results.