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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
mjj4791/python-buienradar | buienradar/buienradar_json.py | parse_json_data | def parse_json_data(content, raincontent, latitude=52.091579,
longitude=5.119734, timeframe=60):
"""Parse the raw data and return as data dictionary."""
result = {SUCCESS: False, MESSAGE: None, DATA: None}
if timeframe < 5 or timeframe > 120:
raise ValueError("Timeframe must be ... | python | def parse_json_data(content, raincontent, latitude=52.091579,
longitude=5.119734, timeframe=60):
"""Parse the raw data and return as data dictionary."""
result = {SUCCESS: False, MESSAGE: None, DATA: None}
if timeframe < 5 or timeframe > 120:
raise ValueError("Timeframe must be ... | [
"def",
"parse_json_data",
"(",
"content",
",",
"raincontent",
",",
"latitude",
"=",
"52.091579",
",",
"longitude",
"=",
"5.119734",
",",
"timeframe",
"=",
"60",
")",
":",
"result",
"=",
"{",
"SUCCESS",
":",
"False",
",",
"MESSAGE",
":",
"None",
",",
"DAT... | Parse the raw data and return as data dictionary. | [
"Parse",
"the",
"raw",
"data",
"and",
"return",
"as",
"data",
"dictionary",
"."
] | a70436f54e007ce921d5210cb296cf3e4adf9d09 | https://github.com/mjj4791/python-buienradar/blob/a70436f54e007ce921d5210cb296cf3e4adf9d09/buienradar/buienradar_json.py#L241-L264 | train | Parse the raw data and return as data dictionary. |
mjj4791/python-buienradar | buienradar/buienradar_json.py | __get_precipfc_data | def __get_precipfc_data(latitude, longitude):
"""Get buienradar forecasted precipitation."""
url = 'https://gpsgadget.buienradar.nl/data/raintext?lat={}&lon={}'
# rounding coordinates prevents unnecessary redirects/calls
url = url.format(
round(latitude, 2),
round(longitude, 2)
)
... | python | def __get_precipfc_data(latitude, longitude):
"""Get buienradar forecasted precipitation."""
url = 'https://gpsgadget.buienradar.nl/data/raintext?lat={}&lon={}'
# rounding coordinates prevents unnecessary redirects/calls
url = url.format(
round(latitude, 2),
round(longitude, 2)
)
... | [
"def",
"__get_precipfc_data",
"(",
"latitude",
",",
"longitude",
")",
":",
"url",
"=",
"'https://gpsgadget.buienradar.nl/data/raintext?lat={}&lon={}'",
"# rounding coordinates prevents unnecessary redirects/calls",
"url",
"=",
"url",
".",
"format",
"(",
"round",
"(",
"latitud... | Get buienradar forecasted precipitation. | [
"Get",
"buienradar",
"forecasted",
"precipitation",
"."
] | a70436f54e007ce921d5210cb296cf3e4adf9d09 | https://github.com/mjj4791/python-buienradar/blob/a70436f54e007ce921d5210cb296cf3e4adf9d09/buienradar/buienradar_json.py#L276-L285 | train | Get buienradar forecasted precipitation. |
mjj4791/python-buienradar | buienradar/buienradar_json.py | __get_url | def __get_url(url):
"""Load json data from url and return result."""
log.info("Retrieving weather data (%s)...", url)
result = {SUCCESS: False, MESSAGE: None}
try:
r = requests.get(url)
result[STATUS_CODE] = r.status_code
result[HEADERS] = r.headers
result[CONTENT] = r.t... | python | def __get_url(url):
"""Load json data from url and return result."""
log.info("Retrieving weather data (%s)...", url)
result = {SUCCESS: False, MESSAGE: None}
try:
r = requests.get(url)
result[STATUS_CODE] = r.status_code
result[HEADERS] = r.headers
result[CONTENT] = r.t... | [
"def",
"__get_url",
"(",
"url",
")",
":",
"log",
".",
"info",
"(",
"\"Retrieving weather data (%s)...\"",
",",
"url",
")",
"result",
"=",
"{",
"SUCCESS",
":",
"False",
",",
"MESSAGE",
":",
"None",
"}",
"try",
":",
"r",
"=",
"requests",
".",
"get",
"("... | Load json data from url and return result. | [
"Load",
"json",
"data",
"from",
"url",
"and",
"return",
"result",
"."
] | a70436f54e007ce921d5210cb296cf3e4adf9d09 | https://github.com/mjj4791/python-buienradar/blob/a70436f54e007ce921d5210cb296cf3e4adf9d09/buienradar/buienradar_json.py#L288-L306 | train | Load json data from url and return result. |
mjj4791/python-buienradar | buienradar/buienradar_json.py | __parse_ws_data | def __parse_ws_data(jsondata, latitude=52.091579, longitude=5.119734):
"""Parse the buienradar json and rain data."""
log.info("Parse ws data: latitude: %s, longitude: %s", latitude, longitude)
result = {SUCCESS: False, MESSAGE: None, DATA: None}
# select the nearest weather station
loc_data = __se... | python | def __parse_ws_data(jsondata, latitude=52.091579, longitude=5.119734):
"""Parse the buienradar json and rain data."""
log.info("Parse ws data: latitude: %s, longitude: %s", latitude, longitude)
result = {SUCCESS: False, MESSAGE: None, DATA: None}
# select the nearest weather station
loc_data = __se... | [
"def",
"__parse_ws_data",
"(",
"jsondata",
",",
"latitude",
"=",
"52.091579",
",",
"longitude",
"=",
"5.119734",
")",
":",
"log",
".",
"info",
"(",
"\"Parse ws data: latitude: %s, longitude: %s\"",
",",
"latitude",
",",
"longitude",
")",
"result",
"=",
"{",
"SUC... | Parse the buienradar json and rain data. | [
"Parse",
"the",
"buienradar",
"json",
"and",
"rain",
"data",
"."
] | a70436f54e007ce921d5210cb296cf3e4adf9d09 | https://github.com/mjj4791/python-buienradar/blob/a70436f54e007ce921d5210cb296cf3e4adf9d09/buienradar/buienradar_json.py#L309-L344 | train | Parse the buienradar json and rain data. |
mjj4791/python-buienradar | buienradar/buienradar_json.py | __parse_loc_data | def __parse_loc_data(loc_data, result):
"""Parse the json data from selected weatherstation."""
result[DATA] = {ATTRIBUTION: ATTRIBUTION_INFO,
FORECAST: [],
PRECIPITATION_FORECAST: None}
for key, [value, func] in SENSOR_TYPES.items():
result[DATA][key] = None... | python | def __parse_loc_data(loc_data, result):
"""Parse the json data from selected weatherstation."""
result[DATA] = {ATTRIBUTION: ATTRIBUTION_INFO,
FORECAST: [],
PRECIPITATION_FORECAST: None}
for key, [value, func] in SENSOR_TYPES.items():
result[DATA][key] = None... | [
"def",
"__parse_loc_data",
"(",
"loc_data",
",",
"result",
")",
":",
"result",
"[",
"DATA",
"]",
"=",
"{",
"ATTRIBUTION",
":",
"ATTRIBUTION_INFO",
",",
"FORECAST",
":",
"[",
"]",
",",
"PRECIPITATION_FORECAST",
":",
"None",
"}",
"for",
"key",
",",
"[",
"v... | Parse the json data from selected weatherstation. | [
"Parse",
"the",
"json",
"data",
"from",
"selected",
"weatherstation",
"."
] | a70436f54e007ce921d5210cb296cf3e4adf9d09 | https://github.com/mjj4791/python-buienradar/blob/a70436f54e007ce921d5210cb296cf3e4adf9d09/buienradar/buienradar_json.py#L347-L379 | train | Parse the json data from selected weatherstation. |
mjj4791/python-buienradar | buienradar/buienradar_json.py | __parse_fc_data | def __parse_fc_data(fc_data):
"""Parse the forecast data from the json section."""
fc = []
for day in fc_data:
fcdata = {
CONDITION: __cond_from_desc(
__get_str(
day,
__WEATHERDESCRIPTION)
),
TEMPERATURE: __g... | python | def __parse_fc_data(fc_data):
"""Parse the forecast data from the json section."""
fc = []
for day in fc_data:
fcdata = {
CONDITION: __cond_from_desc(
__get_str(
day,
__WEATHERDESCRIPTION)
),
TEMPERATURE: __g... | [
"def",
"__parse_fc_data",
"(",
"fc_data",
")",
":",
"fc",
"=",
"[",
"]",
"for",
"day",
"in",
"fc_data",
":",
"fcdata",
"=",
"{",
"CONDITION",
":",
"__cond_from_desc",
"(",
"__get_str",
"(",
"day",
",",
"__WEATHERDESCRIPTION",
")",
")",
",",
"TEMPERATURE",
... | Parse the forecast data from the json section. | [
"Parse",
"the",
"forecast",
"data",
"from",
"the",
"json",
"section",
"."
] | a70436f54e007ce921d5210cb296cf3e4adf9d09 | https://github.com/mjj4791/python-buienradar/blob/a70436f54e007ce921d5210cb296cf3e4adf9d09/buienradar/buienradar_json.py#L382-L408 | train | Parse the forecast data from the json section. |
mjj4791/python-buienradar | buienradar/buienradar_json.py | __get_float | def __get_float(section, name):
"""Get the forecasted float from json section."""
try:
return float(section[name])
except (ValueError, TypeError, KeyError):
return float(0) | python | def __get_float(section, name):
"""Get the forecasted float from json section."""
try:
return float(section[name])
except (ValueError, TypeError, KeyError):
return float(0) | [
"def",
"__get_float",
"(",
"section",
",",
"name",
")",
":",
"try",
":",
"return",
"float",
"(",
"section",
"[",
"name",
"]",
")",
"except",
"(",
"ValueError",
",",
"TypeError",
",",
"KeyError",
")",
":",
"return",
"float",
"(",
"0",
")"
] | Get the forecasted float from json section. | [
"Get",
"the",
"forecasted",
"float",
"from",
"json",
"section",
"."
] | a70436f54e007ce921d5210cb296cf3e4adf9d09 | https://github.com/mjj4791/python-buienradar/blob/a70436f54e007ce921d5210cb296cf3e4adf9d09/buienradar/buienradar_json.py#L419-L424 | train | Get the forecasted float from json section. |
mjj4791/python-buienradar | buienradar/buienradar_json.py | __parse_precipfc_data | def __parse_precipfc_data(data, timeframe):
"""Parse the forecasted precipitation data."""
result = {AVERAGE: None, TOTAL: None, TIMEFRAME: None}
log.debug("Precipitation data: %s", data)
lines = data.splitlines()
index = 1
totalrain = 0
numberoflines = 0
nrlines = min(len(lines), round... | python | def __parse_precipfc_data(data, timeframe):
"""Parse the forecasted precipitation data."""
result = {AVERAGE: None, TOTAL: None, TIMEFRAME: None}
log.debug("Precipitation data: %s", data)
lines = data.splitlines()
index = 1
totalrain = 0
numberoflines = 0
nrlines = min(len(lines), round... | [
"def",
"__parse_precipfc_data",
"(",
"data",
",",
"timeframe",
")",
":",
"result",
"=",
"{",
"AVERAGE",
":",
"None",
",",
"TOTAL",
":",
"None",
",",
"TIMEFRAME",
":",
"None",
"}",
"log",
".",
"debug",
"(",
"\"Precipitation data: %s\"",
",",
"data",
")",
... | Parse the forecasted precipitation data. | [
"Parse",
"the",
"forecasted",
"precipitation",
"data",
"."
] | a70436f54e007ce921d5210cb296cf3e4adf9d09 | https://github.com/mjj4791/python-buienradar/blob/a70436f54e007ce921d5210cb296cf3e4adf9d09/buienradar/buienradar_json.py#L435-L480 | train | Parse the forecasted precipitation data. |
mjj4791/python-buienradar | buienradar/buienradar_json.py | __cond_from_desc | def __cond_from_desc(desc):
"""Get the condition name from the condition description."""
# '{ 'code': 'conditon', 'detailed', 'exact', 'exact_nl'}
for code, [condition, detailed, exact, exact_nl] in __BRCONDITIONS.items():
if exact_nl == desc:
return {CONDCODE: code,
... | python | def __cond_from_desc(desc):
"""Get the condition name from the condition description."""
# '{ 'code': 'conditon', 'detailed', 'exact', 'exact_nl'}
for code, [condition, detailed, exact, exact_nl] in __BRCONDITIONS.items():
if exact_nl == desc:
return {CONDCODE: code,
... | [
"def",
"__cond_from_desc",
"(",
"desc",
")",
":",
"# '{ 'code': 'conditon', 'detailed', 'exact', 'exact_nl'}",
"for",
"code",
",",
"[",
"condition",
",",
"detailed",
",",
"exact",
",",
"exact_nl",
"]",
"in",
"__BRCONDITIONS",
".",
"items",
"(",
")",
":",
"if",
"... | Get the condition name from the condition description. | [
"Get",
"the",
"condition",
"name",
"from",
"the",
"condition",
"description",
"."
] | a70436f54e007ce921d5210cb296cf3e4adf9d09 | https://github.com/mjj4791/python-buienradar/blob/a70436f54e007ce921d5210cb296cf3e4adf9d09/buienradar/buienradar_json.py#L483-L494 | train | Get the condition name from the condition description. |
mjj4791/python-buienradar | buienradar/buienradar_json.py | __select_nearest_ws | def __select_nearest_ws(jsondata, latitude, longitude):
"""Select the nearest weatherstation."""
log.debug("__select_nearest_ws: latitude: %s, longitude: %s",
latitude, longitude)
dist = 0
dist2 = 0
loc_data = None
try:
ws_json = jsondata[__ACTUAL]
ws_json = ws_jso... | python | def __select_nearest_ws(jsondata, latitude, longitude):
"""Select the nearest weatherstation."""
log.debug("__select_nearest_ws: latitude: %s, longitude: %s",
latitude, longitude)
dist = 0
dist2 = 0
loc_data = None
try:
ws_json = jsondata[__ACTUAL]
ws_json = ws_jso... | [
"def",
"__select_nearest_ws",
"(",
"jsondata",
",",
"latitude",
",",
"longitude",
")",
":",
"log",
".",
"debug",
"(",
"\"__select_nearest_ws: latitude: %s, longitude: %s\"",
",",
"latitude",
",",
"longitude",
")",
"dist",
"=",
"0",
"dist2",
"=",
"0",
"loc_data",
... | Select the nearest weatherstation. | [
"Select",
"the",
"nearest",
"weatherstation",
"."
] | a70436f54e007ce921d5210cb296cf3e4adf9d09 | https://github.com/mjj4791/python-buienradar/blob/a70436f54e007ce921d5210cb296cf3e4adf9d09/buienradar/buienradar_json.py#L497-L535 | train | Select the nearest weatherstation in the xmldata. |
mjj4791/python-buienradar | buienradar/buienradar_json.py | __get_ws_distance | def __get_ws_distance(wstation, latitude, longitude):
"""Get the distance to the weatherstation from wstation section of json.
wstation: weerstation section of buienradar json (dict)
latitude: our latitude
longitude: our longitude
"""
if wstation:
try:
wslat = float(wstation... | python | def __get_ws_distance(wstation, latitude, longitude):
"""Get the distance to the weatherstation from wstation section of json.
wstation: weerstation section of buienradar json (dict)
latitude: our latitude
longitude: our longitude
"""
if wstation:
try:
wslat = float(wstation... | [
"def",
"__get_ws_distance",
"(",
"wstation",
",",
"latitude",
",",
"longitude",
")",
":",
"if",
"wstation",
":",
"try",
":",
"wslat",
"=",
"float",
"(",
"wstation",
"[",
"__LAT",
"]",
")",
"wslon",
"=",
"float",
"(",
"wstation",
"[",
"__LON",
"]",
")",... | Get the distance to the weatherstation from wstation section of json.
wstation: weerstation section of buienradar json (dict)
latitude: our latitude
longitude: our longitude | [
"Get",
"the",
"distance",
"to",
"the",
"weatherstation",
"from",
"wstation",
"section",
"of",
"json",
"."
] | a70436f54e007ce921d5210cb296cf3e4adf9d09 | https://github.com/mjj4791/python-buienradar/blob/a70436f54e007ce921d5210cb296cf3e4adf9d09/buienradar/buienradar_json.py#L538-L559 | train | Get the distance to the weatherstation from the json. |
mjj4791/python-buienradar | buienradar/buienradar_json.py | __getStationName | def __getStationName(name, id):
"""Construct a staiion name."""
name = name.replace("Meetstation", "")
name = name.strip()
name += " (%s)" % id
return name | python | def __getStationName(name, id):
"""Construct a staiion name."""
name = name.replace("Meetstation", "")
name = name.strip()
name += " (%s)" % id
return name | [
"def",
"__getStationName",
"(",
"name",
",",
"id",
")",
":",
"name",
"=",
"name",
".",
"replace",
"(",
"\"Meetstation\"",
",",
"\"\"",
")",
"name",
"=",
"name",
".",
"strip",
"(",
")",
"name",
"+=",
"\" (%s)\"",
"%",
"id",
"return",
"name"
] | Construct a staiion name. | [
"Construct",
"a",
"staiion",
"name",
"."
] | a70436f54e007ce921d5210cb296cf3e4adf9d09 | https://github.com/mjj4791/python-buienradar/blob/a70436f54e007ce921d5210cb296cf3e4adf9d09/buienradar/buienradar_json.py#L575-L580 | train | Construct a staiion name. |
stephrdev/django-formwizard | formwizard/views.py | WizardView.as_view | def as_view(cls, *args, **kwargs):
"""
This method is used within urls.py to create unique formwizard
instances for every request. We need to override this method because
we add some kwargs which are needed to make the formwizard usable.
"""
initkwargs = cls.get_initkwarg... | python | def as_view(cls, *args, **kwargs):
"""
This method is used within urls.py to create unique formwizard
instances for every request. We need to override this method because
we add some kwargs which are needed to make the formwizard usable.
"""
initkwargs = cls.get_initkwarg... | [
"def",
"as_view",
"(",
"cls",
",",
"*",
"args",
",",
"*",
"*",
"kwargs",
")",
":",
"initkwargs",
"=",
"cls",
".",
"get_initkwargs",
"(",
"*",
"args",
",",
"*",
"*",
"kwargs",
")",
"return",
"super",
"(",
"WizardView",
",",
"cls",
")",
".",
"as_view... | This method is used within urls.py to create unique formwizard
instances for every request. We need to override this method because
we add some kwargs which are needed to make the formwizard usable. | [
"This",
"method",
"is",
"used",
"within",
"urls",
".",
"py",
"to",
"create",
"unique",
"formwizard",
"instances",
"for",
"every",
"request",
".",
"We",
"need",
"to",
"override",
"this",
"method",
"because",
"we",
"add",
"some",
"kwargs",
"which",
"are",
"n... | 7b35165f0340aae4e8302d5b05b0cb443f6c9904 | https://github.com/stephrdev/django-formwizard/blob/7b35165f0340aae4e8302d5b05b0cb443f6c9904/formwizard/views.py#L103-L110 | train | Override as_view to add additional kwargs to the queryset. |
stephrdev/django-formwizard | formwizard/views.py | WizardView.get_initkwargs | def get_initkwargs(cls, form_list, initial_dict=None,
instance_dict=None, condition_dict=None, *args, **kwargs):
"""
Creates a dict with all needed parameters for the form wizard instances.
* `form_list` - is a list of forms. The list entries can be single form
classes or tupl... | python | def get_initkwargs(cls, form_list, initial_dict=None,
instance_dict=None, condition_dict=None, *args, **kwargs):
"""
Creates a dict with all needed parameters for the form wizard instances.
* `form_list` - is a list of forms. The list entries can be single form
classes or tupl... | [
"def",
"get_initkwargs",
"(",
"cls",
",",
"form_list",
",",
"initial_dict",
"=",
"None",
",",
"instance_dict",
"=",
"None",
",",
"condition_dict",
"=",
"None",
",",
"*",
"args",
",",
"*",
"*",
"kwargs",
")",
":",
"kwargs",
".",
"update",
"(",
"{",
"'in... | Creates a dict with all needed parameters for the form wizard instances.
* `form_list` - is a list of forms. The list entries can be single form
classes or tuples of (`step_name`, `form_class`). If you pass a list
of forms, the formwizard will convert the class list to
(`zero_base... | [
"Creates",
"a",
"dict",
"with",
"all",
"needed",
"parameters",
"for",
"the",
"form",
"wizard",
"instances",
"."
] | 7b35165f0340aae4e8302d5b05b0cb443f6c9904 | https://github.com/stephrdev/django-formwizard/blob/7b35165f0340aae4e8302d5b05b0cb443f6c9904/formwizard/views.py#L113-L170 | train | Returns a dict with all needed keyword arguments for the form wizard instances. |
stephrdev/django-formwizard | formwizard/views.py | WizardView.get_form_list | def get_form_list(self):
"""
This method returns a form_list based on the initial form list but
checks if there is a condition method/value in the condition_list.
If an entry exists in the condition list, it will call/read the value
and respect the result. (True means add the for... | python | def get_form_list(self):
"""
This method returns a form_list based on the initial form list but
checks if there is a condition method/value in the condition_list.
If an entry exists in the condition list, it will call/read the value
and respect the result. (True means add the for... | [
"def",
"get_form_list",
"(",
"self",
")",
":",
"form_list",
"=",
"SortedDict",
"(",
")",
"for",
"form_key",
",",
"form_class",
"in",
"self",
".",
"form_list",
".",
"iteritems",
"(",
")",
":",
"# try to fetch the value from condition list, by default, the form",
"# g... | This method returns a form_list based on the initial form list but
checks if there is a condition method/value in the condition_list.
If an entry exists in the condition list, it will call/read the value
and respect the result. (True means add the form, False means ignore
the form)
... | [
"This",
"method",
"returns",
"a",
"form_list",
"based",
"on",
"the",
"initial",
"form",
"list",
"but",
"checks",
"if",
"there",
"is",
"a",
"condition",
"method",
"/",
"value",
"in",
"the",
"condition_list",
".",
"If",
"an",
"entry",
"exists",
"in",
"the",
... | 7b35165f0340aae4e8302d5b05b0cb443f6c9904 | https://github.com/stephrdev/django-formwizard/blob/7b35165f0340aae4e8302d5b05b0cb443f6c9904/formwizard/views.py#L179-L200 | train | This method returns a list of all the form classes that are set in the initial form list. |
stephrdev/django-formwizard | formwizard/views.py | WizardView.dispatch | def dispatch(self, request, *args, **kwargs):
"""
This method gets called by the routing engine. The first argument is
`request` which contains a `HttpRequest` instance.
The request is stored in `self.request` for later use. The storage
instance is stored in `self.storage`.
... | python | def dispatch(self, request, *args, **kwargs):
"""
This method gets called by the routing engine. The first argument is
`request` which contains a `HttpRequest` instance.
The request is stored in `self.request` for later use. The storage
instance is stored in `self.storage`.
... | [
"def",
"dispatch",
"(",
"self",
",",
"request",
",",
"*",
"args",
",",
"*",
"*",
"kwargs",
")",
":",
"# add the storage engine to the current formwizard instance",
"self",
".",
"wizard_name",
"=",
"self",
".",
"get_wizard_name",
"(",
")",
"self",
".",
"prefix",
... | This method gets called by the routing engine. The first argument is
`request` which contains a `HttpRequest` instance.
The request is stored in `self.request` for later use. The storage
instance is stored in `self.storage`.
After processing the request using the `dispatch` method, the
... | [
"This",
"method",
"gets",
"called",
"by",
"the",
"routing",
"engine",
".",
"The",
"first",
"argument",
"is",
"request",
"which",
"contains",
"a",
"HttpRequest",
"instance",
".",
"The",
"request",
"is",
"stored",
"in",
"self",
".",
"request",
"for",
"later",
... | 7b35165f0340aae4e8302d5b05b0cb443f6c9904 | https://github.com/stephrdev/django-formwizard/blob/7b35165f0340aae4e8302d5b05b0cb443f6c9904/formwizard/views.py#L202-L222 | train | This method gets called by the controller s dispatch method. |
stephrdev/django-formwizard | formwizard/views.py | WizardView.get | def get(self, request, *args, **kwargs):
"""
This method handles GET requests.
If a GET request reaches this point, the wizard assumes that the user
just starts at the first step or wants to restart the process.
The data of the wizard will be resetted before rendering the first ... | python | def get(self, request, *args, **kwargs):
"""
This method handles GET requests.
If a GET request reaches this point, the wizard assumes that the user
just starts at the first step or wants to restart the process.
The data of the wizard will be resetted before rendering the first ... | [
"def",
"get",
"(",
"self",
",",
"request",
",",
"*",
"args",
",",
"*",
"*",
"kwargs",
")",
":",
"self",
".",
"storage",
".",
"reset",
"(",
")",
"# reset the current step to the first step.",
"self",
".",
"storage",
".",
"current_step",
"=",
"self",
".",
... | This method handles GET requests.
If a GET request reaches this point, the wizard assumes that the user
just starts at the first step or wants to restart the process.
The data of the wizard will be resetted before rendering the first step. | [
"This",
"method",
"handles",
"GET",
"requests",
"."
] | 7b35165f0340aae4e8302d5b05b0cb443f6c9904 | https://github.com/stephrdev/django-formwizard/blob/7b35165f0340aae4e8302d5b05b0cb443f6c9904/formwizard/views.py#L224-L236 | train | This method handles GET requests. |
stephrdev/django-formwizard | formwizard/views.py | WizardView.post | def post(self, *args, **kwargs):
"""
This method handles POST requests.
The wizard will render either the current step (if form validation
wasn't successful), the next step (if the current step was stored
successful) or the done view (if no more steps are available)
"""
... | python | def post(self, *args, **kwargs):
"""
This method handles POST requests.
The wizard will render either the current step (if form validation
wasn't successful), the next step (if the current step was stored
successful) or the done view (if no more steps are available)
"""
... | [
"def",
"post",
"(",
"self",
",",
"*",
"args",
",",
"*",
"*",
"kwargs",
")",
":",
"# Look for a wizard_prev_step element in the posted data which",
"# contains a valid step name. If one was found, render the requested",
"# form. (This makes stepping back a lot easier).",
"wizard_prev_... | This method handles POST requests.
The wizard will render either the current step (if form validation
wasn't successful), the next step (if the current step was stored
successful) or the done view (if no more steps are available) | [
"This",
"method",
"handles",
"POST",
"requests",
"."
] | 7b35165f0340aae4e8302d5b05b0cb443f6c9904 | https://github.com/stephrdev/django-formwizard/blob/7b35165f0340aae4e8302d5b05b0cb443f6c9904/formwizard/views.py#L238-L285 | train | This method handles POST requests. |
stephrdev/django-formwizard | formwizard/views.py | WizardView.render_next_step | def render_next_step(self, form, **kwargs):
"""
THis method gets called when the next step/form should be rendered.
`form` contains the last/current form.
"""
# get the form instance based on the data from the storage backend
# (if available).
next_step = self.ste... | python | def render_next_step(self, form, **kwargs):
"""
THis method gets called when the next step/form should be rendered.
`form` contains the last/current form.
"""
# get the form instance based on the data from the storage backend
# (if available).
next_step = self.ste... | [
"def",
"render_next_step",
"(",
"self",
",",
"form",
",",
"*",
"*",
"kwargs",
")",
":",
"# get the form instance based on the data from the storage backend",
"# (if available).",
"next_step",
"=",
"self",
".",
"steps",
".",
"next",
"new_form",
"=",
"self",
".",
"get... | THis method gets called when the next step/form should be rendered.
`form` contains the last/current form. | [
"THis",
"method",
"gets",
"called",
"when",
"the",
"next",
"step",
"/",
"form",
"should",
"be",
"rendered",
".",
"form",
"contains",
"the",
"last",
"/",
"current",
"form",
"."
] | 7b35165f0340aae4e8302d5b05b0cb443f6c9904 | https://github.com/stephrdev/django-formwizard/blob/7b35165f0340aae4e8302d5b05b0cb443f6c9904/formwizard/views.py#L287-L301 | train | This method gets called when the next step should be rendered. It gets called when the next step should be rendered. |
stephrdev/django-formwizard | formwizard/views.py | WizardView.render_done | def render_done(self, form, **kwargs):
"""
This method gets called when all forms passed. The method should also
re-validate all steps to prevent manipulation. If any form don't
validate, `render_revalidation_failure` should get called.
If everything is fine call `done`.
... | python | def render_done(self, form, **kwargs):
"""
This method gets called when all forms passed. The method should also
re-validate all steps to prevent manipulation. If any form don't
validate, `render_revalidation_failure` should get called.
If everything is fine call `done`.
... | [
"def",
"render_done",
"(",
"self",
",",
"form",
",",
"*",
"*",
"kwargs",
")",
":",
"final_form_list",
"=",
"[",
"]",
"# walk through the form list and try to validate the data again.",
"for",
"form_key",
"in",
"self",
".",
"get_form_list",
"(",
")",
":",
"form_obj... | This method gets called when all forms passed. The method should also
re-validate all steps to prevent manipulation. If any form don't
validate, `render_revalidation_failure` should get called.
If everything is fine call `done`. | [
"This",
"method",
"gets",
"called",
"when",
"all",
"forms",
"passed",
".",
"The",
"method",
"should",
"also",
"re",
"-",
"validate",
"all",
"steps",
"to",
"prevent",
"manipulation",
".",
"If",
"any",
"form",
"don",
"t",
"validate",
"render_revalidation_failure... | 7b35165f0340aae4e8302d5b05b0cb443f6c9904 | https://github.com/stephrdev/django-formwizard/blob/7b35165f0340aae4e8302d5b05b0cb443f6c9904/formwizard/views.py#L303-L325 | train | This method gets called when all forms passed and all steps passed. |
stephrdev/django-formwizard | formwizard/views.py | WizardView.get_form_prefix | def get_form_prefix(self, step=None, form=None):
"""
Returns the prefix which will be used when calling the actual form for
the given step. `step` contains the step-name, `form` the form which
will be called with the returned prefix.
If no step is given, the form_prefix will det... | python | def get_form_prefix(self, step=None, form=None):
"""
Returns the prefix which will be used when calling the actual form for
the given step. `step` contains the step-name, `form` the form which
will be called with the returned prefix.
If no step is given, the form_prefix will det... | [
"def",
"get_form_prefix",
"(",
"self",
",",
"step",
"=",
"None",
",",
"form",
"=",
"None",
")",
":",
"if",
"step",
"is",
"None",
":",
"step",
"=",
"self",
".",
"steps",
".",
"current",
"return",
"str",
"(",
"step",
")"
] | Returns the prefix which will be used when calling the actual form for
the given step. `step` contains the step-name, `form` the form which
will be called with the returned prefix.
If no step is given, the form_prefix will determine the current step
automatically. | [
"Returns",
"the",
"prefix",
"which",
"will",
"be",
"used",
"when",
"calling",
"the",
"actual",
"form",
"for",
"the",
"given",
"step",
".",
"step",
"contains",
"the",
"step",
"-",
"name",
"form",
"the",
"form",
"which",
"will",
"be",
"called",
"with",
"th... | 7b35165f0340aae4e8302d5b05b0cb443f6c9904 | https://github.com/stephrdev/django-formwizard/blob/7b35165f0340aae4e8302d5b05b0cb443f6c9904/formwizard/views.py#L327-L338 | train | Returns the form prefix for the given step. |
stephrdev/django-formwizard | formwizard/views.py | WizardView.get_form | def get_form(self, step=None, data=None, files=None):
"""
Constructs the form for a given `step`. If no `step` is defined, the
current step will be determined automatically.
The form will be initialized using the `data` argument to prefill the
new form. If needed, instance or qu... | python | def get_form(self, step=None, data=None, files=None):
"""
Constructs the form for a given `step`. If no `step` is defined, the
current step will be determined automatically.
The form will be initialized using the `data` argument to prefill the
new form. If needed, instance or qu... | [
"def",
"get_form",
"(",
"self",
",",
"step",
"=",
"None",
",",
"data",
"=",
"None",
",",
"files",
"=",
"None",
")",
":",
"if",
"step",
"is",
"None",
":",
"step",
"=",
"self",
".",
"steps",
".",
"current",
"# prepare the kwargs for the form instance.",
"k... | Constructs the form for a given `step`. If no `step` is defined, the
current step will be determined automatically.
The form will be initialized using the `data` argument to prefill the
new form. If needed, instance or queryset (for `ModelForm` or
`ModelFormSet`) will be added too. | [
"Constructs",
"the",
"form",
"for",
"a",
"given",
"step",
".",
"If",
"no",
"step",
"is",
"defined",
"the",
"current",
"step",
"will",
"be",
"determined",
"automatically",
"."
] | 7b35165f0340aae4e8302d5b05b0cb443f6c9904 | https://github.com/stephrdev/django-formwizard/blob/7b35165f0340aae4e8302d5b05b0cb443f6c9904/formwizard/views.py#L363-L388 | train | Constructs the form for a given step. |
stephrdev/django-formwizard | formwizard/views.py | WizardView.render_revalidation_failure | def render_revalidation_failure(self, step, form, **kwargs):
"""
Gets called when a form doesn't validate when rendering the done
view. By default, it changed the current step to failing forms step
and renders the form.
"""
self.storage.current_step = step
return ... | python | def render_revalidation_failure(self, step, form, **kwargs):
"""
Gets called when a form doesn't validate when rendering the done
view. By default, it changed the current step to failing forms step
and renders the form.
"""
self.storage.current_step = step
return ... | [
"def",
"render_revalidation_failure",
"(",
"self",
",",
"step",
",",
"form",
",",
"*",
"*",
"kwargs",
")",
":",
"self",
".",
"storage",
".",
"current_step",
"=",
"step",
"return",
"self",
".",
"render",
"(",
"form",
",",
"*",
"*",
"kwargs",
")"
] | Gets called when a form doesn't validate when rendering the done
view. By default, it changed the current step to failing forms step
and renders the form. | [
"Gets",
"called",
"when",
"a",
"form",
"doesn",
"t",
"validate",
"when",
"rendering",
"the",
"done",
"view",
".",
"By",
"default",
"it",
"changed",
"the",
"current",
"step",
"to",
"failing",
"forms",
"step",
"and",
"renders",
"the",
"form",
"."
] | 7b35165f0340aae4e8302d5b05b0cb443f6c9904 | https://github.com/stephrdev/django-formwizard/blob/7b35165f0340aae4e8302d5b05b0cb443f6c9904/formwizard/views.py#L404-L411 | train | Render the form for a revalidation failure. |
stephrdev/django-formwizard | formwizard/views.py | WizardView.get_all_cleaned_data | def get_all_cleaned_data(self):
"""
Returns a merged dictionary of all step cleaned_data dictionaries.
If a step contains a `FormSet`, the key will be prefixed with formset
and contain a list of the formset' cleaned_data dictionaries.
"""
cleaned_data = {}
for for... | python | def get_all_cleaned_data(self):
"""
Returns a merged dictionary of all step cleaned_data dictionaries.
If a step contains a `FormSet`, the key will be prefixed with formset
and contain a list of the formset' cleaned_data dictionaries.
"""
cleaned_data = {}
for for... | [
"def",
"get_all_cleaned_data",
"(",
"self",
")",
":",
"cleaned_data",
"=",
"{",
"}",
"for",
"form_key",
"in",
"self",
".",
"get_form_list",
"(",
")",
":",
"form_obj",
"=",
"self",
".",
"get_form",
"(",
"step",
"=",
"form_key",
",",
"data",
"=",
"self",
... | Returns a merged dictionary of all step cleaned_data dictionaries.
If a step contains a `FormSet`, the key will be prefixed with formset
and contain a list of the formset' cleaned_data dictionaries. | [
"Returns",
"a",
"merged",
"dictionary",
"of",
"all",
"step",
"cleaned_data",
"dictionaries",
".",
"If",
"a",
"step",
"contains",
"a",
"FormSet",
"the",
"key",
"will",
"be",
"prefixed",
"with",
"formset",
"and",
"contain",
"a",
"list",
"of",
"the",
"formset",... | 7b35165f0340aae4e8302d5b05b0cb443f6c9904 | https://github.com/stephrdev/django-formwizard/blob/7b35165f0340aae4e8302d5b05b0cb443f6c9904/formwizard/views.py#L427-L447 | train | Returns a merged dictionary of all step cleaned_data dictionaries. |
stephrdev/django-formwizard | formwizard/views.py | WizardView.get_cleaned_data_for_step | def get_cleaned_data_for_step(self, step):
"""
Returns the cleaned data for a given `step`. Before returning the
cleaned data, the stored values are being revalidated through the
form. If the data doesn't validate, None will be returned.
"""
if step in self.form_list:
... | python | def get_cleaned_data_for_step(self, step):
"""
Returns the cleaned data for a given `step`. Before returning the
cleaned data, the stored values are being revalidated through the
form. If the data doesn't validate, None will be returned.
"""
if step in self.form_list:
... | [
"def",
"get_cleaned_data_for_step",
"(",
"self",
",",
"step",
")",
":",
"if",
"step",
"in",
"self",
".",
"form_list",
":",
"form_obj",
"=",
"self",
".",
"get_form",
"(",
"step",
"=",
"step",
",",
"data",
"=",
"self",
".",
"storage",
".",
"get_step_data",... | Returns the cleaned data for a given `step`. Before returning the
cleaned data, the stored values are being revalidated through the
form. If the data doesn't validate, None will be returned. | [
"Returns",
"the",
"cleaned",
"data",
"for",
"a",
"given",
"step",
".",
"Before",
"returning",
"the",
"cleaned",
"data",
"the",
"stored",
"values",
"are",
"being",
"revalidated",
"through",
"the",
"form",
".",
"If",
"the",
"data",
"doesn",
"t",
"validate",
... | 7b35165f0340aae4e8302d5b05b0cb443f6c9904 | https://github.com/stephrdev/django-formwizard/blob/7b35165f0340aae4e8302d5b05b0cb443f6c9904/formwizard/views.py#L449-L461 | train | Returns the cleaned data for a given step. |
stephrdev/django-formwizard | formwizard/views.py | WizardView.get_next_step | def get_next_step(self, step=None):
"""
Returns the next step after the given `step`. If no more steps are
available, None will be returned. If the `step` argument is None, the
current step will be determined automatically.
"""
if step is None:
step = self.ste... | python | def get_next_step(self, step=None):
"""
Returns the next step after the given `step`. If no more steps are
available, None will be returned. If the `step` argument is None, the
current step will be determined automatically.
"""
if step is None:
step = self.ste... | [
"def",
"get_next_step",
"(",
"self",
",",
"step",
"=",
"None",
")",
":",
"if",
"step",
"is",
"None",
":",
"step",
"=",
"self",
".",
"steps",
".",
"current",
"form_list",
"=",
"self",
".",
"get_form_list",
"(",
")",
"key",
"=",
"form_list",
".",
"keyO... | Returns the next step after the given `step`. If no more steps are
available, None will be returned. If the `step` argument is None, the
current step will be determined automatically. | [
"Returns",
"the",
"next",
"step",
"after",
"the",
"given",
"step",
".",
"If",
"no",
"more",
"steps",
"are",
"available",
"None",
"will",
"be",
"returned",
".",
"If",
"the",
"step",
"argument",
"is",
"None",
"the",
"current",
"step",
"will",
"be",
"determ... | 7b35165f0340aae4e8302d5b05b0cb443f6c9904 | https://github.com/stephrdev/django-formwizard/blob/7b35165f0340aae4e8302d5b05b0cb443f6c9904/formwizard/views.py#L463-L475 | train | Returns the next step after the given step. |
stephrdev/django-formwizard | formwizard/views.py | WizardView.get_prev_step | def get_prev_step(self, step=None):
"""
Returns the previous step before the given `step`. If there are no
steps available, None will be returned. If the `step` argument is
None, the current step will be determined automatically.
"""
if step is None:
step = se... | python | def get_prev_step(self, step=None):
"""
Returns the previous step before the given `step`. If there are no
steps available, None will be returned. If the `step` argument is
None, the current step will be determined automatically.
"""
if step is None:
step = se... | [
"def",
"get_prev_step",
"(",
"self",
",",
"step",
"=",
"None",
")",
":",
"if",
"step",
"is",
"None",
":",
"step",
"=",
"self",
".",
"steps",
".",
"current",
"form_list",
"=",
"self",
".",
"get_form_list",
"(",
")",
"key",
"=",
"form_list",
".",
"keyO... | Returns the previous step before the given `step`. If there are no
steps available, None will be returned. If the `step` argument is
None, the current step will be determined automatically. | [
"Returns",
"the",
"previous",
"step",
"before",
"the",
"given",
"step",
".",
"If",
"there",
"are",
"no",
"steps",
"available",
"None",
"will",
"be",
"returned",
".",
"If",
"the",
"step",
"argument",
"is",
"None",
"the",
"current",
"step",
"will",
"be",
"... | 7b35165f0340aae4e8302d5b05b0cb443f6c9904 | https://github.com/stephrdev/django-formwizard/blob/7b35165f0340aae4e8302d5b05b0cb443f6c9904/formwizard/views.py#L477-L489 | train | Returns the previous step before the given step. |
stephrdev/django-formwizard | formwizard/views.py | WizardView.get_step_index | def get_step_index(self, step=None):
"""
Returns the index for the given `step` name. If no step is given,
the current step will be used to get the index.
"""
if step is None:
step = self.steps.current
return self.get_form_list().keyOrder.index(step) | python | def get_step_index(self, step=None):
"""
Returns the index for the given `step` name. If no step is given,
the current step will be used to get the index.
"""
if step is None:
step = self.steps.current
return self.get_form_list().keyOrder.index(step) | [
"def",
"get_step_index",
"(",
"self",
",",
"step",
"=",
"None",
")",
":",
"if",
"step",
"is",
"None",
":",
"step",
"=",
"self",
".",
"steps",
".",
"current",
"return",
"self",
".",
"get_form_list",
"(",
")",
".",
"keyOrder",
".",
"index",
"(",
"step"... | Returns the index for the given `step` name. If no step is given,
the current step will be used to get the index. | [
"Returns",
"the",
"index",
"for",
"the",
"given",
"step",
"name",
".",
"If",
"no",
"step",
"is",
"given",
"the",
"current",
"step",
"will",
"be",
"used",
"to",
"get",
"the",
"index",
"."
] | 7b35165f0340aae4e8302d5b05b0cb443f6c9904 | https://github.com/stephrdev/django-formwizard/blob/7b35165f0340aae4e8302d5b05b0cb443f6c9904/formwizard/views.py#L491-L498 | train | Returns the index for the given step name. |
stephrdev/django-formwizard | formwizard/views.py | WizardView.get_context_data | def get_context_data(self, form, *args, **kwargs):
"""
Returns the template context for a step. You can overwrite this method
to add more data for all or some steps. This method returns a
dictionary containing the rendered form step. Available template
context variables are:
... | python | def get_context_data(self, form, *args, **kwargs):
"""
Returns the template context for a step. You can overwrite this method
to add more data for all or some steps. This method returns a
dictionary containing the rendered form step. Available template
context variables are:
... | [
"def",
"get_context_data",
"(",
"self",
",",
"form",
",",
"*",
"args",
",",
"*",
"*",
"kwargs",
")",
":",
"context",
"=",
"super",
"(",
"WizardView",
",",
"self",
")",
".",
"get_context_data",
"(",
"*",
"args",
",",
"*",
"*",
"kwargs",
")",
"context"... | Returns the template context for a step. You can overwrite this method
to add more data for all or some steps. This method returns a
dictionary containing the rendered form step. Available template
context variables are:
* all extra data stored in the storage backend
* `form` ... | [
"Returns",
"the",
"template",
"context",
"for",
"a",
"step",
".",
"You",
"can",
"overwrite",
"this",
"method",
"to",
"add",
"more",
"data",
"for",
"all",
"or",
"some",
"steps",
".",
"This",
"method",
"returns",
"a",
"dictionary",
"containing",
"the",
"rend... | 7b35165f0340aae4e8302d5b05b0cb443f6c9904 | https://github.com/stephrdev/django-formwizard/blob/7b35165f0340aae4e8302d5b05b0cb443f6c9904/formwizard/views.py#L500-L531 | train | Returns the template context for a step. |
stephrdev/django-formwizard | formwizard/views.py | WizardView.render | def render(self, form=None, **kwargs):
"""
Returns a ``HttpResponse`` containing a all needed context data.
"""
form = form or self.get_form()
context = self.get_context_data(form, **kwargs)
return self.render_to_response(context) | python | def render(self, form=None, **kwargs):
"""
Returns a ``HttpResponse`` containing a all needed context data.
"""
form = form or self.get_form()
context = self.get_context_data(form, **kwargs)
return self.render_to_response(context) | [
"def",
"render",
"(",
"self",
",",
"form",
"=",
"None",
",",
"*",
"*",
"kwargs",
")",
":",
"form",
"=",
"form",
"or",
"self",
".",
"get_form",
"(",
")",
"context",
"=",
"self",
".",
"get_context_data",
"(",
"form",
",",
"*",
"*",
"kwargs",
")",
"... | Returns a ``HttpResponse`` containing a all needed context data. | [
"Returns",
"a",
"HttpResponse",
"containing",
"a",
"all",
"needed",
"context",
"data",
"."
] | 7b35165f0340aae4e8302d5b05b0cb443f6c9904 | https://github.com/stephrdev/django-formwizard/blob/7b35165f0340aae4e8302d5b05b0cb443f6c9904/formwizard/views.py#L533-L539 | train | Returns a HttpResponse containing a all needed context data. |
stephrdev/django-formwizard | formwizard/views.py | NamedUrlWizardView.get_initkwargs | def get_initkwargs(cls, *args, **kwargs):
"""
We require a url_name to reverse URLs later. Additionally users can
pass a done_step_name to change the URL name of the "done" view.
"""
assert 'url_name' in kwargs, 'URL name is needed to resolve correct wizard URLs'
extra_kw... | python | def get_initkwargs(cls, *args, **kwargs):
"""
We require a url_name to reverse URLs later. Additionally users can
pass a done_step_name to change the URL name of the "done" view.
"""
assert 'url_name' in kwargs, 'URL name is needed to resolve correct wizard URLs'
extra_kw... | [
"def",
"get_initkwargs",
"(",
"cls",
",",
"*",
"args",
",",
"*",
"*",
"kwargs",
")",
":",
"assert",
"'url_name'",
"in",
"kwargs",
",",
"'URL name is needed to resolve correct wizard URLs'",
"extra_kwargs",
"=",
"{",
"'done_step_name'",
":",
"kwargs",
".",
"pop",
... | We require a url_name to reverse URLs later. Additionally users can
pass a done_step_name to change the URL name of the "done" view. | [
"We",
"require",
"a",
"url_name",
"to",
"reverse",
"URLs",
"later",
".",
"Additionally",
"users",
"can",
"pass",
"a",
"done_step_name",
"to",
"change",
"the",
"URL",
"name",
"of",
"the",
"done",
"view",
"."
] | 7b35165f0340aae4e8302d5b05b0cb443f6c9904 | https://github.com/stephrdev/django-formwizard/blob/7b35165f0340aae4e8302d5b05b0cb443f6c9904/formwizard/views.py#L572-L588 | train | Override get_initkwargs to add done_step_name to the url_name. |
stephrdev/django-formwizard | formwizard/views.py | NamedUrlWizardView.get | def get(self, *args, **kwargs):
"""
This renders the form or, if needed, does the http redirects.
"""
step_url = kwargs.get('step', None)
if step_url is None:
if 'reset' in self.request.GET:
self.storage.reset()
self.storage.current_ste... | python | def get(self, *args, **kwargs):
"""
This renders the form or, if needed, does the http redirects.
"""
step_url = kwargs.get('step', None)
if step_url is None:
if 'reset' in self.request.GET:
self.storage.reset()
self.storage.current_ste... | [
"def",
"get",
"(",
"self",
",",
"*",
"args",
",",
"*",
"*",
"kwargs",
")",
":",
"step_url",
"=",
"kwargs",
".",
"get",
"(",
"'step'",
",",
"None",
")",
"if",
"step_url",
"is",
"None",
":",
"if",
"'reset'",
"in",
"self",
".",
"request",
".",
"GET"... | This renders the form or, if needed, does the http redirects. | [
"This",
"renders",
"the",
"form",
"or",
"if",
"needed",
"does",
"the",
"http",
"redirects",
"."
] | 7b35165f0340aae4e8302d5b05b0cb443f6c9904 | https://github.com/stephrdev/django-formwizard/blob/7b35165f0340aae4e8302d5b05b0cb443f6c9904/formwizard/views.py#L590-L635 | train | This method renders the form or does the http redirects. |
stephrdev/django-formwizard | formwizard/views.py | NamedUrlWizardView.post | def post(self, *args, **kwargs):
"""
Do a redirect if user presses the prev. step button. The rest of this
is super'd from FormWizard.
"""
prev_step = self.request.POST.get('wizard_prev_step', None)
if prev_step and prev_step in self.get_form_list():
self.stor... | python | def post(self, *args, **kwargs):
"""
Do a redirect if user presses the prev. step button. The rest of this
is super'd from FormWizard.
"""
prev_step = self.request.POST.get('wizard_prev_step', None)
if prev_step and prev_step in self.get_form_list():
self.stor... | [
"def",
"post",
"(",
"self",
",",
"*",
"args",
",",
"*",
"*",
"kwargs",
")",
":",
"prev_step",
"=",
"self",
".",
"request",
".",
"POST",
".",
"get",
"(",
"'wizard_prev_step'",
",",
"None",
")",
"if",
"prev_step",
"and",
"prev_step",
"in",
"self",
".",... | Do a redirect if user presses the prev. step button. The rest of this
is super'd from FormWizard. | [
"Do",
"a",
"redirect",
"if",
"user",
"presses",
"the",
"prev",
".",
"step",
"button",
".",
"The",
"rest",
"of",
"this",
"is",
"super",
"d",
"from",
"FormWizard",
"."
] | 7b35165f0340aae4e8302d5b05b0cb443f6c9904 | https://github.com/stephrdev/django-formwizard/blob/7b35165f0340aae4e8302d5b05b0cb443f6c9904/formwizard/views.py#L637-L646 | train | Do a redirect if user presses the prev. step button. |
stephrdev/django-formwizard | formwizard/views.py | NamedUrlWizardView.render_next_step | def render_next_step(self, form, **kwargs):
"""
When using the NamedUrlFormWizard, we have to redirect to update the
browser's URL to match the shown step.
"""
next_step = self.get_next_step()
self.storage.current_step = next_step
return redirect(self.url_name, st... | python | def render_next_step(self, form, **kwargs):
"""
When using the NamedUrlFormWizard, we have to redirect to update the
browser's URL to match the shown step.
"""
next_step = self.get_next_step()
self.storage.current_step = next_step
return redirect(self.url_name, st... | [
"def",
"render_next_step",
"(",
"self",
",",
"form",
",",
"*",
"*",
"kwargs",
")",
":",
"next_step",
"=",
"self",
".",
"get_next_step",
"(",
")",
"self",
".",
"storage",
".",
"current_step",
"=",
"next_step",
"return",
"redirect",
"(",
"self",
".",
"url_... | When using the NamedUrlFormWizard, we have to redirect to update the
browser's URL to match the shown step. | [
"When",
"using",
"the",
"NamedUrlFormWizard",
"we",
"have",
"to",
"redirect",
"to",
"update",
"the",
"browser",
"s",
"URL",
"to",
"match",
"the",
"shown",
"step",
"."
] | 7b35165f0340aae4e8302d5b05b0cb443f6c9904 | https://github.com/stephrdev/django-formwizard/blob/7b35165f0340aae4e8302d5b05b0cb443f6c9904/formwizard/views.py#L648-L655 | train | When using the NamedUrlFormWizard we have to redirect to the next step. |
stephrdev/django-formwizard | formwizard/views.py | NamedUrlWizardView.render_revalidation_failure | def render_revalidation_failure(self, failed_step, form, **kwargs):
"""
When a step fails, we have to redirect the user to the first failing
step.
"""
self.storage.current_step = failed_step
return redirect(self.url_name, step=failed_step) | python | def render_revalidation_failure(self, failed_step, form, **kwargs):
"""
When a step fails, we have to redirect the user to the first failing
step.
"""
self.storage.current_step = failed_step
return redirect(self.url_name, step=failed_step) | [
"def",
"render_revalidation_failure",
"(",
"self",
",",
"failed_step",
",",
"form",
",",
"*",
"*",
"kwargs",
")",
":",
"self",
".",
"storage",
".",
"current_step",
"=",
"failed_step",
"return",
"redirect",
"(",
"self",
".",
"url_name",
",",
"step",
"=",
"f... | When a step fails, we have to redirect the user to the first failing
step. | [
"When",
"a",
"step",
"fails",
"we",
"have",
"to",
"redirect",
"the",
"user",
"to",
"the",
"first",
"failing",
"step",
"."
] | 7b35165f0340aae4e8302d5b05b0cb443f6c9904 | https://github.com/stephrdev/django-formwizard/blob/7b35165f0340aae4e8302d5b05b0cb443f6c9904/formwizard/views.py#L657-L663 | train | Redirect the user to the first failingCOOKIE. |
stephrdev/django-formwizard | formwizard/views.py | NamedUrlWizardView.render_done | def render_done(self, form, **kwargs):
"""
When rendering the done view, we have to redirect first (if the URL
name doesn't fit).
"""
if kwargs.get('step', None) != self.done_step_name:
return redirect(self.url_name, step=self.done_step_name)
return super(Name... | python | def render_done(self, form, **kwargs):
"""
When rendering the done view, we have to redirect first (if the URL
name doesn't fit).
"""
if kwargs.get('step', None) != self.done_step_name:
return redirect(self.url_name, step=self.done_step_name)
return super(Name... | [
"def",
"render_done",
"(",
"self",
",",
"form",
",",
"*",
"*",
"kwargs",
")",
":",
"if",
"kwargs",
".",
"get",
"(",
"'step'",
",",
"None",
")",
"!=",
"self",
".",
"done_step_name",
":",
"return",
"redirect",
"(",
"self",
".",
"url_name",
",",
"step",... | When rendering the done view, we have to redirect first (if the URL
name doesn't fit). | [
"When",
"rendering",
"the",
"done",
"view",
"we",
"have",
"to",
"redirect",
"first",
"(",
"if",
"the",
"URL",
"name",
"doesn",
"t",
"fit",
")",
"."
] | 7b35165f0340aae4e8302d5b05b0cb443f6c9904 | https://github.com/stephrdev/django-formwizard/blob/7b35165f0340aae4e8302d5b05b0cb443f6c9904/formwizard/views.py#L665-L672 | train | When rendering the done view we have to redirect first. |
bunzen/RashlyOutlaid | RashlyOutlaid/libwhois.py | astext | def astext(data):
"""
Given a unicode/str/bytes always return str.
We prefer to work with the 'native' string type for the version of python
we run on, and this gets us that.
"""
if isinstance(data, str):
return data
elif isinstance(data, text_type):
return data.encode("utf-... | python | def astext(data):
"""
Given a unicode/str/bytes always return str.
We prefer to work with the 'native' string type for the version of python
we run on, and this gets us that.
"""
if isinstance(data, str):
return data
elif isinstance(data, text_type):
return data.encode("utf-... | [
"def",
"astext",
"(",
"data",
")",
":",
"if",
"isinstance",
"(",
"data",
",",
"str",
")",
":",
"return",
"data",
"elif",
"isinstance",
"(",
"data",
",",
"text_type",
")",
":",
"return",
"data",
".",
"encode",
"(",
"\"utf-8\"",
",",
"\"ignore\"",
")",
... | Given a unicode/str/bytes always return str.
We prefer to work with the 'native' string type for the version of python
we run on, and this gets us that. | [
"Given",
"a",
"unicode",
"/",
"str",
"/",
"bytes",
"always",
"return",
"str",
"."
] | d08ab62725e632d6a38889c7a93f47b39defb5a1 | https://github.com/bunzen/RashlyOutlaid/blob/d08ab62725e632d6a38889c7a93f47b39defb5a1/RashlyOutlaid/libwhois.py#L38-L51 | train | Given a unicode string always return str. |
StackStorm/pybind | pybind/slxos/v17s_1_02/openflow_state/detail/__init__.py | detail._set_default_action | def _set_default_action(self, v, load=False):
"""
Setter method for default_action, mapped from YANG variable /openflow_state/detail/default_action (default-packet-action)
If this variable is read-only (config: false) in the
source YANG file, then _set_default_action is considered as a private
metho... | python | def _set_default_action(self, v, load=False):
"""
Setter method for default_action, mapped from YANG variable /openflow_state/detail/default_action (default-packet-action)
If this variable is read-only (config: false) in the
source YANG file, then _set_default_action is considered as a private
metho... | [
"def",
"_set_default_action",
"(",
"self",
",",
"v",
",",
"load",
"=",
"False",
")",
":",
"if",
"hasattr",
"(",
"v",
",",
"\"_utype\"",
")",
":",
"v",
"=",
"v",
".",
"_utype",
"(",
"v",
")",
"try",
":",
"t",
"=",
"YANGDynClass",
"(",
"v",
",",
... | Setter method for default_action, mapped from YANG variable /openflow_state/detail/default_action (default-packet-action)
If this variable is read-only (config: false) in the
source YANG file, then _set_default_action is considered as a private
method. Backends looking to populate this variable should
d... | [
"Setter",
"method",
"for",
"default_action",
"mapped",
"from",
"YANG",
"variable",
"/",
"openflow_state",
"/",
"detail",
"/",
"default_action",
"(",
"default",
"-",
"packet",
"-",
"action",
")",
"If",
"this",
"variable",
"is",
"read",
"-",
"only",
"(",
"conf... | 44c467e71b2b425be63867aba6e6fa28b2cfe7fb | https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/slxos/v17s_1_02/openflow_state/detail/__init__.py#L441-L464 | train | Sets the default action for the
|
StackStorm/pybind | pybind/nos/v6_0_2f/brocade_interface_ext_rpc/get_interface_detail/output/interface/__init__.py | interface._set_hardware_type | def _set_hardware_type(self, v, load=False):
"""
Setter method for hardware_type, mapped from YANG variable /brocade_interface_ext_rpc/get_interface_detail/output/interface/hardware_type (enumeration)
If this variable is read-only (config: false) in the
source YANG file, then _set_hardware_type is consi... | python | def _set_hardware_type(self, v, load=False):
"""
Setter method for hardware_type, mapped from YANG variable /brocade_interface_ext_rpc/get_interface_detail/output/interface/hardware_type (enumeration)
If this variable is read-only (config: false) in the
source YANG file, then _set_hardware_type is consi... | [
"def",
"_set_hardware_type",
"(",
"self",
",",
"v",
",",
"load",
"=",
"False",
")",
":",
"if",
"hasattr",
"(",
"v",
",",
"\"_utype\"",
")",
":",
"v",
"=",
"v",
".",
"_utype",
"(",
"v",
")",
"try",
":",
"t",
"=",
"YANGDynClass",
"(",
"v",
",",
"... | Setter method for hardware_type, mapped from YANG variable /brocade_interface_ext_rpc/get_interface_detail/output/interface/hardware_type (enumeration)
If this variable is read-only (config: false) in the
source YANG file, then _set_hardware_type is considered as a private
method. Backends looking to popula... | [
"Setter",
"method",
"for",
"hardware_type",
"mapped",
"from",
"YANG",
"variable",
"/",
"brocade_interface_ext_rpc",
"/",
"get_interface_detail",
"/",
"output",
"/",
"interface",
"/",
"hardware_type",
"(",
"enumeration",
")",
"If",
"this",
"variable",
"is",
"read",
... | 44c467e71b2b425be63867aba6e6fa28b2cfe7fb | https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/nos/v6_0_2f/brocade_interface_ext_rpc/get_interface_detail/output/interface/__init__.py#L595-L618 | train | Sets the hardware type of the node. |
StackStorm/pybind | pybind/nos/v6_0_2f/brocade_interface_ext_rpc/get_interface_detail/output/interface/__init__.py | interface._set_media_type | def _set_media_type(self, v, load=False):
"""
Setter method for media_type, mapped from YANG variable /brocade_interface_ext_rpc/get_interface_detail/output/interface/media_type (enumeration)
If this variable is read-only (config: false) in the
source YANG file, then _set_media_type is considered as a p... | python | def _set_media_type(self, v, load=False):
"""
Setter method for media_type, mapped from YANG variable /brocade_interface_ext_rpc/get_interface_detail/output/interface/media_type (enumeration)
If this variable is read-only (config: false) in the
source YANG file, then _set_media_type is considered as a p... | [
"def",
"_set_media_type",
"(",
"self",
",",
"v",
",",
"load",
"=",
"False",
")",
":",
"if",
"hasattr",
"(",
"v",
",",
"\"_utype\"",
")",
":",
"v",
"=",
"v",
".",
"_utype",
"(",
"v",
")",
"try",
":",
"t",
"=",
"YANGDynClass",
"(",
"v",
",",
"bas... | Setter method for media_type, mapped from YANG variable /brocade_interface_ext_rpc/get_interface_detail/output/interface/media_type (enumeration)
If this variable is read-only (config: false) in the
source YANG file, then _set_media_type is considered as a private
method. Backends looking to populate this v... | [
"Setter",
"method",
"for",
"media_type",
"mapped",
"from",
"YANG",
"variable",
"/",
"brocade_interface_ext_rpc",
"/",
"get_interface_detail",
"/",
"output",
"/",
"interface",
"/",
"media_type",
"(",
"enumeration",
")",
"If",
"this",
"variable",
"is",
"read",
"-",
... | 44c467e71b2b425be63867aba6e6fa28b2cfe7fb | https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/nos/v6_0_2f/brocade_interface_ext_rpc/get_interface_detail/output/interface/__init__.py#L711-L735 | train | Sets the media type of the
|
StackStorm/pybind | pybind/nos/v6_0_2f/brocade_interface_ext_rpc/get_interface_detail/output/interface/__init__.py | interface._set_port_mode | def _set_port_mode(self, v, load=False):
"""
Setter method for port_mode, mapped from YANG variable /brocade_interface_ext_rpc/get_interface_detail/output/interface/port_mode (enumeration)
If this variable is read-only (config: false) in the
source YANG file, then _set_port_mode is considered as a priva... | python | def _set_port_mode(self, v, load=False):
"""
Setter method for port_mode, mapped from YANG variable /brocade_interface_ext_rpc/get_interface_detail/output/interface/port_mode (enumeration)
If this variable is read-only (config: false) in the
source YANG file, then _set_port_mode is considered as a priva... | [
"def",
"_set_port_mode",
"(",
"self",
",",
"v",
",",
"load",
"=",
"False",
")",
":",
"if",
"hasattr",
"(",
"v",
",",
"\"_utype\"",
")",
":",
"v",
"=",
"v",
".",
"_utype",
"(",
"v",
")",
"try",
":",
"t",
"=",
"YANGDynClass",
"(",
"v",
",",
"base... | Setter method for port_mode, mapped from YANG variable /brocade_interface_ext_rpc/get_interface_detail/output/interface/port_mode (enumeration)
If this variable is read-only (config: false) in the
source YANG file, then _set_port_mode is considered as a private
method. Backends looking to populate this vari... | [
"Setter",
"method",
"for",
"port_mode",
"mapped",
"from",
"YANG",
"variable",
"/",
"brocade_interface_ext_rpc",
"/",
"get_interface_detail",
"/",
"output",
"/",
"interface",
"/",
"port_mode",
"(",
"enumeration",
")",
"If",
"this",
"variable",
"is",
"read",
"-",
... | 44c467e71b2b425be63867aba6e6fa28b2cfe7fb | https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/nos/v6_0_2f/brocade_interface_ext_rpc/get_interface_detail/output/interface/__init__.py#L1065-L1090 | train | Sets the port mode of the non - negative integer list of physical blocks. |
StackStorm/pybind | pybind/nos/v7_2_0/interface/port_channel/ip/ip_config/__init__.py | ip_config._set_unnumbered | def _set_unnumbered(self, v, load=False):
"""
Setter method for unnumbered, mapped from YANG variable /interface/port_channel/ip/ip_config/unnumbered (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_unnumbered is considered as a private
method. Backends lo... | python | def _set_unnumbered(self, v, load=False):
"""
Setter method for unnumbered, mapped from YANG variable /interface/port_channel/ip/ip_config/unnumbered (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_unnumbered is considered as a private
method. Backends lo... | [
"def",
"_set_unnumbered",
"(",
"self",
",",
"v",
",",
"load",
"=",
"False",
")",
":",
"if",
"hasattr",
"(",
"v",
",",
"\"_utype\"",
")",
":",
"v",
"=",
"v",
".",
"_utype",
"(",
"v",
")",
"try",
":",
"t",
"=",
"YANGDynClass",
"(",
"v",
",",
"bas... | Setter method for unnumbered, mapped from YANG variable /interface/port_channel/ip/ip_config/unnumbered (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_unnumbered is considered as a private
method. Backends looking to populate this variable should
do so via c... | [
"Setter",
"method",
"for",
"unnumbered",
"mapped",
"from",
"YANG",
"variable",
"/",
"interface",
"/",
"port_channel",
"/",
"ip",
"/",
"ip_config",
"/",
"unnumbered",
"(",
"container",
")",
"If",
"this",
"variable",
"is",
"read",
"-",
"only",
"(",
"config",
... | 44c467e71b2b425be63867aba6e6fa28b2cfe7fb | https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/nos/v7_2_0/interface/port_channel/ip/ip_config/__init__.py#L298-L319 | train | Set the unnumbered value of the specified unnumbered sequence. |
StackStorm/pybind | pybind/slxos/v17s_1_02/qos/map_/dscp_cos/__init__.py | dscp_cos._set_dscp_to_cos_mapping | def _set_dscp_to_cos_mapping(self, v, load=False):
"""
Setter method for dscp_to_cos_mapping, mapped from YANG variable /qos/map/dscp_cos/dscp_to_cos_mapping (list)
If this variable is read-only (config: false) in the
source YANG file, then _set_dscp_to_cos_mapping is considered as a private
method.... | python | def _set_dscp_to_cos_mapping(self, v, load=False):
"""
Setter method for dscp_to_cos_mapping, mapped from YANG variable /qos/map/dscp_cos/dscp_to_cos_mapping (list)
If this variable is read-only (config: false) in the
source YANG file, then _set_dscp_to_cos_mapping is considered as a private
method.... | [
"def",
"_set_dscp_to_cos_mapping",
"(",
"self",
",",
"v",
",",
"load",
"=",
"False",
")",
":",
"if",
"hasattr",
"(",
"v",
",",
"\"_utype\"",
")",
":",
"v",
"=",
"v",
".",
"_utype",
"(",
"v",
")",
"try",
":",
"t",
"=",
"YANGDynClass",
"(",
"v",
",... | Setter method for dscp_to_cos_mapping, mapped from YANG variable /qos/map/dscp_cos/dscp_to_cos_mapping (list)
If this variable is read-only (config: false) in the
source YANG file, then _set_dscp_to_cos_mapping is considered as a private
method. Backends looking to populate this variable should
do so vi... | [
"Setter",
"method",
"for",
"dscp_to_cos_mapping",
"mapped",
"from",
"YANG",
"variable",
"/",
"qos",
"/",
"map",
"/",
"dscp_cos",
"/",
"dscp_to_cos_mapping",
"(",
"list",
")",
"If",
"this",
"variable",
"is",
"read",
"-",
"only",
"(",
"config",
":",
"false",
... | 44c467e71b2b425be63867aba6e6fa28b2cfe7fb | https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/slxos/v17s_1_02/qos/map_/dscp_cos/__init__.py#L131-L152 | train | Sets the DSCP to CoS mapping. |
StackStorm/pybind | pybind/slxos/v17s_1_02/routing_system/interface/ve/ip/interface_vlan_ospf_conf/__init__.py | interface_vlan_ospf_conf._set_ospf1 | def _set_ospf1(self, v, load=False):
"""
Setter method for ospf1, mapped from YANG variable /routing_system/interface/ve/ip/interface_vlan_ospf_conf/ospf1 (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_ospf1 is considered as a private
method. Backends lo... | python | def _set_ospf1(self, v, load=False):
"""
Setter method for ospf1, mapped from YANG variable /routing_system/interface/ve/ip/interface_vlan_ospf_conf/ospf1 (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_ospf1 is considered as a private
method. Backends lo... | [
"def",
"_set_ospf1",
"(",
"self",
",",
"v",
",",
"load",
"=",
"False",
")",
":",
"if",
"hasattr",
"(",
"v",
",",
"\"_utype\"",
")",
":",
"v",
"=",
"v",
".",
"_utype",
"(",
"v",
")",
"try",
":",
"t",
"=",
"YANGDynClass",
"(",
"v",
",",
"base",
... | Setter method for ospf1, mapped from YANG variable /routing_system/interface/ve/ip/interface_vlan_ospf_conf/ospf1 (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_ospf1 is considered as a private
method. Backends looking to populate this variable should
do so ... | [
"Setter",
"method",
"for",
"ospf1",
"mapped",
"from",
"YANG",
"variable",
"/",
"routing_system",
"/",
"interface",
"/",
"ve",
"/",
"ip",
"/",
"interface_vlan_ospf_conf",
"/",
"ospf1",
"(",
"container",
")",
"If",
"this",
"variable",
"is",
"read",
"-",
"only"... | 44c467e71b2b425be63867aba6e6fa28b2cfe7fb | https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/slxos/v17s_1_02/routing_system/interface/ve/ip/interface_vlan_ospf_conf/__init__.py#L92-L113 | train | Sets the value of the OSPF1 variable. |
StackStorm/pybind | pybind/nos/v6_0_2f/rbridge_id/global_lc_holder/linecard/__init__.py | linecard._set_linecards | def _set_linecards(self, v, load=False):
"""
Setter method for linecards, mapped from YANG variable /rbridge_id/global_lc_holder/linecard/linecards (list)
If this variable is read-only (config: false) in the
source YANG file, then _set_linecards is considered as a private
method. Backends looking to... | python | def _set_linecards(self, v, load=False):
"""
Setter method for linecards, mapped from YANG variable /rbridge_id/global_lc_holder/linecard/linecards (list)
If this variable is read-only (config: false) in the
source YANG file, then _set_linecards is considered as a private
method. Backends looking to... | [
"def",
"_set_linecards",
"(",
"self",
",",
"v",
",",
"load",
"=",
"False",
")",
":",
"if",
"hasattr",
"(",
"v",
",",
"\"_utype\"",
")",
":",
"v",
"=",
"v",
".",
"_utype",
"(",
"v",
")",
"try",
":",
"t",
"=",
"YANGDynClass",
"(",
"v",
",",
"base... | Setter method for linecards, mapped from YANG variable /rbridge_id/global_lc_holder/linecard/linecards (list)
If this variable is read-only (config: false) in the
source YANG file, then _set_linecards is considered as a private
method. Backends looking to populate this variable should
do so via calling ... | [
"Setter",
"method",
"for",
"linecards",
"mapped",
"from",
"YANG",
"variable",
"/",
"rbridge_id",
"/",
"global_lc_holder",
"/",
"linecard",
"/",
"linecards",
"(",
"list",
")",
"If",
"this",
"variable",
"is",
"read",
"-",
"only",
"(",
"config",
":",
"false",
... | 44c467e71b2b425be63867aba6e6fa28b2cfe7fb | https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/nos/v6_0_2f/rbridge_id/global_lc_holder/linecard/__init__.py#L92-L113 | train | Sets the value of the linecards field in the cluster. |
StackStorm/pybind | pybind/nos/v6_0_2f/mac_group/__init__.py | mac_group._set_mac_group_entry | def _set_mac_group_entry(self, v, load=False):
"""
Setter method for mac_group_entry, mapped from YANG variable /mac_group/mac_group_entry (list)
If this variable is read-only (config: false) in the
source YANG file, then _set_mac_group_entry is considered as a private
method. Backends looking to po... | python | def _set_mac_group_entry(self, v, load=False):
"""
Setter method for mac_group_entry, mapped from YANG variable /mac_group/mac_group_entry (list)
If this variable is read-only (config: false) in the
source YANG file, then _set_mac_group_entry is considered as a private
method. Backends looking to po... | [
"def",
"_set_mac_group_entry",
"(",
"self",
",",
"v",
",",
"load",
"=",
"False",
")",
":",
"if",
"hasattr",
"(",
"v",
",",
"\"_utype\"",
")",
":",
"v",
"=",
"v",
".",
"_utype",
"(",
"v",
")",
"try",
":",
"t",
"=",
"YANGDynClass",
"(",
"v",
",",
... | Setter method for mac_group_entry, mapped from YANG variable /mac_group/mac_group_entry (list)
If this variable is read-only (config: false) in the
source YANG file, then _set_mac_group_entry is considered as a private
method. Backends looking to populate this variable should
do so via calling thisObj._... | [
"Setter",
"method",
"for",
"mac_group_entry",
"mapped",
"from",
"YANG",
"variable",
"/",
"mac_group",
"/",
"mac_group_entry",
"(",
"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/mac_group/__init__.py#L131-L152 | train | Set the entry of the mac group. |
StackStorm/pybind | pybind/nos/v6_0_2f/overlay_gateway/attach/__init__.py | attach._set_rbridge_id | def _set_rbridge_id(self, v, load=False):
"""
Setter method for rbridge_id, mapped from YANG variable /overlay_gateway/attach/rbridge_id (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_rbridge_id is considered as a private
method. Backends looking to popu... | python | def _set_rbridge_id(self, v, load=False):
"""
Setter method for rbridge_id, mapped from YANG variable /overlay_gateway/attach/rbridge_id (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_rbridge_id is considered as a private
method. Backends looking to popu... | [
"def",
"_set_rbridge_id",
"(",
"self",
",",
"v",
",",
"load",
"=",
"False",
")",
":",
"if",
"hasattr",
"(",
"v",
",",
"\"_utype\"",
")",
":",
"v",
"=",
"v",
".",
"_utype",
"(",
"v",
")",
"try",
":",
"t",
"=",
"YANGDynClass",
"(",
"v",
",",
"bas... | Setter method for rbridge_id, mapped from YANG variable /overlay_gateway/attach/rbridge_id (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_rbridge_id is considered as a private
method. Backends looking to populate this variable should
do so via calling thisOb... | [
"Setter",
"method",
"for",
"rbridge_id",
"mapped",
"from",
"YANG",
"variable",
"/",
"overlay_gateway",
"/",
"attach",
"/",
"rbridge_id",
"(",
"container",
")",
"If",
"this",
"variable",
"is",
"read",
"-",
"only",
"(",
"config",
":",
"false",
")",
"in",
"th... | 44c467e71b2b425be63867aba6e6fa28b2cfe7fb | https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/nos/v6_0_2f/overlay_gateway/attach/__init__.py#L94-L115 | train | Sets the rbridge_id of the
|
StackStorm/pybind | pybind/nos/v6_0_2f/overlay_gateway/attach/__init__.py | attach._set_vlan | def _set_vlan(self, v, load=False):
"""
Setter method for vlan, mapped from YANG variable /overlay_gateway/attach/vlan (list)
If this variable is read-only (config: false) in the
source YANG file, then _set_vlan is considered as a private
method. Backends looking to populate this variable should
... | python | def _set_vlan(self, v, load=False):
"""
Setter method for vlan, mapped from YANG variable /overlay_gateway/attach/vlan (list)
If this variable is read-only (config: false) in the
source YANG file, then _set_vlan is considered as a private
method. Backends looking to populate this variable should
... | [
"def",
"_set_vlan",
"(",
"self",
",",
"v",
",",
"load",
"=",
"False",
")",
":",
"if",
"hasattr",
"(",
"v",
",",
"\"_utype\"",
")",
":",
"v",
"=",
"v",
".",
"_utype",
"(",
"v",
")",
"try",
":",
"t",
"=",
"YANGDynClass",
"(",
"v",
",",
"base",
... | Setter method for vlan, mapped from YANG variable /overlay_gateway/attach/vlan (list)
If this variable is read-only (config: false) in the
source YANG file, then _set_vlan is considered as a private
method. Backends looking to populate this variable should
do so via calling thisObj._set_vlan() directly. | [
"Setter",
"method",
"for",
"vlan",
"mapped",
"from",
"YANG",
"variable",
"/",
"overlay_gateway",
"/",
"attach",
"/",
"vlan",
"(",
"list",
")",
"If",
"this",
"variable",
"is",
"read",
"-",
"only",
"(",
"config",
":",
"false",
")",
"in",
"the",
"source",
... | 44c467e71b2b425be63867aba6e6fa28b2cfe7fb | https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/nos/v6_0_2f/overlay_gateway/attach/__init__.py#L127-L148 | train | Set the vlan field of the
|
StackStorm/pybind | pybind/nos/v6_0_2f/rbridge_id/fabric/__init__.py | fabric._set_ecmp | def _set_ecmp(self, v, load=False):
"""
Setter method for ecmp, mapped from YANG variable /rbridge_id/fabric/ecmp (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_ecmp is considered as a private
method. Backends looking to populate this variable should
... | python | def _set_ecmp(self, v, load=False):
"""
Setter method for ecmp, mapped from YANG variable /rbridge_id/fabric/ecmp (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_ecmp is considered as a private
method. Backends looking to populate this variable should
... | [
"def",
"_set_ecmp",
"(",
"self",
",",
"v",
",",
"load",
"=",
"False",
")",
":",
"if",
"hasattr",
"(",
"v",
",",
"\"_utype\"",
")",
":",
"v",
"=",
"v",
".",
"_utype",
"(",
"v",
")",
"try",
":",
"t",
"=",
"YANGDynClass",
"(",
"v",
",",
"base",
... | Setter method for ecmp, mapped from YANG variable /rbridge_id/fabric/ecmp (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_ecmp is considered as a private
method. Backends looking to populate this variable should
do so via calling thisObj._set_ecmp() directly.... | [
"Setter",
"method",
"for",
"ecmp",
"mapped",
"from",
"YANG",
"variable",
"/",
"rbridge_id",
"/",
"fabric",
"/",
"ecmp",
"(",
"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/rbridge_id/fabric/__init__.py#L105-L129 | train | Sets the ecmp parameter of the
|
StackStorm/pybind | pybind/nos/v6_0_2f/rbridge_id/fabric/__init__.py | fabric._set_port_channel | def _set_port_channel(self, v, load=False):
"""
Setter method for port_channel, mapped from YANG variable /rbridge_id/fabric/port_channel (list)
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 popula... | python | def _set_port_channel(self, v, load=False):
"""
Setter method for port_channel, mapped from YANG variable /rbridge_id/fabric/port_channel (list)
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 popula... | [
"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 /rbridge_id/fabric/port_channel (list)
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 calling thisObj._s... | [
"Setter",
"method",
"for",
"port_channel",
"mapped",
"from",
"YANG",
"variable",
"/",
"rbridge_id",
"/",
"fabric",
"/",
"port_channel",
"(",
"list",
")",
"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/fabric/__init__.py#L180-L201 | train | Sets the port_channel of the
based on the given list of PO IDs. |
StackStorm/pybind | pybind/nos/v6_0_2f/rbridge_id/fabric/__init__.py | fabric._set_login_policy | def _set_login_policy(self, v, load=False):
"""
Setter method for login_policy, mapped from YANG variable /rbridge_id/fabric/login_policy (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_login_policy is considered as a private
method. Backends looking to p... | python | def _set_login_policy(self, v, load=False):
"""
Setter method for login_policy, mapped from YANG variable /rbridge_id/fabric/login_policy (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_login_policy is considered as a private
method. Backends looking to p... | [
"def",
"_set_login_policy",
"(",
"self",
",",
"v",
",",
"load",
"=",
"False",
")",
":",
"if",
"hasattr",
"(",
"v",
",",
"\"_utype\"",
")",
":",
"v",
"=",
"v",
".",
"_utype",
"(",
"v",
")",
"try",
":",
"t",
"=",
"YANGDynClass",
"(",
"v",
",",
"b... | Setter method for login_policy, mapped from YANG variable /rbridge_id/fabric/login_policy (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_login_policy is considered as a private
method. Backends looking to populate this variable should
do so via calling thisO... | [
"Setter",
"method",
"for",
"login_policy",
"mapped",
"from",
"YANG",
"variable",
"/",
"rbridge_id",
"/",
"fabric",
"/",
"login_policy",
"(",
"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/fabric/__init__.py#L216-L240 | train | Set the login policy of the
|
StackStorm/pybind | pybind/nos/v6_0_2f/brocade_system_rpc/__init__.py | brocade_system._set_get_system_uptime | def _set_get_system_uptime(self, v, load=False):
"""
Setter method for get_system_uptime, mapped from YANG variable /brocade_system_rpc/get_system_uptime (rpc)
If this variable is read-only (config: false) in the
source YANG file, then _set_get_system_uptime is considered as a private
method. Backen... | python | def _set_get_system_uptime(self, v, load=False):
"""
Setter method for get_system_uptime, mapped from YANG variable /brocade_system_rpc/get_system_uptime (rpc)
If this variable is read-only (config: false) in the
source YANG file, then _set_get_system_uptime is considered as a private
method. Backen... | [
"def",
"_set_get_system_uptime",
"(",
"self",
",",
"v",
",",
"load",
"=",
"False",
")",
":",
"if",
"hasattr",
"(",
"v",
",",
"\"_utype\"",
")",
":",
"v",
"=",
"v",
".",
"_utype",
"(",
"v",
")",
"try",
":",
"t",
"=",
"YANGDynClass",
"(",
"v",
",",... | Setter method for get_system_uptime, mapped from YANG variable /brocade_system_rpc/get_system_uptime (rpc)
If this variable is read-only (config: false) in the
source YANG file, then _set_get_system_uptime is considered as a private
method. Backends looking to populate this variable should
do so via cal... | [
"Setter",
"method",
"for",
"get_system_uptime",
"mapped",
"from",
"YANG",
"variable",
"/",
"brocade_system_rpc",
"/",
"get_system_uptime",
"(",
"rpc",
")",
"If",
"this",
"variable",
"is",
"read",
"-",
"only",
"(",
"config",
":",
"false",
")",
"in",
"the",
"s... | 44c467e71b2b425be63867aba6e6fa28b2cfe7fb | https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/nos/v6_0_2f/brocade_system_rpc/__init__.py#L97-L121 | train | This method is used to set the get_system_uptime property of the managed entity. |
StackStorm/pybind | pybind/nos/v6_0_2f/brocade_ntp_rpc/__init__.py | brocade_ntp._set_show_ntp | def _set_show_ntp(self, v, load=False):
"""
Setter method for show_ntp, mapped from YANG variable /brocade_ntp_rpc/show_ntp (rpc)
If this variable is read-only (config: false) in the
source YANG file, then _set_show_ntp is considered as a private
method. Backends looking to populate this variable sh... | python | def _set_show_ntp(self, v, load=False):
"""
Setter method for show_ntp, mapped from YANG variable /brocade_ntp_rpc/show_ntp (rpc)
If this variable is read-only (config: false) in the
source YANG file, then _set_show_ntp is considered as a private
method. Backends looking to populate this variable sh... | [
"def",
"_set_show_ntp",
"(",
"self",
",",
"v",
",",
"load",
"=",
"False",
")",
":",
"if",
"hasattr",
"(",
"v",
",",
"\"_utype\"",
")",
":",
"v",
"=",
"v",
".",
"_utype",
"(",
"v",
")",
"try",
":",
"t",
"=",
"YANGDynClass",
"(",
"v",
",",
"base"... | Setter method for show_ntp, mapped from YANG variable /brocade_ntp_rpc/show_ntp (rpc)
If this variable is read-only (config: false) in the
source YANG file, then _set_show_ntp is considered as a private
method. Backends looking to populate this variable should
do so via calling thisObj._set_show_ntp() d... | [
"Setter",
"method",
"for",
"show_ntp",
"mapped",
"from",
"YANG",
"variable",
"/",
"brocade_ntp_rpc",
"/",
"show_ntp",
"(",
"rpc",
")",
"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/brocade_ntp_rpc/__init__.py#L96-L119 | train | Set the show_ntp property of the
. |
StackStorm/pybind | pybind/nos/v6_0_2f/terminal_cfg/__init__.py | terminal_cfg._set_line | def _set_line(self, v, load=False):
"""
Setter method for line, mapped from YANG variable /terminal_cfg/line (list)
If this variable is read-only (config: false) in the
source YANG file, then _set_line is considered as a private
method. Backends looking to populate this variable should
do so via... | python | def _set_line(self, v, load=False):
"""
Setter method for line, mapped from YANG variable /terminal_cfg/line (list)
If this variable is read-only (config: false) in the
source YANG file, then _set_line is considered as a private
method. Backends looking to populate this variable should
do so via... | [
"def",
"_set_line",
"(",
"self",
",",
"v",
",",
"load",
"=",
"False",
")",
":",
"if",
"hasattr",
"(",
"v",
",",
"\"_utype\"",
")",
":",
"v",
"=",
"v",
".",
"_utype",
"(",
"v",
")",
"try",
":",
"t",
"=",
"YANGDynClass",
"(",
"v",
",",
"base",
... | Setter method for line, mapped from YANG variable /terminal_cfg/line (list)
If this variable is read-only (config: false) in the
source YANG file, then _set_line is considered as a private
method. Backends looking to populate this variable should
do so via calling thisObj._set_line() directly. | [
"Setter",
"method",
"for",
"line",
"mapped",
"from",
"YANG",
"variable",
"/",
"terminal_cfg",
"/",
"line",
"(",
"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/terminal_cfg/__init__.py#L92-L113 | train | Set the line of the
based on the line configuration. |
StackStorm/pybind | pybind/nos/v6_0_2f/rbridge_id/router/hide_pim_holder/__init__.py | hide_pim_holder._set_pim | def _set_pim(self, v, load=False):
"""
Setter method for pim, mapped from YANG variable /rbridge_id/router/hide_pim_holder/pim (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_pim is considered as a private
method. Backends looking to populate this variabl... | python | def _set_pim(self, v, load=False):
"""
Setter method for pim, mapped from YANG variable /rbridge_id/router/hide_pim_holder/pim (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_pim is considered as a private
method. Backends looking to populate this variabl... | [
"def",
"_set_pim",
"(",
"self",
",",
"v",
",",
"load",
"=",
"False",
")",
":",
"if",
"hasattr",
"(",
"v",
",",
"\"_utype\"",
")",
":",
"v",
"=",
"v",
".",
"_utype",
"(",
"v",
")",
"try",
":",
"t",
"=",
"YANGDynClass",
"(",
"v",
",",
"base",
"... | Setter method for pim, mapped from YANG variable /rbridge_id/router/hide_pim_holder/pim (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_pim is considered as a private
method. Backends looking to populate this variable should
do so via calling thisObj._set_pim... | [
"Setter",
"method",
"for",
"pim",
"mapped",
"from",
"YANG",
"variable",
"/",
"rbridge_id",
"/",
"router",
"/",
"hide_pim_holder",
"/",
"pim",
"(",
"container",
")",
"If",
"this",
"variable",
"is",
"read",
"-",
"only",
"(",
"config",
":",
"false",
")",
"i... | 44c467e71b2b425be63867aba6e6fa28b2cfe7fb | https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/nos/v6_0_2f/rbridge_id/router/hide_pim_holder/__init__.py#L92-L113 | train | Set the pim property of the
|
StackStorm/pybind | pybind/nos/v6_0_2f/interface/fortygigabitethernet/ipv6/__init__.py | ipv6._set_interface_phy_dhcp_conf | def _set_interface_phy_dhcp_conf(self, v, load=False):
"""
Setter method for interface_phy_dhcp_conf, mapped from YANG variable /interface/fortygigabitethernet/ipv6/interface_phy_dhcp_conf (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_interface_phy_dhcp_con... | python | def _set_interface_phy_dhcp_conf(self, v, load=False):
"""
Setter method for interface_phy_dhcp_conf, mapped from YANG variable /interface/fortygigabitethernet/ipv6/interface_phy_dhcp_conf (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_interface_phy_dhcp_con... | [
"def",
"_set_interface_phy_dhcp_conf",
"(",
"self",
",",
"v",
",",
"load",
"=",
"False",
")",
":",
"if",
"hasattr",
"(",
"v",
",",
"\"_utype\"",
")",
":",
"v",
"=",
"v",
".",
"_utype",
"(",
"v",
")",
"try",
":",
"t",
"=",
"YANGDynClass",
"(",
"v",
... | Setter method for interface_phy_dhcp_conf, mapped from YANG variable /interface/fortygigabitethernet/ipv6/interface_phy_dhcp_conf (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_interface_phy_dhcp_conf is considered as a private
method. Backends looking to popula... | [
"Setter",
"method",
"for",
"interface_phy_dhcp_conf",
"mapped",
"from",
"YANG",
"variable",
"/",
"interface",
"/",
"fortygigabitethernet",
"/",
"ipv6",
"/",
"interface_phy_dhcp_conf",
"(",
"container",
")",
"If",
"this",
"variable",
"is",
"read",
"-",
"only",
"(",... | 44c467e71b2b425be63867aba6e6fa28b2cfe7fb | https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/nos/v6_0_2f/interface/fortygigabitethernet/ipv6/__init__.py#L179-L200 | train | Sets the interface_phy_dhcp_conf property of the
|
StackStorm/pybind | pybind/nos/v6_0_2f/interface/fortygigabitethernet/ipv6/__init__.py | ipv6._set_ipv6_phy_intf_cmds | def _set_ipv6_phy_intf_cmds(self, v, load=False):
"""
Setter method for ipv6_phy_intf_cmds, mapped from YANG variable /interface/fortygigabitethernet/ipv6/ipv6_phy_intf_cmds (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_ipv6_phy_intf_cmds is considered as a... | python | def _set_ipv6_phy_intf_cmds(self, v, load=False):
"""
Setter method for ipv6_phy_intf_cmds, mapped from YANG variable /interface/fortygigabitethernet/ipv6/ipv6_phy_intf_cmds (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_ipv6_phy_intf_cmds is considered as a... | [
"def",
"_set_ipv6_phy_intf_cmds",
"(",
"self",
",",
"v",
",",
"load",
"=",
"False",
")",
":",
"if",
"hasattr",
"(",
"v",
",",
"\"_utype\"",
")",
":",
"v",
"=",
"v",
".",
"_utype",
"(",
"v",
")",
"try",
":",
"t",
"=",
"YANGDynClass",
"(",
"v",
","... | Setter method for ipv6_phy_intf_cmds, mapped from YANG variable /interface/fortygigabitethernet/ipv6/ipv6_phy_intf_cmds (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_ipv6_phy_intf_cmds is considered as a private
method. Backends looking to populate this variabl... | [
"Setter",
"method",
"for",
"ipv6_phy_intf_cmds",
"mapped",
"from",
"YANG",
"variable",
"/",
"interface",
"/",
"fortygigabitethernet",
"/",
"ipv6",
"/",
"ipv6_phy_intf_cmds",
"(",
"container",
")",
"If",
"this",
"variable",
"is",
"read",
"-",
"only",
"(",
"config... | 44c467e71b2b425be63867aba6e6fa28b2cfe7fb | https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/nos/v6_0_2f/interface/fortygigabitethernet/ipv6/__init__.py#L348-L369 | train | Sets the list of commands supported by the ipv6 - phy interface. |
budacom/trading-bots | trading_bots/core/storage.py | get_store | def get_store(logger: Logger=None) -> 'Store':
"""Get and configure the storage backend"""
from trading_bots.conf import settings
store_settings = settings.storage
store = store_settings.get('name', 'json')
if store == 'json':
store = 'trading_bots.core.storage.JSONStore'
elif store == '... | python | def get_store(logger: Logger=None) -> 'Store':
"""Get and configure the storage backend"""
from trading_bots.conf import settings
store_settings = settings.storage
store = store_settings.get('name', 'json')
if store == 'json':
store = 'trading_bots.core.storage.JSONStore'
elif store == '... | [
"def",
"get_store",
"(",
"logger",
":",
"Logger",
"=",
"None",
")",
"->",
"'Store'",
":",
"from",
"trading_bots",
".",
"conf",
"import",
"settings",
"store_settings",
"=",
"settings",
".",
"storage",
"store",
"=",
"store_settings",
".",
"get",
"(",
"'name'",... | Get and configure the storage backend | [
"Get",
"and",
"configure",
"the",
"storage",
"backend"
] | 8cb68bb8d0b5f822108db1cc5dae336e3d3c3452 | https://github.com/budacom/trading-bots/blob/8cb68bb8d0b5f822108db1cc5dae336e3d3c3452/trading_bots/core/storage.py#L15-L26 | train | Get and configure the storage backend |
StackStorm/pybind | pybind/slxos/v17s_1_02/interface/ethernet/ipv6/__init__.py | ipv6._set_access_group | def _set_access_group(self, v, load=False):
"""
Setter method for access_group, mapped from YANG variable /interface/ethernet/ipv6/access_group (list)
If this variable is read-only (config: false) in the
source YANG file, then _set_access_group is considered as a private
method. Backends looking to ... | python | def _set_access_group(self, v, load=False):
"""
Setter method for access_group, mapped from YANG variable /interface/ethernet/ipv6/access_group (list)
If this variable is read-only (config: false) in the
source YANG file, then _set_access_group is considered as a private
method. Backends looking to ... | [
"def",
"_set_access_group",
"(",
"self",
",",
"v",
",",
"load",
"=",
"False",
")",
":",
"if",
"hasattr",
"(",
"v",
",",
"\"_utype\"",
")",
":",
"v",
"=",
"v",
".",
"_utype",
"(",
"v",
")",
"try",
":",
"t",
"=",
"YANGDynClass",
"(",
"v",
",",
"b... | Setter method for access_group, mapped from YANG variable /interface/ethernet/ipv6/access_group (list)
If this variable is read-only (config: false) in the
source YANG file, then _set_access_group is considered as a private
method. Backends looking to populate this variable should
do so via calling this... | [
"Setter",
"method",
"for",
"access_group",
"mapped",
"from",
"YANG",
"variable",
"/",
"interface",
"/",
"ethernet",
"/",
"ipv6",
"/",
"access_group",
"(",
"list",
")",
"If",
"this",
"variable",
"is",
"read",
"-",
"only",
"(",
"config",
":",
"false",
")",
... | 44c467e71b2b425be63867aba6e6fa28b2cfe7fb | https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/slxos/v17s_1_02/interface/ethernet/ipv6/__init__.py#L247-L268 | train | Sets the access group of the
based on the given list of ipv6_access_list values. |
StackStorm/pybind | pybind/slxos/v17s_1_02/interface/ethernet/ipv6/__init__.py | ipv6._set_intf_ipv6_router_isis | def _set_intf_ipv6_router_isis(self, v, load=False):
"""
Setter method for intf_ipv6_router_isis, mapped from YANG variable /interface/ethernet/ipv6/intf_ipv6_router_isis (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_intf_ipv6_router_isis is considered as a... | python | def _set_intf_ipv6_router_isis(self, v, load=False):
"""
Setter method for intf_ipv6_router_isis, mapped from YANG variable /interface/ethernet/ipv6/intf_ipv6_router_isis (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_intf_ipv6_router_isis is considered as a... | [
"def",
"_set_intf_ipv6_router_isis",
"(",
"self",
",",
"v",
",",
"load",
"=",
"False",
")",
":",
"if",
"hasattr",
"(",
"v",
",",
"\"_utype\"",
")",
":",
"v",
"=",
"v",
".",
"_utype",
"(",
"v",
")",
"try",
":",
"t",
"=",
"YANGDynClass",
"(",
"v",
... | Setter method for intf_ipv6_router_isis, mapped from YANG variable /interface/ethernet/ipv6/intf_ipv6_router_isis (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_intf_ipv6_router_isis is considered as a private
method. Backends looking to populate this variable s... | [
"Setter",
"method",
"for",
"intf_ipv6_router_isis",
"mapped",
"from",
"YANG",
"variable",
"/",
"interface",
"/",
"ethernet",
"/",
"ipv6",
"/",
"intf_ipv6_router_isis",
"(",
"container",
")",
"If",
"this",
"variable",
"is",
"read",
"-",
"only",
"(",
"config",
"... | 44c467e71b2b425be63867aba6e6fa28b2cfe7fb | https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/slxos/v17s_1_02/interface/ethernet/ipv6/__init__.py#L350-L371 | train | Set the value of the interface ipv6_router_isis variable. |
spoqa/dodotable | dodotable/util.py | camel_to_underscore | def camel_to_underscore(name):
"""CamelCase로 주어진 ``name``\ 을 underscore_with_lower_case로 변환합니다
.. code-block:: python
>>> camel_to_underscore('SomePythonClass')
'some_python_class'
:param str name: name to convert
:return: converted name
:rtype: :class:`str`
"""
s1 = first_... | python | def camel_to_underscore(name):
"""CamelCase로 주어진 ``name``\ 을 underscore_with_lower_case로 변환합니다
.. code-block:: python
>>> camel_to_underscore('SomePythonClass')
'some_python_class'
:param str name: name to convert
:return: converted name
:rtype: :class:`str`
"""
s1 = first_... | [
"def",
"camel_to_underscore",
"(",
"name",
")",
":",
"s1",
"=",
"first_cap_re",
".",
"sub",
"(",
"r'\\1_\\2'",
",",
"name",
")",
"return",
"all_cap_re",
".",
"sub",
"(",
"r'\\1_\\2'",
",",
"s1",
")",
".",
"lower",
"(",
")"
] | CamelCase로 주어진 ``name``\ 을 underscore_with_lower_case로 변환합니다
.. code-block:: python
>>> camel_to_underscore('SomePythonClass')
'some_python_class'
:param str name: name to convert
:return: converted name
:rtype: :class:`str` | [
"CamelCase로",
"주어진",
"name",
"\\",
"을",
"underscore_with_lower_case로",
"변환합니다"
] | 083ebdeb8ceb109a8f67264b44a652af49b64250 | https://github.com/spoqa/dodotable/blob/083ebdeb8ceb109a8f67264b44a652af49b64250/dodotable/util.py#L27-L41 | train | CamelCase로 주어진 name \ 을 underscore_with_lower_case로 변환합니다. |
spoqa/dodotable | dodotable/util.py | render | def render(template_name, extra_environments=None, **kwargs):
"""주어진 템플릿을 jinja로 렌더링합니다
:param template_name:
:return:
"""
if extra_environments is None:
extra_environments = {}
default_loader = PackageLoader('dodotable', 'templates')
loader = extra_environments.get(
'templ... | python | def render(template_name, extra_environments=None, **kwargs):
"""주어진 템플릿을 jinja로 렌더링합니다
:param template_name:
:return:
"""
if extra_environments is None:
extra_environments = {}
default_loader = PackageLoader('dodotable', 'templates')
loader = extra_environments.get(
'templ... | [
"def",
"render",
"(",
"template_name",
",",
"extra_environments",
"=",
"None",
",",
"*",
"*",
"kwargs",
")",
":",
"if",
"extra_environments",
"is",
"None",
":",
"extra_environments",
"=",
"{",
"}",
"default_loader",
"=",
"PackageLoader",
"(",
"'dodotable'",
",... | 주어진 템플릿을 jinja로 렌더링합니다
:param template_name:
:return: | [
"주어진",
"템플릿을",
"jinja로",
"렌더링합니다"
] | 083ebdeb8ceb109a8f67264b44a652af49b64250 | https://github.com/spoqa/dodotable/blob/083ebdeb8ceb109a8f67264b44a652af49b64250/dodotable/util.py#L44-L69 | train | Renders a template with the given name. |
StackStorm/pybind | pybind/nos/v7_2_0/rbridge_id/interface/ve/ipv6/__init__.py | ipv6._set_ipv6_anycast_address | def _set_ipv6_anycast_address(self, v, load=False):
"""
Setter method for ipv6_anycast_address, mapped from YANG variable /rbridge_id/interface/ve/ipv6/ipv6_anycast_address (list)
If this variable is read-only (config: false) in the
source YANG file, then _set_ipv6_anycast_address is considered as a pri... | python | def _set_ipv6_anycast_address(self, v, load=False):
"""
Setter method for ipv6_anycast_address, mapped from YANG variable /rbridge_id/interface/ve/ipv6/ipv6_anycast_address (list)
If this variable is read-only (config: false) in the
source YANG file, then _set_ipv6_anycast_address is considered as a pri... | [
"def",
"_set_ipv6_anycast_address",
"(",
"self",
",",
"v",
",",
"load",
"=",
"False",
")",
":",
"if",
"hasattr",
"(",
"v",
",",
"\"_utype\"",
")",
":",
"v",
"=",
"v",
".",
"_utype",
"(",
"v",
")",
"try",
":",
"t",
"=",
"YANGDynClass",
"(",
"v",
"... | Setter method for ipv6_anycast_address, mapped from YANG variable /rbridge_id/interface/ve/ipv6/ipv6_anycast_address (list)
If this variable is read-only (config: false) in the
source YANG file, then _set_ipv6_anycast_address is considered as a private
method. Backends looking to populate this variable shou... | [
"Setter",
"method",
"for",
"ipv6_anycast_address",
"mapped",
"from",
"YANG",
"variable",
"/",
"rbridge_id",
"/",
"interface",
"/",
"ve",
"/",
"ipv6",
"/",
"ipv6_anycast_address",
"(",
"list",
")",
"If",
"this",
"variable",
"is",
"read",
"-",
"only",
"(",
"co... | 44c467e71b2b425be63867aba6e6fa28b2cfe7fb | https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/nos/v7_2_0/rbridge_id/interface/ve/ipv6/__init__.py#L147-L168 | train | Sets the IPv6 address of an interface. |
StackStorm/pybind | pybind/nos/v6_0_2f/rbridge_id/ag/nport_menu/nport_interface/nport/map_/__init__.py | map_._set_map_fport | def _set_map_fport(self, v, load=False):
"""
Setter method for map_fport, mapped from YANG variable /rbridge_id/ag/nport_menu/nport_interface/nport/map/map_fport (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_map_fport is considered as a private
method. ... | python | def _set_map_fport(self, v, load=False):
"""
Setter method for map_fport, mapped from YANG variable /rbridge_id/ag/nport_menu/nport_interface/nport/map/map_fport (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_map_fport is considered as a private
method. ... | [
"def",
"_set_map_fport",
"(",
"self",
",",
"v",
",",
"load",
"=",
"False",
")",
":",
"if",
"hasattr",
"(",
"v",
",",
"\"_utype\"",
")",
":",
"v",
"=",
"v",
".",
"_utype",
"(",
"v",
")",
"try",
":",
"t",
"=",
"YANGDynClass",
"(",
"v",
",",
"base... | Setter method for map_fport, mapped from YANG variable /rbridge_id/ag/nport_menu/nport_interface/nport/map/map_fport (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_map_fport is considered as a private
method. Backends looking to populate this variable should
... | [
"Setter",
"method",
"for",
"map_fport",
"mapped",
"from",
"YANG",
"variable",
"/",
"rbridge_id",
"/",
"ag",
"/",
"nport_menu",
"/",
"nport_interface",
"/",
"nport",
"/",
"map",
"/",
"map_fport",
"(",
"container",
")",
"If",
"this",
"variable",
"is",
"read",
... | 44c467e71b2b425be63867aba6e6fa28b2cfe7fb | https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/nos/v6_0_2f/rbridge_id/ag/nport_menu/nport_interface/nport/map_/__init__.py#L92-L113 | train | Sets the fport of the
based on the given map_fport value. |
StackStorm/pybind | pybind/nos/v6_0_2f/rbridge_id/threshold_monitor/__init__.py | threshold_monitor._set_security | def _set_security(self, v, load=False):
"""
Setter method for security, mapped from YANG variable /rbridge_id/threshold_monitor/security (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_security is considered as a private
method. Backends looking to popula... | python | def _set_security(self, v, load=False):
"""
Setter method for security, mapped from YANG variable /rbridge_id/threshold_monitor/security (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_security is considered as a private
method. Backends looking to popula... | [
"def",
"_set_security",
"(",
"self",
",",
"v",
",",
"load",
"=",
"False",
")",
":",
"if",
"hasattr",
"(",
"v",
",",
"\"_utype\"",
")",
":",
"v",
"=",
"v",
".",
"_utype",
"(",
"v",
")",
"try",
":",
"t",
"=",
"YANGDynClass",
"(",
"v",
",",
"base"... | Setter method for security, mapped from YANG variable /rbridge_id/threshold_monitor/security (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_security is considered as a private
method. Backends looking to populate this variable should
do so via calling thisOb... | [
"Setter",
"method",
"for",
"security",
"mapped",
"from",
"YANG",
"variable",
"/",
"rbridge_id",
"/",
"threshold_monitor",
"/",
"security",
"(",
"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/threshold_monitor/__init__.py#L133-L154 | train | Sets the security property of the
|
coyo8/parinx | parinx/parser.py | parse_request_headers | def parse_request_headers(headers):
"""
convert headers in human readable format
:param headers:
:return:
"""
request_header_keys = set(headers.keys(lower=True))
request_meta_keys = set(XHEADERS_TO_ARGS_DICT.keys())
data_header_keys = request_header_keys.intersection(request_meta_keys)
... | python | def parse_request_headers(headers):
"""
convert headers in human readable format
:param headers:
:return:
"""
request_header_keys = set(headers.keys(lower=True))
request_meta_keys = set(XHEADERS_TO_ARGS_DICT.keys())
data_header_keys = request_header_keys.intersection(request_meta_keys)
... | [
"def",
"parse_request_headers",
"(",
"headers",
")",
":",
"request_header_keys",
"=",
"set",
"(",
"headers",
".",
"keys",
"(",
"lower",
"=",
"True",
")",
")",
"request_meta_keys",
"=",
"set",
"(",
"XHEADERS_TO_ARGS_DICT",
".",
"keys",
"(",
")",
")",
"data_he... | convert headers in human readable format
:param headers:
:return: | [
"convert",
"headers",
"in",
"human",
"readable",
"format"
] | 6493798ceba8089345d970f71be4a896eb6b081d | https://github.com/coyo8/parinx/blob/6493798ceba8089345d970f71be4a896eb6b081d/parinx/parser.py#L48-L59 | train | convert headers in human readable format |
coyo8/parinx | parinx/parser.py | split_docstring | def split_docstring(docstring):
"""
Separates the method's description and paramter's
:return: Return description string and list of fields strings
"""
docstring_list = [line.strip() for line in docstring.splitlines()]
description_list = list(
takewhile(lambda line: not (line.startswith... | python | def split_docstring(docstring):
"""
Separates the method's description and paramter's
:return: Return description string and list of fields strings
"""
docstring_list = [line.strip() for line in docstring.splitlines()]
description_list = list(
takewhile(lambda line: not (line.startswith... | [
"def",
"split_docstring",
"(",
"docstring",
")",
":",
"docstring_list",
"=",
"[",
"line",
".",
"strip",
"(",
")",
"for",
"line",
"in",
"docstring",
".",
"splitlines",
"(",
")",
"]",
"description_list",
"=",
"list",
"(",
"takewhile",
"(",
"lambda",
"line",
... | Separates the method's description and paramter's
:return: Return description string and list of fields strings | [
"Separates",
"the",
"method",
"s",
"description",
"and",
"paramter",
"s"
] | 6493798ceba8089345d970f71be4a896eb6b081d | https://github.com/coyo8/parinx/blob/6493798ceba8089345d970f71be4a896eb6b081d/parinx/parser.py#L125-L151 | train | Splits the method s description and paramter s
. |
coyo8/parinx | parinx/parser.py | get_method_docstring | def get_method_docstring(cls, method_name):
"""
return method docstring
if method docstring is empty we get docstring from parent
:param method:
:type method:
:return:
:rtype:
"""
method = getattr(cls, method_name, None)
if method is None:
return
docstrign = inspect... | python | def get_method_docstring(cls, method_name):
"""
return method docstring
if method docstring is empty we get docstring from parent
:param method:
:type method:
:return:
:rtype:
"""
method = getattr(cls, method_name, None)
if method is None:
return
docstrign = inspect... | [
"def",
"get_method_docstring",
"(",
"cls",
",",
"method_name",
")",
":",
"method",
"=",
"getattr",
"(",
"cls",
",",
"method_name",
",",
"None",
")",
"if",
"method",
"is",
"None",
":",
"return",
"docstrign",
"=",
"inspect",
".",
"getdoc",
"(",
"method",
"... | return method docstring
if method docstring is empty we get docstring from parent
:param method:
:type method:
:return:
:rtype: | [
"return",
"method",
"docstring",
"if",
"method",
"docstring",
"is",
"empty",
"we",
"get",
"docstring",
"from",
"parent"
] | 6493798ceba8089345d970f71be4a896eb6b081d | https://github.com/coyo8/parinx/blob/6493798ceba8089345d970f71be4a896eb6b081d/parinx/parser.py#L154-L176 | train | get the docstring of a method from the base class |
coyo8/parinx | parinx/parser.py | parse_docstring | def parse_docstring(docstring, cls=None):
"""
:return: return dict
description - method description
arguments - dict of dicts arg_name: {description, type_name, required}
return - dict: {description, type}
"""
def_arg_dict = lambda: {'description': None,
... | python | def parse_docstring(docstring, cls=None):
"""
:return: return dict
description - method description
arguments - dict of dicts arg_name: {description, type_name, required}
return - dict: {description, type}
"""
def_arg_dict = lambda: {'description': None,
... | [
"def",
"parse_docstring",
"(",
"docstring",
",",
"cls",
"=",
"None",
")",
":",
"def_arg_dict",
"=",
"lambda",
":",
"{",
"'description'",
":",
"None",
",",
"'type_name'",
":",
"None",
",",
"'required'",
":",
"False",
",",
"}",
"description",
",",
"fields_li... | :return: return dict
description - method description
arguments - dict of dicts arg_name: {description, type_name, required}
return - dict: {description, type} | [
":",
"return",
":",
"return",
"dict",
"description",
"-",
"method",
"description",
"arguments",
"-",
"dict",
"of",
"dicts",
"arg_name",
":",
"{",
"description",
"type_name",
"required",
"}",
"return",
"-",
"dict",
":",
"{",
"description",
"type",
"}"
] | 6493798ceba8089345d970f71be4a896eb6b081d | https://github.com/coyo8/parinx/blob/6493798ceba8089345d970f71be4a896eb6b081d/parinx/parser.py#L207-L260 | train | Parses a docstring into a dictionary of parameters and return values. |
StackStorm/pybind | pybind/slxos/v17r_1_01a/routing_system/interface/ve/ipv6/ipv6_nd_ra/ipv6_intf_cmds/nd/address/__init__.py | address._set_suppressing_address | def _set_suppressing_address(self, v, load=False):
"""
Setter method for suppressing_address, mapped from YANG variable /routing_system/interface/ve/ipv6/ipv6_nd_ra/ipv6_intf_cmds/nd/address/suppressing_address (list)
If this variable is read-only (config: false) in the
source YANG file, then _set_suppr... | python | def _set_suppressing_address(self, v, load=False):
"""
Setter method for suppressing_address, mapped from YANG variable /routing_system/interface/ve/ipv6/ipv6_nd_ra/ipv6_intf_cmds/nd/address/suppressing_address (list)
If this variable is read-only (config: false) in the
source YANG file, then _set_suppr... | [
"def",
"_set_suppressing_address",
"(",
"self",
",",
"v",
",",
"load",
"=",
"False",
")",
":",
"if",
"hasattr",
"(",
"v",
",",
"\"_utype\"",
")",
":",
"v",
"=",
"v",
".",
"_utype",
"(",
"v",
")",
"try",
":",
"t",
"=",
"YANGDynClass",
"(",
"v",
",... | Setter method for suppressing_address, mapped from YANG variable /routing_system/interface/ve/ipv6/ipv6_nd_ra/ipv6_intf_cmds/nd/address/suppressing_address (list)
If this variable is read-only (config: false) in the
source YANG file, then _set_suppressing_address is considered as a private
method. Backends ... | [
"Setter",
"method",
"for",
"suppressing_address",
"mapped",
"from",
"YANG",
"variable",
"/",
"routing_system",
"/",
"interface",
"/",
"ve",
"/",
"ipv6",
"/",
"ipv6_nd_ra",
"/",
"ipv6_intf_cmds",
"/",
"nd",
"/",
"address",
"/",
"suppressing_address",
"(",
"list",... | 44c467e71b2b425be63867aba6e6fa28b2cfe7fb | https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/slxos/v17r_1_01a/routing_system/interface/ve/ipv6/ipv6_nd_ra/ipv6_intf_cmds/nd/address/__init__.py#L93-L114 | train | Sets the suppressing address of the node. |
StackStorm/pybind | pybind/slxos/v17s_1_02/routing_system/router/isis/router_isis_cmds_holder/address_family/ipv4/__init__.py | ipv4._set_af_ipv4_unicast | def _set_af_ipv4_unicast(self, v, load=False):
"""
Setter method for af_ipv4_unicast, mapped from YANG variable /routing_system/router/isis/router_isis_cmds_holder/address_family/ipv4/af_ipv4_unicast (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_af_ipv4_uni... | python | def _set_af_ipv4_unicast(self, v, load=False):
"""
Setter method for af_ipv4_unicast, mapped from YANG variable /routing_system/router/isis/router_isis_cmds_holder/address_family/ipv4/af_ipv4_unicast (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_af_ipv4_uni... | [
"def",
"_set_af_ipv4_unicast",
"(",
"self",
",",
"v",
",",
"load",
"=",
"False",
")",
":",
"if",
"hasattr",
"(",
"v",
",",
"\"_utype\"",
")",
":",
"v",
"=",
"v",
".",
"_utype",
"(",
"v",
")",
"try",
":",
"t",
"=",
"YANGDynClass",
"(",
"v",
",",
... | Setter method for af_ipv4_unicast, mapped from YANG variable /routing_system/router/isis/router_isis_cmds_holder/address_family/ipv4/af_ipv4_unicast (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_af_ipv4_unicast is considered as a private
method. Backends lookin... | [
"Setter",
"method",
"for",
"af_ipv4_unicast",
"mapped",
"from",
"YANG",
"variable",
"/",
"routing_system",
"/",
"router",
"/",
"isis",
"/",
"router_isis_cmds_holder",
"/",
"address_family",
"/",
"ipv4",
"/",
"af_ipv4_unicast",
"(",
"container",
")",
"If",
"this",
... | 44c467e71b2b425be63867aba6e6fa28b2cfe7fb | https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/slxos/v17s_1_02/routing_system/router/isis/router_isis_cmds_holder/address_family/ipv4/__init__.py#L92-L113 | train | Sets the value of the af_ipv4_unicast variable. |
StackStorm/pybind | pybind/nos/v6_0_2f/rbridge_id/vcs/__init__.py | vcs._set_auto_shut | def _set_auto_shut(self, v, load=False):
"""
Setter method for auto_shut, mapped from YANG variable /rbridge_id/vcs/auto_shut (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_auto_shut is considered as a private
method. Backends looking to populate this va... | python | def _set_auto_shut(self, v, load=False):
"""
Setter method for auto_shut, mapped from YANG variable /rbridge_id/vcs/auto_shut (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_auto_shut is considered as a private
method. Backends looking to populate this va... | [
"def",
"_set_auto_shut",
"(",
"self",
",",
"v",
",",
"load",
"=",
"False",
")",
":",
"if",
"hasattr",
"(",
"v",
",",
"\"_utype\"",
")",
":",
"v",
"=",
"v",
".",
"_utype",
"(",
"v",
")",
"try",
":",
"t",
"=",
"YANGDynClass",
"(",
"v",
",",
"base... | Setter method for auto_shut, mapped from YANG variable /rbridge_id/vcs/auto_shut (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_auto_shut is considered as a private
method. Backends looking to populate this variable should
do so via calling thisObj._set_auto... | [
"Setter",
"method",
"for",
"auto_shut",
"mapped",
"from",
"YANG",
"variable",
"/",
"rbridge_id",
"/",
"vcs",
"/",
"auto_shut",
"(",
"container",
")",
"If",
"this",
"variable",
"is",
"read",
"-",
"only",
"(",
"config",
":",
"false",
")",
"in",
"the",
"sou... | 44c467e71b2b425be63867aba6e6fa28b2cfe7fb | https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/nos/v6_0_2f/rbridge_id/vcs/__init__.py#L92-L113 | train | Sets the auto - shut property of the
. |
StackStorm/pybind | pybind/slxos/v17r_2_00/cluster/__init__.py | cluster._set_designated_forwarder_hold_time | def _set_designated_forwarder_hold_time(self, v, load=False):
"""
Setter method for designated_forwarder_hold_time, mapped from YANG variable /cluster/designated_forwarder_hold_time (uint16)
If this variable is read-only (config: false) in the
source YANG file, then _set_designated_forwarder_hold_time i... | python | def _set_designated_forwarder_hold_time(self, v, load=False):
"""
Setter method for designated_forwarder_hold_time, mapped from YANG variable /cluster/designated_forwarder_hold_time (uint16)
If this variable is read-only (config: false) in the
source YANG file, then _set_designated_forwarder_hold_time i... | [
"def",
"_set_designated_forwarder_hold_time",
"(",
"self",
",",
"v",
",",
"load",
"=",
"False",
")",
":",
"if",
"hasattr",
"(",
"v",
",",
"\"_utype\"",
")",
":",
"v",
"=",
"v",
".",
"_utype",
"(",
"v",
")",
"try",
":",
"t",
"=",
"YANGDynClass",
"(",
... | Setter method for designated_forwarder_hold_time, mapped from YANG variable /cluster/designated_forwarder_hold_time (uint16)
If this variable is read-only (config: false) in the
source YANG file, then _set_designated_forwarder_hold_time is considered as a private
method. Backends looking to populate this va... | [
"Setter",
"method",
"for",
"designated_forwarder_hold_time",
"mapped",
"from",
"YANG",
"variable",
"/",
"cluster",
"/",
"designated_forwarder_hold_time",
"(",
"uint16",
")",
"If",
"this",
"variable",
"is",
"read",
"-",
"only",
"(",
"config",
":",
"false",
")",
"... | 44c467e71b2b425be63867aba6e6fa28b2cfe7fb | https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/slxos/v17r_2_00/cluster/__init__.py#L317-L338 | train | Sets the time in seconds to wait before electing a designated forwarder. |
StackStorm/pybind | pybind/slxos/v17r_2_00/cluster/__init__.py | cluster._set_client | def _set_client(self, v, load=False):
"""
Setter method for client, mapped from YANG variable /cluster/client (list)
If this variable is read-only (config: false) in the
source YANG file, then _set_client is considered as a private
method. Backends looking to populate this variable should
do so ... | python | def _set_client(self, v, load=False):
"""
Setter method for client, mapped from YANG variable /cluster/client (list)
If this variable is read-only (config: false) in the
source YANG file, then _set_client is considered as a private
method. Backends looking to populate this variable should
do so ... | [
"def",
"_set_client",
"(",
"self",
",",
"v",
",",
"load",
"=",
"False",
")",
":",
"if",
"hasattr",
"(",
"v",
",",
"\"_utype\"",
")",
":",
"v",
"=",
"v",
".",
"_utype",
"(",
"v",
")",
"try",
":",
"t",
"=",
"YANGDynClass",
"(",
"v",
",",
"base",
... | Setter method for client, mapped from YANG variable /cluster/client (list)
If this variable is read-only (config: false) in the
source YANG file, then _set_client is considered as a private
method. Backends looking to populate this variable should
do so via calling thisObj._set_client() directly. | [
"Setter",
"method",
"for",
"client",
"mapped",
"from",
"YANG",
"variable",
"/",
"cluster",
"/",
"client",
"(",
"list",
")",
"If",
"this",
"variable",
"is",
"read",
"-",
"only",
"(",
"config",
":",
"false",
")",
"in",
"the",
"source",
"YANG",
"file",
"t... | 44c467e71b2b425be63867aba6e6fa28b2cfe7fb | https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/slxos/v17r_2_00/cluster/__init__.py#L383-L404 | train | Sets the client property of the cluster node. |
StackStorm/pybind | pybind/slxos/v17r_2_00/cluster/__init__.py | cluster._set_client_pw | def _set_client_pw(self, v, load=False):
"""
Setter method for client_pw, mapped from YANG variable /cluster/client_pw (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_client_pw is considered as a private
method. Backends looking to populate this variable ... | python | def _set_client_pw(self, v, load=False):
"""
Setter method for client_pw, mapped from YANG variable /cluster/client_pw (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_client_pw is considered as a private
method. Backends looking to populate this variable ... | [
"def",
"_set_client_pw",
"(",
"self",
",",
"v",
",",
"load",
"=",
"False",
")",
":",
"if",
"hasattr",
"(",
"v",
",",
"\"_utype\"",
")",
":",
"v",
"=",
"v",
".",
"_utype",
"(",
"v",
")",
"try",
":",
"t",
"=",
"YANGDynClass",
"(",
"v",
",",
"base... | Setter method for client_pw, mapped from YANG variable /cluster/client_pw (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_client_pw is considered as a private
method. Backends looking to populate this variable should
do so via calling thisObj._set_client_pw()... | [
"Setter",
"method",
"for",
"client_pw",
"mapped",
"from",
"YANG",
"variable",
"/",
"cluster",
"/",
"client_pw",
"(",
"container",
")",
"If",
"this",
"variable",
"is",
"read",
"-",
"only",
"(",
"config",
":",
"false",
")",
"in",
"the",
"source",
"YANG",
"... | 44c467e71b2b425be63867aba6e6fa28b2cfe7fb | https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/slxos/v17r_2_00/cluster/__init__.py#L418-L441 | train | Sets the client - pseudo - wire for the cluster. |
StackStorm/pybind | pybind/nos/v6_0_2f/rbridge_id/router/__init__.py | router._set_ospf | def _set_ospf(self, v, load=False):
"""
Setter method for ospf, mapped from YANG variable /rbridge_id/router/ospf (list)
If this variable is read-only (config: false) in the
source YANG file, then _set_ospf is considered as a private
method. Backends looking to populate this variable should
do s... | python | def _set_ospf(self, v, load=False):
"""
Setter method for ospf, mapped from YANG variable /rbridge_id/router/ospf (list)
If this variable is read-only (config: false) in the
source YANG file, then _set_ospf is considered as a private
method. Backends looking to populate this variable should
do s... | [
"def",
"_set_ospf",
"(",
"self",
",",
"v",
",",
"load",
"=",
"False",
")",
":",
"if",
"hasattr",
"(",
"v",
",",
"\"_utype\"",
")",
":",
"v",
"=",
"v",
".",
"_utype",
"(",
"v",
")",
"try",
":",
"t",
"=",
"YANGDynClass",
"(",
"v",
",",
"base",
... | Setter method for ospf, mapped from YANG variable /rbridge_id/router/ospf (list)
If this variable is read-only (config: false) in the
source YANG file, then _set_ospf is considered as a private
method. Backends looking to populate this variable should
do so via calling thisObj._set_ospf() directly. | [
"Setter",
"method",
"for",
"ospf",
"mapped",
"from",
"YANG",
"variable",
"/",
"rbridge_id",
"/",
"router",
"/",
"ospf",
"(",
"list",
")",
"If",
"this",
"variable",
"is",
"read",
"-",
"only",
"(",
"config",
":",
"false",
")",
"in",
"the",
"source",
"YAN... | 44c467e71b2b425be63867aba6e6fa28b2cfe7fb | https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/nos/v6_0_2f/rbridge_id/router/__init__.py#L131-L152 | train | Set the value of the OSPF parameter. |
StackStorm/pybind | pybind/slxos/v17r_2_00/overlay_gateway/__init__.py | overlay_gateway._set_site | def _set_site(self, v, load=False):
"""
Setter method for site, mapped from YANG variable /overlay_gateway/site (list)
If this variable is read-only (config: false) in the
source YANG file, then _set_site is considered as a private
method. Backends looking to populate this variable should
do so ... | python | def _set_site(self, v, load=False):
"""
Setter method for site, mapped from YANG variable /overlay_gateway/site (list)
If this variable is read-only (config: false) in the
source YANG file, then _set_site is considered as a private
method. Backends looking to populate this variable should
do so ... | [
"def",
"_set_site",
"(",
"self",
",",
"v",
",",
"load",
"=",
"False",
")",
":",
"if",
"hasattr",
"(",
"v",
",",
"\"_utype\"",
")",
":",
"v",
"=",
"v",
".",
"_utype",
"(",
"v",
")",
"try",
":",
"t",
"=",
"YANGDynClass",
"(",
"v",
",",
"base",
... | Setter method for site, mapped from YANG variable /overlay_gateway/site (list)
If this variable is read-only (config: false) in the
source YANG file, then _set_site is considered as a private
method. Backends looking to populate this variable should
do so via calling thisObj._set_site() directly.
Y... | [
"Setter",
"method",
"for",
"site",
"mapped",
"from",
"YANG",
"variable",
"/",
"overlay_gateway",
"/",
"site",
"(",
"list",
")",
"If",
"this",
"variable",
"is",
"read",
"-",
"only",
"(",
"config",
":",
"false",
")",
"in",
"the",
"source",
"YANG",
"file",
... | 44c467e71b2b425be63867aba6e6fa28b2cfe7fb | https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/slxos/v17r_2_00/overlay_gateway/__init__.py#L318-L342 | train | Sets the site of the cluster. |
StackStorm/pybind | pybind/slxos/v17s_1_02/protocol/cfm/domain_name/__init__.py | domain_name._set_domain_name | def _set_domain_name(self, v, load=False):
"""
Setter method for domain_name, mapped from YANG variable /protocol/cfm/domain_name/domain_name (string)
If this variable is read-only (config: false) in the
source YANG file, then _set_domain_name is considered as a private
method. Backends looking to p... | python | def _set_domain_name(self, v, load=False):
"""
Setter method for domain_name, mapped from YANG variable /protocol/cfm/domain_name/domain_name (string)
If this variable is read-only (config: false) in the
source YANG file, then _set_domain_name is considered as a private
method. Backends looking to p... | [
"def",
"_set_domain_name",
"(",
"self",
",",
"v",
",",
"load",
"=",
"False",
")",
":",
"parent",
"=",
"getattr",
"(",
"self",
",",
"\"_parent\"",
",",
"None",
")",
"if",
"parent",
"is",
"not",
"None",
"and",
"load",
"is",
"False",
":",
"raise",
"Attr... | Setter method for domain_name, mapped from YANG variable /protocol/cfm/domain_name/domain_name (string)
If this variable is read-only (config: false) in the
source YANG file, then _set_domain_name is considered as a private
method. Backends looking to populate this variable should
do so via calling this... | [
"Setter",
"method",
"for",
"domain_name",
"mapped",
"from",
"YANG",
"variable",
"/",
"protocol",
"/",
"cfm",
"/",
"domain_name",
"/",
"domain_name",
"(",
"string",
")",
"If",
"this",
"variable",
"is",
"read",
"-",
"only",
"(",
"config",
":",
"false",
")",
... | 44c467e71b2b425be63867aba6e6fa28b2cfe7fb | https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/slxos/v17s_1_02/protocol/cfm/domain_name/__init__.py#L94-L120 | train | Sets the domain name of the node. |
StackStorm/pybind | pybind/slxos/v17s_1_02/protocol/cfm/domain_name/__init__.py | domain_name._set_domain_level | def _set_domain_level(self, v, load=False):
"""
Setter method for domain_level, mapped from YANG variable /protocol/cfm/domain_name/domain_level (uint32)
If this variable is read-only (config: false) in the
source YANG file, then _set_domain_level is considered as a private
method. Backends looking ... | python | def _set_domain_level(self, v, load=False):
"""
Setter method for domain_level, mapped from YANG variable /protocol/cfm/domain_name/domain_level (uint32)
If this variable is read-only (config: false) in the
source YANG file, then _set_domain_level is considered as a private
method. Backends looking ... | [
"def",
"_set_domain_level",
"(",
"self",
",",
"v",
",",
"load",
"=",
"False",
")",
":",
"if",
"hasattr",
"(",
"v",
",",
"\"_utype\"",
")",
":",
"v",
"=",
"v",
".",
"_utype",
"(",
"v",
")",
"try",
":",
"t",
"=",
"YANGDynClass",
"(",
"v",
",",
"b... | Setter method for domain_level, mapped from YANG variable /protocol/cfm/domain_name/domain_level (uint32)
If this variable is read-only (config: false) in the
source YANG file, then _set_domain_level is considered as a private
method. Backends looking to populate this variable should
do so via calling t... | [
"Setter",
"method",
"for",
"domain_level",
"mapped",
"from",
"YANG",
"variable",
"/",
"protocol",
"/",
"cfm",
"/",
"domain_name",
"/",
"domain_level",
"(",
"uint32",
")",
"If",
"this",
"variable",
"is",
"read",
"-",
"only",
"(",
"config",
":",
"false",
")"... | 44c467e71b2b425be63867aba6e6fa28b2cfe7fb | https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/slxos/v17s_1_02/protocol/cfm/domain_name/__init__.py#L132-L153 | train | Sets the domain level of the
|
StackStorm/pybind | pybind/slxos/v17s_1_02/protocol/cfm/domain_name/__init__.py | domain_name._set_ma_name | def _set_ma_name(self, v, load=False):
"""
Setter method for ma_name, mapped from YANG variable /protocol/cfm/domain_name/ma_name (list)
If this variable is read-only (config: false) in the
source YANG file, then _set_ma_name is considered as a private
method. Backends looking to populate this varia... | python | def _set_ma_name(self, v, load=False):
"""
Setter method for ma_name, mapped from YANG variable /protocol/cfm/domain_name/ma_name (list)
If this variable is read-only (config: false) in the
source YANG file, then _set_ma_name is considered as a private
method. Backends looking to populate this varia... | [
"def",
"_set_ma_name",
"(",
"self",
",",
"v",
",",
"load",
"=",
"False",
")",
":",
"if",
"hasattr",
"(",
"v",
",",
"\"_utype\"",
")",
":",
"v",
"=",
"v",
".",
"_utype",
"(",
"v",
")",
"try",
":",
"t",
"=",
"YANGDynClass",
"(",
"v",
",",
"base",... | Setter method for ma_name, mapped from YANG variable /protocol/cfm/domain_name/ma_name (list)
If this variable is read-only (config: false) in the
source YANG file, then _set_ma_name is considered as a private
method. Backends looking to populate this variable should
do so via calling thisObj._set_ma_na... | [
"Setter",
"method",
"for",
"ma_name",
"mapped",
"from",
"YANG",
"variable",
"/",
"protocol",
"/",
"cfm",
"/",
"domain_name",
"/",
"ma_name",
"(",
"list",
")",
"If",
"this",
"variable",
"is",
"read",
"-",
"only",
"(",
"config",
":",
"false",
")",
"in",
... | 44c467e71b2b425be63867aba6e6fa28b2cfe7fb | https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/slxos/v17s_1_02/protocol/cfm/domain_name/__init__.py#L165-L186 | train | Set the name of the Maintance Association. |
StackStorm/pybind | pybind/slxos/v17s_1_02/routing_system/router/isis/router_isis_cmds_holder/__init__.py | router_isis_cmds_holder._set_net | def _set_net(self, v, load=False):
"""
Setter method for net, mapped from YANG variable /routing_system/router/isis/router_isis_cmds_holder/net (list)
If this variable is read-only (config: false) in the
source YANG file, then _set_net is considered as a private
method. Backends looking to populate ... | python | def _set_net(self, v, load=False):
"""
Setter method for net, mapped from YANG variable /routing_system/router/isis/router_isis_cmds_holder/net (list)
If this variable is read-only (config: false) in the
source YANG file, then _set_net is considered as a private
method. Backends looking to populate ... | [
"def",
"_set_net",
"(",
"self",
",",
"v",
",",
"load",
"=",
"False",
")",
":",
"if",
"hasattr",
"(",
"v",
",",
"\"_utype\"",
")",
":",
"v",
"=",
"v",
".",
"_utype",
"(",
"v",
")",
"try",
":",
"t",
"=",
"YANGDynClass",
"(",
"v",
",",
"base",
"... | Setter method for net, mapped from YANG variable /routing_system/router/isis/router_isis_cmds_holder/net (list)
If this variable is read-only (config: false) in the
source YANG file, then _set_net is considered as a private
method. Backends looking to populate this variable should
do so via calling this... | [
"Setter",
"method",
"for",
"net",
"mapped",
"from",
"YANG",
"variable",
"/",
"routing_system",
"/",
"router",
"/",
"isis",
"/",
"router_isis_cmds_holder",
"/",
"net",
"(",
"list",
")",
"If",
"this",
"variable",
"is",
"read",
"-",
"only",
"(",
"config",
":"... | 44c467e71b2b425be63867aba6e6fa28b2cfe7fb | https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/slxos/v17s_1_02/routing_system/router/isis/router_isis_cmds_holder/__init__.py#L96-L117 | train | Set the net property of the
|
StackStorm/pybind | pybind/slxos/v17s_1_02/interface/ethernet/switchport/__init__.py | switchport._set_port_security | def _set_port_security(self, v, load=False):
"""
Setter method for port_security, mapped from YANG variable /interface/ethernet/switchport/port_security (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_port_security is considered as a private
method. Backe... | python | def _set_port_security(self, v, load=False):
"""
Setter method for port_security, mapped from YANG variable /interface/ethernet/switchport/port_security (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_port_security is considered as a private
method. Backe... | [
"def",
"_set_port_security",
"(",
"self",
",",
"v",
",",
"load",
"=",
"False",
")",
":",
"if",
"hasattr",
"(",
"v",
",",
"\"_utype\"",
")",
":",
"v",
"=",
"v",
".",
"_utype",
"(",
"v",
")",
"try",
":",
"t",
"=",
"YANGDynClass",
"(",
"v",
",",
"... | Setter method for port_security, mapped from YANG variable /interface/ethernet/switchport/port_security (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_port_security is considered as a private
method. Backends looking to populate this variable should
do so vi... | [
"Setter",
"method",
"for",
"port_security",
"mapped",
"from",
"YANG",
"variable",
"/",
"interface",
"/",
"ethernet",
"/",
"switchport",
"/",
"port_security",
"(",
"container",
")",
"If",
"this",
"variable",
"is",
"read",
"-",
"only",
"(",
"config",
":",
"fal... | 44c467e71b2b425be63867aba6e6fa28b2cfe7fb | https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/slxos/v17s_1_02/interface/ethernet/switchport/__init__.py#L147-L170 | train | Sets the port - security property of the
|
StackStorm/pybind | pybind/slxos/v17s_1_02/interface/ethernet/switchport/__init__.py | switchport._set_access_mac_vlan_classification | def _set_access_mac_vlan_classification(self, v, load=False):
"""
Setter method for access_mac_vlan_classification, mapped from YANG variable /interface/ethernet/switchport/access_mac_vlan_classification (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_access_... | python | def _set_access_mac_vlan_classification(self, v, load=False):
"""
Setter method for access_mac_vlan_classification, mapped from YANG variable /interface/ethernet/switchport/access_mac_vlan_classification (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_access_... | [
"def",
"_set_access_mac_vlan_classification",
"(",
"self",
",",
"v",
",",
"load",
"=",
"False",
")",
":",
"if",
"hasattr",
"(",
"v",
",",
"\"_utype\"",
")",
":",
"v",
"=",
"v",
".",
"_utype",
"(",
"v",
")",
"try",
":",
"t",
"=",
"YANGDynClass",
"(",
... | Setter method for access_mac_vlan_classification, mapped from YANG variable /interface/ethernet/switchport/access_mac_vlan_classification (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_access_mac_vlan_classification is considered as a private
method. Backends lo... | [
"Setter",
"method",
"for",
"access_mac_vlan_classification",
"mapped",
"from",
"YANG",
"variable",
"/",
"interface",
"/",
"ethernet",
"/",
"switchport",
"/",
"access_mac_vlan_classification",
"(",
"container",
")",
"If",
"this",
"variable",
"is",
"read",
"-",
"only"... | 44c467e71b2b425be63867aba6e6fa28b2cfe7fb | https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/slxos/v17s_1_02/interface/ethernet/switchport/__init__.py#L221-L242 | train | Sets the access - mac - vlan - classification of the mac vlan. |
StackStorm/pybind | pybind/nos/v6_0_2f/brocade_vswitch_rpc/__init__.py | brocade_vswitch._set_get_vnetwork_hosts | def _set_get_vnetwork_hosts(self, v, load=False):
"""
Setter method for get_vnetwork_hosts, mapped from YANG variable /brocade_vswitch_rpc/get_vnetwork_hosts (rpc)
If this variable is read-only (config: false) in the
source YANG file, then _set_get_vnetwork_hosts is considered as a private
method. B... | python | def _set_get_vnetwork_hosts(self, v, load=False):
"""
Setter method for get_vnetwork_hosts, mapped from YANG variable /brocade_vswitch_rpc/get_vnetwork_hosts (rpc)
If this variable is read-only (config: false) in the
source YANG file, then _set_get_vnetwork_hosts is considered as a private
method. B... | [
"def",
"_set_get_vnetwork_hosts",
"(",
"self",
",",
"v",
",",
"load",
"=",
"False",
")",
":",
"if",
"hasattr",
"(",
"v",
",",
"\"_utype\"",
")",
":",
"v",
"=",
"v",
".",
"_utype",
"(",
"v",
")",
"try",
":",
"t",
"=",
"YANGDynClass",
"(",
"v",
","... | Setter method for get_vnetwork_hosts, mapped from YANG variable /brocade_vswitch_rpc/get_vnetwork_hosts (rpc)
If this variable is read-only (config: false) in the
source YANG file, then _set_get_vnetwork_hosts is considered as a private
method. Backends looking to populate this variable should
do so via... | [
"Setter",
"method",
"for",
"get_vnetwork_hosts",
"mapped",
"from",
"YANG",
"variable",
"/",
"brocade_vswitch_rpc",
"/",
"get_vnetwork_hosts",
"(",
"rpc",
")",
"If",
"this",
"variable",
"is",
"read",
"-",
"only",
"(",
"config",
":",
"false",
")",
"in",
"the",
... | 44c467e71b2b425be63867aba6e6fa28b2cfe7fb | https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/nos/v6_0_2f/brocade_vswitch_rpc/__init__.py#L109-L132 | train | This method is used to set the get_vnetwork_hosts variable in the vswitch. |
StackStorm/pybind | pybind/nos/v6_0_2f/brocade_vswitch_rpc/__init__.py | brocade_vswitch._set_get_vnetwork_vms | def _set_get_vnetwork_vms(self, v, load=False):
"""
Setter method for get_vnetwork_vms, mapped from YANG variable /brocade_vswitch_rpc/get_vnetwork_vms (rpc)
If this variable is read-only (config: false) in the
source YANG file, then _set_get_vnetwork_vms is considered as a private
method. Backends ... | python | def _set_get_vnetwork_vms(self, v, load=False):
"""
Setter method for get_vnetwork_vms, mapped from YANG variable /brocade_vswitch_rpc/get_vnetwork_vms (rpc)
If this variable is read-only (config: false) in the
source YANG file, then _set_get_vnetwork_vms is considered as a private
method. Backends ... | [
"def",
"_set_get_vnetwork_vms",
"(",
"self",
",",
"v",
",",
"load",
"=",
"False",
")",
":",
"if",
"hasattr",
"(",
"v",
",",
"\"_utype\"",
")",
":",
"v",
"=",
"v",
".",
"_utype",
"(",
"v",
")",
"try",
":",
"t",
"=",
"YANGDynClass",
"(",
"v",
",",
... | Setter method for get_vnetwork_vms, mapped from YANG variable /brocade_vswitch_rpc/get_vnetwork_vms (rpc)
If this variable is read-only (config: false) in the
source YANG file, then _set_get_vnetwork_vms is considered as a private
method. Backends looking to populate this variable should
do so via calli... | [
"Setter",
"method",
"for",
"get_vnetwork_vms",
"mapped",
"from",
"YANG",
"variable",
"/",
"brocade_vswitch_rpc",
"/",
"get_vnetwork_vms",
"(",
"rpc",
")",
"If",
"this",
"variable",
"is",
"read",
"-",
"only",
"(",
"config",
":",
"false",
")",
"in",
"the",
"so... | 44c467e71b2b425be63867aba6e6fa28b2cfe7fb | https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/nos/v6_0_2f/brocade_vswitch_rpc/__init__.py#L146-L169 | train | This method is used to set the get_vnetwork_vms property in the vswitch. |
StackStorm/pybind | pybind/nos/v6_0_2f/brocade_vswitch_rpc/__init__.py | brocade_vswitch._set_get_vnetwork_dvpgs | def _set_get_vnetwork_dvpgs(self, v, load=False):
"""
Setter method for get_vnetwork_dvpgs, mapped from YANG variable /brocade_vswitch_rpc/get_vnetwork_dvpgs (rpc)
If this variable is read-only (config: false) in the
source YANG file, then _set_get_vnetwork_dvpgs is considered as a private
method. B... | python | def _set_get_vnetwork_dvpgs(self, v, load=False):
"""
Setter method for get_vnetwork_dvpgs, mapped from YANG variable /brocade_vswitch_rpc/get_vnetwork_dvpgs (rpc)
If this variable is read-only (config: false) in the
source YANG file, then _set_get_vnetwork_dvpgs is considered as a private
method. B... | [
"def",
"_set_get_vnetwork_dvpgs",
"(",
"self",
",",
"v",
",",
"load",
"=",
"False",
")",
":",
"if",
"hasattr",
"(",
"v",
",",
"\"_utype\"",
")",
":",
"v",
"=",
"v",
".",
"_utype",
"(",
"v",
")",
"try",
":",
"t",
"=",
"YANGDynClass",
"(",
"v",
","... | Setter method for get_vnetwork_dvpgs, mapped from YANG variable /brocade_vswitch_rpc/get_vnetwork_dvpgs (rpc)
If this variable is read-only (config: false) in the
source YANG file, then _set_get_vnetwork_dvpgs is considered as a private
method. Backends looking to populate this variable should
do so via... | [
"Setter",
"method",
"for",
"get_vnetwork_dvpgs",
"mapped",
"from",
"YANG",
"variable",
"/",
"brocade_vswitch_rpc",
"/",
"get_vnetwork_dvpgs",
"(",
"rpc",
")",
"If",
"this",
"variable",
"is",
"read",
"-",
"only",
"(",
"config",
":",
"false",
")",
"in",
"the",
... | 44c467e71b2b425be63867aba6e6fa28b2cfe7fb | https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/nos/v6_0_2f/brocade_vswitch_rpc/__init__.py#L183-L206 | train | This method is used to set the value of the get_vnetwork_dvpgs variable in the vswitch. |
StackStorm/pybind | pybind/nos/v6_0_2f/brocade_vswitch_rpc/__init__.py | brocade_vswitch._set_get_vnetwork_dvs | def _set_get_vnetwork_dvs(self, v, load=False):
"""
Setter method for get_vnetwork_dvs, mapped from YANG variable /brocade_vswitch_rpc/get_vnetwork_dvs (rpc)
If this variable is read-only (config: false) in the
source YANG file, then _set_get_vnetwork_dvs is considered as a private
method. Backends ... | python | def _set_get_vnetwork_dvs(self, v, load=False):
"""
Setter method for get_vnetwork_dvs, mapped from YANG variable /brocade_vswitch_rpc/get_vnetwork_dvs (rpc)
If this variable is read-only (config: false) in the
source YANG file, then _set_get_vnetwork_dvs is considered as a private
method. Backends ... | [
"def",
"_set_get_vnetwork_dvs",
"(",
"self",
",",
"v",
",",
"load",
"=",
"False",
")",
":",
"if",
"hasattr",
"(",
"v",
",",
"\"_utype\"",
")",
":",
"v",
"=",
"v",
".",
"_utype",
"(",
"v",
")",
"try",
":",
"t",
"=",
"YANGDynClass",
"(",
"v",
",",
... | Setter method for get_vnetwork_dvs, mapped from YANG variable /brocade_vswitch_rpc/get_vnetwork_dvs (rpc)
If this variable is read-only (config: false) in the
source YANG file, then _set_get_vnetwork_dvs is considered as a private
method. Backends looking to populate this variable should
do so via calli... | [
"Setter",
"method",
"for",
"get_vnetwork_dvs",
"mapped",
"from",
"YANG",
"variable",
"/",
"brocade_vswitch_rpc",
"/",
"get_vnetwork_dvs",
"(",
"rpc",
")",
"If",
"this",
"variable",
"is",
"read",
"-",
"only",
"(",
"config",
":",
"false",
")",
"in",
"the",
"so... | 44c467e71b2b425be63867aba6e6fa28b2cfe7fb | https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/nos/v6_0_2f/brocade_vswitch_rpc/__init__.py#L220-L243 | train | This method is used to set the value of get_vnetwork_dvs in the virtual network. |
StackStorm/pybind | pybind/nos/v6_0_2f/brocade_vswitch_rpc/__init__.py | brocade_vswitch._set_get_vnetwork_vswitches | def _set_get_vnetwork_vswitches(self, v, load=False):
"""
Setter method for get_vnetwork_vswitches, mapped from YANG variable /brocade_vswitch_rpc/get_vnetwork_vswitches (rpc)
If this variable is read-only (config: false) in the
source YANG file, then _set_get_vnetwork_vswitches is considered as a priva... | python | def _set_get_vnetwork_vswitches(self, v, load=False):
"""
Setter method for get_vnetwork_vswitches, mapped from YANG variable /brocade_vswitch_rpc/get_vnetwork_vswitches (rpc)
If this variable is read-only (config: false) in the
source YANG file, then _set_get_vnetwork_vswitches is considered as a priva... | [
"def",
"_set_get_vnetwork_vswitches",
"(",
"self",
",",
"v",
",",
"load",
"=",
"False",
")",
":",
"if",
"hasattr",
"(",
"v",
",",
"\"_utype\"",
")",
":",
"v",
"=",
"v",
".",
"_utype",
"(",
"v",
")",
"try",
":",
"t",
"=",
"YANGDynClass",
"(",
"v",
... | Setter method for get_vnetwork_vswitches, mapped from YANG variable /brocade_vswitch_rpc/get_vnetwork_vswitches (rpc)
If this variable is read-only (config: false) in the
source YANG file, then _set_get_vnetwork_vswitches is considered as a private
method. Backends looking to populate this variable should
... | [
"Setter",
"method",
"for",
"get_vnetwork_vswitches",
"mapped",
"from",
"YANG",
"variable",
"/",
"brocade_vswitch_rpc",
"/",
"get_vnetwork_vswitches",
"(",
"rpc",
")",
"If",
"this",
"variable",
"is",
"read",
"-",
"only",
"(",
"config",
":",
"false",
")",
"in",
... | 44c467e71b2b425be63867aba6e6fa28b2cfe7fb | https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/nos/v6_0_2f/brocade_vswitch_rpc/__init__.py#L257-L280 | train | This method is used to set the value of the get_vnetwork_vswitches property in the virtual network. |
StackStorm/pybind | pybind/nos/v6_0_2f/brocade_vswitch_rpc/__init__.py | brocade_vswitch._set_get_vnetwork_portgroups | def _set_get_vnetwork_portgroups(self, v, load=False):
"""
Setter method for get_vnetwork_portgroups, mapped from YANG variable /brocade_vswitch_rpc/get_vnetwork_portgroups (rpc)
If this variable is read-only (config: false) in the
source YANG file, then _set_get_vnetwork_portgroups is considered as a p... | python | def _set_get_vnetwork_portgroups(self, v, load=False):
"""
Setter method for get_vnetwork_portgroups, mapped from YANG variable /brocade_vswitch_rpc/get_vnetwork_portgroups (rpc)
If this variable is read-only (config: false) in the
source YANG file, then _set_get_vnetwork_portgroups is considered as a p... | [
"def",
"_set_get_vnetwork_portgroups",
"(",
"self",
",",
"v",
",",
"load",
"=",
"False",
")",
":",
"if",
"hasattr",
"(",
"v",
",",
"\"_utype\"",
")",
":",
"v",
"=",
"v",
".",
"_utype",
"(",
"v",
")",
"try",
":",
"t",
"=",
"YANGDynClass",
"(",
"v",
... | Setter method for get_vnetwork_portgroups, mapped from YANG variable /brocade_vswitch_rpc/get_vnetwork_portgroups (rpc)
If this variable is read-only (config: false) in the
source YANG file, then _set_get_vnetwork_portgroups is considered as a private
method. Backends looking to populate this variable shoul... | [
"Setter",
"method",
"for",
"get_vnetwork_portgroups",
"mapped",
"from",
"YANG",
"variable",
"/",
"brocade_vswitch_rpc",
"/",
"get_vnetwork_portgroups",
"(",
"rpc",
")",
"If",
"this",
"variable",
"is",
"read",
"-",
"only",
"(",
"config",
":",
"false",
")",
"in",
... | 44c467e71b2b425be63867aba6e6fa28b2cfe7fb | https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/nos/v6_0_2f/brocade_vswitch_rpc/__init__.py#L294-L317 | train | This method is used to set the value of the get_vnetwork_portgroups variable in the vswitch |
StackStorm/pybind | pybind/nos/v6_0_2f/brocade_vswitch_rpc/__init__.py | brocade_vswitch._set_get_vmpolicy_macaddr | def _set_get_vmpolicy_macaddr(self, v, load=False):
"""
Setter method for get_vmpolicy_macaddr, mapped from YANG variable /brocade_vswitch_rpc/get_vmpolicy_macaddr (rpc)
If this variable is read-only (config: false) in the
source YANG file, then _set_get_vmpolicy_macaddr is considered as a private
m... | python | def _set_get_vmpolicy_macaddr(self, v, load=False):
"""
Setter method for get_vmpolicy_macaddr, mapped from YANG variable /brocade_vswitch_rpc/get_vmpolicy_macaddr (rpc)
If this variable is read-only (config: false) in the
source YANG file, then _set_get_vmpolicy_macaddr is considered as a private
m... | [
"def",
"_set_get_vmpolicy_macaddr",
"(",
"self",
",",
"v",
",",
"load",
"=",
"False",
")",
":",
"if",
"hasattr",
"(",
"v",
",",
"\"_utype\"",
")",
":",
"v",
"=",
"v",
".",
"_utype",
"(",
"v",
")",
"try",
":",
"t",
"=",
"YANGDynClass",
"(",
"v",
"... | Setter method for get_vmpolicy_macaddr, mapped from YANG variable /brocade_vswitch_rpc/get_vmpolicy_macaddr (rpc)
If this variable is read-only (config: false) in the
source YANG file, then _set_get_vmpolicy_macaddr is considered as a private
method. Backends looking to populate this variable should
do ... | [
"Setter",
"method",
"for",
"get_vmpolicy_macaddr",
"mapped",
"from",
"YANG",
"variable",
"/",
"brocade_vswitch_rpc",
"/",
"get_vmpolicy_macaddr",
"(",
"rpc",
")",
"If",
"this",
"variable",
"is",
"read",
"-",
"only",
"(",
"config",
":",
"false",
")",
"in",
"the... | 44c467e71b2b425be63867aba6e6fa28b2cfe7fb | https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/nos/v6_0_2f/brocade_vswitch_rpc/__init__.py#L331-L354 | train | This method is used to set the value of the get_vmpolicy_macaddr property in the virtual node. |
StackStorm/pybind | pybind/nos/v6_0_2f/zoning/__init__.py | zoning._set_defined_configuration | def _set_defined_configuration(self, v, load=False):
"""
Setter method for defined_configuration, mapped from YANG variable /zoning/defined_configuration (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_defined_configuration is considered as a private
meth... | python | def _set_defined_configuration(self, v, load=False):
"""
Setter method for defined_configuration, mapped from YANG variable /zoning/defined_configuration (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_defined_configuration is considered as a private
meth... | [
"def",
"_set_defined_configuration",
"(",
"self",
",",
"v",
",",
"load",
"=",
"False",
")",
":",
"if",
"hasattr",
"(",
"v",
",",
"\"_utype\"",
")",
":",
"v",
"=",
"v",
".",
"_utype",
"(",
"v",
")",
"try",
":",
"t",
"=",
"YANGDynClass",
"(",
"v",
... | Setter method for defined_configuration, mapped from YANG variable /zoning/defined_configuration (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_defined_configuration is considered as a private
method. Backends looking to populate this variable should
do so v... | [
"Setter",
"method",
"for",
"defined_configuration",
"mapped",
"from",
"YANG",
"variable",
"/",
"zoning",
"/",
"defined_configuration",
"(",
"container",
")",
"If",
"this",
"variable",
"is",
"read",
"-",
"only",
"(",
"config",
":",
"false",
")",
"in",
"the",
... | 44c467e71b2b425be63867aba6e6fa28b2cfe7fb | https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/nos/v6_0_2f/zoning/__init__.py#L94-L115 | train | Sets the defined_configuration variable. |
StackStorm/pybind | pybind/nos/v6_0_2f/router/__init__.py | router._set_fabric_virtual_gateway | def _set_fabric_virtual_gateway(self, v, load=False):
"""
Setter method for fabric_virtual_gateway, mapped from YANG variable /router/fabric_virtual_gateway (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_fabric_virtual_gateway is considered as a private
... | python | def _set_fabric_virtual_gateway(self, v, load=False):
"""
Setter method for fabric_virtual_gateway, mapped from YANG variable /router/fabric_virtual_gateway (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_fabric_virtual_gateway is considered as a private
... | [
"def",
"_set_fabric_virtual_gateway",
"(",
"self",
",",
"v",
",",
"load",
"=",
"False",
")",
":",
"if",
"hasattr",
"(",
"v",
",",
"\"_utype\"",
")",
":",
"v",
"=",
"v",
".",
"_utype",
"(",
"v",
")",
"try",
":",
"t",
"=",
"YANGDynClass",
"(",
"v",
... | Setter method for fabric_virtual_gateway, mapped from YANG variable /router/fabric_virtual_gateway (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_fabric_virtual_gateway is considered as a private
method. Backends looking to populate this variable should
do s... | [
"Setter",
"method",
"for",
"fabric_virtual_gateway",
"mapped",
"from",
"YANG",
"variable",
"/",
"router",
"/",
"fabric_virtual_gateway",
"(",
"container",
")",
"If",
"this",
"variable",
"is",
"read",
"-",
"only",
"(",
"config",
":",
"false",
")",
"in",
"the",
... | 44c467e71b2b425be63867aba6e6fa28b2cfe7fb | https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/nos/v6_0_2f/router/__init__.py#L96-L119 | train | Sets the value of the fabric_virtual_gateway variable. |
StackStorm/pybind | pybind/nos/v6_0_2f/brocade_netconf_ext_rpc/__init__.py | brocade_netconf_ext._set_get_netconf_client_capabilities | def _set_get_netconf_client_capabilities(self, v, load=False):
"""
Setter method for get_netconf_client_capabilities, mapped from YANG variable /brocade_netconf_ext_rpc/get_netconf_client_capabilities (rpc)
If this variable is read-only (config: false) in the
source YANG file, then _set_get_netconf_clie... | python | def _set_get_netconf_client_capabilities(self, v, load=False):
"""
Setter method for get_netconf_client_capabilities, mapped from YANG variable /brocade_netconf_ext_rpc/get_netconf_client_capabilities (rpc)
If this variable is read-only (config: false) in the
source YANG file, then _set_get_netconf_clie... | [
"def",
"_set_get_netconf_client_capabilities",
"(",
"self",
",",
"v",
",",
"load",
"=",
"False",
")",
":",
"if",
"hasattr",
"(",
"v",
",",
"\"_utype\"",
")",
":",
"v",
"=",
"v",
".",
"_utype",
"(",
"v",
")",
"try",
":",
"t",
"=",
"YANGDynClass",
"(",... | Setter method for get_netconf_client_capabilities, mapped from YANG variable /brocade_netconf_ext_rpc/get_netconf_client_capabilities (rpc)
If this variable is read-only (config: false) in the
source YANG file, then _set_get_netconf_client_capabilities is considered as a private
method. Backends looking to ... | [
"Setter",
"method",
"for",
"get_netconf_client_capabilities",
"mapped",
"from",
"YANG",
"variable",
"/",
"brocade_netconf_ext_rpc",
"/",
"get_netconf_client_capabilities",
"(",
"rpc",
")",
"If",
"this",
"variable",
"is",
"read",
"-",
"only",
"(",
"config",
":",
"fal... | 44c467e71b2b425be63867aba6e6fa28b2cfe7fb | https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/nos/v6_0_2f/brocade_netconf_ext_rpc/__init__.py#L99-L123 | train | Sets the variable to be read - only. |
StackStorm/pybind | pybind/slxos/v17s_1_02/brocade_lag_rpc/get_portchannel_info_by_intf/output/lacp/__init__.py | lacp._set_receive_machine_state | def _set_receive_machine_state(self, v, load=False):
"""
Setter method for receive_machine_state, mapped from YANG variable /brocade_lag_rpc/get_portchannel_info_by_intf/output/lacp/receive_machine_state (enumeration)
If this variable is read-only (config: false) in the
source YANG file, then _set_recei... | python | def _set_receive_machine_state(self, v, load=False):
"""
Setter method for receive_machine_state, mapped from YANG variable /brocade_lag_rpc/get_portchannel_info_by_intf/output/lacp/receive_machine_state (enumeration)
If this variable is read-only (config: false) in the
source YANG file, then _set_recei... | [
"def",
"_set_receive_machine_state",
"(",
"self",
",",
"v",
",",
"load",
"=",
"False",
")",
":",
"if",
"hasattr",
"(",
"v",
",",
"\"_utype\"",
")",
":",
"v",
"=",
"v",
".",
"_utype",
"(",
"v",
")",
"try",
":",
"t",
"=",
"YANGDynClass",
"(",
"v",
... | Setter method for receive_machine_state, mapped from YANG variable /brocade_lag_rpc/get_portchannel_info_by_intf/output/lacp/receive_machine_state (enumeration)
If this variable is read-only (config: false) in the
source YANG file, then _set_receive_machine_state is considered as a private
method. Backends ... | [
"Setter",
"method",
"for",
"receive_machine_state",
"mapped",
"from",
"YANG",
"variable",
"/",
"brocade_lag_rpc",
"/",
"get_portchannel_info_by_intf",
"/",
"output",
"/",
"lacp",
"/",
"receive_machine_state",
"(",
"enumeration",
")",
"If",
"this",
"variable",
"is",
... | 44c467e71b2b425be63867aba6e6fa28b2cfe7fb | https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/slxos/v17s_1_02/brocade_lag_rpc/get_portchannel_info_by_intf/output/lacp/__init__.py#L521-L544 | train | Sets the receive machine state of the
|
StackStorm/pybind | pybind/slxos/v17s_1_02/brocade_lag_rpc/get_portchannel_info_by_intf/output/lacp/__init__.py | lacp._set_periodic_transmission_machine_state | def _set_periodic_transmission_machine_state(self, v, load=False):
"""
Setter method for periodic_transmission_machine_state, mapped from YANG variable /brocade_lag_rpc/get_portchannel_info_by_intf/output/lacp/periodic_transmission_machine_state (enumeration)
If this variable is read-only (config: false) in... | python | def _set_periodic_transmission_machine_state(self, v, load=False):
"""
Setter method for periodic_transmission_machine_state, mapped from YANG variable /brocade_lag_rpc/get_portchannel_info_by_intf/output/lacp/periodic_transmission_machine_state (enumeration)
If this variable is read-only (config: false) in... | [
"def",
"_set_periodic_transmission_machine_state",
"(",
"self",
",",
"v",
",",
"load",
"=",
"False",
")",
":",
"if",
"hasattr",
"(",
"v",
",",
"\"_utype\"",
")",
":",
"v",
"=",
"v",
".",
"_utype",
"(",
"v",
")",
"try",
":",
"t",
"=",
"YANGDynClass",
... | Setter method for periodic_transmission_machine_state, mapped from YANG variable /brocade_lag_rpc/get_portchannel_info_by_intf/output/lacp/periodic_transmission_machine_state (enumeration)
If this variable is read-only (config: false) in the
source YANG file, then _set_periodic_transmission_machine_state is con... | [
"Setter",
"method",
"for",
"periodic_transmission_machine_state",
"mapped",
"from",
"YANG",
"variable",
"/",
"brocade_lag_rpc",
"/",
"get_portchannel_info_by_intf",
"/",
"output",
"/",
"lacp",
"/",
"periodic_transmission_machine_state",
"(",
"enumeration",
")",
"If",
"thi... | 44c467e71b2b425be63867aba6e6fa28b2cfe7fb | https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/slxos/v17s_1_02/brocade_lag_rpc/get_portchannel_info_by_intf/output/lacp/__init__.py#L559-L583 | train | Sets the periodic transmission machine state. |
StackStorm/pybind | pybind/slxos/v17s_1_02/brocade_lag_rpc/get_portchannel_info_by_intf/output/lacp/__init__.py | lacp._set_mux_machine_state | def _set_mux_machine_state(self, v, load=False):
"""
Setter method for mux_machine_state, mapped from YANG variable /brocade_lag_rpc/get_portchannel_info_by_intf/output/lacp/mux_machine_state (enumeration)
If this variable is read-only (config: false) in the
source YANG file, then _set_mux_machine_state... | python | def _set_mux_machine_state(self, v, load=False):
"""
Setter method for mux_machine_state, mapped from YANG variable /brocade_lag_rpc/get_portchannel_info_by_intf/output/lacp/mux_machine_state (enumeration)
If this variable is read-only (config: false) in the
source YANG file, then _set_mux_machine_state... | [
"def",
"_set_mux_machine_state",
"(",
"self",
",",
"v",
",",
"load",
"=",
"False",
")",
":",
"if",
"hasattr",
"(",
"v",
",",
"\"_utype\"",
")",
":",
"v",
"=",
"v",
".",
"_utype",
"(",
"v",
")",
"try",
":",
"t",
"=",
"YANGDynClass",
"(",
"v",
",",... | Setter method for mux_machine_state, mapped from YANG variable /brocade_lag_rpc/get_portchannel_info_by_intf/output/lacp/mux_machine_state (enumeration)
If this variable is read-only (config: false) in the
source YANG file, then _set_mux_machine_state is considered as a private
method. Backends looking to p... | [
"Setter",
"method",
"for",
"mux_machine_state",
"mapped",
"from",
"YANG",
"variable",
"/",
"brocade_lag_rpc",
"/",
"get_portchannel_info_by_intf",
"/",
"output",
"/",
"lacp",
"/",
"mux_machine_state",
"(",
"enumeration",
")",
"If",
"this",
"variable",
"is",
"read",
... | 44c467e71b2b425be63867aba6e6fa28b2cfe7fb | https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/slxos/v17s_1_02/brocade_lag_rpc/get_portchannel_info_by_intf/output/lacp/__init__.py#L597-L620 | train | Sets the mux machine state for the portchannel. |
StackStorm/pybind | pybind/slxos/v17s_1_02/brocade_lag_rpc/get_portchannel_info_by_intf/output/lacp/__init__.py | lacp._set_oper_state | def _set_oper_state(self, v, load=False):
"""
Setter method for oper_state, mapped from YANG variable /brocade_lag_rpc/get_portchannel_info_by_intf/output/lacp/oper_state (lacp-state)
If this variable is read-only (config: false) in the
source YANG file, then _set_oper_state is considered as a private
... | python | def _set_oper_state(self, v, load=False):
"""
Setter method for oper_state, mapped from YANG variable /brocade_lag_rpc/get_portchannel_info_by_intf/output/lacp/oper_state (lacp-state)
If this variable is read-only (config: false) in the
source YANG file, then _set_oper_state is considered as a private
... | [
"def",
"_set_oper_state",
"(",
"self",
",",
"v",
",",
"load",
"=",
"False",
")",
":",
"if",
"hasattr",
"(",
"v",
",",
"\"_utype\"",
")",
":",
"v",
"=",
"v",
".",
"_utype",
"(",
"v",
")",
"try",
":",
"t",
"=",
"YANGDynClass",
"(",
"v",
",",
"bas... | Setter method for oper_state, mapped from YANG variable /brocade_lag_rpc/get_portchannel_info_by_intf/output/lacp/oper_state (lacp-state)
If this variable is read-only (config: false) in the
source YANG file, then _set_oper_state is considered as a private
method. Backends looking to populate this variable ... | [
"Setter",
"method",
"for",
"oper_state",
"mapped",
"from",
"YANG",
"variable",
"/",
"brocade_lag_rpc",
"/",
"get_portchannel_info_by_intf",
"/",
"output",
"/",
"lacp",
"/",
"oper_state",
"(",
"lacp",
"-",
"state",
")",
"If",
"this",
"variable",
"is",
"read",
"... | 44c467e71b2b425be63867aba6e6fa28b2cfe7fb | https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/slxos/v17s_1_02/brocade_lag_rpc/get_portchannel_info_by_intf/output/lacp/__init__.py#L671-L694 | train | Sets the operational state of the
|
StackStorm/pybind | pybind/slxos/v17s_1_02/brocade_lag_rpc/get_portchannel_info_by_intf/output/lacp/__init__.py | lacp._set_partner_brcd_state | def _set_partner_brcd_state(self, v, load=False):
"""
Setter method for partner_brcd_state, mapped from YANG variable /brocade_lag_rpc/get_portchannel_info_by_intf/output/lacp/partner_brcd_state (brcd-trunk-states)
If this variable is read-only (config: false) in the
source YANG file, then _set_partner_... | python | def _set_partner_brcd_state(self, v, load=False):
"""
Setter method for partner_brcd_state, mapped from YANG variable /brocade_lag_rpc/get_portchannel_info_by_intf/output/lacp/partner_brcd_state (brcd-trunk-states)
If this variable is read-only (config: false) in the
source YANG file, then _set_partner_... | [
"def",
"_set_partner_brcd_state",
"(",
"self",
",",
"v",
",",
"load",
"=",
"False",
")",
":",
"if",
"hasattr",
"(",
"v",
",",
"\"_utype\"",
")",
":",
"v",
"=",
"v",
".",
"_utype",
"(",
"v",
")",
"try",
":",
"t",
"=",
"YANGDynClass",
"(",
"v",
","... | Setter method for partner_brcd_state, mapped from YANG variable /brocade_lag_rpc/get_portchannel_info_by_intf/output/lacp/partner_brcd_state (brcd-trunk-states)
If this variable is read-only (config: false) in the
source YANG file, then _set_partner_brcd_state is considered as a private
method. Backends loo... | [
"Setter",
"method",
"for",
"partner_brcd_state",
"mapped",
"from",
"YANG",
"variable",
"/",
"brocade_lag_rpc",
"/",
"get_portchannel_info_by_intf",
"/",
"output",
"/",
"lacp",
"/",
"partner_brcd_state",
"(",
"brcd",
"-",
"trunk",
"-",
"states",
")",
"If",
"this",
... | 44c467e71b2b425be63867aba6e6fa28b2cfe7fb | https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/slxos/v17s_1_02/brocade_lag_rpc/get_portchannel_info_by_intf/output/lacp/__init__.py#L967-L990 | train | Sets the state of the partner brcd trunk state. |
StackStorm/pybind | pybind/nos/v6_0_2f/interface/fortygigabitethernet/storm_control/__init__.py | storm_control._set_ingress | def _set_ingress(self, v, load=False):
"""
Setter method for ingress, mapped from YANG variable /interface/fortygigabitethernet/storm_control/ingress (list)
If this variable is read-only (config: false) in the
source YANG file, then _set_ingress is considered as a private
method. Backends looking to... | python | def _set_ingress(self, v, load=False):
"""
Setter method for ingress, mapped from YANG variable /interface/fortygigabitethernet/storm_control/ingress (list)
If this variable is read-only (config: false) in the
source YANG file, then _set_ingress is considered as a private
method. Backends looking to... | [
"def",
"_set_ingress",
"(",
"self",
",",
"v",
",",
"load",
"=",
"False",
")",
":",
"if",
"hasattr",
"(",
"v",
",",
"\"_utype\"",
")",
":",
"v",
"=",
"v",
".",
"_utype",
"(",
"v",
")",
"try",
":",
"t",
"=",
"YANGDynClass",
"(",
"v",
",",
"base",... | Setter method for ingress, mapped from YANG variable /interface/fortygigabitethernet/storm_control/ingress (list)
If this variable is read-only (config: false) in the
source YANG file, then _set_ingress is considered as a private
method. Backends looking to populate this variable should
do so via callin... | [
"Setter",
"method",
"for",
"ingress",
"mapped",
"from",
"YANG",
"variable",
"/",
"interface",
"/",
"fortygigabitethernet",
"/",
"storm_control",
"/",
"ingress",
"(",
"list",
")",
"If",
"this",
"variable",
"is",
"read",
"-",
"only",
"(",
"config",
":",
"false... | 44c467e71b2b425be63867aba6e6fa28b2cfe7fb | https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/nos/v6_0_2f/interface/fortygigabitethernet/storm_control/__init__.py#L92-L113 | train | Set the ingress value for the
|
StackStorm/pybind | pybind/slxos/v17r_1_01a/ha/__init__.py | ha._set_process_restart | def _set_process_restart(self, v, load=False):
"""
Setter method for process_restart, mapped from YANG variable /ha/process_restart (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_process_restart is considered as a private
method. Backends looking to popu... | python | def _set_process_restart(self, v, load=False):
"""
Setter method for process_restart, mapped from YANG variable /ha/process_restart (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_process_restart is considered as a private
method. Backends looking to popu... | [
"def",
"_set_process_restart",
"(",
"self",
",",
"v",
",",
"load",
"=",
"False",
")",
":",
"if",
"hasattr",
"(",
"v",
",",
"\"_utype\"",
")",
":",
"v",
"=",
"v",
".",
"_utype",
"(",
"v",
")",
"try",
":",
"t",
"=",
"YANGDynClass",
"(",
"v",
",",
... | Setter method for process_restart, mapped from YANG variable /ha/process_restart (container)
If this variable is read-only (config: false) in the
source YANG file, then _set_process_restart is considered as a private
method. Backends looking to populate this variable should
do so via calling thisObj._se... | [
"Setter",
"method",
"for",
"process_restart",
"mapped",
"from",
"YANG",
"variable",
"/",
"ha",
"/",
"process_restart",
"(",
"container",
")",
"If",
"this",
"variable",
"is",
"read",
"-",
"only",
"(",
"config",
":",
"false",
")",
"in",
"the",
"source",
"YAN... | 44c467e71b2b425be63867aba6e6fa28b2cfe7fb | https://github.com/StackStorm/pybind/blob/44c467e71b2b425be63867aba6e6fa28b2cfe7fb/pybind/slxos/v17r_1_01a/ha/__init__.py#L94-L115 | train | Sets the process restart for the
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.