content stringlengths 7 1.05M |
|---|
#Python program to clone or copy a list.
original_list = [10, 22, 44, 23, 4]
new_list = list(original_list)
print(original_list)
print(new_list) |
def input1():
l1 = []
while (True):
a = input('输入字符串: ')
if a == 'q':
break
b = input('输入字符串个数:')
for i in range(int(b)):
l1.append(a)
return l1
|
def get_input():
"""
Wrap input in this method so that it can be wrapped with @patch in tests
:return:
"""
return input('') |
def find_price_ranges(candlestick_data, period_size):
"""Calculates historical price ranges for a given period duration.
For one period of bars ranges counts as:
1st range: (high price in period - first bar opening price) / first bar opening price - 1
2nd range: (first bar opening price - low price in period) / first bar opening price - 1
The next period is obtained by a shift of always 1 bar.
:param (dict of str: list) candlestick_data: candlestick market price data (required)
:param int period_size: size of one period in bars (required)
:return (list of float) price_ranges: all price ranges in market price data
"""
price_ranges = []
for candle_index in range(candlestick_data['length'] - period_size + 1):
period_open = candlestick_data['open'][candle_index]
max_high = max(candlestick_data['high'][candle_index: candle_index + period_size])
min_low = min(candlestick_data['low'][candle_index: candle_index + period_size])
price_ranges.append(max_high / period_open - 1)
price_ranges.append(1 - min_low / period_open)
print(sorted(price_ranges))
return sorted(price_ranges)
def find_order_relative_levels(price_ranges, order_probabilities):
"""Calculates orders relative levels with given filling probability depending on historical market volatility
:param (list of float) price_ranges: historical price ranges (required)
:param (list of float) order_probabilities: order filling probabilities (required)
:return (list of float) order_levels: relative levels of orders
"""
probability_step = 1 / len(price_ranges)
order_levels = []
for fill_probability in order_probabilities:
if fill_probability < probability_step:
order_levels.append(0)
continue
range_index = len(price_ranges) - fill_probability / probability_step
range_index_int_part = int(range_index)
range_index_double_part = range_index - range_index_int_part
level = price_ranges[range_index_int_part] + (price_ranges[range_index_int_part + 1] -
price_ranges[range_index_int_part]) * range_index_double_part
order_levels.append(level)
return order_levels
def find_order_price_levels(base_price, relative_levels, direction):
"""Calculates order price levels by base price and relative order levels
:param float base_price: base price for order price level calculating (f.e. current market price)
:param (list of float) relative_levels: relative order levels
:param str direction: `higher` for orders above base_price or `lower` for orders below base_price
:return (list of float) price_levels: price levels of orders
"""
direction_int = 1 if direction == 'higher' else -1
price_levels = []
for level in relative_levels:
price_levels.append(base_price * (1 + level * direction_int))
return price_levels
def get_candle_properties(hold_time):
"""
Todo: realize function (issue #11)
"""
candle_properties = {
'resolution': 0,
'amount': 0,
'start_time': 0,
'end_time': 0
}
return candle_properties
def get_range_period_size(hold_time):
"""
Todo: realize function (issue #11)
"""
period_size = 0
return period_size
|
class GeneratorError(Exception): pass
class ProgressionGenerator:
# diatonic triads for major keys
diatonic_triads = [
('C', 'Dm', 'Em', 'F', 'G', 'Am', 'Bdim'),
('G', 'Am', 'Bm', 'C', 'D', 'Em', 'F#dim'),
('D', 'Em', 'F#m', 'G', 'A', 'Bm', 'C#dim'),
('A', 'Bm', 'C#m', 'D', 'E', 'F#m', 'G#dim'),
('E', 'F#m', 'G#m', 'A', 'B', 'C#m', 'D#dim'),
('B', 'C#m', 'D#m', 'E', 'F#', 'G#m', 'A#dim'),
('F#', 'G#m', 'A#m', 'B', 'C#', 'D#m', 'E#dim'),
('Db', 'Ebm', 'Fm', 'Gb', 'Ab', 'Bbm', 'Cdim'),
('Ab', 'Bbm', 'Cm', 'Db', 'Eb', 'Fm', 'Gdim'),
('Eb', 'Fm', 'Gm', 'Ab', 'Bb', 'Cm', 'Ddim'),
('Bb', 'Cm', 'Dm', 'Eb', 'F', 'Gm', 'Adim'),
('F', 'Gm', 'Am', 'Bb', 'C', 'Dm', 'Edim'),
]
numerals_table = {
'I': '1',
'ii': '2',
'iii': '3',
'IV': '4',
'V': '5',
'vi': '6',
'VII': '7',
}
def _is_allowed_numeral(self, numeral):
return numeral in self.numerals_table or numeral in self.numerals_table.values()
def _to_indexes(self, numerals):
"""numerals -- valid numerals
returns indexes (list) -- usable indexes for ProgressionGenerator.diatonic_triads
"""
indexes = []
for numeral in numerals:
if numeral in self.numerals_table:
n = int(self.numerals_table[numeral])
else:
n = int(numeral)
indexes.append(n-1) # indexes are zero based
return indexes
def _get_chords(self, chords, indexes):
"""chords (list) -- chords to choose from
indexes (list) -- which chords to choose
returns (list)
"""
return [chords[i] for i in indexes]
def _to_numerals(self, prog):
"""prog (string) -- line of numerals
returns numerals (list)
throws GeneratorError on incorrect format
"""
if '-' in prog:
numerals = prog.split('-')
elif ' ' in prog:
numerals = prog.split(' ')
elif len(prog) == 1:
numerals = [prog]
else:
raise GeneratorError('Incorrect format.')
return numerals
def _parse_input(self, prog):
"""prog (string) -- line of numerals
returns numerals (list) -- valid numerals
throws GeneratorError on incorrect input
"""
prog = prog.strip()
numerals = self._to_numerals(prog)
for numeral in numerals:
if not self._is_allowed_numeral(numeral):
raise GeneratorError('{} isn\'t allowed numeral.'.format(numeral))
return numerals
def get_progressions(self, prog):
"""Acceptable inputs:
1)'I V vi IV' (separated by a single space)
2)'V-vi-I-I-vi' (separated by hyphen)
3)'1 5 6 4' (as numbers)
4)'6 4' (variable length)
etc
Unacceptable inputs:
1)'i V' (1 can't be minor)
2)'1 8' (7 is maximum)
3)'3.50' (No Loch Ness monsters allowed)
Return value format (example):
[
{'input_numerals': ['I', 'V', 'vi', 'IV']},
{'key': 'C', 'chords': ['C', 'G', 'Am', 'F']},
{'key': 'G', 'chords': ['G', 'D', 'Em', 'C']},
...
]
prog (string) -- see above
returns progressions (list) -- see above
"""
numerals = self._parse_input(prog)
indexes = self._to_indexes(numerals)
progressions = [{
'input_numerals': numerals,
}]
for chords in self.diatonic_triads:
progressions.append({
'key': chords[0],
'chords': self._get_chords(chords, indexes),
})
return progressions |
"""Defines the Exceptions that can be raised from the DomainTools API"""
class ServiceException(Exception):
def __init__(self, code, reason):
self.code = code
self.reason = reason
super(ServiceException, self).__init__(str(reason))
class BadRequestException(ServiceException):
pass
class InternalServerErrorException(ServiceException):
pass
class NotAuthorizedException(ServiceException):
pass
class NotFoundException(ServiceException):
pass
class ServiceUnavailableException(ServiceException):
pass
class IncompleteResponseException(ServiceException):
pass
class RequestUriTooLongException(ServiceException):
pass
|
x = int(input())
if (x > 0):
print("positivo")
elif (x < 0):
print("negativo")
else:
print("nulo")
|
# test order of closed over locals
# not that CPython seems to sort closed over variables (but not fast locals)
def f():
l1 = 1
l2 = 4
l3 = 3
l4 = 2
l5 = 5
def g():
return l1 + l4 + l3 + l2 + l5
def h():
return l1 + l2 + l3 + l4 + l5
|
EAA_EDUCATION_FACILITIES = {'buildings', 'education facilities - schools', 'facilities and infrastructure'}
EAA_EDUCATION_STATISTICS = {
'baseline population', 'census', 'demographics', 'development', 'early learning', 'economics',
'educational attainment', 'educators - teachers', 'gap analysis', 'government data', 'indicators', 'inequality',
'literacy', 'mortality', 'out-of-school', 'poverty', 'school enrollment', 'sex and age disaggregated data - sadd',
'socioeconomics', 'survey', 'sustainable development',
}
EAA_CRISIS_RESPONSE = {
'access to education', 'affected schools', 'aid workers security', 'armed violence', 'assistance targets',
'Bangladesh - Rohingya refugee crisis', 'camp coordination and camp management', 'caseload - humanitarian profile',
'casualties', 'complex emergency', 'common operational dataset - cod', 'coordination', 'coxs bazar',
'cyclones - hurricanes - typhoons', 'damage assessment', 'damaged buildings',
'displaced persons locations - camps - shelters', 'earthquakes', 'ebola', 'epidemics and outbreaks',
'fatalities - deaths', 'floods', 'hazards and risk', 'humanitarian needs overview - hno',
'hurricane matthew - sep 2016', 'incidents of disasters', 'internally displaced persons - idp',
'lake chad basin crisis - 2014-2017', 'livelihoods', 'needs assessment', 'Nigeria - complex emergency - 2014 -',
'operational presence', 'recovery - reconstruction', 'shelter', 'syria crisis - 2011-', 'violence and conflict',
'vulnerable populations', 'who is doing what and where - 3w - 4w - 5w'
}
EAA_ALL_USED_TAGS = EAA_EDUCATION_FACILITIES.union(EAA_EDUCATION_STATISTICS).union(EAA_CRISIS_RESPONSE)
EAA_FACET_NAMING_TO_INFO = {
'education_facilities': {
'url_param_name': 'ext_eaa_education_facilities',
'tag_list': EAA_EDUCATION_FACILITIES,
'negate': False
},
'education_statistics': {
'url_param_name': 'ext_eaa_education_statistics',
'tag_list': EAA_EDUCATION_STATISTICS,
'negate': False
},
'crisis_response': {
'url_param_name': 'ext_eaa_crisis_response',
'tag_list': EAA_CRISIS_RESPONSE,
'negate': False
},
'other': {
'url_param_name': 'ext_eaa_other',
'tag_list': EAA_ALL_USED_TAGS,
'negate': True
}
}
|
N = input().split()
m = int(N[0])
for i in range(round(m / 2, 0)):
for j in range(m):
print(N[-1], end='')
print()
|
#!/usr/bin/env python3
# coding: utf-8
'''
定义管理员群的名称
在该群内的人都将被设为管理员,
管理员在被管理的群中享有高级管理权限,可进行如踢人等的操作
注:群名为部分匹配,请尽量输入全名以保证搜索到的群的唯一性
'''
admin_group_name = 'AAAUUUUXXXX'
'''
定义被管理群的群名前缀
所有以此为前缀的群都将设为被管理的群
注:前缀大小写敏感
如:设定为'Linux中国◆',则将自动搜索到
「Linux中国◆微信机器人群」「Linux中国◆LFS群」等以其为开头的群,
并将其设为被管理的群
'''
group_prefix = '贝尔乐实验室'
# 新人入群的欢迎语
welcome_text = '''🎉 欢迎 @{} 家长的加入贝尔乐早教!
😃 贝尔乐早教电话:0757-22115439,欧老师:13129130667,朱老师:13392227928 @平姐 @蓝色雨;
😃 欢迎关注我们的公众号"贝尔乐早教"。
'''
invite_text = """感谢您的咨询,如长时间没有回复,请加入我们微群咨询"""
'''
设置群组关键词和对应群名
* 关键词必须为小写,查询时会做相应的小写处理
关于随机加群功能:
针对同类的群有多个的场景,例如群名 LFS群1、LFS群2、LFS群3...
设置关键词字典如下:
keyword_of_group = {
"lfs":"LFS群"
}
机器人会以"LFS群"为群名搜索,搜索结果为同类群名的列表,
再从列表中随机选取一个发出加群邀请。
'''
keyword_of_group = {
"key": "keyword group"
}
'''
地区群
'''
city_group = {
"city": "city group"
}
alert_group = "alert group"
turing_key = 'dda82262138a4556b24ff4d210e3c09b'
# 以下为功能配置选项
'''
全局静默开关
'''
silence_mode = False
|
##############################################################################
# Copyright 2022-present, Facebook, Inc.
# All rights reserved.
#
# This source code is licensed under the license found in the
# LICENSE file in the root directory of this source tree.
##############################################################################
upload_handles = {}
class FileUploader:
def __init__(self, context: str = "default"):
self.upload_handles = getUploadHandles()
if context not in self.upload_handles:
raise RuntimeError(f"No configuration found for {context}")
self.uploader = self.upload_handles[context]()
def upload_file(self, file):
return self.uploader.upload_file(file)
def get_uploader(self):
return self.uploader
def registerFileUploader(name, obj):
global upload_handles
upload_handles[name] = obj
def getUploadHandles():
return upload_handles
|
# -*- coding: utf-8 -*-
"""Honeycomb test constants."""
class commands():
"""Plugin commands."""
RUN = "run"
LOGS = "logs"
SHOW = "show"
TEST = "test"
STOP = "stop"
LIST = "list"
STATUS = "status"
INSTALL = "install"
UNINSTALL = "uninstall"
CONFIGURE = "configure"
class args():
"""Plugin arguments."""
YES = "--yes"
NUM = "--num"
HOME = "--home"
HELP = "--help"
CONFIG = "--config"
FOLLOW = "--follow"
DAEMON = "--daemon"
VERBOSE = "--verbose"
IAMROOT = "--iamroot"
SHOW_ALL = "--show-all"
INTEGRATION = "--integration"
COMMON_ARGS = [VERBOSE, IAMROOT, HOME]
|
"""The GLSL toolchain definition and implementation
"""
def _glsl_toolchain_impl(ctx):
# it is expected the the glslc target contains one and only one
# file that is the compiler.
glslc_executable = ""
if ctx.attr.is_windows:
glslc_executable = ctx.attr.glslc.files.to_list()[0].path
else:
glslc_executable = "glslc"
toolchain_info = platform_common.ToolchainInfo(
glslc = ctx.attr.glslc,
glslc_executable = glslc_executable,
is_windows = ctx.attr.is_windows,
)
return [toolchain_info]
glsl_toolchain = rule(
implementation = _glsl_toolchain_impl,
attrs = {
"glslc": attr.label(
doc = "The location of the glslc compiler.",
allow_single_file = True
),
"is_windows": attr.bool(
doc = "Whether or not this toolchain runs in windows",
mandatory = True
)
},
)
|
# coding=UTF-8
## This class define a composite ply
class CompositePly:
def __init__(self,Material,Thickness,Orientation):
## the material of the ply (either IsoMaterial or OrthoMaterial)
self.Material = Material
## the thickness of the ply (m)
self.Thickness = Thickness
## the orientation of fiber in case of OrthoMaterial
self.Orientation = Orientation
def GetMaterial(self):
return self.Material
def GetThickness(self):
return self.Thickness
def GetOrientation(self):
return self.Orientation
|
class AppTestClasses:
spaceconfig = dict(usemodules=['_multibytecodec'])
def setup_class(cls):
cls.w_IncrementalHzDecoder = cls.space.appexec([], """():
import _codecs_cn
from _multibytecodec import MultibyteIncrementalDecoder
class IncrementalHzDecoder(MultibyteIncrementalDecoder):
codec = _codecs_cn.getcodec('hz')
return IncrementalHzDecoder
""")
cls.w_IncrementalHzEncoder = cls.space.appexec([], """():
import _codecs_cn
from _multibytecodec import MultibyteIncrementalEncoder
class IncrementalHzEncoder(MultibyteIncrementalEncoder):
codec = _codecs_cn.getcodec('hz')
return IncrementalHzEncoder
""")
cls.w_IncrementalBig5hkscsEncoder = cls.space.appexec([], """():
import _codecs_hk
from _multibytecodec import MultibyteIncrementalEncoder
class IncrementalBig5hkscsEncoder(MultibyteIncrementalEncoder):
codec = _codecs_hk.getcodec('big5hkscs')
return IncrementalBig5hkscsEncoder
""")
def test_decode_hz(self):
d = self.IncrementalHzDecoder()
r = d.decode(b"~{abcd~}")
assert r == '\u5f95\u6c85'
r = d.decode(b"~{efgh~}")
assert r == '\u5f50\u73b7'
for c, output in zip(b"!~{abcd~}xyz~{efgh",
['!', # !
'', # ~
'', # {
'', # a
'\u5f95', # b
'', # c
'\u6c85', # d
'', # ~
'', # }
'x', # x
'y', # y
'z', # z
'', # ~
'', # {
'', # e
'\u5f50', # f
'', # g
'\u73b7', # h
]):
r = d.decode(bytes([c]))
assert r == output
def test_decode_hz_final(self):
d = self.IncrementalHzDecoder()
r = d.decode(b"~{", True)
assert r == ''
raises(UnicodeDecodeError, d.decode, b"~", True)
raises(UnicodeDecodeError, d.decode, b"~{a", True)
def test_decode_hz_reset(self):
d = self.IncrementalHzDecoder()
r = d.decode(b"ab")
assert r == 'ab'
r = d.decode(b"~{")
assert r == ''
r = d.decode(b"ab")
assert r == '\u5f95'
r = d.decode(b"ab")
assert r == '\u5f95'
d.reset()
r = d.decode(b"ab")
assert r == 'ab'
def test_decode_hz_error(self):
d = self.IncrementalHzDecoder()
raises(UnicodeDecodeError, d.decode, b"~{abc", True)
d = self.IncrementalHzDecoder("ignore")
r = d.decode(b"~{abc", True)
assert r == '\u5f95'
d = self.IncrementalHzDecoder()
d.errors = "replace"
r = d.decode(b"~{abc", True)
assert r == '\u5f95\ufffd'
def test_decode_hz_buffer_grow(self):
d = self.IncrementalHzDecoder()
for i in range(13):
r = d.decode(b"a" * (2**i))
assert r == "a" * (2**i)
def test_encode_hz(self):
e = self.IncrementalHzEncoder()
r = e.encode("abcd")
assert r == b'abcd'
r = e.encode("\u5f95\u6c85")
assert r == b'~{abcd'
r = e.encode("\u5f50")
assert r == b'ef'
r = e.encode("\u73b7", final=True)
assert r == b'gh~}'
def test_encode_hz_final(self):
e = self.IncrementalHzEncoder()
r = e.encode("xyz\u5f95\u6c85", True)
assert r == b'xyz~{abcd~}'
# This is a bit hard to test, because the only way I can see that
# encoders can return MBERR_TOOFEW is with surrogates, which only
# occur with 2-byte unicode characters... We will just have to
# trust that the logic works, because it is exactly the same one
# as in the decode case :-/
def test_encode_hz_reset(self):
# Same issue as with test_encode_hz_final
e = self.IncrementalHzEncoder()
r = e.encode("xyz\u5f95\u6c85", True)
assert r == b'xyz~{abcd~}'
e.reset()
r = e.encode("xyz\u5f95\u6c85")
assert r == b'xyz~{abcd'
r = e.encode('', final=True)
assert r == b'~}'
def test_encode_hz_noreset(self):
text = ('\u5df1\u6240\u4e0d\u6b32\uff0c\u52ff\u65bd\u65bc\u4eba\u3002'
'Bye.')
out = b''
e = self.IncrementalHzEncoder()
for c in text:
out += e.encode(c)
assert out == b'~{<:Ky2;S{#,NpJ)l6HK!#~}Bye.'
def test_encode_hz_error(self):
e = self.IncrementalHzEncoder()
raises(UnicodeEncodeError, e.encode, "\u4321", True)
e = self.IncrementalHzEncoder("ignore")
r = e.encode("xy\u4321z", True)
assert r == b'xyz'
e = self.IncrementalHzEncoder()
e.errors = "replace"
r = e.encode("xy\u4321z", True)
assert r == b'xy?z'
def test_encode_hz_buffer_grow(self):
e = self.IncrementalHzEncoder()
for i in range(13):
r = e.encode("a" * (2**i))
assert r == b"a" * (2**i)
def test_encode_big5hkscs(self):
#e = self.IncrementalBig5hkscsEncoder()
#r = e.encode('\xca', True)
#assert r == b'\x88f'
#r = e.encode('\xca', True)
#assert r == b'\x88f'
#raises(UnicodeEncodeError, e.encode, '\u0304', True)
#
e = self.IncrementalBig5hkscsEncoder()
r = e.encode('\xca')
assert r == b''
r = e.encode('\xca')
assert r == b'\x88f'
r = e.encode('\u0304')
assert r == b'\x88b'
|
"""T Gate"""
def t(index, vector):
return vector
|
#! /usr/bin/env python3
# -*- coding: utf-8 -*-
# vim:fenc=utf-8
#
# Copyright © 2021 Shlomi Fish < https://www.shlomifish.org/ >
#
# Licensed under the terms of the MIT license.
"""
"""
def _unused():
print(fn="test.jl", template=('''
using OpenCL
device, ctx, queue = cl.create_compute_context()
const first_int = -1
const bufsize = {bufsize}
const num_ints_in_first = {num_ints_in_first};
const num_remaining_ints = 4*13 - num_ints_in_first;
const sum_kernel = "
__kernel void sum(__global unsigned int *r,
__global unsigned int *i)
{{
int gid = get_global_id(0);
{kernel_sum_cl_code}
}}
"
p = cl.Program(ctx, source=sum_kernel) |> cl.build!
k = cl.Kernel(p, "sum")
is_right = false
mystart = 1
myints = [{myints}]
while (! is_right)
r = Array{{UInt32}}(UnitRange{{UInt32}}(mystart:mystart+bufsize-1))
i = zeros(UInt32, bufsize)
r_buff = cl.Buffer(UInt32, ctx, (:r, :copy), hostbuf=r)
i_buff = cl.Buffer(UInt32, ctx, (:r, :copy), hostbuf=i)
queue(k, size(r), nothing, r_buff, i_buff)
r = cl.read(queue, r_buff)
i = cl.read(queue, i_buff)
for myiterint in 1:bufsize
if i[myiterint] == first_int
global is_right = true
rr = r[myiterint]
for n in num_remaining_ints:-1:2
rr = ((rr * 214013 + 2531011) & 0xFFFFFFFF)
if ( ((rr >> 16) & 0x7fff) % n != myints[n])
global is_right = false
break
end
end
if is_right
@show mystart+myiterint-1
break
end
end
end
global mystart += bufsize
if mystart > {limit}
break
end
end
'''))
|
# Automatically generated file
# enum Z3_lbool
Z3_L_FALSE = -1
Z3_L_UNDEF = 0
Z3_L_TRUE = 1
# enum Z3_symbol_kind
Z3_INT_SYMBOL = 0
Z3_STRING_SYMBOL = 1
# enum Z3_parameter_kind
Z3_PARAMETER_INT = 0
Z3_PARAMETER_DOUBLE = 1
Z3_PARAMETER_RATIONAL = 2
Z3_PARAMETER_SYMBOL = 3
Z3_PARAMETER_SORT = 4
Z3_PARAMETER_AST = 5
Z3_PARAMETER_FUNC_DECL = 6
# enum Z3_sort_kind
Z3_UNINTERPRETED_SORT = 0
Z3_BOOL_SORT = 1
Z3_INT_SORT = 2
Z3_REAL_SORT = 3
Z3_BV_SORT = 4
Z3_ARRAY_SORT = 5
Z3_DATATYPE_SORT = 6
Z3_RELATION_SORT = 7
Z3_FINITE_DOMAIN_SORT = 8
Z3_FLOATING_POINT_SORT = 9
Z3_ROUNDING_MODE_SORT = 10
Z3_SEQ_SORT = 11
Z3_RE_SORT = 12
Z3_UNKNOWN_SORT = 1000
# enum Z3_ast_kind
Z3_NUMERAL_AST = 0
Z3_APP_AST = 1
Z3_VAR_AST = 2
Z3_QUANTIFIER_AST = 3
Z3_SORT_AST = 4
Z3_FUNC_DECL_AST = 5
Z3_UNKNOWN_AST = 1000
# enum Z3_decl_kind
Z3_OP_TRUE = 256
Z3_OP_FALSE = 257
Z3_OP_EQ = 258
Z3_OP_DISTINCT = 259
Z3_OP_ITE = 260
Z3_OP_AND = 261
Z3_OP_OR = 262
Z3_OP_IFF = 263
Z3_OP_XOR = 264
Z3_OP_NOT = 265
Z3_OP_IMPLIES = 266
Z3_OP_OEQ = 267
Z3_OP_ANUM = 512
Z3_OP_AGNUM = 513
Z3_OP_LE = 514
Z3_OP_GE = 515
Z3_OP_LT = 516
Z3_OP_GT = 517
Z3_OP_ADD = 518
Z3_OP_SUB = 519
Z3_OP_UMINUS = 520
Z3_OP_MUL = 521
Z3_OP_DIV = 522
Z3_OP_IDIV = 523
Z3_OP_REM = 524
Z3_OP_MOD = 525
Z3_OP_TO_REAL = 526
Z3_OP_TO_INT = 527
Z3_OP_IS_INT = 528
Z3_OP_POWER = 529
Z3_OP_STORE = 768
Z3_OP_SELECT = 769
Z3_OP_CONST_ARRAY = 770
Z3_OP_ARRAY_MAP = 771
Z3_OP_ARRAY_DEFAULT = 772
Z3_OP_SET_UNION = 773
Z3_OP_SET_INTERSECT = 774
Z3_OP_SET_DIFFERENCE = 775
Z3_OP_SET_COMPLEMENT = 776
Z3_OP_SET_SUBSET = 777
Z3_OP_AS_ARRAY = 778
Z3_OP_ARRAY_EXT = 779
Z3_OP_BNUM = 1024
Z3_OP_BIT1 = 1025
Z3_OP_BIT0 = 1026
Z3_OP_BNEG = 1027
Z3_OP_BADD = 1028
Z3_OP_BSUB = 1029
Z3_OP_BMUL = 1030
Z3_OP_BSDIV = 1031
Z3_OP_BUDIV = 1032
Z3_OP_BSREM = 1033
Z3_OP_BUREM = 1034
Z3_OP_BSMOD = 1035
Z3_OP_BSDIV0 = 1036
Z3_OP_BUDIV0 = 1037
Z3_OP_BSREM0 = 1038
Z3_OP_BUREM0 = 1039
Z3_OP_BSMOD0 = 1040
Z3_OP_ULEQ = 1041
Z3_OP_SLEQ = 1042
Z3_OP_UGEQ = 1043
Z3_OP_SGEQ = 1044
Z3_OP_ULT = 1045
Z3_OP_SLT = 1046
Z3_OP_UGT = 1047
Z3_OP_SGT = 1048
Z3_OP_BAND = 1049
Z3_OP_BOR = 1050
Z3_OP_BNOT = 1051
Z3_OP_BXOR = 1052
Z3_OP_BNAND = 1053
Z3_OP_BNOR = 1054
Z3_OP_BXNOR = 1055
Z3_OP_CONCAT = 1056
Z3_OP_SIGN_EXT = 1057
Z3_OP_ZERO_EXT = 1058
Z3_OP_EXTRACT = 1059
Z3_OP_REPEAT = 1060
Z3_OP_BREDOR = 1061
Z3_OP_BREDAND = 1062
Z3_OP_BCOMP = 1063
Z3_OP_BSHL = 1064
Z3_OP_BLSHR = 1065
Z3_OP_BASHR = 1066
Z3_OP_ROTATE_LEFT = 1067
Z3_OP_ROTATE_RIGHT = 1068
Z3_OP_EXT_ROTATE_LEFT = 1069
Z3_OP_EXT_ROTATE_RIGHT = 1070
Z3_OP_BIT2BOOL = 1071
Z3_OP_INT2BV = 1072
Z3_OP_BV2INT = 1073
Z3_OP_CARRY = 1074
Z3_OP_XOR3 = 1075
Z3_OP_BSMUL_NO_OVFL = 1076
Z3_OP_BUMUL_NO_OVFL = 1077
Z3_OP_BSMUL_NO_UDFL = 1078
Z3_OP_BSDIV_I = 1079
Z3_OP_BUDIV_I = 1080
Z3_OP_BSREM_I = 1081
Z3_OP_BUREM_I = 1082
Z3_OP_BSMOD_I = 1083
Z3_OP_PR_UNDEF = 1280
Z3_OP_PR_TRUE = 1281
Z3_OP_PR_ASSERTED = 1282
Z3_OP_PR_GOAL = 1283
Z3_OP_PR_MODUS_PONENS = 1284
Z3_OP_PR_REFLEXIVITY = 1285
Z3_OP_PR_SYMMETRY = 1286
Z3_OP_PR_TRANSITIVITY = 1287
Z3_OP_PR_TRANSITIVITY_STAR = 1288
Z3_OP_PR_MONOTONICITY = 1289
Z3_OP_PR_QUANT_INTRO = 1290
Z3_OP_PR_BIND = 1291
Z3_OP_PR_DISTRIBUTIVITY = 1292
Z3_OP_PR_AND_ELIM = 1293
Z3_OP_PR_NOT_OR_ELIM = 1294
Z3_OP_PR_REWRITE = 1295
Z3_OP_PR_REWRITE_STAR = 1296
Z3_OP_PR_PULL_QUANT = 1297
Z3_OP_PR_PUSH_QUANT = 1298
Z3_OP_PR_ELIM_UNUSED_VARS = 1299
Z3_OP_PR_DER = 1300
Z3_OP_PR_QUANT_INST = 1301
Z3_OP_PR_HYPOTHESIS = 1302
Z3_OP_PR_LEMMA = 1303
Z3_OP_PR_UNIT_RESOLUTION = 1304
Z3_OP_PR_IFF_TRUE = 1305
Z3_OP_PR_IFF_FALSE = 1306
Z3_OP_PR_COMMUTATIVITY = 1307
Z3_OP_PR_DEF_AXIOM = 1308
Z3_OP_PR_ASSUMPTION_ADD = 1309
Z3_OP_PR_LEMMA_ADD = 1310
Z3_OP_PR_REDUNDANT_DEL = 1311
Z3_OP_PR_CLAUSE_TRAIL = 1312
Z3_OP_PR_DEF_INTRO = 1313
Z3_OP_PR_APPLY_DEF = 1314
Z3_OP_PR_IFF_OEQ = 1315
Z3_OP_PR_NNF_POS = 1316
Z3_OP_PR_NNF_NEG = 1317
Z3_OP_PR_SKOLEMIZE = 1318
Z3_OP_PR_MODUS_PONENS_OEQ = 1319
Z3_OP_PR_TH_LEMMA = 1320
Z3_OP_PR_HYPER_RESOLVE = 1321
Z3_OP_RA_STORE = 1536
Z3_OP_RA_EMPTY = 1537
Z3_OP_RA_IS_EMPTY = 1538
Z3_OP_RA_JOIN = 1539
Z3_OP_RA_UNION = 1540
Z3_OP_RA_WIDEN = 1541
Z3_OP_RA_PROJECT = 1542
Z3_OP_RA_FILTER = 1543
Z3_OP_RA_NEGATION_FILTER = 1544
Z3_OP_RA_RENAME = 1545
Z3_OP_RA_COMPLEMENT = 1546
Z3_OP_RA_SELECT = 1547
Z3_OP_RA_CLONE = 1548
Z3_OP_FD_CONSTANT = 1549
Z3_OP_FD_LT = 1550
Z3_OP_SEQ_UNIT = 1551
Z3_OP_SEQ_EMPTY = 1552
Z3_OP_SEQ_CONCAT = 1553
Z3_OP_SEQ_PREFIX = 1554
Z3_OP_SEQ_SUFFIX = 1555
Z3_OP_SEQ_CONTAINS = 1556
Z3_OP_SEQ_EXTRACT = 1557
Z3_OP_SEQ_REPLACE = 1558
Z3_OP_SEQ_AT = 1559
Z3_OP_SEQ_NTH = 1560
Z3_OP_SEQ_LENGTH = 1561
Z3_OP_SEQ_INDEX = 1562
Z3_OP_SEQ_LAST_INDEX = 1563
Z3_OP_SEQ_TO_RE = 1564
Z3_OP_SEQ_IN_RE = 1565
Z3_OP_STR_TO_INT = 1566
Z3_OP_INT_TO_STR = 1567
Z3_OP_RE_PLUS = 1568
Z3_OP_RE_STAR = 1569
Z3_OP_RE_OPTION = 1570
Z3_OP_RE_CONCAT = 1571
Z3_OP_RE_UNION = 1572
Z3_OP_RE_RANGE = 1573
Z3_OP_RE_LOOP = 1574
Z3_OP_RE_INTERSECT = 1575
Z3_OP_RE_EMPTY_SET = 1576
Z3_OP_RE_FULL_SET = 1577
Z3_OP_RE_COMPLEMENT = 1578
Z3_OP_LABEL = 1792
Z3_OP_LABEL_LIT = 1793
Z3_OP_DT_CONSTRUCTOR = 2048
Z3_OP_DT_RECOGNISER = 2049
Z3_OP_DT_IS = 2050
Z3_OP_DT_ACCESSOR = 2051
Z3_OP_DT_UPDATE_FIELD = 2052
Z3_OP_PB_AT_MOST = 2304
Z3_OP_PB_AT_LEAST = 2305
Z3_OP_PB_LE = 2306
Z3_OP_PB_GE = 2307
Z3_OP_PB_EQ = 2308
Z3_OP_SPECIAL_RELATION_LO = 40960
Z3_OP_SPECIAL_RELATION_PO = 40961
Z3_OP_SPECIAL_RELATION_PLO = 40962
Z3_OP_SPECIAL_RELATION_TO = 40963
Z3_OP_SPECIAL_RELATION_TC = 40964
Z3_OP_SPECIAL_RELATION_TRC = 40965
Z3_OP_FPA_RM_NEAREST_TIES_TO_EVEN = 45056
Z3_OP_FPA_RM_NEAREST_TIES_TO_AWAY = 45057
Z3_OP_FPA_RM_TOWARD_POSITIVE = 45058
Z3_OP_FPA_RM_TOWARD_NEGATIVE = 45059
Z3_OP_FPA_RM_TOWARD_ZERO = 45060
Z3_OP_FPA_NUM = 45061
Z3_OP_FPA_PLUS_INF = 45062
Z3_OP_FPA_MINUS_INF = 45063
Z3_OP_FPA_NAN = 45064
Z3_OP_FPA_PLUS_ZERO = 45065
Z3_OP_FPA_MINUS_ZERO = 45066
Z3_OP_FPA_ADD = 45067
Z3_OP_FPA_SUB = 45068
Z3_OP_FPA_NEG = 45069
Z3_OP_FPA_MUL = 45070
Z3_OP_FPA_DIV = 45071
Z3_OP_FPA_REM = 45072
Z3_OP_FPA_ABS = 45073
Z3_OP_FPA_MIN = 45074
Z3_OP_FPA_MAX = 45075
Z3_OP_FPA_FMA = 45076
Z3_OP_FPA_SQRT = 45077
Z3_OP_FPA_ROUND_TO_INTEGRAL = 45078
Z3_OP_FPA_EQ = 45079
Z3_OP_FPA_LT = 45080
Z3_OP_FPA_GT = 45081
Z3_OP_FPA_LE = 45082
Z3_OP_FPA_GE = 45083
Z3_OP_FPA_IS_NAN = 45084
Z3_OP_FPA_IS_INF = 45085
Z3_OP_FPA_IS_ZERO = 45086
Z3_OP_FPA_IS_NORMAL = 45087
Z3_OP_FPA_IS_SUBNORMAL = 45088
Z3_OP_FPA_IS_NEGATIVE = 45089
Z3_OP_FPA_IS_POSITIVE = 45090
Z3_OP_FPA_FP = 45091
Z3_OP_FPA_TO_FP = 45092
Z3_OP_FPA_TO_FP_UNSIGNED = 45093
Z3_OP_FPA_TO_UBV = 45094
Z3_OP_FPA_TO_SBV = 45095
Z3_OP_FPA_TO_REAL = 45096
Z3_OP_FPA_TO_IEEE_BV = 45097
Z3_OP_FPA_BVWRAP = 45098
Z3_OP_FPA_BV2RM = 45099
Z3_OP_INTERNAL = 45100
Z3_OP_UNINTERPRETED = 45101
# enum Z3_param_kind
Z3_PK_UINT = 0
Z3_PK_BOOL = 1
Z3_PK_DOUBLE = 2
Z3_PK_SYMBOL = 3
Z3_PK_STRING = 4
Z3_PK_OTHER = 5
Z3_PK_INVALID = 6
# enum Z3_ast_print_mode
Z3_PRINT_SMTLIB_FULL = 0
Z3_PRINT_LOW_LEVEL = 1
Z3_PRINT_SMTLIB2_COMPLIANT = 2
# enum Z3_error_code
Z3_OK = 0
Z3_SORT_ERROR = 1
Z3_IOB = 2
Z3_INVALID_ARG = 3
Z3_PARSER_ERROR = 4
Z3_NO_PARSER = 5
Z3_INVALID_PATTERN = 6
Z3_MEMOUT_FAIL = 7
Z3_FILE_ACCESS_ERROR = 8
Z3_INTERNAL_FATAL = 9
Z3_INVALID_USAGE = 10
Z3_DEC_REF_ERROR = 11
Z3_EXCEPTION = 12
# enum Z3_goal_prec
Z3_GOAL_PRECISE = 0
Z3_GOAL_UNDER = 1
Z3_GOAL_OVER = 2
Z3_GOAL_UNDER_OVER = 3
|
#!/usr/bin/env python
# -*- encoding: utf-8 -*-
"""
@Creation: 22/06/2020 22:08
@Author: liang
@File: settings.py
"""
COLLECTION_NAME = 'demos' # non-environment dependent plain text data
API_ENV = '${API_ENV:dev}'
# environment dependent sensible data
MONGO_DB_URL = '${MONGO_DB_URL:mongodb://localhost:27017}'
TYPE_VAR = '${TYPE_VAR:125<int>}'
DICT_VAR = '${DICT_VAR:{"name":"demo"}<dict>}'
LIST_VAR = '${LIST_VAR:a,b,c<list>}'
SET_VAR = '${SET_VAR:d,e,f<set>}'
TUPLE_VAR = '${TUPLE_VAR:g,h,i<tuple>}'
_config_files_ = ['config.ini'] # environment dependent plain text data
MONGO_DB_NAME = None
|
def f(x):
a = []
if x == 0:
return f(x)
while x > 0:
a.append(x)
print(x)
f(x-1)
f(3)
|
def fimdejogo(ma, ve=0):
for l in range(0, 3):
for c in range(0, 3):
# linhas
if ma[l][0] == ma[l][1] and ma[l][1] == ma[l][2]:
let = ma[l][2]
return let
# Colunas
if ma[0][c] == ma[1][c] and ma[1][c] == ma[2][c]:
let = ma[2][c]
return let
# Diagonais
if ma[0][0] == ma[1][1] and ma[1][1] == ma[2][2]:
let = ma[2][2]
return let
if ma[0][2] == ma[1][1] and ma[1][1] == ma[2][0]:
let = ma[2][0]
return let
# Velha
if ve == 9:
let = 'niguem'
return let
# Retorna se o jogo acabou
|
class Provider(PhoneNumberProvider):
formats = ("%## ####", "%##-####", "%######", "0{{area_code}} %## ####", "0{{area_code}} %##-####", "0{{area_code}}-%##-####", "0{{area_code}} %######", "(0{{area_code}}) %## ####", "(0{{area_code}}) %##-####", "(0{{area_code}}) %######", "+64 {{area_code}} %## ####", "+64 {{area_code}} %##-####", "+64 {{area_code}} %######", "+64-{{area_code}}-%##-####", "+64{{area_code}}%######")
area_codes = ["20", "21", "22", "27", "29", "3", "4", "6", "7", "9"]
def area_code(self):
return self.numerify(self.random_element(self.area_codes))
def phone_number(self):
pattern = self.random_element(self.formats)
return self.numerify(self.generator.parse(pattern)) |
# No Bugs in Production (NBP) Library
# https://github.com/aenachescu/nbplib
#
# Licensed under the MIT License <http://opensource.org/licenses/MIT>.
# SPDX-License-Identifier: MIT
# Copyright (c) 2019-2020 Alin Enachescu <https://github.com/aenachescu>
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to deal
# in the Software without restriction, including without limitation the rights
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
# copies of the Software, and to permit persons to whom the Software is
# furnished to do so, subject to the following conditions:
#
# The above copyright notice and this permission notice shall be included in all
# copies or substantial portions of the Software.
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
# SOFTWARE.
testsConfig = [
{
"name": "check_build_configuration",
"buildConfig": [
{
"config": "<any>:<any>:<any>:<any>",
"consoleOutputContains": "linux ${compiler} ${standard} "
"${platform} ${sanitizer}"
}
]
},
{
"name": "check_leak_sanitizer",
"consoleOutputContains": "check_leak_sanitizer completed successfully",
"buildConfig": [
{
"config": "<any>:<any>:<-m64>:<leak>",
"returnCode": 23,
"consoleOutputContains": "detected memory leaks"
}
]
},
{
"name": "check_thread_sanitizer",
"consoleOutputContains":
"check_thread_sanitizer completed successfully",
"buildConfig": [
{
"config": "<any>:<any>:<any>:<thread>",
"returnCode": 66,
"consoleOutputContains": "ThreadSanitizer: data race"
}
]
},
{
"name": "check_ub_sanitizer",
"consoleOutputContains": "check_ub_sanitizer completed successfully",
"buildConfig": [
{
"config": "<any>:<any>:<any>:<ub>",
"returnCode": 1,
"consoleOutputContains": "signed integer overflow"
}
]
},
{
"name": "check_address_sanitizer_heap_use_after_free",
"consoleOutputContains": "check_address_sanitizer(heap use after free) "
"completed successfully",
"buildConfig": [
{
"config": "<any>:<any>:<any>:<address>",
"returnCode": 1,
"consoleOutputContains":
"AddressSanitizer: heap-use-after-free on address"
}
]
},
{
"name": "check_address_sanitizer_heap_buffer_overflow",
"consoleOutputContains": "check_address_sanitizer(heap buffer "
"overflow) completed successfully",
"buildConfig": [
{
"config": "<any>:<any>:<any>:<address>",
"returnCode": 1,
"consoleOutputContains":
"AddressSanitizer: heap-buffer-overflow on address"
}
]
},
{
"name": "check_address_sanitizer_stack_buffer_overflow",
"consoleOutputContains":
"check_address_sanitizer_stack_buffer_overflow "
"completed successfully",
"buildConfig": [
{
"config": "<any>:<any>:<any>:<address>",
"returnCode": 1,
"consoleOutputContains":
"AddressSanitizer: stack-buffer-overflow on address"
}
]
},
{
"name": "check_address_sanitizer_global_buffer_overflow",
"consoleOutputContains":
"check_address_sanitizer_global_buffer_overflow "
"completed successfully",
"buildConfig": [
{
"config": "<any>:<any>:<any>:<address>",
"returnCode": 1,
"consoleOutputContains":
"AddressSanitizer: global-buffer-overflow on address"
}
]
},
{
"name": "check_address_sanitizer_stack_use_after_return",
"consoleOutputContains":
"check_address_sanitizer_stack_use_after_return "
"completed successfully",
"buildConfig": [
{
"config": "<any>:<any>:<any>:<address>",
"returnCode": 1,
"consoleOutputContains":
"AddressSanitizer: stack-use-after-return on address"
}
]
},
{
"name": "check_address_sanitizer_pointer_comparison",
"consoleOutputContains":
"check_address_sanitizer_pointer_comparison completed successfully",
"buildConfig": [
{
"config": "<any>:<any>:<any>:<address>",
"returnCode": 1,
"consoleOutputContains":
"AddressSanitizer: invalid-pointer-pair:"
}
]
},
{
"name": "check_address_sanitizer_pointer_subtraction",
"consoleOutputContains":"check_address_sanitizer_pointer_subtraction "
"completed successfully",
"buildConfig": [
{
"config": "<any>:<any>:<any>:<address>",
"returnCode": 1,
"consoleOutputContains":
"AddressSanitizer: invalid-pointer-pair:"
}
]
}
]
|
class Solution:
def getRow(self, rowIndex):
"""
:type rowIndex: int
:rtype: List[int]
"""
res = [1] * (rowIndex+1)
for i in range(2, rowIndex+1):
for j in range(1, i):
res[i-j] += res[i-j-1]
return res
|
loaddata = LoadData("./unified/uw/train.conll", "./unified/uw/dev.conll", "./unified/uw/test.conll")
counter, counter_dev, counter_test = [],[],[]
a = loaddata.conllu_counter['train']
a = loaddata.counter_process(a)
for d in a:
counter.append(d)
for d in range(len(counter)):
counter[d].index=tuple([d])
b = loaddata.conllu_counter['dev']
b = loaddata.counter_process(b)
for d in b :
counter_dev.append(d)
for d in range(len(counter_dev)):
counter_dev[d].index=tuple([d])
c = loaddata.conllu_counter['test']
c = loaddata.counter_process(c)
test_i=c.copy()
for d in c:
counter_test.append(d)
for d in range(len(counter_test)):
counter_test[d].index=tuple([d]) |
class WrongInputValue(Exception):
pass
class Input:
def __init__(self):
self.a = None
self.b = 0
@staticmethod
def get_int_from_user(message: str) -> int:
x = input(message)
if x.isdigit():
return int(x)
else:
raise WrongInputValue("Podaj liczbę całkowitą :)")
def get_a_from_user(self):
self.a = self.get_int_from_user("Podaj liczbę A: ")
def get_b_from_user(self):
self.b = self.get_int_from_user("Podaj liczbę B: ")
def get_a_b_from_user(self):
self.get_a_from_user()
self.get_b_from_user()
|
#
# PySNMP MIB module CISCO-WAN-PAR-MIB (http://snmplabs.com/pysmi)
# ASN.1 source file:///Users/davwang4/Dev/mibs.snmplabs.com/asn1/CISCO-WAN-PAR-MIB
# Produced by pysmi-0.3.4 at Wed May 1 12:20:40 2019
# On host DAVWANG4-M-1475 platform Darwin version 18.5.0 by user davwang4
# Using Python version 3.7.3 (default, Mar 27 2019, 09:23:15)
#
OctetString, ObjectIdentifier, Integer = mibBuilder.importSymbols("ASN1", "OctetString", "ObjectIdentifier", "Integer")
NamedValues, = mibBuilder.importSymbols("ASN1-ENUMERATION", "NamedValues")
ValueRangeConstraint, SingleValueConstraint, ConstraintsUnion, ValueSizeConstraint, ConstraintsIntersection = mibBuilder.importSymbols("ASN1-REFINEMENT", "ValueRangeConstraint", "SingleValueConstraint", "ConstraintsUnion", "ValueSizeConstraint", "ConstraintsIntersection")
par, = mibBuilder.importSymbols("BASIS-MIB", "par")
ciscoWan, = mibBuilder.importSymbols("CISCOWAN-SMI", "ciscoWan")
NotificationGroup, ModuleCompliance, ObjectGroup = mibBuilder.importSymbols("SNMPv2-CONF", "NotificationGroup", "ModuleCompliance", "ObjectGroup")
ObjectIdentity, Integer32, MibScalar, MibTable, MibTableRow, MibTableColumn, iso, NotificationType, Unsigned32, Gauge32, IpAddress, Bits, MibIdentifier, Counter32, ModuleIdentity, Counter64, TimeTicks = mibBuilder.importSymbols("SNMPv2-SMI", "ObjectIdentity", "Integer32", "MibScalar", "MibTable", "MibTableRow", "MibTableColumn", "iso", "NotificationType", "Unsigned32", "Gauge32", "IpAddress", "Bits", "MibIdentifier", "Counter32", "ModuleIdentity", "Counter64", "TimeTicks")
TruthValue, TextualConvention, DisplayString = mibBuilder.importSymbols("SNMPv2-TC", "TruthValue", "TextualConvention", "DisplayString")
ciscoWanParMIB = ModuleIdentity((1, 3, 6, 1, 4, 1, 351, 150, 63))
ciscoWanParMIB.setRevisions(('2002-09-10 00:00',))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
if mibBuilder.loadTexts: ciscoWanParMIB.setRevisionsDescriptions(('Initial version of the MIB. The content of this MIB was originally available in CISCO-WAN-AXIPOP-MIB defined using SMIv1. The applicable objects from CISCO-WAN-AXIPOP-MIB are defined using SMIv2 in this MIB. Also the descriptions of some of the objects have been modified.',))
if mibBuilder.loadTexts: ciscoWanParMIB.setLastUpdated('200209100000Z')
if mibBuilder.loadTexts: ciscoWanParMIB.setOrganization('Cisco Systems, Inc.')
if mibBuilder.loadTexts: ciscoWanParMIB.setContactInfo(' Cisco Systems Customer Service Postal: 170 W Tasman Drive San Jose, CA 95134 USA Tel: +1 800 553-NETS E-mail: cs-wanatm@cisco.com')
if mibBuilder.loadTexts: ciscoWanParMIB.setDescription('The MIB module for configuring AutoRoute controller. The Portable AutoRoute(PAR) is a Controller providing routing capabilities in Network of Cisco MGX and BPX Switches. PAR controller performs following functions: - Connection Provisioning. Adding/Deleting/modifying connections - Connection Alarm Management. On receipt of a failure event, PAR sends messages to condition the connection. - Annex G functionality. Manages the LMI communication between feeder and routing node. - Clocking Control. PAR handles the clocking selection for the switch.')
parSelfNode = MibIdentifier((1, 3, 6, 1, 4, 1, 351, 130, 1))
parInterfaces = MibIdentifier((1, 3, 6, 1, 4, 1, 351, 130, 2))
parConnection = MibIdentifier((1, 3, 6, 1, 4, 1, 351, 130, 3))
parNetworkClock = MibIdentifier((1, 3, 6, 1, 4, 1, 351, 130, 4))
parConfigParms = MibIdentifier((1, 3, 6, 1, 4, 1, 351, 130, 5))
parVsiConfigParms = MibIdentifier((1, 3, 6, 1, 4, 1, 351, 130, 5, 1))
parCmParms = MibIdentifier((1, 3, 6, 1, 4, 1, 351, 130, 5, 2))
parMnUpdt = MibIdentifier((1, 3, 6, 1, 4, 1, 351, 130, 5, 3))
parSwFunc = MibIdentifier((1, 3, 6, 1, 4, 1, 351, 130, 5, 4))
parOnOff = MibIdentifier((1, 3, 6, 1, 4, 1, 351, 130, 5, 5))
parSysParms = MibIdentifier((1, 3, 6, 1, 4, 1, 351, 130, 5, 6))
parNetworkingParms = MibIdentifier((1, 3, 6, 1, 4, 1, 351, 130, 5, 7))
parSnNodeId = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 1, 1), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 223)).clone(1)).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parSnNodeId.setStatus('current')
if mibBuilder.loadTexts: parSnNodeId.setDescription(' This object specifies the node number of the node. When the network manager tries to modify the value of this object, a message is sent node state machine which propagates this information and the value gets modified only if the new node number is successfully propagated. The node number uniquely identifies a routing node in a network.')
parSnNodeIP = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 1, 2), IpAddress()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parSnNodeIP.setStatus('current')
if mibBuilder.loadTexts: parSnNodeIP.setDescription('This object specifies the IP address for routing node and is used for communication with SNMP manager(for example Cisco Wan Manager:CWM).')
parSnNodeName = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 1, 3), DisplayString().subtype(subtypeSpec=ValueSizeConstraint(0, 8))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parSnNodeName.setStatus('current')
if mibBuilder.loadTexts: parSnNodeName.setDescription('This object specifies the name of the node and is unique among all the nodes in the network. Whenever the name of the node is changed, AutoRoute has to propagate the information to the other nodes in the network. It also specifies the name of a PAR Feeder node.')
parSnRevision = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 1, 4), DisplayString()).setMaxAccess("readonly")
if mibBuilder.loadTexts: parSnRevision.setStatus('current')
if mibBuilder.loadTexts: parSnRevision.setDescription('This object specifies the primary revision of the PAR running on the node. Format: cc.c.cc Where: c = one ascii character')
parSnNodeAlarmStatus = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 1, 5), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2, 3, 4))).clone(namedValues=NamedValues(("clear", 1), ("minor", 2), ("major", 3), ("unreach", 4)))).setMaxAccess("readonly")
if mibBuilder.loadTexts: parSnNodeAlarmStatus.setStatus('current')
if mibBuilder.loadTexts: parSnNodeAlarmStatus.setDescription('This object specifies the type of alarm on the node. clear(1) : No Alarm minor(2) : Minor Alarm major(3) : Major Alarm unreach(4) : Node is unreachable.')
parSnNumberOfTrunks = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 1, 6), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 255))).setMaxAccess("readonly")
if mibBuilder.loadTexts: parSnNumberOfTrunks.setStatus('current')
if mibBuilder.loadTexts: parSnNumberOfTrunks.setDescription('This object specifies the number of trunks attached to the node.')
parIfTable = MibTable((1, 3, 6, 1, 4, 1, 351, 130, 2, 1), )
if mibBuilder.loadTexts: parIfTable.setStatus('current')
if mibBuilder.loadTexts: parIfTable.setDescription('Table of all logical interfaces supported by PAR')
parIfEntry = MibTableRow((1, 3, 6, 1, 4, 1, 351, 130, 2, 1, 1), ).setIndexNames((0, "CISCO-WAN-PAR-MIB", "parIfLogicalInterface"))
if mibBuilder.loadTexts: parIfEntry.setStatus('current')
if mibBuilder.loadTexts: parIfEntry.setDescription('Entries for logical interfaces.')
parIfLogicalInterface = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 1, 1, 1), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 2147483647))).setMaxAccess("readonly")
if mibBuilder.loadTexts: parIfLogicalInterface.setStatus('current')
if mibBuilder.loadTexts: parIfLogicalInterface.setDescription('This object specifies the logical interface number.')
parIfType = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 1, 1, 2), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2, 3, 4, 5))).clone(namedValues=NamedValues(("userport", 1), ("routingtrunk", 2), ("feedertrunk", 3), ("clkport", 4), ("virtualtrunk", 5))).clone('userport')).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parIfType.setStatus('current')
if mibBuilder.loadTexts: parIfType.setDescription('This object specifies the type of interface. User ports need to be UNI interface. The trunks can be either UNI or NNI. userport(1) : UNI interface. This is for user ports. routingtrunk(2) : NNI interface. This value can be set provided there are no connections on the interface. feedertrunk(3) : It is feeder trunk. clkport(4) : Clock port. virtualtrunk(5): Virtual Trunk. Type of interface can be changed from nni(2) to uni(1) if the trunk is not added.')
parIfOperStatus = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 1, 1, 3), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2, 3, 4))).clone(namedValues=NamedValues(("up", 1), ("added", 2), ("failed", 3), ("added-failed", 4)))).setMaxAccess("readonly")
if mibBuilder.loadTexts: parIfOperStatus.setStatus('current')
if mibBuilder.loadTexts: parIfOperStatus.setDescription('This object specifies the operation status of the interface. up(1) : Interface is up. This value is applicable for UNI as well as NNI interfaces. added(2) : Interface is added. This value is applicable for NNI interfaces. failed(3) : Interface is failed. This value is applicable for UNI as well as NNI interfaces. added-failed (4) : Interface is failed. This value is applicable for NNI interfaces. interfaces.')
parIfTxBw = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 1, 1, 4), Integer32()).setUnits('cells-per-second').setMaxAccess("readonly")
if mibBuilder.loadTexts: parIfTxBw.setStatus('current')
if mibBuilder.loadTexts: parIfTxBw.setDescription('This object specifies the transmit bandwidth for the interface.')
parIfRxBw = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 1, 1, 5), Integer32()).setUnits('cells-per-second').setMaxAccess("readonly")
if mibBuilder.loadTexts: parIfRxBw.setStatus('current')
if mibBuilder.loadTexts: parIfRxBw.setDescription('This object specifies the receive bandwidth for the interface.')
parIfMaxConn = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 1, 1, 6), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: parIfMaxConn.setStatus('current')
if mibBuilder.loadTexts: parIfMaxConn.setDescription('This object specifies the maximum number of connections that can be configured over the interface.')
parIfHiAddrMin = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 1, 1, 7), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: parIfHiAddrMin.setStatus('current')
if mibBuilder.loadTexts: parIfHiAddrMin.setDescription('This object specifies the minimum VPI that PAR can use for configuring connection in the interface.')
parIfHiAddrMax = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 1, 1, 8), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: parIfHiAddrMax.setStatus('current')
if mibBuilder.loadTexts: parIfHiAddrMax.setDescription('This object specifies the maximum VPI that PAR can use for configuring connection in the interface.')
parIfLoAddrMin = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 1, 1, 9), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: parIfLoAddrMin.setStatus('current')
if mibBuilder.loadTexts: parIfLoAddrMin.setDescription('This object specifies the minimum VCI that PAR can use for configuring connection in the interface.')
parIfLoAddrMax = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 1, 1, 10), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: parIfLoAddrMax.setStatus('current')
if mibBuilder.loadTexts: parIfLoAddrMax.setDescription('This object specifies the maximum VCI that PAR can use for configuring connection in the interface.')
parTrkTable = MibTable((1, 3, 6, 1, 4, 1, 351, 130, 2, 2), )
if mibBuilder.loadTexts: parTrkTable.setStatus('current')
if mibBuilder.loadTexts: parTrkTable.setDescription('The table containing trunk parameters.')
parTrkEntry = MibTableRow((1, 3, 6, 1, 4, 1, 351, 130, 2, 2, 1), ).setIndexNames((0, "CISCO-WAN-PAR-MIB", "parIfLogicalInterface"))
if mibBuilder.loadTexts: parTrkEntry.setStatus('current')
if mibBuilder.loadTexts: parTrkEntry.setDescription('Entries for logical interfaces configured as trunks (parIfType nni).')
parTrkId = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 2, 1, 1), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: parTrkId.setStatus('current')
if mibBuilder.loadTexts: parTrkId.setDescription('This object specifies the logical trunk number associated with the trunk at the local node.')
parTrkStatReserve = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 2, 1, 2), Integer32().clone(1000)).setUnits('cells-per-second').setMaxAccess("readwrite")
if mibBuilder.loadTexts: parTrkStatReserve.setStatus('current')
if mibBuilder.loadTexts: parTrkStatReserve.setDescription('Specifies the bandwidth reserved as Statistical Reserve on the trunk in units of cells per second. This object cannot take a value beyond the bandwidth capacity of the trunk.')
parTrkCnfgCcRestrict = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 2, 1, 3), TruthValue().clone('false')).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parTrkCnfgCcRestrict.setStatus('current')
if mibBuilder.loadTexts: parTrkCnfgCcRestrict.setDescription('This object specifies the operators preference for routing control plane traffic on the interface. If the object is set to False, then the interface may be chosen for control plane traffic. If it is True, then the interface is not chosen, unless there is no other trunk with parIfOperStatus added(2), in which case it is chosen regardless of the value of this object.')
parTrkCnfgLineType = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 2, 1, 4), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2))).clone(namedValues=NamedValues(("terrestrial", 1), ("satellite", 2))).clone('terrestrial')).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parTrkCnfgLineType.setStatus('current')
if mibBuilder.loadTexts: parTrkCnfgLineType.setDescription('This object specifies the type of interface terrestrial or satellite. The interfaces configured as terrestrial(1) are preferred over those configured as satellite(2) for routing control plane traffic. This information is also used for connections for which routing restrictions are specified.')
parTrkCnfgPassSync = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 2, 1, 5), TruthValue().clone('true')).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parTrkCnfgPassSync.setStatus('current')
if mibBuilder.loadTexts: parTrkCnfgPassSync.setDescription('This object specifies whether the trunk can be used to pass clock sync. If the value of this object is True, clock can be synchronized through the trunk; otherwise not.')
parTrkCnfgDerouteDelay = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 2, 1, 6), Integer32()).setUnits('seconds').setMaxAccess("readwrite")
if mibBuilder.loadTexts: parTrkCnfgDerouteDelay.setStatus('current')
if mibBuilder.loadTexts: parTrkCnfgDerouteDelay.setDescription('This object specifies the value of deroute delay timer in seconds.')
parTrkCnfgTrafficClassFst = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 2, 1, 7), TruthValue().clone('true')).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parTrkCnfgTrafficClassFst.setStatus('current')
if mibBuilder.loadTexts: parTrkCnfgTrafficClassFst.setDescription('This object indicates whether Foresight traffic can be routed over the trunk. If the value is true(1), it can be rerouted otherwise not.')
parTrkCnfgTrafficClassFr = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 2, 1, 8), TruthValue().clone('true')).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parTrkCnfgTrafficClassFr.setStatus('current')
if mibBuilder.loadTexts: parTrkCnfgTrafficClassFr.setDescription('This object indicates whether Frame Relay traffic can be routed over the trunk. If the value is true(1), it can be rerouted otherwise not.')
parTrkCnfgTrafficClassNts = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 2, 1, 9), TruthValue().clone('true')).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parTrkCnfgTrafficClassNts.setStatus('current')
if mibBuilder.loadTexts: parTrkCnfgTrafficClassNts.setDescription('This object indicates whether Non-Time Stamped traffic can be routed over the trunk. If the value is true(1) it can be rerouted otherwise not.')
parTrkCnfgTrafficClassTs = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 2, 1, 10), TruthValue().clone('true')).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parTrkCnfgTrafficClassTs.setStatus('current')
if mibBuilder.loadTexts: parTrkCnfgTrafficClassTs.setDescription('This object indicates whether Time Stamped traffic can be routed over the trunk. If the value is true(1) it can be rerouted otherwise not.')
parTrkCnfgTrafficClassVoice = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 2, 1, 11), TruthValue().clone('true')).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parTrkCnfgTrafficClassVoice.setStatus('current')
if mibBuilder.loadTexts: parTrkCnfgTrafficClassVoice.setDescription('This object indicates whether Voice traffic can be routed over the trunk. If the value is true(1), it can be rerouted otherwise not.')
parTrkCnfgTrafficClassCbr = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 2, 1, 12), TruthValue().clone('true')).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parTrkCnfgTrafficClassCbr.setStatus('current')
if mibBuilder.loadTexts: parTrkCnfgTrafficClassCbr.setDescription('This object indicates whether Constant Bit Rate traffic can be routed over the trunk. If the value is true(1), it can be rerouted otherwise not.')
parTrkCnfgTrafficClassVbr = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 2, 1, 13), TruthValue().clone('true')).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parTrkCnfgTrafficClassVbr.setStatus('current')
if mibBuilder.loadTexts: parTrkCnfgTrafficClassVbr.setDescription('This object indicates whether Variable Bit Rate traffic can be routed over the trunk. If the value is true(1), it can be rerouted otherwise not.')
parTrkCnfgTrafficClassAbr = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 2, 1, 14), TruthValue().clone('true')).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parTrkCnfgTrafficClassAbr.setStatus('current')
if mibBuilder.loadTexts: parTrkCnfgTrafficClassAbr.setDescription('This object indicates whether Available Bit Rate traffic can be routed over the trunk. If the value is true(1), it can be rerouted otherwise not.')
parTrkCnfgAdminStatus = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 2, 1, 15), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2))).clone(namedValues=NamedValues(("add", 1), ("delete", 2))).clone('delete')).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parTrkCnfgAdminStatus.setStatus('current')
if mibBuilder.loadTexts: parTrkCnfgAdminStatus.setDescription('This object can be used to add or delete the trunk. The value of this object can be set to add(1) only if the parIfOperStatus is up(1). The value can be set to delete if parIfOperStatus is added or added-failed')
parTrkCnfgRoutingCost = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 2, 1, 16), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 15)).clone(7)).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parTrkCnfgRoutingCost.setStatus('current')
if mibBuilder.loadTexts: parTrkCnfgRoutingCost.setDescription('This object specifies the cost associated with the trunk for the purpose of routing the connections. This object has significance if cost based routing feature is enabled(parCmParmsCostBased)')
parTrkCnfgVccConids = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 2, 1, 17), Integer32()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parTrkCnfgVccConids.setStatus('current')
if mibBuilder.loadTexts: parTrkCnfgVccConids.setDescription('The maximum number of routing resource available on the trunk for VCC connections.')
parTrkCnfgVpcConids = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 2, 1, 18), Integer32()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parTrkCnfgVpcConids.setStatus('current')
if mibBuilder.loadTexts: parTrkCnfgVpcConids.setDescription('The maximum number of routing resource available on the trunk for VPC connections')
parTrkLocalSlotNumber = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 2, 1, 19), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 32))).setMaxAccess("readonly")
if mibBuilder.loadTexts: parTrkLocalSlotNumber.setStatus('current')
if mibBuilder.loadTexts: parTrkLocalSlotNumber.setDescription('This object specifies the slot number of the interface card associated with the trunk at the local node.')
parTrkLocalPortNumber = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 2, 1, 20), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 2147483647))).setMaxAccess("readonly")
if mibBuilder.loadTexts: parTrkLocalPortNumber.setStatus('current')
if mibBuilder.loadTexts: parTrkLocalPortNumber.setDescription('This object specifies the port number of the interface card associated with the trunk at the local node.')
parTrkLocalVTrunkId = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 2, 1, 21), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 255))).setMaxAccess("readonly")
if mibBuilder.loadTexts: parTrkLocalVTrunkId.setStatus('current')
if mibBuilder.loadTexts: parTrkLocalVTrunkId.setDescription('This object specifies the Virtual trunk of the interface card associated with the trunk at the local node. The value of this object is between 1 and 254, inclusive for a virtual trunk and 255 for a physical trunk.')
parTrkRemoteNodeId = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 2, 1, 22), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 223))).setMaxAccess("readonly")
if mibBuilder.loadTexts: parTrkRemoteNodeId.setStatus('current')
if mibBuilder.loadTexts: parTrkRemoteNodeId.setDescription('This object specifies the node number of the node attached to the remote end of the trunk.')
parTrkRemoteTrunkId = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 2, 1, 23), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 255))).setMaxAccess("readonly")
if mibBuilder.loadTexts: parTrkRemoteTrunkId.setStatus('current')
if mibBuilder.loadTexts: parTrkRemoteTrunkId.setDescription('This object specifies the logical trunk number at the node on the remote end of the trunk.')
parTrkRemoteSlotNumber = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 2, 1, 24), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 32))).setMaxAccess("readonly")
if mibBuilder.loadTexts: parTrkRemoteSlotNumber.setStatus('current')
if mibBuilder.loadTexts: parTrkRemoteSlotNumber.setDescription('This object specifies the slot number of the interface card to which the trunk is attached on the remote node.')
parTrkRemotePortNumber = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 2, 1, 25), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 2147483647))).setMaxAccess("readonly")
if mibBuilder.loadTexts: parTrkRemotePortNumber.setStatus('current')
if mibBuilder.loadTexts: parTrkRemotePortNumber.setDescription('This object specifies the port number of the interface card to which the trunk is attached on the remote node.')
parTrkRemoteVTrunkId = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 2, 1, 26), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 255))).setMaxAccess("readonly")
if mibBuilder.loadTexts: parTrkRemoteVTrunkId.setStatus('current')
if mibBuilder.loadTexts: parTrkRemoteVTrunkId.setDescription('This object specifies the Virtual trunk of the interface card associated with the trunk at the remote node. The value of this object is between 1 and 254, inclusive for a virtual trunk and 255 for a physical trunk.')
parTrkRemoteNodeIP = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 2, 1, 27), IpAddress()).setMaxAccess("readonly")
if mibBuilder.loadTexts: parTrkRemoteNodeIP.setStatus('current')
if mibBuilder.loadTexts: parTrkRemoteNodeIP.setDescription('This object specifies the IP address for the Remote node, used for communication with NMS')
parTrkRemoteNodeType = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 2, 1, 28), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2, 3, 4, 5))).clone(namedValues=NamedValues(("ipx", 1), ("igx", 2), ("bpx", 3), ("par", 4), ("unknown", 5)))).setMaxAccess("readonly")
if mibBuilder.loadTexts: parTrkRemoteNodeType.setStatus('current')
if mibBuilder.loadTexts: parTrkRemoteNodeType.setDescription('Specifies the type of the node.')
parTrkRemoteNodeName = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 2, 1, 29), DisplayString()).setMaxAccess("readonly")
if mibBuilder.loadTexts: parTrkRemoteNodeName.setStatus('current')
if mibBuilder.loadTexts: parTrkRemoteNodeName.setDescription('This object specifies the name of the remote node and is unique among all the nodes in the network.')
parTrkAlarmStatus = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 2, 1, 30), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2, 3))).clone(namedValues=NamedValues(("clear", 1), ("minor", 2), ("major", 3)))).setMaxAccess("readonly")
if mibBuilder.loadTexts: parTrkAlarmStatus.setStatus('current')
if mibBuilder.loadTexts: parTrkAlarmStatus.setDescription('This object specifies the severity of the alarm on the trunk. clear(1) : No Alarm minor(2) : Minor Alarm major(3) : Major Alarm.')
parTrkAlarmType = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 2, 1, 31), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2, 3, 4, 5))).clone(namedValues=NamedValues(("rsrcunavail", 1), ("commfail", 2), ("unknown", 3), ("failed", 4), ("looped", 5)))).setMaxAccess("readonly")
if mibBuilder.loadTexts: parTrkAlarmType.setStatus('current')
if mibBuilder.loadTexts: parTrkAlarmType.setDescription('This object specifies the type of alarm on the trunk. The value of this object has no significance if parTrunkAlarmStatus indicates no alarm. rsrcunavail(1) : resources unavailable indicates that the platform has not provided the resources required to make this interface into a trunk. commfail(2) : communication failure indicates that message exchanged between neighboring nodes on this trunk has failed. unknown (3) : indicates that the alarm type is unknown to PAR, for example if the platform has declared the interface in alarm due to some physical problem with the interface.')
parTrkBwCapacity = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 2, 1, 32), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: parTrkBwCapacity.setStatus('current')
if mibBuilder.loadTexts: parTrkBwCapacity.setDescription('Specifies the bandwidth capacity of the trunk.')
parTrkLineLoad = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 2, 1, 33), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: parTrkLineLoad.setStatus('current')
if mibBuilder.loadTexts: parTrkLineLoad.setDescription('Specifies the bandwidth used by the connections routed over the trunk.')
parTrkLoadTable = MibTable((1, 3, 6, 1, 4, 1, 351, 130, 2, 3), )
if mibBuilder.loadTexts: parTrkLoadTable.setStatus('current')
if mibBuilder.loadTexts: parTrkLoadTable.setDescription('Trunk Load Information')
parTrkLoadEntry = MibTableRow((1, 3, 6, 1, 4, 1, 351, 130, 2, 3, 1), ).setIndexNames((0, "CISCO-WAN-PAR-MIB", "parIfLogicalInterface"))
if mibBuilder.loadTexts: parTrkLoadEntry.setStatus('current')
if mibBuilder.loadTexts: parTrkLoadEntry.setDescription('Load info for logical interfaces configured as trunks (parIfType nni).')
parTrkLoadXmtUsedCbr = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 3, 1, 1), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: parTrkLoadXmtUsedCbr.setStatus('current')
if mibBuilder.loadTexts: parTrkLoadXmtUsedCbr.setDescription('This object specifies the used bandwidth in the transmit direction for CBR traffic.')
parTrkLoadRcvUsedCbr = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 3, 1, 2), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: parTrkLoadRcvUsedCbr.setStatus('current')
if mibBuilder.loadTexts: parTrkLoadRcvUsedCbr.setDescription('This object specifies the used bandwidth in the receive direction for CBR traffic')
parTrkLoadXmtUsedVbr = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 3, 1, 3), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: parTrkLoadXmtUsedVbr.setStatus('current')
if mibBuilder.loadTexts: parTrkLoadXmtUsedVbr.setDescription('This object specifies the used bandwidth in the transmit direction for VBR traffic.')
parTrkLoadRcvUsedVbr = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 3, 1, 4), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: parTrkLoadRcvUsedVbr.setStatus('current')
if mibBuilder.loadTexts: parTrkLoadRcvUsedVbr.setDescription('This object specifies the used bandwidth in the receive direction for VBR traffic.')
parTrkLoadXmtUsedAbr = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 3, 1, 5), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: parTrkLoadXmtUsedAbr.setStatus('current')
if mibBuilder.loadTexts: parTrkLoadXmtUsedAbr.setDescription('This object specifies the used bandwidth in the transmit direction for ABR.')
parTrkLoadRcvUsedAbr = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 3, 1, 6), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: parTrkLoadRcvUsedAbr.setStatus('current')
if mibBuilder.loadTexts: parTrkLoadRcvUsedAbr.setDescription('This object specifies the used bandwidth in the receive direction for ABR.')
parTrkLoadXmtUsedNts = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 3, 1, 7), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: parTrkLoadXmtUsedNts.setStatus('current')
if mibBuilder.loadTexts: parTrkLoadXmtUsedNts.setDescription('This object specifies the used bandwidth in the transmit direction for Non-Time Stamped.')
parTrkLoadRcvUsedNts = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 3, 1, 8), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: parTrkLoadRcvUsedNts.setStatus('current')
if mibBuilder.loadTexts: parTrkLoadRcvUsedNts.setDescription('This object specifies the used bandwidth in the receive direction for Non-Time Stamped.')
parTrkLoadXmtUsedTs = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 3, 1, 9), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: parTrkLoadXmtUsedTs.setStatus('current')
if mibBuilder.loadTexts: parTrkLoadXmtUsedTs.setDescription('This object specifies the used bandwidth in the transmit direction for Time-Stamped.')
parTrkLoadRcvUsedTs = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 3, 1, 10), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: parTrkLoadRcvUsedTs.setStatus('current')
if mibBuilder.loadTexts: parTrkLoadRcvUsedTs.setDescription('This object specifies the used bandwidth in the receive direction for Time-Stamped.')
parTrkLoadXmtUsedVoice = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 3, 1, 11), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: parTrkLoadXmtUsedVoice.setStatus('current')
if mibBuilder.loadTexts: parTrkLoadXmtUsedVoice.setDescription('This object specifies the used bandwidth in the transmit direction for Voice.')
parTrkLoadRcvUsedVoice = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 3, 1, 12), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: parTrkLoadRcvUsedVoice.setStatus('current')
if mibBuilder.loadTexts: parTrkLoadRcvUsedVoice.setDescription('This object specifies the used bandwidth in the receive direction for Voice.')
parTrkLoadXmtUsedBdataA = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 3, 1, 13), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: parTrkLoadXmtUsedBdataA.setStatus('current')
if mibBuilder.loadTexts: parTrkLoadXmtUsedBdataA.setDescription('This object specifies the used bandwidth in the transmit direction for Busty Data A.')
parTrkLoadRcvUsedBdataA = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 3, 1, 14), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: parTrkLoadRcvUsedBdataA.setStatus('current')
if mibBuilder.loadTexts: parTrkLoadRcvUsedBdataA.setDescription('This object specifies the used bandwidth in the receive direction for Bursty Data A.')
parTrkLoadXmtUsedBdataB = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 3, 1, 15), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: parTrkLoadXmtUsedBdataB.setStatus('current')
if mibBuilder.loadTexts: parTrkLoadXmtUsedBdataB.setDescription('This object specifies the used bandwidth in the transmit direction for Bursty Data B.')
parTrkLoadRcvUsedBdataB = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 3, 1, 16), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: parTrkLoadRcvUsedBdataB.setStatus('current')
if mibBuilder.loadTexts: parTrkLoadRcvUsedBdataB.setDescription('This object specifies the used bandwidth in the receive direction for Bursty Data B.')
parTrkLoadVccConidsUsed = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 3, 1, 17), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: parTrkLoadVccConidsUsed.setStatus('current')
if mibBuilder.loadTexts: parTrkLoadVccConidsUsed.setDescription('This object specifies the number of conids used for VCCs (not used) on the trunk.')
parTrkLoadVpcConidsUsed = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 2, 3, 1, 19), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: parTrkLoadVpcConidsUsed.setStatus('current')
if mibBuilder.loadTexts: parTrkLoadVpcConidsUsed.setDescription('This object specifies the number of conids Used for VPCs (not used) on the trunk.')
parConnectionTable = MibTable((1, 3, 6, 1, 4, 1, 351, 130, 3, 1), )
if mibBuilder.loadTexts: parConnectionTable.setStatus('current')
if mibBuilder.loadTexts: parConnectionTable.setDescription('This table contains connections Mastered or slaved by the node.')
parConnectionEntry = MibTableRow((1, 3, 6, 1, 4, 1, 351, 130, 3, 1, 1), ).setIndexNames((0, "CISCO-WAN-PAR-MIB", "parConnLocalSlot"), (0, "CISCO-WAN-PAR-MIB", "parConnLocalPort"), (0, "CISCO-WAN-PAR-MIB", "parConnLocalVpi"), (0, "CISCO-WAN-PAR-MIB", "parConnLocalVci"))
if mibBuilder.loadTexts: parConnectionEntry.setStatus('current')
if mibBuilder.loadTexts: parConnectionEntry.setDescription('Entries for connections mastered or slaved by the node. Each entry contains Local and remote end information.')
parConnLocalSlot = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 3, 1, 1, 1), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 32))).setMaxAccess("readonly")
if mibBuilder.loadTexts: parConnLocalSlot.setStatus('current')
if mibBuilder.loadTexts: parConnLocalSlot.setDescription('This object specifies the slot number part of the local endpoint connection address.')
parConnLocalPort = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 3, 1, 1, 2), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 2147483647))).setMaxAccess("readonly")
if mibBuilder.loadTexts: parConnLocalPort.setStatus('current')
if mibBuilder.loadTexts: parConnLocalPort.setDescription('This object specifies the port number part of the local endpoint connection address.')
parConnLocalVpi = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 3, 1, 1, 3), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 4095))).setMaxAccess("readonly")
if mibBuilder.loadTexts: parConnLocalVpi.setStatus('current')
if mibBuilder.loadTexts: parConnLocalVpi.setDescription('This object specifies the Virtual Path Identifier part of the local endpoint connection address.')
parConnLocalVci = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 3, 1, 1, 4), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 65535))).setMaxAccess("readonly")
if mibBuilder.loadTexts: parConnLocalVci.setStatus('current')
if mibBuilder.loadTexts: parConnLocalVci.setDescription('This object specifies the Virtual Channel Identifier part of the local endpoint connection address.')
parConnMasterShip = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 3, 1, 1, 5), TruthValue()).setMaxAccess("readonly")
if mibBuilder.loadTexts: parConnMasterShip.setStatus('current')
if mibBuilder.loadTexts: parConnMasterShip.setDescription('This object specifies whether this end of the connection is the master or the slave of the connection. The value true(1) signifies the master end and false(2) signifies slave end.')
parConnLocalVcIndx = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 3, 1, 1, 6), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: parConnLocalVcIndx.setStatus('current')
if mibBuilder.loadTexts: parConnLocalVcIndx.setDescription('This object specifies the Virtual Connection Index at this node. It is used by Network Management to correlate this end of the connection with the remote end.')
parConnLocalEndpt = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 3, 1, 1, 7), DisplayString()).setMaxAccess("readonly")
if mibBuilder.loadTexts: parConnLocalEndpt.setStatus('current')
if mibBuilder.loadTexts: parConnLocalEndpt.setDescription('This object specifies the actual physical connection endpoint at the local node.')
parConnRemoteNodeName = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 3, 1, 1, 8), DisplayString()).setMaxAccess("readonly")
if mibBuilder.loadTexts: parConnRemoteNodeName.setStatus('current')
if mibBuilder.loadTexts: parConnRemoteNodeName.setDescription('This object specifies the node name of the remote endpoint. For a intra-switch connection or feeder connection this object would specify the self node name.')
parConnRemoteSlot = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 3, 1, 1, 9), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 32))).setMaxAccess("readonly")
if mibBuilder.loadTexts: parConnRemoteSlot.setStatus('current')
if mibBuilder.loadTexts: parConnRemoteSlot.setDescription('This object specifies the slot number part of the remote endpoint connection address.')
parConnRemotePort = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 3, 1, 1, 10), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 2147483647))).setMaxAccess("readonly")
if mibBuilder.loadTexts: parConnRemotePort.setStatus('current')
if mibBuilder.loadTexts: parConnRemotePort.setDescription('This object specifies the port number part of the remote endpoint connection address.')
parConnRemoteVpi = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 3, 1, 1, 11), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: parConnRemoteVpi.setStatus('current')
if mibBuilder.loadTexts: parConnRemoteVpi.setDescription('This object specifies the VPI part of the remote endpoint connection address.')
parConnRemoteVci = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 3, 1, 1, 12), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: parConnRemoteVci.setStatus('current')
if mibBuilder.loadTexts: parConnRemoteVci.setDescription('This object specifies the VCI part of the remote endpoint connection address.')
parConnRemoteVcIndx = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 3, 1, 1, 13), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: parConnRemoteVcIndx.setStatus('current')
if mibBuilder.loadTexts: parConnRemoteVcIndx.setDescription('This object specifies the Virtual Connection Index at the remote node. It is used by Network Management to correlate this end of the connection with the remote end..')
parConnOperStatus = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 3, 1, 1, 14), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2, 3, 4))).clone(namedValues=NamedValues(("routed", 1), ("unrouted", 2), ("lmifail", 3), ("unknown", 4)))).setMaxAccess("readonly")
if mibBuilder.loadTexts: parConnOperStatus.setStatus('current')
if mibBuilder.loadTexts: parConnOperStatus.setDescription('This object specifies the status of connection as known and determined by PAR. The status shall be OK if there is an A-bit alarm on the connection.')
parConnAdminStatus = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 3, 1, 1, 15), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2, 3))).clone(namedValues=NamedValues(("down", 1), ("up", 2), ("reroute", 3))).clone('up')).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parConnAdminStatus.setStatus('current')
if mibBuilder.loadTexts: parConnAdminStatus.setDescription("This object is used by the operator to reroute or down/up a connection. The value of this object is up(1) when the connection is created. If the value of the object is set to down(1) the connection is derouted (if it is routed) and parConnOperStatus object is set to not routed. If the value of the object is up (2) and it is set to reroute(3) the connection is derouted and attempt is made to reroute the connection. If the value of the object is down (1) and the it is set to reroute (3), no action is performed and the object's value does not changes. If the value of object is down(1) and is set to up(2), an attempt is made to reroute the connection.")
parConnRoute = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 3, 1, 1, 16), DisplayString()).setMaxAccess("readonly")
if mibBuilder.loadTexts: parConnRoute.setStatus('current')
if mibBuilder.loadTexts: parConnRoute.setDescription('This object specifies the current path on which the connection is routed. A value of this object is valid only if parConnOperStatus is routed. The Null string specifies that the connection is not routed. Format: Nodename {Trk--Trk Nodename} Where: Nodename = up to 8 characters, Trk = slot.port.vtrk, slot = 1 or 2 characters, port = 1 or two characters, and vtrk = 1 or two characters and is optional. The portion of the format shown in braces {like this} can be repeated up to 10 times.')
parConnRemoteEndpt = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 3, 1, 1, 17), DisplayString()).setMaxAccess("readonly")
if mibBuilder.loadTexts: parConnRemoteEndpt.setStatus('current')
if mibBuilder.loadTexts: parConnRemoteEndpt.setDescription('This object specifies the actual physical connection endpoint at the remote end of the connection. It shall be known only if the connection is a local(DAX) connection.')
parPrefRoute = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 3, 1, 1, 18), DisplayString()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parPrefRoute.setStatus('current')
if mibBuilder.loadTexts: parPrefRoute.setDescription('This object specifies the preferred path for the connection. The Null string specifies that the connection does not have a preferred route. Format: Nodename {Trk--Trk Nodename} Where: Nodename = up to 8 characters, Trk = slot.port.vtrk, slot = 1 or 2 characters, port = 1 or two characters, and vtrk = 1 or two characters and is optional. The portion of the format shown in braces {like this} can be repeated up to 10 times.')
parConnFailRsn = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 3, 1, 1, 19), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2, 3, 4, 5, 6))).clone(namedValues=NamedValues(("down", 1), ("hwalm", 2), ("abitalm", 3), ("lmifail", 4), ("rrtfail", 5), ("incomplete", 6)))).setMaxAccess("readonly")
if mibBuilder.loadTexts: parConnFailRsn.setStatus('current')
if mibBuilder.loadTexts: parConnFailRsn.setDescription('This object specifies a reason code for the failure of the connection.')
parRrtFailRsn = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 3, 1, 1, 20), DisplayString()).setMaxAccess("readonly")
if mibBuilder.loadTexts: parRrtFailRsn.setStatus('current')
if mibBuilder.loadTexts: parRrtFailRsn.setDescription('This object specifies the Reason of failure of a connection to route.')
parConnRstrTyp = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 3, 1, 1, 21), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2, 3, 4))).clone(namedValues=NamedValues(("norestrict", 1), ("terrestrict", 2), ("satrestrict", 3), ("undefrestrict", 4)))).setMaxAccess("readonly")
if mibBuilder.loadTexts: parConnRstrTyp.setStatus('current')
if mibBuilder.loadTexts: parConnRstrTyp.setDescription('This object specifies the Route restriction of a connection.')
parConnRstrZcs = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 3, 1, 1, 22), TruthValue()).setMaxAccess("readonly")
if mibBuilder.loadTexts: parConnRstrZcs.setStatus('current')
if mibBuilder.loadTexts: parConnRstrZcs.setDescription('This object specifies whether ZCS lines should be avoided or not.')
parConnCos = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 3, 1, 1, 23), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 15))).setMaxAccess("readonly")
if mibBuilder.loadTexts: parConnCos.setStatus('current')
if mibBuilder.loadTexts: parConnCos.setDescription('This object specifies the COS for the connection.')
parClockTable = MibTable((1, 3, 6, 1, 4, 1, 351, 130, 4, 1), )
if mibBuilder.loadTexts: parClockTable.setStatus('current')
if mibBuilder.loadTexts: parClockTable.setDescription('Table of clock sources available to PAR')
parClockEntry = MibTableRow((1, 3, 6, 1, 4, 1, 351, 130, 4, 1, 1), ).setIndexNames((0, "CISCO-WAN-PAR-MIB", "parClockIndex"))
if mibBuilder.loadTexts: parClockEntry.setStatus('current')
if mibBuilder.loadTexts: parClockEntry.setDescription('Each entry represent a clock source available to PAR')
parClockIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 4, 1, 1, 1), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 2147483647))).setMaxAccess("readonly")
if mibBuilder.loadTexts: parClockIndex.setStatus('current')
if mibBuilder.loadTexts: parClockIndex.setDescription('This clock index is assigned by PAR.')
parClockType = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 4, 1, 1, 2), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2, 3, 4))).clone(namedValues=NamedValues(("primary", 1), ("secondary", 2), ("tertiary", 3), ("null", 4)))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parClockType.setStatus('current')
if mibBuilder.loadTexts: parClockType.setDescription('Specifies the type of clock.')
parClockSource = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 4, 1, 1, 3), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2, 3))).clone(namedValues=NamedValues(("internal", 1), ("interface", 2), ("external", 3))).clone('internal')).setMaxAccess("readonly")
if mibBuilder.loadTexts: parClockSource.setStatus('current')
if mibBuilder.loadTexts: parClockSource.setDescription('Specifies source of the clock.')
parClockCurSource = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 4, 1, 1, 4), TruthValue().clone('false')).setMaxAccess("readonly")
if mibBuilder.loadTexts: parClockCurSource.setStatus('current')
if mibBuilder.loadTexts: parClockCurSource.setDescription('Specifies whether clock source is a current clock source or not. The value is true if the cloock source is current and false otherwise')
parClockSourceId = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 4, 1, 1, 5), Integer32()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parClockSourceId.setStatus('current')
if mibBuilder.loadTexts: parClockSourceId.setDescription("Specifies identification of the clock - for example - if clock source is `Interface' then this field will carry logical interface number")
parClockPath = MibTableColumn((1, 3, 6, 1, 4, 1, 351, 130, 4, 1, 1, 6), DisplayString()).setMaxAccess("readonly")
if mibBuilder.loadTexts: parClockPath.setStatus('current')
if mibBuilder.loadTexts: parClockPath.setDescription('Describes the path used for clock synchronization')
parCmParmsMaxRoutingBundle = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 2, 1), Integer32().clone(24)).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parCmParmsMaxRoutingBundle.setStatus('current')
if mibBuilder.loadTexts: parCmParmsMaxRoutingBundle.setDescription('This object specifies the maximum number of connections that can be routed in one routing cycle.')
parCmParmsRerouteTimer = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 2, 2), Integer32()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parCmParmsRerouteTimer.setStatus('current')
if mibBuilder.loadTexts: parCmParmsRerouteTimer.setDescription('This object specifies the minimum time after which a connection is routed once it has been successfully routed.')
parCmParmsResetTimer = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 2, 3), TruthValue().clone('true')).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parCmParmsResetTimer.setStatus('current')
if mibBuilder.loadTexts: parCmParmsResetTimer.setDescription('This object specifies whether the reroute timer should be reset if the path for routed connection failed. If the value of the object is true(1), the timer is reset on detecting path fail.')
parCmParmsDnUpPerPass = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 2, 4), Integer32().clone(50)).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parCmParmsDnUpPerPass.setStatus('current')
if mibBuilder.loadTexts: parCmParmsDnUpPerPass.setDescription('This object specifies the maximum number of connections that are upped or down in one schedule of down connection state machine.')
parCmParmsDnUpTimer = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 2, 5), Integer32().clone(30000)).setUnits('milliseconds').setMaxAccess("readwrite")
if mibBuilder.loadTexts: parCmParmsDnUpTimer.setStatus('current')
if mibBuilder.loadTexts: parCmParmsDnUpTimer.setDescription('This object specifies the minimum time interval (in milliseconds) between two schedules of the down connection state machine.')
parCmParmsRrtErrsPerCycle = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 2, 6), Integer32().clone(50)).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parCmParmsRrtErrsPerCycle.setStatus('current')
if mibBuilder.loadTexts: parCmParmsRrtErrsPerCycle.setDescription('This object specifies the threshold for number of failures to route a connection before it is moved into the wait group. If the value of this object is zero, the feature is disabled.')
parCmParmsRrtCycleInterval = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 2, 7), Integer32().clone(5)).setUnits('minutes').setMaxAccess("readwrite")
if mibBuilder.loadTexts: parCmParmsRrtCycleInterval.setStatus('current')
if mibBuilder.loadTexts: parCmParmsRrtCycleInterval.setDescription('This object specifies the time (in minutes) for which no attempt is made to route a connection in the wait group.')
parCmParmsMaxRrtCycles = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 2, 8), Integer32().clone(10)).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parCmParmsMaxRrtCycles.setStatus('current')
if mibBuilder.loadTexts: parCmParmsMaxRrtCycles.setDescription('This object specifies the number of times a connection is added to the wait group before declaring it unroutable.')
parCmParmsRrtPauseTime = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 2, 9), Integer32()).setUnits('milliseconds').setMaxAccess("readwrite")
if mibBuilder.loadTexts: parCmParmsRrtPauseTime.setStatus('current')
if mibBuilder.loadTexts: parCmParmsRrtPauseTime.setDescription('This object specifies the time interval (in milliseconds) between two routing cycles.')
parCmParmsMaxUpdates = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 2, 10), Integer32().clone(10)).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parCmParmsMaxUpdates.setStatus('current')
if mibBuilder.loadTexts: parCmParmsMaxUpdates.setDescription('This object specifies the maximum number of connection management updates that are sent by the node in schedule..')
parCmParmsRerouteGroups = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 2, 11), Integer32().clone(50)).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parCmParmsRerouteGroups.setStatus('current')
if mibBuilder.loadTexts: parCmParmsRerouteGroups.setDescription('This object specifies the total number of reroute groups.')
parCmParmsMinRrGroupSize = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 2, 12), Integer32()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parCmParmsMinRrGroupSize.setStatus('current')
if mibBuilder.loadTexts: parCmParmsMinRrGroupSize.setDescription('This object specifies the minimum size of reroute group in Cell Load Units.')
parCmParmsRrGroupInc = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 2, 13), Integer32().clone(100)).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parCmParmsRrGroupInc.setStatus('current')
if mibBuilder.loadTexts: parCmParmsRrGroupInc.setDescription('This object specifies the increment of reroute group size (in Cell Load Units) between adjacent groups.')
parCmParmsCostBased = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 2, 14), TruthValue().clone('false')).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parCmParmsCostBased.setStatus('current')
if mibBuilder.loadTexts: parCmParmsCostBased.setDescription('This object can be configured to enable or disable cost based routing feature. If the value of this object is true(1), the feature is enabled else it is disabled.')
parCmParmsUseCache = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 2, 15), TruthValue().clone('false')).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parCmParmsUseCache.setStatus('current')
if mibBuilder.loadTexts: parCmParmsUseCache.setDescription('This object can be configured to enable or disable hop based route selection from using cache of precomputed routes. If the value of this object is true(1), the feature is enabled else it is disabled.')
parCmParmsUseDelay = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 2, 16), TruthValue().clone('false')).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parCmParmsUseDelay.setStatus('current')
if mibBuilder.loadTexts: parCmParmsUseDelay.setDescription('This object can be configured to enable or disable cost based route selection from considering end-to-end delay associated with the routes. If the value of this object is true(1), the delay would be considered otherwise daley would not be considered during routing of connection.')
parCmParmMaxViaCons = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 2, 17), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 80000)).clone(50000)).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parCmParmMaxViaCons.setStatus('current')
if mibBuilder.loadTexts: parCmParmMaxViaCons.setDescription('This object specifies the maximum number of via user connections that can be routed through the node.')
parMnUpdtInterval = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 3, 1), Integer32().clone(15)).setUnits('seconds').setMaxAccess("readwrite")
if mibBuilder.loadTexts: parMnUpdtInterval.setStatus('current')
if mibBuilder.loadTexts: parMnUpdtInterval.setDescription('This object specifies the timer interval (in seconds) for the current update state machine.')
parMnUpdtNodesPerInt = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 3, 2), Integer32().clone(20)).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parMnUpdtNodesPerInt.setStatus('current')
if mibBuilder.loadTexts: parMnUpdtNodesPerInt.setDescription('This object specifies the maximum number of nodes to which current updates can be sent per interval.')
parMnUpdtBatchSend = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 3, 3), TruthValue().clone('true')).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parMnUpdtBatchSend.setStatus('current')
if mibBuilder.loadTexts: parMnUpdtBatchSend.setDescription('This object specifies whether current updates to any node are sent one at a time or all in one go. If the value of this object is true(1), all current updates are sent to the node simultaneously. If the value of this object is False, current updates are sent one at a time.')
parSwFuncAbrVsvd = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 4, 1), TruthValue().clone('false')).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parSwFuncAbrVsvd.setStatus('current')
if mibBuilder.loadTexts: parSwFuncAbrVsvd.setDescription('This object enables/disables the ABR standard with VSVD. The feature is enabled if the value of the object is true(1).')
parSwFuncNodeType = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 4, 2), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2))).clone(namedValues=NamedValues(("routing", 1), ("feeder", 2))).clone('routing')).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parSwFuncNodeType.setStatus('current')
if mibBuilder.loadTexts: parSwFuncNodeType.setDescription('This object specifies whether the node is a routing node or a feeder node. To configure the node from a routing(1) node to feeder(2) node the node should be part of a single node network. To configure the node from feeder node to routing node, there should be no feeder trunk attached to the node.')
parOnOffBackgroundUpdt = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 5, 1), TruthValue().clone('false')).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parOnOffBackgroundUpdt.setStatus('current')
if mibBuilder.loadTexts: parOnOffBackgroundUpdt.setDescription('This object can be used to enable or disable Background updates. If the value of the object is true(1), background updates are enabled; otherwise they are disabled.')
parOnOffDynamicBwAlloc = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 5, 2), TruthValue().clone('true')).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parOnOffDynamicBwAlloc.setStatus('current')
if mibBuilder.loadTexts: parOnOffDynamicBwAlloc.setDescription('This object can be used to enable or disable Bandwidth state machine. If the value of the object is true(1), bandwidth state machine is enabled; otherwise it is disabled.')
parOnOffCmUpdts = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 5, 3), TruthValue().clone('true')).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parOnOffCmUpdts.setStatus('current')
if mibBuilder.loadTexts: parOnOffCmUpdts.setDescription('This object can be used to enable or disable connection management updates. If the value of the object is true(1), connection management updates are enabled; otherwise they are disabled.')
parOnOffRouting = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 5, 4), TruthValue().clone('true')).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parOnOffRouting.setStatus('current')
if mibBuilder.loadTexts: parOnOffRouting.setDescription('This object can be used to enable or disable connection routing. If the value of the object is true(1), routing is enabled; otherwise it is disabled.')
parOnOffCommFailTest = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 5, 5), TruthValue().clone('true')).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parOnOffCommFailTest.setStatus('current')
if mibBuilder.loadTexts: parOnOffCommFailTest.setDescription('This object can be used to enable or disable Comm Fail Test. If the value of the object is true(1), Comm Fail test is enabled; otherwise it is disabled.')
parOnOffDrtDelay = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 5, 6), TruthValue().clone('true')).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parOnOffDrtDelay.setStatus('current')
if mibBuilder.loadTexts: parOnOffDrtDelay.setDescription('This object can be used to enable or disable Deroute Delay feature. If the value of the object is true(1) Derote delay feature is enabled; otherwise it is disabled.')
parOnOffRenumRec = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 5, 7), TruthValue().clone('false')).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parOnOffRenumRec.setStatus('current')
if mibBuilder.loadTexts: parOnOffRenumRec.setDescription('This object can be used to enable or disable Renumber recovery feature. If the value of the object is true(1), renumber recovery feature is enabled; otherwise it is disabled.')
parOnOffCommBreak = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 5, 8), TruthValue().clone('false')).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parOnOffCommBreak.setStatus('current')
if mibBuilder.loadTexts: parOnOffCommBreak.setDescription('This object can be used to enable or disable Comm Break Test. If the value of the object is true(1), Comm Break Test feature is enabled; otherwise it is disabled.')
parSysParmsTsPacketAge = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 6, 1), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 64)).clone(64)).setUnits('milliseconds').setMaxAccess("readwrite")
if mibBuilder.loadTexts: parSysParmsTsPacketAge.setStatus('current')
if mibBuilder.loadTexts: parSysParmsTsPacketAge.setDescription('Time Stamped packets older than this value (in milliseconds)are discarded. This is a network wide parameter.')
parSysParmsConnFail = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 6, 2), TruthValue().clone('false')).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parSysParmsConnFail.setStatus('current')
if mibBuilder.loadTexts: parSysParmsConnFail.setDescription('This object specifies whether the connections to a node should be failed when comm fail is declared with the node. If the value of this object is true(1), the connection will be failed. This is a network wide parameter.')
parSysParmsVcPollRate = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 6, 3), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: parSysParmsVcPollRate.setStatus('current')
if mibBuilder.loadTexts: parSysParmsVcPollRate.setDescription('This object specifies the rate at which VC statistics are to be polled. This is a network wide parameter. For Portable AutoRoute statistic collections would be done by platform software.')
parSysParmsMaxVDelay = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 6, 4), Integer32()).setUnits('milliseconds').setMaxAccess("readonly")
if mibBuilder.loadTexts: parSysParmsMaxVDelay.setStatus('current')
if mibBuilder.loadTexts: parSysParmsMaxVDelay.setDescription('This object specifies the maximum delay for voice connection with VAD enabled in milli-seconds. This is a network wide parameter.')
parSysParmsMaxCDelay = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 6, 5), Integer32()).setUnits('milliseconds').setMaxAccess("readonly")
if mibBuilder.loadTexts: parSysParmsMaxCDelay.setStatus('current')
if mibBuilder.loadTexts: parSysParmsMaxCDelay.setDescription('This object specifies the maximum delay for ADPCM compressed voice connection with VAD enabled in milli-seconds. This is a network wide parameter.')
parSysParmsMaxDDelay = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 6, 6), Integer32()).setUnits('milliseconds').setMaxAccess("readonly")
if mibBuilder.loadTexts: parSysParmsMaxDDelay.setStatus('current')
if mibBuilder.loadTexts: parSysParmsMaxDDelay.setDescription('This object specifies the maximum delay for data connection in milli-seconds. This is a network wide parameter.')
parSysParmsMaxADelay = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 6, 7), Integer32()).setUnits('milliseconds').setMaxAccess("readonly")
if mibBuilder.loadTexts: parSysParmsMaxADelay.setStatus('current')
if mibBuilder.loadTexts: parSysParmsMaxADelay.setDescription('This object specifies the maximum delay for ADPCM compressed voice connection in milli-seconds. This is a network wide parameter.')
parSysParmsMaxHsdDelay = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 6, 8), Integer32()).setUnits('milliseconds').setMaxAccess("readonly")
if mibBuilder.loadTexts: parSysParmsMaxHsdDelay.setStatus('current')
if mibBuilder.loadTexts: parSysParmsMaxHsdDelay.setDescription('This object specifies the maximum delay for High Speed data connection in milli-seconds. This is a network wide parameter.')
parSysParmsDeEnable = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 6, 9), TruthValue()).setMaxAccess("readonly")
if mibBuilder.loadTexts: parSysParmsDeEnable.setStatus('current')
if mibBuilder.loadTexts: parSysParmsDeEnable.setDescription('This object specifies whether DE bit of Frame Relay frames can be modified. DE bit can be modified if the value of this object is true(1). This is a network wide parameter.')
parSysParmsFrStandard = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 6, 10), TruthValue()).setMaxAccess("readonly")
if mibBuilder.loadTexts: parSysParmsFrStandard.setStatus('current')
if mibBuilder.loadTexts: parSysParmsFrStandard.setDescription('This object specifies whether standard Frame Relay parameters,Be and Bc, are to be used. If the value of this object is true(1), standard parameters are used. This is a network wide parameter.')
parSysParmsDrtDelay = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 6, 11), TruthValue().clone('true')).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parSysParmsDrtDelay.setStatus('current')
if mibBuilder.loadTexts: parSysParmsDrtDelay.setDescription('This object specifies whether Deroute Delay feature is enabled. If the value of this object is true(1), the feature is enabled. This is a network wide parameter.')
parSysParmsInvLogAlarmThres = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 6, 12), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: parSysParmsInvLogAlarmThres.setStatus('current')
if mibBuilder.loadTexts: parSysParmsInvLogAlarmThres.setDescription('This object specifies the threshold for invalid login attempts before triggering an alarm. If the value of this object is zero, this feature is disabled. This is a network wide parameter.')
parSysParmsMaxCdpVDelay = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 6, 13), Integer32()).setUnits('milliseconds').setMaxAccess("readonly")
if mibBuilder.loadTexts: parSysParmsMaxCdpVDelay.setStatus('current')
if mibBuilder.loadTexts: parSysParmsMaxCdpVDelay.setDescription('This object specifies the maximum network delay for CDP to CDP voice connection with VAD enabled in milli-seconds. This is a network wide parameter.')
parSysParmsMaxCdpCDelay = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 6, 14), Integer32()).setUnits('milliseconds').setMaxAccess("readonly")
if mibBuilder.loadTexts: parSysParmsMaxCdpCDelay.setStatus('current')
if mibBuilder.loadTexts: parSysParmsMaxCdpCDelay.setDescription('This object specifies the maximum network delay for CDP to CDP ADPCM compressed voice connection with VAD enabled. This is a network wide parameter.')
parSysParmsMaxCdpDDelay = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 6, 15), Integer32()).setUnits('milliseconds').setMaxAccess("readonly")
if mibBuilder.loadTexts: parSysParmsMaxCdpDDelay.setStatus('current')
if mibBuilder.loadTexts: parSysParmsMaxCdpDDelay.setDescription('This object specifies the maximum network delay for CDP to CDP data connection. This is a network wide parameter.')
parSysParmsMaxCdpADelay = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 6, 16), Integer32()).setUnits('milliseconds').setMaxAccess("readonly")
if mibBuilder.loadTexts: parSysParmsMaxCdpADelay.setStatus('current')
if mibBuilder.loadTexts: parSysParmsMaxCdpADelay.setDescription('This object specifies the maximum network delay for CDP to CDP ADPCM compressed voice connection. This is a network wide parameter.')
parSysParmsMaxCdpHsdDelay = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 6, 17), Integer32()).setUnits('milliseconds').setMaxAccess("readonly")
if mibBuilder.loadTexts: parSysParmsMaxCdpHsdDelay.setStatus('current')
if mibBuilder.loadTexts: parSysParmsMaxCdpHsdDelay.setDescription('This object specifies the maximum network delay for CDP to CDP High Speed data connection. This is a network wide parameter.')
parSysParmsMaxIpcdpVDelay = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 6, 18), Integer32()).setUnits('milliseconds').setMaxAccess("readonly")
if mibBuilder.loadTexts: parSysParmsMaxIpcdpVDelay.setStatus('current')
if mibBuilder.loadTexts: parSysParmsMaxIpcdpVDelay.setDescription('This object specifies the maximum local delay for CDP to CDP voice connection with VAD enabled. This is a network wide parameter.')
parSysParmsMaxIpcdpCDelay = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 6, 19), Integer32()).setUnits('milliseconds').setMaxAccess("readonly")
if mibBuilder.loadTexts: parSysParmsMaxIpcdpCDelay.setStatus('current')
if mibBuilder.loadTexts: parSysParmsMaxIpcdpCDelay.setDescription('This object specifies the maximum local delay for CDP to CDP ADPCM compressed voice connection with VAD enabled. This is a network wide parameter.')
parSysParmsMaxIpcdpDDelay = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 6, 20), Integer32()).setUnits('milliseconds').setMaxAccess("readonly")
if mibBuilder.loadTexts: parSysParmsMaxIpcdpDDelay.setStatus('current')
if mibBuilder.loadTexts: parSysParmsMaxIpcdpDDelay.setDescription('This object specifies the maximum local delay for CDP to CDP data connection. This is a network wide parameter.')
parSysParmsMaxIpcdpADelay = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 6, 21), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: parSysParmsMaxIpcdpADelay.setStatus('current')
if mibBuilder.loadTexts: parSysParmsMaxIpcdpADelay.setDescription('This object specifies the maximum local delay for CDP to CDP ADPCM compressed voice connection. This is a network wide parameter.')
parSysParmsMaxIpcdpHsdDelay = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 6, 22), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: parSysParmsMaxIpcdpHsdDelay.setStatus('current')
if mibBuilder.loadTexts: parSysParmsMaxIpcdpHsdDelay.setDescription('This object specifies the maximum local delay for CDP to CDP High Speed data connection. This is a network wide parameter.')
parSysParmsMaxIphsdDelay = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 6, 23), Integer32()).setUnits('milliseconds').setMaxAccess("readonly")
if mibBuilder.loadTexts: parSysParmsMaxIphsdDelay.setStatus('current')
if mibBuilder.loadTexts: parSysParmsMaxIphsdDelay.setDescription('This object specifies the maximum local delay for High Speed data connection. This is a network wide parameter.')
parSysParmsFpdDeJitter = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 6, 24), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: parSysParmsFpdDeJitter.setStatus('current')
if mibBuilder.loadTexts: parSysParmsFpdDeJitter.setDescription('This object specifies the jitter delay for Fast Pad. This is a network wide parameter.')
parNetParmCondInitialStgr = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 7, 1), Integer32().clone(5000)).setUnits('milliseconds').setMaxAccess("readwrite")
if mibBuilder.loadTexts: parNetParmCondInitialStgr.setStatus('current')
if mibBuilder.loadTexts: parNetParmCondInitialStgr.setDescription('This object specifies the initial pause time (in milliseconds) per new node added on addition of node(s) in the network before initiating conditional updates.')
parNetParmCondPerNodeInterval = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 7, 2), Integer32().clone(30000)).setUnits('milliseconds').setMaxAccess("readwrite")
if mibBuilder.loadTexts: parNetParmCondPerNodeInterval.setStatus('current')
if mibBuilder.loadTexts: parNetParmCondPerNodeInterval.setDescription('This object specifies the minimum interval (in milliseconds) between sending of conditional updates to any two nodes.')
parNetParmCbDelay = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 7, 3), Integer32().clone(30000)).setUnits('milliseconds').setMaxAccess("readwrite")
if mibBuilder.loadTexts: parNetParmCbDelay.setStatus('current')
if mibBuilder.loadTexts: parNetParmCbDelay.setDescription('This object specifies the minimum interval (in milliseconds) between initiating comm break tests between any two nodes.')
parNetParmCbOffset = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 7, 4), Integer32().clone(10)).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parNetParmCbOffset.setStatus('current')
if mibBuilder.loadTexts: parNetParmCbOffset.setDescription('Offset for CB.')
parNetParmMsgTimeout = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 7, 5), Integer32().clone(1700)).setUnits('milliseconds').setMaxAccess("readwrite")
if mibBuilder.loadTexts: parNetParmMsgTimeout.setStatus('current')
if mibBuilder.loadTexts: parNetParmMsgTimeout.setDescription('This object specifies the timeout (in milliseconds) for acknowledgment for control plane message sent to another node.')
parNetParmMsgMaxTimeout = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 7, 6), Integer32().clone(7)).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parNetParmMsgMaxTimeout.setStatus('current')
if mibBuilder.loadTexts: parNetParmMsgMaxTimeout.setDescription('This object specifies the maximum number of times a network handler timeout waiting for acknowledgment for control plane message sent to another node reachable through all terrestrial trunks.')
parNetParmMsgMaxTimeoutSat = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 7, 7), Integer32().clone(6)).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parNetParmMsgMaxTimeoutSat.setStatus('current')
if mibBuilder.loadTexts: parNetParmMsgMaxTimeoutSat.setDescription('This object specifies the maximum number of times a network handler timeout waiting for acknowledgment for control plane message sent to another node reachable through all satellite trunks.')
parNetParmBlindMaxTimeout = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 7, 8), Integer32().clone(4)).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parNetParmBlindMaxTimeout.setStatus('current')
if mibBuilder.loadTexts: parNetParmBlindMaxTimeout.setDescription('This object specifies the maximum number of times a network handler timeout waiting for acknowledgment for control plane blind message sent to another node.')
parNetParmCbMaxTimeout = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 7, 9), Integer32().clone(5)).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parNetParmCbMaxTimeout.setStatus('current')
if mibBuilder.loadTexts: parNetParmCbMaxTimeout.setDescription('This object specifies the maximum number of times a network handler timeout waiting for acknowledgment for comm break test message sent to another node.')
parNetParmCfTestInterval = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 7, 10), Integer32().clone(10000)).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parNetParmCfTestInterval.setStatus('current')
if mibBuilder.loadTexts: parNetParmCfTestInterval.setDescription('This object specifies the minimum time interval between the comm fail tests for a trunk.')
parNetParmCfTestMultiplier = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 7, 11), Integer32().clone(3)).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parNetParmCfTestMultiplier.setStatus('current')
if mibBuilder.loadTexts: parNetParmCfTestMultiplier.setDescription('This object specifies the multiplier for the comm fail test interval for good trunks, that is, trunks not in comm fail.')
parNetParmNetwWindowSz = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 7, 12), Integer32().clone(1)).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parNetParmNetwWindowSz.setStatus('current')
if mibBuilder.loadTexts: parNetParmNetwWindowSz.setDescription('This object specifies the window size for the network handler for messages to any node. That is, the number of messages that the network handler can send simultaneous to a node without receiving the acknowledgment for them.')
parNetParmNetwLetWait = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 7, 13), Integer32().clone(50)).setUnits('milliseconds').setMaxAccess("readwrite")
if mibBuilder.loadTexts: parNetParmNetwLetWait.setStatus('current')
if mibBuilder.loadTexts: parNetParmNetwLetWait.setDescription('This object specifies the maximum interval (in milliseconds) network handler waits for the letter (message) from the processes running on its nodes before checking the received cells.')
parNetParmCfDelay = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 7, 14), Integer32().clone(60)).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parNetParmCfDelay.setStatus('current')
if mibBuilder.loadTexts: parNetParmCfDelay.setDescription('TBD (in milliseconds).')
parNetParmHighTxRate = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 7, 15), Integer32().clone(2500)).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parNetParmHighTxRate.setStatus('current')
if mibBuilder.loadTexts: parNetParmHighTxRate.setDescription('This object specifies the rate (in fast packets per second) at which the network handler sends control plane message cells to high performance nodes (High performance node are BPX and MGX).')
parNetParmLowTxRate = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 7, 16), Integer32().clone(500)).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parNetParmLowTxRate.setStatus('current')
if mibBuilder.loadTexts: parNetParmLowTxRate.setDescription('This object specifies the rate (in fast packets per second) at which the network handler sends control plane message cells to low capacity nodes (Low capacity node are IPX and IGX).')
parNetParmMaxNodeBlks = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 7, 17), Integer32().clone(3000)).setMaxAccess("readwrite")
if mibBuilder.loadTexts: parNetParmMaxNodeBlks.setStatus('current')
if mibBuilder.loadTexts: parNetParmMaxNodeBlks.setDescription('This object specifies the maximum number of blocks of size 256 bytes, that should be queued up for transmission to a node.')
parNetParmTopoMsgSegSz = MibScalar((1, 3, 6, 1, 4, 1, 351, 130, 5, 7, 18), Integer32().clone(3570)).setUnits('bytes').setMaxAccess("readwrite")
if mibBuilder.loadTexts: parNetParmTopoMsgSegSz.setStatus('current')
if mibBuilder.loadTexts: parNetParmTopoMsgSegSz.setDescription('This object specifies the maximum size (in bytes) of the segment into which the topology message, sent during network join, is divided.')
cwParMIBConformance = MibIdentifier((1, 3, 6, 1, 4, 1, 351, 150, 63, 2))
cwParMIBGroups = MibIdentifier((1, 3, 6, 1, 4, 1, 351, 150, 63, 2, 1))
cwParMIBCompliances = MibIdentifier((1, 3, 6, 1, 4, 1, 351, 150, 63, 2, 2))
cwParCompliance = ModuleCompliance((1, 3, 6, 1, 4, 1, 351, 150, 63, 2, 2, 1)).setObjects(("CISCO-WAN-PAR-MIB", "cwParCmParamsGroup"), ("CISCO-WAN-PAR-MIB", "cwParCmParamsUpdateGroup"), ("CISCO-WAN-PAR-MIB", "cwParGeneralGroup"), ("CISCO-WAN-PAR-MIB", "cwParSysParamsGroup"), ("CISCO-WAN-PAR-MIB", "cwParNetParamsGroup"), ("CISCO-WAN-PAR-MIB", "cwParNodeGroup"), ("CISCO-WAN-PAR-MIB", "cwParInterfaceConfGroup"), ("CISCO-WAN-PAR-MIB", "cwParTrunkConfGroup"), ("CISCO-WAN-PAR-MIB", "cwParTrunkLoadConfGroup"), ("CISCO-WAN-PAR-MIB", "cwParConnConfGroup"), ("CISCO-WAN-PAR-MIB", "cwParClockConfGroup"))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
cwParCompliance = cwParCompliance.setStatus('current')
if mibBuilder.loadTexts: cwParCompliance.setDescription('The compliance statement for objects related to AutoRoute MIB.')
cwParCmParamsGroup = ObjectGroup((1, 3, 6, 1, 4, 1, 351, 150, 63, 2, 1, 1)).setObjects(("CISCO-WAN-PAR-MIB", "parCmParmsMaxRoutingBundle"), ("CISCO-WAN-PAR-MIB", "parCmParmsRerouteTimer"), ("CISCO-WAN-PAR-MIB", "parCmParmsResetTimer"), ("CISCO-WAN-PAR-MIB", "parCmParmsDnUpPerPass"), ("CISCO-WAN-PAR-MIB", "parCmParmsDnUpTimer"), ("CISCO-WAN-PAR-MIB", "parCmParmsRrtErrsPerCycle"), ("CISCO-WAN-PAR-MIB", "parCmParmsRrtCycleInterval"), ("CISCO-WAN-PAR-MIB", "parCmParmsMaxRrtCycles"), ("CISCO-WAN-PAR-MIB", "parCmParmsRrtPauseTime"), ("CISCO-WAN-PAR-MIB", "parCmParmsMaxUpdates"), ("CISCO-WAN-PAR-MIB", "parCmParmsRerouteGroups"), ("CISCO-WAN-PAR-MIB", "parCmParmsMinRrGroupSize"), ("CISCO-WAN-PAR-MIB", "parCmParmsRrGroupInc"), ("CISCO-WAN-PAR-MIB", "parCmParmsCostBased"), ("CISCO-WAN-PAR-MIB", "parCmParmsUseCache"), ("CISCO-WAN-PAR-MIB", "parCmParmsUseDelay"), ("CISCO-WAN-PAR-MIB", "parCmParmMaxViaCons"))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
cwParCmParamsGroup = cwParCmParamsGroup.setStatus('current')
if mibBuilder.loadTexts: cwParCmParamsGroup.setDescription('The collection of objects which are applicable for PAR connection management.')
cwParCmParamsUpdateGroup = ObjectGroup((1, 3, 6, 1, 4, 1, 351, 150, 63, 2, 1, 2)).setObjects(("CISCO-WAN-PAR-MIB", "parMnUpdtInterval"), ("CISCO-WAN-PAR-MIB", "parMnUpdtNodesPerInt"), ("CISCO-WAN-PAR-MIB", "parMnUpdtBatchSend"))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
cwParCmParamsUpdateGroup = cwParCmParamsUpdateGroup.setStatus('current')
if mibBuilder.loadTexts: cwParCmParamsUpdateGroup.setDescription('The collection of objects which are applicable for PAR Connection Management parameters updates.')
cwParGeneralGroup = ObjectGroup((1, 3, 6, 1, 4, 1, 351, 150, 63, 2, 1, 3)).setObjects(("CISCO-WAN-PAR-MIB", "parSwFuncAbrVsvd"), ("CISCO-WAN-PAR-MIB", "parSwFuncNodeType"), ("CISCO-WAN-PAR-MIB", "parOnOffBackgroundUpdt"), ("CISCO-WAN-PAR-MIB", "parOnOffDynamicBwAlloc"), ("CISCO-WAN-PAR-MIB", "parOnOffCmUpdts"), ("CISCO-WAN-PAR-MIB", "parOnOffRouting"), ("CISCO-WAN-PAR-MIB", "parOnOffCommFailTest"), ("CISCO-WAN-PAR-MIB", "parOnOffDrtDelay"), ("CISCO-WAN-PAR-MIB", "parOnOffRenumRec"), ("CISCO-WAN-PAR-MIB", "parOnOffCommBreak"))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
cwParGeneralGroup = cwParGeneralGroup.setStatus('current')
if mibBuilder.loadTexts: cwParGeneralGroup.setDescription('The collection of objects which are applicable for general PAR configuration.')
cwParSysParamsGroup = ObjectGroup((1, 3, 6, 1, 4, 1, 351, 150, 63, 2, 1, 4)).setObjects(("CISCO-WAN-PAR-MIB", "parSysParmsTsPacketAge"), ("CISCO-WAN-PAR-MIB", "parSysParmsConnFail"), ("CISCO-WAN-PAR-MIB", "parSysParmsVcPollRate"), ("CISCO-WAN-PAR-MIB", "parSysParmsMaxVDelay"), ("CISCO-WAN-PAR-MIB", "parSysParmsMaxCDelay"), ("CISCO-WAN-PAR-MIB", "parSysParmsMaxDDelay"), ("CISCO-WAN-PAR-MIB", "parSysParmsMaxADelay"), ("CISCO-WAN-PAR-MIB", "parSysParmsMaxHsdDelay"), ("CISCO-WAN-PAR-MIB", "parSysParmsDeEnable"), ("CISCO-WAN-PAR-MIB", "parSysParmsFrStandard"), ("CISCO-WAN-PAR-MIB", "parSysParmsDrtDelay"), ("CISCO-WAN-PAR-MIB", "parSysParmsInvLogAlarmThres"), ("CISCO-WAN-PAR-MIB", "parSysParmsMaxCdpVDelay"), ("CISCO-WAN-PAR-MIB", "parSysParmsMaxCdpCDelay"), ("CISCO-WAN-PAR-MIB", "parSysParmsMaxCdpDDelay"), ("CISCO-WAN-PAR-MIB", "parSysParmsMaxCdpADelay"), ("CISCO-WAN-PAR-MIB", "parSysParmsMaxCdpHsdDelay"), ("CISCO-WAN-PAR-MIB", "parSysParmsMaxIpcdpVDelay"), ("CISCO-WAN-PAR-MIB", "parSysParmsMaxIpcdpCDelay"), ("CISCO-WAN-PAR-MIB", "parSysParmsMaxIpcdpDDelay"), ("CISCO-WAN-PAR-MIB", "parSysParmsMaxIpcdpADelay"), ("CISCO-WAN-PAR-MIB", "parSysParmsMaxIpcdpHsdDelay"), ("CISCO-WAN-PAR-MIB", "parSysParmsMaxIphsdDelay"), ("CISCO-WAN-PAR-MIB", "parSysParmsFpdDeJitter"))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
cwParSysParamsGroup = cwParSysParamsGroup.setStatus('current')
if mibBuilder.loadTexts: cwParSysParamsGroup.setDescription('The collection of objects which are applicable for PAR system parameters.')
cwParNetParamsGroup = ObjectGroup((1, 3, 6, 1, 4, 1, 351, 150, 63, 2, 1, 5)).setObjects(("CISCO-WAN-PAR-MIB", "parNetParmCondInitialStgr"), ("CISCO-WAN-PAR-MIB", "parNetParmCondPerNodeInterval"), ("CISCO-WAN-PAR-MIB", "parNetParmCbDelay"), ("CISCO-WAN-PAR-MIB", "parNetParmCbOffset"), ("CISCO-WAN-PAR-MIB", "parNetParmMsgTimeout"), ("CISCO-WAN-PAR-MIB", "parNetParmMsgMaxTimeout"), ("CISCO-WAN-PAR-MIB", "parNetParmMsgMaxTimeoutSat"), ("CISCO-WAN-PAR-MIB", "parNetParmBlindMaxTimeout"), ("CISCO-WAN-PAR-MIB", "parNetParmCbMaxTimeout"), ("CISCO-WAN-PAR-MIB", "parNetParmCfTestInterval"), ("CISCO-WAN-PAR-MIB", "parNetParmCfTestMultiplier"), ("CISCO-WAN-PAR-MIB", "parNetParmNetwWindowSz"), ("CISCO-WAN-PAR-MIB", "parNetParmNetwLetWait"), ("CISCO-WAN-PAR-MIB", "parNetParmCfDelay"), ("CISCO-WAN-PAR-MIB", "parNetParmHighTxRate"), ("CISCO-WAN-PAR-MIB", "parNetParmLowTxRate"), ("CISCO-WAN-PAR-MIB", "parNetParmMaxNodeBlks"), ("CISCO-WAN-PAR-MIB", "parNetParmTopoMsgSegSz"))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
cwParNetParamsGroup = cwParNetParamsGroup.setStatus('current')
if mibBuilder.loadTexts: cwParNetParamsGroup.setDescription('The collection of objects which are applicable for parameters applicable network-wide.')
cwParNodeGroup = ObjectGroup((1, 3, 6, 1, 4, 1, 351, 150, 63, 2, 1, 6)).setObjects(("CISCO-WAN-PAR-MIB", "parSnNodeId"), ("CISCO-WAN-PAR-MIB", "parSnNodeIP"), ("CISCO-WAN-PAR-MIB", "parSnNodeName"), ("CISCO-WAN-PAR-MIB", "parSnRevision"), ("CISCO-WAN-PAR-MIB", "parSnNodeAlarmStatus"), ("CISCO-WAN-PAR-MIB", "parSnNumberOfTrunks"))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
cwParNodeGroup = cwParNodeGroup.setStatus('current')
if mibBuilder.loadTexts: cwParNodeGroup.setDescription('The collection of objects which are applicable for node level configuration of auto route controller.')
cwParInterfaceConfGroup = ObjectGroup((1, 3, 6, 1, 4, 1, 351, 150, 63, 2, 1, 7)).setObjects(("CISCO-WAN-PAR-MIB", "parIfLogicalInterface"), ("CISCO-WAN-PAR-MIB", "parIfType"), ("CISCO-WAN-PAR-MIB", "parIfOperStatus"), ("CISCO-WAN-PAR-MIB", "parIfTxBw"), ("CISCO-WAN-PAR-MIB", "parIfRxBw"), ("CISCO-WAN-PAR-MIB", "parIfMaxConn"), ("CISCO-WAN-PAR-MIB", "parIfHiAddrMin"), ("CISCO-WAN-PAR-MIB", "parIfHiAddrMax"), ("CISCO-WAN-PAR-MIB", "parIfLoAddrMin"), ("CISCO-WAN-PAR-MIB", "parIfLoAddrMax"))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
cwParInterfaceConfGroup = cwParInterfaceConfGroup.setStatus('current')
if mibBuilder.loadTexts: cwParInterfaceConfGroup.setDescription('The collection of objects which are used for configuring autoroute interfaces.')
cwParTrunkConfGroup = ObjectGroup((1, 3, 6, 1, 4, 1, 351, 150, 63, 2, 1, 8)).setObjects(("CISCO-WAN-PAR-MIB", "parTrkId"), ("CISCO-WAN-PAR-MIB", "parTrkStatReserve"), ("CISCO-WAN-PAR-MIB", "parTrkCnfgCcRestrict"), ("CISCO-WAN-PAR-MIB", "parTrkCnfgLineType"), ("CISCO-WAN-PAR-MIB", "parTrkCnfgPassSync"), ("CISCO-WAN-PAR-MIB", "parTrkCnfgDerouteDelay"), ("CISCO-WAN-PAR-MIB", "parTrkCnfgTrafficClassFst"), ("CISCO-WAN-PAR-MIB", "parTrkCnfgTrafficClassFr"), ("CISCO-WAN-PAR-MIB", "parTrkCnfgTrafficClassNts"), ("CISCO-WAN-PAR-MIB", "parTrkCnfgTrafficClassTs"), ("CISCO-WAN-PAR-MIB", "parTrkCnfgTrafficClassVoice"), ("CISCO-WAN-PAR-MIB", "parTrkCnfgTrafficClassCbr"), ("CISCO-WAN-PAR-MIB", "parTrkCnfgTrafficClassVbr"), ("CISCO-WAN-PAR-MIB", "parTrkCnfgTrafficClassAbr"), ("CISCO-WAN-PAR-MIB", "parTrkCnfgAdminStatus"), ("CISCO-WAN-PAR-MIB", "parTrkCnfgRoutingCost"), ("CISCO-WAN-PAR-MIB", "parTrkCnfgVpcConids"), ("CISCO-WAN-PAR-MIB", "parTrkCnfgVccConids"), ("CISCO-WAN-PAR-MIB", "parTrkLocalSlotNumber"), ("CISCO-WAN-PAR-MIB", "parTrkLocalPortNumber"), ("CISCO-WAN-PAR-MIB", "parTrkLocalVTrunkId"), ("CISCO-WAN-PAR-MIB", "parTrkRemoteNodeId"), ("CISCO-WAN-PAR-MIB", "parTrkRemoteTrunkId"), ("CISCO-WAN-PAR-MIB", "parTrkRemoteSlotNumber"), ("CISCO-WAN-PAR-MIB", "parTrkRemotePortNumber"), ("CISCO-WAN-PAR-MIB", "parTrkRemoteVTrunkId"), ("CISCO-WAN-PAR-MIB", "parTrkRemoteNodeIP"), ("CISCO-WAN-PAR-MIB", "parTrkRemoteNodeType"), ("CISCO-WAN-PAR-MIB", "parTrkRemoteNodeName"), ("CISCO-WAN-PAR-MIB", "parTrkAlarmStatus"), ("CISCO-WAN-PAR-MIB", "parTrkAlarmType"), ("CISCO-WAN-PAR-MIB", "parTrkLineLoad"), ("CISCO-WAN-PAR-MIB", "parTrkBwCapacity"))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
cwParTrunkConfGroup = cwParTrunkConfGroup.setStatus('current')
if mibBuilder.loadTexts: cwParTrunkConfGroup.setDescription('The collection of objects which are used for configuring trunks in portable autoroute.')
cwParTrunkLoadConfGroup = ObjectGroup((1, 3, 6, 1, 4, 1, 351, 150, 63, 2, 1, 9)).setObjects(("CISCO-WAN-PAR-MIB", "parTrkLoadXmtUsedCbr"), ("CISCO-WAN-PAR-MIB", "parTrkLoadRcvUsedCbr"), ("CISCO-WAN-PAR-MIB", "parTrkLoadXmtUsedVbr"), ("CISCO-WAN-PAR-MIB", "parTrkLoadRcvUsedVbr"), ("CISCO-WAN-PAR-MIB", "parTrkLoadXmtUsedAbr"), ("CISCO-WAN-PAR-MIB", "parTrkLoadRcvUsedAbr"), ("CISCO-WAN-PAR-MIB", "parTrkLoadXmtUsedNts"), ("CISCO-WAN-PAR-MIB", "parTrkLoadRcvUsedNts"), ("CISCO-WAN-PAR-MIB", "parTrkLoadXmtUsedTs"), ("CISCO-WAN-PAR-MIB", "parTrkLoadRcvUsedTs"), ("CISCO-WAN-PAR-MIB", "parTrkLoadXmtUsedVoice"), ("CISCO-WAN-PAR-MIB", "parTrkLoadRcvUsedVoice"), ("CISCO-WAN-PAR-MIB", "parTrkLoadXmtUsedBdataA"), ("CISCO-WAN-PAR-MIB", "parTrkLoadRcvUsedBdataA"), ("CISCO-WAN-PAR-MIB", "parTrkLoadXmtUsedBdataB"), ("CISCO-WAN-PAR-MIB", "parTrkLoadRcvUsedBdataB"), ("CISCO-WAN-PAR-MIB", "parTrkLoadVccConidsUsed"), ("CISCO-WAN-PAR-MIB", "parTrkLoadVpcConidsUsed"))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
cwParTrunkLoadConfGroup = cwParTrunkLoadConfGroup.setStatus('current')
if mibBuilder.loadTexts: cwParTrunkLoadConfGroup.setDescription('The collection of objects which are used for configuring trunks in portable autoroute.')
cwParConnConfGroup = ObjectGroup((1, 3, 6, 1, 4, 1, 351, 150, 63, 2, 1, 10)).setObjects(("CISCO-WAN-PAR-MIB", "parConnLocalSlot"), ("CISCO-WAN-PAR-MIB", "parConnLocalPort"), ("CISCO-WAN-PAR-MIB", "parConnLocalVpi"), ("CISCO-WAN-PAR-MIB", "parConnLocalVci"), ("CISCO-WAN-PAR-MIB", "parConnMasterShip"), ("CISCO-WAN-PAR-MIB", "parConnLocalVcIndx"), ("CISCO-WAN-PAR-MIB", "parConnLocalEndpt"), ("CISCO-WAN-PAR-MIB", "parConnRemoteNodeName"), ("CISCO-WAN-PAR-MIB", "parConnRemoteSlot"), ("CISCO-WAN-PAR-MIB", "parConnRemotePort"), ("CISCO-WAN-PAR-MIB", "parConnRemoteVpi"), ("CISCO-WAN-PAR-MIB", "parConnRemoteVci"), ("CISCO-WAN-PAR-MIB", "parConnRemoteVcIndx"), ("CISCO-WAN-PAR-MIB", "parConnRemoteEndpt"), ("CISCO-WAN-PAR-MIB", "parConnOperStatus"), ("CISCO-WAN-PAR-MIB", "parConnAdminStatus"), ("CISCO-WAN-PAR-MIB", "parConnRoute"), ("CISCO-WAN-PAR-MIB", "parPrefRoute"), ("CISCO-WAN-PAR-MIB", "parConnFailRsn"), ("CISCO-WAN-PAR-MIB", "parRrtFailRsn"), ("CISCO-WAN-PAR-MIB", "parConnRstrTyp"), ("CISCO-WAN-PAR-MIB", "parConnRstrZcs"), ("CISCO-WAN-PAR-MIB", "parConnCos"))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
cwParConnConfGroup = cwParConnConfGroup.setStatus('current')
if mibBuilder.loadTexts: cwParConnConfGroup.setDescription('The collection of objects which are used for configuring trunks in portable autoroute.')
cwParClockConfGroup = ObjectGroup((1, 3, 6, 1, 4, 1, 351, 150, 63, 2, 1, 11)).setObjects(("CISCO-WAN-PAR-MIB", "parClockIndex"), ("CISCO-WAN-PAR-MIB", "parClockType"), ("CISCO-WAN-PAR-MIB", "parClockCurSource"), ("CISCO-WAN-PAR-MIB", "parClockSource"), ("CISCO-WAN-PAR-MIB", "parClockSourceId"), ("CISCO-WAN-PAR-MIB", "parClockPath"))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
cwParClockConfGroup = cwParClockConfGroup.setStatus('current')
if mibBuilder.loadTexts: cwParClockConfGroup.setDescription('The collection of objects which are used for configuring trunks in portable autoroute.')
mibBuilder.exportSymbols("CISCO-WAN-PAR-MIB", parSwFuncNodeType=parSwFuncNodeType, cwParTrunkConfGroup=cwParTrunkConfGroup, parNetParmTopoMsgSegSz=parNetParmTopoMsgSegSz, parOnOffRenumRec=parOnOffRenumRec, parTrkLineLoad=parTrkLineLoad, parSysParmsMaxCDelay=parSysParmsMaxCDelay, parSwFunc=parSwFunc, parIfLoAddrMin=parIfLoAddrMin, parTrkCnfgTrafficClassCbr=parTrkCnfgTrafficClassCbr, cwParMIBCompliances=cwParMIBCompliances, parTrkAlarmStatus=parTrkAlarmStatus, parTrkLoadRcvUsedBdataB=parTrkLoadRcvUsedBdataB, parTrkCnfgTrafficClassNts=parTrkCnfgTrafficClassNts, parClockTable=parClockTable, parTrkRemoteTrunkId=parTrkRemoteTrunkId, parSysParmsConnFail=parSysParmsConnFail, parPrefRoute=parPrefRoute, parCmParmsMinRrGroupSize=parCmParmsMinRrGroupSize, cwParCompliance=cwParCompliance, parSysParmsMaxCdpVDelay=parSysParmsMaxCdpVDelay, parNetParmNetwWindowSz=parNetParmNetwWindowSz, parTrkAlarmType=parTrkAlarmType, parClockCurSource=parClockCurSource, parCmParmsCostBased=parCmParmsCostBased, parNetParmLowTxRate=parNetParmLowTxRate, parCmParmsRrtPauseTime=parCmParmsRrtPauseTime, parConnRoute=parConnRoute, parIfLoAddrMax=parIfLoAddrMax, parTrkLoadXmtUsedAbr=parTrkLoadXmtUsedAbr, parSysParmsMaxIpcdpCDelay=parSysParmsMaxIpcdpCDelay, parConnRemoteNodeName=parConnRemoteNodeName, parSnNumberOfTrunks=parSnNumberOfTrunks, parConnLocalEndpt=parConnLocalEndpt, parSnRevision=parSnRevision, parConnection=parConnection, parTrkCnfgTrafficClassFst=parTrkCnfgTrafficClassFst, parNetParmHighTxRate=parNetParmHighTxRate, parConnRstrZcs=parConnRstrZcs, parCmParmsDnUpTimer=parCmParmsDnUpTimer, parCmParmMaxViaCons=parCmParmMaxViaCons, cwParConnConfGroup=cwParConnConfGroup, parNetParmCbOffset=parNetParmCbOffset, parNetParmCondInitialStgr=parNetParmCondInitialStgr, parNetParmCfDelay=parNetParmCfDelay, parIfRxBw=parIfRxBw, parTrkLoadRcvUsedVoice=parTrkLoadRcvUsedVoice, PYSNMP_MODULE_ID=ciscoWanParMIB, parNetParmNetwLetWait=parNetParmNetwLetWait, parCmParmsUseCache=parCmParmsUseCache, parTrkLoadRcvUsedCbr=parTrkLoadRcvUsedCbr, parTrkLoadXmtUsedVoice=parTrkLoadXmtUsedVoice, parNetParmCbMaxTimeout=parNetParmCbMaxTimeout, parNetParmBlindMaxTimeout=parNetParmBlindMaxTimeout, parConnMasterShip=parConnMasterShip, parTrkLoadVccConidsUsed=parTrkLoadVccConidsUsed, cwParClockConfGroup=cwParClockConfGroup, parOnOff=parOnOff, parTrkLoadTable=parTrkLoadTable, parOnOffDynamicBwAlloc=parOnOffDynamicBwAlloc, parCmParmsRrtCycleInterval=parCmParmsRrtCycleInterval, parSnNodeIP=parSnNodeIP, parClockSourceId=parClockSourceId, ciscoWanParMIB=ciscoWanParMIB, parSysParmsMaxIpcdpADelay=parSysParmsMaxIpcdpADelay, parTrkCnfgTrafficClassVbr=parTrkCnfgTrafficClassVbr, parMnUpdtNodesPerInt=parMnUpdtNodesPerInt, parTrkStatReserve=parTrkStatReserve, parConnAdminStatus=parConnAdminStatus, parTrkLocalVTrunkId=parTrkLocalVTrunkId, parCmParmsRerouteGroups=parCmParmsRerouteGroups, parSwFuncAbrVsvd=parSwFuncAbrVsvd, parNetworkingParms=parNetworkingParms, parSysParmsMaxCdpADelay=parSysParmsMaxCdpADelay, parClockType=parClockType, parNetParmMsgMaxTimeoutSat=parNetParmMsgMaxTimeoutSat, cwParSysParamsGroup=cwParSysParamsGroup, parConnRemoteVci=parConnRemoteVci, parConnFailRsn=parConnFailRsn, parSysParmsInvLogAlarmThres=parSysParmsInvLogAlarmThres, parSysParmsTsPacketAge=parSysParmsTsPacketAge, parConnLocalPort=parConnLocalPort, parTrkCnfgVccConids=parTrkCnfgVccConids, cwParTrunkLoadConfGroup=cwParTrunkLoadConfGroup, parTrkCnfgDerouteDelay=parTrkCnfgDerouteDelay, parTrkCnfgTrafficClassVoice=parTrkCnfgTrafficClassVoice, parOnOffCmUpdts=parOnOffCmUpdts, parSysParmsDrtDelay=parSysParmsDrtDelay, parSysParmsMaxIpcdpDDelay=parSysParmsMaxIpcdpDDelay, parOnOffBackgroundUpdt=parOnOffBackgroundUpdt, parSysParmsMaxIpcdpVDelay=parSysParmsMaxIpcdpVDelay, parSysParmsDeEnable=parSysParmsDeEnable, cwParMIBConformance=cwParMIBConformance, parCmParmsRrtErrsPerCycle=parCmParmsRrtErrsPerCycle, parSysParmsMaxCdpCDelay=parSysParmsMaxCdpCDelay, parConnLocalSlot=parConnLocalSlot, parTrkLoadXmtUsedBdataB=parTrkLoadXmtUsedBdataB, parIfMaxConn=parIfMaxConn, parNetworkClock=parNetworkClock, parSysParmsMaxDDelay=parSysParmsMaxDDelay, parNetParmCfTestMultiplier=parNetParmCfTestMultiplier, parTrkLocalSlotNumber=parTrkLocalSlotNumber, parTrkLoadRcvUsedBdataA=parTrkLoadRcvUsedBdataA, parTrkLocalPortNumber=parTrkLocalPortNumber, parTrkRemoteNodeName=parTrkRemoteNodeName, parSysParmsMaxIpcdpHsdDelay=parSysParmsMaxIpcdpHsdDelay, parClockEntry=parClockEntry, parCmParmsUseDelay=parCmParmsUseDelay, parConnLocalVpi=parConnLocalVpi, parSysParmsFrStandard=parSysParmsFrStandard, parTrkCnfgCcRestrict=parTrkCnfgCcRestrict, parConnectionEntry=parConnectionEntry, parSysParmsVcPollRate=parSysParmsVcPollRate, parIfHiAddrMax=parIfHiAddrMax, parNetParmMsgTimeout=parNetParmMsgTimeout, parTrkLoadXmtUsedCbr=parTrkLoadXmtUsedCbr, parTrkCnfgVpcConids=parTrkCnfgVpcConids, parConnRemoteVcIndx=parConnRemoteVcIndx, parTrkRemotePortNumber=parTrkRemotePortNumber, parTrkLoadXmtUsedNts=parTrkLoadXmtUsedNts, parSysParmsMaxHsdDelay=parSysParmsMaxHsdDelay, parCmParms=parCmParms, parTrkLoadRcvUsedAbr=parTrkLoadRcvUsedAbr, parSnNodeId=parSnNodeId, parTrkCnfgPassSync=parTrkCnfgPassSync, parTrkCnfgAdminStatus=parTrkCnfgAdminStatus, parMnUpdt=parMnUpdt, parTrkLoadRcvUsedNts=parTrkLoadRcvUsedNts, parConnLocalVcIndx=parConnLocalVcIndx, parConnCos=parConnCos, parOnOffCommFailTest=parOnOffCommFailTest, parOnOffCommBreak=parOnOffCommBreak, cwParInterfaceConfGroup=cwParInterfaceConfGroup, parSnNodeName=parSnNodeName, parOnOffDrtDelay=parOnOffDrtDelay, parTrkLoadXmtUsedVbr=parTrkLoadXmtUsedVbr, cwParCmParamsUpdateGroup=cwParCmParamsUpdateGroup, parCmParmsMaxRrtCycles=parCmParmsMaxRrtCycles, parTrkLoadVpcConidsUsed=parTrkLoadVpcConidsUsed, parConnOperStatus=parConnOperStatus, parTrkRemoteNodeIP=parTrkRemoteNodeIP, parClockPath=parClockPath, parCmParmsRerouteTimer=parCmParmsRerouteTimer, parConnectionTable=parConnectionTable, parTrkTable=parTrkTable, parMnUpdtInterval=parMnUpdtInterval, parIfHiAddrMin=parIfHiAddrMin, parSysParmsMaxCdpDDelay=parSysParmsMaxCdpDDelay, parNetParmCfTestInterval=parNetParmCfTestInterval, parOnOffRouting=parOnOffRouting, cwParNodeGroup=cwParNodeGroup, parCmParmsMaxRoutingBundle=parCmParmsMaxRoutingBundle, parConnRemotePort=parConnRemotePort, parIfLogicalInterface=parIfLogicalInterface, parIfTable=parIfTable, parSysParmsFpdDeJitter=parSysParmsFpdDeJitter, parTrkCnfgTrafficClassFr=parTrkCnfgTrafficClassFr, parSysParms=parSysParms, parIfTxBw=parIfTxBw, parTrkBwCapacity=parTrkBwCapacity, parTrkLoadXmtUsedTs=parTrkLoadXmtUsedTs, parConnRemoteEndpt=parConnRemoteEndpt, parCmParmsRrGroupInc=parCmParmsRrGroupInc, cwParCmParamsGroup=cwParCmParamsGroup, parSelfNode=parSelfNode, parIfOperStatus=parIfOperStatus, cwParNetParamsGroup=cwParNetParamsGroup, parTrkRemoteNodeId=parTrkRemoteNodeId, parMnUpdtBatchSend=parMnUpdtBatchSend, parConnLocalVci=parConnLocalVci, parTrkLoadEntry=parTrkLoadEntry, parVsiConfigParms=parVsiConfigParms, parNetParmCondPerNodeInterval=parNetParmCondPerNodeInterval, parNetParmMsgMaxTimeout=parNetParmMsgMaxTimeout, parInterfaces=parInterfaces, parClockSource=parClockSource, parTrkCnfgLineType=parTrkCnfgLineType, parSysParmsMaxVDelay=parSysParmsMaxVDelay, parTrkRemoteNodeType=parTrkRemoteNodeType, parSnNodeAlarmStatus=parSnNodeAlarmStatus, cwParGeneralGroup=cwParGeneralGroup, parConnRstrTyp=parConnRstrTyp, parTrkRemoteSlotNumber=parTrkRemoteSlotNumber, parTrkCnfgRoutingCost=parTrkCnfgRoutingCost, parIfEntry=parIfEntry, parTrkCnfgTrafficClassTs=parTrkCnfgTrafficClassTs, parIfType=parIfType, parTrkRemoteVTrunkId=parTrkRemoteVTrunkId, parConnRemoteVpi=parConnRemoteVpi, parClockIndex=parClockIndex, parCmParmsDnUpPerPass=parCmParmsDnUpPerPass, parTrkId=parTrkId, parConnRemoteSlot=parConnRemoteSlot, parRrtFailRsn=parRrtFailRsn, parSysParmsMaxCdpHsdDelay=parSysParmsMaxCdpHsdDelay, parSysParmsMaxADelay=parSysParmsMaxADelay, parTrkLoadXmtUsedBdataA=parTrkLoadXmtUsedBdataA, parTrkEntry=parTrkEntry, parTrkLoadRcvUsedVbr=parTrkLoadRcvUsedVbr, cwParMIBGroups=cwParMIBGroups, parNetParmMaxNodeBlks=parNetParmMaxNodeBlks, parTrkCnfgTrafficClassAbr=parTrkCnfgTrafficClassAbr, parNetParmCbDelay=parNetParmCbDelay, parCmParmsMaxUpdates=parCmParmsMaxUpdates, parSysParmsMaxIphsdDelay=parSysParmsMaxIphsdDelay, parTrkLoadRcvUsedTs=parTrkLoadRcvUsedTs, parConfigParms=parConfigParms, parCmParmsResetTimer=parCmParmsResetTimer)
|
class Verbosity:
"""
The Digital DNA utility class to set verbosity.
"""
TEST = 0
MEMORY_ONLY = 1
FILE = 2
FILE_EXTENDED = 3
|
# https://leetcode.com/problems/single-number/
def singleNumber(nums):
count = {}
for x in nums:
if x not in count:
count[x] = 1
else:
count[x] = count[x]+1
for x in count:
if count[x] ==1:
return x
print(singleNumber([4, 1, 2, 1, 2])) |
# AUTOGENERATED BY NBDEV! DO NOT EDIT!
__all__ = ["index", "modules", "custom_doc_links", "git_url"]
index = {"draw_bg": "01_bbox_canvas.ipynb",
"draw_bounding_box": "01_bbox_canvas.ipynb",
"get_image_size": "01_bbox_canvas.ipynb",
"draw_img": "01_bbox_canvas.ipynb",
"points2bbox_coords": "01_bbox_canvas.ipynb",
"BBoxCanvas": "01_bbox_canvas.ipynb",
"draw_bbox": "01a_datasets.ipynb",
"xywh_to_xyxy": "01a_datasets.ipynb",
"xyxy_to_xywh": "01a_datasets.ipynb",
"bbox_intersection": "01a_datasets.ipynb",
"overlap": "01a_datasets.ipynb",
"sample_bbox": "01a_datasets.ipynb",
"draw_rectangle": "01a_datasets.ipynb",
"draw_ellipse": "01a_datasets.ipynb",
"create_simple_object_detection_dataset": "01a_datasets.ipynb",
"create_color_classification": "01a_datasets.ipynb",
"create_shape_color_classification": "01a_datasets.ipynb",
"create_object_detection": "01a_datasets.ipynb",
"get_cifar10": "01a_datasets_download.ipynb",
"get_oxford_102_flowers": "01a_datasets_download.ipynb",
"get_cub_200_2011": "01a_datasets_download.ipynb",
"NaviGUI": "02_navi_widget.ipynb",
"NaviLogic": "02_navi_widget.ipynb",
"Navi": "02_navi_widget.ipynb",
"setup_project_paths": "03_storage.ipynb",
"get_image_list_from_folder": "03_storage.ipynb",
"AnnotationStorage": "03_storage.ipynb",
"AnnotationStorageIterator": "03_storage.ipynb",
"AnnotationDBStorage": "03_storage.ipynb",
"BBoxAnnotatorGUI": "04_bbox_annotator.ipynb",
"BBoxAnnotatorLogic": "04_bbox_annotator.ipynb",
"BBoxAnnotator": "04_bbox_annotator.ipynb",
"ImageButton": "05_image_button.ipynb",
"CaptureGrid": "06_capture_annotator.ipynb",
"CaptureAnnotatorGUI": "06_capture_annotator.ipynb",
"CaptureAnnotatorLogic": "06_capture_annotator.ipynb",
"CaptureAnnotator": "06_capture_annotator.ipynb",
"ImCanvas": "07_im2im_annotator.ipynb",
"Im2ImAnnotatorGUI": "07_im2im_annotator.ipynb",
"text_on_img": "07_im2im_annotator.ipynb",
"flatten": "07_im2im_annotator.ipynb",
"reconstruct_class_images": "07_im2im_annotator.ipynb",
"Im2ImAnnotatorLogic": "07_im2im_annotator.ipynb",
"Im2ImAnnotator": "07_im2im_annotator.ipynb"}
modules = ["bbox_canvas.py",
"datasets/generators.py",
"datasets/download.py",
"navi_widget.py",
"storage.py",
"bbox_annotator.py",
"image_button.py",
"capture_annotator.py",
"im2im_annotator.py"]
doc_url = "//ipyannotator"
git_url = "https://gitlab.palaimon.io/devops/ipyannotator/tree/master/"
def custom_doc_links(name): return None
|
CONFIDENT_ALL_MATCH = 1.0
CONFIDENT_MULTIPLIER_NAME_ONLY = 0.5
CONFIDENT_MULTIPLIER_PARTIAL_MATCH = 0.7
CONFIDENT_MULTIPLIER_OPPOSITE_STREET = 0.75
CONFIDENT_MULTIPLIER_FULL_STREET_MATCH = 1.5
CONFIDENT_REVERSE_MATCH = 0.9
OGCIO_KEY_BLOCK = "Block"
OGCIO_KEY_PHASE = "Phase"
OGCIO_KEY_ESTATE = "Estate"
OGCIO_KEY_VILLAGE = "Village"
OGCIO_KEY_STREET = "Street"
OGCIO_KEY_REGION = "Region"
OGCIO_KEY_BUILDING_NAME = "BuildingName"
SOURCE_OCGIO = "ogcio"
SOURCE_LAND = "land"
SCORE_SCHEME = {
OGCIO_KEY_BUILDING_NAME: 50,
OGCIO_KEY_VILLAGE: 40,
OGCIO_KEY_ESTATE: 40,
OGCIO_KEY_STREET: 40,
OGCIO_KEY_REGION: 20,
OGCIO_KEY_PHASE: 20,
OGCIO_KEY_BLOCK: 20,
}
SCORE_PER_MATCHED_CHAR = 0.1
ELEMENT_PRIORITY = [
OGCIO_KEY_BUILDING_NAME,
OGCIO_KEY_BLOCK,
OGCIO_KEY_PHASE,
OGCIO_KEY_ESTATE,
OGCIO_KEY_VILLAGE,
OGCIO_KEY_STREET,
OGCIO_KEY_REGION,
]
REGION = {
"HK": {"eng": "Hong Kong", "chi": "香港"},
"KLN": {"eng": "Kowloon", "chi": "九龍"},
"NT": {"eng": "New Territories", "chi": "新界"},
}
DC_DISTRICT = {
"invalid": {"eng": "Invalid District Name", "chi": "無效地區"},
"CW": {"eng": "Central and Western District", "chi": "中西區"},
"EST": {"eng": "Eastern District", "chi": "東區"},
"ILD": {"eng": "Islands District", "chi": "離島區"},
"KLC": {"eng": "Kowloon City District", "chi": "九龍城區"},
"KC": {"eng": "Kwai Tsing District", "chi": "葵青區"},
"KT": {"eng": "Kwun Tong District", "chi": "觀塘區"},
"NTH": {"eng": "North District", "chi": "北區"},
"SK": {"eng": "Sai Kung District", "chi": "西貢區"},
"ST": {"eng": "Sha Tin Distric", "chi": "沙田區"},
"SSP": {"eng": "Sham Shui Po District", "chi": "深水埗區"},
"STH": {"eng": "Southern District", "chi": "南區"},
"TP": {"eng": "Tai Po District", "chi": "大埔區"},
"TW": {"eng": "Tsuen Wan District", "chi": "荃灣區"},
"TM": {"eng": "Tuen Mun District", "chi": "屯門區"},
"WC": {"eng": "Wan Chai District", "chi": "灣仔區"},
"WTS": {"eng": "Wong Tai Sin District", "chi": "黃大仙區"},
"YTM": {"eng": "Yau Tsim Mong District", "chi": "油尖旺區"},
"YL": {"eng": "Yuen Long District", "chi": "元朗區"},
}
|
raio = float(input())
pi = 3.14159
area = round(pi * (pow(raio,2)),4)
print("A=%.4f" % area)
|
#!/usr/bin/env python
class CommitMgr(object):
def __init__():
pass
|
login_query = """
mutation {
login(
input: {
username: $username
password: $password
}
) {
user{
username
sessionExpiration
}
errors{
messages
}
mfaUrl
token
}
}
"""
|
print('Analisando emprestimos!!!')
print('=-=' * 20)
valor = float(input('Valor do imovel: R$'))
salario = float(input('Salario do cliente: R$'))
tempo = int(input('Tempo do emprestimo [anos]: '))
print('=-=' * 20)
if valor / (12 * tempo) >= salario * 30/100:
print(f'Seu emprestimo foi \033[31mNEGADO!')
else:
print('Seu emprestimo foi \033[34mAPROVADO!')
|
"""Definition for create_release macro."""
load("//shlib/rules:execute_binary.bzl", "execute_binary")
def create_release(name, workflow_name):
"""Declares an executable target that launches a Github Actions release workflow.
This utility expects Github's CLI (`gh`) to be installed. Running this \
utility launches a Github Actions workflow that creates a release tag, \
generates release notes, creates a release, and creates a PR with an \
updated README.md file.
Args:
name: The name of the executable target as a `string`.
workflow_name: The name of the Github Actions workflow.
"""
arguments = ["--workflow", workflow_name]
execute_binary(
name = name,
arguments = arguments,
binary = "@cgrindel_bazel_starlib//bzlrelease/tools:create_release",
)
|
# Time: O(n)
# Space: O(h)
# Definition for a binary tree node.
class TreeNode(object):
def __init__(self, x):
self.val = x
self.left = None
self.right = None
class Solution(object):
def bstToGst(self, root):
"""
:type root: TreeNode
:rtype: TreeNode
"""
def bstToGstHelper(root, prev):
if not root:
return root
bstToGstHelper(root.right, prev)
root.val += prev[0]
prev[0] = root.val
bstToGstHelper(root.left, prev)
return root
prev = [0]
return bstToGstHelper(root, prev)
|
#python 3.5.2
'''
This Python functions finds the maximum number in a list by compares each
number to every other number on the list.
'''
class MyMath():
def __init__(self, list):
self.list = list
def findMaxNo(self):
max = self.list[0]
for x in self.list:
if x > max:
max = x
return max
print ('Test first element in the list is the largest number: ', MyMath( [12,0,9,3,0] ).findMaxNo() )
print ('Test the largest number is in middle of the list : ', MyMath( [0,0,12,3,0] ).findMaxNo() )
print ('Test last element in the list is largest number: ', MyMath( [12,0,9,3,0] ).findMaxNo() )
'''
OUTPUT:
Test first element in the list is the largest number: 12
Test the largest number is in middle of the list : 12
Test last element in the list is largest number: 12
'''
|
for x in range(1, 11):
if x % 2 == 0:
continue # interrompe prematuramente a iteração indo diretamente para a próxima iteração mas ainda dentro do laço "for"
print(x)
for x in range(1, 11):
if x == 5:
break # para completamente a iteração saindo do laço "for" executando os códigos fora do laço
print(x)
print('Fim!')
|
name, age = "Inshad", 18
username = "MohammedInshad"
print ('Hello!')
print("inshad: {}\n18 {}\nMohammedInshad: {}".format(name, age, username))
|
'''
The MIT License (MIT)
Copyright (c) 2016 WavyCloud
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
'''
def add_facet_to_object(DirectoryArn=None, SchemaFacet=None, ObjectAttributeList=None, ObjectReference=None):
"""
Adds a new Facet to an object.
See also: AWS API Documentation
:example: response = client.add_facet_to_object(
DirectoryArn='string',
SchemaFacet={
'SchemaArn': 'string',
'FacetName': 'string'
},
ObjectAttributeList=[
{
'Key': {
'SchemaArn': 'string',
'FacetName': 'string',
'Name': 'string'
},
'Value': {
'StringValue': 'string',
'BinaryValue': b'bytes',
'BooleanValue': True|False,
'NumberValue': 'string',
'DatetimeValue': datetime(2015, 1, 1)
}
},
],
ObjectReference={
'Selector': 'string'
}
)
:type DirectoryArn: string
:param DirectoryArn: [REQUIRED]
The Amazon Resource Name (ARN) that is associated with the Directory where the object resides. For more information, see arns .
:type SchemaFacet: dict
:param SchemaFacet: [REQUIRED]
Identifiers for the facet that you are adding to the object.
SchemaArn (string) --The ARN of the schema that contains the facet.
FacetName (string) --The name of the facet.
:type ObjectAttributeList: list
:param ObjectAttributeList: Attributes on the facet that you are adding to the object.
(dict) --The combination of an attribute key and an attribute value.
Key (dict) -- [REQUIRED]The key of the attribute.
SchemaArn (string) -- [REQUIRED]The Amazon Resource Name (ARN) of the schema that contains the facet and attribute.
FacetName (string) -- [REQUIRED]The name of the facet that the attribute exists within.
Name (string) -- [REQUIRED]The name of the attribute.
Value (dict) -- [REQUIRED]The value of the attribute.
StringValue (string) --A string data value.
BinaryValue (bytes) --A binary data value.
BooleanValue (boolean) --A Boolean data value.
NumberValue (string) --A number data value.
DatetimeValue (datetime) --A date and time value.
:type ObjectReference: dict
:param ObjectReference: [REQUIRED]
A reference to the object you are adding the specified facet to.
Selector (string) --A path selector supports easy selection of an object by the parent/child links leading to it from the directory root. Use the link names from each parent/child link to construct the path. Path selectors start with a slash (/) and link names are separated by slashes. For more information about paths, see Accessing Objects . You can identify an object in one of the following ways:
$ObjectIdentifier - An object identifier is an opaque string provided by Amazon Cloud Directory. When creating objects, the system will provide you with the identifier of the created object. An object s identifier is immutable and no two objects will ever share the same object identifier
/some/path - Identifies the object based on path
#SomeBatchReference - Identifies the object in a batch call
:rtype: dict
:return: {}
:returns:
(dict) --
"""
pass
def apply_schema(PublishedSchemaArn=None, DirectoryArn=None):
"""
Copies the input published schema into the Directory with the same name and version as that of the published schema .
See also: AWS API Documentation
:example: response = client.apply_schema(
PublishedSchemaArn='string',
DirectoryArn='string'
)
:type PublishedSchemaArn: string
:param PublishedSchemaArn: [REQUIRED]
Published schema Amazon Resource Name (ARN) that needs to be copied. For more information, see arns .
:type DirectoryArn: string
:param DirectoryArn: [REQUIRED]
The Amazon Resource Name (ARN) that is associated with the Directory into which the schema is copied. For more information, see arns .
:rtype: dict
:return: {
'AppliedSchemaArn': 'string',
'DirectoryArn': 'string'
}
"""
pass
def attach_object(DirectoryArn=None, ParentReference=None, ChildReference=None, LinkName=None):
"""
Attaches an existing object to another object. An object can be accessed in two ways:
See also: AWS API Documentation
:example: response = client.attach_object(
DirectoryArn='string',
ParentReference={
'Selector': 'string'
},
ChildReference={
'Selector': 'string'
},
LinkName='string'
)
:type DirectoryArn: string
:param DirectoryArn: [REQUIRED]
Amazon Resource Name (ARN) that is associated with the Directory where both objects reside. For more information, see arns .
:type ParentReference: dict
:param ParentReference: [REQUIRED]
The parent object reference.
Selector (string) --A path selector supports easy selection of an object by the parent/child links leading to it from the directory root. Use the link names from each parent/child link to construct the path. Path selectors start with a slash (/) and link names are separated by slashes. For more information about paths, see Accessing Objects . You can identify an object in one of the following ways:
$ObjectIdentifier - An object identifier is an opaque string provided by Amazon Cloud Directory. When creating objects, the system will provide you with the identifier of the created object. An object s identifier is immutable and no two objects will ever share the same object identifier
/some/path - Identifies the object based on path
#SomeBatchReference - Identifies the object in a batch call
:type ChildReference: dict
:param ChildReference: [REQUIRED]
The child object reference to be attached to the object.
Selector (string) --A path selector supports easy selection of an object by the parent/child links leading to it from the directory root. Use the link names from each parent/child link to construct the path. Path selectors start with a slash (/) and link names are separated by slashes. For more information about paths, see Accessing Objects . You can identify an object in one of the following ways:
$ObjectIdentifier - An object identifier is an opaque string provided by Amazon Cloud Directory. When creating objects, the system will provide you with the identifier of the created object. An object s identifier is immutable and no two objects will ever share the same object identifier
/some/path - Identifies the object based on path
#SomeBatchReference - Identifies the object in a batch call
:type LinkName: string
:param LinkName: [REQUIRED]
The link name with which the child object is attached to the parent.
:rtype: dict
:return: {
'AttachedObjectIdentifier': 'string'
}
:returns:
DirectoryArn (string) -- [REQUIRED]
Amazon Resource Name (ARN) that is associated with the Directory where both objects reside. For more information, see arns .
ParentReference (dict) -- [REQUIRED]
The parent object reference.
Selector (string) --A path selector supports easy selection of an object by the parent/child links leading to it from the directory root. Use the link names from each parent/child link to construct the path. Path selectors start with a slash (/) and link names are separated by slashes. For more information about paths, see Accessing Objects . You can identify an object in one of the following ways:
$ObjectIdentifier - An object identifier is an opaque string provided by Amazon Cloud Directory. When creating objects, the system will provide you with the identifier of the created object. An objects identifier is immutable and no two objects will ever share the same object identifier
/some/path - Identifies the object based on path
#SomeBatchReference - Identifies the object in a batch call
ChildReference (dict) -- [REQUIRED]
The child object reference to be attached to the object.
Selector (string) --A path selector supports easy selection of an object by the parent/child links leading to it from the directory root. Use the link names from each parent/child link to construct the path. Path selectors start with a slash (/) and link names are separated by slashes. For more information about paths, see Accessing Objects . You can identify an object in one of the following ways:
$ObjectIdentifier - An object identifier is an opaque string provided by Amazon Cloud Directory. When creating objects, the system will provide you with the identifier of the created object. An objects identifier is immutable and no two objects will ever share the same object identifier
/some/path - Identifies the object based on path
#SomeBatchReference - Identifies the object in a batch call
LinkName (string) -- [REQUIRED]
The link name with which the child object is attached to the parent.
"""
pass
def attach_policy(DirectoryArn=None, PolicyReference=None, ObjectReference=None):
"""
Attaches a policy object to a regular object. An object can have a limited number of attached policies.
See also: AWS API Documentation
:example: response = client.attach_policy(
DirectoryArn='string',
PolicyReference={
'Selector': 'string'
},
ObjectReference={
'Selector': 'string'
}
)
:type DirectoryArn: string
:param DirectoryArn: The Amazon Resource Name (ARN) that is associated with the Directory where both objects reside. For more information, see arns .
:type PolicyReference: dict
:param PolicyReference: [REQUIRED]
The reference that is associated with the policy object.
Selector (string) --A path selector supports easy selection of an object by the parent/child links leading to it from the directory root. Use the link names from each parent/child link to construct the path. Path selectors start with a slash (/) and link names are separated by slashes. For more information about paths, see Accessing Objects . You can identify an object in one of the following ways:
$ObjectIdentifier - An object identifier is an opaque string provided by Amazon Cloud Directory. When creating objects, the system will provide you with the identifier of the created object. An object s identifier is immutable and no two objects will ever share the same object identifier
/some/path - Identifies the object based on path
#SomeBatchReference - Identifies the object in a batch call
:type ObjectReference: dict
:param ObjectReference: [REQUIRED]
The reference that identifies the object to which the policy will be attached.
Selector (string) --A path selector supports easy selection of an object by the parent/child links leading to it from the directory root. Use the link names from each parent/child link to construct the path. Path selectors start with a slash (/) and link names are separated by slashes. For more information about paths, see Accessing Objects . You can identify an object in one of the following ways:
$ObjectIdentifier - An object identifier is an opaque string provided by Amazon Cloud Directory. When creating objects, the system will provide you with the identifier of the created object. An object s identifier is immutable and no two objects will ever share the same object identifier
/some/path - Identifies the object based on path
#SomeBatchReference - Identifies the object in a batch call
:rtype: dict
:return: {}
:returns:
(dict) --
"""
pass
def attach_to_index(DirectoryArn=None, IndexReference=None, TargetReference=None):
"""
Attaches the specified object to the specified index.
See also: AWS API Documentation
:example: response = client.attach_to_index(
DirectoryArn='string',
IndexReference={
'Selector': 'string'
},
TargetReference={
'Selector': 'string'
}
)
:type DirectoryArn: string
:param DirectoryArn: [REQUIRED]
The Amazon Resource Name (ARN) of the directory where the object and index exist.
:type IndexReference: dict
:param IndexReference: [REQUIRED]
A reference to the index that you are attaching the object to.
Selector (string) --A path selector supports easy selection of an object by the parent/child links leading to it from the directory root. Use the link names from each parent/child link to construct the path. Path selectors start with a slash (/) and link names are separated by slashes. For more information about paths, see Accessing Objects . You can identify an object in one of the following ways:
$ObjectIdentifier - An object identifier is an opaque string provided by Amazon Cloud Directory. When creating objects, the system will provide you with the identifier of the created object. An object s identifier is immutable and no two objects will ever share the same object identifier
/some/path - Identifies the object based on path
#SomeBatchReference - Identifies the object in a batch call
:type TargetReference: dict
:param TargetReference: [REQUIRED]
A reference to the object that you are attaching to the index.
Selector (string) --A path selector supports easy selection of an object by the parent/child links leading to it from the directory root. Use the link names from each parent/child link to construct the path. Path selectors start with a slash (/) and link names are separated by slashes. For more information about paths, see Accessing Objects . You can identify an object in one of the following ways:
$ObjectIdentifier - An object identifier is an opaque string provided by Amazon Cloud Directory. When creating objects, the system will provide you with the identifier of the created object. An object s identifier is immutable and no two objects will ever share the same object identifier
/some/path - Identifies the object based on path
#SomeBatchReference - Identifies the object in a batch call
:rtype: dict
:return: {
'AttachedObjectIdentifier': 'string'
}
"""
pass
def attach_typed_link(DirectoryArn=None, SourceObjectReference=None, TargetObjectReference=None, TypedLinkFacet=None, Attributes=None):
"""
Attaches a typed link to a specified source and target object. For more information, see Typed link .
See also: AWS API Documentation
:example: response = client.attach_typed_link(
DirectoryArn='string',
SourceObjectReference={
'Selector': 'string'
},
TargetObjectReference={
'Selector': 'string'
},
TypedLinkFacet={
'SchemaArn': 'string',
'TypedLinkName': 'string'
},
Attributes=[
{
'AttributeName': 'string',
'Value': {
'StringValue': 'string',
'BinaryValue': b'bytes',
'BooleanValue': True|False,
'NumberValue': 'string',
'DatetimeValue': datetime(2015, 1, 1)
}
},
]
)
:type DirectoryArn: string
:param DirectoryArn: [REQUIRED]
The Amazon Resource Name (ARN) of the directory where you want to attach the typed link.
:type SourceObjectReference: dict
:param SourceObjectReference: [REQUIRED]
Identifies the source object that the typed link will attach to.
Selector (string) --A path selector supports easy selection of an object by the parent/child links leading to it from the directory root. Use the link names from each parent/child link to construct the path. Path selectors start with a slash (/) and link names are separated by slashes. For more information about paths, see Accessing Objects . You can identify an object in one of the following ways:
$ObjectIdentifier - An object identifier is an opaque string provided by Amazon Cloud Directory. When creating objects, the system will provide you with the identifier of the created object. An object s identifier is immutable and no two objects will ever share the same object identifier
/some/path - Identifies the object based on path
#SomeBatchReference - Identifies the object in a batch call
:type TargetObjectReference: dict
:param TargetObjectReference: [REQUIRED]
Identifies the target object that the typed link will attach to.
Selector (string) --A path selector supports easy selection of an object by the parent/child links leading to it from the directory root. Use the link names from each parent/child link to construct the path. Path selectors start with a slash (/) and link names are separated by slashes. For more information about paths, see Accessing Objects . You can identify an object in one of the following ways:
$ObjectIdentifier - An object identifier is an opaque string provided by Amazon Cloud Directory. When creating objects, the system will provide you with the identifier of the created object. An object s identifier is immutable and no two objects will ever share the same object identifier
/some/path - Identifies the object based on path
#SomeBatchReference - Identifies the object in a batch call
:type TypedLinkFacet: dict
:param TypedLinkFacet: [REQUIRED]
Identifies the typed link facet that is associated with the typed link.
SchemaArn (string) -- [REQUIRED]The Amazon Resource Name (ARN) that is associated with the schema. For more information, see arns .
TypedLinkName (string) -- [REQUIRED]The unique name of the typed link facet.
:type Attributes: list
:param Attributes: [REQUIRED]
An ordered set of attributes that are associated with the typed link.
(dict) --Identifies the attribute name and value for a typed link.
AttributeName (string) -- [REQUIRED]The attribute name of the typed link.
Value (dict) -- [REQUIRED]The value for the typed link.
StringValue (string) --A string data value.
BinaryValue (bytes) --A binary data value.
BooleanValue (boolean) --A Boolean data value.
NumberValue (string) --A number data value.
DatetimeValue (datetime) --A date and time value.
:rtype: dict
:return: {
'TypedLinkSpecifier': {
'TypedLinkFacet': {
'SchemaArn': 'string',
'TypedLinkName': 'string'
},
'SourceObjectReference': {
'Selector': 'string'
},
'TargetObjectReference': {
'Selector': 'string'
},
'IdentityAttributeValues': [
{
'AttributeName': 'string',
'Value': {
'StringValue': 'string',
'BinaryValue': b'bytes',
'BooleanValue': True|False,
'NumberValue': 'string',
'DatetimeValue': datetime(2015, 1, 1)
}
},
]
}
}
:returns:
$ObjectIdentifier - An object identifier is an opaque string provided by Amazon Cloud Directory. When creating objects, the system will provide you with the identifier of the created object. An objects identifier is immutable and no two objects will ever share the same object identifier
/some/path - Identifies the object based on path
#SomeBatchReference - Identifies the object in a batch call
"""
pass
def batch_read(DirectoryArn=None, Operations=None, ConsistencyLevel=None):
"""
Performs all the read operations in a batch.
See also: AWS API Documentation
:example: response = client.batch_read(
DirectoryArn='string',
Operations=[
{
'ListObjectAttributes': {
'ObjectReference': {
'Selector': 'string'
},
'NextToken': 'string',
'MaxResults': 123,
'FacetFilter': {
'SchemaArn': 'string',
'FacetName': 'string'
}
},
'ListObjectChildren': {
'ObjectReference': {
'Selector': 'string'
},
'NextToken': 'string',
'MaxResults': 123
}
},
],
ConsistencyLevel='SERIALIZABLE'|'EVENTUAL'
)
:type DirectoryArn: string
:param DirectoryArn: [REQUIRED]
The Amazon Resource Name (ARN) that is associated with the Directory . For more information, see arns .
:type Operations: list
:param Operations: [REQUIRED]
A list of operations that are part of the batch.
(dict) --Represents the output of a BatchRead operation.
ListObjectAttributes (dict) --Lists all attributes that are associated with an object.
ObjectReference (dict) -- [REQUIRED]Reference of the object whose attributes need to be listed.
Selector (string) --A path selector supports easy selection of an object by the parent/child links leading to it from the directory root. Use the link names from each parent/child link to construct the path. Path selectors start with a slash (/) and link names are separated by slashes. For more information about paths, see Accessing Objects . You can identify an object in one of the following ways:
$ObjectIdentifier - An object identifier is an opaque string provided by Amazon Cloud Directory. When creating objects, the system will provide you with the identifier of the created object. An object s identifier is immutable and no two objects will ever share the same object identifier
/some/path - Identifies the object based on path
#SomeBatchReference - Identifies the object in a batch call
NextToken (string) --The pagination token.
MaxResults (integer) --The maximum number of items to be retrieved in a single call. This is an approximate number.
FacetFilter (dict) --Used to filter the list of object attributes that are associated with a certain facet.
SchemaArn (string) --The ARN of the schema that contains the facet.
FacetName (string) --The name of the facet.
ListObjectChildren (dict) --Returns a paginated list of child objects that are associated with a given object.
ObjectReference (dict) -- [REQUIRED]Reference of the object for which child objects are being listed.
Selector (string) --A path selector supports easy selection of an object by the parent/child links leading to it from the directory root. Use the link names from each parent/child link to construct the path. Path selectors start with a slash (/) and link names are separated by slashes. For more information about paths, see Accessing Objects . You can identify an object in one of the following ways:
$ObjectIdentifier - An object identifier is an opaque string provided by Amazon Cloud Directory. When creating objects, the system will provide you with the identifier of the created object. An object s identifier is immutable and no two objects will ever share the same object identifier
/some/path - Identifies the object based on path
#SomeBatchReference - Identifies the object in a batch call
NextToken (string) --The pagination token.
MaxResults (integer) --Maximum number of items to be retrieved in a single call. This is an approximate number.
:type ConsistencyLevel: string
:param ConsistencyLevel: Represents the manner and timing in which the successful write or update of an object is reflected in a subsequent read operation of that same object.
:rtype: dict
:return: {
'Responses': [
{
'SuccessfulResponse': {
'ListObjectAttributes': {
'Attributes': [
{
'Key': {
'SchemaArn': 'string',
'FacetName': 'string',
'Name': 'string'
},
'Value': {
'StringValue': 'string',
'BinaryValue': b'bytes',
'BooleanValue': True|False,
'NumberValue': 'string',
'DatetimeValue': datetime(2015, 1, 1)
}
},
],
'NextToken': 'string'
},
'ListObjectChildren': {
'Children': {
'string': 'string'
},
'NextToken': 'string'
}
},
'ExceptionResponse': {
'Type': 'ValidationException'|'InvalidArnException'|'ResourceNotFoundException'|'InvalidNextTokenException'|'AccessDeniedException'|'NotNodeException',
'Message': 'string'
}
},
]
}
:returns:
(string) --
(string) --
"""
pass
def batch_write(DirectoryArn=None, Operations=None):
"""
Performs all the write operations in a batch. Either all the operations succeed or none. Batch writes supports only object-related operations.
See also: AWS API Documentation
:example: response = client.batch_write(
DirectoryArn='string',
Operations=[
{
'CreateObject': {
'SchemaFacet': [
{
'SchemaArn': 'string',
'FacetName': 'string'
},
],
'ObjectAttributeList': [
{
'Key': {
'SchemaArn': 'string',
'FacetName': 'string',
'Name': 'string'
},
'Value': {
'StringValue': 'string',
'BinaryValue': b'bytes',
'BooleanValue': True|False,
'NumberValue': 'string',
'DatetimeValue': datetime(2015, 1, 1)
}
},
],
'ParentReference': {
'Selector': 'string'
},
'LinkName': 'string',
'BatchReferenceName': 'string'
},
'AttachObject': {
'ParentReference': {
'Selector': 'string'
},
'ChildReference': {
'Selector': 'string'
},
'LinkName': 'string'
},
'DetachObject': {
'ParentReference': {
'Selector': 'string'
},
'LinkName': 'string',
'BatchReferenceName': 'string'
},
'UpdateObjectAttributes': {
'ObjectReference': {
'Selector': 'string'
},
'AttributeUpdates': [
{
'ObjectAttributeKey': {
'SchemaArn': 'string',
'FacetName': 'string',
'Name': 'string'
},
'ObjectAttributeAction': {
'ObjectAttributeActionType': 'CREATE_OR_UPDATE'|'DELETE',
'ObjectAttributeUpdateValue': {
'StringValue': 'string',
'BinaryValue': b'bytes',
'BooleanValue': True|False,
'NumberValue': 'string',
'DatetimeValue': datetime(2015, 1, 1)
}
}
},
]
},
'DeleteObject': {
'ObjectReference': {
'Selector': 'string'
}
},
'AddFacetToObject': {
'SchemaFacet': {
'SchemaArn': 'string',
'FacetName': 'string'
},
'ObjectAttributeList': [
{
'Key': {
'SchemaArn': 'string',
'FacetName': 'string',
'Name': 'string'
},
'Value': {
'StringValue': 'string',
'BinaryValue': b'bytes',
'BooleanValue': True|False,
'NumberValue': 'string',
'DatetimeValue': datetime(2015, 1, 1)
}
},
],
'ObjectReference': {
'Selector': 'string'
}
},
'RemoveFacetFromObject': {
'SchemaFacet': {
'SchemaArn': 'string',
'FacetName': 'string'
},
'ObjectReference': {
'Selector': 'string'
}
}
},
]
)
:type DirectoryArn: string
:param DirectoryArn: [REQUIRED]
The Amazon Resource Name (ARN) that is associated with the Directory . For more information, see arns .
:type Operations: list
:param Operations: [REQUIRED]
A list of operations that are part of the batch.
(dict) --Represents the output of a BatchWrite operation.
CreateObject (dict) --Creates an object.
SchemaFacet (list) -- [REQUIRED]A list of FacetArns that will be associated with the object. For more information, see arns .
(dict) --A facet.
SchemaArn (string) --The ARN of the schema that contains the facet.
FacetName (string) --The name of the facet.
ObjectAttributeList (list) -- [REQUIRED]An attribute map, which contains an attribute ARN as the key and attribute value as the map value.
(dict) --The combination of an attribute key and an attribute value.
Key (dict) -- [REQUIRED]The key of the attribute.
SchemaArn (string) -- [REQUIRED]The Amazon Resource Name (ARN) of the schema that contains the facet and attribute.
FacetName (string) -- [REQUIRED]The name of the facet that the attribute exists within.
Name (string) -- [REQUIRED]The name of the attribute.
Value (dict) -- [REQUIRED]The value of the attribute.
StringValue (string) --A string data value.
BinaryValue (bytes) --A binary data value.
BooleanValue (boolean) --A Boolean data value.
NumberValue (string) --A number data value.
DatetimeValue (datetime) --A date and time value.
ParentReference (dict) -- [REQUIRED]If specified, the parent reference to which this object will be attached.
Selector (string) --A path selector supports easy selection of an object by the parent/child links leading to it from the directory root. Use the link names from each parent/child link to construct the path. Path selectors start with a slash (/) and link names are separated by slashes. For more information about paths, see Accessing Objects . You can identify an object in one of the following ways:
$ObjectIdentifier - An object identifier is an opaque string provided by Amazon Cloud Directory. When creating objects, the system will provide you with the identifier of the created object. An object s identifier is immutable and no two objects will ever share the same object identifier
/some/path - Identifies the object based on path
#SomeBatchReference - Identifies the object in a batch call
LinkName (string) -- [REQUIRED]The name of the link.
BatchReferenceName (string) -- [REQUIRED]The batch reference name. See Batches for more information.
AttachObject (dict) --Attaches an object to a Directory .
ParentReference (dict) -- [REQUIRED]The parent object reference.
Selector (string) --A path selector supports easy selection of an object by the parent/child links leading to it from the directory root. Use the link names from each parent/child link to construct the path. Path selectors start with a slash (/) and link names are separated by slashes. For more information about paths, see Accessing Objects . You can identify an object in one of the following ways:
$ObjectIdentifier - An object identifier is an opaque string provided by Amazon Cloud Directory. When creating objects, the system will provide you with the identifier of the created object. An object s identifier is immutable and no two objects will ever share the same object identifier
/some/path - Identifies the object based on path
#SomeBatchReference - Identifies the object in a batch call
ChildReference (dict) -- [REQUIRED]The child object reference that is to be attached to the object.
Selector (string) --A path selector supports easy selection of an object by the parent/child links leading to it from the directory root. Use the link names from each parent/child link to construct the path. Path selectors start with a slash (/) and link names are separated by slashes. For more information about paths, see Accessing Objects . You can identify an object in one of the following ways:
$ObjectIdentifier - An object identifier is an opaque string provided by Amazon Cloud Directory. When creating objects, the system will provide you with the identifier of the created object. An object s identifier is immutable and no two objects will ever share the same object identifier
/some/path - Identifies the object based on path
#SomeBatchReference - Identifies the object in a batch call
LinkName (string) -- [REQUIRED]The name of the link.
DetachObject (dict) --Detaches an object from a Directory .
ParentReference (dict) -- [REQUIRED]Parent reference from which the object with the specified link name is detached.
Selector (string) --A path selector supports easy selection of an object by the parent/child links leading to it from the directory root. Use the link names from each parent/child link to construct the path. Path selectors start with a slash (/) and link names are separated by slashes. For more information about paths, see Accessing Objects . You can identify an object in one of the following ways:
$ObjectIdentifier - An object identifier is an opaque string provided by Amazon Cloud Directory. When creating objects, the system will provide you with the identifier of the created object. An object s identifier is immutable and no two objects will ever share the same object identifier
/some/path - Identifies the object based on path
#SomeBatchReference - Identifies the object in a batch call
LinkName (string) -- [REQUIRED]The name of the link.
BatchReferenceName (string) -- [REQUIRED]The batch reference name. See Batches for more information.
UpdateObjectAttributes (dict) --Updates a given object's attributes.
ObjectReference (dict) -- [REQUIRED]Reference that identifies the object.
Selector (string) --A path selector supports easy selection of an object by the parent/child links leading to it from the directory root. Use the link names from each parent/child link to construct the path. Path selectors start with a slash (/) and link names are separated by slashes. For more information about paths, see Accessing Objects . You can identify an object in one of the following ways:
$ObjectIdentifier - An object identifier is an opaque string provided by Amazon Cloud Directory. When creating objects, the system will provide you with the identifier of the created object. An object s identifier is immutable and no two objects will ever share the same object identifier
/some/path - Identifies the object based on path
#SomeBatchReference - Identifies the object in a batch call
AttributeUpdates (list) -- [REQUIRED]Attributes update structure.
(dict) --Structure that contains attribute update information.
ObjectAttributeKey (dict) --The key of the attribute being updated.
SchemaArn (string) -- [REQUIRED]The Amazon Resource Name (ARN) of the schema that contains the facet and attribute.
FacetName (string) -- [REQUIRED]The name of the facet that the attribute exists within.
Name (string) -- [REQUIRED]The name of the attribute.
ObjectAttributeAction (dict) --The action to perform as part of the attribute update.
ObjectAttributeActionType (string) --A type that can be either Update or Delete .
ObjectAttributeUpdateValue (dict) --The value that you want to update to.
StringValue (string) --A string data value.
BinaryValue (bytes) --A binary data value.
BooleanValue (boolean) --A Boolean data value.
NumberValue (string) --A number data value.
DatetimeValue (datetime) --A date and time value.
DeleteObject (dict) --Deletes an object in a Directory .
ObjectReference (dict) -- [REQUIRED]The reference that identifies the object.
Selector (string) --A path selector supports easy selection of an object by the parent/child links leading to it from the directory root. Use the link names from each parent/child link to construct the path. Path selectors start with a slash (/) and link names are separated by slashes. For more information about paths, see Accessing Objects . You can identify an object in one of the following ways:
$ObjectIdentifier - An object identifier is an opaque string provided by Amazon Cloud Directory. When creating objects, the system will provide you with the identifier of the created object. An object s identifier is immutable and no two objects will ever share the same object identifier
/some/path - Identifies the object based on path
#SomeBatchReference - Identifies the object in a batch call
AddFacetToObject (dict) --A batch operation that adds a facet to an object.
SchemaFacet (dict) -- [REQUIRED]Represents the facet being added to the object.
SchemaArn (string) --The ARN of the schema that contains the facet.
FacetName (string) --The name of the facet.
ObjectAttributeList (list) -- [REQUIRED]The attributes to set on the object.
(dict) --The combination of an attribute key and an attribute value.
Key (dict) -- [REQUIRED]The key of the attribute.
SchemaArn (string) -- [REQUIRED]The Amazon Resource Name (ARN) of the schema that contains the facet and attribute.
FacetName (string) -- [REQUIRED]The name of the facet that the attribute exists within.
Name (string) -- [REQUIRED]The name of the attribute.
Value (dict) -- [REQUIRED]The value of the attribute.
StringValue (string) --A string data value.
BinaryValue (bytes) --A binary data value.
BooleanValue (boolean) --A Boolean data value.
NumberValue (string) --A number data value.
DatetimeValue (datetime) --A date and time value.
ObjectReference (dict) -- [REQUIRED]A reference to the object being mutated.
Selector (string) --A path selector supports easy selection of an object by the parent/child links leading to it from the directory root. Use the link names from each parent/child link to construct the path. Path selectors start with a slash (/) and link names are separated by slashes. For more information about paths, see Accessing Objects . You can identify an object in one of the following ways:
$ObjectIdentifier - An object identifier is an opaque string provided by Amazon Cloud Directory. When creating objects, the system will provide you with the identifier of the created object. An object s identifier is immutable and no two objects will ever share the same object identifier
/some/path - Identifies the object based on path
#SomeBatchReference - Identifies the object in a batch call
RemoveFacetFromObject (dict) --A batch operation that removes a facet from an object.
SchemaFacet (dict) -- [REQUIRED]The facet to remove from the object.
SchemaArn (string) --The ARN of the schema that contains the facet.
FacetName (string) --The name of the facet.
ObjectReference (dict) -- [REQUIRED]A reference to the object whose facet will be removed.
Selector (string) --A path selector supports easy selection of an object by the parent/child links leading to it from the directory root. Use the link names from each parent/child link to construct the path. Path selectors start with a slash (/) and link names are separated by slashes. For more information about paths, see Accessing Objects . You can identify an object in one of the following ways:
$ObjectIdentifier - An object identifier is an opaque string provided by Amazon Cloud Directory. When creating objects, the system will provide you with the identifier of the created object. An object s identifier is immutable and no two objects will ever share the same object identifier
/some/path - Identifies the object based on path
#SomeBatchReference - Identifies the object in a batch call
:rtype: dict
:return: {
'Responses': [
{
'CreateObject': {
'ObjectIdentifier': 'string'
},
'AttachObject': {
'attachedObjectIdentifier': 'string'
},
'DetachObject': {
'detachedObjectIdentifier': 'string'
},
'UpdateObjectAttributes': {
'ObjectIdentifier': 'string'
},
'DeleteObject': {}
,
'AddFacetToObject': {}
,
'RemoveFacetFromObject': {}
},
]
}
"""
pass
def can_paginate(operation_name=None):
"""
Check if an operation can be paginated.
:type operation_name: string
:param operation_name: The operation name. This is the same name
as the method name on the client. For example, if the
method name is create_foo, and you'd normally invoke the
operation as client.create_foo(**kwargs), if the
create_foo operation can be paginated, you can use the
call client.get_paginator('create_foo').
"""
pass
def create_directory(Name=None, SchemaArn=None):
"""
Creates a Directory by copying the published schema into the directory. A directory cannot be created without a schema.
See also: AWS API Documentation
:example: response = client.create_directory(
Name='string',
SchemaArn='string'
)
:type Name: string
:param Name: [REQUIRED]
The name of the Directory . Should be unique per account, per region.
:type SchemaArn: string
:param SchemaArn: [REQUIRED]
The Amazon Resource Name (ARN) of the published schema that will be copied into the data Directory . For more information, see arns .
:rtype: dict
:return: {
'DirectoryArn': 'string',
'Name': 'string',
'ObjectIdentifier': 'string',
'AppliedSchemaArn': 'string'
}
"""
pass
def create_facet(SchemaArn=None, Name=None, Attributes=None, ObjectType=None):
"""
Creates a new Facet in a schema. Facet creation is allowed only in development or applied schemas.
See also: AWS API Documentation
:example: response = client.create_facet(
SchemaArn='string',
Name='string',
Attributes=[
{
'Name': 'string',
'AttributeDefinition': {
'Type': 'STRING'|'BINARY'|'BOOLEAN'|'NUMBER'|'DATETIME',
'DefaultValue': {
'StringValue': 'string',
'BinaryValue': b'bytes',
'BooleanValue': True|False,
'NumberValue': 'string',
'DatetimeValue': datetime(2015, 1, 1)
},
'IsImmutable': True|False,
'Rules': {
'string': {
'Type': 'BINARY_LENGTH'|'NUMBER_COMPARISON'|'STRING_FROM_SET'|'STRING_LENGTH',
'Parameters': {
'string': 'string'
}
}
}
},
'AttributeReference': {
'TargetFacetName': 'string',
'TargetAttributeName': 'string'
},
'RequiredBehavior': 'REQUIRED_ALWAYS'|'NOT_REQUIRED'
},
],
ObjectType='NODE'|'LEAF_NODE'|'POLICY'|'INDEX'
)
:type SchemaArn: string
:param SchemaArn: [REQUIRED]
The schema ARN in which the new Facet will be created. For more information, see arns .
:type Name: string
:param Name: [REQUIRED]
The name of the Facet , which is unique for a given schema.
:type Attributes: list
:param Attributes: The attributes that are associated with the Facet .
(dict) --An attribute that is associated with the Facet .
Name (string) -- [REQUIRED]The name of the facet attribute.
AttributeDefinition (dict) --A facet attribute consists of either a definition or a reference. This structure contains the attribute definition. See Attribute References for more information.
Type (string) -- [REQUIRED]The type of the attribute.
DefaultValue (dict) --The default value of the attribute (if configured).
StringValue (string) --A string data value.
BinaryValue (bytes) --A binary data value.
BooleanValue (boolean) --A Boolean data value.
NumberValue (string) --A number data value.
DatetimeValue (datetime) --A date and time value.
IsImmutable (boolean) --Whether the attribute is mutable or not.
Rules (dict) --Validation rules attached to the attribute definition.
(string) --
(dict) --Contains an Amazon Resource Name (ARN) and parameters that are associated with the rule.
Type (string) --The type of attribute validation rule.
Parameters (dict) --The minimum and maximum parameters that are associated with the rule.
(string) --
(string) --
AttributeReference (dict) --An attribute reference that is associated with the attribute. See Attribute References for more information.
TargetFacetName (string) -- [REQUIRED]The target facet name that is associated with the facet reference. See Attribute References for more information.
TargetAttributeName (string) -- [REQUIRED]The target attribute name that is associated with the facet reference. See Attribute References for more information.
RequiredBehavior (string) --The required behavior of the FacetAttribute .
:type ObjectType: string
:param ObjectType: [REQUIRED]
Specifies whether a given object created from this facet is of type node, leaf node, policy or index.
Node: Can have multiple children but one parent.
Leaf node: Cannot have children but can have multiple parents.
Policy: Allows you to store a policy document and policy type. For more information, see Policies .
Index: Can be created with the Index API.
:rtype: dict
:return: {}
:returns:
(dict) --
"""
pass
def create_index(DirectoryArn=None, OrderedIndexedAttributeList=None, IsUnique=None, ParentReference=None, LinkName=None):
"""
Creates an index object. See Indexing for more information.
See also: AWS API Documentation
:example: response = client.create_index(
DirectoryArn='string',
OrderedIndexedAttributeList=[
{
'SchemaArn': 'string',
'FacetName': 'string',
'Name': 'string'
},
],
IsUnique=True|False,
ParentReference={
'Selector': 'string'
},
LinkName='string'
)
:type DirectoryArn: string
:param DirectoryArn: [REQUIRED]
The ARN of the directory where the index should be created.
:type OrderedIndexedAttributeList: list
:param OrderedIndexedAttributeList: [REQUIRED]
Specifies the attributes that should be indexed on. Currently only a single attribute is supported.
(dict) --A unique identifier for an attribute.
SchemaArn (string) -- [REQUIRED]The Amazon Resource Name (ARN) of the schema that contains the facet and attribute.
FacetName (string) -- [REQUIRED]The name of the facet that the attribute exists within.
Name (string) -- [REQUIRED]The name of the attribute.
:type IsUnique: boolean
:param IsUnique: [REQUIRED]
Indicates whether the attribute that is being indexed has unique values or not.
:type ParentReference: dict
:param ParentReference: A reference to the parent object that contains the index object.
Selector (string) --A path selector supports easy selection of an object by the parent/child links leading to it from the directory root. Use the link names from each parent/child link to construct the path. Path selectors start with a slash (/) and link names are separated by slashes. For more information about paths, see Accessing Objects . You can identify an object in one of the following ways:
$ObjectIdentifier - An object identifier is an opaque string provided by Amazon Cloud Directory. When creating objects, the system will provide you with the identifier of the created object. An object s identifier is immutable and no two objects will ever share the same object identifier
/some/path - Identifies the object based on path
#SomeBatchReference - Identifies the object in a batch call
:type LinkName: string
:param LinkName: The name of the link between the parent object and the index object.
:rtype: dict
:return: {
'ObjectIdentifier': 'string'
}
"""
pass
def create_object(DirectoryArn=None, SchemaFacets=None, ObjectAttributeList=None, ParentReference=None, LinkName=None):
"""
Creates an object in a Directory . Additionally attaches the object to a parent, if a parent reference and LinkName is specified. An object is simply a collection of Facet attributes. You can also use this API call to create a policy object, if the facet from which you create the object is a policy facet.
See also: AWS API Documentation
:example: response = client.create_object(
DirectoryArn='string',
SchemaFacets=[
{
'SchemaArn': 'string',
'FacetName': 'string'
},
],
ObjectAttributeList=[
{
'Key': {
'SchemaArn': 'string',
'FacetName': 'string',
'Name': 'string'
},
'Value': {
'StringValue': 'string',
'BinaryValue': b'bytes',
'BooleanValue': True|False,
'NumberValue': 'string',
'DatetimeValue': datetime(2015, 1, 1)
}
},
],
ParentReference={
'Selector': 'string'
},
LinkName='string'
)
:type DirectoryArn: string
:param DirectoryArn: [REQUIRED]
The Amazon Resource Name (ARN) that is associated with the Directory in which the object will be created. For more information, see arns .
:type SchemaFacets: list
:param SchemaFacets: [REQUIRED]
A list of schema facets to be associated with the object that contains SchemaArn and facet name. For more information, see arns .
(dict) --A facet.
SchemaArn (string) --The ARN of the schema that contains the facet.
FacetName (string) --The name of the facet.
:type ObjectAttributeList: list
:param ObjectAttributeList: The attribute map whose attribute ARN contains the key and attribute value as the map value.
(dict) --The combination of an attribute key and an attribute value.
Key (dict) -- [REQUIRED]The key of the attribute.
SchemaArn (string) -- [REQUIRED]The Amazon Resource Name (ARN) of the schema that contains the facet and attribute.
FacetName (string) -- [REQUIRED]The name of the facet that the attribute exists within.
Name (string) -- [REQUIRED]The name of the attribute.
Value (dict) -- [REQUIRED]The value of the attribute.
StringValue (string) --A string data value.
BinaryValue (bytes) --A binary data value.
BooleanValue (boolean) --A Boolean data value.
NumberValue (string) --A number data value.
DatetimeValue (datetime) --A date and time value.
:type ParentReference: dict
:param ParentReference: If specified, the parent reference to which this object will be attached.
Selector (string) --A path selector supports easy selection of an object by the parent/child links leading to it from the directory root. Use the link names from each parent/child link to construct the path. Path selectors start with a slash (/) and link names are separated by slashes. For more information about paths, see Accessing Objects . You can identify an object in one of the following ways:
$ObjectIdentifier - An object identifier is an opaque string provided by Amazon Cloud Directory. When creating objects, the system will provide you with the identifier of the created object. An object s identifier is immutable and no two objects will ever share the same object identifier
/some/path - Identifies the object based on path
#SomeBatchReference - Identifies the object in a batch call
:type LinkName: string
:param LinkName: The name of link that is used to attach this object to a parent.
:rtype: dict
:return: {
'ObjectIdentifier': 'string'
}
"""
pass
def create_schema(Name=None):
"""
Creates a new schema in a development state. A schema can exist in three phases:
See also: AWS API Documentation
:example: response = client.create_schema(
Name='string'
)
:type Name: string
:param Name: [REQUIRED]
The name that is associated with the schema. This is unique to each account and in each region.
:rtype: dict
:return: {
'SchemaArn': 'string'
}
"""
pass
def create_typed_link_facet(SchemaArn=None, Facet=None):
"""
Creates a TypedLinkFacet . For more information, see Typed link .
See also: AWS API Documentation
:example: response = client.create_typed_link_facet(
SchemaArn='string',
Facet={
'Name': 'string',
'Attributes': [
{
'Name': 'string',
'Type': 'STRING'|'BINARY'|'BOOLEAN'|'NUMBER'|'DATETIME',
'DefaultValue': {
'StringValue': 'string',
'BinaryValue': b'bytes',
'BooleanValue': True|False,
'NumberValue': 'string',
'DatetimeValue': datetime(2015, 1, 1)
},
'IsImmutable': True|False,
'Rules': {
'string': {
'Type': 'BINARY_LENGTH'|'NUMBER_COMPARISON'|'STRING_FROM_SET'|'STRING_LENGTH',
'Parameters': {
'string': 'string'
}
}
},
'RequiredBehavior': 'REQUIRED_ALWAYS'|'NOT_REQUIRED'
},
],
'IdentityAttributeOrder': [
'string',
]
}
)
:type SchemaArn: string
:param SchemaArn: [REQUIRED]
The Amazon Resource Name (ARN) that is associated with the schema. For more information, see arns .
:type Facet: dict
:param Facet: [REQUIRED]
Facet structure that is associated with the typed link facet.
Name (string) -- [REQUIRED]The unique name of the typed link facet.
Attributes (list) -- [REQUIRED]An ordered set of attributes that are associate with the typed link. You can use typed link attributes when you need to represent the relationship between two objects or allow for quick filtering of incoming or outgoing typed links.
(dict) --A typed link attribute definition.
Name (string) -- [REQUIRED]The unique name of the typed link attribute.
Type (string) -- [REQUIRED]The type of the attribute.
DefaultValue (dict) --The default value of the attribute (if configured).
StringValue (string) --A string data value.
BinaryValue (bytes) --A binary data value.
BooleanValue (boolean) --A Boolean data value.
NumberValue (string) --A number data value.
DatetimeValue (datetime) --A date and time value.
IsImmutable (boolean) --Whether the attribute is mutable or not.
Rules (dict) --Validation rules that are attached to the attribute definition.
(string) --
(dict) --Contains an Amazon Resource Name (ARN) and parameters that are associated with the rule.
Type (string) --The type of attribute validation rule.
Parameters (dict) --The minimum and maximum parameters that are associated with the rule.
(string) --
(string) --
RequiredBehavior (string) -- [REQUIRED]The required behavior of the TypedLinkAttributeDefinition .
IdentityAttributeOrder (list) -- [REQUIRED]A range filter that you provide for multiple attributes. The ability to filter typed links considers the order that the attributes are defined on the typed link facet. When providing ranges to typed link selection, any inexact ranges must be specified at the end. Any attributes that do not have a range specified are presumed to match the entire range. Filters are interpreted in the order of the attributes on the typed link facet, not the order in which they are supplied to any API calls.
(string) --
:rtype: dict
:return: {}
:returns:
(dict) --
"""
pass
def delete_directory(DirectoryArn=None):
"""
Deletes a directory. Only disabled directories can be deleted. A deleted directory cannot be undone. Exercise extreme caution when deleting directories.
See also: AWS API Documentation
:example: response = client.delete_directory(
DirectoryArn='string'
)
:type DirectoryArn: string
:param DirectoryArn: [REQUIRED]
The ARN of the directory to delete.
:rtype: dict
:return: {
'DirectoryArn': 'string'
}
"""
pass
def delete_facet(SchemaArn=None, Name=None):
"""
Deletes a given Facet . All attributes and Rule s that are associated with the facet will be deleted. Only development schema facets are allowed deletion.
See also: AWS API Documentation
:example: response = client.delete_facet(
SchemaArn='string',
Name='string'
)
:type SchemaArn: string
:param SchemaArn: [REQUIRED]
The Amazon Resource Name (ARN) that is associated with the Facet . For more information, see arns .
:type Name: string
:param Name: [REQUIRED]
The name of the facet to delete.
:rtype: dict
:return: {}
:returns:
(dict) --
"""
pass
def delete_object(DirectoryArn=None, ObjectReference=None):
"""
Deletes an object and its associated attributes. Only objects with no children and no parents can be deleted.
See also: AWS API Documentation
:example: response = client.delete_object(
DirectoryArn='string',
ObjectReference={
'Selector': 'string'
}
)
:type DirectoryArn: string
:param DirectoryArn: [REQUIRED]
The Amazon Resource Name (ARN) that is associated with the Directory where the object resides. For more information, see arns .
:type ObjectReference: dict
:param ObjectReference: [REQUIRED]
A reference that identifies the object.
Selector (string) --A path selector supports easy selection of an object by the parent/child links leading to it from the directory root. Use the link names from each parent/child link to construct the path. Path selectors start with a slash (/) and link names are separated by slashes. For more information about paths, see Accessing Objects . You can identify an object in one of the following ways:
$ObjectIdentifier - An object identifier is an opaque string provided by Amazon Cloud Directory. When creating objects, the system will provide you with the identifier of the created object. An object s identifier is immutable and no two objects will ever share the same object identifier
/some/path - Identifies the object based on path
#SomeBatchReference - Identifies the object in a batch call
:rtype: dict
:return: {}
:returns:
(dict) --
"""
pass
def delete_schema(SchemaArn=None):
"""
Deletes a given schema. Schemas in a development and published state can only be deleted.
See also: AWS API Documentation
:example: response = client.delete_schema(
SchemaArn='string'
)
:type SchemaArn: string
:param SchemaArn: [REQUIRED]
The Amazon Resource Name (ARN) of the development schema. For more information, see arns .
:rtype: dict
:return: {
'SchemaArn': 'string'
}
"""
pass
def delete_typed_link_facet(SchemaArn=None, Name=None):
"""
Deletes a TypedLinkFacet . For more information, see Typed link .
See also: AWS API Documentation
:example: response = client.delete_typed_link_facet(
SchemaArn='string',
Name='string'
)
:type SchemaArn: string
:param SchemaArn: [REQUIRED]
The Amazon Resource Name (ARN) that is associated with the schema. For more information, see arns .
:type Name: string
:param Name: [REQUIRED]
The unique name of the typed link facet.
:rtype: dict
:return: {}
:returns:
(dict) --
"""
pass
def detach_from_index(DirectoryArn=None, IndexReference=None, TargetReference=None):
"""
Detaches the specified object from the specified index.
See also: AWS API Documentation
:example: response = client.detach_from_index(
DirectoryArn='string',
IndexReference={
'Selector': 'string'
},
TargetReference={
'Selector': 'string'
}
)
:type DirectoryArn: string
:param DirectoryArn: [REQUIRED]
The Amazon Resource Name (ARN) of the directory the index and object exist in.
:type IndexReference: dict
:param IndexReference: [REQUIRED]
A reference to the index object.
Selector (string) --A path selector supports easy selection of an object by the parent/child links leading to it from the directory root. Use the link names from each parent/child link to construct the path. Path selectors start with a slash (/) and link names are separated by slashes. For more information about paths, see Accessing Objects . You can identify an object in one of the following ways:
$ObjectIdentifier - An object identifier is an opaque string provided by Amazon Cloud Directory. When creating objects, the system will provide you with the identifier of the created object. An object s identifier is immutable and no two objects will ever share the same object identifier
/some/path - Identifies the object based on path
#SomeBatchReference - Identifies the object in a batch call
:type TargetReference: dict
:param TargetReference: [REQUIRED]
A reference to the object being detached from the index.
Selector (string) --A path selector supports easy selection of an object by the parent/child links leading to it from the directory root. Use the link names from each parent/child link to construct the path. Path selectors start with a slash (/) and link names are separated by slashes. For more information about paths, see Accessing Objects . You can identify an object in one of the following ways:
$ObjectIdentifier - An object identifier is an opaque string provided by Amazon Cloud Directory. When creating objects, the system will provide you with the identifier of the created object. An object s identifier is immutable and no two objects will ever share the same object identifier
/some/path - Identifies the object based on path
#SomeBatchReference - Identifies the object in a batch call
:rtype: dict
:return: {
'DetachedObjectIdentifier': 'string'
}
"""
pass
def detach_object(DirectoryArn=None, ParentReference=None, LinkName=None):
"""
Detaches a given object from the parent object. The object that is to be detached from the parent is specified by the link name.
See also: AWS API Documentation
:example: response = client.detach_object(
DirectoryArn='string',
ParentReference={
'Selector': 'string'
},
LinkName='string'
)
:type DirectoryArn: string
:param DirectoryArn: [REQUIRED]
The Amazon Resource Name (ARN) that is associated with the Directory where objects reside. For more information, see arns .
:type ParentReference: dict
:param ParentReference: [REQUIRED]
The parent reference from which the object with the specified link name is detached.
Selector (string) --A path selector supports easy selection of an object by the parent/child links leading to it from the directory root. Use the link names from each parent/child link to construct the path. Path selectors start with a slash (/) and link names are separated by slashes. For more information about paths, see Accessing Objects . You can identify an object in one of the following ways:
$ObjectIdentifier - An object identifier is an opaque string provided by Amazon Cloud Directory. When creating objects, the system will provide you with the identifier of the created object. An object s identifier is immutable and no two objects will ever share the same object identifier
/some/path - Identifies the object based on path
#SomeBatchReference - Identifies the object in a batch call
:type LinkName: string
:param LinkName: [REQUIRED]
The link name associated with the object that needs to be detached.
:rtype: dict
:return: {
'DetachedObjectIdentifier': 'string'
}
"""
pass
def detach_policy(DirectoryArn=None, PolicyReference=None, ObjectReference=None):
"""
Detaches a policy from an object.
See also: AWS API Documentation
:example: response = client.detach_policy(
DirectoryArn='string',
PolicyReference={
'Selector': 'string'
},
ObjectReference={
'Selector': 'string'
}
)
:type DirectoryArn: string
:param DirectoryArn: [REQUIRED]
The Amazon Resource Name (ARN) that is associated with the Directory where both objects reside. For more information, see arns .
:type PolicyReference: dict
:param PolicyReference: [REQUIRED]
Reference that identifies the policy object.
Selector (string) --A path selector supports easy selection of an object by the parent/child links leading to it from the directory root. Use the link names from each parent/child link to construct the path. Path selectors start with a slash (/) and link names are separated by slashes. For more information about paths, see Accessing Objects . You can identify an object in one of the following ways:
$ObjectIdentifier - An object identifier is an opaque string provided by Amazon Cloud Directory. When creating objects, the system will provide you with the identifier of the created object. An object s identifier is immutable and no two objects will ever share the same object identifier
/some/path - Identifies the object based on path
#SomeBatchReference - Identifies the object in a batch call
:type ObjectReference: dict
:param ObjectReference: [REQUIRED]
Reference that identifies the object whose policy object will be detached.
Selector (string) --A path selector supports easy selection of an object by the parent/child links leading to it from the directory root. Use the link names from each parent/child link to construct the path. Path selectors start with a slash (/) and link names are separated by slashes. For more information about paths, see Accessing Objects . You can identify an object in one of the following ways:
$ObjectIdentifier - An object identifier is an opaque string provided by Amazon Cloud Directory. When creating objects, the system will provide you with the identifier of the created object. An object s identifier is immutable and no two objects will ever share the same object identifier
/some/path - Identifies the object based on path
#SomeBatchReference - Identifies the object in a batch call
:rtype: dict
:return: {}
:returns:
(dict) --
"""
pass
def detach_typed_link(DirectoryArn=None, TypedLinkSpecifier=None):
"""
Detaches a typed link from a specified source and target object. For more information, see Typed link .
See also: AWS API Documentation
:example: response = client.detach_typed_link(
DirectoryArn='string',
TypedLinkSpecifier={
'TypedLinkFacet': {
'SchemaArn': 'string',
'TypedLinkName': 'string'
},
'SourceObjectReference': {
'Selector': 'string'
},
'TargetObjectReference': {
'Selector': 'string'
},
'IdentityAttributeValues': [
{
'AttributeName': 'string',
'Value': {
'StringValue': 'string',
'BinaryValue': b'bytes',
'BooleanValue': True|False,
'NumberValue': 'string',
'DatetimeValue': datetime(2015, 1, 1)
}
},
]
}
)
:type DirectoryArn: string
:param DirectoryArn: [REQUIRED]
The Amazon Resource Name (ARN) of the directory where you want to detach the typed link.
:type TypedLinkSpecifier: dict
:param TypedLinkSpecifier: [REQUIRED]
Used to accept a typed link specifier as input.
TypedLinkFacet (dict) -- [REQUIRED]Identifies the typed link facet that is associated with the typed link.
SchemaArn (string) -- [REQUIRED]The Amazon Resource Name (ARN) that is associated with the schema. For more information, see arns .
TypedLinkName (string) -- [REQUIRED]The unique name of the typed link facet.
SourceObjectReference (dict) -- [REQUIRED]Identifies the source object that the typed link will attach to.
Selector (string) --A path selector supports easy selection of an object by the parent/child links leading to it from the directory root. Use the link names from each parent/child link to construct the path. Path selectors start with a slash (/) and link names are separated by slashes. For more information about paths, see Accessing Objects . You can identify an object in one of the following ways:
$ObjectIdentifier - An object identifier is an opaque string provided by Amazon Cloud Directory. When creating objects, the system will provide you with the identifier of the created object. An object s identifier is immutable and no two objects will ever share the same object identifier
/some/path - Identifies the object based on path
#SomeBatchReference - Identifies the object in a batch call
TargetObjectReference (dict) -- [REQUIRED]Identifies the target object that the typed link will attach to.
Selector (string) --A path selector supports easy selection of an object by the parent/child links leading to it from the directory root. Use the link names from each parent/child link to construct the path. Path selectors start with a slash (/) and link names are separated by slashes. For more information about paths, see Accessing Objects . You can identify an object in one of the following ways:
$ObjectIdentifier - An object identifier is an opaque string provided by Amazon Cloud Directory. When creating objects, the system will provide you with the identifier of the created object. An object s identifier is immutable and no two objects will ever share the same object identifier
/some/path - Identifies the object based on path
#SomeBatchReference - Identifies the object in a batch call
IdentityAttributeValues (list) -- [REQUIRED]Identifies the attribute value to update.
(dict) --Identifies the attribute name and value for a typed link.
AttributeName (string) -- [REQUIRED]The attribute name of the typed link.
Value (dict) -- [REQUIRED]The value for the typed link.
StringValue (string) --A string data value.
BinaryValue (bytes) --A binary data value.
BooleanValue (boolean) --A Boolean data value.
NumberValue (string) --A number data value.
DatetimeValue (datetime) --A date and time value.
"""
pass
def disable_directory(DirectoryArn=None):
"""
Disables the specified directory. Disabled directories cannot be read or written to. Only enabled directories can be disabled. Disabled directories may be reenabled.
See also: AWS API Documentation
:example: response = client.disable_directory(
DirectoryArn='string'
)
:type DirectoryArn: string
:param DirectoryArn: [REQUIRED]
The ARN of the directory to disable.
:rtype: dict
:return: {
'DirectoryArn': 'string'
}
"""
pass
def enable_directory(DirectoryArn=None):
"""
Enables the specified directory. Only disabled directories can be enabled. Once enabled, the directory can then be read and written to.
See also: AWS API Documentation
:example: response = client.enable_directory(
DirectoryArn='string'
)
:type DirectoryArn: string
:param DirectoryArn: [REQUIRED]
The ARN of the directory to enable.
:rtype: dict
:return: {
'DirectoryArn': 'string'
}
"""
pass
def generate_presigned_url(ClientMethod=None, Params=None, ExpiresIn=None, HttpMethod=None):
"""
Generate a presigned url given a client, its method, and arguments
:type ClientMethod: string
:param ClientMethod: The client method to presign for
:type Params: dict
:param Params: The parameters normally passed to
ClientMethod.
:type ExpiresIn: int
:param ExpiresIn: The number of seconds the presigned url is valid
for. By default it expires in an hour (3600 seconds)
:type HttpMethod: string
:param HttpMethod: The http method to use on the generated url. By
default, the http method is whatever is used in the method's model.
"""
pass
def get_directory(DirectoryArn=None):
"""
Retrieves metadata about a directory.
See also: AWS API Documentation
:example: response = client.get_directory(
DirectoryArn='string'
)
:type DirectoryArn: string
:param DirectoryArn: [REQUIRED]
The ARN of the directory.
:rtype: dict
:return: {
'Directory': {
'Name': 'string',
'DirectoryArn': 'string',
'State': 'ENABLED'|'DISABLED'|'DELETED',
'CreationDateTime': datetime(2015, 1, 1)
}
}
"""
pass
def get_facet(SchemaArn=None, Name=None):
"""
Gets details of the Facet , such as facet name, attributes, Rule s, or ObjectType . You can call this on all kinds of schema facets -- published, development, or applied.
See also: AWS API Documentation
:example: response = client.get_facet(
SchemaArn='string',
Name='string'
)
:type SchemaArn: string
:param SchemaArn: [REQUIRED]
The Amazon Resource Name (ARN) that is associated with the Facet . For more information, see arns .
:type Name: string
:param Name: [REQUIRED]
The name of the facet to retrieve.
:rtype: dict
:return: {
'Facet': {
'Name': 'string',
'ObjectType': 'NODE'|'LEAF_NODE'|'POLICY'|'INDEX'
}
}
"""
pass
def get_object_information(DirectoryArn=None, ObjectReference=None, ConsistencyLevel=None):
"""
Retrieves metadata about an object.
See also: AWS API Documentation
:example: response = client.get_object_information(
DirectoryArn='string',
ObjectReference={
'Selector': 'string'
},
ConsistencyLevel='SERIALIZABLE'|'EVENTUAL'
)
:type DirectoryArn: string
:param DirectoryArn: [REQUIRED]
The ARN of the directory being retrieved.
:type ObjectReference: dict
:param ObjectReference: [REQUIRED]
A reference to the object.
Selector (string) --A path selector supports easy selection of an object by the parent/child links leading to it from the directory root. Use the link names from each parent/child link to construct the path. Path selectors start with a slash (/) and link names are separated by slashes. For more information about paths, see Accessing Objects . You can identify an object in one of the following ways:
$ObjectIdentifier - An object identifier is an opaque string provided by Amazon Cloud Directory. When creating objects, the system will provide you with the identifier of the created object. An object s identifier is immutable and no two objects will ever share the same object identifier
/some/path - Identifies the object based on path
#SomeBatchReference - Identifies the object in a batch call
:type ConsistencyLevel: string
:param ConsistencyLevel: The consistency level at which to retrieve the object information.
:rtype: dict
:return: {
'SchemaFacets': [
{
'SchemaArn': 'string',
'FacetName': 'string'
},
],
'ObjectIdentifier': 'string'
}
"""
pass
def get_paginator(operation_name=None):
"""
Create a paginator for an operation.
:type operation_name: string
:param operation_name: The operation name. This is the same name
as the method name on the client. For example, if the
method name is create_foo, and you'd normally invoke the
operation as client.create_foo(**kwargs), if the
create_foo operation can be paginated, you can use the
call client.get_paginator('create_foo').
:rtype: L{botocore.paginate.Paginator}
"""
pass
def get_schema_as_json(SchemaArn=None):
"""
Retrieves a JSON representation of the schema. See JSON Schema Format for more information.
See also: AWS API Documentation
:example: response = client.get_schema_as_json(
SchemaArn='string'
)
:type SchemaArn: string
:param SchemaArn: [REQUIRED]
The ARN of the schema to retrieve.
:rtype: dict
:return: {
'Name': 'string',
'Document': 'string'
}
"""
pass
def get_typed_link_facet_information(SchemaArn=None, Name=None):
"""
Returns the identity attribute order for a specific TypedLinkFacet . For more information, see Typed link .
See also: AWS API Documentation
:example: response = client.get_typed_link_facet_information(
SchemaArn='string',
Name='string'
)
:type SchemaArn: string
:param SchemaArn: [REQUIRED]
The Amazon Resource Name (ARN) that is associated with the schema. For more information, see arns .
:type Name: string
:param Name: [REQUIRED]
The unique name of the typed link facet.
:rtype: dict
:return: {
'IdentityAttributeOrder': [
'string',
]
}
:returns:
(string) --
"""
pass
def get_waiter():
"""
"""
pass
def list_applied_schema_arns(DirectoryArn=None, NextToken=None, MaxResults=None):
"""
Lists schemas applied to a directory.
See also: AWS API Documentation
:example: response = client.list_applied_schema_arns(
DirectoryArn='string',
NextToken='string',
MaxResults=123
)
:type DirectoryArn: string
:param DirectoryArn: [REQUIRED]
The ARN of the directory you are listing.
:type NextToken: string
:param NextToken: The pagination token.
:type MaxResults: integer
:param MaxResults: The maximum number of results to retrieve.
:rtype: dict
:return: {
'SchemaArns': [
'string',
],
'NextToken': 'string'
}
:returns:
(string) --
"""
pass
def list_attached_indices(DirectoryArn=None, TargetReference=None, NextToken=None, MaxResults=None, ConsistencyLevel=None):
"""
Lists indices attached to an object.
See also: AWS API Documentation
:example: response = client.list_attached_indices(
DirectoryArn='string',
TargetReference={
'Selector': 'string'
},
NextToken='string',
MaxResults=123,
ConsistencyLevel='SERIALIZABLE'|'EVENTUAL'
)
:type DirectoryArn: string
:param DirectoryArn: [REQUIRED]
The ARN of the directory.
:type TargetReference: dict
:param TargetReference: [REQUIRED]
A reference to the object to that has indices attached.
Selector (string) --A path selector supports easy selection of an object by the parent/child links leading to it from the directory root. Use the link names from each parent/child link to construct the path. Path selectors start with a slash (/) and link names are separated by slashes. For more information about paths, see Accessing Objects . You can identify an object in one of the following ways:
$ObjectIdentifier - An object identifier is an opaque string provided by Amazon Cloud Directory. When creating objects, the system will provide you with the identifier of the created object. An object s identifier is immutable and no two objects will ever share the same object identifier
/some/path - Identifies the object based on path
#SomeBatchReference - Identifies the object in a batch call
:type NextToken: string
:param NextToken: The pagination token.
:type MaxResults: integer
:param MaxResults: The maximum number of results to retrieve.
:type ConsistencyLevel: string
:param ConsistencyLevel: The consistency level to use for this operation.
:rtype: dict
:return: {
'IndexAttachments': [
{
'IndexedAttributes': [
{
'Key': {
'SchemaArn': 'string',
'FacetName': 'string',
'Name': 'string'
},
'Value': {
'StringValue': 'string',
'BinaryValue': b'bytes',
'BooleanValue': True|False,
'NumberValue': 'string',
'DatetimeValue': datetime(2015, 1, 1)
}
},
],
'ObjectIdentifier': 'string'
},
],
'NextToken': 'string'
}
"""
pass
def list_development_schema_arns(NextToken=None, MaxResults=None):
"""
Retrieves each Amazon Resource Name (ARN) of schemas in the development state.
See also: AWS API Documentation
:example: response = client.list_development_schema_arns(
NextToken='string',
MaxResults=123
)
:type NextToken: string
:param NextToken: The pagination token.
:type MaxResults: integer
:param MaxResults: The maximum number of results to retrieve.
:rtype: dict
:return: {
'SchemaArns': [
'string',
],
'NextToken': 'string'
}
:returns:
(string) --
"""
pass
def list_directories(NextToken=None, MaxResults=None, state=None):
"""
Lists directories created within an account.
See also: AWS API Documentation
:example: response = client.list_directories(
NextToken='string',
MaxResults=123,
state='ENABLED'|'DISABLED'|'DELETED'
)
:type NextToken: string
:param NextToken: The pagination token.
:type MaxResults: integer
:param MaxResults: The maximum number of results to retrieve.
:type state: string
:param state: The state of the directories in the list. Can be either Enabled, Disabled, or Deleted.
:rtype: dict
:return: {
'Directories': [
{
'Name': 'string',
'DirectoryArn': 'string',
'State': 'ENABLED'|'DISABLED'|'DELETED',
'CreationDateTime': datetime(2015, 1, 1)
},
],
'NextToken': 'string'
}
"""
pass
def list_facet_attributes(SchemaArn=None, Name=None, NextToken=None, MaxResults=None):
"""
Retrieves attributes attached to the facet.
See also: AWS API Documentation
:example: response = client.list_facet_attributes(
SchemaArn='string',
Name='string',
NextToken='string',
MaxResults=123
)
:type SchemaArn: string
:param SchemaArn: [REQUIRED]
The ARN of the schema where the facet resides.
:type Name: string
:param Name: [REQUIRED]
The name of the facet whose attributes will be retrieved.
:type NextToken: string
:param NextToken: The pagination token.
:type MaxResults: integer
:param MaxResults: The maximum number of results to retrieve.
:rtype: dict
:return: {
'Attributes': [
{
'Name': 'string',
'AttributeDefinition': {
'Type': 'STRING'|'BINARY'|'BOOLEAN'|'NUMBER'|'DATETIME',
'DefaultValue': {
'StringValue': 'string',
'BinaryValue': b'bytes',
'BooleanValue': True|False,
'NumberValue': 'string',
'DatetimeValue': datetime(2015, 1, 1)
},
'IsImmutable': True|False,
'Rules': {
'string': {
'Type': 'BINARY_LENGTH'|'NUMBER_COMPARISON'|'STRING_FROM_SET'|'STRING_LENGTH',
'Parameters': {
'string': 'string'
}
}
}
},
'AttributeReference': {
'TargetFacetName': 'string',
'TargetAttributeName': 'string'
},
'RequiredBehavior': 'REQUIRED_ALWAYS'|'NOT_REQUIRED'
},
],
'NextToken': 'string'
}
:returns:
(string) --
(string) --
"""
pass
def list_facet_names(SchemaArn=None, NextToken=None, MaxResults=None):
"""
Retrieves the names of facets that exist in a schema.
See also: AWS API Documentation
:example: response = client.list_facet_names(
SchemaArn='string',
NextToken='string',
MaxResults=123
)
:type SchemaArn: string
:param SchemaArn: [REQUIRED]
The Amazon Resource Name (ARN) to retrieve facet names from.
:type NextToken: string
:param NextToken: The pagination token.
:type MaxResults: integer
:param MaxResults: The maximum number of results to retrieve.
:rtype: dict
:return: {
'FacetNames': [
'string',
],
'NextToken': 'string'
}
:returns:
(string) --
"""
pass
def list_incoming_typed_links(DirectoryArn=None, ObjectReference=None, FilterAttributeRanges=None, FilterTypedLink=None, NextToken=None, MaxResults=None, ConsistencyLevel=None):
"""
Returns a paginated list of all the incoming TypedLinkSpecifier information for an object. It also supports filtering by typed link facet and identity attributes. For more information, see Typed link .
See also: AWS API Documentation
:example: response = client.list_incoming_typed_links(
DirectoryArn='string',
ObjectReference={
'Selector': 'string'
},
FilterAttributeRanges=[
{
'AttributeName': 'string',
'Range': {
'StartMode': 'FIRST'|'LAST'|'LAST_BEFORE_MISSING_VALUES'|'INCLUSIVE'|'EXCLUSIVE',
'StartValue': {
'StringValue': 'string',
'BinaryValue': b'bytes',
'BooleanValue': True|False,
'NumberValue': 'string',
'DatetimeValue': datetime(2015, 1, 1)
},
'EndMode': 'FIRST'|'LAST'|'LAST_BEFORE_MISSING_VALUES'|'INCLUSIVE'|'EXCLUSIVE',
'EndValue': {
'StringValue': 'string',
'BinaryValue': b'bytes',
'BooleanValue': True|False,
'NumberValue': 'string',
'DatetimeValue': datetime(2015, 1, 1)
}
}
},
],
FilterTypedLink={
'SchemaArn': 'string',
'TypedLinkName': 'string'
},
NextToken='string',
MaxResults=123,
ConsistencyLevel='SERIALIZABLE'|'EVENTUAL'
)
:type DirectoryArn: string
:param DirectoryArn: [REQUIRED]
The Amazon Resource Name (ARN) of the directory where you want to list the typed links.
:type ObjectReference: dict
:param ObjectReference: [REQUIRED]
Reference that identifies the object whose attributes will be listed.
Selector (string) --A path selector supports easy selection of an object by the parent/child links leading to it from the directory root. Use the link names from each parent/child link to construct the path. Path selectors start with a slash (/) and link names are separated by slashes. For more information about paths, see Accessing Objects . You can identify an object in one of the following ways:
$ObjectIdentifier - An object identifier is an opaque string provided by Amazon Cloud Directory. When creating objects, the system will provide you with the identifier of the created object. An object s identifier is immutable and no two objects will ever share the same object identifier
/some/path - Identifies the object based on path
#SomeBatchReference - Identifies the object in a batch call
:type FilterAttributeRanges: list
:param FilterAttributeRanges: Provides range filters for multiple attributes. When providing ranges to typed link selection, any inexact ranges must be specified at the end. Any attributes that do not have a range specified are presumed to match the entire range.
(dict) --Identifies the range of attributes that are used by a specified filter.
AttributeName (string) --The unique name of the typed link attribute.
Range (dict) -- [REQUIRED]The range of attribute values that are being selected.
StartMode (string) -- [REQUIRED]The inclusive or exclusive range start.
StartValue (dict) --The value to start the range at.
StringValue (string) --A string data value.
BinaryValue (bytes) --A binary data value.
BooleanValue (boolean) --A Boolean data value.
NumberValue (string) --A number data value.
DatetimeValue (datetime) --A date and time value.
EndMode (string) -- [REQUIRED]The inclusive or exclusive range end.
EndValue (dict) --The attribute value to terminate the range at.
StringValue (string) --A string data value.
BinaryValue (bytes) --A binary data value.
BooleanValue (boolean) --A Boolean data value.
NumberValue (string) --A number data value.
DatetimeValue (datetime) --A date and time value.
:type FilterTypedLink: dict
:param FilterTypedLink: Filters are interpreted in the order of the attributes on the typed link facet, not the order in which they are supplied to any API calls.
SchemaArn (string) -- [REQUIRED]The Amazon Resource Name (ARN) that is associated with the schema. For more information, see arns .
TypedLinkName (string) -- [REQUIRED]The unique name of the typed link facet.
:type NextToken: string
:param NextToken: The pagination token.
:type MaxResults: integer
:param MaxResults: The maximum number of results to retrieve.
:type ConsistencyLevel: string
:param ConsistencyLevel: The consistency level to execute the request at.
:rtype: dict
:return: {
'LinkSpecifiers': [
{
'TypedLinkFacet': {
'SchemaArn': 'string',
'TypedLinkName': 'string'
},
'SourceObjectReference': {
'Selector': 'string'
},
'TargetObjectReference': {
'Selector': 'string'
},
'IdentityAttributeValues': [
{
'AttributeName': 'string',
'Value': {
'StringValue': 'string',
'BinaryValue': b'bytes',
'BooleanValue': True|False,
'NumberValue': 'string',
'DatetimeValue': datetime(2015, 1, 1)
}
},
]
},
],
'NextToken': 'string'
}
:returns:
$ObjectIdentifier - An object identifier is an opaque string provided by Amazon Cloud Directory. When creating objects, the system will provide you with the identifier of the created object. An objects identifier is immutable and no two objects will ever share the same object identifier
/some/path - Identifies the object based on path
#SomeBatchReference - Identifies the object in a batch call
"""
pass
def list_index(DirectoryArn=None, RangesOnIndexedValues=None, IndexReference=None, MaxResults=None, NextToken=None, ConsistencyLevel=None):
"""
Lists objects attached to the specified index.
See also: AWS API Documentation
:example: response = client.list_index(
DirectoryArn='string',
RangesOnIndexedValues=[
{
'AttributeKey': {
'SchemaArn': 'string',
'FacetName': 'string',
'Name': 'string'
},
'Range': {
'StartMode': 'FIRST'|'LAST'|'LAST_BEFORE_MISSING_VALUES'|'INCLUSIVE'|'EXCLUSIVE',
'StartValue': {
'StringValue': 'string',
'BinaryValue': b'bytes',
'BooleanValue': True|False,
'NumberValue': 'string',
'DatetimeValue': datetime(2015, 1, 1)
},
'EndMode': 'FIRST'|'LAST'|'LAST_BEFORE_MISSING_VALUES'|'INCLUSIVE'|'EXCLUSIVE',
'EndValue': {
'StringValue': 'string',
'BinaryValue': b'bytes',
'BooleanValue': True|False,
'NumberValue': 'string',
'DatetimeValue': datetime(2015, 1, 1)
}
}
},
],
IndexReference={
'Selector': 'string'
},
MaxResults=123,
NextToken='string',
ConsistencyLevel='SERIALIZABLE'|'EVENTUAL'
)
:type DirectoryArn: string
:param DirectoryArn: [REQUIRED]
The ARN of the directory that the index exists in.
:type RangesOnIndexedValues: list
:param RangesOnIndexedValues: Specifies the ranges of indexed values that you want to query.
(dict) --A range of attributes.
AttributeKey (dict) --The key of the attribute that the attribute range covers.
SchemaArn (string) -- [REQUIRED]The Amazon Resource Name (ARN) of the schema that contains the facet and attribute.
FacetName (string) -- [REQUIRED]The name of the facet that the attribute exists within.
Name (string) -- [REQUIRED]The name of the attribute.
Range (dict) --The range of attribute values being selected.
StartMode (string) -- [REQUIRED]The inclusive or exclusive range start.
StartValue (dict) --The value to start the range at.
StringValue (string) --A string data value.
BinaryValue (bytes) --A binary data value.
BooleanValue (boolean) --A Boolean data value.
NumberValue (string) --A number data value.
DatetimeValue (datetime) --A date and time value.
EndMode (string) -- [REQUIRED]The inclusive or exclusive range end.
EndValue (dict) --The attribute value to terminate the range at.
StringValue (string) --A string data value.
BinaryValue (bytes) --A binary data value.
BooleanValue (boolean) --A Boolean data value.
NumberValue (string) --A number data value.
DatetimeValue (datetime) --A date and time value.
:type IndexReference: dict
:param IndexReference: [REQUIRED]
The reference to the index to list.
Selector (string) --A path selector supports easy selection of an object by the parent/child links leading to it from the directory root. Use the link names from each parent/child link to construct the path. Path selectors start with a slash (/) and link names are separated by slashes. For more information about paths, see Accessing Objects . You can identify an object in one of the following ways:
$ObjectIdentifier - An object identifier is an opaque string provided by Amazon Cloud Directory. When creating objects, the system will provide you with the identifier of the created object. An object s identifier is immutable and no two objects will ever share the same object identifier
/some/path - Identifies the object based on path
#SomeBatchReference - Identifies the object in a batch call
:type MaxResults: integer
:param MaxResults: The maximum number of results to retrieve from the index.
:type NextToken: string
:param NextToken: The pagination token.
:type ConsistencyLevel: string
:param ConsistencyLevel: The consistency level to execute the request at.
:rtype: dict
:return: {
'IndexAttachments': [
{
'IndexedAttributes': [
{
'Key': {
'SchemaArn': 'string',
'FacetName': 'string',
'Name': 'string'
},
'Value': {
'StringValue': 'string',
'BinaryValue': b'bytes',
'BooleanValue': True|False,
'NumberValue': 'string',
'DatetimeValue': datetime(2015, 1, 1)
}
},
],
'ObjectIdentifier': 'string'
},
],
'NextToken': 'string'
}
"""
pass
def list_object_attributes(DirectoryArn=None, ObjectReference=None, NextToken=None, MaxResults=None, ConsistencyLevel=None, FacetFilter=None):
"""
Lists all attributes that are associated with an object.
See also: AWS API Documentation
:example: response = client.list_object_attributes(
DirectoryArn='string',
ObjectReference={
'Selector': 'string'
},
NextToken='string',
MaxResults=123,
ConsistencyLevel='SERIALIZABLE'|'EVENTUAL',
FacetFilter={
'SchemaArn': 'string',
'FacetName': 'string'
}
)
:type DirectoryArn: string
:param DirectoryArn: [REQUIRED]
The Amazon Resource Name (ARN) that is associated with the Directory where the object resides. For more information, see arns .
:type ObjectReference: dict
:param ObjectReference: [REQUIRED]
The reference that identifies the object whose attributes will be listed.
Selector (string) --A path selector supports easy selection of an object by the parent/child links leading to it from the directory root. Use the link names from each parent/child link to construct the path. Path selectors start with a slash (/) and link names are separated by slashes. For more information about paths, see Accessing Objects . You can identify an object in one of the following ways:
$ObjectIdentifier - An object identifier is an opaque string provided by Amazon Cloud Directory. When creating objects, the system will provide you with the identifier of the created object. An object s identifier is immutable and no two objects will ever share the same object identifier
/some/path - Identifies the object based on path
#SomeBatchReference - Identifies the object in a batch call
:type NextToken: string
:param NextToken: The pagination token.
:type MaxResults: integer
:param MaxResults: The maximum number of items to be retrieved in a single call. This is an approximate number.
:type ConsistencyLevel: string
:param ConsistencyLevel: Represents the manner and timing in which the successful write or update of an object is reflected in a subsequent read operation of that same object.
:type FacetFilter: dict
:param FacetFilter: Used to filter the list of object attributes that are associated with a certain facet.
SchemaArn (string) --The ARN of the schema that contains the facet.
FacetName (string) --The name of the facet.
:rtype: dict
:return: {
'Attributes': [
{
'Key': {
'SchemaArn': 'string',
'FacetName': 'string',
'Name': 'string'
},
'Value': {
'StringValue': 'string',
'BinaryValue': b'bytes',
'BooleanValue': True|False,
'NumberValue': 'string',
'DatetimeValue': datetime(2015, 1, 1)
}
},
],
'NextToken': 'string'
}
"""
pass
def list_object_children(DirectoryArn=None, ObjectReference=None, NextToken=None, MaxResults=None, ConsistencyLevel=None):
"""
Returns a paginated list of child objects that are associated with a given object.
See also: AWS API Documentation
:example: response = client.list_object_children(
DirectoryArn='string',
ObjectReference={
'Selector': 'string'
},
NextToken='string',
MaxResults=123,
ConsistencyLevel='SERIALIZABLE'|'EVENTUAL'
)
:type DirectoryArn: string
:param DirectoryArn: [REQUIRED]
The Amazon Resource Name (ARN) that is associated with the Directory where the object resides. For more information, see arns .
:type ObjectReference: dict
:param ObjectReference: [REQUIRED]
The reference that identifies the object for which child objects are being listed.
Selector (string) --A path selector supports easy selection of an object by the parent/child links leading to it from the directory root. Use the link names from each parent/child link to construct the path. Path selectors start with a slash (/) and link names are separated by slashes. For more information about paths, see Accessing Objects . You can identify an object in one of the following ways:
$ObjectIdentifier - An object identifier is an opaque string provided by Amazon Cloud Directory. When creating objects, the system will provide you with the identifier of the created object. An object s identifier is immutable and no two objects will ever share the same object identifier
/some/path - Identifies the object based on path
#SomeBatchReference - Identifies the object in a batch call
:type NextToken: string
:param NextToken: The pagination token.
:type MaxResults: integer
:param MaxResults: The maximum number of items to be retrieved in a single call. This is an approximate number.
:type ConsistencyLevel: string
:param ConsistencyLevel: Represents the manner and timing in which the successful write or update of an object is reflected in a subsequent read operation of that same object.
:rtype: dict
:return: {
'Children': {
'string': 'string'
},
'NextToken': 'string'
}
:returns:
(string) --
(string) --
"""
pass
def list_object_parent_paths(DirectoryArn=None, ObjectReference=None, NextToken=None, MaxResults=None):
"""
Retrieves all available parent paths for any object type such as node, leaf node, policy node, and index node objects. For more information about objects, see Directory Structure .
Use this API to evaluate all parents for an object. The call returns all objects from the root of the directory up to the requested object. The API returns the number of paths based on user-defined MaxResults , in case there are multiple paths to the parent. The order of the paths and nodes returned is consistent among multiple API calls unless the objects are deleted or moved. Paths not leading to the directory root are ignored from the target object.
See also: AWS API Documentation
:example: response = client.list_object_parent_paths(
DirectoryArn='string',
ObjectReference={
'Selector': 'string'
},
NextToken='string',
MaxResults=123
)
:type DirectoryArn: string
:param DirectoryArn: [REQUIRED]
The ARN of the directory to which the parent path applies.
:type ObjectReference: dict
:param ObjectReference: [REQUIRED]
The reference that identifies the object whose parent paths are listed.
Selector (string) --A path selector supports easy selection of an object by the parent/child links leading to it from the directory root. Use the link names from each parent/child link to construct the path. Path selectors start with a slash (/) and link names are separated by slashes. For more information about paths, see Accessing Objects . You can identify an object in one of the following ways:
$ObjectIdentifier - An object identifier is an opaque string provided by Amazon Cloud Directory. When creating objects, the system will provide you with the identifier of the created object. An object s identifier is immutable and no two objects will ever share the same object identifier
/some/path - Identifies the object based on path
#SomeBatchReference - Identifies the object in a batch call
:type NextToken: string
:param NextToken: The pagination token.
:type MaxResults: integer
:param MaxResults: The maximum number of items to be retrieved in a single call. This is an approximate number.
:rtype: dict
:return: {
'PathToObjectIdentifiersList': [
{
'Path': 'string',
'ObjectIdentifiers': [
'string',
]
},
],
'NextToken': 'string'
}
:returns:
(string) --
"""
pass
def list_object_parents(DirectoryArn=None, ObjectReference=None, NextToken=None, MaxResults=None, ConsistencyLevel=None):
"""
Lists parent objects that are associated with a given object in pagination fashion.
See also: AWS API Documentation
:example: response = client.list_object_parents(
DirectoryArn='string',
ObjectReference={
'Selector': 'string'
},
NextToken='string',
MaxResults=123,
ConsistencyLevel='SERIALIZABLE'|'EVENTUAL'
)
:type DirectoryArn: string
:param DirectoryArn: [REQUIRED]
The Amazon Resource Name (ARN) that is associated with the Directory where the object resides. For more information, see arns .
:type ObjectReference: dict
:param ObjectReference: [REQUIRED]
The reference that identifies the object for which parent objects are being listed.
Selector (string) --A path selector supports easy selection of an object by the parent/child links leading to it from the directory root. Use the link names from each parent/child link to construct the path. Path selectors start with a slash (/) and link names are separated by slashes. For more information about paths, see Accessing Objects . You can identify an object in one of the following ways:
$ObjectIdentifier - An object identifier is an opaque string provided by Amazon Cloud Directory. When creating objects, the system will provide you with the identifier of the created object. An object s identifier is immutable and no two objects will ever share the same object identifier
/some/path - Identifies the object based on path
#SomeBatchReference - Identifies the object in a batch call
:type NextToken: string
:param NextToken: The pagination token.
:type MaxResults: integer
:param MaxResults: The maximum number of items to be retrieved in a single call. This is an approximate number.
:type ConsistencyLevel: string
:param ConsistencyLevel: Represents the manner and timing in which the successful write or update of an object is reflected in a subsequent read operation of that same object.
:rtype: dict
:return: {
'Parents': {
'string': 'string'
},
'NextToken': 'string'
}
:returns:
(string) --
(string) --
"""
pass
def list_object_policies(DirectoryArn=None, ObjectReference=None, NextToken=None, MaxResults=None, ConsistencyLevel=None):
"""
Returns policies attached to an object in pagination fashion.
See also: AWS API Documentation
:example: response = client.list_object_policies(
DirectoryArn='string',
ObjectReference={
'Selector': 'string'
},
NextToken='string',
MaxResults=123,
ConsistencyLevel='SERIALIZABLE'|'EVENTUAL'
)
:type DirectoryArn: string
:param DirectoryArn: [REQUIRED]
The Amazon Resource Name (ARN) that is associated with the Directory where objects reside. For more information, see arns .
:type ObjectReference: dict
:param ObjectReference: [REQUIRED]
Reference that identifies the object for which policies will be listed.
Selector (string) --A path selector supports easy selection of an object by the parent/child links leading to it from the directory root. Use the link names from each parent/child link to construct the path. Path selectors start with a slash (/) and link names are separated by slashes. For more information about paths, see Accessing Objects . You can identify an object in one of the following ways:
$ObjectIdentifier - An object identifier is an opaque string provided by Amazon Cloud Directory. When creating objects, the system will provide you with the identifier of the created object. An object s identifier is immutable and no two objects will ever share the same object identifier
/some/path - Identifies the object based on path
#SomeBatchReference - Identifies the object in a batch call
:type NextToken: string
:param NextToken: The pagination token.
:type MaxResults: integer
:param MaxResults: The maximum number of items to be retrieved in a single call. This is an approximate number.
:type ConsistencyLevel: string
:param ConsistencyLevel: Represents the manner and timing in which the successful write or update of an object is reflected in a subsequent read operation of that same object.
:rtype: dict
:return: {
'AttachedPolicyIds': [
'string',
],
'NextToken': 'string'
}
:returns:
(string) --
"""
pass
def list_outgoing_typed_links(DirectoryArn=None, ObjectReference=None, FilterAttributeRanges=None, FilterTypedLink=None, NextToken=None, MaxResults=None, ConsistencyLevel=None):
"""
Returns a paginated list of all the outgoing TypedLinkSpecifier information for an object. It also supports filtering by typed link facet and identity attributes. For more information, see Typed link .
See also: AWS API Documentation
:example: response = client.list_outgoing_typed_links(
DirectoryArn='string',
ObjectReference={
'Selector': 'string'
},
FilterAttributeRanges=[
{
'AttributeName': 'string',
'Range': {
'StartMode': 'FIRST'|'LAST'|'LAST_BEFORE_MISSING_VALUES'|'INCLUSIVE'|'EXCLUSIVE',
'StartValue': {
'StringValue': 'string',
'BinaryValue': b'bytes',
'BooleanValue': True|False,
'NumberValue': 'string',
'DatetimeValue': datetime(2015, 1, 1)
},
'EndMode': 'FIRST'|'LAST'|'LAST_BEFORE_MISSING_VALUES'|'INCLUSIVE'|'EXCLUSIVE',
'EndValue': {
'StringValue': 'string',
'BinaryValue': b'bytes',
'BooleanValue': True|False,
'NumberValue': 'string',
'DatetimeValue': datetime(2015, 1, 1)
}
}
},
],
FilterTypedLink={
'SchemaArn': 'string',
'TypedLinkName': 'string'
},
NextToken='string',
MaxResults=123,
ConsistencyLevel='SERIALIZABLE'|'EVENTUAL'
)
:type DirectoryArn: string
:param DirectoryArn: [REQUIRED]
The Amazon Resource Name (ARN) of the directory where you want to list the typed links.
:type ObjectReference: dict
:param ObjectReference: [REQUIRED]
A reference that identifies the object whose attributes will be listed.
Selector (string) --A path selector supports easy selection of an object by the parent/child links leading to it from the directory root. Use the link names from each parent/child link to construct the path. Path selectors start with a slash (/) and link names are separated by slashes. For more information about paths, see Accessing Objects . You can identify an object in one of the following ways:
$ObjectIdentifier - An object identifier is an opaque string provided by Amazon Cloud Directory. When creating objects, the system will provide you with the identifier of the created object. An object s identifier is immutable and no two objects will ever share the same object identifier
/some/path - Identifies the object based on path
#SomeBatchReference - Identifies the object in a batch call
:type FilterAttributeRanges: list
:param FilterAttributeRanges: Provides range filters for multiple attributes. When providing ranges to typed link selection, any inexact ranges must be specified at the end. Any attributes that do not have a range specified are presumed to match the entire range.
(dict) --Identifies the range of attributes that are used by a specified filter.
AttributeName (string) --The unique name of the typed link attribute.
Range (dict) -- [REQUIRED]The range of attribute values that are being selected.
StartMode (string) -- [REQUIRED]The inclusive or exclusive range start.
StartValue (dict) --The value to start the range at.
StringValue (string) --A string data value.
BinaryValue (bytes) --A binary data value.
BooleanValue (boolean) --A Boolean data value.
NumberValue (string) --A number data value.
DatetimeValue (datetime) --A date and time value.
EndMode (string) -- [REQUIRED]The inclusive or exclusive range end.
EndValue (dict) --The attribute value to terminate the range at.
StringValue (string) --A string data value.
BinaryValue (bytes) --A binary data value.
BooleanValue (boolean) --A Boolean data value.
NumberValue (string) --A number data value.
DatetimeValue (datetime) --A date and time value.
:type FilterTypedLink: dict
:param FilterTypedLink: Filters are interpreted in the order of the attributes defined on the typed link facet, not the order they are supplied to any API calls.
SchemaArn (string) -- [REQUIRED]The Amazon Resource Name (ARN) that is associated with the schema. For more information, see arns .
TypedLinkName (string) -- [REQUIRED]The unique name of the typed link facet.
:type NextToken: string
:param NextToken: The pagination token.
:type MaxResults: integer
:param MaxResults: The maximum number of results to retrieve.
:type ConsistencyLevel: string
:param ConsistencyLevel: The consistency level to execute the request at.
:rtype: dict
:return: {
'TypedLinkSpecifiers': [
{
'TypedLinkFacet': {
'SchemaArn': 'string',
'TypedLinkName': 'string'
},
'SourceObjectReference': {
'Selector': 'string'
},
'TargetObjectReference': {
'Selector': 'string'
},
'IdentityAttributeValues': [
{
'AttributeName': 'string',
'Value': {
'StringValue': 'string',
'BinaryValue': b'bytes',
'BooleanValue': True|False,
'NumberValue': 'string',
'DatetimeValue': datetime(2015, 1, 1)
}
},
]
},
],
'NextToken': 'string'
}
:returns:
$ObjectIdentifier - An object identifier is an opaque string provided by Amazon Cloud Directory. When creating objects, the system will provide you with the identifier of the created object. An objects identifier is immutable and no two objects will ever share the same object identifier
/some/path - Identifies the object based on path
#SomeBatchReference - Identifies the object in a batch call
"""
pass
def list_policy_attachments(DirectoryArn=None, PolicyReference=None, NextToken=None, MaxResults=None, ConsistencyLevel=None):
"""
Returns all of the ObjectIdentifiers to which a given policy is attached.
See also: AWS API Documentation
:example: response = client.list_policy_attachments(
DirectoryArn='string',
PolicyReference={
'Selector': 'string'
},
NextToken='string',
MaxResults=123,
ConsistencyLevel='SERIALIZABLE'|'EVENTUAL'
)
:type DirectoryArn: string
:param DirectoryArn: [REQUIRED]
The Amazon Resource Name (ARN) that is associated with the Directory where objects reside. For more information, see arns .
:type PolicyReference: dict
:param PolicyReference: [REQUIRED]
The reference that identifies the policy object.
Selector (string) --A path selector supports easy selection of an object by the parent/child links leading to it from the directory root. Use the link names from each parent/child link to construct the path. Path selectors start with a slash (/) and link names are separated by slashes. For more information about paths, see Accessing Objects . You can identify an object in one of the following ways:
$ObjectIdentifier - An object identifier is an opaque string provided by Amazon Cloud Directory. When creating objects, the system will provide you with the identifier of the created object. An object s identifier is immutable and no two objects will ever share the same object identifier
/some/path - Identifies the object based on path
#SomeBatchReference - Identifies the object in a batch call
:type NextToken: string
:param NextToken: The pagination token.
:type MaxResults: integer
:param MaxResults: The maximum number of items to be retrieved in a single call. This is an approximate number.
:type ConsistencyLevel: string
:param ConsistencyLevel: Represents the manner and timing in which the successful write or update of an object is reflected in a subsequent read operation of that same object.
:rtype: dict
:return: {
'ObjectIdentifiers': [
'string',
],
'NextToken': 'string'
}
:returns:
(string) --
"""
pass
def list_published_schema_arns(NextToken=None, MaxResults=None):
"""
Retrieves each published schema Amazon Resource Name (ARN).
See also: AWS API Documentation
:example: response = client.list_published_schema_arns(
NextToken='string',
MaxResults=123
)
:type NextToken: string
:param NextToken: The pagination token.
:type MaxResults: integer
:param MaxResults: The maximum number of results to retrieve.
:rtype: dict
:return: {
'SchemaArns': [
'string',
],
'NextToken': 'string'
}
:returns:
(string) --
"""
pass
def list_tags_for_resource(ResourceArn=None, NextToken=None, MaxResults=None):
"""
Returns tags for a resource. Tagging is currently supported only for directories with a limit of 50 tags per directory. All 50 tags are returned for a given directory with this API call.
See also: AWS API Documentation
:example: response = client.list_tags_for_resource(
ResourceArn='string',
NextToken='string',
MaxResults=123
)
:type ResourceArn: string
:param ResourceArn: [REQUIRED]
The Amazon Resource Name (ARN) of the resource. Tagging is only supported for directories.
:type NextToken: string
:param NextToken: The pagination token. This is for future use. Currently pagination is not supported for tagging.
:type MaxResults: integer
:param MaxResults: The MaxResults parameter sets the maximum number of results returned in a single page. This is for future use and is not supported currently.
:rtype: dict
:return: {
'Tags': [
{
'Key': 'string',
'Value': 'string'
},
],
'NextToken': 'string'
}
"""
pass
def list_typed_link_facet_attributes(SchemaArn=None, Name=None, NextToken=None, MaxResults=None):
"""
Returns a paginated list of all attribute definitions for a particular TypedLinkFacet . For more information, see Typed link .
See also: AWS API Documentation
:example: response = client.list_typed_link_facet_attributes(
SchemaArn='string',
Name='string',
NextToken='string',
MaxResults=123
)
:type SchemaArn: string
:param SchemaArn: [REQUIRED]
The Amazon Resource Name (ARN) that is associated with the schema. For more information, see arns .
:type Name: string
:param Name: [REQUIRED]
The unique name of the typed link facet.
:type NextToken: string
:param NextToken: The pagination token.
:type MaxResults: integer
:param MaxResults: The maximum number of results to retrieve.
:rtype: dict
:return: {
'Attributes': [
{
'Name': 'string',
'Type': 'STRING'|'BINARY'|'BOOLEAN'|'NUMBER'|'DATETIME',
'DefaultValue': {
'StringValue': 'string',
'BinaryValue': b'bytes',
'BooleanValue': True|False,
'NumberValue': 'string',
'DatetimeValue': datetime(2015, 1, 1)
},
'IsImmutable': True|False,
'Rules': {
'string': {
'Type': 'BINARY_LENGTH'|'NUMBER_COMPARISON'|'STRING_FROM_SET'|'STRING_LENGTH',
'Parameters': {
'string': 'string'
}
}
},
'RequiredBehavior': 'REQUIRED_ALWAYS'|'NOT_REQUIRED'
},
],
'NextToken': 'string'
}
:returns:
(string) --
(string) --
"""
pass
def list_typed_link_facet_names(SchemaArn=None, NextToken=None, MaxResults=None):
"""
Returns a paginated list of TypedLink facet names for a particular schema. For more information, see Typed link .
See also: AWS API Documentation
:example: response = client.list_typed_link_facet_names(
SchemaArn='string',
NextToken='string',
MaxResults=123
)
:type SchemaArn: string
:param SchemaArn: [REQUIRED]
The Amazon Resource Name (ARN) that is associated with the schema. For more information, see arns .
:type NextToken: string
:param NextToken: The pagination token.
:type MaxResults: integer
:param MaxResults: The maximum number of results to retrieve.
:rtype: dict
:return: {
'FacetNames': [
'string',
],
'NextToken': 'string'
}
:returns:
(string) --
"""
pass
def lookup_policy(DirectoryArn=None, ObjectReference=None, NextToken=None, MaxResults=None):
"""
Lists all policies from the root of the Directory to the object specified. If there are no policies present, an empty list is returned. If policies are present, and if some objects don't have the policies attached, it returns the ObjectIdentifier for such objects. If policies are present, it returns ObjectIdentifier , policyId , and policyType . Paths that don't lead to the root from the target object are ignored. For more information, see Policies .
See also: AWS API Documentation
:example: response = client.lookup_policy(
DirectoryArn='string',
ObjectReference={
'Selector': 'string'
},
NextToken='string',
MaxResults=123
)
:type DirectoryArn: string
:param DirectoryArn: [REQUIRED]
The Amazon Resource Name (ARN) that is associated with the Directory . For more information, see arns .
:type ObjectReference: dict
:param ObjectReference: [REQUIRED]
Reference that identifies the object whose policies will be looked up.
Selector (string) --A path selector supports easy selection of an object by the parent/child links leading to it from the directory root. Use the link names from each parent/child link to construct the path. Path selectors start with a slash (/) and link names are separated by slashes. For more information about paths, see Accessing Objects . You can identify an object in one of the following ways:
$ObjectIdentifier - An object identifier is an opaque string provided by Amazon Cloud Directory. When creating objects, the system will provide you with the identifier of the created object. An object s identifier is immutable and no two objects will ever share the same object identifier
/some/path - Identifies the object based on path
#SomeBatchReference - Identifies the object in a batch call
:type NextToken: string
:param NextToken: The token to request the next page of results.
:type MaxResults: integer
:param MaxResults: The maximum number of items to be retrieved in a single call. This is an approximate number.
:rtype: dict
:return: {
'PolicyToPathList': [
{
'Path': 'string',
'Policies': [
{
'PolicyId': 'string',
'ObjectIdentifier': 'string',
'PolicyType': 'string'
},
]
},
],
'NextToken': 'string'
}
"""
pass
def publish_schema(DevelopmentSchemaArn=None, Version=None, Name=None):
"""
Publishes a development schema with a version. If description and attributes are specified, PublishSchema overrides the development schema description and attributes. If not, the development schema description and attributes are used.
See also: AWS API Documentation
:example: response = client.publish_schema(
DevelopmentSchemaArn='string',
Version='string',
Name='string'
)
:type DevelopmentSchemaArn: string
:param DevelopmentSchemaArn: [REQUIRED]
The Amazon Resource Name (ARN) that is associated with the development schema. For more information, see arns .
:type Version: string
:param Version: [REQUIRED]
The version under which the schema will be published.
:type Name: string
:param Name: The new name under which the schema will be published. If this is not provided, the development schema is considered.
:rtype: dict
:return: {
'PublishedSchemaArn': 'string'
}
"""
pass
def put_schema_from_json(SchemaArn=None, Document=None):
"""
Allows a schema to be updated using JSON upload. Only available for development schemas. See JSON Schema Format for more information.
See also: AWS API Documentation
:example: response = client.put_schema_from_json(
SchemaArn='string',
Document='string'
)
:type SchemaArn: string
:param SchemaArn: [REQUIRED]
The ARN of the schema to update.
:type Document: string
:param Document: [REQUIRED]
The replacement JSON schema.
:rtype: dict
:return: {
'Arn': 'string'
}
"""
pass
def remove_facet_from_object(DirectoryArn=None, SchemaFacet=None, ObjectReference=None):
"""
Removes the specified facet from the specified object.
See also: AWS API Documentation
:example: response = client.remove_facet_from_object(
DirectoryArn='string',
SchemaFacet={
'SchemaArn': 'string',
'FacetName': 'string'
},
ObjectReference={
'Selector': 'string'
}
)
:type DirectoryArn: string
:param DirectoryArn: [REQUIRED]
The ARN of the directory in which the object resides.
:type SchemaFacet: dict
:param SchemaFacet: [REQUIRED]
The facet to remove.
SchemaArn (string) --The ARN of the schema that contains the facet.
FacetName (string) --The name of the facet.
:type ObjectReference: dict
:param ObjectReference: [REQUIRED]
A reference to the object to remove the facet from.
Selector (string) --A path selector supports easy selection of an object by the parent/child links leading to it from the directory root. Use the link names from each parent/child link to construct the path. Path selectors start with a slash (/) and link names are separated by slashes. For more information about paths, see Accessing Objects . You can identify an object in one of the following ways:
$ObjectIdentifier - An object identifier is an opaque string provided by Amazon Cloud Directory. When creating objects, the system will provide you with the identifier of the created object. An object s identifier is immutable and no two objects will ever share the same object identifier
/some/path - Identifies the object based on path
#SomeBatchReference - Identifies the object in a batch call
:rtype: dict
:return: {}
:returns:
(dict) --
"""
pass
def tag_resource(ResourceArn=None, Tags=None):
"""
An API operation for adding tags to a resource.
See also: AWS API Documentation
:example: response = client.tag_resource(
ResourceArn='string',
Tags=[
{
'Key': 'string',
'Value': 'string'
},
]
)
:type ResourceArn: string
:param ResourceArn: [REQUIRED]
The Amazon Resource Name (ARN) of the resource. Tagging is only supported for directories.
:type Tags: list
:param Tags: [REQUIRED]
A list of tag key-value pairs.
(dict) --The tag structure that contains a tag key and value.
Key (string) --The key that is associated with the tag.
Value (string) --The value that is associated with the tag.
:rtype: dict
:return: {}
:returns:
(dict) --
"""
pass
def untag_resource(ResourceArn=None, TagKeys=None):
"""
An API operation for removing tags from a resource.
See also: AWS API Documentation
:example: response = client.untag_resource(
ResourceArn='string',
TagKeys=[
'string',
]
)
:type ResourceArn: string
:param ResourceArn: [REQUIRED]
The Amazon Resource Name (ARN) of the resource. Tagging is only supported for directories.
:type TagKeys: list
:param TagKeys: [REQUIRED]
Keys of the tag that need to be removed from the resource.
(string) --
:rtype: dict
:return: {}
:returns:
(dict) --
"""
pass
def update_facet(SchemaArn=None, Name=None, AttributeUpdates=None, ObjectType=None):
"""
Does the following:
See also: AWS API Documentation
:example: response = client.update_facet(
SchemaArn='string',
Name='string',
AttributeUpdates=[
{
'Attribute': {
'Name': 'string',
'AttributeDefinition': {
'Type': 'STRING'|'BINARY'|'BOOLEAN'|'NUMBER'|'DATETIME',
'DefaultValue': {
'StringValue': 'string',
'BinaryValue': b'bytes',
'BooleanValue': True|False,
'NumberValue': 'string',
'DatetimeValue': datetime(2015, 1, 1)
},
'IsImmutable': True|False,
'Rules': {
'string': {
'Type': 'BINARY_LENGTH'|'NUMBER_COMPARISON'|'STRING_FROM_SET'|'STRING_LENGTH',
'Parameters': {
'string': 'string'
}
}
}
},
'AttributeReference': {
'TargetFacetName': 'string',
'TargetAttributeName': 'string'
},
'RequiredBehavior': 'REQUIRED_ALWAYS'|'NOT_REQUIRED'
},
'Action': 'CREATE_OR_UPDATE'|'DELETE'
},
],
ObjectType='NODE'|'LEAF_NODE'|'POLICY'|'INDEX'
)
:type SchemaArn: string
:param SchemaArn: [REQUIRED]
The Amazon Resource Name (ARN) that is associated with the Facet . For more information, see arns .
:type Name: string
:param Name: [REQUIRED]
The name of the facet.
:type AttributeUpdates: list
:param AttributeUpdates: List of attributes that need to be updated in a given schema Facet . Each attribute is followed by AttributeAction , which specifies the type of update operation to perform.
(dict) --A structure that contains information used to update an attribute.
Attribute (dict) --The attribute to update.
Name (string) -- [REQUIRED]The name of the facet attribute.
AttributeDefinition (dict) --A facet attribute consists of either a definition or a reference. This structure contains the attribute definition. See Attribute References for more information.
Type (string) -- [REQUIRED]The type of the attribute.
DefaultValue (dict) --The default value of the attribute (if configured).
StringValue (string) --A string data value.
BinaryValue (bytes) --A binary data value.
BooleanValue (boolean) --A Boolean data value.
NumberValue (string) --A number data value.
DatetimeValue (datetime) --A date and time value.
IsImmutable (boolean) --Whether the attribute is mutable or not.
Rules (dict) --Validation rules attached to the attribute definition.
(string) --
(dict) --Contains an Amazon Resource Name (ARN) and parameters that are associated with the rule.
Type (string) --The type of attribute validation rule.
Parameters (dict) --The minimum and maximum parameters that are associated with the rule.
(string) --
(string) --
AttributeReference (dict) --An attribute reference that is associated with the attribute. See Attribute References for more information.
TargetFacetName (string) -- [REQUIRED]The target facet name that is associated with the facet reference. See Attribute References for more information.
TargetAttributeName (string) -- [REQUIRED]The target attribute name that is associated with the facet reference. See Attribute References for more information.
RequiredBehavior (string) --The required behavior of the FacetAttribute .
Action (string) --The action to perform when updating the attribute.
:type ObjectType: string
:param ObjectType: The object type that is associated with the facet. See CreateFacetRequest$ObjectType for more details.
:rtype: dict
:return: {}
:returns:
SchemaArn (string) -- [REQUIRED]
The Amazon Resource Name (ARN) that is associated with the Facet . For more information, see arns .
Name (string) -- [REQUIRED]
The name of the facet.
AttributeUpdates (list) -- List of attributes that need to be updated in a given schema Facet . Each attribute is followed by AttributeAction , which specifies the type of update operation to perform.
(dict) --A structure that contains information used to update an attribute.
Attribute (dict) --The attribute to update.
Name (string) -- [REQUIRED]The name of the facet attribute.
AttributeDefinition (dict) --A facet attribute consists of either a definition or a reference. This structure contains the attribute definition. See Attribute References for more information.
Type (string) -- [REQUIRED]The type of the attribute.
DefaultValue (dict) --The default value of the attribute (if configured).
StringValue (string) --A string data value.
BinaryValue (bytes) --A binary data value.
BooleanValue (boolean) --A Boolean data value.
NumberValue (string) --A number data value.
DatetimeValue (datetime) --A date and time value.
IsImmutable (boolean) --Whether the attribute is mutable or not.
Rules (dict) --Validation rules attached to the attribute definition.
(string) --
(dict) --Contains an Amazon Resource Name (ARN) and parameters that are associated with the rule.
Type (string) --The type of attribute validation rule.
Parameters (dict) --The minimum and maximum parameters that are associated with the rule.
(string) --
(string) --
AttributeReference (dict) --An attribute reference that is associated with the attribute. See Attribute References for more information.
TargetFacetName (string) -- [REQUIRED]The target facet name that is associated with the facet reference. See Attribute References for more information.
TargetAttributeName (string) -- [REQUIRED]The target attribute name that is associated with the facet reference. See Attribute References for more information.
RequiredBehavior (string) --The required behavior of the FacetAttribute .
Action (string) --The action to perform when updating the attribute.
ObjectType (string) -- The object type that is associated with the facet. See CreateFacetRequest$ObjectType for more details.
"""
pass
def update_object_attributes(DirectoryArn=None, ObjectReference=None, AttributeUpdates=None):
"""
Updates a given object's attributes.
See also: AWS API Documentation
:example: response = client.update_object_attributes(
DirectoryArn='string',
ObjectReference={
'Selector': 'string'
},
AttributeUpdates=[
{
'ObjectAttributeKey': {
'SchemaArn': 'string',
'FacetName': 'string',
'Name': 'string'
},
'ObjectAttributeAction': {
'ObjectAttributeActionType': 'CREATE_OR_UPDATE'|'DELETE',
'ObjectAttributeUpdateValue': {
'StringValue': 'string',
'BinaryValue': b'bytes',
'BooleanValue': True|False,
'NumberValue': 'string',
'DatetimeValue': datetime(2015, 1, 1)
}
}
},
]
)
:type DirectoryArn: string
:param DirectoryArn: [REQUIRED]
The Amazon Resource Name (ARN) that is associated with the Directory where the object resides. For more information, see arns .
:type ObjectReference: dict
:param ObjectReference: [REQUIRED]
The reference that identifies the object.
Selector (string) --A path selector supports easy selection of an object by the parent/child links leading to it from the directory root. Use the link names from each parent/child link to construct the path. Path selectors start with a slash (/) and link names are separated by slashes. For more information about paths, see Accessing Objects . You can identify an object in one of the following ways:
$ObjectIdentifier - An object identifier is an opaque string provided by Amazon Cloud Directory. When creating objects, the system will provide you with the identifier of the created object. An object s identifier is immutable and no two objects will ever share the same object identifier
/some/path - Identifies the object based on path
#SomeBatchReference - Identifies the object in a batch call
:type AttributeUpdates: list
:param AttributeUpdates: [REQUIRED]
The attributes update structure.
(dict) --Structure that contains attribute update information.
ObjectAttributeKey (dict) --The key of the attribute being updated.
SchemaArn (string) -- [REQUIRED]The Amazon Resource Name (ARN) of the schema that contains the facet and attribute.
FacetName (string) -- [REQUIRED]The name of the facet that the attribute exists within.
Name (string) -- [REQUIRED]The name of the attribute.
ObjectAttributeAction (dict) --The action to perform as part of the attribute update.
ObjectAttributeActionType (string) --A type that can be either Update or Delete .
ObjectAttributeUpdateValue (dict) --The value that you want to update to.
StringValue (string) --A string data value.
BinaryValue (bytes) --A binary data value.
BooleanValue (boolean) --A Boolean data value.
NumberValue (string) --A number data value.
DatetimeValue (datetime) --A date and time value.
:rtype: dict
:return: {
'ObjectIdentifier': 'string'
}
"""
pass
def update_schema(SchemaArn=None, Name=None):
"""
Updates the schema name with a new name. Only development schema names can be updated.
See also: AWS API Documentation
:example: response = client.update_schema(
SchemaArn='string',
Name='string'
)
:type SchemaArn: string
:param SchemaArn: [REQUIRED]
The Amazon Resource Name (ARN) of the development schema. For more information, see arns .
:type Name: string
:param Name: [REQUIRED]
The name of the schema.
:rtype: dict
:return: {
'SchemaArn': 'string'
}
"""
pass
def update_typed_link_facet(SchemaArn=None, Name=None, AttributeUpdates=None, IdentityAttributeOrder=None):
"""
Updates a TypedLinkFacet . For more information, see Typed link .
See also: AWS API Documentation
:example: response = client.update_typed_link_facet(
SchemaArn='string',
Name='string',
AttributeUpdates=[
{
'Attribute': {
'Name': 'string',
'Type': 'STRING'|'BINARY'|'BOOLEAN'|'NUMBER'|'DATETIME',
'DefaultValue': {
'StringValue': 'string',
'BinaryValue': b'bytes',
'BooleanValue': True|False,
'NumberValue': 'string',
'DatetimeValue': datetime(2015, 1, 1)
},
'IsImmutable': True|False,
'Rules': {
'string': {
'Type': 'BINARY_LENGTH'|'NUMBER_COMPARISON'|'STRING_FROM_SET'|'STRING_LENGTH',
'Parameters': {
'string': 'string'
}
}
},
'RequiredBehavior': 'REQUIRED_ALWAYS'|'NOT_REQUIRED'
},
'Action': 'CREATE_OR_UPDATE'|'DELETE'
},
],
IdentityAttributeOrder=[
'string',
]
)
:type SchemaArn: string
:param SchemaArn: [REQUIRED]
The Amazon Resource Name (ARN) that is associated with the schema. For more information, see arns .
:type Name: string
:param Name: [REQUIRED]
The unique name of the typed link facet.
:type AttributeUpdates: list
:param AttributeUpdates: [REQUIRED]
Attributes update structure.
(dict) --A typed link facet attribute update.
Attribute (dict) -- [REQUIRED]The attribute to update.
Name (string) -- [REQUIRED]The unique name of the typed link attribute.
Type (string) -- [REQUIRED]The type of the attribute.
DefaultValue (dict) --The default value of the attribute (if configured).
StringValue (string) --A string data value.
BinaryValue (bytes) --A binary data value.
BooleanValue (boolean) --A Boolean data value.
NumberValue (string) --A number data value.
DatetimeValue (datetime) --A date and time value.
IsImmutable (boolean) --Whether the attribute is mutable or not.
Rules (dict) --Validation rules that are attached to the attribute definition.
(string) --
(dict) --Contains an Amazon Resource Name (ARN) and parameters that are associated with the rule.
Type (string) --The type of attribute validation rule.
Parameters (dict) --The minimum and maximum parameters that are associated with the rule.
(string) --
(string) --
RequiredBehavior (string) -- [REQUIRED]The required behavior of the TypedLinkAttributeDefinition .
Action (string) -- [REQUIRED]The action to perform when updating the attribute.
:type IdentityAttributeOrder: list
:param IdentityAttributeOrder: [REQUIRED]
A range filter that you provide for multiple attributes. The ability to filter typed links considers the order that the attributes are defined on the typed link facet. When providing ranges to a typed link selection, any inexact ranges must be specified at the end. Any attributes that do not have a range specified are presumed to match the entire range. Filters are interpreted in the order of the attributes on the typed link facet, not the order in which they are supplied to any API calls.
(string) --
:rtype: dict
:return: {}
:returns:
(dict) --
"""
pass
|
workers = 1
worker_class = 'gevent'
bind = '0.0.0.0:5000'
pidfile = '/tmp/gunicorn-csdh-api.pid'
debug = True
reload = True
loglevel = 'info'
errorlog = '/tmp/gunicorn_csdh_api_error.log'
accesslog = '/tmp/gunicorn_csdh_api_access.log'
daemon = False
|
# -*- coding: utf-8 -*-
# ------------- Diccionario -------------
#Solo se ermite una llave nula
#Los valores son mutables pero las llaves NO
#No se encuentran ordenados por ser hashmap
elementos = {'hidrogeno': 1, 'helio': 2, 'carbon': 6}
# Al imprimir el diccionario, los elementos puede
# aparecer en diferente orden del introducido
print (elementos)
print (elementos['hidrogeno'])
# Envía un error al imprimir un elemento inexistente
# print elementos['oxigeno']
# Se pueen agregar elementos al diccionario
elementos['litio'] = 3
elementos['nitrogeno'] = 8
elementos['hidrogeno'] = 1000 #Si existe lo actualiza, en caso contrario lo agrega
print (elementos)
# Se crea un nuevo diccionario
elementos2 = {}
elementos2['H'] = {'name': 'Hydrogen', 'number': 1, 'weight': 1.00794}
elementos2['He'] = {'name': 'Helium', 'number': 2, 'weight': 4.002602}
print (elementos2)
# Se imprimen los datos de un elemento del diccionario
print (elementos2['H'])
print (elementos2['H']['name'])
print (elementos2['H']['number'])
# Se cambia el valor de un elemento
elementos2['H']['weight'] = 4.30
print (elementos2['H']['weight'])
# Se agregan elementos a una llave
elementos2['H'].update({'gas noble': True})
print (elementos2['H'])
# Muestra todas las llaves del diccionario
print (elementos2.keys()) #Devuelve listas
# Muestra todos los valores del diccionario
print (elementos2.items()) #Devuelve listas con subtuplas
for k,v in elementos2.items(): #Iterar y leer tuplas
print ("Llave: " + str(k))
print ("Valor: " + str(v))
for subk, subv in v.items():
print ("\tSUBLlave: " + str(subk))
print ("\tSUBValor: " + str(subv))
# Se limpia el diccionario
#elementos2.clear()
print('\n')
elementos2['H'].clear()
print (elementos2)
print('\n')
elementos2['He'].clear()
print (elementos2)
# Eliminar con operacion del, elimina elemento por medio de llave
del(elementos2['He'])
print (elementos2)
|
'''
This problem was asked by Yelp.
Given a mapping of digits to letters (as in a phone number), and a digit string, return all possible letters the number could represent.
You can assume each valid number in the mapping is a single digit.
For example if {“2”: [“a”, “b”, “c”], 3: [“d”, “e”, “f”], …} then “23” should return [“ad”, “ae”, “af”, “bd”, “be”, “bf”, “cd”, “ce”, “cf"].
'''
def solve(phone_no, nums):
if not nums: return []
ans = phone_no.get(nums[0], [])
for i in range(1, len(nums)):
no = ans
ans = []
for j in no:
for k in phone_no.get(nums[i], []):
ans.append(j+k)
return ans
if __name__ == "__main__":
data = [
[
[{"2": ["a", "b", "c"], "3": ["d", "e", "f"]}, "23"],
['ad', 'ae', 'af', 'bd', 'be', 'bf', 'cd', 'ce', 'cf']
]
]
for d in data:
print('input', d[0], 'output', solve(*d[0])) |
somaidade = 0 #variavel para somar a idade
homemvelho = '' # variavel para o homem mais velho
idadehomevelho = 0 # variavel paraca idade do homem mais velho
contmulher = 0 # contador de mulher com menos de 20 anos
for c in range(1, 5):
print(f'-'*5,f'PESSOA {c}', '-'*5)
nome = str(input('Nome: ')).strip()
idade = int(input('Idade (anos): '))
somaidade += idade
sexo = str(input('Sexo (M/F): ')).strip()
if sexo in 'Mm' and idade > idadehomevelho:
idadehomevelho = idade
homemvelho = nome
if sexo in 'Ff' and idade < 20:
contmulher += 1
mediaidade = somaidade / 4
print(f'A media de idade é {mediaidade:.1f} anos')
print(f'O homem mais velho é {homemvelho} com {idadehomevelho} anos')
print(f'Ao total {contmulher} mulheres tem menos de 20 anos') |
def sol():
a = input()
b = input()
for i in range(3):
print( int(a) * int(b[2 - i]) )
print(int(a) * int(b))
if __name__ == "__main__":
sol()
|
# LISTS
#
# A list is a data structure consisting of a collection of elements (values or variables)
food = ['oranges', 'strawberries', 'lemons']
x = food[0] # The first element is at index 0
y = food[1] # The second element is at index 1
z = food[2] # The third element is at index 2
print('I like', x, ', ', y, ', and', z)
# COUNT ELEMENTS IN A LIST
fruits = ['Apple', 'Banana', 'Watermelon', 'Peach', ' Nectarine']
num_fruits = len(fruits) # The variable 'num_fruits' is 5 (the number of elements of the array 'fruits')
print(num_fruits)
# MODIFY A LIST ELEMENT
ages = [43, 72, 32, 22, 65]
ages[3] = 57 # Modify the element at index 3. Result: [43, 72, 32, 57, 65]
ages[0] = 6 # Modify the first element. Result: [6, 72, 32, 57, 65]
ages[-1] = 12 # Modify the last element. Result: [6, 72, 32, 57, 12]
print(ages)
# ADD AN ELEMENT TO A LIST
names = ['Nacho', 'Lola', 'David']
names.insert(2, 'Alba') # Add 'Alba' at index 2. Result: ['Nacho', 'David', 'Alba', 'Lola']
names.insert(0, 'Álvaro') # Add 'Álvaro' at the beginning. Result: ['Álvaro', 'Nacho', 'David', 'Alba', 'Lola']
names.append('Marta') # Add 'Marta' at the end. Result: ['Álvaro', 'Nacho', 'David', 'Alba', 'Lola', 'Marta']
print(names);
# REMOVE A LIST ELEMENT
colours = ['Blue', 'Orange', 'Green', 'Yellow', 'White']
colours.pop(2) # Remove the element at index 2. Result: ['Blue', 'Orange', 'Yellow', 'White']
colours.pop(0) # Remove the first element. Result: ['Orange', 'Yellow', 'White']
colours.pop() # Remove the last element. Result: ['Orange', 'Yellow']
print(colours)
# SUBARRAYS [start:end]
vegetables = ['Onions', 'Tomatoes', 'Spinach', 'Eggplants', 'Radishes']
veg1 = vegetables[:] # Result: ['Onions', 'Tomatoes', 'Spinach', 'Eggplants', 'Radishes']
veg2 = vegetables[2:] # Result: ['Spinach', 'Eggplants', 'Radishes']
veg3 = vegetables[2:4] # Result: ['Spinach', 'Eggplants']
veg4 = vegetables[-3:-2] # Result: ['Spinach']
# REVERSE ELEMENTS IN A LIST
numbers = [4, 5.6, -2.4, 20]
animals = ['Dog', 'Whale', 'Cat', 'Fox']
numbers_reversed = numbers[::-1]
animals_reversed = animals[::-1]
print(numbers_reversed)
print(animals_reversed)
# SORT ELEMENTS IN A LIST
numbers_sorted = sorted(numbers)
animals_sorted = sorted(animals)
print(numbers_sorted);
print(animals_sorted);
# MULTIDIMENSIONAL LISTS
a = [8, 1]
b = [3, 5, 7, 6]
c = [4, [10, 9], 2];
multi = [a, b, c]
d = multi[1][3] # Get the element at [1][3]. Variable 'd' is 6
multi[2][1][0] = -1 # Modify the element at index [2][1][0]
print(multi)
# CREATE EMPTY LISTS
empty_1d_list = [] # Create an empty list
empty_2d_list = [[]] # Create an empty two-dimensional list
empty_3d_list = [[[]]] # Create an empty three-dimensional list
my_list = [[], []]
my_list[0].append(2)
my_list[0].append('Marta')
my_list[1].append('Hi!')
my_list[1].append(3.4)
print(my_list) # Prints [[2, 'Marta'], ['Hi!', 3.4]]
# STRINGS AS ARRAYS OF CHARACTERS - SUBSTRINGS
phrase = 'Oranges are round, and oranges are juicy.'
num_chars = len(phrase) # The number of characters of the string 'phrase'. Result: 41.
p1 = phrase[23:] # Result: 'oranges are juicy.'
p2 = phrase[12:17] # Result: 'round'
p3 = phrase[-6:-1] # Result: 'juicy'
p4 = phrase[17:18] # Result: ','
p5 = phrase[-1:] # Result: '.'
|
#!/usr/bin/env python
# -*- coding: utf-8 -*-
def all_messages():
return \
{
"0": "Il motore Nettacker è iniziato ...\n\n",
"1": "python nettacker.py [opzioni]",
"2": "Mostra il menu di aiuto di Nettacker",
"3": "Leggere la licenza e gli accordi https://github.com/viraintel/OWASP-Nettacker\n",
"4": "Motore",
"5": "Opzioni di ingresso del motore",
"6": "selezionare una lingua {0}",
"7": "scansione di tutti gli IP nell'intervallo",
"8": "trovare e analizzare i sottodomini",
"9": "numeri di thread per le connessioni ad un host",
"10": "numeri di thread per gli host di scansione",
"11": "salvare tutti i registri nel file (results.txt, results.html, results.json)",
"12": "Bersaglio",
"13": "Opzioni di ingresso target",
"14": "elenco target (s), separato con \",\"",
"15": "leggere i bersagli dal file",
"16": "Opzioni del metodo di scansione",
"17": "scegliere il metodo di scansione {0}",
"18": "scegliere il metodo di scansione per escludere {0}",
"19": "nome utente, separato da \",\"",
"20": "leggere il nome utente dal file",
"21": "elenco delle password, separato con \",\"",
"22": "leggere le password dal file",
"23": "elenco delle porte, separato da \",\"",
"24": "leggere le password dal file",
"25": "tempo di dormire tra ogni richiesta",
"26": "Impossibile specificare i target (i)",
"27": "Impossibile specificare gli obiettivi, impossibile aprire il file: {0}",
"28": "è meglio utilizzare il numero di thread inferiore a 100, BTW stiamo continuando ...",
"29": "impostare il timeout a {0} secondi, è troppo grande, non "
"è vero? dal modo in cui stiamo continuando ...",
"30": "questo modulo di scansione [{0}] non è stato trovato!",
"31": "questo modulo di scansione [{0}] non è stato trovato!",
"32": "non è possibile escludere tutti i metodi di scansione",
"33": "non è possibile escludere tutti i metodi di scansione",
"34": "il modulo {0} selezionato per escludere non trovato!",
"35": "inserire gli input di metodi, ad esempio: \"ftp_brute_users=test,admin&"
"ftp_brute_passwds=read_from_file:/tmp/pass.txt&ftp_brute_port=21\"",
"36": "non riesce a leggere file {0}",
"37": "Impossibile specificare il nome utente, impossibile aprire il file: {0}",
"38": "",
"39": "Impossibile specificare le password, impossibile aprire il file: {0}",
"40": "file \"{0}\" non è scrivibile!",
"41": "scelga il metodo di scansione!",
"42": "rimuovendo file temporanei!",
"43": "risolvere i risultati!",
"44": "fatto!",
"45": "iniziare ad attaccare {0}, {1} di {2}",
"46": "questo modulo \"{0}\" non è disponibile",
"47": "purtroppo questa versione del software potrebbe essere eseguita solo su linux / osx / windows.",
"48": "La tua versione Python non è supportata!",
"49": "saltare l'obiettivo duplicato (alcuni sottodomini / domini possono avere lo stesso IP e le aree)",
"50": "tipo sconosciuto di destinazione [{0}]",
"51": "controlla la gamma {0} ...",
"52": "controllando {0} ...",
"53": "OSPITE",
"54": "NOME UTENTE",
"55": "PASSWORD",
"56": "PORTA",
"57": "TIPO",
"58": "DESCRIZIONE",
"59": "livello di modalità verbose (0-5) (impostazione predefinita 0)",
"60": "mostrare la versione del software",
"61": "ricerca aggiornamenti",
"62": "",
"63": "",
"64": "Ripeti quando il timeout di connessione (default 3)",
"65": "ftp a {0}: {1} timeout, saltando {2}: {3}",
"66": "INCONTATO IN SUCCESSO!",
"67": "INCONTRATO IN SUCCESSO, PERMISSIONE ANNULLATA PER IL COMANDO ELENCO!",
"68": "ftp a {0}: {1} non è riuscito, saltando intero passo [processo "
"{2} di {3}]! andando al passo successivo",
"69": "il target di input per il modulo {0} deve essere DOMAIN, HTTP o SINGLE_IPv4, saltando {1}",
"70": "utente: {0} pass: {1} host: {2} port: {3} trovato!",
"71": "(NESSUNA PERMISSIONE PER LE FILE DELLE LISTA)",
"72": "provando {0} di {1} in processo {2} di {3} {4}: {5}",
"73": "connessione smtp a {0}: {1} timeout, saltando {2}: {3}",
"74": "la connessione smtp a {0}: {1} non è riuscita, saltando tutto il passo [processo {2} "
"di {3}]! andando al passo successivo",
"75": "il target di ingresso per il modulo {0} deve essere HTTP, saltando {1}",
"76": "ssh a {0}: {1} timeout, saltando {2}: {3}",
"77": "ssh a {0}: {1} non è riuscito, saltando intero passo [processo {2} di {3}]! andando "
"al passo successivo",
"78": "connessione ssh a% s:% s non riuscita, saltando intero passo [processo% s di% s]!"
" andando al passo successivo",
"79": "PORTA APERTA",
"80": "host: {0} port: {1} trovato!",
"81": "target {0} inviato!",
"82": "impossibile aprire il file di elenco proxy: {0}",
"83": "impossibile trovare il file di elenco proxy: {0}",
"84": "si esegue la versione OWASP Nettacker {0} {1} {2} {6} con il nome del codice {3} {4} {5}",
"85": "questa funzione non è ancora disponibile! si prega di eseguire "
"\"clone git https://github.com/viraintel/OWASP-Nettacker.git\" o "
"\"pip install -U OWASP-Nettacker\" per ottenere l'ultima versione.",
"86": "costruire un grafico di tutte le attività e le informazioni, è necessario "
"utilizzare l'output HTML. grafici disponibili: {0}",
"87": "per utilizzare il grafico il nome del file di output deve terminare con \".html\" o \".htm\"!",
"88": "costruzione grafico ...",
"89": "finire il grafico di costruzione!",
"90": "Grafici di prova di penetrazione",
"91": "Questo grafico creato da OWASP Nettacker. Il grafico contiene tutte le "
"attività dei moduli, mappe di rete e informazioni sensibili. Non condividi "
"questo file con nessuno se non è affidabile.",
"92": "Rapporto OWASP Nettacker",
"93": "Dettagli del software: versione OWASP Nettacker {0} [{1}] in {2}",
"94": "non sono state trovate porte aperte!",
"95": "nessun utente / password trovato!",
"96": "{0} moduli caricati ...",
"97": "questo modulo di grafico non è trovato: {0}",
"98": "questo modulo grafico \"{0}\" non è disponibile",
"99": "ping prima di eseguire la scansione dell'host",
"100": "saltando l'intero target {0} e il metodo di scansione {1} a causa di "
"--ping-before-scan è vero e non ha risposto!",
"101": "non si utilizza l'ultima versione di OWASP Nettacker, si prega di aggiornare.",
"102": "non riesci a controllare l'aggiornamento, controlla la tua connessione internet.",
"103": "Stai utilizzando l'ultima versione di OWASP Nettacker ...",
"104": "elenco directory trovato in {0}",
"105": "inserire la porta tramite il comando -g o -methods-args anziché url",
"106": "connessione http {0} timeout!",
"107": "",
"108": "nessuna directory o file trovato per {0} nella porta {1}",
"109": "impossibile aprire {0}",
"110": "il valore dir_scan_http_method deve essere GET o HEAD, impostare il valore predefinito su GET.",
"111": "elenca tutti i metodi args",
"112": "non è possibile ottenere {0} modulo args",
"113": "",
"114": "",
"115": "",
"116": "",
"117": ""
}
|
def main():
x = 10
if(x == 5):
x = 1
else:
x = 2
x = 3 |
class Phishing(object):
@staticmethod
def create_():
print("Haciendo phishing") |
n = int(input())
ondo = [list(map(float, input().split())) for _ in range(n)]
soukei = {'mousyo': 0, 'manatsu': 1, 'natsu': 2,
'nettai': 3, 'huyu': 4, 'mafuyu': 5}
s = [0]*6
for i, j in ondo:
if i >= 35:
s[soukei['mousyo']] += 1
if 30 <= i < 35:
s[soukei['manatsu']] += 1
if 25 <= i < 30:
s[soukei['natsu']] += 1
if 25 <= j:
s[soukei['nettai']] += 1
if j < 0 and 0 <= i:
s[soukei['huyu']] += 1
if i < 0:
s[soukei['mafuyu']] += 1
print(*s)
|
num1 = int(input("Digite um número: "))
num2 = int(input("Digite um número: "))
soma = num1 + num2
print("A soma é: %3.0f" % soma)
|
class Car(object):
speed = 0
def __init__(self, vehicle_type=None,model='GM',name='General'):
self.vehicle_type= vehicle_type
self.model = model
self.name=name
if self.name in ['Porsche', 'Koenigsegg']:
self.num_of_doors = 2
else:
self.num_of_doors = 4
if self.vehicle_type == 'trailer':
self.num_of_wheels = 8
else:
self.num_of_wheels = 4
def is_saloon(self):
if self.vehicle_type is not 'trailer':
self.vehicle_type=='saloon'
return True
def drive_car(self, moving_speed):
if moving_speed == 3:
Car.speed = 1000
elif moving_speed == 7:
Car.speed = 77
return self
|
# Python Program To Find Square Of Elements In A List
'''
Function Name : Square Of Elements In A List.
Function Date : 8 Sep 2020
Function Author : Prasad Dangare
Input : Integer
Output : Integer
'''
def square(x):
return x*x
# Let Us Take A List Of Numbers
lst = [1,2,3,4,5]
# Call map() With Square() And lst
lst1 = list(map(square, lst))
print(lst1) |
class Solution(object):
def countAndSay(self, n):
"""
:type n: int
:rtype: str
"""
if n == 1:
return "1"
prev = self.countAndSay(n-1)
res = ""
ct = 1
for i in range(len(prev)):
if i == len(prev)-1 or prev[i] != prev[i+1]:
res += str(ct) + prev[i]
ct = 1
else:
ct += 1
return res |
n=int(input())
while True:
a=int(input())
if a is 0:
break
if a%n is 0:
print("{} is a multiple of {}.".format(a,n))
else:
print("{} is NOT a multiple of {}.".format(a,n)) |
"""
UB_ID : 50291708
Name : Md Moniruzzaman Monir
"""
class Rectangle:
# constructor
def __init__(self, x, y, width, height):
self.x = x
self.y = y
self.width = width
self.height = height
# Return the sum of all pixels inside a rectangle for a specific integral image
def compute_sum(self, integralImg, scale, x, y):
x = self.x
y = self.y
width = self.width
height = self.height
one = integralImg[y][x]
two = integralImg[y][x+width]
three = integralImg[y+height][x]
four = integralImg[y+height][x+width]
desiredSum = (one + four) - (two + three)
return desiredSum
|
n = int(input())
l = int(input())
for first in range(1, n):
for second in range(1, n):
for three in range(97, 97 + l):
for four in range(97, 97 + l):
for five in range(2, n + 1):
three_chr = chr(three)
four_chr = chr(four)
if five > first and five > second:
print(f'{first}{second}{three_chr}{four_chr}{five}', end=' ')
|
def extended_gcd(a, b):
if a == 0:
return (b, 0, 1)
g, y, x = extended_gcd(b % a, a)
return (g, x - (b // a) * y, y)
def modinv(a, m):
g, x, y = extended_gcd(a % m, m)
if g != 1:
raise Exception('Element has no inverse')
return x % m
|
"""some additional (math) types you may need, with instance checks"""
__all__ = ['NaturalNumber', 'StrictNaturalNumber']
class NaturalNumberMeta(type):
"""metaclass"""
def __instancecheck__(self, instance):
return isinstance(instance, int) and instance >= 0
class StrictNaturalNumberMeta(type):
"""metaclass"""
def __instancecheck__(self, instance):
return isinstance(instance, int) and instance >= 1
class NaturalNumber(metaclass=NaturalNumberMeta):
"""A natural number is any non-negative integer"""
pass
class StrictNaturalNumber(metaclass=StrictNaturalNumberMeta):
"""A strict natural number is any integer bigger than 0"""
pass
|
"""Exercise 1: Country Roads
Remember to fill out all the TODO's, you can quickly scan for them by pressing CTRL/CMD + F
"""
class Car:
"""A class representing a car with details about how far it can travel"""
def __init__(self, gas_tank_size, fuel, litres_per_kilometre):
self.gas_tank_size = gas_tank_size
self.fuel = fuel
self.litres_per_kilometre = litres_per_kilometre
def fill_up(self):
"""Fills up the car's Fuel"""
... # TODO: finish function
def drive(self, kilometres_driven):
"""Remove the amount of fuel, based on distance driven"""
... # TODO: finish function
def kilometres_available(self):
"""Return the number of kilometers that the car could drive with the current amount of fuel"""
... # TODO: Finish Function
# Code to test
c = Car(10,9,2)
print(c.kilometres_available())
c.drive(4)
print(c.kilometres_available())
c.fill_up()
print(c.kilometres_available)
|
def balanced(text: str):
stack = []
is_balanced = True
for i in range(len(text)):
if text[i] in "{[(":
stack.append(i)
elif text[i] in ")]}" and len(stack) > 0:
start_ind = stack.pop()
if text[start_ind] == "{":
if text[i] != "}":
is_balanced = False
break
elif text[start_ind] == "[":
if text[i] != "]":
is_balanced = False
break
elif text[start_ind] == "(":
if text[i] != ")":
is_balanced = False
break
else:
is_balanced = False
break
else:
is_balanced = False
break
if is_balanced and len(text) > 0 and len(stack) == 0:
print("YES")
else:
print("NO")
balanced(text=input())
|
'''
Esse script é um exercício de if e else.
'''
nota1 = float(input('Digite sua primeira nota: '))
nota2 = float(input('Digite a segunda: '))
media = (nota1 + nota2) / 2
if media < 4.9:
print('Reprovado/a')
print(f'Sua média é {media}')
elif media > 5 and media < 6.9:
print('Recuperação')
print(f'Sua média é {media}')
elif media == 10.0:
print('Parabéns')
print(f'Sua média é {media}')
else:
print('Aprovado/a')
print(f'Sua média é {media}')
print('final do programa')
|
def round_scores(student_scores):
'''
:param student_scores: list of student exam scores as float or int.
:return: list of student scores *rounded* to nearest integer value.
'''
rounded = []
while student_scores:
rounded.append(round(student_scores.pop()))
return rounded
def count_failed_students(student_scores):
'''
:param student_scores: list of integer student scores.
:return: integer count of student scores at or below 40.
'''
non_passing = 0
for score in student_scores:
if score <= 40:
non_passing += 1
return non_passing
def above_threshold(student_scores, threshold):
'''
:param student_scores: list of integer scores
:param threshold : integer
:return: list of integer scores that are at or above the "best" threshold.
'''
above = []
for score in student_scores:
if score >= threshold:
above.append(score)
return above
def letter_grades(highest):
'''
:param highest: integer of highest exam score.
:return: list of integer score thresholds for each F-A letter grades.
'''
increment = round((highest - 40)/4)
scores = []
for score in range(41, highest, increment):
scores.append(score)
return scores
def student_ranking(student_scores, student_names):
'''
:param student_scores: list of scores in descending order.
:param student_names: list of names in descending order by exam score.
:return: list of strings in format ["<rank>. <student name>: <score>"].
'''
results = []
for index, name in enumerate(student_names):
rank_string = str(index + 1) + ". " + name + ": " + str(student_scores[index])
results.append(rank_string)
return results
def perfect_score(student_info):
'''
:param student_info: list of [<student name>, <score>] lists
:return: First [<student name>, 100] found OR "No perfect score."
'''
result = "No perfect score."
for item in student_info:
if item[1] == 100:
result = item
break
return result
|
sections = {
# type descriptions / header blocks
"public": {
"name": "Public Routes",
"desc": """\
<p>These routes <b>DO NOT</b> require user authentication (though some of them
require a valid API key to use).</p>
<p> When building an application, use these routes to construct
dashboard type views and to look up game asset data that does not belong to any
user, such as Fighting Arts, Gear cards, etc.</p>""",
},
"private": {
'name': 'Private Routes',
'desc': """\
<p>Private routes require an Authorization header including a JWT token.</p>
<p>(See the documentation above for more info on how to <b>POST</b> user
credentials to the <code>/login</code> route to get a token.)</p>
<p>Generally speaking, when you access any private route, you want your headers
to look something like this:</p>
<code>
{
'content-type': 'application/json',
'Authorization': 'eyJhbGciOiJIUzI1NiIsInR5cCI6...'
}
</code>
<p>Finally, keep in mind that tokens are extremely short-lived, so you should be
prepared to refresh them frequently. See the section below on 'Authorization
Token Management' for more info on checking/refreshing tokens.</p>
<p><b>Important!</b> In order to support the CORS pre-flight checks that most
browsers are going to auto-magically perform before <b>POST</b>ing to one of
these routes, <u>all private routes supported by the KD:M API also support the
<code>OPTIONS</code> method</u>.</p>\
""",
},
# public routes
"user_creation_and_auth": {
"name": "User creation and auth",
"desc": (
"These public routes are how you want to create new users and "
"authenticate existing ones."
),
},
"password_reset": {
"name": "Password reset",
"desc": "Use these two routes to build a password reset mechanism.",
},
"user_collection_management": {
"name": "User collection management",
"desc": "The endpoints defined below are used to manage the User's IRL collection of game assets, e.g. expansions, etc.",
},
"ui_ux_helpers": {
"name": "UI/UX Helpers",
"desc": "These routes are intended to help with user experience by rapidly returning basic asset sets.",
},
"dashboard": {
"name": "Dashboard",
"desc": "The public endpoints here are meant to be used to create a dashboard or landing page type of view for users when they first sign in.",
},
"game_asset_lookups": {
"name": "Game asset lookup routes",
"desc": (
'<p>Use these endpoints to get information about game assets, e.g. '
'monsters, gear, expansions, etc.</p>'
'<p>Each of these routes works essentially the same way. You can '
'<b>POST</b> a query to one and retireve data about a single asset '
'if you know its name or handle -OR- you can <b>GET</b> the route '
'to get a dictionary of all assets.</p>'
'<p><b>PROTIP:</b> Use the <a href="/game_asset">/game_asset</a> '
'endpoint to get a list of available game asset types -OR- hit the '
'<a href="/kingdom_death">/kingdom_death</a> endpoint to dump a '
'JSON representation of every game asset that the API tracks.</p>'
),
},
# private routes
"authorization_token_management": {
"name": "Authorization token management",
"desc": """\
Once you've got an authorization token, you can work with it using these routes.
Most failures from these routes are reported back as 401's, since they concern
authorization.""",
},
"administrative_views_and_data":{
"name": "Administrative views and data",
"desc": "Administrative views and data:</b> If your user has the 'admin' attribute, i.e. they are an administrator of the API server, the user can hit these routes to retrieve data about application usage, etc. These endpoints are used primarily to construct the administrator's dashboard.",
},
"user_management": {
"name": "User management",
"desc": """\
All routes for working directly with a user follow a <code>/user/<action>/<user_id></code> convention. These routes are private and require authentication.
""",
},
"user_attribute_management": {
"name": "User attribute management (and updates)",
"desc": "These endpoints are used to update and modify individual webapp users.",
},
"user_collection_management": {
"name": "User Collection management",
"desc": "The endpoints defined in this section are used to manage the User's IRL collection of game assets, e.g. Expansions, etc."
},
"create_assets": {
"name": "Create assets",
"desc": "To create new assets (user, survivor, settlement), <b>POST</b> JSON containing appropriate params to the /new/<asset_type> route. Invalid or unrecognized params will be ignored!",
},
#
# settlement routes
#
"settlement_management": {
"name": "Settlement management",
"desc": """\
<p>All routes for working with a settlement follow the normal convention in the
KDM API for working with individual user assets, i.e.
<code>/settlement/<action>/<settlement_id></code></p>
<p>Many operations below require asset handles.</p>
<p>Asset handles may be found in the settlement's <code>game_assets</code>
element, which contains dictionaries and lists of assets that are
available to the settlement based on its campaign, expansions, etc.</p>
<p>Typical settlement JSON looks like this:</p>
<pre><code>
{
"user_assets": {...},
"meta": {...},
"sheet": {...},
"game_assets": {
"milestones_options": {...},
"campaign": {...},
"weapon_specializations": {...},
"locations": {...},
"innovations": {...},
"principles_options": {...},
"causes_of_death": {...},
"quarry_options": {...},
"nemesis_options": {...},
"eligible_parents": {...},
...
},
}
</code></pre>
<p><b>Important!</b> As indicated elsewhere in this documentation,
asset handles will never change. Asset names are subject to change,
and, while name-based lookup methods are supported by various routes,
using names instead of handles is not recommended.</p>
""",
},
"settlement_set_attribute": {
"name": "Attribtue set",
"desc": """Use the routes below to set a settlement's individual attributes, e.g. Name, Survival Limit, etc. to a specific value. <p>Attributes such as Survival Limit, Population and Death Count are more or less automatically managed by the API, but you may use the routes in this section to set them directly. Be advised that the API calculates "base" values for a number of numerical attributes and will typically set attributes to that base if you attempt to set them to a lower value.</p>""",
},
"settlement_update_attribute": {
"name": "Attribute update",
"desc": """Use the routes here to update and/or toggle individual settlement attributes. <p>Updating is different from setting, in that the update-type routes will add the value you <b>POST</b> to the current value, rather than just overwriting the value in the way a set-type route would.</p>""",
},
"settlement_component_gets": {
"name": "Component GET routes (sub-GETs)",
"desc": "The two heaviest elements of a settlement, from the perspectives of both the raw size of the JSON and how long it takes for the API server to put it together, are the event log and the settlement storage. These two endpoints allow you to get them separately, e.g. behind-the-scenes, on demand or only if necessary, etc.",
},
"settlement_manage_survivors": {
"name": "Bulk survivor management",
"desc": """These routes allow you to manage groups or types of survivors within the settlement.""",
},
"settlement_manage_expansions": {
"name": "Expansion content",
"desc": """The endpoints here all you to <b>POST</b> lists of expansion content handles to update the expansion content used in the settlement.""",
},
"settlement_manage_monsters": {
"name": "Monsters",
"desc": """These routes all allow you to do things with the settlement's various lists of monsters and monster-related attributes.""",
},
"settlement_manage_principles": {
"name": "Principles and Milestones",
"desc": """Routes for setting and unsetting princples and milestones.""",
},
"settlement_manage_locations": {
"name": "Locations",
"desc": """Routes for adding, removing and working with settlement locations.""",
},
"settlement_manage_innovations": {
"name": "Innovations",
"desc": """Routes for adding, removing and working with settlement innovations.""",
},
"settlement_manage_timeline": {
"name": "Timeline",
"desc": """<a id="timelineDataModel"></a> use these routes to manage the
settlement's timeline.
<p> Make sure you you are familiar with the data model for the timeline
(documented in the paragraphs below) before using these routes.</p>
<p>At the highest level, every settlement's <code>sheet.timeline</code>
element is a list of hashes, where each hash represents an individual
lantern year.</p>
<p>Within each Lantern Year, the keys's values are lists of events, except
for the <code>year</code> key, which is special because it is the only
key in the Lantern Year hash whose value is an integer, instead of a list.</p>
<p>The other keys in the hash, the ones whose values are lists of events,
have to be one of the following:
<ul class="embedded">
<li><code>settlement_event</code></li>
<li><code>story_event</code></li>
<li><code>special_showdown</code></li>
<li><code>nemesis_encounter</code></li>
<li><code>showdown_event</code></li>
</ul>
Individual events are themselves hashes. In the 1.2 revision of the
timeline data model, individual event hashes have a single key/value
pair: they either have a <code>handle</code> key, whose value is an
event handle (e.g. from the settlement JSON's <code>game_assets.events
</code> element) or a a <code>name</code> key, whose value is an
arbitrary string.</p>
<p>In generic terms, here is how a settlement's <code>
sheet.timeline</code> JSON is structured:</p>
<pre><code>
[
{
year: 0,
showdown_event: [{name: 'name'}],
story_event: [{handle: 'handle'}]
},
{year: 1, special_showdown: [{name: 'name'}], settlement_event: [{handle: 'handle'}]}
{year: 2, }
{year: 3, nemesis_encounter: [{name: 'name'}, {name: 'name'}], story_event: [{name: 'name'}, {handle: 'handle'}]}
...
]</code></pre>
<p><b>Important!</b> Individual Lantern Year hashes need not
contain any event list hashes, but they <u>absolutely must contain a
hash with the <code>year</code> key/value pair.</u></p>
<p>Any attempt to <b>POST</b> a Lantern Year without this 'magic'
key/value pair, will cause the API to throw an error.</p>
<p>Also, for now, the API does not enforce any normalization or business logic
for the timeline and individual event lists may contain as many
event hashes as necessary.</p>
<p>Finally, the API should <b>always</b> render the list of Lantern
Year hashes (i.e. <code>sheet.timeline</code> in "chronological"
order. If you get them back out of order, open a ticket.</p>
""",
},
"settlement_admin_permissions": {
"name": "Settlement administrators",
"desc": """Each settlement has at least one administrator who serves as
the primary owner/admin maintainer of the settlement. Each settlement
can have as many administrators as necessary. Use these endpoints to
add and remove admins from the lsit of settlement admins.""",
},
"settlement_notes_management": {
"name": "Settlement notes",
"desc": """Much like survivors, settlements can have notes appended to
(or removed from them). These are stored with a creation timestamp for
easy representation in chronological or reverse chron order. """,
},
#
# survivor management
#
"survivor_management": {
"name": "Survivor management",
"desc": (
"<p>Much like settlement management routes, survivor management "
"routes require the Authorization header and follow the "
"survivor / operation / OID convention, e.g. "
"<code>/survivor/add_note/5f2c78ae84d8860d89594fa8</code></p>"
"<p>For most of the endpoints here, in any JSON you <b>POST</b>, "
"you can include the the <code>serialize_on_response</code> key "
"with a Boolean 'true' value:</p>"
"""<pre><code>{
serialize_on_response: true,
whatever: other_stuff,
...
}</code></pre>"""
"<p>This will cause the route to return a serialized "
"representation of the survivor that is similar to what you would "
"get from the main <code>/survivor/get/<survivor_id> </code> "
"route, potentially allowing you to save some time and/or make "
"fewer calls to the API.</p>"
"<p>These routes are private and require authentication.</p>"
),
},
"survivor_sheet":{
"name": "Survivor Sheet",
"desc": (
"Endpoints documented here are allow a survivor's 'sheet' to "
"be managed."
),
},
"survivor_gear_management":{
"name": "Survivor gear",
"desc": (
"The API supports a basic set of methods for tracking "
"survivor gear. Typically this involves using gear handles (see "
"above) and adding them to lists or dictionaries on the survivor "
"record."
),
},
"survivor_notes_management":{
"name": "Survivor notes",
"desc": (
"Starting with the 1.14.92 release of the API survivor notes "
"are enhanced to allow for annotation (e.g. pinning, colors, "
"etc.) and an improved level of detail over their previous "
"functionality."
),
},
"survivor_admin":{
"name": "Survivor administration",
"desc": (
"In order to help facilitate 'quality of life' type features, "
"the API supports a handful of endpoints that allow users to "
"manager survivors by tagging them and setting various "
"non-game-related attributes that can be used for sorting, etc."
),
},
"survivor_relationships":{
"name": "Survivor relationships",
"desc": (
"For purposes of tracking certain types of game assets as well "
"as non-game 'meta' type data, the API supports a couple of "
"endpoints that allow survivors to be linked, typically by adding "
"each other's OIDs to their own records."
),
},
}
|
#使用 else 子句比把所有的语句都放在 try 子句里面要好,这样可以避免一些意想不到的、而except又没有捕获的异常。
while True:
try:
x = int(input("please input a number: "))
print('1 Good! Right number!')
# break
except ValueError as e: # if the exception is not ValueError, then it's passed to the higher layer
print("oops! it's not a valid number, please try again")
print("oops 2! ", e.with_traceback)
raise # 自己的异常处理完毕后,继续抛给最高层
else:
print('2 Good! Right number!')
break
finally:
print("finally executing ....") # 无论如何最后都要处理的,Finally |
def is_prime(n):
if n % 2 == 0:
return n == 2
d = 3
while d * d <= n and n % d != 0:
d += 2
return d * d > n
def main():
n = int(input("Input the number from 0 to 1000: "))
print(is_prime(n))
if __name__ == '__main__':
main()
|
class Node:
def __init__(self, value = 0):
self.value = value
self.next = None
def findList(first, second):
if not first and not second:
return True
if not first or not second:
return False
ptr1 = first
ptr2 = second
while ptr2:
ptr2 = second
while ptr1:
if not ptr2:
return False
elif ptr1.value == ptr2.value:
ptr1 = ptr1.next
ptr2 = ptr2.next
else:
break
if not ptr1:
return True
ptr1 = first
second = second.next
return False
node_a = Node(1)
node_a.next = Node(2)
node_a.next.next = Node(3)
node_a.next.next.next = Node(4)
node_b = Node(1)
node_b.next = Node(2)
node_b.next.next = Node(1)
node_b.next.next.next = Node(2)
node_b.next.next.next.next = Node(3)
node_b.next.next.next.next.next = Node(4)
if findList(node_a, node_b):
print("LIST FOUND")
else:
print("LIST NOT FOUND")
|
def sequencia():
s = 0
for i in range(1, 101):
s += 1/i
print(f'{s:.2f}')
sequencia()
|
def main_menu():
print("Please select an option from the following:")
print(" [1] Customer") #add to db
print(" [2] Order")# add to db
print(" [3] Complete Order")
print(" [4] Cancel Order")
print(" [5] Exit")
def sign_up_menu():
print("Please select an option from the following:")
print(" [1] Scan Code") #add to db
print(" [2] return to previous menu")# add to db |
"""
Descrição: Este programa calcula o número e o valor das prestações a pagar em um imóvel.
Autor:Henrique Joner
Versão:0.0.1
Data:24/11/2018
"""
#Inicialização de variáveis
valorcasa = 0
anos = 0
nprestacao = 0
prestacao = 0
salario = 0
#Entrada de dados
valorcasa = float(input("Qual o valor da casa que você deseja adquirir? "))
anos = int(input("Deseja pagar em quantos anos? "))
salario = float(input("Qual seu salário atual? "))
#Processamento de dados
nprestacao = anos * 12
prestacao = valorcasa / nprestacao
if prestacao <= salario * 0.3:
print("Você terá de pagar %d vezes de R$%5.2f !" % (nprestacao, prestacao))
else:
print("Infelizmente sua renda não é compatível com a aquisição que você deseja realizar!")
#Saída de dados
|
x = float(input('x = '))
if x > 1:
y = 3 * x - 5
elif x >= -1:
y = x + 2
else:
y = 5 * x + 3
print('f(%.2f) = %.2f' % (x, y))
print(range(10))
|
def selectionsort(arr):
N = len(arr)
for i in range(N):
minimum = i
for j in range(1, N):
if arr[j] < arr[minimum]:
minimum = j
arr[minimum], arr[i] = arr[i], arr[minimum]
return arr
if __name__ == "__main__":
arr = [0, 4, 5, 6, 7, 8, 2, 1, 5, 3, 9]
print(selectionsort(arr))
|
class Person:
def __init__(self, name, age):
self.x__name = name
self.age = age
def info(self):
return f'Name: {self.x__name}, Age: {self.age}'
def __generate_key(self, key):
if key.startswith('x__'):
return f'x__Person{key}'
return key
def __setattr__(self, key, value):
super().__setattr__(self.__generate_key(key), value)
def __getattr__(self, item):
return super().__getattribute__(self.__generate_key(item))
p = Person('Gosho', 11)
print(p.__dict__)
print(p.info())
#
# print(hasattr(p, 'name'))
# print(hasattr(p, 'name2'))
#
# while True:
# attr_name = input()
# attr = getattr(p, attr_name, -7)
# if hasattr(attr, '__call__'):
# print(attr())
# else:
# print(attr)
|
class Solution:
def shiftingLetters(self, S: str, shifts: List[int]) -> str:
"""String.
Running time: O(n) where n == len(shifts).
"""
orda = ord('a')
n = len(shifts)
suf = shifts
suf[-1] %= 26
for i in range(n - 2, -1, -1):
suf[i] = (suf[i] + suf[i+1]) % 26
res = [''] * n
for i in range(n):
res[i] = chr(orda + (ord(S[i]) - orda + suf[i]) % 26)
return ''.join(res)
|
useragents = [
"Mozilla/5.0 (Windows NT 6.1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/41.0.2228.0 Safari/537.36",
"Mozilla/5.0 (Macintosh; Intel Mac OS X 10_10_1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/41.0.2227.1 Safari/537.36",
"Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/41.0.2227.0 Safari/537.36",
"Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/41.0.2227.0 Safari/537.36",
"Mozilla/5.0 (Windows NT 6.3; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/41.0.2226.0 Safari/537.36",
"Mozilla/5.0 (Windows NT 6.4; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/41.0.2225.0 Safari/537.36",
"Mozilla/5.0 (Windows NT 6.3; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/41.0.2225.0 Safari/537.36",
"Mozilla/5.0 (Windows NT 5.1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/41.0.2224.3 Safari/537.36",
"Mozilla/5.0 (Windows NT 10.0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/40.0.2214.93 Safari/537.36",
"Mozilla/5.0 (Macintosh; Intel Mac OS X 10_10_1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/37.0.2062.124 Safari/537.36",
"Mozilla/5.0 (Windows NT 6.3; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/37.0.2049.0 Safari/537.36",
"Mozilla/5.0 (Windows NT 4.0; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/37.0.2049.0 Safari/537.36",
"Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/36.0.1985.67 Safari/537.36",
"Mozilla/5.0 (Windows NT 5.1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/36.0.1985.67 Safari/537.36",
"Mozilla/5.0 (X11; OpenBSD i386) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/36.0.1985.125 Safari/537.36",
"Mozilla/5.0 (Macintosh; Intel Mac OS X 10_9_2) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/36.0.1944.0 Safari/537.36",
"Mozilla/5.0 (Windows NT 5.1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/35.0.3319.102 Safari/537.36",
"Mozilla/5.0 (Windows NT 5.1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/35.0.2309.372 Safari/537.36",
"Mozilla/5.0 (Windows NT 5.1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/35.0.2117.157 Safari/537.36",
"Mozilla/5.0 (Macintosh; Intel Mac OS X 10_9_3) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/35.0.1916.47 Safari/537.36",
"Mozilla/5.0 (Windows NT 5.1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/34.0.1866.237 Safari/537.36",
"Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/34.0.1847.137 Safari/4E423F",
"Mozilla/5.0 (Windows NT 5.1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/34.0.1847.116 Safari/537.36 Mozilla/5.0 (iPad; U; CPU OS 3_2 like Mac OS X; en-us) AppleWebKit/531.21.10 (KHTML, like Gecko) Version/4.0.4 Mobile/7B334b Safari/531.21.10",
"Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/33.0.1750.517 Safari/537.36",
"Mozilla/5.0 (Windows NT 6.2; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/32.0.1667.0 Safari/537.36",
"Mozilla/5.0 (Macintosh; Intel Mac OS X 10_9_0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/32.0.1664.3 Safari/537.36",
"Mozilla/5.0 (Macintosh; Intel Mac OS X 10_8_0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/32.0.1664.3 Safari/537.36",
"Mozilla/5.0 (Windows NT 5.1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/31.0.1650.16 Safari/537.36",
"Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/31.0.1623.0 Safari/537.36",
"Mozilla/5.0 (Windows NT 6.2; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/30.0.1599.17 Safari/537.36",
"Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/29.0.1547.62 Safari/537.36",
"Mozilla/5.0 (X11; CrOS i686 4319.74.0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/29.0.1547.57 Safari/537.36",
"Mozilla/5.0 (Windows NT 6.2; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/29.0.1547.2 Safari/537.36",
"Mozilla/5.0 (Windows NT 6.1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/28.0.1468.0 Safari/537.36",
"Mozilla/5.0 (Windows NT 6.2) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/28.0.1467.0 Safari/537.36",
"Mozilla/5.0 (Windows NT 6.2) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/28.0.1464.0 Safari/537.36",
"Mozilla/5.0 (Windows NT 6.2; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/27.0.1500.55 Safari/537.36",
"Mozilla/5.0 (Windows NT 6.2; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/27.0.1453.93 Safari/537.36",
"Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/27.0.1453.93 Safari/537.36",
"Mozilla/5.0 (Windows NT 6.1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/27.0.1453.93 Safari/537.36",
"Mozilla/5.0 (Windows NT 5.1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/27.0.1453.93 Safari/537.36",
"Mozilla/5.0 (Macintosh; Intel Mac OS X 10_8_3) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/27.0.1453.93 Safari/537.36",
"Mozilla/5.0 (Macintosh; Intel Mac OS X 10_7_5) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/27.0.1453.93 Safari/537.36",
"Mozilla/5.0 (Windows NT 6.1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/27.0.1453.90 Safari/537.36",
"Mozilla/5.0 (X11; NetBSD) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/27.0.1453.116 Safari/537.36",
"Mozilla/5.0 (X11; CrOS i686 3912.101.0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/27.0.1453.116 Safari/537.36",
"Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.17 (KHTML, like Gecko) Chrome/24.0.1312.60 Safari/537.17",
"Mozilla/5.0 (Macintosh; Intel Mac OS X 10_8_2) AppleWebKit/537.17 (KHTML, like Gecko) Chrome/24.0.1309.0 Safari/537.17",
"Mozilla/5.0 (Windows NT 6.2; WOW64) AppleWebKit/537.15 (KHTML, like Gecko) Chrome/24.0.1295.0 Safari/537.15",
"Mozilla/5.0 (Windows NT 6.2; WOW64) AppleWebKit/537.14 (KHTML, like Gecko) Chrome/24.0.1292.0 Safari/537.14"
"Mozilla/5.0 (Windows NT 6.1; WOW64; rv:40.0) Gecko/20100101 Firefox/40.1",
"Mozilla/5.0 (Windows NT 6.3; rv:36.0) Gecko/20100101 Firefox/36.0",
"Mozilla/5.0 (Macintosh; Intel Mac OS X 10_10; rv:33.0) Gecko/20100101 Firefox/33.0",
"Mozilla/5.0 (X11; Linux i586; rv:31.0) Gecko/20100101 Firefox/31.0",
"Mozilla/5.0 (Windows NT 6.1; WOW64; rv:31.0) Gecko/20130401 Firefox/31.0",
"Mozilla/5.0 (Windows NT 5.1; rv:31.0) Gecko/20100101 Firefox/31.0",
"Mozilla/5.0 (Windows NT 6.1; WOW64; rv:29.0) Gecko/20120101 Firefox/29.0",
"Mozilla/5.0 (Windows NT 6.1; Win64; x64; rv:25.0) Gecko/20100101 Firefox/29.0",
"Mozilla/5.0 (X11; OpenBSD amd64; rv:28.0) Gecko/20100101 Firefox/28.0",
"Mozilla/5.0 (X11; Linux x86_64; rv:28.0) Gecko/20100101 Firefox/28.0",
"Mozilla/5.0 (Windows NT 6.1; rv:27.3) Gecko/20130101 Firefox/27.3",
"Mozilla/5.0 (Windows NT 6.2; Win64; x64; rv:27.0) Gecko/20121011 Firefox/27.0",
"Mozilla/5.0 (Windows NT 6.1; Win64; x64; rv:25.0) Gecko/20100101 Firefox/25.0",
"Mozilla/5.0 (Macintosh; Intel Mac OS X 10.6; rv:25.0) Gecko/20100101 Firefox/25.0",
"Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:24.0) Gecko/20100101 Firefox/24.0",
"Mozilla/5.0 (Windows NT 6.0; WOW64; rv:24.0) Gecko/20100101 Firefox/24.0",
"Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:24.0) Gecko/20100101 Firefox/24.0",
"Mozilla/5.0 (Windows NT 6.2; rv:22.0) Gecko/20130405 Firefox/23.0",
"Mozilla/5.0 (Windows NT 6.1; WOW64; rv:23.0) Gecko/20130406 Firefox/23.0",
"Mozilla/5.0 (Windows NT 6.1; Win64; x64; rv:23.0) Gecko/20131011 Firefox/23.0",
"Mozilla/5.0 (Windows NT 6.2; rv:22.0) Gecko/20130405 Firefox/22.0",
"Mozilla/5.0 (Windows NT 6.1; Win64; x64; rv:22.0) Gecko/20130328 Firefox/22.0",
"Mozilla/5.0 (Windows NT 6.1; rv:22.0) Gecko/20130405 Firefox/22.0",
"Mozilla/5.0 (Microsoft Windows NT 6.2.9200.0); rv:22.0) Gecko/20130405 Firefox/22.0",
"Mozilla/5.0 (Windows NT 6.2; Win64; x64; rv:16.0.1) Gecko/20121011 Firefox/21.0.1",
"Mozilla/5.0 (Windows NT 6.1; Win64; x64; rv:16.0.1) Gecko/20121011 Firefox/21.0.1",
"Mozilla/5.0 (Windows NT 6.2; Win64; x64; rv:21.0.0) Gecko/20121011 Firefox/21.0.0",
"Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:21.0) Gecko/20130331 Firefox/21.0",
"Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:21.0) Gecko/20100101 Firefox/21.0",
"Mozilla/5.0 (X11; Linux i686; rv:21.0) Gecko/20100101 Firefox/21.0",
"Mozilla/5.0 (Windows NT 6.2; WOW64; rv:21.0) Gecko/20130514 Firefox/21.0",
"Mozilla/5.0 (Windows NT 6.2; rv:21.0) Gecko/20130326 Firefox/21.0",
"Mozilla/5.0 (Windows NT 6.1; WOW64; rv:21.0) Gecko/20130401 Firefox/21.0",
"Mozilla/5.0 (Windows NT 6.1; WOW64; rv:21.0) Gecko/20130331 Firefox/21.0",
"Mozilla/5.0 (Windows NT 6.1; WOW64; rv:21.0) Gecko/20130330 Firefox/21.0",
"Mozilla/5.0 (Windows NT 6.1; WOW64; rv:21.0) Gecko/20100101 Firefox/21.0",
"Mozilla/5.0 (Windows NT 6.1; rv:21.0) Gecko/20130401 Firefox/21.0",
"Mozilla/5.0 (Windows NT 6.1; rv:21.0) Gecko/20130328 Firefox/21.0",
"Mozilla/5.0 (Windows NT 6.1; rv:21.0) Gecko/20100101 Firefox/21.0",
"Mozilla/5.0 (Windows NT 5.1; rv:21.0) Gecko/20130401 Firefox/21.0",
"Mozilla/5.0 (Windows NT 5.1; rv:21.0) Gecko/20130331 Firefox/21.0",
"Mozilla/5.0 (Windows NT 5.1; rv:21.0) Gecko/20100101 Firefox/21.0",
"Mozilla/5.0 (Windows NT 5.0; rv:21.0) Gecko/20100101 Firefox/21.0",
"Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:21.0) Gecko/20100101 Firefox/21.0",
"Mozilla/5.0 (Windows NT 6.2; Win64; x64;) Gecko/20100101 Firefox/20.0",
"Mozilla/5.0 (Windows x86; rv:19.0) Gecko/20100101 Firefox/19.0",
"Mozilla/5.0 (Windows NT 6.1; rv:6.0) Gecko/20100101 Firefox/19.0",
"Mozilla/5.0 (Windows NT 6.1; rv:14.0) Gecko/20100101 Firefox/18.0.1",
"Mozilla/5.0 (Windows NT 6.1; WOW64; rv:18.0) Gecko/20100101 Firefox/18.0",
"Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:17.0) Gecko/20100101 Firefox/17.0.6"
]
|
def exists(env):
return True
def generate(env):
env.Replace(MODE='test')
|
class Solution:
def XXX(self, x: int) -> int:
s = str(x)
s = "-" + s.replace("-","")[::-1] if "-" in s else s[::-1]
return (int(s) if int(s)<2**31-1 and int(s)>-2**31 else 0)
|
# invert a binary tree
def reverse(root):
if not root:
return
root.left, root.right = root.right, root.left
if root.left:
reverse(root.left)
if root.right:
reverse(root.right)
|
for _ in range(int(input())):
n = int(input())
l = list(map(int, input().split(' ')))
ans = 0
for i in range(n):
ans += (i + 1) * (n - i)
if l[i] == 0:
ans += (i + 1) * (n - i)
print(ans)
|
#-*- coding:utf-8 -*-
age = [3, 2, 30, 1, 16, 18, 19, 20, 22, 25]
name = ['lizi', 'liudehua', 'linjunjie', 'zhoujielun', 'zhangsan', 'bigmom', 'kaiduo', 'luffe']
print(age)
print(sorted(age))
print(age)
age.sort()
print(age)
age.append(33)
print(age)
age.insert(2, 65)
print(age)
age.pop()
print(age)
_del = age.pop()
print(_del)
print(age)
del age[0:2]
print(age)
age.remove(22)
print(age)
print(sorted(name))
print(name)
name.sort()
print(name)
name.sort(reverse=False)
print(age)
name.reverse()
print(name) |
class DatabaseService:
def __init__(self):
#TODO: mongo
pass |
class OddNumberException(Exception):
def __init__(self,*args):
self.args = args
class EvenNumberException(Exception):
def __init__(self,*args):
self.args = args
try:
n = int(input("Enter a Number to check whether he number is odd or even : "))
if n % 2 == 0:
raise EvenNumberException("%d is a Even Number!!."%n)
else:
raise OddNumberException("%d is a Odd Number!!."%n)
except EvenNumberException as r:
print(r)
except OddNumberException as r:
print(r)
|
EXTERN_START = "\n#ifdef __cplusplus\nextern \"C\" {\n#endif\n\n"
EXTERN_STOP = "#ifdef __cplusplus\n}\n#endif\n\n"
EXTERN_FIND1 = "extern \"C\" {\n"
EXTERN_FIND2 = " *****************************************************************************/\n" # noqa
def add_extern_c(source_file, source):
"""
Add 'Extern C' to a given source_file.
"""
# Patches only work with newline versions of the file.
if "\r\n" in source:
raise Exception(
"You need to convert all Gecko SDK sources to Linux file endings "
"first (use something like dos2unix).")
# Don't add it if file already contains it.
if EXTERN_FIND1 in source:
return source
# Dirty hack by looking for a string, but it works.
offset = source.index(EXTERN_FIND2) + len(EXTERN_FIND2)
part_one = source[:offset]
part_two = source[offset:]
return part_one + EXTERN_START + part_two + EXTERN_STOP
def fix_arm_math(source_file, source):
"""
Add conditional for ARM_MATH_CM definition. It is already defined by the
Cortex definitions of RIOT-OS.
"""
return source.replace(
"#define ARM_MATH_CM0PLUS",
"#ifndef ARM_MATH_CM0PLUS\n#define ARM_MATH_CM0PLUS\n#endif")
|
"""
This is boin default hyper parameters.
"""
model_name = 'BoinAutoEncoder'
lr = 0.001
max_view_num = 500
view_interval = 100
class encoder_hparams:
model_name = 'BoinEncoder'
nhid = 512
nlayers = 2
class decoder_hparams:
model_name = 'BoinDecoder'
nhid = 512
nlayers = 2
|
"""
Matrix exercise
"""
class Matrix:
"""
Matrix class
"""
def __init__(self, matrix_string):
"""
Create a matrix
"""
self.rows = []
self.columns = [[] for i in range(len(matrix_string.split("\n")[0].split()))]
for line in matrix_string.split("\n"):
items = list(map(int, line.split(" ")))
self.rows.append(items)
for index, value in enumerate(items):
self.columns[index].append(value)
def row(self, index):
"""
Return a row by index
"""
return self.rows[index - 1]
def column(self, index):
"""
Return a column by index
"""
return self.columns[index - 1]
|
def filter_db_queryset_by_id(db_queryset, rqst_id, list_of_ids):
if isinstance(rqst_id, str) and rqst_id.lower() == "all":
db_queryset = db_queryset.order_by("id")
else:
db_queryset = db_queryset.filter(id__in=list_of_ids).order_by("id")
return db_queryset
|
"""
w04 team assignment : Date.py
day : int
month : int
year : int
__init__()
prompt()
display()
"""
class Date:
""" the date class """
def __init__(self, date_day=1, date_month=1, date_year=2000):
# set up the class variables and assign default values
self.day = date_day
self.month = date_month
self.year = date_year
def prompt(self):
""" ask for a day, month, and year value """
self.day = int(input('Day: '))
# reset month value, if the user doesn't give a vaild month, then ask again
self.month = 0
while self.month < 1 or self.month > 12:
self.month = int(input('Month: '))
# reset year value, if the user doesn't give a vaild year, assk again
self.year = 1999
while year < 2000:
self.year = int(input('Year: '))
def display(self):
""" print out the date in mm/dd/yyyy format """
# remove the :02d to remove leading zeroes, for example 05/09/2021 --> 5/9/2021
print(f'{self.month:02d}/{self.day:02d}/{self.year}')
|
tabela = ('Fortaleza', 'Athletico-PR', 'Flamengo', 'Atlético-GO', 'Atlético-MG', 'Bragantino', 'Fluminense', 'Bahia',
'Palmeiras', 'Corinthians', 'Ceará SC', 'Santos', 'Internacional', 'Juventude', 'Cuiabá', 'Sport Recife',
'São Paulo', 'Chapecoense', 'Grêmio', 'América-MG')
linha = '-=-' * 98
print(linha)
print(f'Lista de times: {tabela}')
print(linha)
print(f'Os 5 primeiros colocados são: {tabela[:5]}')
print(linha)
print(f'Os 4 últimos colocados são: {tabela[-4:]}')
print(linha)
print(f'Times em ordem alfabética: {sorted(tabela)}')
print(linha)
print(f'O Chapecoense está na {tabela.index("Chapecoense") + 1}ª posição')
print(linha)
|
"""
1. Create a inheritance tree with the following structure
1. BaseCharacter
1. Non-Playable Character(NPC)
1. Friendly
2. Enemy
2. Playable Character(PC)
1. Archer
2. Green Lantern
3. Butcher
2. Add 'printName' function All characters have
3. Add 'self.attackDamage = 5' attr for all enemies
4. Create weapon class within same file
5. Have all PC characters start with a weapon
"""
class BaseCharacter(object):
def printName(self):
print (self.name)
class NonPlayableCharacter(BaseCharacter):
pass
class NPCFriendly(NonPlayableCharacter):
pass
class NPCEnemy(NonPlayableCharacter):
def __init__(self):
self.attackDamage = 5
class Weapon(object):
pass
class PlayableCharacter(BaseCharacter):
def __init__(self):
self.weapon = Weapon()
class PCArcher(PlayableCharacter):
pass
class PCGreenLantern(PlayableCharacter):
pass
class PCButcher(PlayableCharacter):
pass
if __name__ == '__main__':
enemy = NPCEnemy()
print (enemy.attackDamage)
butcher = PCButcher()
print (butcher.weapon)
|
class Dij:
# matrix of roads
road = [[]]
# infinity
infinit = 9999
# array of costs
D = []
# array of selected nodes
S = []
# array of fathers
T = []
# number of nodes
nodes = -1
# output
output = []
def __init__(self, start):
self.readGraph()
self.r = start
r = self.r
self.S[r] = 1
for j in range(1, self.nodes + 1):
self.D[j] = self.road[r][j]
for j in range(1, self.nodes + 1):
if self.D[j]:
self.T[j] = r
for i in range(1, self.nodes):
min = 9999
for j in range(1, self.nodes + 1):
if self.S[j] == 0:
if self.D[j] < min:
min = self.D[j]
pos = j
self.S[pos] = 1
for j in range(1, self.nodes + 1):
if self.S[j] == 0:
if self.D[j] > self.D[pos] + self.road[pos][j]:
self.D[j] = self.D[pos] + self.road[pos][j]
self.T[j] = pos
f = open('road.out', 'w')
for k in range(1, self.nodes + 1):
if k is not r:
if self.T[k]:
print
"Road from ", r, " to ", k
self.draw(k)
print
self.output
f.write("Road from {} to {} => {}".format(r, k, str(self.output)))
f.write("\n")
self.output = []
else:
print
"There is not exists road"
f.close()
def draw(self, node):
if self.T[node]:
self.draw(self.T[node])
print
node
self.output.append(node)
def readGraph(self):
counter = 0
input = []
with open('example.txt', 'r') as file:
for a_line in file:
counter += 1
if counter == 1:
number_of_nodes = int(a_line.rstrip())
else:
input.append(a_line.rstrip())
size = len(input)
self.nodes = number_of_nodes
self.road = [[0 for i in range(0, number_of_nodes + 1)] for j in range(0, number_of_nodes + 1)]
for i in range(0, self.nodes + 1):
for j in range(0, self.nodes + 1):
if i == j:
self.road[i][j] = 0
else:
self.road[i][j] = self.infinit
for i in range(0, size):
component = input[i]
node1 = int(component[0])
node2 = int(component[2])
cost = int(component[4])
self.road[node1][node2] = cost
# init
self.D = [0] * (number_of_nodes + 1)
self.S = [0] * (number_of_nodes + 1)
self.T = [0] * (number_of_nodes + 1)
ob = Dij(2) |
"""Mappings.
Mappings define how internal objects and their fields will be indexed.
The provided record-v1.0.0.json file is an example of how to index records
in Elasticsearch.
"""
|
n, k = (int(x) for x in input().split())
arr = [int(x) for x in input().split()]
new_arr = list()
i = 0
while i != n - k + 1:
new_arr.append(max(arr[i:i+k]))
i += 1
print(*new_arr) |
#
# PySNMP MIB module Nortel-Magellan-Passport-SoftwareMIB (http://snmplabs.com/pysmi)
# ASN.1 source file:///Users/davwang4/Dev/mibs.snmplabs.com/asn1/Nortel-Magellan-Passport-SoftwareMIB
# Produced by pysmi-0.3.4 at Mon Apr 29 20:18:50 2019
# On host DAVWANG4-M-1475 platform Darwin version 18.5.0 by user davwang4
# Using Python version 3.7.3 (default, Mar 27 2019, 09:23:15)
#
ObjectIdentifier, Integer, OctetString = mibBuilder.importSymbols("ASN1", "ObjectIdentifier", "Integer", "OctetString")
NamedValues, = mibBuilder.importSymbols("ASN1-ENUMERATION", "NamedValues")
ConstraintsUnion, SingleValueConstraint, ValueSizeConstraint, ConstraintsIntersection, ValueRangeConstraint = mibBuilder.importSymbols("ASN1-REFINEMENT", "ConstraintsUnion", "SingleValueConstraint", "ValueSizeConstraint", "ConstraintsIntersection", "ValueRangeConstraint")
DisplayString, Unsigned32, RowStatus, StorageType = mibBuilder.importSymbols("Nortel-Magellan-Passport-StandardTextualConventionsMIB", "DisplayString", "Unsigned32", "RowStatus", "StorageType")
AsciiStringIndex, Link, AsciiString, NonReplicated = mibBuilder.importSymbols("Nortel-Magellan-Passport-TextualConventionsMIB", "AsciiStringIndex", "Link", "AsciiString", "NonReplicated")
components, passportMIBs = mibBuilder.importSymbols("Nortel-Magellan-Passport-UsefulDefinitionsMIB", "components", "passportMIBs")
NotificationGroup, ModuleCompliance = mibBuilder.importSymbols("SNMPv2-CONF", "NotificationGroup", "ModuleCompliance")
iso, ModuleIdentity, IpAddress, Unsigned32, ObjectIdentity, MibIdentifier, TimeTicks, NotificationType, Counter32, MibScalar, MibTable, MibTableRow, MibTableColumn, Counter64, Integer32, Gauge32, Bits = mibBuilder.importSymbols("SNMPv2-SMI", "iso", "ModuleIdentity", "IpAddress", "Unsigned32", "ObjectIdentity", "MibIdentifier", "TimeTicks", "NotificationType", "Counter32", "MibScalar", "MibTable", "MibTableRow", "MibTableColumn", "Counter64", "Integer32", "Gauge32", "Bits")
TextualConvention, DisplayString = mibBuilder.importSymbols("SNMPv2-TC", "TextualConvention", "DisplayString")
softwareMIB = MibIdentifier((1, 3, 6, 1, 4, 1, 562, 2, 4, 2, 17))
sw = MibIdentifier((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14))
swRowStatusTable = MibTable((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 1), )
if mibBuilder.loadTexts: swRowStatusTable.setStatus('mandatory')
swRowStatusEntry = MibTableRow((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 1, 1), ).setIndexNames((0, "Nortel-Magellan-Passport-SoftwareMIB", "swIndex"))
if mibBuilder.loadTexts: swRowStatusEntry.setStatus('mandatory')
swRowStatus = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 1, 1, 1), RowStatus()).setMaxAccess("readonly")
if mibBuilder.loadTexts: swRowStatus.setStatus('mandatory')
swComponentName = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 1, 1, 2), DisplayString()).setMaxAccess("readonly")
if mibBuilder.loadTexts: swComponentName.setStatus('mandatory')
swStorageType = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 1, 1, 4), StorageType()).setMaxAccess("readonly")
if mibBuilder.loadTexts: swStorageType.setStatus('mandatory')
swIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 1, 1, 10), NonReplicated())
if mibBuilder.loadTexts: swIndex.setStatus('mandatory')
swOperTable = MibTable((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 11), )
if mibBuilder.loadTexts: swOperTable.setStatus('mandatory')
swOperEntry = MibTableRow((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 11, 1), ).setIndexNames((0, "Nortel-Magellan-Passport-SoftwareMIB", "swIndex"))
if mibBuilder.loadTexts: swOperEntry.setStatus('mandatory')
swTidyStatus = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 11, 1, 1), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(0, 1, 2))).clone(namedValues=NamedValues(("inactive", 0), ("inProgress", 1), ("querying", 2)))).setMaxAccess("readonly")
if mibBuilder.loadTexts: swTidyStatus.setStatus('mandatory')
swAvBeingTidied = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 11, 1, 421), AsciiString().subtype(subtypeSpec=ValueSizeConstraint(1, 30))).setMaxAccess("readonly")
if mibBuilder.loadTexts: swAvBeingTidied.setStatus('mandatory')
swAvlTable = MibTable((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 256), )
if mibBuilder.loadTexts: swAvlTable.setStatus('mandatory')
swAvlEntry = MibTableRow((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 256, 1), ).setIndexNames((0, "Nortel-Magellan-Passport-SoftwareMIB", "swIndex"), (0, "Nortel-Magellan-Passport-SoftwareMIB", "swAvlValue"))
if mibBuilder.loadTexts: swAvlEntry.setStatus('mandatory')
swAvlValue = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 256, 1, 1), AsciiString().subtype(subtypeSpec=ValueSizeConstraint(1, 30))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: swAvlValue.setStatus('mandatory')
swAvlRowStatus = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 256, 1, 2), RowStatus()).setMaxAccess("writeonly")
if mibBuilder.loadTexts: swAvlRowStatus.setStatus('mandatory')
swAvListToTidyTable = MibTable((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 422), )
if mibBuilder.loadTexts: swAvListToTidyTable.setStatus('mandatory')
swAvListToTidyEntry = MibTableRow((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 422, 1), ).setIndexNames((0, "Nortel-Magellan-Passport-SoftwareMIB", "swIndex"), (0, "Nortel-Magellan-Passport-SoftwareMIB", "swAvListToTidyValue"))
if mibBuilder.loadTexts: swAvListToTidyEntry.setStatus('mandatory')
swAvListToTidyValue = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 422, 1, 1), AsciiString().subtype(subtypeSpec=ValueSizeConstraint(1, 30))).setMaxAccess("readonly")
if mibBuilder.loadTexts: swAvListToTidyValue.setStatus('mandatory')
swAvListTidiedTable = MibTable((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 423), )
if mibBuilder.loadTexts: swAvListTidiedTable.setStatus('mandatory')
swAvListTidiedEntry = MibTableRow((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 423, 1), ).setIndexNames((0, "Nortel-Magellan-Passport-SoftwareMIB", "swIndex"), (0, "Nortel-Magellan-Passport-SoftwareMIB", "swAvListTidiedValue"))
if mibBuilder.loadTexts: swAvListTidiedEntry.setStatus('mandatory')
swAvListTidiedValue = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 423, 1, 1), AsciiString().subtype(subtypeSpec=ValueSizeConstraint(1, 30))).setMaxAccess("readonly")
if mibBuilder.loadTexts: swAvListTidiedValue.setStatus('mandatory')
swPatlTable = MibTable((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 436), )
if mibBuilder.loadTexts: swPatlTable.setStatus('mandatory')
swPatlEntry = MibTableRow((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 436, 1), ).setIndexNames((0, "Nortel-Magellan-Passport-SoftwareMIB", "swIndex"), (0, "Nortel-Magellan-Passport-SoftwareMIB", "swPatlValue"))
if mibBuilder.loadTexts: swPatlEntry.setStatus('mandatory')
swPatlValue = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 436, 1, 1), AsciiString().subtype(subtypeSpec=ValueSizeConstraint(1, 30))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: swPatlValue.setStatus('mandatory')
swPatlRowStatus = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 436, 1, 2), RowStatus()).setMaxAccess("writeonly")
if mibBuilder.loadTexts: swPatlRowStatus.setStatus('mandatory')
swDld = MibIdentifier((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 2))
swDldRowStatusTable = MibTable((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 2, 1), )
if mibBuilder.loadTexts: swDldRowStatusTable.setStatus('mandatory')
swDldRowStatusEntry = MibTableRow((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 2, 1, 1), ).setIndexNames((0, "Nortel-Magellan-Passport-SoftwareMIB", "swIndex"), (0, "Nortel-Magellan-Passport-SoftwareMIB", "swDldIndex"))
if mibBuilder.loadTexts: swDldRowStatusEntry.setStatus('mandatory')
swDldRowStatus = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 2, 1, 1, 1), RowStatus()).setMaxAccess("readonly")
if mibBuilder.loadTexts: swDldRowStatus.setStatus('mandatory')
swDldComponentName = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 2, 1, 1, 2), DisplayString()).setMaxAccess("readonly")
if mibBuilder.loadTexts: swDldComponentName.setStatus('mandatory')
swDldStorageType = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 2, 1, 1, 4), StorageType()).setMaxAccess("readonly")
if mibBuilder.loadTexts: swDldStorageType.setStatus('mandatory')
swDldIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 2, 1, 1, 10), NonReplicated())
if mibBuilder.loadTexts: swDldIndex.setStatus('mandatory')
swDldOperTable = MibTable((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 2, 10), )
if mibBuilder.loadTexts: swDldOperTable.setStatus('mandatory')
swDldOperEntry = MibTableRow((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 2, 10, 1), ).setIndexNames((0, "Nortel-Magellan-Passport-SoftwareMIB", "swIndex"), (0, "Nortel-Magellan-Passport-SoftwareMIB", "swDldIndex"))
if mibBuilder.loadTexts: swDldOperEntry.setStatus('mandatory')
swDldAvBeingDownloaded = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 2, 10, 1, 1), AsciiString().subtype(subtypeSpec=ValueSizeConstraint(0, 30))).setMaxAccess("readonly")
if mibBuilder.loadTexts: swDldAvBeingDownloaded.setStatus('mandatory')
swDldStatus = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 2, 10, 1, 2), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(0, 1, 2))).clone(namedValues=NamedValues(("inactive", 0), ("inProgress", 1), ("stopping", 2)))).setMaxAccess("readonly")
if mibBuilder.loadTexts: swDldStatus.setStatus('mandatory')
swDldFilesToTransfer = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 2, 10, 1, 3), Unsigned32().subtype(subtypeSpec=ValueRangeConstraint(0, 1000))).setMaxAccess("readonly")
if mibBuilder.loadTexts: swDldFilesToTransfer.setStatus('mandatory')
swDldProcessorTargets = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 2, 10, 1, 4), OctetString().subtype(subtypeSpec=ValueSizeConstraint(1, 1)).setFixedLength(1)).setMaxAccess("readwrite")
if mibBuilder.loadTexts: swDldProcessorTargets.setStatus('mandatory')
swDldDldListTable = MibTable((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 2, 260), )
if mibBuilder.loadTexts: swDldDldListTable.setStatus('mandatory')
swDldDldListEntry = MibTableRow((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 2, 260, 1), ).setIndexNames((0, "Nortel-Magellan-Passport-SoftwareMIB", "swIndex"), (0, "Nortel-Magellan-Passport-SoftwareMIB", "swDldIndex"), (0, "Nortel-Magellan-Passport-SoftwareMIB", "swDldDldListValue"))
if mibBuilder.loadTexts: swDldDldListEntry.setStatus('mandatory')
swDldDldListValue = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 2, 260, 1, 1), AsciiString().subtype(subtypeSpec=ValueSizeConstraint(1, 30))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: swDldDldListValue.setStatus('mandatory')
swDldDldListRowStatus = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 2, 260, 1, 2), RowStatus()).setMaxAccess("writeonly")
if mibBuilder.loadTexts: swDldDldListRowStatus.setStatus('mandatory')
swDldDownloadedAvListTable = MibTable((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 2, 261), )
if mibBuilder.loadTexts: swDldDownloadedAvListTable.setStatus('mandatory')
swDldDownloadedAvListEntry = MibTableRow((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 2, 261, 1), ).setIndexNames((0, "Nortel-Magellan-Passport-SoftwareMIB", "swIndex"), (0, "Nortel-Magellan-Passport-SoftwareMIB", "swDldIndex"), (0, "Nortel-Magellan-Passport-SoftwareMIB", "swDldDownloadedAvListValue"))
if mibBuilder.loadTexts: swDldDownloadedAvListEntry.setStatus('mandatory')
swDldDownloadedAvListValue = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 2, 261, 1, 1), AsciiString().subtype(subtypeSpec=ValueSizeConstraint(1, 30))).setMaxAccess("readonly")
if mibBuilder.loadTexts: swDldDownloadedAvListValue.setStatus('mandatory')
swAv = MibIdentifier((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 3))
swAvRowStatusTable = MibTable((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 3, 1), )
if mibBuilder.loadTexts: swAvRowStatusTable.setStatus('mandatory')
swAvRowStatusEntry = MibTableRow((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 3, 1, 1), ).setIndexNames((0, "Nortel-Magellan-Passport-SoftwareMIB", "swIndex"), (0, "Nortel-Magellan-Passport-SoftwareMIB", "swAvIndex"))
if mibBuilder.loadTexts: swAvRowStatusEntry.setStatus('mandatory')
swAvRowStatus = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 3, 1, 1, 1), RowStatus()).setMaxAccess("readonly")
if mibBuilder.loadTexts: swAvRowStatus.setStatus('mandatory')
swAvComponentName = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 3, 1, 1, 2), DisplayString()).setMaxAccess("readonly")
if mibBuilder.loadTexts: swAvComponentName.setStatus('mandatory')
swAvStorageType = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 3, 1, 1, 4), StorageType()).setMaxAccess("readonly")
if mibBuilder.loadTexts: swAvStorageType.setStatus('mandatory')
swAvIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 3, 1, 1, 10), AsciiStringIndex().subtype(subtypeSpec=ValueSizeConstraint(1, 30)))
if mibBuilder.loadTexts: swAvIndex.setStatus('mandatory')
swAvOperTable = MibTable((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 3, 10), )
if mibBuilder.loadTexts: swAvOperTable.setStatus('mandatory')
swAvOperEntry = MibTableRow((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 3, 10, 1), ).setIndexNames((0, "Nortel-Magellan-Passport-SoftwareMIB", "swIndex"), (0, "Nortel-Magellan-Passport-SoftwareMIB", "swAvIndex"))
if mibBuilder.loadTexts: swAvOperEntry.setStatus('mandatory')
swAvProcessorTargets = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 3, 10, 1, 1), OctetString().subtype(subtypeSpec=ValueSizeConstraint(1, 1)).setFixedLength(1)).setMaxAccess("readonly")
if mibBuilder.loadTexts: swAvProcessorTargets.setStatus('mandatory')
swAvCompatibleAvListTable = MibTable((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 3, 259), )
if mibBuilder.loadTexts: swAvCompatibleAvListTable.setStatus('mandatory')
swAvCompatibleAvListEntry = MibTableRow((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 3, 259, 1), ).setIndexNames((0, "Nortel-Magellan-Passport-SoftwareMIB", "swIndex"), (0, "Nortel-Magellan-Passport-SoftwareMIB", "swAvIndex"), (0, "Nortel-Magellan-Passport-SoftwareMIB", "swAvCompatibleAvListValue"))
if mibBuilder.loadTexts: swAvCompatibleAvListEntry.setStatus('mandatory')
swAvCompatibleAvListValue = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 3, 259, 1, 1), AsciiString().subtype(subtypeSpec=ValueSizeConstraint(1, 30))).setMaxAccess("readonly")
if mibBuilder.loadTexts: swAvCompatibleAvListValue.setStatus('mandatory')
swAvFeat = MibIdentifier((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 3, 2))
swAvFeatRowStatusTable = MibTable((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 3, 2, 1), )
if mibBuilder.loadTexts: swAvFeatRowStatusTable.setStatus('mandatory')
swAvFeatRowStatusEntry = MibTableRow((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 3, 2, 1, 1), ).setIndexNames((0, "Nortel-Magellan-Passport-SoftwareMIB", "swIndex"), (0, "Nortel-Magellan-Passport-SoftwareMIB", "swAvIndex"), (0, "Nortel-Magellan-Passport-SoftwareMIB", "swAvFeatIndex"))
if mibBuilder.loadTexts: swAvFeatRowStatusEntry.setStatus('mandatory')
swAvFeatRowStatus = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 3, 2, 1, 1, 1), RowStatus()).setMaxAccess("readonly")
if mibBuilder.loadTexts: swAvFeatRowStatus.setStatus('mandatory')
swAvFeatComponentName = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 3, 2, 1, 1, 2), DisplayString()).setMaxAccess("readonly")
if mibBuilder.loadTexts: swAvFeatComponentName.setStatus('mandatory')
swAvFeatStorageType = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 3, 2, 1, 1, 4), StorageType()).setMaxAccess("readonly")
if mibBuilder.loadTexts: swAvFeatStorageType.setStatus('mandatory')
swAvFeatIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 3, 2, 1, 1, 10), AsciiStringIndex().subtype(subtypeSpec=ValueSizeConstraint(1, 25)))
if mibBuilder.loadTexts: swAvFeatIndex.setStatus('mandatory')
swAvPatch = MibIdentifier((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 3, 3))
swAvPatchRowStatusTable = MibTable((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 3, 3, 1), )
if mibBuilder.loadTexts: swAvPatchRowStatusTable.setStatus('mandatory')
swAvPatchRowStatusEntry = MibTableRow((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 3, 3, 1, 1), ).setIndexNames((0, "Nortel-Magellan-Passport-SoftwareMIB", "swIndex"), (0, "Nortel-Magellan-Passport-SoftwareMIB", "swAvIndex"), (0, "Nortel-Magellan-Passport-SoftwareMIB", "swAvPatchIndex"))
if mibBuilder.loadTexts: swAvPatchRowStatusEntry.setStatus('mandatory')
swAvPatchRowStatus = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 3, 3, 1, 1, 1), RowStatus()).setMaxAccess("readonly")
if mibBuilder.loadTexts: swAvPatchRowStatus.setStatus('mandatory')
swAvPatchComponentName = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 3, 3, 1, 1, 2), DisplayString()).setMaxAccess("readonly")
if mibBuilder.loadTexts: swAvPatchComponentName.setStatus('mandatory')
swAvPatchStorageType = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 3, 3, 1, 1, 4), StorageType()).setMaxAccess("readonly")
if mibBuilder.loadTexts: swAvPatchStorageType.setStatus('mandatory')
swAvPatchIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 3, 3, 1, 1, 10), AsciiStringIndex().subtype(subtypeSpec=ValueSizeConstraint(1, 30)))
if mibBuilder.loadTexts: swAvPatchIndex.setStatus('mandatory')
swAvPatchOperTable = MibTable((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 3, 3, 10), )
if mibBuilder.loadTexts: swAvPatchOperTable.setStatus('mandatory')
swAvPatchOperEntry = MibTableRow((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 3, 3, 10, 1), ).setIndexNames((0, "Nortel-Magellan-Passport-SoftwareMIB", "swIndex"), (0, "Nortel-Magellan-Passport-SoftwareMIB", "swAvIndex"), (0, "Nortel-Magellan-Passport-SoftwareMIB", "swAvPatchIndex"))
if mibBuilder.loadTexts: swAvPatchOperEntry.setStatus('mandatory')
swAvPatchDescription = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 3, 3, 10, 1, 1), AsciiString().subtype(subtypeSpec=ValueSizeConstraint(0, 512))).setMaxAccess("readonly")
if mibBuilder.loadTexts: swAvPatchDescription.setStatus('mandatory')
swLpt = MibIdentifier((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 4))
swLptRowStatusTable = MibTable((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 4, 1), )
if mibBuilder.loadTexts: swLptRowStatusTable.setStatus('mandatory')
swLptRowStatusEntry = MibTableRow((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 4, 1, 1), ).setIndexNames((0, "Nortel-Magellan-Passport-SoftwareMIB", "swIndex"), (0, "Nortel-Magellan-Passport-SoftwareMIB", "swLptIndex"))
if mibBuilder.loadTexts: swLptRowStatusEntry.setStatus('mandatory')
swLptRowStatus = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 4, 1, 1, 1), RowStatus()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: swLptRowStatus.setStatus('mandatory')
swLptComponentName = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 4, 1, 1, 2), DisplayString()).setMaxAccess("readonly")
if mibBuilder.loadTexts: swLptComponentName.setStatus('mandatory')
swLptStorageType = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 4, 1, 1, 4), StorageType()).setMaxAccess("readonly")
if mibBuilder.loadTexts: swLptStorageType.setStatus('mandatory')
swLptIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 4, 1, 1, 10), AsciiStringIndex().subtype(subtypeSpec=ValueSizeConstraint(1, 25)))
if mibBuilder.loadTexts: swLptIndex.setStatus('mandatory')
swLptProvTable = MibTable((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 4, 10), )
if mibBuilder.loadTexts: swLptProvTable.setStatus('mandatory')
swLptProvEntry = MibTableRow((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 4, 10, 1), ).setIndexNames((0, "Nortel-Magellan-Passport-SoftwareMIB", "swIndex"), (0, "Nortel-Magellan-Passport-SoftwareMIB", "swLptIndex"))
if mibBuilder.loadTexts: swLptProvEntry.setStatus('mandatory')
swLptCommentText = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 4, 10, 1, 1), AsciiString().subtype(subtypeSpec=ValueSizeConstraint(0, 80))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: swLptCommentText.setStatus('mandatory')
swLptSystemConfig = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 4, 10, 1, 2), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(0))).clone(namedValues=NamedValues(("default", 0))).clone('default')).setMaxAccess("readwrite")
if mibBuilder.loadTexts: swLptSystemConfig.setStatus('mandatory')
swLptFlTable = MibTable((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 4, 257), )
if mibBuilder.loadTexts: swLptFlTable.setStatus('mandatory')
swLptFlEntry = MibTableRow((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 4, 257, 1), ).setIndexNames((0, "Nortel-Magellan-Passport-SoftwareMIB", "swIndex"), (0, "Nortel-Magellan-Passport-SoftwareMIB", "swLptIndex"), (0, "Nortel-Magellan-Passport-SoftwareMIB", "swLptFlValue"))
if mibBuilder.loadTexts: swLptFlEntry.setStatus('mandatory')
swLptFlValue = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 4, 257, 1, 1), AsciiString().subtype(subtypeSpec=ValueSizeConstraint(1, 25))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: swLptFlValue.setStatus('mandatory')
swLptFlRowStatus = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 4, 257, 1, 2), RowStatus()).setMaxAccess("writeonly")
if mibBuilder.loadTexts: swLptFlRowStatus.setStatus('mandatory')
swLptLogicalProcessorsTable = MibTable((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 4, 258), )
if mibBuilder.loadTexts: swLptLogicalProcessorsTable.setStatus('mandatory')
swLptLogicalProcessorsEntry = MibTableRow((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 4, 258, 1), ).setIndexNames((0, "Nortel-Magellan-Passport-SoftwareMIB", "swIndex"), (0, "Nortel-Magellan-Passport-SoftwareMIB", "swLptIndex"), (0, "Nortel-Magellan-Passport-SoftwareMIB", "swLptLogicalProcessorsValue"))
if mibBuilder.loadTexts: swLptLogicalProcessorsEntry.setStatus('mandatory')
swLptLogicalProcessorsValue = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 2, 4, 1, 14, 4, 258, 1, 1), Link()).setMaxAccess("readonly")
if mibBuilder.loadTexts: swLptLogicalProcessorsValue.setStatus('mandatory')
softwareGroup = MibIdentifier((1, 3, 6, 1, 4, 1, 562, 2, 4, 2, 17, 1))
softwareGroupBE = MibIdentifier((1, 3, 6, 1, 4, 1, 562, 2, 4, 2, 17, 1, 5))
softwareGroupBE01 = MibIdentifier((1, 3, 6, 1, 4, 1, 562, 2, 4, 2, 17, 1, 5, 2))
softwareGroupBE01A = MibIdentifier((1, 3, 6, 1, 4, 1, 562, 2, 4, 2, 17, 1, 5, 2, 2))
softwareCapabilities = MibIdentifier((1, 3, 6, 1, 4, 1, 562, 2, 4, 2, 17, 3))
softwareCapabilitiesBE = MibIdentifier((1, 3, 6, 1, 4, 1, 562, 2, 4, 2, 17, 3, 5))
softwareCapabilitiesBE01 = MibIdentifier((1, 3, 6, 1, 4, 1, 562, 2, 4, 2, 17, 3, 5, 2))
softwareCapabilitiesBE01A = MibIdentifier((1, 3, 6, 1, 4, 1, 562, 2, 4, 2, 17, 3, 5, 2, 2))
mibBuilder.exportSymbols("Nortel-Magellan-Passport-SoftwareMIB", softwareCapabilitiesBE01A=softwareCapabilitiesBE01A, swDldDldListRowStatus=swDldDldListRowStatus, swAvPatchOperEntry=swAvPatchOperEntry, swLptSystemConfig=swLptSystemConfig, swDldDownloadedAvListValue=swDldDownloadedAvListValue, swAvListToTidyTable=swAvListToTidyTable, swAvStorageType=swAvStorageType, swLptLogicalProcessorsEntry=swLptLogicalProcessorsEntry, softwareCapabilitiesBE01=softwareCapabilitiesBE01, swLptIndex=swLptIndex, softwareCapabilities=softwareCapabilities, swLptProvTable=swLptProvTable, swAvlTable=swAvlTable, swLptComponentName=swLptComponentName, swAvFeatIndex=swAvFeatIndex, swAvPatchRowStatusEntry=swAvPatchRowStatusEntry, swLpt=swLpt, swAvRowStatusTable=swAvRowStatusTable, swDldDldListEntry=swDldDldListEntry, swAvRowStatus=swAvRowStatus, swDldOperTable=swDldOperTable, swAvFeatRowStatus=swAvFeatRowStatus, swAvPatchOperTable=swAvPatchOperTable, swComponentName=swComponentName, swAvFeat=swAvFeat, swDldDownloadedAvListEntry=swDldDownloadedAvListEntry, swDldFilesToTransfer=swDldFilesToTransfer, swDldProcessorTargets=swDldProcessorTargets, swLptFlRowStatus=swLptFlRowStatus, swAvListToTidyValue=swAvListToTidyValue, swAvRowStatusEntry=swAvRowStatusEntry, swDldComponentName=swDldComponentName, swAvOperEntry=swAvOperEntry, swLptRowStatusTable=swLptRowStatusTable, swDldOperEntry=swDldOperEntry, swAvPatchDescription=swAvPatchDescription, sw=sw, swLptLogicalProcessorsTable=swLptLogicalProcessorsTable, swLptFlEntry=swLptFlEntry, swDldRowStatusEntry=swDldRowStatusEntry, swAvFeatRowStatusTable=swAvFeatRowStatusTable, swDldRowStatus=swDldRowStatus, swPatlValue=swPatlValue, swAvPatchComponentName=swAvPatchComponentName, swAvPatchStorageType=swAvPatchStorageType, swLptRowStatusEntry=swLptRowStatusEntry, swAvListTidiedEntry=swAvListTidiedEntry, swAvPatch=swAvPatch, softwareCapabilitiesBE=softwareCapabilitiesBE, swTidyStatus=swTidyStatus, swDldStorageType=swDldStorageType, swAvPatchRowStatus=swAvPatchRowStatus, swAvCompatibleAvListEntry=swAvCompatibleAvListEntry, swRowStatusEntry=swRowStatusEntry, swAvPatchIndex=swAvPatchIndex, swRowStatus=swRowStatus, swLptProvEntry=swLptProvEntry, softwareGroupBE01=softwareGroupBE01, swPatlEntry=swPatlEntry, swAvComponentName=swAvComponentName, swIndex=swIndex, swAvFeatRowStatusEntry=swAvFeatRowStatusEntry, swLptFlTable=swLptFlTable, swDldIndex=swDldIndex, swLptFlValue=swLptFlValue, swAvIndex=swAvIndex, swAvListTidiedValue=swAvListTidiedValue, swLptRowStatus=swLptRowStatus, swAvOperTable=swAvOperTable, swAvPatchRowStatusTable=swAvPatchRowStatusTable, swOperEntry=swOperEntry, swAvFeatStorageType=swAvFeatStorageType, swDldAvBeingDownloaded=swDldAvBeingDownloaded, softwareGroup=softwareGroup, swAvListTidiedTable=swAvListTidiedTable, swLptCommentText=swLptCommentText, swRowStatusTable=swRowStatusTable, swAvProcessorTargets=swAvProcessorTargets, softwareGroupBE01A=softwareGroupBE01A, swAvlEntry=swAvlEntry, swAvlRowStatus=swAvlRowStatus, swLptLogicalProcessorsValue=swLptLogicalProcessorsValue, swOperTable=swOperTable, swAv=swAv, swPatlTable=swPatlTable, swStorageType=swStorageType, swDldDldListValue=swDldDldListValue, swAvListToTidyEntry=swAvListToTidyEntry, softwareGroupBE=softwareGroupBE, swDld=swDld, swDldDownloadedAvListTable=swDldDownloadedAvListTable, swLptStorageType=swLptStorageType, swAvlValue=swAvlValue, swPatlRowStatus=swPatlRowStatus, swDldRowStatusTable=swDldRowStatusTable, swDldStatus=swDldStatus, swAvCompatibleAvListValue=swAvCompatibleAvListValue, swDldDldListTable=swDldDldListTable, swAvFeatComponentName=swAvFeatComponentName, softwareMIB=softwareMIB, swAvCompatibleAvListTable=swAvCompatibleAvListTable, swAvBeingTidied=swAvBeingTidied)
|
expression = input()
parentheses_indices = []
for i in range(len(expression)):
if expression[i] == '(':
parentheses_indices.append(i)
elif expression[i] == ')':
opening_index = parentheses_indices.pop()
closing_index = i
searched_set = expression[opening_index:closing_index + 1]
print(searched_set) |
sexo=str(input('Informe seu sexo: [M/F]')).upper()[0].strip()
print(sexo)
while sexo not in 'MF':
sexo=str(input('Dados inválidos. Por favor, informe seu sexo: '))
print('Sexo {} validado'.format(sexo))
|
name = "Optimizer Parameters"
description = None
args_and_kwargs = (
(("--iterations",), {
"help":"Number of gradient steps to take.",
"type":int,
"default":10000,
}),
(("--learning-rate",), {
"help":"Adam learning rate. The default is 0.001",
"type":float,
"default":0.001,
}),
(("--beta-1",), {
"help":"Adam beta_1 param. The default is 0.9",
"type":float,
"default":0.9,
}),
(("--beta-2",), {
"help":"Adam beta_2 param. The default is 0.99",
"type":float,
"default":0.99,
}),
)
|
# File: M (Python 2.4)
class Mappable:
def __init__(self):
pass
def getMapNode(self):
pass
class MappableArea(Mappable):
def getMapName(self):
return ''
def getZoomLevels(self):
return ((100, 200, 300), 1)
def getFootprintNode(self):
pass
def getShopNodes(self):
return ()
def getCapturePointNodes(self, holidayId):
return ()
class MappableGrid(MappableArea):
def getGridParamters(self):
return ()
|
#!/usr/bin/env python
S_PC = ord("p")
S_A = ord("A")
S_X = ord("X")
S_Y = ord("Y")
S_SP = ord("S")
S_IND_X = 0x1D9
S_IND_Y = 0x1DF
S_Z_X = 0x209
S_Z_Y = 0x20F
S_Z = 0x200
S_ABS_X = 0x809
S_ABS_Y = 0x80F
S_ABS = 0x800
S_HASH = ord("#")
S_XXX = 0xFFFF
S_NONE = 0x0000
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.