content stringlengths 7 1.05M | fixed_cases stringlengths 1 1.28M |
|---|---|
# Largest palindrome product
DIGITS = 3
def solve():
return max(p for x in range(10**(DIGITS - 1), 10**DIGITS)
for y in range(x, 10**DIGITS)
if str(p := x * y) == str(p)[::-1])
if __name__ == "__main__":
print(solve())
| digits = 3
def solve():
return max((p for x in range(10 ** (DIGITS - 1), 10 ** DIGITS) for y in range(x, 10 ** DIGITS) if str((p := (x * y))) == str(p)[::-1]))
if __name__ == '__main__':
print(solve()) |
def format_list(my_list):
"""
:param my_list:
:type: list
:return: list separated with ', ' & before the last item add the word 'and '
:rtype: list
"""
new_list = ', '.join(my_list[0:len(my_list)-1:2]) + " and " + my_list[len(my_list)-1]
return new_list
def main():
print(format_list.__doc__)
my_list = ["hydrogen", "helium", "lithium", "beryllium", "boron", "magnesium"]
print(format_list(my_list))
if __name__ == '__main__':
main()
| def format_list(my_list):
"""
:param my_list:
:type: list
:return: list separated with ', ' & before the last item add the word 'and '
:rtype: list
"""
new_list = ', '.join(my_list[0:len(my_list) - 1:2]) + ' and ' + my_list[len(my_list) - 1]
return new_list
def main():
print(format_list.__doc__)
my_list = ['hydrogen', 'helium', 'lithium', 'beryllium', 'boron', 'magnesium']
print(format_list(my_list))
if __name__ == '__main__':
main() |
# -*- coding: utf-8 -*-
"""
Created on Sat Jul 3 11:20:06 2021
@author: Easin
"""
in1 = input()
list1 = []
for elem in range(len(in1)):
if in1[elem] != "+":
list1.append(in1[elem])
#print(list1)
list1.sort()
str1 = ""
for elem in range(len(list1)):
str1 += list1[elem]+ "+"
print(str1[:-1]) | """
Created on Sat Jul 3 11:20:06 2021
@author: Easin
"""
in1 = input()
list1 = []
for elem in range(len(in1)):
if in1[elem] != '+':
list1.append(in1[elem])
list1.sort()
str1 = ''
for elem in range(len(list1)):
str1 += list1[elem] + '+'
print(str1[:-1]) |
def find_longest_palindrome(string):
if is_palindrome(string):
return string
left = find_longest_palindrome(string[:-1])
right = find_longest_palindrome(string[1:])
middle = find_longest_palindrome(string[1:-1])
if len(left) >= len(right) and len(left) >= len(middle):
return left
elif len(right) >= len(left) and len(right) >= len(middle):
return right
else:
return middle
def is_palindrome(string):
i = 0
while i < (len(string) - 1 - i):
if string[i] == string[len(string) - 1 - i]:
i += 1
else:
return False
return True
string = "asdlkfjsdlfusdboob"
print(find_longest_palindrome(string)) | def find_longest_palindrome(string):
if is_palindrome(string):
return string
left = find_longest_palindrome(string[:-1])
right = find_longest_palindrome(string[1:])
middle = find_longest_palindrome(string[1:-1])
if len(left) >= len(right) and len(left) >= len(middle):
return left
elif len(right) >= len(left) and len(right) >= len(middle):
return right
else:
return middle
def is_palindrome(string):
i = 0
while i < len(string) - 1 - i:
if string[i] == string[len(string) - 1 - i]:
i += 1
else:
return False
return True
string = 'asdlkfjsdlfusdboob'
print(find_longest_palindrome(string)) |
class Solution:
def mySqrt(self, x: int) -> int:
if x < 0 or x>(2**31):
return False
ans = 0
for i in range(0, x+1):
if i**2<=x:
ans = i
else:
break
return ans
| class Solution:
def my_sqrt(self, x: int) -> int:
if x < 0 or x > 2 ** 31:
return False
ans = 0
for i in range(0, x + 1):
if i ** 2 <= x:
ans = i
else:
break
return ans |
# Copyright 2020 The Kythe Authors. All rights reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
load("@bazel_skylib//lib:paths.bzl", "paths")
load("@bazel_tools//tools/cpp:toolchain_utils.bzl", "find_cpp_toolchain")
load("//kythe/go/indexer:testdata/go_indexer_test.bzl", "go_verifier_test")
load(
"//tools/build_rules/verifier_test:verifier_test.bzl",
"KytheEntries",
)
def _rust_extract_impl(ctx):
# Get the path for the system's linker
cc_toolchain = find_cpp_toolchain(ctx)
cc_features = cc_common.configure_features(
ctx = ctx,
cc_toolchain = cc_toolchain,
)
linker_path = cc_common.get_tool_for_action(
feature_configuration = cc_features,
action_name = "c++-link-executable",
)
# Rust toolchain
rust_toolchain = ctx.toolchains["@io_bazel_rules_rust//rust:toolchain"]
rustc_lib = rust_toolchain.rustc_lib.files.to_list()
rust_lib = rust_toolchain.rust_lib.files.to_list()
# Generate extra_action file to be used by the extractor
extra_action_file = ctx.actions.declare_file(ctx.label.name + ".xa")
xa_maker = ctx.executable._extra_action
ctx.actions.run(
executable = xa_maker,
arguments = [
"--src_files=%s" % ",".join([f.path for f in ctx.files.srcs]),
"--output=%s" % extra_action_file.path,
"--owner=%s" % ctx.label.name,
"--crate_name=%s" % ctx.attr.crate_name,
"--sysroot=%s" % paths.dirname(rust_lib[0].path),
"--linker=%s" % linker_path,
],
outputs = [extra_action_file],
)
# Generate the kzip
output = ctx.outputs.kzip
ctx.actions.run(
mnemonic = "RustExtract",
executable = ctx.executable._extractor,
arguments = [
"--extra_action=%s" % extra_action_file.path,
"--output=%s" % output.path,
],
inputs = [extra_action_file] + rustc_lib + rust_lib + ctx.files.srcs,
outputs = [output],
env = {
"KYTHE_CORPUS": "test_corpus",
"LD_LIBRARY_PATH": paths.dirname(rustc_lib[0].path),
},
)
return struct(kzip = output)
# Generate a kzip with the compilations captured from a single Go library or
# binary rule.
rust_extract = rule(
_rust_extract_impl,
attrs = {
# Additional data files to include in each compilation.
"data": attr.label_list(
allow_empty = True,
allow_files = True,
),
"srcs": attr.label_list(
mandatory = True,
allow_files = [".rs"],
),
"crate_name": attr.string(
default = "test_crate",
),
"_extractor": attr.label(
default = Label("//kythe/rust/extractor"),
executable = True,
cfg = "host",
),
"_extra_action": attr.label(
default = Label("//tools/rust/extra_action"),
executable = True,
cfg = "host",
),
"_cc_toolchain": attr.label(
default = Label("@bazel_tools//tools/cpp:current_cc_toolchain"),
allow_files = True,
),
},
outputs = {"kzip": "%{name}.kzip"},
fragments = ["cpp"],
toolchains = ["@io_bazel_rules_rust//rust:toolchain"],
)
def _rust_entries_impl(ctx):
kzip = ctx.attr.kzip.kzip
indexer = ctx.executable._indexer
iargs = [indexer.path]
output = ctx.outputs.entries
# TODO(Arm1stice): Pass arguments to indexer based on rule attributes
# # If the test wants marked source, enable support for it in the indexer.
# if ctx.attr.has_marked_source:
# iargs.append("-code")
# if ctx.attr.emit_anchor_scopes:
# iargs.append("-anchor_scopes")
# # If the test wants linkage metadata, enable support for it in the indexer.
# if ctx.attr.metadata_suffix:
# iargs += ["-meta", ctx.attr.metadata_suffix]
iargs += [kzip.path, "| gzip >" + output.path]
cmds = ["set -e", "set -o pipefail", " ".join(iargs), ""]
ctx.actions.run_shell(
mnemonic = "RustIndexer",
command = "\n".join(cmds),
outputs = [output],
inputs = [kzip],
tools = [indexer],
)
return [KytheEntries(compressed = depset([output]), files = depset())]
# Run the Kythe indexer on the output that results from a go_extract rule.
rust_entries = rule(
_rust_entries_impl,
attrs = {
# Whether to enable explosion of MarkedSource facts.
"has_marked_source": attr.bool(default = False),
# Whether to enable anchor scope edges.
"emit_anchor_scopes": attr.bool(default = False),
# The kzip to pass to the Rust indexer
"kzip": attr.label(
providers = ["kzip"],
mandatory = True,
),
# The location of the Rust indexer binary.
"_indexer": attr.label(
default = Label("//kythe/rust/indexer"),
executable = True,
cfg = "host",
),
},
outputs = {"entries": "%{name}.entries.gz"},
)
def _rust_indexer(
name,
srcs,
data = None,
has_marked_source = False,
emit_anchor_scopes = False,
allow_duplicates = False,
metadata_suffix = ""):
kzip = name + "_units"
rust_extract(
name = kzip,
srcs = srcs,
)
entries = name + "_entries"
rust_entries(
name = entries,
has_marked_source = has_marked_source,
emit_anchor_scopes = emit_anchor_scopes,
kzip = ":" + kzip,
)
return entries
def rust_indexer_test(
name,
srcs,
size = None,
tags = None,
log_entries = False,
has_marked_source = False,
emit_anchor_scopes = False,
allow_duplicates = False):
# Generate entries using the Rust indexer
entries = _rust_indexer(
name = name,
srcs = srcs,
has_marked_source = has_marked_source,
emit_anchor_scopes = emit_anchor_scopes,
)
# Most of this code was copied from the Go verifier macros and modified for
# Rust. This function does not need to be modified, so we are just calling
# it directly here.
go_verifier_test(
name = name,
size = size,
allow_duplicates = allow_duplicates,
entries = ":" + entries,
has_marked_source = has_marked_source,
log_entries = log_entries,
tags = tags,
)
| load('@bazel_skylib//lib:paths.bzl', 'paths')
load('@bazel_tools//tools/cpp:toolchain_utils.bzl', 'find_cpp_toolchain')
load('//kythe/go/indexer:testdata/go_indexer_test.bzl', 'go_verifier_test')
load('//tools/build_rules/verifier_test:verifier_test.bzl', 'KytheEntries')
def _rust_extract_impl(ctx):
cc_toolchain = find_cpp_toolchain(ctx)
cc_features = cc_common.configure_features(ctx=ctx, cc_toolchain=cc_toolchain)
linker_path = cc_common.get_tool_for_action(feature_configuration=cc_features, action_name='c++-link-executable')
rust_toolchain = ctx.toolchains['@io_bazel_rules_rust//rust:toolchain']
rustc_lib = rust_toolchain.rustc_lib.files.to_list()
rust_lib = rust_toolchain.rust_lib.files.to_list()
extra_action_file = ctx.actions.declare_file(ctx.label.name + '.xa')
xa_maker = ctx.executable._extra_action
ctx.actions.run(executable=xa_maker, arguments=['--src_files=%s' % ','.join([f.path for f in ctx.files.srcs]), '--output=%s' % extra_action_file.path, '--owner=%s' % ctx.label.name, '--crate_name=%s' % ctx.attr.crate_name, '--sysroot=%s' % paths.dirname(rust_lib[0].path), '--linker=%s' % linker_path], outputs=[extra_action_file])
output = ctx.outputs.kzip
ctx.actions.run(mnemonic='RustExtract', executable=ctx.executable._extractor, arguments=['--extra_action=%s' % extra_action_file.path, '--output=%s' % output.path], inputs=[extra_action_file] + rustc_lib + rust_lib + ctx.files.srcs, outputs=[output], env={'KYTHE_CORPUS': 'test_corpus', 'LD_LIBRARY_PATH': paths.dirname(rustc_lib[0].path)})
return struct(kzip=output)
rust_extract = rule(_rust_extract_impl, attrs={'data': attr.label_list(allow_empty=True, allow_files=True), 'srcs': attr.label_list(mandatory=True, allow_files=['.rs']), 'crate_name': attr.string(default='test_crate'), '_extractor': attr.label(default=label('//kythe/rust/extractor'), executable=True, cfg='host'), '_extra_action': attr.label(default=label('//tools/rust/extra_action'), executable=True, cfg='host'), '_cc_toolchain': attr.label(default=label('@bazel_tools//tools/cpp:current_cc_toolchain'), allow_files=True)}, outputs={'kzip': '%{name}.kzip'}, fragments=['cpp'], toolchains=['@io_bazel_rules_rust//rust:toolchain'])
def _rust_entries_impl(ctx):
kzip = ctx.attr.kzip.kzip
indexer = ctx.executable._indexer
iargs = [indexer.path]
output = ctx.outputs.entries
iargs += [kzip.path, '| gzip >' + output.path]
cmds = ['set -e', 'set -o pipefail', ' '.join(iargs), '']
ctx.actions.run_shell(mnemonic='RustIndexer', command='\n'.join(cmds), outputs=[output], inputs=[kzip], tools=[indexer])
return [kythe_entries(compressed=depset([output]), files=depset())]
rust_entries = rule(_rust_entries_impl, attrs={'has_marked_source': attr.bool(default=False), 'emit_anchor_scopes': attr.bool(default=False), 'kzip': attr.label(providers=['kzip'], mandatory=True), '_indexer': attr.label(default=label('//kythe/rust/indexer'), executable=True, cfg='host')}, outputs={'entries': '%{name}.entries.gz'})
def _rust_indexer(name, srcs, data=None, has_marked_source=False, emit_anchor_scopes=False, allow_duplicates=False, metadata_suffix=''):
kzip = name + '_units'
rust_extract(name=kzip, srcs=srcs)
entries = name + '_entries'
rust_entries(name=entries, has_marked_source=has_marked_source, emit_anchor_scopes=emit_anchor_scopes, kzip=':' + kzip)
return entries
def rust_indexer_test(name, srcs, size=None, tags=None, log_entries=False, has_marked_source=False, emit_anchor_scopes=False, allow_duplicates=False):
entries = _rust_indexer(name=name, srcs=srcs, has_marked_source=has_marked_source, emit_anchor_scopes=emit_anchor_scopes)
go_verifier_test(name=name, size=size, allow_duplicates=allow_duplicates, entries=':' + entries, has_marked_source=has_marked_source, log_entries=log_entries, tags=tags) |
class Participant:
def __init__(self, pa_name, pa_has_somebody_to_gift=False):
self._name = pa_name
# I don't use this property in my algorithm :P
self._has_somebody_to_gift = pa_has_somebody_to_gift
@property
def name(self):
return self._name
@name.setter
def name(self, pa_name):
self._name = pa_name
@property
def has_somebody_to_gift(self):
return self._has_somebody_to_gift
@has_somebody_to_gift.setter
def has_somebody_to_gift(self, pa_has_somebody_to_gift):
self._has_somebody_to_gift = pa_has_somebody_to_gift
| class Participant:
def __init__(self, pa_name, pa_has_somebody_to_gift=False):
self._name = pa_name
self._has_somebody_to_gift = pa_has_somebody_to_gift
@property
def name(self):
return self._name
@name.setter
def name(self, pa_name):
self._name = pa_name
@property
def has_somebody_to_gift(self):
return self._has_somebody_to_gift
@has_somebody_to_gift.setter
def has_somebody_to_gift(self, pa_has_somebody_to_gift):
self._has_somebody_to_gift = pa_has_somebody_to_gift |
def trint(inthing):
try:
outhing = int(inthing)
except:
outhing = None
return outhing
def trfloat(inthing, scale):
try:
outhing = float(inthing) * scale
except:
outhing = None
return outhing
class IMMA:
def __init__(self): # Standard instance object
self.data = {} # Dictionary to hold the parameter values
def readstr(self,line):
self.data['ID'] = line[0]
self.data['UID'] = line[1]
self.data['LAT'] = float(line[2])
self.data['LON'] = float(line[3])
self.data['YR'] = int(float(line[4]))
self.data['MO'] = int(float(line[5]))
self.data['DY'] = int(float(line[6]))
self.data['HR'] = float(float(line[7]))
if self.data['HR'] == -32768.:
self.data['HR'] = None
self.data['SST'] = float(float(line[11]))
if self.data['SST'] == -32768.:
self.data['SST'] = None
self.data['DCK'] = 999 | def trint(inthing):
try:
outhing = int(inthing)
except:
outhing = None
return outhing
def trfloat(inthing, scale):
try:
outhing = float(inthing) * scale
except:
outhing = None
return outhing
class Imma:
def __init__(self):
self.data = {}
def readstr(self, line):
self.data['ID'] = line[0]
self.data['UID'] = line[1]
self.data['LAT'] = float(line[2])
self.data['LON'] = float(line[3])
self.data['YR'] = int(float(line[4]))
self.data['MO'] = int(float(line[5]))
self.data['DY'] = int(float(line[6]))
self.data['HR'] = float(float(line[7]))
if self.data['HR'] == -32768.0:
self.data['HR'] = None
self.data['SST'] = float(float(line[11]))
if self.data['SST'] == -32768.0:
self.data['SST'] = None
self.data['DCK'] = 999 |
class Solution:
def removeDuplicates(self, nums: List[int]) -> int:
count = 1
i = 0
while i <len(nums)-1:
if nums[i]!=nums[i+1]:
count=1
else:
count+=1
if count==2:
i+=1
continue
else:
del nums[i]
continue
i+=1 | class Solution:
def remove_duplicates(self, nums: List[int]) -> int:
count = 1
i = 0
while i < len(nums) - 1:
if nums[i] != nums[i + 1]:
count = 1
else:
count += 1
if count == 2:
i += 1
continue
else:
del nums[i]
continue
i += 1 |
# START LAB EXERCISE 02
print('Lab Exercise 02 \n')
# SETUP
sandwich_string = 'chicken, bread, lettuce, onion, olives'
# END SETUP
# PROBLEM 1 (4 Points)
sandwich_replace = sandwich_string.replace('olives', 'tomato')
# PROBLEM 2 (4 Points)
# Don't have heavy_cream need to replace with milk
sandwich_list = sandwich_replace.split(", ")
# PROBLEM 3 (4 Points)
sandwich_list.pop(0)
# PROBLEM 4 (4 Points)
sandwich_list.append('cheese')
# PROBLEM 5 (4 Points)
last_item = sandwich_list[-1]
# END LAB EXERCISE | print('Lab Exercise 02 \n')
sandwich_string = 'chicken, bread, lettuce, onion, olives'
sandwich_replace = sandwich_string.replace('olives', 'tomato')
sandwich_list = sandwich_replace.split(', ')
sandwich_list.pop(0)
sandwich_list.append('cheese')
last_item = sandwich_list[-1] |
conf_nova_compute_conf = """[DEFAULT]
compute_driver = libvirt.LibvirtDriver
glance_api_version = 2
[libvirt]
virt_type = kvm
inject_password = False
inject_key = False
inject_partition = -2
images_type = rbd
images_rbd_pool = vms
images_rbd_ceph_conf = /etc/ceph/ceph.conf
rbd_user = cinder
rbd_secret_uuid = {{ rbd_secret_uuid }}
disk_cachemodes= "network=writeback"
block_migration_flag = "VIR_MIGRATE_UNDEFINE_SOURCE,VIR_MIGRATE_PEER2PEER,VIR_MIGRATE_LIVE,VIR_MIGRATE_NON_SHARED_INC"
live_migration_flag = "VIR_MIGRATE_UNDEFINE_SOURCE,VIR_MIGRATE_PEER2PEER,VIR_MIGRATE_LIVE,VIR_MIGRATE_PERSIST_DEST,VIR_MIGRATE_TUNNELLED"
live_migration_uri = qemu+tcp://%s/system
"""
| conf_nova_compute_conf = '[DEFAULT]\ncompute_driver = libvirt.LibvirtDriver\nglance_api_version = 2\n[libvirt]\nvirt_type = kvm\ninject_password = False\ninject_key = False\ninject_partition = -2\nimages_type = rbd\nimages_rbd_pool = vms\nimages_rbd_ceph_conf = /etc/ceph/ceph.conf\nrbd_user = cinder\nrbd_secret_uuid = {{ rbd_secret_uuid }}\ndisk_cachemodes= "network=writeback"\nblock_migration_flag = "VIR_MIGRATE_UNDEFINE_SOURCE,VIR_MIGRATE_PEER2PEER,VIR_MIGRATE_LIVE,VIR_MIGRATE_NON_SHARED_INC"\nlive_migration_flag = "VIR_MIGRATE_UNDEFINE_SOURCE,VIR_MIGRATE_PEER2PEER,VIR_MIGRATE_LIVE,VIR_MIGRATE_PERSIST_DEST,VIR_MIGRATE_TUNNELLED"\nlive_migration_uri = qemu+tcp://%s/system\n' |
compilers_ = {
"python": "cpython-head",
"c++": "gcc-head",
"cpp": "gcc-head",
"c": "gcc-head",
"c#": "mono-head",
"javascript": "nodejs-head",
"js": "nodejs-head",
"coffeescript": "coffeescript-head",
"cs": "coffeescript-head",
"java": "openjdk-head",
"haskell": "ghc-8.4.2",
"bash": "bash",
"cmake": "cmake-head",
"crystal": "crystal-head",
"elixir": "elixir-head",
"d": "dmd-head",
"ruby": "ruby-head",
"rust": "rust-head",
"sql": "sqlite-head",
"sqlite": "sqlite-head",
"lisp": "clisp-2.49",
"go": "go-head",
"f#": "fsharp-head",
"scala": "scala-2.13.x",
"swift": "swift-head",
"typescript": "typescript-3.9.5",
"ts": "typescript-3.9.5",
"vim": "vim-head",
"lua": "lua-5.4.0",
"nim": "nim-head",
"php": "php-head",
"perl": "perl-head",
"pony": "pony-head",
}
| compilers_ = {'python': 'cpython-head', 'c++': 'gcc-head', 'cpp': 'gcc-head', 'c': 'gcc-head', 'c#': 'mono-head', 'javascript': 'nodejs-head', 'js': 'nodejs-head', 'coffeescript': 'coffeescript-head', 'cs': 'coffeescript-head', 'java': 'openjdk-head', 'haskell': 'ghc-8.4.2', 'bash': 'bash', 'cmake': 'cmake-head', 'crystal': 'crystal-head', 'elixir': 'elixir-head', 'd': 'dmd-head', 'ruby': 'ruby-head', 'rust': 'rust-head', 'sql': 'sqlite-head', 'sqlite': 'sqlite-head', 'lisp': 'clisp-2.49', 'go': 'go-head', 'f#': 'fsharp-head', 'scala': 'scala-2.13.x', 'swift': 'swift-head', 'typescript': 'typescript-3.9.5', 'ts': 'typescript-3.9.5', 'vim': 'vim-head', 'lua': 'lua-5.4.0', 'nim': 'nim-head', 'php': 'php-head', 'perl': 'perl-head', 'pony': 'pony-head'} |
"""Contains some helper functions to display time as a nicely formatted string"""
intervals = (
('weeks', 604800), # 60 * 60 * 24 * 7
('days', 86400), # 60 * 60 * 24
('hours', 3600), # 60 * 60
('minutes', 60),
('seconds', 1),
)
def display_time(seconds, granularity=2):
"""Display time as a nicely formatted string"""
result = []
if seconds == 0:
return "0 second"
for name, count in intervals:
value = seconds // count
if value:
seconds -= value * count
if value == 1:
name = name.rstrip('s')
result.append("{} {}".format(value, name))
return ', '.join(result[:granularity])
| """Contains some helper functions to display time as a nicely formatted string"""
intervals = (('weeks', 604800), ('days', 86400), ('hours', 3600), ('minutes', 60), ('seconds', 1))
def display_time(seconds, granularity=2):
"""Display time as a nicely formatted string"""
result = []
if seconds == 0:
return '0 second'
for (name, count) in intervals:
value = seconds // count
if value:
seconds -= value * count
if value == 1:
name = name.rstrip('s')
result.append('{} {}'.format(value, name))
return ', '.join(result[:granularity]) |
class News(object):
news_id: int
title: str
image: str
def __init__(self, news_id: int, title: str, image: str):
self.news_id = news_id
self.title = title
self.image = image
class NewsContent(object):
news_id: int
title: str
content: str
def __init__(self, news_id: int, title: str, content: str):
self.news_id = news_id
self.title = title
self.content = content
| class News(object):
news_id: int
title: str
image: str
def __init__(self, news_id: int, title: str, image: str):
self.news_id = news_id
self.title = title
self.image = image
class Newscontent(object):
news_id: int
title: str
content: str
def __init__(self, news_id: int, title: str, content: str):
self.news_id = news_id
self.title = title
self.content = content |
class Error(Exception):
"""
Base class for exceptions in this module
"""
pass
class InstrumentError(Error):
"""
Exception raised when trying to access a pyvisa instrument that is not connected
Attributes
----------
_resourceAddress: str
The address of the resource
_resourceName: str
The name of the resource (instrument)
_message: str
An explanation of the error
"""
def __init__(self, address: str, resource_name: str, message: str):
"""
Parameters
---------
address: str
The address of the resource
resource_name: str
The name of the resource
message: str
The explanation of the error
"""
self._resourceAddress = address
self._resourceName = resource_name
self._message = message
@property
def address(self) -> str:
return self._resourceAddress
@property
def resource_name(self) -> str:
return self._resourceName
@property
def message(self) -> str:
return self._message
class HotplateError(InstrumentError):
_heatingStatus = 1 # Not heating
_temperatureSetpoint = 25
def __init__(self, address: str, resource_name: str, message: str):
super().__init__(address, resource_name, message)
@property
def heating_status(self) -> bool:
return self._heatingStatus
def set_heating_status(self, status: bool):
self._heatingStatus = status
@property
def temperature_setpoint(self) -> int:
return self._temperatureSetpoint
def set_temperature_setpoint(self, setpoint: int):
self._temperatureSetpoint = setpoint
class ConfigurationError(Error):
"""
Base class for Configuration Errors
Attributes
----------
_message: str
The explanation of the error
"""
def __init__(self, message: str):
"""
Parameters
---------
message: str
The explanation of the error.
"""
self._message = message
@property
def message(self):
return self._message
class BTSSystemConfigError(ConfigurationError):
"""
A Class representing a System Configuration Error
Attributes
----------
_testUnits: int
The number of test units in the system
"""
def __init__(self, message: str, test_units: int):
"""
Parameters
----------
message: str
The explanation of the error
test_units: int
The number of test units in the system
"""
super().__init__(message=message)
self._testUnits = test_units
@property
def test_units(self) -> int:
return self._testUnits
class DLCPSystemConfigError(ConfigurationError):
"""
A Class representing a System Configuration Error
Attributes
----------
_testUnits: int
The number of test units in the system
"""
def __init__(self, message: str):
"""
Parameters
----------
message: str
The explanation of the error
test_units: int
The number of test units in the system
"""
super().__init__(message=message)
class ArduinoError(InstrumentError):
"""
This class represents an Arduino Error
"""
def __init__(self, address: str, name: str, message: str):
super().__init__(address=address, resource_name=name, message=message)
class ArduinoSketchError(ArduinoError):
"""
This class represents an error caused by handling an Arduino Sketch
Attributes
----------
_sketchFile: str
The sketch file that produced the error
"""
_sketchFile: str = None
def __init__(self, address: str, name: str, sketch_file: str, message: str):
super().__init__(address=address, name=name, message=message)
self._sketchFile = sketch_file
@property
def sketch_file(self) -> str:
return self._sketchFile
| class Error(Exception):
"""
Base class for exceptions in this module
"""
pass
class Instrumenterror(Error):
"""
Exception raised when trying to access a pyvisa instrument that is not connected
Attributes
----------
_resourceAddress: str
The address of the resource
_resourceName: str
The name of the resource (instrument)
_message: str
An explanation of the error
"""
def __init__(self, address: str, resource_name: str, message: str):
"""
Parameters
---------
address: str
The address of the resource
resource_name: str
The name of the resource
message: str
The explanation of the error
"""
self._resourceAddress = address
self._resourceName = resource_name
self._message = message
@property
def address(self) -> str:
return self._resourceAddress
@property
def resource_name(self) -> str:
return self._resourceName
@property
def message(self) -> str:
return self._message
class Hotplateerror(InstrumentError):
_heating_status = 1
_temperature_setpoint = 25
def __init__(self, address: str, resource_name: str, message: str):
super().__init__(address, resource_name, message)
@property
def heating_status(self) -> bool:
return self._heatingStatus
def set_heating_status(self, status: bool):
self._heatingStatus = status
@property
def temperature_setpoint(self) -> int:
return self._temperatureSetpoint
def set_temperature_setpoint(self, setpoint: int):
self._temperatureSetpoint = setpoint
class Configurationerror(Error):
"""
Base class for Configuration Errors
Attributes
----------
_message: str
The explanation of the error
"""
def __init__(self, message: str):
"""
Parameters
---------
message: str
The explanation of the error.
"""
self._message = message
@property
def message(self):
return self._message
class Btssystemconfigerror(ConfigurationError):
"""
A Class representing a System Configuration Error
Attributes
----------
_testUnits: int
The number of test units in the system
"""
def __init__(self, message: str, test_units: int):
"""
Parameters
----------
message: str
The explanation of the error
test_units: int
The number of test units in the system
"""
super().__init__(message=message)
self._testUnits = test_units
@property
def test_units(self) -> int:
return self._testUnits
class Dlcpsystemconfigerror(ConfigurationError):
"""
A Class representing a System Configuration Error
Attributes
----------
_testUnits: int
The number of test units in the system
"""
def __init__(self, message: str):
"""
Parameters
----------
message: str
The explanation of the error
test_units: int
The number of test units in the system
"""
super().__init__(message=message)
class Arduinoerror(InstrumentError):
"""
This class represents an Arduino Error
"""
def __init__(self, address: str, name: str, message: str):
super().__init__(address=address, resource_name=name, message=message)
class Arduinosketcherror(ArduinoError):
"""
This class represents an error caused by handling an Arduino Sketch
Attributes
----------
_sketchFile: str
The sketch file that produced the error
"""
_sketch_file: str = None
def __init__(self, address: str, name: str, sketch_file: str, message: str):
super().__init__(address=address, name=name, message=message)
self._sketchFile = sketch_file
@property
def sketch_file(self) -> str:
return self._sketchFile |
"""
Programme additionnant une liste de nombres
"""
def addition(nombres):
somme = 0
for nombre in nombres:
somme += nombre
return somme
# Exemple
print(addition([1, 2, 3]))
# >>> 6
| """
Programme additionnant une liste de nombres
"""
def addition(nombres):
somme = 0
for nombre in nombres:
somme += nombre
return somme
print(addition([1, 2, 3])) |
numbers = input()
list_of_nums = numbers.split(',')
tuple_of_nums = tuple(list_of_nums)
print(list_of_nums)
print(tuple_of_nums) | numbers = input()
list_of_nums = numbers.split(',')
tuple_of_nums = tuple(list_of_nums)
print(list_of_nums)
print(tuple_of_nums) |
# Generated by h2py z /usr/include/sys/cdio.h
CDROM_LBA = 0x01
CDROM_MSF = 0x02
CDROM_DATA_TRACK = 0x04
CDROM_LEADOUT = 0xAA
CDROM_AUDIO_INVALID = 0x00
CDROM_AUDIO_PLAY = 0x11
CDROM_AUDIO_PAUSED = 0x12
CDROM_AUDIO_COMPLETED = 0x13
CDROM_AUDIO_ERROR = 0x14
CDROM_AUDIO_NO_STATUS = 0x15
CDROM_DA_NO_SUBCODE = 0x00
CDROM_DA_SUBQ = 0x01
CDROM_DA_ALL_SUBCODE = 0x02
CDROM_DA_SUBCODE_ONLY = 0x03
CDROM_XA_DATA = 0x00
CDROM_XA_SECTOR_DATA = 0x01
CDROM_XA_DATA_W_ERROR = 0x02
CDROM_BLK_512 = 512
CDROM_BLK_1024 = 1024
CDROM_BLK_2048 = 2048
CDROM_BLK_2056 = 2056
CDROM_BLK_2336 = 2336
CDROM_BLK_2340 = 2340
CDROM_BLK_2352 = 2352
CDROM_BLK_2368 = 2368
CDROM_BLK_2448 = 2448
CDROM_BLK_2646 = 2646
CDROM_BLK_2647 = 2647
CDROM_BLK_SUBCODE = 96
CDROM_NORMAL_SPEED = 0x00
CDROM_DOUBLE_SPEED = 0x01
CDROM_QUAD_SPEED = 0x03
CDROM_TWELVE_SPEED = 0x0C
CDROM_MAXIMUM_SPEED = 0xff
CDIOC = (0x04 << 8)
CDROMPAUSE = (CDIOC|151)
CDROMRESUME = (CDIOC|152)
CDROMPLAYMSF = (CDIOC|153)
CDROMPLAYTRKIND = (CDIOC|154)
CDROMREADTOCHDR = (CDIOC|155)
CDROMREADTOCENTRY = (CDIOC|156)
CDROMSTOP = (CDIOC|157)
CDROMSTART = (CDIOC|158)
CDROMEJECT = (CDIOC|159)
CDROMVOLCTRL = (CDIOC|160)
CDROMSUBCHNL = (CDIOC|161)
CDROMREADMODE2 = (CDIOC|162)
CDROMREADMODE1 = (CDIOC|163)
CDROMREADOFFSET = (CDIOC|164)
CDROMGBLKMODE = (CDIOC|165)
CDROMSBLKMODE = (CDIOC|166)
CDROMCDDA = (CDIOC|167)
CDROMCDXA = (CDIOC|168)
CDROMSUBCODE = (CDIOC|169)
CDROMGDRVSPEED = (CDIOC|170)
CDROMSDRVSPEED = (CDIOC|171)
SCMD_READ_TOC = 0x43
SCMD_PLAYAUDIO_MSF = 0x47
SCMD_PLAYAUDIO_TI = 0x48
SCMD_PAUSE_RESUME = 0x4B
SCMD_READ_SUBCHANNEL = 0x42
SCMD_PLAYAUDIO10 = 0x45
SCMD_PLAYTRACK_REL10 = 0x49
SCMD_READ_HEADER = 0x44
SCMD_PLAYAUDIO12 = 0xA5
SCMD_PLAYTRACK_REL12 = 0xA9
SCMD_CD_PLAYBACK_CONTROL = 0xC9
SCMD_CD_PLAYBACK_STATUS = 0xC4
SCMD_READ_CDDA = 0xD8
SCMD_READ_CDXA = 0xDB
SCMD_READ_ALL_SUBCODES = 0xDF
CDROM_MODE2_SIZE = 2336
| cdrom_lba = 1
cdrom_msf = 2
cdrom_data_track = 4
cdrom_leadout = 170
cdrom_audio_invalid = 0
cdrom_audio_play = 17
cdrom_audio_paused = 18
cdrom_audio_completed = 19
cdrom_audio_error = 20
cdrom_audio_no_status = 21
cdrom_da_no_subcode = 0
cdrom_da_subq = 1
cdrom_da_all_subcode = 2
cdrom_da_subcode_only = 3
cdrom_xa_data = 0
cdrom_xa_sector_data = 1
cdrom_xa_data_w_error = 2
cdrom_blk_512 = 512
cdrom_blk_1024 = 1024
cdrom_blk_2048 = 2048
cdrom_blk_2056 = 2056
cdrom_blk_2336 = 2336
cdrom_blk_2340 = 2340
cdrom_blk_2352 = 2352
cdrom_blk_2368 = 2368
cdrom_blk_2448 = 2448
cdrom_blk_2646 = 2646
cdrom_blk_2647 = 2647
cdrom_blk_subcode = 96
cdrom_normal_speed = 0
cdrom_double_speed = 1
cdrom_quad_speed = 3
cdrom_twelve_speed = 12
cdrom_maximum_speed = 255
cdioc = 4 << 8
cdrompause = CDIOC | 151
cdromresume = CDIOC | 152
cdromplaymsf = CDIOC | 153
cdromplaytrkind = CDIOC | 154
cdromreadtochdr = CDIOC | 155
cdromreadtocentry = CDIOC | 156
cdromstop = CDIOC | 157
cdromstart = CDIOC | 158
cdromeject = CDIOC | 159
cdromvolctrl = CDIOC | 160
cdromsubchnl = CDIOC | 161
cdromreadmode2 = CDIOC | 162
cdromreadmode1 = CDIOC | 163
cdromreadoffset = CDIOC | 164
cdromgblkmode = CDIOC | 165
cdromsblkmode = CDIOC | 166
cdromcdda = CDIOC | 167
cdromcdxa = CDIOC | 168
cdromsubcode = CDIOC | 169
cdromgdrvspeed = CDIOC | 170
cdromsdrvspeed = CDIOC | 171
scmd_read_toc = 67
scmd_playaudio_msf = 71
scmd_playaudio_ti = 72
scmd_pause_resume = 75
scmd_read_subchannel = 66
scmd_playaudio10 = 69
scmd_playtrack_rel10 = 73
scmd_read_header = 68
scmd_playaudio12 = 165
scmd_playtrack_rel12 = 169
scmd_cd_playback_control = 201
scmd_cd_playback_status = 196
scmd_read_cdda = 216
scmd_read_cdxa = 219
scmd_read_all_subcodes = 223
cdrom_mode2_size = 2336 |
"""
A unit fraction contains 1 in the numerator. The decimal representation of the unit fractions with denominators 2 to 10 are given:
1/2 = 0.5
1/3 = 0.(3)
1/4 = 0.25
1/5 = 0.2
1/6 = 0.1(6)
1/7 = 0.(142857)
1/8 = 0.125
1/9 = 0.(1)
1/10 = 0.1
Where 0.1(6) means 0.166666..., and has a 1-digit recurring cycle. It can be seen that 1/7 has a 6-digit recurring cycle.
Find the value of d < 1000 for which 1/d contains the longest recurring cycle in its decimal fraction part.
"""
max_s = 100
def rep_len(n):
# http://mathworld.wolfram.com/DecimalExpansion.html
for s in range(max_s):
for t in range(1, n):
if 10**s == (10**(s+t)) % n:
return t
return -1
def longest_d(limit):
m = 1
d = -1
for n in range(2, limit):
# In base-10 it's factors 2 and 5 will not produce recurring cycles. 3 won't produce anything of significant lenth.
# Calculation is crazy slow without this.
if n % 2 != 0 and n % 3 != 0 and n % 5 != 0:
r = rep_len(n)
if r > m:
m = r
d = n
return d
if __name__ == "__main__":
print(longest_d(1000))
| """
A unit fraction contains 1 in the numerator. The decimal representation of the unit fractions with denominators 2 to 10 are given:
1/2 = 0.5
1/3 = 0.(3)
1/4 = 0.25
1/5 = 0.2
1/6 = 0.1(6)
1/7 = 0.(142857)
1/8 = 0.125
1/9 = 0.(1)
1/10 = 0.1
Where 0.1(6) means 0.166666..., and has a 1-digit recurring cycle. It can be seen that 1/7 has a 6-digit recurring cycle.
Find the value of d < 1000 for which 1/d contains the longest recurring cycle in its decimal fraction part.
"""
max_s = 100
def rep_len(n):
for s in range(max_s):
for t in range(1, n):
if 10 ** s == 10 ** (s + t) % n:
return t
return -1
def longest_d(limit):
m = 1
d = -1
for n in range(2, limit):
if n % 2 != 0 and n % 3 != 0 and (n % 5 != 0):
r = rep_len(n)
if r > m:
m = r
d = n
return d
if __name__ == '__main__':
print(longest_d(1000)) |
"""
General-purpose helpers not related to the framework itself
(neither to the reactor nor to the engines nor to the structs),
which are used to prepare and control the runtime environment.
These are things that should better be in the standard library
or in the dependencies.
Utilities do not depend on anything in the framework. For most cases,
they do not even implement any entities or behaviours of the domain
of K8s Operators, but rather some unrelated low-level patterns.
As a rule of thumb, helpers MUST be abstracted from the framework
to such an extent that they could be extracted as reusable libraries.
If they implement concepts of the framework, they are not "helpers"
(consider making them _kits, structs, engines, or the reactor parts).
"""
| """
General-purpose helpers not related to the framework itself
(neither to the reactor nor to the engines nor to the structs),
which are used to prepare and control the runtime environment.
These are things that should better be in the standard library
or in the dependencies.
Utilities do not depend on anything in the framework. For most cases,
they do not even implement any entities or behaviours of the domain
of K8s Operators, but rather some unrelated low-level patterns.
As a rule of thumb, helpers MUST be abstracted from the framework
to such an extent that they could be extracted as reusable libraries.
If they implement concepts of the framework, they are not "helpers"
(consider making them _kits, structs, engines, or the reactor parts).
""" |
def can_build(platform):
return platform != "android"
def configure(env):
pass
| def can_build(platform):
return platform != 'android'
def configure(env):
pass |
# Divide and Conquer algorithm
def find_max(nums, left, right):
"""
find max value in list
:param nums: contains elements
:param left: index of first element
:param right: index of last element
:return: max in nums
>>> nums = [1, 3, 5, 7, 9, 2, 4, 6, 8, 10]
>>> find_max(nums, 0, len(nums) - 1) == max(nums)
True
"""
if left == right:
return nums[left]
mid = (left + right) >> 1 # the middle
left_max = find_max(nums, left, mid) # find max in range[left, mid]
right_max = find_max(nums, mid + 1, right) # find max in range[mid + 1, right]
return left_max if left_max >= right_max else right_max
if __name__ == "__main__":
nums = [1, 3, 5, 7, 9, 2, 4, 6, 8, 10]
assert find_max(nums, 0, len(nums) - 1) == 10
| def find_max(nums, left, right):
"""
find max value in list
:param nums: contains elements
:param left: index of first element
:param right: index of last element
:return: max in nums
>>> nums = [1, 3, 5, 7, 9, 2, 4, 6, 8, 10]
>>> find_max(nums, 0, len(nums) - 1) == max(nums)
True
"""
if left == right:
return nums[left]
mid = left + right >> 1
left_max = find_max(nums, left, mid)
right_max = find_max(nums, mid + 1, right)
return left_max if left_max >= right_max else right_max
if __name__ == '__main__':
nums = [1, 3, 5, 7, 9, 2, 4, 6, 8, 10]
assert find_max(nums, 0, len(nums) - 1) == 10 |
"""
Given the head of a singly linked list, group all the nodes with odd indices together followed by the nodes with even indices, and return the reordered list.
The first node is considered odd, and the second node is even, and so on.
Note that the relative order inside both the even and odd groups should remain as it was in the input.
You must solve the problem in O(1) extra space complexity and O(n) time complexity.
Example 1:
Input: head = [1,2,3,4,5]
Output: [1,3,5,2,4]
Example 2:
Input: head = [2,1,3,5,6,4,7]
Output: [2,3,6,7,1,5,4]
Constraints:
n == number of nodes in the linked list
0 <= n <= 10^4
-10^6 <= Node.val <= 10^6
"""
# Definition for singly-linked list.
class ListNode:
def __init__(self, val=0, next=None):
self.val = val
self.next = next
class Solution:
def oddEvenList(self, head: Optional[ListNode]) -> Optional[ListNode]:
if not head or not head.next:
return head
odd_head = head
odd_cur = head
even_head = head.next
even_cur = even_head
cur = head.next.next
n = 3
while cur:
# odd
if n % 2 != 0:
tmp = cur
cur = cur.next
odd_cur.next = tmp
odd_cur = odd_cur.next
n += 1
# even
else:
tmp = cur
cur = cur.next
even_cur.next = tmp
even_cur = even_cur.next
n += 1
even_cur.next = None
odd_cur.next = even_head
return odd_head
| """
Given the head of a singly linked list, group all the nodes with odd indices together followed by the nodes with even indices, and return the reordered list.
The first node is considered odd, and the second node is even, and so on.
Note that the relative order inside both the even and odd groups should remain as it was in the input.
You must solve the problem in O(1) extra space complexity and O(n) time complexity.
Example 1:
Input: head = [1,2,3,4,5]
Output: [1,3,5,2,4]
Example 2:
Input: head = [2,1,3,5,6,4,7]
Output: [2,3,6,7,1,5,4]
Constraints:
n == number of nodes in the linked list
0 <= n <= 10^4
-10^6 <= Node.val <= 10^6
"""
class Listnode:
def __init__(self, val=0, next=None):
self.val = val
self.next = next
class Solution:
def odd_even_list(self, head: Optional[ListNode]) -> Optional[ListNode]:
if not head or not head.next:
return head
odd_head = head
odd_cur = head
even_head = head.next
even_cur = even_head
cur = head.next.next
n = 3
while cur:
if n % 2 != 0:
tmp = cur
cur = cur.next
odd_cur.next = tmp
odd_cur = odd_cur.next
n += 1
else:
tmp = cur
cur = cur.next
even_cur.next = tmp
even_cur = even_cur.next
n += 1
even_cur.next = None
odd_cur.next = even_head
return odd_head |
# Copyright 2014 The Bazel Authors. All rights reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
load(
"//go/private:context.bzl",
"go_context",
)
load(
"//go/private:common.bzl",
"asm_exts",
"cgo_exts",
"go_exts",
)
load(
"//go/private:providers.bzl",
"GoLibrary",
"GoSDK",
)
load(
"//go/private/rules:transition.bzl",
"go_transition_rule",
)
load(
"//go/private:mode.bzl",
"LINKMODE_PLUGIN",
"LINKMODE_SHARED",
)
def _go_binary_impl(ctx):
"""go_binary_impl emits actions for compiling and linking a go executable."""
go = go_context(ctx)
is_main = go.mode.link not in (LINKMODE_SHARED, LINKMODE_PLUGIN)
library = go.new_library(go, importable = False, is_main = is_main)
source = go.library_to_source(go, ctx.attr, library, ctx.coverage_instrumented())
name = ctx.attr.basename
if not name:
name = ctx.label.name
executable = None
if ctx.attr.out:
# Use declare_file instead of attr.output(). When users set output files
# directly, Bazel warns them not to use the same name as the rule, which is
# the common case with go_binary.
executable = ctx.actions.declare_file(ctx.attr.out)
archive, executable, runfiles = go.binary(
go,
name = name,
source = source,
gc_linkopts = gc_linkopts(ctx),
version_file = ctx.version_file,
info_file = ctx.info_file,
executable = executable,
)
return [
library,
source,
archive,
OutputGroupInfo(
cgo_exports = archive.cgo_exports,
compilation_outputs = [archive.data.file],
),
DefaultInfo(
files = depset([executable]),
runfiles = runfiles,
executable = executable,
),
]
_go_binary_kwargs = {
"implementation": _go_binary_impl,
"attrs": {
"srcs": attr.label_list(allow_files = go_exts + asm_exts + cgo_exts),
"data": attr.label_list(allow_files = True),
"deps": attr.label_list(
providers = [GoLibrary],
),
"embed": attr.label_list(
providers = [GoLibrary],
),
"embedsrcs": attr.label_list(allow_files = True),
"importpath": attr.string(),
"gc_goopts": attr.string_list(),
"gc_linkopts": attr.string_list(),
"x_defs": attr.string_dict(),
"basename": attr.string(),
"out": attr.string(),
"cgo": attr.bool(),
"cdeps": attr.label_list(),
"cppopts": attr.string_list(),
"copts": attr.string_list(),
"cxxopts": attr.string_list(),
"clinkopts": attr.string_list(),
"_go_context_data": attr.label(default = "//:go_context_data"),
},
"executable": True,
"toolchains": ["@io_bazel_rules_go//go:toolchain"],
}
go_binary = rule(**_go_binary_kwargs)
go_transition_binary = go_transition_rule(**_go_binary_kwargs)
def _go_tool_binary_impl(ctx):
sdk = ctx.attr.sdk[GoSDK]
name = ctx.label.name
if sdk.goos == "windows":
name += ".exe"
cout = ctx.actions.declare_file(name + ".a")
if sdk.goos == "windows":
cmd = "@echo off\n {go} tool compile -o {cout} -trimpath=%cd% {srcs}".format(
go = sdk.go.path.replace("/", "\\"),
cout = cout.path,
srcs = " ".join([f.path for f in ctx.files.srcs]),
)
bat = ctx.actions.declare_file(name + ".bat")
ctx.actions.write(
output = bat,
content = cmd,
)
ctx.actions.run(
executable = bat.path.replace("/", "\\"),
inputs = sdk.libs + sdk.headers + sdk.tools + ctx.files.srcs + [sdk.go],
outputs = [cout],
env = {"GOROOT": sdk.root_file.dirname}, # NOTE(#2005): avoid realpath in sandbox
mnemonic = "GoToolchainBinaryCompile",
)
else:
cmd = "{go} tool compile -o {cout} -trimpath=$PWD {srcs}".format(
go = sdk.go.path,
cout = cout.path,
srcs = " ".join([f.path for f in ctx.files.srcs]),
)
ctx.actions.run_shell(
command = cmd,
inputs = sdk.libs + sdk.headers + sdk.tools + ctx.files.srcs + [sdk.go],
outputs = [cout],
env = {"GOROOT": sdk.root_file.dirname}, # NOTE(#2005): avoid realpath in sandbox
mnemonic = "GoToolchainBinaryCompile",
)
out = ctx.actions.declare_file(name)
largs = ctx.actions.args()
largs.add_all(["tool", "link"])
largs.add("-o", out)
largs.add(cout)
ctx.actions.run(
executable = sdk.go,
arguments = [largs],
inputs = sdk.libs + sdk.headers + sdk.tools + [cout],
outputs = [out],
mnemonic = "GoToolchainBinary",
)
return [DefaultInfo(
files = depset([out]),
executable = out,
)]
go_tool_binary = rule(
implementation = _go_tool_binary_impl,
attrs = {
"srcs": attr.label_list(
allow_files = True,
doc = "Source files for the binary. Must be in 'package main'.",
),
"sdk": attr.label(
mandatory = True,
providers = [GoSDK],
doc = "The SDK containing tools and libraries to build this binary",
),
},
executable = True,
doc = """Used instead of go_binary for executables used in the toolchain.
go_tool_binary depends on tools and libraries that are part of the Go SDK.
It does not depend on other toolchains. It can only compile binaries that
just have a main package and only depend on the standard library and don't
require build constraints.
""",
)
def gc_linkopts(ctx):
gc_linkopts = [
ctx.expand_make_variables("gc_linkopts", f, {})
for f in ctx.attr.gc_linkopts
]
return gc_linkopts
| load('//go/private:context.bzl', 'go_context')
load('//go/private:common.bzl', 'asm_exts', 'cgo_exts', 'go_exts')
load('//go/private:providers.bzl', 'GoLibrary', 'GoSDK')
load('//go/private/rules:transition.bzl', 'go_transition_rule')
load('//go/private:mode.bzl', 'LINKMODE_PLUGIN', 'LINKMODE_SHARED')
def _go_binary_impl(ctx):
"""go_binary_impl emits actions for compiling and linking a go executable."""
go = go_context(ctx)
is_main = go.mode.link not in (LINKMODE_SHARED, LINKMODE_PLUGIN)
library = go.new_library(go, importable=False, is_main=is_main)
source = go.library_to_source(go, ctx.attr, library, ctx.coverage_instrumented())
name = ctx.attr.basename
if not name:
name = ctx.label.name
executable = None
if ctx.attr.out:
executable = ctx.actions.declare_file(ctx.attr.out)
(archive, executable, runfiles) = go.binary(go, name=name, source=source, gc_linkopts=gc_linkopts(ctx), version_file=ctx.version_file, info_file=ctx.info_file, executable=executable)
return [library, source, archive, output_group_info(cgo_exports=archive.cgo_exports, compilation_outputs=[archive.data.file]), default_info(files=depset([executable]), runfiles=runfiles, executable=executable)]
_go_binary_kwargs = {'implementation': _go_binary_impl, 'attrs': {'srcs': attr.label_list(allow_files=go_exts + asm_exts + cgo_exts), 'data': attr.label_list(allow_files=True), 'deps': attr.label_list(providers=[GoLibrary]), 'embed': attr.label_list(providers=[GoLibrary]), 'embedsrcs': attr.label_list(allow_files=True), 'importpath': attr.string(), 'gc_goopts': attr.string_list(), 'gc_linkopts': attr.string_list(), 'x_defs': attr.string_dict(), 'basename': attr.string(), 'out': attr.string(), 'cgo': attr.bool(), 'cdeps': attr.label_list(), 'cppopts': attr.string_list(), 'copts': attr.string_list(), 'cxxopts': attr.string_list(), 'clinkopts': attr.string_list(), '_go_context_data': attr.label(default='//:go_context_data')}, 'executable': True, 'toolchains': ['@io_bazel_rules_go//go:toolchain']}
go_binary = rule(**_go_binary_kwargs)
go_transition_binary = go_transition_rule(**_go_binary_kwargs)
def _go_tool_binary_impl(ctx):
sdk = ctx.attr.sdk[GoSDK]
name = ctx.label.name
if sdk.goos == 'windows':
name += '.exe'
cout = ctx.actions.declare_file(name + '.a')
if sdk.goos == 'windows':
cmd = '@echo off\n {go} tool compile -o {cout} -trimpath=%cd% {srcs}'.format(go=sdk.go.path.replace('/', '\\'), cout=cout.path, srcs=' '.join([f.path for f in ctx.files.srcs]))
bat = ctx.actions.declare_file(name + '.bat')
ctx.actions.write(output=bat, content=cmd)
ctx.actions.run(executable=bat.path.replace('/', '\\'), inputs=sdk.libs + sdk.headers + sdk.tools + ctx.files.srcs + [sdk.go], outputs=[cout], env={'GOROOT': sdk.root_file.dirname}, mnemonic='GoToolchainBinaryCompile')
else:
cmd = '{go} tool compile -o {cout} -trimpath=$PWD {srcs}'.format(go=sdk.go.path, cout=cout.path, srcs=' '.join([f.path for f in ctx.files.srcs]))
ctx.actions.run_shell(command=cmd, inputs=sdk.libs + sdk.headers + sdk.tools + ctx.files.srcs + [sdk.go], outputs=[cout], env={'GOROOT': sdk.root_file.dirname}, mnemonic='GoToolchainBinaryCompile')
out = ctx.actions.declare_file(name)
largs = ctx.actions.args()
largs.add_all(['tool', 'link'])
largs.add('-o', out)
largs.add(cout)
ctx.actions.run(executable=sdk.go, arguments=[largs], inputs=sdk.libs + sdk.headers + sdk.tools + [cout], outputs=[out], mnemonic='GoToolchainBinary')
return [default_info(files=depset([out]), executable=out)]
go_tool_binary = rule(implementation=_go_tool_binary_impl, attrs={'srcs': attr.label_list(allow_files=True, doc="Source files for the binary. Must be in 'package main'."), 'sdk': attr.label(mandatory=True, providers=[GoSDK], doc='The SDK containing tools and libraries to build this binary')}, executable=True, doc="Used instead of go_binary for executables used in the toolchain.\n\ngo_tool_binary depends on tools and libraries that are part of the Go SDK.\nIt does not depend on other toolchains. It can only compile binaries that\njust have a main package and only depend on the standard library and don't\nrequire build constraints.\n")
def gc_linkopts(ctx):
gc_linkopts = [ctx.expand_make_variables('gc_linkopts', f, {}) for f in ctx.attr.gc_linkopts]
return gc_linkopts |
#!/bin/env python3
def gift_area(l, w, h):
side_a = l*w
side_b = w*h
side_c = l*h
return 2*side_a+2*side_b+2*side_c+min((side_a, side_b, side_c))
def gift_ribbon(l, w, h):
side_a = 2*l+2*w
side_b = 2*w+2*h
side_c = 2*l+2*h
ribbon = min((side_a, side_b, side_c))
ribbon += l*w*h
return ribbon
if __name__ == "__main__":
with open("d02.txt") as f:
lines = f.readlines()
gifts = []
for l in lines:
fields = l.split("x")
gifts.append([int(f) for f in fields])
area = 0
ribbon = 0
for g in gifts:
area += gift_area(g[0], g[1], g[2])
ribbon += gift_ribbon(g[0], g[1], g[2])
print(area)
print(ribbon)
| def gift_area(l, w, h):
side_a = l * w
side_b = w * h
side_c = l * h
return 2 * side_a + 2 * side_b + 2 * side_c + min((side_a, side_b, side_c))
def gift_ribbon(l, w, h):
side_a = 2 * l + 2 * w
side_b = 2 * w + 2 * h
side_c = 2 * l + 2 * h
ribbon = min((side_a, side_b, side_c))
ribbon += l * w * h
return ribbon
if __name__ == '__main__':
with open('d02.txt') as f:
lines = f.readlines()
gifts = []
for l in lines:
fields = l.split('x')
gifts.append([int(f) for f in fields])
area = 0
ribbon = 0
for g in gifts:
area += gift_area(g[0], g[1], g[2])
ribbon += gift_ribbon(g[0], g[1], g[2])
print(area)
print(ribbon) |
class C:
pass
def method(x):
pass
c = C()
method(1) | class C:
pass
def method(x):
pass
c = c()
method(1) |
tb = [54, 0,55,54,61,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
66, 0,64,66,61, 0, 0, 0, 0, 0, 0 ,0, 0, 0, 0, 0,
54, 0,55,54,61, 0,66, 0,64]
expander = lambda i: [i, 300] if i > 0 else [0,0]
tkm = [expander(i) for i in tb]
print(tkm) | tb = [54, 0, 55, 54, 61, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 66, 0, 64, 66, 61, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 54, 0, 55, 54, 61, 0, 66, 0, 64]
expander = lambda i: [i, 300] if i > 0 else [0, 0]
tkm = [expander(i) for i in tb]
print(tkm) |
# Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. The ASF licenses this file
# to you under the Apache License, Version 2.0 (the
# "License"); you may not use this file except in compliance
# with the License. You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing,
# software distributed under the License is distributed on an
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
# KIND, either express or implied. See the License for the
# specific language governing permissions and limitations
# under the License.
def enclose_param(param: str) -> str:
"""
Replace all single quotes in parameter by two single quotes and enclose param in single quote.
.. seealso::
https://docs.snowflake.com/en/sql-reference/data-types-text.html#single-quoted-string-constants
Examples:
.. code-block:: python
enclose_param("without quotes") # Returns: 'without quotes'
enclose_param("'with quotes'") # Returns: '''with quotes'''
enclose_param("Today's sales projections") # Returns: 'Today''s sales projections'
enclose_param("sample/john's.csv") # Returns: 'sample/john''s.csv'
enclose_param(".*'awesome'.*[.]csv") # Returns: '.*''awesome''.*[.]csv'
:param param: parameter which required single quotes enclosure.
"""
return f"""'{param.replace("'", "''")}'"""
| def enclose_param(param: str) -> str:
"""
Replace all single quotes in parameter by two single quotes and enclose param in single quote.
.. seealso::
https://docs.snowflake.com/en/sql-reference/data-types-text.html#single-quoted-string-constants
Examples:
.. code-block:: python
enclose_param("without quotes") # Returns: 'without quotes'
enclose_param("'with quotes'") # Returns: '''with quotes'''
enclose_param("Today's sales projections") # Returns: 'Today''s sales projections'
enclose_param("sample/john's.csv") # Returns: 'sample/john''s.csv'
enclose_param(".*'awesome'.*[.]csv") # Returns: '.*''awesome''.*[.]csv'
:param param: parameter which required single quotes enclosure.
"""
return f"""'{param.replace("'", "''")}'""" |
class MenuItem(Menu, IComponent, IDisposable):
"""
Represents an individual item that is displayed within a System.Windows.Forms.MainMenu or System.Windows.Forms.ContextMenu. Although System.Windows.Forms.ToolStripMenuItem replaces and adds functionality to the System.Windows.Forms.MenuItem control of previous versions,System.Windows.Forms.MenuItem is retained for both backward compatibility and future use if you choose.
MenuItem()
MenuItem(text: str)
MenuItem(text: str,onClick: EventHandler)
MenuItem(text: str,onClick: EventHandler,shortcut: Shortcut)
MenuItem(text: str,items: Array[MenuItem])
MenuItem(mergeType: MenuMerge,mergeOrder: int,shortcut: Shortcut,text: str,onClick: EventHandler,onPopup: EventHandler,onSelect: EventHandler,items: Array[MenuItem])
"""
def CloneMenu(self):
"""
CloneMenu(self: MenuItem) -> MenuItem
Creates a copy of the current System.Windows.Forms.MenuItem.
Returns: A System.Windows.Forms.MenuItem that represents the duplicated menu item.
"""
pass
def CreateMenuHandle(self, *args):
"""
CreateMenuHandle(self: Menu) -> IntPtr
Creates a new handle to the System.Windows.Forms.Menu.
Returns: A handle to the menu if the method succeeds; otherwise,null.
"""
pass
def Dispose(self):
"""
Dispose(self: MenuItem,disposing: bool)
Disposes of the resources (other than memory) used by the System.Windows.Forms.MenuItem.
disposing: true to release both managed and unmanaged resources; false to release only unmanaged resources.
"""
pass
def FindMergePosition(self, *args):
"""
FindMergePosition(self: Menu,mergeOrder: int) -> int
Returns the position at which a menu item should be inserted into the menu.
mergeOrder: The merge order position for the menu item to be merged.
Returns: The position at which a menu item should be inserted into the menu.
"""
pass
def GetService(self, *args):
"""
GetService(self: Component,service: Type) -> object
Returns an object that represents a service provided by the System.ComponentModel.Component or
by its System.ComponentModel.Container.
service: A service provided by the System.ComponentModel.Component.
Returns: An System.Object that represents a service provided by the System.ComponentModel.Component,or
null if the System.ComponentModel.Component does not provide the specified service.
"""
pass
def MemberwiseClone(self, *args):
"""
MemberwiseClone(self: MarshalByRefObject,cloneIdentity: bool) -> MarshalByRefObject
Creates a shallow copy of the current System.MarshalByRefObject object.
cloneIdentity: false to delete the current System.MarshalByRefObject object's identity,which will cause the
object to be assigned a new identity when it is marshaled across a remoting boundary. A value of
false is usually appropriate. true to copy the current System.MarshalByRefObject object's
identity to its clone,which will cause remoting client calls to be routed to the remote server
object.
Returns: A shallow copy of the current System.MarshalByRefObject object.
MemberwiseClone(self: object) -> object
Creates a shallow copy of the current System.Object.
Returns: A shallow copy of the current System.Object.
"""
pass
def MergeMenu(self, *__args):
"""
MergeMenu(self: MenuItem,itemSrc: MenuItem)
Merges another menu item with this menu item.
itemSrc: A System.Windows.Forms.MenuItem that specifies the menu item to merge with this one.
MergeMenu(self: MenuItem) -> MenuItem
Merges this System.Windows.Forms.MenuItem with another System.Windows.Forms.MenuItem and returns
the resulting merged System.Windows.Forms.MenuItem.
Returns: A System.Windows.Forms.MenuItem that represents the merged menu item.
"""
pass
def OnClick(self, *args):
"""
OnClick(self: MenuItem,e: EventArgs)
Raises the System.Windows.Forms.MenuItem.Click event.
e: An System.EventArgs that contains the event data.
"""
pass
def OnDrawItem(self, *args):
"""
OnDrawItem(self: MenuItem,e: DrawItemEventArgs)
Raises the System.Windows.Forms.MenuItem.DrawItem event.
e: A System.Windows.Forms.DrawItemEventArgs that contains the event data.
"""
pass
def OnInitMenuPopup(self, *args):
"""
OnInitMenuPopup(self: MenuItem,e: EventArgs)
Raises the System.Windows.Forms.MenuItem.Popup event.
e: An System.EventArgs that contains the event data.
"""
pass
def OnMeasureItem(self, *args):
"""
OnMeasureItem(self: MenuItem,e: MeasureItemEventArgs)
Raises the System.Windows.Forms.MenuItem.MeasureItem event.
e: A System.Windows.Forms.MeasureItemEventArgs that contains the event data.
"""
pass
def OnPopup(self, *args):
"""
OnPopup(self: MenuItem,e: EventArgs)
Raises the System.Windows.Forms.MenuItem.Popup event.
e: An System.EventArgs that contains the event data.
"""
pass
def OnSelect(self, *args):
"""
OnSelect(self: MenuItem,e: EventArgs)
Raises the System.Windows.Forms.MenuItem.Select event.
e: An System.EventArgs that contains the event data.
"""
pass
def PerformClick(self):
"""
PerformClick(self: MenuItem)
Generates a System.Windows.Forms.Control.Click event for the System.Windows.Forms.MenuItem,
simulating a click by a user.
"""
pass
def PerformSelect(self):
"""
PerformSelect(self: MenuItem)
Raises the System.Windows.Forms.MenuItem.Select event for this menu item.
"""
pass
def ProcessCmdKey(self, *args):
"""
ProcessCmdKey(self: Menu,msg: Message,keyData: Keys) -> (bool,Message)
Processes a command key.
msg: A System.Windows.Forms.Message,passed by reference that represents the window message to
process.
keyData: One of the System.Windows.Forms.Keys values that represents the key to process.
Returns: true if the character was processed by the control; otherwise,false.
"""
pass
def ToString(self):
"""
ToString(self: MenuItem) -> str
Returns a string that represents the System.Windows.Forms.MenuItem.
Returns: A string that represents the current System.Windows.Forms.MenuItem. The string includes the type
and the System.Windows.Forms.MenuItem.Text property of the control.
"""
pass
def __enter__(self, *args):
"""
__enter__(self: IDisposable) -> object
Provides the implementation of __enter__ for objects which implement IDisposable.
"""
pass
def __exit__(self, *args):
"""
__exit__(self: IDisposable,exc_type: object,exc_value: object,exc_back: object)
Provides the implementation of __exit__ for objects which implement IDisposable.
"""
pass
def __init__(self, *args):
""" x.__init__(...) initializes x; see x.__class__.__doc__ for signaturex.__init__(...) initializes x; see x.__class__.__doc__ for signaturex.__init__(...) initializes x; see x.__class__.__doc__ for signature """
pass
@staticmethod
def __new__(self, *__args):
"""
__new__(cls: type)
__new__(cls: type,text: str)
__new__(cls: type,text: str,onClick: EventHandler)
__new__(cls: type,text: str,onClick: EventHandler,shortcut: Shortcut)
__new__(cls: type,text: str,items: Array[MenuItem])
__new__(cls: type,mergeType: MenuMerge,mergeOrder: int,shortcut: Shortcut,text: str,onClick: EventHandler,onPopup: EventHandler,onSelect: EventHandler,items: Array[MenuItem])
"""
pass
def __str__(self, *args):
pass
BarBreak = property(lambda self: object(), lambda self, v: None, lambda self: None)
"""Gets or sets a value indicating whether the System.Windows.Forms.MenuItem is placed on a new line (for a menu item added to a System.Windows.Forms.MainMenu object) or in a new column (for a submenu item or menu item displayed in a System.Windows.Forms.ContextMenu).
Get: BarBreak(self: MenuItem) -> bool
Set: BarBreak(self: MenuItem)=value
"""
Break = property(lambda self: object(), lambda self, v: None, lambda self: None)
"""Gets or sets a value indicating whether the item is placed on a new line (for a menu item added to a System.Windows.Forms.MainMenu object) or in a new column (for a menu item or submenu item displayed in a System.Windows.Forms.ContextMenu).
Get: Break(self: MenuItem) -> bool
Set: Break(self: MenuItem)=value
"""
CanRaiseEvents = property(
lambda self: object(), lambda self, v: None, lambda self: None
)
"""Gets a value indicating whether the component can raise an event.
"""
Checked = property(lambda self: object(), lambda self, v: None, lambda self: None)
"""Gets or sets a value indicating whether a check mark appears next to the text of the menu item.
Get: Checked(self: MenuItem) -> bool
Set: Checked(self: MenuItem)=value
"""
DefaultItem = property(
lambda self: object(), lambda self, v: None, lambda self: None
)
"""Gets or sets a value indicating whether the menu item is the default menu item.
Get: DefaultItem(self: MenuItem) -> bool
Set: DefaultItem(self: MenuItem)=value
"""
DesignMode = property(
lambda self: object(), lambda self, v: None, lambda self: None
)
"""Gets a value that indicates whether the System.ComponentModel.Component is currently in design mode.
"""
Enabled = property(lambda self: object(), lambda self, v: None, lambda self: None)
"""Gets or sets a value indicating whether the menu item is enabled.
Get: Enabled(self: MenuItem) -> bool
Set: Enabled(self: MenuItem)=value
"""
Events = property(lambda self: object(), lambda self, v: None, lambda self: None)
"""Gets the list of event handlers that are attached to this System.ComponentModel.Component.
"""
Index = property(lambda self: object(), lambda self, v: None, lambda self: None)
"""Gets or sets a value indicating the position of the menu item in its parent menu.
Get: Index(self: MenuItem) -> int
Set: Index(self: MenuItem)=value
"""
IsParent = property(lambda self: object(), lambda self, v: None, lambda self: None)
"""Gets a value indicating whether the menu item contains child menu items.
Get: IsParent(self: MenuItem) -> bool
"""
MdiList = property(lambda self: object(), lambda self, v: None, lambda self: None)
"""Gets or sets a value indicating whether the menu item will be populated with a list of the Multiple Document Interface (MDI) child windows that are displayed within the associated form.
Get: MdiList(self: MenuItem) -> bool
Set: MdiList(self: MenuItem)=value
"""
MenuID = property(lambda self: object(), lambda self, v: None, lambda self: None)
"""Gets a value indicating the Windows identifier for this menu item.
"""
MergeOrder = property(
lambda self: object(), lambda self, v: None, lambda self: None
)
"""Gets or sets a value indicating the relative position of the menu item when it is merged with another.
Get: MergeOrder(self: MenuItem) -> int
Set: MergeOrder(self: MenuItem)=value
"""
MergeType = property(lambda self: object(), lambda self, v: None, lambda self: None)
"""Gets or sets a value indicating the behavior of this menu item when its menu is merged with another.
Get: MergeType(self: MenuItem) -> MenuMerge
Set: MergeType(self: MenuItem)=value
"""
Mnemonic = property(lambda self: object(), lambda self, v: None, lambda self: None)
"""Gets a value indicating the mnemonic character that is associated with this menu item.
Get: Mnemonic(self: MenuItem) -> Char
"""
OwnerDraw = property(lambda self: object(), lambda self, v: None, lambda self: None)
"""Gets or sets a value indicating whether the code that you provide draws the menu item or Windows draws the menu item.
Get: OwnerDraw(self: MenuItem) -> bool
Set: OwnerDraw(self: MenuItem)=value
"""
Parent = property(lambda self: object(), lambda self, v: None, lambda self: None)
"""Gets a value indicating the menu that contains this menu item.
Get: Parent(self: MenuItem) -> Menu
"""
RadioCheck = property(
lambda self: object(), lambda self, v: None, lambda self: None
)
"""Gets or sets a value indicating whether the System.Windows.Forms.MenuItem,if checked,displays a radio-button instead of a check mark.
Get: RadioCheck(self: MenuItem) -> bool
Set: RadioCheck(self: MenuItem)=value
"""
Shortcut = property(lambda self: object(), lambda self, v: None, lambda self: None)
"""Gets or sets a value indicating the shortcut key associated with the menu item.
Get: Shortcut(self: MenuItem) -> Shortcut
Set: Shortcut(self: MenuItem)=value
"""
ShowShortcut = property(
lambda self: object(), lambda self, v: None, lambda self: None
)
"""Gets or sets a value indicating whether the shortcut key that is associated with the menu item is displayed next to the menu item caption.
Get: ShowShortcut(self: MenuItem) -> bool
Set: ShowShortcut(self: MenuItem)=value
"""
Text = property(lambda self: object(), lambda self, v: None, lambda self: None)
"""Gets or sets a value indicating the caption of the menu item.
Get: Text(self: MenuItem) -> str
Set: Text(self: MenuItem)=value
"""
Visible = property(lambda self: object(), lambda self, v: None, lambda self: None)
"""Gets or sets a value indicating whether the menu item is visible.
Get: Visible(self: MenuItem) -> bool
Set: Visible(self: MenuItem)=value
"""
Click = None
DrawItem = None
MeasureItem = None
Popup = None
Select = None
| class Menuitem(Menu, IComponent, IDisposable):
"""
Represents an individual item that is displayed within a System.Windows.Forms.MainMenu or System.Windows.Forms.ContextMenu. Although System.Windows.Forms.ToolStripMenuItem replaces and adds functionality to the System.Windows.Forms.MenuItem control of previous versions,System.Windows.Forms.MenuItem is retained for both backward compatibility and future use if you choose.
MenuItem()
MenuItem(text: str)
MenuItem(text: str,onClick: EventHandler)
MenuItem(text: str,onClick: EventHandler,shortcut: Shortcut)
MenuItem(text: str,items: Array[MenuItem])
MenuItem(mergeType: MenuMerge,mergeOrder: int,shortcut: Shortcut,text: str,onClick: EventHandler,onPopup: EventHandler,onSelect: EventHandler,items: Array[MenuItem])
"""
def clone_menu(self):
"""
CloneMenu(self: MenuItem) -> MenuItem
Creates a copy of the current System.Windows.Forms.MenuItem.
Returns: A System.Windows.Forms.MenuItem that represents the duplicated menu item.
"""
pass
def create_menu_handle(self, *args):
"""
CreateMenuHandle(self: Menu) -> IntPtr
Creates a new handle to the System.Windows.Forms.Menu.
Returns: A handle to the menu if the method succeeds; otherwise,null.
"""
pass
def dispose(self):
"""
Dispose(self: MenuItem,disposing: bool)
Disposes of the resources (other than memory) used by the System.Windows.Forms.MenuItem.
disposing: true to release both managed and unmanaged resources; false to release only unmanaged resources.
"""
pass
def find_merge_position(self, *args):
"""
FindMergePosition(self: Menu,mergeOrder: int) -> int
Returns the position at which a menu item should be inserted into the menu.
mergeOrder: The merge order position for the menu item to be merged.
Returns: The position at which a menu item should be inserted into the menu.
"""
pass
def get_service(self, *args):
"""
GetService(self: Component,service: Type) -> object
Returns an object that represents a service provided by the System.ComponentModel.Component or
by its System.ComponentModel.Container.
service: A service provided by the System.ComponentModel.Component.
Returns: An System.Object that represents a service provided by the System.ComponentModel.Component,or
null if the System.ComponentModel.Component does not provide the specified service.
"""
pass
def memberwise_clone(self, *args):
"""
MemberwiseClone(self: MarshalByRefObject,cloneIdentity: bool) -> MarshalByRefObject
Creates a shallow copy of the current System.MarshalByRefObject object.
cloneIdentity: false to delete the current System.MarshalByRefObject object's identity,which will cause the
object to be assigned a new identity when it is marshaled across a remoting boundary. A value of
false is usually appropriate. true to copy the current System.MarshalByRefObject object's
identity to its clone,which will cause remoting client calls to be routed to the remote server
object.
Returns: A shallow copy of the current System.MarshalByRefObject object.
MemberwiseClone(self: object) -> object
Creates a shallow copy of the current System.Object.
Returns: A shallow copy of the current System.Object.
"""
pass
def merge_menu(self, *__args):
"""
MergeMenu(self: MenuItem,itemSrc: MenuItem)
Merges another menu item with this menu item.
itemSrc: A System.Windows.Forms.MenuItem that specifies the menu item to merge with this one.
MergeMenu(self: MenuItem) -> MenuItem
Merges this System.Windows.Forms.MenuItem with another System.Windows.Forms.MenuItem and returns
the resulting merged System.Windows.Forms.MenuItem.
Returns: A System.Windows.Forms.MenuItem that represents the merged menu item.
"""
pass
def on_click(self, *args):
"""
OnClick(self: MenuItem,e: EventArgs)
Raises the System.Windows.Forms.MenuItem.Click event.
e: An System.EventArgs that contains the event data.
"""
pass
def on_draw_item(self, *args):
"""
OnDrawItem(self: MenuItem,e: DrawItemEventArgs)
Raises the System.Windows.Forms.MenuItem.DrawItem event.
e: A System.Windows.Forms.DrawItemEventArgs that contains the event data.
"""
pass
def on_init_menu_popup(self, *args):
"""
OnInitMenuPopup(self: MenuItem,e: EventArgs)
Raises the System.Windows.Forms.MenuItem.Popup event.
e: An System.EventArgs that contains the event data.
"""
pass
def on_measure_item(self, *args):
"""
OnMeasureItem(self: MenuItem,e: MeasureItemEventArgs)
Raises the System.Windows.Forms.MenuItem.MeasureItem event.
e: A System.Windows.Forms.MeasureItemEventArgs that contains the event data.
"""
pass
def on_popup(self, *args):
"""
OnPopup(self: MenuItem,e: EventArgs)
Raises the System.Windows.Forms.MenuItem.Popup event.
e: An System.EventArgs that contains the event data.
"""
pass
def on_select(self, *args):
"""
OnSelect(self: MenuItem,e: EventArgs)
Raises the System.Windows.Forms.MenuItem.Select event.
e: An System.EventArgs that contains the event data.
"""
pass
def perform_click(self):
"""
PerformClick(self: MenuItem)
Generates a System.Windows.Forms.Control.Click event for the System.Windows.Forms.MenuItem,
simulating a click by a user.
"""
pass
def perform_select(self):
"""
PerformSelect(self: MenuItem)
Raises the System.Windows.Forms.MenuItem.Select event for this menu item.
"""
pass
def process_cmd_key(self, *args):
"""
ProcessCmdKey(self: Menu,msg: Message,keyData: Keys) -> (bool,Message)
Processes a command key.
msg: A System.Windows.Forms.Message,passed by reference that represents the window message to
process.
keyData: One of the System.Windows.Forms.Keys values that represents the key to process.
Returns: true if the character was processed by the control; otherwise,false.
"""
pass
def to_string(self):
"""
ToString(self: MenuItem) -> str
Returns a string that represents the System.Windows.Forms.MenuItem.
Returns: A string that represents the current System.Windows.Forms.MenuItem. The string includes the type
and the System.Windows.Forms.MenuItem.Text property of the control.
"""
pass
def __enter__(self, *args):
"""
__enter__(self: IDisposable) -> object
Provides the implementation of __enter__ for objects which implement IDisposable.
"""
pass
def __exit__(self, *args):
"""
__exit__(self: IDisposable,exc_type: object,exc_value: object,exc_back: object)
Provides the implementation of __exit__ for objects which implement IDisposable.
"""
pass
def __init__(self, *args):
""" x.__init__(...) initializes x; see x.__class__.__doc__ for signaturex.__init__(...) initializes x; see x.__class__.__doc__ for signaturex.__init__(...) initializes x; see x.__class__.__doc__ for signature """
pass
@staticmethod
def __new__(self, *__args):
"""
__new__(cls: type)
__new__(cls: type,text: str)
__new__(cls: type,text: str,onClick: EventHandler)
__new__(cls: type,text: str,onClick: EventHandler,shortcut: Shortcut)
__new__(cls: type,text: str,items: Array[MenuItem])
__new__(cls: type,mergeType: MenuMerge,mergeOrder: int,shortcut: Shortcut,text: str,onClick: EventHandler,onPopup: EventHandler,onSelect: EventHandler,items: Array[MenuItem])
"""
pass
def __str__(self, *args):
pass
bar_break = property(lambda self: object(), lambda self, v: None, lambda self: None)
'Gets or sets a value indicating whether the System.Windows.Forms.MenuItem is placed on a new line (for a menu item added to a System.Windows.Forms.MainMenu object) or in a new column (for a submenu item or menu item displayed in a System.Windows.Forms.ContextMenu).\n\n\n\nGet: BarBreak(self: MenuItem) -> bool\n\n\n\nSet: BarBreak(self: MenuItem)=value\n\n'
break = property(lambda self: object(), lambda self, v: None, lambda self: None)
'Gets or sets a value indicating whether the item is placed on a new line (for a menu item added to a System.Windows.Forms.MainMenu object) or in a new column (for a menu item or submenu item displayed in a System.Windows.Forms.ContextMenu).\n\n\n\nGet: Break(self: MenuItem) -> bool\n\n\n\nSet: Break(self: MenuItem)=value\n\n'
can_raise_events = property(lambda self: object(), lambda self, v: None, lambda self: None)
'Gets a value indicating whether the component can raise an event.\n\n\n\n'
checked = property(lambda self: object(), lambda self, v: None, lambda self: None)
'Gets or sets a value indicating whether a check mark appears next to the text of the menu item.\n\n\n\nGet: Checked(self: MenuItem) -> bool\n\n\n\nSet: Checked(self: MenuItem)=value\n\n'
default_item = property(lambda self: object(), lambda self, v: None, lambda self: None)
'Gets or sets a value indicating whether the menu item is the default menu item.\n\n\n\nGet: DefaultItem(self: MenuItem) -> bool\n\n\n\nSet: DefaultItem(self: MenuItem)=value\n\n'
design_mode = property(lambda self: object(), lambda self, v: None, lambda self: None)
'Gets a value that indicates whether the System.ComponentModel.Component is currently in design mode.\n\n\n\n'
enabled = property(lambda self: object(), lambda self, v: None, lambda self: None)
'Gets or sets a value indicating whether the menu item is enabled.\n\n\n\nGet: Enabled(self: MenuItem) -> bool\n\n\n\nSet: Enabled(self: MenuItem)=value\n\n'
events = property(lambda self: object(), lambda self, v: None, lambda self: None)
'Gets the list of event handlers that are attached to this System.ComponentModel.Component.\n\n\n\n'
index = property(lambda self: object(), lambda self, v: None, lambda self: None)
'Gets or sets a value indicating the position of the menu item in its parent menu.\n\n\n\nGet: Index(self: MenuItem) -> int\n\n\n\nSet: Index(self: MenuItem)=value\n\n'
is_parent = property(lambda self: object(), lambda self, v: None, lambda self: None)
'Gets a value indicating whether the menu item contains child menu items.\n\n\n\nGet: IsParent(self: MenuItem) -> bool\n\n\n\n'
mdi_list = property(lambda self: object(), lambda self, v: None, lambda self: None)
'Gets or sets a value indicating whether the menu item will be populated with a list of the Multiple Document Interface (MDI) child windows that are displayed within the associated form.\n\n\n\nGet: MdiList(self: MenuItem) -> bool\n\n\n\nSet: MdiList(self: MenuItem)=value\n\n'
menu_id = property(lambda self: object(), lambda self, v: None, lambda self: None)
'Gets a value indicating the Windows identifier for this menu item.\n\n\n\n'
merge_order = property(lambda self: object(), lambda self, v: None, lambda self: None)
'Gets or sets a value indicating the relative position of the menu item when it is merged with another.\n\n\n\nGet: MergeOrder(self: MenuItem) -> int\n\n\n\nSet: MergeOrder(self: MenuItem)=value\n\n'
merge_type = property(lambda self: object(), lambda self, v: None, lambda self: None)
'Gets or sets a value indicating the behavior of this menu item when its menu is merged with another.\n\n\n\nGet: MergeType(self: MenuItem) -> MenuMerge\n\n\n\nSet: MergeType(self: MenuItem)=value\n\n'
mnemonic = property(lambda self: object(), lambda self, v: None, lambda self: None)
'Gets a value indicating the mnemonic character that is associated with this menu item.\n\n\n\nGet: Mnemonic(self: MenuItem) -> Char\n\n\n\n'
owner_draw = property(lambda self: object(), lambda self, v: None, lambda self: None)
'Gets or sets a value indicating whether the code that you provide draws the menu item or Windows draws the menu item.\n\n\n\nGet: OwnerDraw(self: MenuItem) -> bool\n\n\n\nSet: OwnerDraw(self: MenuItem)=value\n\n'
parent = property(lambda self: object(), lambda self, v: None, lambda self: None)
'Gets a value indicating the menu that contains this menu item.\n\n\n\nGet: Parent(self: MenuItem) -> Menu\n\n\n\n'
radio_check = property(lambda self: object(), lambda self, v: None, lambda self: None)
'Gets or sets a value indicating whether the System.Windows.Forms.MenuItem,if checked,displays a radio-button instead of a check mark.\n\n\n\nGet: RadioCheck(self: MenuItem) -> bool\n\n\n\nSet: RadioCheck(self: MenuItem)=value\n\n'
shortcut = property(lambda self: object(), lambda self, v: None, lambda self: None)
'Gets or sets a value indicating the shortcut key associated with the menu item.\n\n\n\nGet: Shortcut(self: MenuItem) -> Shortcut\n\n\n\nSet: Shortcut(self: MenuItem)=value\n\n'
show_shortcut = property(lambda self: object(), lambda self, v: None, lambda self: None)
'Gets or sets a value indicating whether the shortcut key that is associated with the menu item is displayed next to the menu item caption.\n\n\n\nGet: ShowShortcut(self: MenuItem) -> bool\n\n\n\nSet: ShowShortcut(self: MenuItem)=value\n\n'
text = property(lambda self: object(), lambda self, v: None, lambda self: None)
'Gets or sets a value indicating the caption of the menu item.\n\n\n\nGet: Text(self: MenuItem) -> str\n\n\n\nSet: Text(self: MenuItem)=value\n\n'
visible = property(lambda self: object(), lambda self, v: None, lambda self: None)
'Gets or sets a value indicating whether the menu item is visible.\n\n\n\nGet: Visible(self: MenuItem) -> bool\n\n\n\nSet: Visible(self: MenuItem)=value\n\n'
click = None
draw_item = None
measure_item = None
popup = None
select = None |
class Reflector:
alphabet = "ABCDEFGHIJKLMNOPQRSTUVWXYZ"
def __init__(self, permutation):
"""
:param permutation: string, mono-alphabetic permutation of the alphabet i.e. YRUHQSLDPXNGOKMIEBFZCWVJAT
"""
self.permutation = permutation
def calc(self, c):
"""
Swaps character with corresponding letter in permuted alphabet
:param c: char, character being encrypted or decrypted
:return: char, post-encryption/decryption character
"""
return self.permutation[self.alphabet.index(c)]
| class Reflector:
alphabet = 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'
def __init__(self, permutation):
"""
:param permutation: string, mono-alphabetic permutation of the alphabet i.e. YRUHQSLDPXNGOKMIEBFZCWVJAT
"""
self.permutation = permutation
def calc(self, c):
"""
Swaps character with corresponding letter in permuted alphabet
:param c: char, character being encrypted or decrypted
:return: char, post-encryption/decryption character
"""
return self.permutation[self.alphabet.index(c)] |
if __name__ == '__main__':
with open("../R/problem_module.R") as filename:
lines = filename.readlines()
for line in lines:
if "<- function(" in line:
function_name = line.split("<-")[0]
print(f"### {function_name.strip()}\n")
print("#### Main Documentation\n")
print("```{r, comment=NA, echo=FALSE}")
print(f'tools::Rd2txt(paste0(root, "{function_name.strip()}", ext))\n```\n')
| if __name__ == '__main__':
with open('../R/problem_module.R') as filename:
lines = filename.readlines()
for line in lines:
if '<- function(' in line:
function_name = line.split('<-')[0]
print(f'### {function_name.strip()}\n')
print('#### Main Documentation\n')
print('```{r, comment=NA, echo=FALSE}')
print(f'tools::Rd2txt(paste0(root, "{function_name.strip()}", ext))\n```\n') |
for t in range(int(input())):
word=input()
ispalin=True
for i in range(int(len(word)/2)):
if word[i]=="*" or word[len(word)-1-i]=="*":
break
elif word[i]!=word[len(word)-1-i]:
ispalin=False
print(f"#{t+1} Not exist")
break
else:
continue
if ispalin:
print(f"#{t+1} Exist")
| for t in range(int(input())):
word = input()
ispalin = True
for i in range(int(len(word) / 2)):
if word[i] == '*' or word[len(word) - 1 - i] == '*':
break
elif word[i] != word[len(word) - 1 - i]:
ispalin = False
print(f'#{t + 1} Not exist')
break
else:
continue
if ispalin:
print(f'#{t + 1} Exist') |
'''
Program implemented to count number of 1's in its binary number
'''
def countSetBits(n):
if n == 0:
return 0
else:
return (n&1) + countSetBits(n>>1)
n = int(input())
print(countSetBits(n))
| """
Program implemented to count number of 1's in its binary number
"""
def count_set_bits(n):
if n == 0:
return 0
else:
return (n & 1) + count_set_bits(n >> 1)
n = int(input())
print(count_set_bits(n)) |
#in=42
#golden=8
n = input_int()
c = 0
while (n > 1):
c = c + 1
if n % 2 == 0:
n = n // 2
else:
n = 3 * n + 1
print(c)
| n = input_int()
c = 0
while n > 1:
c = c + 1
if n % 2 == 0:
n = n // 2
else:
n = 3 * n + 1
print(c) |
#!/usr/bin/env python
# -*- coding: utf-8 -*-
"""Supported media formats.
https://kodi.wiki/view/Features_and_supported_formats
Media containers:
AVI, MPEG, WMV, ASF, FLV, MKV/MKA (Matroska), QuickTime, MP4, M4A, AAC, NUT, Ogg, OGM, RealMedia RAM/RM/RV/RA/RMVB, 3gp, VIVO, PVA, NUV, NSV, NSA, FLI, FLC, DVR-MS, WTV, TRP and F4V
"""
class MediaContainers( object ):
def __init__( self ):
self._supported = [ Mpeg1(),
Mpeg2(),
Mpeg4(),
QuickTime(),
RealMedia(),
Vp9(),
Wmv(),
Asf(),
Flash(),
Matroska(),
Ogg(),
ThreeGp(),
DivX(),
Vob(),
Bluray() ]
self._file_extensions = []
def extensions( self, wildcard=False ):
extensions = []
for media in self._supported:
extensions.extend( media.fs_ext( wildcard ) )
return set( extensions )
class SupportedMedia( object ):
def __init__( self ):
super( SupportedMedia, self ).__init__()
def fs_ext( self, wildcard = True ):
return [ '*%s' % ext if wildcard else ext for ext in self._extensions ]
class Mpeg1( SupportedMedia ):
def __init__( self ):
super( Mpeg1, self ).__init__()
self._extensions = [ '.mpg', '.mpeg', '.mp1', '.mp2', '.mp3', '.m1v', '.m1a','.m2a', '.mpa', '.mpv' ]
class Mpeg2( Mpeg1 ):
def __init__( self ):
super( Mpeg2, self ).__init__()
class Mpeg4( SupportedMedia ):
def __init__( self ):
super( Mpeg4, self ).__init__()
self._extensions = [ '.mp4', '.m4a', '.m4p', '.m4b', '.m4r', '.m4v' ]
class QuickTime( SupportedMedia ):
def __init__( self ):
super( QuickTime, self ).__init__()
self._extensions = [ '.mov', '.qt' ]
class RealMedia( SupportedMedia ):
def __init__( self ):
super( RealMedia, self ).__init__()
self._extensions = ['.rmvb']
class Vp9( SupportedMedia ):
def __init__( self ):
super( Vp9, self ).__init__()
self._extensions = ['.webm', '.mkv']
class Wmv( SupportedMedia ):
'''
Windows Media Video
'''
def __init__( self ):
super( Wmv, self ).__init__()
self._extensions = ['.wmv', '.asf', '.avi']
class Asf( SupportedMedia ):
'''
AdvancedSystemsFormat
'''
def __init__( self ):
super( Asf, self ).__init__()
self._extensions = [ '.asf', '.wma', '.wmv' ]
class Flash( SupportedMedia ):
def __init__( self ):
super( Flash, self ).__init__()
self._extensions = [ '.flv', '.f4v', '.f4p', '.f4a', '.f4b' ]
class Matroska( SupportedMedia ):
def __init__( self ):
super( Matroska, self ).__init__()
self._extensions = [ '.mkv', '.mk3d', '.mka', '.mks' ]
class Ogg( SupportedMedia ):
def __init__( self ):
super( Ogg, self ).__init__()
self._extensions = [ '.ogg', '.ogv', '.oga', '.ogx', '.ogm', '.spx', '.opus' ]
class ThreeGp( SupportedMedia ):
def __init__( self ):
super( ThreeGp, self ).__init__()
self._extensions = [ '.3gp' ]
class DivX( SupportedMedia ):
def __init__( self ):
super( DivX, self ).__init__()
self._extensions = [ '.avi', '.divx', '.mkv' ]
class Vob( SupportedMedia ):
def __init__( self ):
super( Vob, self ).__init__()
self._extensions = [ '.vob' ]
class Bluray( SupportedMedia ):
def __init__( self ):
super( Bluray, self ).__init__()
self._extensions = [ '.m2ts', '.mts' ]
| """Supported media formats.
https://kodi.wiki/view/Features_and_supported_formats
Media containers:
AVI, MPEG, WMV, ASF, FLV, MKV/MKA (Matroska), QuickTime, MP4, M4A, AAC, NUT, Ogg, OGM, RealMedia RAM/RM/RV/RA/RMVB, 3gp, VIVO, PVA, NUV, NSV, NSA, FLI, FLC, DVR-MS, WTV, TRP and F4V
"""
class Mediacontainers(object):
def __init__(self):
self._supported = [mpeg1(), mpeg2(), mpeg4(), quick_time(), real_media(), vp9(), wmv(), asf(), flash(), matroska(), ogg(), three_gp(), div_x(), vob(), bluray()]
self._file_extensions = []
def extensions(self, wildcard=False):
extensions = []
for media in self._supported:
extensions.extend(media.fs_ext(wildcard))
return set(extensions)
class Supportedmedia(object):
def __init__(self):
super(SupportedMedia, self).__init__()
def fs_ext(self, wildcard=True):
return ['*%s' % ext if wildcard else ext for ext in self._extensions]
class Mpeg1(SupportedMedia):
def __init__(self):
super(Mpeg1, self).__init__()
self._extensions = ['.mpg', '.mpeg', '.mp1', '.mp2', '.mp3', '.m1v', '.m1a', '.m2a', '.mpa', '.mpv']
class Mpeg2(Mpeg1):
def __init__(self):
super(Mpeg2, self).__init__()
class Mpeg4(SupportedMedia):
def __init__(self):
super(Mpeg4, self).__init__()
self._extensions = ['.mp4', '.m4a', '.m4p', '.m4b', '.m4r', '.m4v']
class Quicktime(SupportedMedia):
def __init__(self):
super(QuickTime, self).__init__()
self._extensions = ['.mov', '.qt']
class Realmedia(SupportedMedia):
def __init__(self):
super(RealMedia, self).__init__()
self._extensions = ['.rmvb']
class Vp9(SupportedMedia):
def __init__(self):
super(Vp9, self).__init__()
self._extensions = ['.webm', '.mkv']
class Wmv(SupportedMedia):
"""
Windows Media Video
"""
def __init__(self):
super(Wmv, self).__init__()
self._extensions = ['.wmv', '.asf', '.avi']
class Asf(SupportedMedia):
"""
AdvancedSystemsFormat
"""
def __init__(self):
super(Asf, self).__init__()
self._extensions = ['.asf', '.wma', '.wmv']
class Flash(SupportedMedia):
def __init__(self):
super(Flash, self).__init__()
self._extensions = ['.flv', '.f4v', '.f4p', '.f4a', '.f4b']
class Matroska(SupportedMedia):
def __init__(self):
super(Matroska, self).__init__()
self._extensions = ['.mkv', '.mk3d', '.mka', '.mks']
class Ogg(SupportedMedia):
def __init__(self):
super(Ogg, self).__init__()
self._extensions = ['.ogg', '.ogv', '.oga', '.ogx', '.ogm', '.spx', '.opus']
class Threegp(SupportedMedia):
def __init__(self):
super(ThreeGp, self).__init__()
self._extensions = ['.3gp']
class Divx(SupportedMedia):
def __init__(self):
super(DivX, self).__init__()
self._extensions = ['.avi', '.divx', '.mkv']
class Vob(SupportedMedia):
def __init__(self):
super(Vob, self).__init__()
self._extensions = ['.vob']
class Bluray(SupportedMedia):
def __init__(self):
super(Bluray, self).__init__()
self._extensions = ['.m2ts', '.mts'] |
"""
ALWAYS START WITH DOCUMENTATION!
This code provides functions for calculating area of different shapes
Author: Caitlin C. Bannan U.C. Irvine Mobley Group
"""
def area_square(length):
"""
Calculates the area of a square.
Parameters
----------
length (float or int) length of one side of a square
Returns
-------
area (float) - area of the square
"""
return length ** 2
| """
ALWAYS START WITH DOCUMENTATION!
This code provides functions for calculating area of different shapes
Author: Caitlin C. Bannan U.C. Irvine Mobley Group
"""
def area_square(length):
"""
Calculates the area of a square.
Parameters
----------
length (float or int) length of one side of a square
Returns
-------
area (float) - area of the square
"""
return length ** 2 |
def outer():
a = 0
b = 1
def inner():
print(a)
b=4
print(b)
# b += 1 # A
#b = 4 # B
inner()
outer()
for i in range(10):
print(i)
print(i) | def outer():
a = 0
b = 1
def inner():
print(a)
b = 4
print(b)
inner()
outer()
for i in range(10):
print(i)
print(i) |
class MyClass:
count = 0
def __init__(self, val):
self.val = self.filterint(val)
MyClass.count += 1
@staticmethod
def filterint(value):
if not isinstance(value, int):
print("Entered value is not an INT, value set to 0")
return 0
else:
return value
if __name__ == '__main__':
a = MyClass(5)
b = MyClass(10)
c = MyClass(15)
print(a.val)
print(b.val)
print(c.val)
print(a.filterint(100)) | class Myclass:
count = 0
def __init__(self, val):
self.val = self.filterint(val)
MyClass.count += 1
@staticmethod
def filterint(value):
if not isinstance(value, int):
print('Entered value is not an INT, value set to 0')
return 0
else:
return value
if __name__ == '__main__':
a = my_class(5)
b = my_class(10)
c = my_class(15)
print(a.val)
print(b.val)
print(c.val)
print(a.filterint(100)) |
#
# PySNMP MIB module RETIX-MIB (http://snmplabs.com/pysmi)
# ASN.1 source file:///Users/davwang4/Dev/mibs.snmplabs.com/asn1/RETIX-MIB
# Produced by pysmi-0.3.4 at Mon Apr 29 20:47:44 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, Integer, ObjectIdentifier = mibBuilder.importSymbols("ASN1", "OctetString", "Integer", "ObjectIdentifier")
NamedValues, = mibBuilder.importSymbols("ASN1-ENUMERATION", "NamedValues")
ConstraintsIntersection, ConstraintsUnion, ValueRangeConstraint, SingleValueConstraint, ValueSizeConstraint = mibBuilder.importSymbols("ASN1-REFINEMENT", "ConstraintsIntersection", "ConstraintsUnion", "ValueRangeConstraint", "SingleValueConstraint", "ValueSizeConstraint")
MibScalar, MibTable, MibTableRow, MibTableColumn = mibBuilder.importSymbols("RFC1212", "MibScalar", "MibTable", "MibTableRow", "MibTableColumn")
NotificationGroup, ModuleCompliance = mibBuilder.importSymbols("SNMPv2-CONF", "NotificationGroup", "ModuleCompliance")
iso, Bits, Unsigned32, ObjectIdentity, MibIdentifier, Gauge32, NotificationType, ModuleIdentity, MibScalar, MibTable, MibTableRow, MibTableColumn, enterprises, IpAddress, Counter32, Counter64, Integer32, TimeTicks = mibBuilder.importSymbols("SNMPv2-SMI", "iso", "Bits", "Unsigned32", "ObjectIdentity", "MibIdentifier", "Gauge32", "NotificationType", "ModuleIdentity", "MibScalar", "MibTable", "MibTableRow", "MibTableColumn", "enterprises", "IpAddress", "Counter32", "Counter64", "Integer32", "TimeTicks")
TextualConvention, DisplayString = mibBuilder.importSymbols("SNMPv2-TC", "TextualConvention", "DisplayString")
retix = MibIdentifier((1, 3, 6, 1, 4, 1, 72))
station = MibIdentifier((1, 3, 6, 1, 4, 1, 72, 1))
lapb = MibIdentifier((1, 3, 6, 1, 4, 1, 72, 2))
ieee8023 = MibIdentifier((1, 3, 6, 1, 4, 1, 72, 3))
phySerIf = MibIdentifier((1, 3, 6, 1, 4, 1, 72, 4))
mlink = MibIdentifier((1, 3, 6, 1, 4, 1, 72, 5))
lan = MibIdentifier((1, 3, 6, 1, 4, 1, 72, 6))
bridge = MibIdentifier((1, 3, 6, 1, 4, 1, 72, 7))
product = MibIdentifier((1, 3, 6, 1, 4, 1, 72, 8))
router = MibIdentifier((1, 3, 6, 1, 4, 1, 72, 10))
boot = MibIdentifier((1, 3, 6, 1, 4, 1, 72, 11))
boothelper = MibIdentifier((1, 3, 6, 1, 4, 1, 72, 12))
remote = MibIdentifier((1, 3, 6, 1, 4, 1, 72, 13))
ipx = MibIdentifier((1, 3, 6, 1, 4, 1, 72, 13, 1))
decnet = MibIdentifier((1, 3, 6, 1, 4, 1, 72, 13, 2))
rmtLapb = MibIdentifier((1, 3, 6, 1, 4, 1, 72, 13, 3))
x25 = MibIdentifier((1, 3, 6, 1, 4, 1, 72, 13, 4))
stationTime = MibScalar((1, 3, 6, 1, 4, 1, 72, 1, 1), OctetString().subtype(subtypeSpec=ValueSizeConstraint(13, 13)).setFixedLength(13)).setMaxAccess("readwrite")
if mibBuilder.loadTexts: stationTime.setStatus('mandatory')
stationCountResets = MibScalar((1, 3, 6, 1, 4, 1, 72, 1, 2), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: stationCountResets.setStatus('mandatory')
freeBufferCount = MibScalar((1, 3, 6, 1, 4, 1, 72, 1, 3), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: freeBufferCount.setStatus('mandatory')
freeHeaderCount = MibScalar((1, 3, 6, 1, 4, 1, 72, 1, 4), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: freeHeaderCount.setStatus('mandatory')
physBlkSize = MibScalar((1, 3, 6, 1, 4, 1, 72, 1, 5), Integer32().subtype(subtypeSpec=ValueRangeConstraint(300, 1600))).setMaxAccess("readonly")
if mibBuilder.loadTexts: physBlkSize.setStatus('mandatory')
newPhysBlkSize = MibScalar((1, 3, 6, 1, 4, 1, 72, 1, 6), Integer32().subtype(subtypeSpec=ValueRangeConstraint(300, 1600))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: newPhysBlkSize.setStatus('mandatory')
resetStation = MibScalar((1, 3, 6, 1, 4, 1, 72, 1, 7), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2))).clone(namedValues=NamedValues(("noAction", 1), ("resetStation", 2)))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: resetStation.setStatus('mandatory')
initStation = MibScalar((1, 3, 6, 1, 4, 1, 72, 1, 8), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2))).clone(namedValues=NamedValues(("noAction", 1), ("initialize", 2)))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: initStation.setStatus('mandatory')
resetStats = MibScalar((1, 3, 6, 1, 4, 1, 72, 1, 9), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2))).clone(namedValues=NamedValues(("noAction", 1), ("resetStats", 2)))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: resetStats.setStatus('mandatory')
processorLoading = MibScalar((1, 3, 6, 1, 4, 1, 72, 1, 10), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: processorLoading.setStatus('mandatory')
trapDestinationTable = MibIdentifier((1, 3, 6, 1, 4, 1, 72, 1, 11))
trapDestTable = MibTable((1, 3, 6, 1, 4, 1, 72, 1, 11, 1), )
if mibBuilder.loadTexts: trapDestTable.setStatus('mandatory')
trapDestEntry = MibTableRow((1, 3, 6, 1, 4, 1, 72, 1, 11, 1, 1), ).setIndexNames((0, "RETIX-MIB", "trapDestEntryIpAddr"))
if mibBuilder.loadTexts: trapDestEntry.setStatus('mandatory')
trapDestEntryIpAddr = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 1, 11, 1, 1, 1), IpAddress()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: trapDestEntryIpAddr.setStatus('mandatory')
trapDestEntryCommunityName = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 1, 11, 1, 1, 2), OctetString().subtype(subtypeSpec=ValueSizeConstraint(0, 10))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: trapDestEntryCommunityName.setStatus('mandatory')
trapDestEntryType = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 1, 11, 1, 1, 3), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2))).clone(namedValues=NamedValues(("valid", 1), ("invalid", 2)))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: trapDestEntryType.setStatus('mandatory')
trapDestAction = MibScalar((1, 3, 6, 1, 4, 1, 72, 1, 11, 2), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2))).clone(namedValues=NamedValues(("noAction", 1), ("clearTable", 2)))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: trapDestAction.setStatus('mandatory')
trapDestPage = MibScalar((1, 3, 6, 1, 4, 1, 72, 1, 11, 3), OctetString().subtype(subtypeSpec=ValueSizeConstraint(240, 240)).setFixedLength(240)).setMaxAccess("readonly")
if mibBuilder.loadTexts: trapDestPage.setStatus('mandatory')
passWord = MibScalar((1, 3, 6, 1, 4, 1, 72, 1, 12), OctetString().subtype(subtypeSpec=ValueSizeConstraint(0, 10))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: passWord.setStatus('mandatory')
snmpAccessPolicyObject = MibIdentifier((1, 3, 6, 1, 4, 1, 72, 1, 13))
snmpAccessPolicyTable = MibTable((1, 3, 6, 1, 4, 1, 72, 1, 13, 1), )
if mibBuilder.loadTexts: snmpAccessPolicyTable.setStatus('mandatory')
snmpAccessPolicyEntry = MibTableRow((1, 3, 6, 1, 4, 1, 72, 1, 13, 1, 1), ).setIndexNames((0, "RETIX-MIB", "accessPolicyIndex"))
if mibBuilder.loadTexts: snmpAccessPolicyEntry.setStatus('mandatory')
accessPolicyIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 1, 13, 1, 1, 1), Integer32()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: accessPolicyIndex.setStatus('mandatory')
communityName = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 1, 13, 1, 1, 2), OctetString().subtype(subtypeSpec=ValueSizeConstraint(0, 10))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: communityName.setStatus('mandatory')
accessMode = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 1, 13, 1, 1, 3), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 3))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: accessMode.setStatus('mandatory')
snmpAccessPolicyType = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 1, 13, 1, 1, 4), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2))).clone(namedValues=NamedValues(("valid", 1), ("invalid", 2)))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: snmpAccessPolicyType.setStatus('mandatory')
snmpAccessPolicyAction = MibScalar((1, 3, 6, 1, 4, 1, 72, 1, 13, 2), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2))).clone(namedValues=NamedValues(("noAction", 1), ("clearTable", 2)))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: snmpAccessPolicyAction.setStatus('mandatory')
snmpAccessPolicyPage = MibScalar((1, 3, 6, 1, 4, 1, 72, 1, 13, 3), OctetString().subtype(subtypeSpec=ValueSizeConstraint(256, 256)).setFixedLength(256)).setMaxAccess("readonly")
if mibBuilder.loadTexts: snmpAccessPolicyPage.setStatus('mandatory')
authenticationTrapStatus = MibScalar((1, 3, 6, 1, 4, 1, 72, 1, 14), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2))).clone(namedValues=NamedValues(("enabled", 1), ("disabled", 2)))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: authenticationTrapStatus.setStatus('mandatory')
serialTxQueueSize = MibScalar((1, 3, 6, 1, 4, 1, 72, 1, 15), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 127))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: serialTxQueueSize.setStatus('mandatory')
internalQueueCurrentLength = MibScalar((1, 3, 6, 1, 4, 1, 72, 1, 16), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: internalQueueCurrentLength.setStatus('mandatory')
queueUpperLimit = MibScalar((1, 3, 6, 1, 4, 1, 72, 1, 17), Integer32()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: queueUpperLimit.setStatus('mandatory')
lanQueueSize = MibScalar((1, 3, 6, 1, 4, 1, 72, 1, 18), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: lanQueueSize.setStatus('mandatory')
lapbNumber = MibScalar((1, 3, 6, 1, 4, 1, 72, 2, 1), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: lapbNumber.setStatus('mandatory')
lapbTable = MibTable((1, 3, 6, 1, 4, 1, 72, 2, 2), )
if mibBuilder.loadTexts: lapbTable.setStatus('mandatory')
lapbEntry = MibTableRow((1, 3, 6, 1, 4, 1, 72, 2, 2, 1), ).setIndexNames((0, "RETIX-MIB", "lapbIndex"))
if mibBuilder.loadTexts: lapbEntry.setStatus('mandatory')
lapbIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 2, 2, 1, 1), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: lapbIndex.setStatus('mandatory')
lapbModeT1 = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 2, 2, 1, 2), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 1))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: lapbModeT1.setStatus('mandatory')
lapbAutoT1value = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 2, 2, 1, 3), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: lapbAutoT1value.setStatus('mandatory')
lapbManualT1value = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 2, 2, 1, 4), Integer32().subtype(subtypeSpec=ValueRangeConstraint(10, 5000))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: lapbManualT1value.setStatus('mandatory')
lapbWindow = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 2, 2, 1, 5), Integer32().subtype(subtypeSpec=ValueRangeConstraint(7, 127))).setMaxAccess("readonly")
if mibBuilder.loadTexts: lapbWindow.setStatus('mandatory')
lapbPolarity = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 2, 2, 1, 6), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 1))).setMaxAccess("readonly")
if mibBuilder.loadTexts: lapbPolarity.setStatus('mandatory')
lapbCountResets = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 2, 2, 1, 7), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: lapbCountResets.setStatus('mandatory')
lapbCountSentFrames = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 2, 2, 1, 8), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: lapbCountSentFrames.setStatus('mandatory')
lapbCountRcvFrames = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 2, 2, 1, 9), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: lapbCountRcvFrames.setStatus('mandatory')
lapbCountSentOctets = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 2, 2, 1, 10), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: lapbCountSentOctets.setStatus('mandatory')
lapbCountRcvOctets = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 2, 2, 1, 11), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: lapbCountRcvOctets.setStatus('mandatory')
lapbCountAborts = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 2, 2, 1, 12), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: lapbCountAborts.setStatus('mandatory')
lapbCountCrcErrors = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 2, 2, 1, 13), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: lapbCountCrcErrors.setStatus('mandatory')
lapbState = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 2, 2, 1, 14), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: lapbState.setStatus('mandatory')
lapbLastResetTime = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 2, 2, 1, 15), OctetString().subtype(subtypeSpec=ValueSizeConstraint(13, 13)).setFixedLength(13)).setMaxAccess("readonly")
if mibBuilder.loadTexts: lapbLastResetTime.setStatus('mandatory')
lapbLastResetReason = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 2, 2, 1, 16), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 8))).setMaxAccess("readonly")
if mibBuilder.loadTexts: lapbLastResetReason.setStatus('mandatory')
lapbLinkReset = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 2, 2, 1, 17), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2))).clone(namedValues=NamedValues(("noAction", 1), ("reset", 2)))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: lapbLinkReset.setStatus('mandatory')
lapbRetryCount = MibScalar((1, 3, 6, 1, 4, 1, 72, 2, 3), Integer32()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: lapbRetryCount.setStatus('mandatory')
ieee8023Number = MibScalar((1, 3, 6, 1, 4, 1, 72, 3, 1), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: ieee8023Number.setStatus('mandatory')
ieee8023Table = MibTable((1, 3, 6, 1, 4, 1, 72, 3, 2), )
if mibBuilder.loadTexts: ieee8023Table.setStatus('mandatory')
ieee8023Entry = MibTableRow((1, 3, 6, 1, 4, 1, 72, 3, 2, 1), ).setIndexNames((0, "RETIX-MIB", "ieee8023Index"))
if mibBuilder.loadTexts: ieee8023Entry.setStatus('mandatory')
ieee8023Index = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 1), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: ieee8023Index.setStatus('mandatory')
ieee8023FramesTransmittedOks = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 2), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: ieee8023FramesTransmittedOks.setStatus('mandatory')
ieee8023SingleCollisionFrames = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 3), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: ieee8023SingleCollisionFrames.setStatus('mandatory')
ieee8023MultipleCollisionFrames = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 4), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: ieee8023MultipleCollisionFrames.setStatus('mandatory')
ieee8023OctetsTransmittedOks = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 5), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: ieee8023OctetsTransmittedOks.setStatus('mandatory')
ieee8023DeferredTransmissions = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 6), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: ieee8023DeferredTransmissions.setStatus('mandatory')
ieee8023MulticastFramesTransmittedOks = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 7), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: ieee8023MulticastFramesTransmittedOks.setStatus('mandatory')
ieee8023BroadcastFramesTransmittedOks = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 8), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: ieee8023BroadcastFramesTransmittedOks.setStatus('mandatory')
ieee8023LateCollisions = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 9), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: ieee8023LateCollisions.setStatus('mandatory')
ieee8023ExcessiveCollisions = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 10), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: ieee8023ExcessiveCollisions.setStatus('mandatory')
ieee8023InternalMACTransmitErrors = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 11), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: ieee8023InternalMACTransmitErrors.setStatus('mandatory')
ieee8023CarrierSenseErrors = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 12), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: ieee8023CarrierSenseErrors.setStatus('mandatory')
ieee8023ExcessiveDeferrals = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 13), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: ieee8023ExcessiveDeferrals.setStatus('mandatory')
ieee8023FramesReceivedOks = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 14), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: ieee8023FramesReceivedOks.setStatus('mandatory')
ieee8023OctetsReceivedOks = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 15), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: ieee8023OctetsReceivedOks.setStatus('mandatory')
ieee8023MulticastFramesReceivedOks = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 16), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: ieee8023MulticastFramesReceivedOks.setStatus('mandatory')
ieee8023BroadcastFramesReceivedOks = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 17), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: ieee8023BroadcastFramesReceivedOks.setStatus('mandatory')
ieee8023FrameTooLongs = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 18), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: ieee8023FrameTooLongs.setStatus('mandatory')
ieee8023AlignmentErrors = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 19), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: ieee8023AlignmentErrors.setStatus('mandatory')
ieee8023FCSErrors = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 20), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: ieee8023FCSErrors.setStatus('mandatory')
ieee8023inRangeLengthErrors = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 21), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: ieee8023inRangeLengthErrors.setStatus('mandatory')
ieee8023outOfRangeLengthFields = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 22), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: ieee8023outOfRangeLengthFields.setStatus('mandatory')
ieee8023InternalMACReceiveErrors = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 23), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: ieee8023InternalMACReceiveErrors.setStatus('mandatory')
ieee8023InitializeMAC = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 24), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1))).clone(namedValues=NamedValues(("initialize", 1)))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: ieee8023InitializeMAC.setStatus('mandatory')
ieee8023PromiscuousReceiveStatus = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 25), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1))).clone(namedValues=NamedValues(("enabled", 1)))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: ieee8023PromiscuousReceiveStatus.setStatus('mandatory')
ieee8023MACSubLayerStatus = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 26), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1))).clone(namedValues=NamedValues(("enabled", 1)))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: ieee8023MACSubLayerStatus.setStatus('mandatory')
ieee8023TransmitStatus = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 27), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2))).clone(namedValues=NamedValues(("enabled", 1), ("disabled", 2)))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: ieee8023TransmitStatus.setStatus('mandatory')
ieee8023MulticastReceiveStatus = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 28), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1))).clone(namedValues=NamedValues(("enabled", 1)))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: ieee8023MulticastReceiveStatus.setStatus('mandatory')
ieee8023MACAddress = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 29), OctetString().subtype(subtypeSpec=ValueSizeConstraint(6, 6)).setFixedLength(6)).setMaxAccess("readonly")
if mibBuilder.loadTexts: ieee8023MACAddress.setStatus('mandatory')
ieee8023SQETestErrors = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 30), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: ieee8023SQETestErrors.setStatus('mandatory')
ieee8023NewMACAddress = MibTable((1, 3, 6, 1, 4, 1, 72, 3, 3), )
if mibBuilder.loadTexts: ieee8023NewMACAddress.setStatus('mandatory')
ieee8023NewMACAddressEntry = MibTableRow((1, 3, 6, 1, 4, 1, 72, 3, 3, 1), ).setIndexNames((0, "RETIX-MIB", "ieee8023NewMACAddressIndex"))
if mibBuilder.loadTexts: ieee8023NewMACAddressEntry.setStatus('mandatory')
ieee8023NewMACAddressIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 3, 3, 1, 1), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: ieee8023NewMACAddressIndex.setStatus('mandatory')
ieee8023NewMACAddressValue = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 3, 3, 1, 2), OctetString().subtype(subtypeSpec=ValueSizeConstraint(6, 6)).setFixedLength(6)).setMaxAccess("readwrite")
if mibBuilder.loadTexts: ieee8023NewMACAddressValue.setStatus('mandatory')
phySerIfNumber = MibScalar((1, 3, 6, 1, 4, 1, 72, 4, 1), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: phySerIfNumber.setStatus('mandatory')
phySerIfTable = MibTable((1, 3, 6, 1, 4, 1, 72, 4, 2), )
if mibBuilder.loadTexts: phySerIfTable.setStatus('mandatory')
phySerIfEntry = MibTableRow((1, 3, 6, 1, 4, 1, 72, 4, 2, 1), ).setIndexNames((0, "RETIX-MIB", "phySerIfIndex"))
if mibBuilder.loadTexts: phySerIfEntry.setStatus('mandatory')
phySerIfIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 4, 2, 1, 1), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: phySerIfIndex.setStatus('mandatory')
phySerIfInterfaceType = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 4, 2, 1, 2), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2, 3, 4, 5, 6, 7, 8))).clone(namedValues=NamedValues(("x21dte", 1), ("x21dce", 2), ("rs449", 3), ("g703", 4), ("v35", 5), ("v35btb", 6), ("rs232", 7), ("t1", 8)))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: phySerIfInterfaceType.setStatus('mandatory')
phySerIfMeasuredSpeed = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 4, 2, 1, 3), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: phySerIfMeasuredSpeed.setStatus('mandatory')
phySerIfIsSpeedsettable = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 4, 2, 1, 4), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 1))).setMaxAccess("readonly")
if mibBuilder.loadTexts: phySerIfIsSpeedsettable.setStatus('mandatory')
phySerIfPortSpeed = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 4, 2, 1, 5), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1200, 2400, 4800, 9600, 19200, 24000, 32000, 48000, 64000, 256000, 512000, 1024000, 2048000))).clone(namedValues=NamedValues(("b1200", 1200), ("b2400", 2400), ("b4800", 4800), ("b9600", 9600), ("b19200", 19200), ("b24000", 24000), ("b32000", 32000), ("b48000", 48000), ("b64000", 64000), ("b256000", 256000), ("b512000", 512000), ("b1024000", 1024000), ("b2048000", 2048000)))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: phySerIfPortSpeed.setStatus('mandatory')
phySerIfTransitDelay = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 4, 2, 1, 6), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: phySerIfTransitDelay.setStatus('mandatory')
phySerIfT1clockSource = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 4, 2, 1, 7), Integer32()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: phySerIfT1clockSource.setStatus('mandatory')
phySerIfT1SlotLvalue = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 4, 2, 1, 8), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 24))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: phySerIfT1SlotLvalue.setStatus('mandatory')
phySerIfT1SlotHvalue = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 4, 2, 1, 9), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 24))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: phySerIfT1SlotHvalue.setStatus('mandatory')
phySerIfT1dRatePerChan = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 4, 2, 1, 10), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 1))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: phySerIfT1dRatePerChan.setStatus('mandatory')
phySerIfT1frameAndCode = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 4, 2, 1, 11), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 3))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: phySerIfT1frameAndCode.setStatus('mandatory')
phySerIfPartnerAddress = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 4, 2, 1, 12), OctetString().subtype(subtypeSpec=ValueSizeConstraint(0, 6))).setMaxAccess("readonly")
if mibBuilder.loadTexts: phySerIfPartnerAddress.setStatus('mandatory')
mlinkNumber = MibScalar((1, 3, 6, 1, 4, 1, 72, 5, 1), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: mlinkNumber.setStatus('mandatory')
mlinkTable = MibTable((1, 3, 6, 1, 4, 1, 72, 5, 2), )
if mibBuilder.loadTexts: mlinkTable.setStatus('mandatory')
mlinkEntry = MibTableRow((1, 3, 6, 1, 4, 1, 72, 5, 2, 1), ).setIndexNames((0, "RETIX-MIB", "mlinkIndex"))
if mibBuilder.loadTexts: mlinkEntry.setStatus('mandatory')
mlinkIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 5, 2, 1, 1), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: mlinkIndex.setStatus('mandatory')
mlinkState = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 5, 2, 1, 2), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 3))).setMaxAccess("readonly")
if mibBuilder.loadTexts: mlinkState.setStatus('mandatory')
mlinkSendSeq = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 5, 2, 1, 3), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: mlinkSendSeq.setStatus('mandatory')
mlinkRcvSeq = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 5, 2, 1, 4), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: mlinkRcvSeq.setStatus('mandatory')
mlinkSendUpperEdge = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 5, 2, 1, 5), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: mlinkSendUpperEdge.setStatus('mandatory')
mlinkRcvUpperEdge = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 5, 2, 1, 6), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: mlinkRcvUpperEdge.setStatus('mandatory')
mlinkLostFrames = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 5, 2, 1, 7), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: mlinkLostFrames.setStatus('mandatory')
deletedMlinkFrames = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 5, 2, 1, 8), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: deletedMlinkFrames.setStatus('mandatory')
expressQueueCurrentLength = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 5, 2, 1, 9), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: expressQueueCurrentLength.setStatus('mandatory')
expressQueueUpperLimit = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 5, 2, 1, 10), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: expressQueueUpperLimit.setStatus('mandatory')
hiPriQueueCurrentLength = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 5, 2, 1, 11), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: hiPriQueueCurrentLength.setStatus('mandatory')
hiPriQueueUpperLimit = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 5, 2, 1, 12), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: hiPriQueueUpperLimit.setStatus('mandatory')
loPriQueueCurrentLength = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 5, 2, 1, 13), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: loPriQueueCurrentLength.setStatus('mandatory')
loPriQueueUpperLimit = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 5, 2, 1, 14), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: loPriQueueUpperLimit.setStatus('mandatory')
mlinkWindow = MibScalar((1, 3, 6, 1, 4, 1, 72, 5, 3), Integer32()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: mlinkWindow.setStatus('mandatory')
mlinkRxTimeout = MibScalar((1, 3, 6, 1, 4, 1, 72, 5, 4), Integer32()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: mlinkRxTimeout.setStatus('mandatory')
lanInterfaceType = MibScalar((1, 3, 6, 1, 4, 1, 72, 6, 1), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2, 3))).clone(namedValues=NamedValues(("tenBase5", 1), ("oneBase5", 2), ("tenBase2", 3)))).setMaxAccess("readonly")
if mibBuilder.loadTexts: lanInterfaceType.setStatus('mandatory')
portNumber = MibScalar((1, 3, 6, 1, 4, 1, 72, 7, 1), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: portNumber.setStatus('mandatory')
bridgeStatsTable = MibTable((1, 3, 6, 1, 4, 1, 72, 7, 2), )
if mibBuilder.loadTexts: bridgeStatsTable.setStatus('mandatory')
bridgeStatsEntry = MibTableRow((1, 3, 6, 1, 4, 1, 72, 7, 2, 1), ).setIndexNames((0, "RETIX-MIB", "bridgeStatsIndex"))
if mibBuilder.loadTexts: bridgeStatsEntry.setStatus('mandatory')
bridgeStatsIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 7, 2, 1, 1), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: bridgeStatsIndex.setStatus('mandatory')
averageForwardedFrames = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 7, 2, 1, 2), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: averageForwardedFrames.setStatus('mandatory')
maxForwardedFrames = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 7, 2, 1, 3), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: maxForwardedFrames.setStatus('mandatory')
averageRejectedFrames = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 7, 2, 1, 4), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: averageRejectedFrames.setStatus('mandatory')
maxRejectedFrames = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 7, 2, 1, 5), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: maxRejectedFrames.setStatus('mandatory')
lanAccepts = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 7, 2, 1, 6), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: lanAccepts.setStatus('mandatory')
lanRejects = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 7, 2, 1, 7), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: lanRejects.setStatus('mandatory')
deletedLanFrames = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 7, 2, 1, 8), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: deletedLanFrames.setStatus('mandatory')
stpTable = MibTable((1, 3, 6, 1, 4, 1, 72, 7, 3), )
if mibBuilder.loadTexts: stpTable.setStatus('mandatory')
stpEntry = MibTableRow((1, 3, 6, 1, 4, 1, 72, 7, 3, 1), ).setIndexNames((0, "RETIX-MIB", "stpIndex"))
if mibBuilder.loadTexts: stpEntry.setStatus('mandatory')
stpIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 7, 3, 1, 1), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: stpIndex.setStatus('mandatory')
pathCostMode = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 7, 3, 1, 2), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 1))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: pathCostMode.setStatus('mandatory')
pathCostAutoValue = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 7, 3, 1, 3), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: pathCostAutoValue.setStatus('mandatory')
pathCostManualValue = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 7, 3, 1, 4), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 65535))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: pathCostManualValue.setStatus('mandatory')
portSpatState = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 7, 3, 1, 5), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: portSpatState.setStatus('mandatory')
portPriorityMode = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 7, 3, 1, 6), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 1))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: portPriorityMode.setStatus('mandatory')
portPriorityAutoValue = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 7, 3, 1, 7), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: portPriorityAutoValue.setStatus('mandatory')
portPriorityManualValue = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 7, 3, 1, 8), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 255))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: portPriorityManualValue.setStatus('mandatory')
spanningTree = MibScalar((1, 3, 6, 1, 4, 1, 72, 7, 4), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 1))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: spanningTree.setStatus('mandatory')
spatPriority = MibScalar((1, 3, 6, 1, 4, 1, 72, 7, 5), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 65535))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: spatPriority.setStatus('mandatory')
spatHelloTimer = MibScalar((1, 3, 6, 1, 4, 1, 72, 7, 6), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 10))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: spatHelloTimer.setStatus('mandatory')
spatResetTimer = MibScalar((1, 3, 6, 1, 4, 1, 72, 7, 7), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 1800))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: spatResetTimer.setStatus('mandatory')
spatVersion = MibScalar((1, 3, 6, 1, 4, 1, 72, 7, 8), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(3, 8))).clone(namedValues=NamedValues(("revisionC", 3), ("revision8", 8)))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: spatVersion.setStatus('mandatory')
spanningMcastAddr = MibScalar((1, 3, 6, 1, 4, 1, 72, 7, 9), OctetString().subtype(subtypeSpec=ValueSizeConstraint(6, 6)).setFixedLength(6)).setMaxAccess("readwrite")
if mibBuilder.loadTexts: spanningMcastAddr.setStatus('mandatory')
operatingMode = MibScalar((1, 3, 6, 1, 4, 1, 72, 7, 10), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 1))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: operatingMode.setStatus('mandatory')
preconfSourceFilter = MibScalar((1, 3, 6, 1, 4, 1, 72, 7, 11), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 1))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: preconfSourceFilter.setStatus('mandatory')
typeFilter = MibScalar((1, 3, 6, 1, 4, 1, 72, 7, 12), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 1))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: typeFilter.setStatus('mandatory')
typePrioritisation = MibScalar((1, 3, 6, 1, 4, 1, 72, 7, 13), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 1))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: typePrioritisation.setStatus('mandatory')
dynamicLearningInLM = MibScalar((1, 3, 6, 1, 4, 1, 72, 7, 14), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 1))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: dynamicLearningInLM.setStatus('mandatory')
forgetAddressTimer = MibScalar((1, 3, 6, 1, 4, 1, 72, 7, 15), Integer32().subtype(subtypeSpec=ValueRangeConstraint(24, 1000))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: forgetAddressTimer.setStatus('mandatory')
deleteAddressTimer = MibScalar((1, 3, 6, 1, 4, 1, 72, 7, 16), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 20000))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: deleteAddressTimer.setStatus('mandatory')
multicastDisposition = MibScalar((1, 3, 6, 1, 4, 1, 72, 7, 17), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 1))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: multicastDisposition.setStatus('mandatory')
filterMatches = MibScalar((1, 3, 6, 1, 4, 1, 72, 7, 18), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 1))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: filterMatches.setStatus('mandatory')
ieeeFormatFilter = MibScalar((1, 3, 6, 1, 4, 1, 72, 7, 19), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 1))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: ieeeFormatFilter.setStatus('mandatory')
priorityMatches = MibScalar((1, 3, 6, 1, 4, 1, 72, 7, 20), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 1))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: priorityMatches.setStatus('mandatory')
ieeeFormatPriority = MibScalar((1, 3, 6, 1, 4, 1, 72, 7, 21), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 1))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: ieeeFormatPriority.setStatus('mandatory')
averagePeriod = MibScalar((1, 3, 6, 1, 4, 1, 72, 7, 22), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: averagePeriod.setStatus('mandatory')
triangulation = MibScalar((1, 3, 6, 1, 4, 1, 72, 7, 23), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 1))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: triangulation.setStatus('mandatory')
adaptiveRouting = MibScalar((1, 3, 6, 1, 4, 1, 72, 7, 24), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 1))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: adaptiveRouting.setStatus('mandatory')
adaptiveMcastAddr = MibScalar((1, 3, 6, 1, 4, 1, 72, 7, 25), OctetString().subtype(subtypeSpec=ValueSizeConstraint(6, 6)).setFixedLength(6)).setMaxAccess("readwrite")
if mibBuilder.loadTexts: adaptiveMcastAddr.setStatus('mandatory')
arAddressInfo = MibIdentifier((1, 3, 6, 1, 4, 1, 72, 7, 26))
standbyRemote = MibScalar((1, 3, 6, 1, 4, 1, 72, 7, 26, 1), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: standbyRemote.setStatus('mandatory')
standbyLocal = MibScalar((1, 3, 6, 1, 4, 1, 72, 7, 26, 2), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: standbyLocal.setStatus('mandatory')
activeRemote = MibScalar((1, 3, 6, 1, 4, 1, 72, 7, 26, 3), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: activeRemote.setStatus('mandatory')
activeLocal = MibScalar((1, 3, 6, 1, 4, 1, 72, 7, 26, 4), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: activeLocal.setStatus('mandatory')
maxSerialLoading = MibScalar((1, 3, 6, 1, 4, 1, 72, 7, 27), Integer32()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: maxSerialLoading.setStatus('mandatory')
serialLoadPeriod = MibScalar((1, 3, 6, 1, 4, 1, 72, 7, 28), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(10, 20, 30, 40, 50, 60))).clone(namedValues=NamedValues(("ten", 10), ("twenty", 20), ("thirty", 30), ("forty", 40), ("fifty", 50), ("sixty", 60)))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: serialLoadPeriod.setStatus('mandatory')
serialLoading = MibScalar((1, 3, 6, 1, 4, 1, 72, 7, 29), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: serialLoading.setStatus('mandatory')
filteringDataBaseTable = MibIdentifier((1, 3, 6, 1, 4, 1, 72, 7, 30))
filteringDbTable = MibTable((1, 3, 6, 1, 4, 1, 72, 7, 30, 1), )
if mibBuilder.loadTexts: filteringDbTable.setStatus('mandatory')
filteringDbEntry = MibTableRow((1, 3, 6, 1, 4, 1, 72, 7, 30, 1, 1), ).setIndexNames((0, "RETIX-MIB", "filteringDbMacAddress"))
if mibBuilder.loadTexts: filteringDbEntry.setStatus('mandatory')
filteringDbMacAddress = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 7, 30, 1, 1, 1), OctetString().subtype(subtypeSpec=ValueSizeConstraint(6, 6)).setFixedLength(6)).setMaxAccess("readwrite")
if mibBuilder.loadTexts: filteringDbMacAddress.setStatus('mandatory')
filteringDbDisposition = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 7, 30, 1, 1, 2), Integer32()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: filteringDbDisposition.setStatus('mandatory')
filteringDbStatus = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 7, 30, 1, 1, 3), Integer32()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: filteringDbStatus.setStatus('mandatory')
filteringDbType = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 7, 30, 1, 1, 4), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2))).clone(namedValues=NamedValues(("valid", 1), ("invalid", 2)))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: filteringDbType.setStatus('mandatory')
filteringDbAction = MibScalar((1, 3, 6, 1, 4, 1, 72, 7, 30, 2), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2))).clone(namedValues=NamedValues(("noAction", 1), ("clearTable", 2)))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: filteringDbAction.setStatus('mandatory')
priorityTable = MibIdentifier((1, 3, 6, 1, 4, 1, 72, 7, 31))
prioritySubTable = MibTable((1, 3, 6, 1, 4, 1, 72, 7, 31, 1), )
if mibBuilder.loadTexts: prioritySubTable.setStatus('mandatory')
priorityTableEntry = MibTableRow((1, 3, 6, 1, 4, 1, 72, 7, 31, 1, 1), ).setIndexNames((0, "RETIX-MIB", "priorityTableEntryValue"))
if mibBuilder.loadTexts: priorityTableEntry.setStatus('mandatory')
priorityTableEntryValue = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 7, 31, 1, 1, 1), Integer32()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: priorityTableEntryValue.setStatus('mandatory')
priorityTableEntryType = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 7, 31, 1, 1, 2), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2))).clone(namedValues=NamedValues(("valid", 1), ("invalid", 2)))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: priorityTableEntryType.setStatus('mandatory')
priorityTableAction = MibScalar((1, 3, 6, 1, 4, 1, 72, 7, 31, 2), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2))).clone(namedValues=NamedValues(("noAction", 1), ("clearTable", 2)))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: priorityTableAction.setStatus('mandatory')
priorityPage = MibScalar((1, 3, 6, 1, 4, 1, 72, 7, 31, 3), OctetString().subtype(subtypeSpec=ValueSizeConstraint(16, 16)).setFixedLength(16)).setMaxAccess("readwrite")
if mibBuilder.loadTexts: priorityPage.setStatus('optional')
filterTable = MibIdentifier((1, 3, 6, 1, 4, 1, 72, 7, 32))
filterSubTable = MibTable((1, 3, 6, 1, 4, 1, 72, 7, 32, 1), )
if mibBuilder.loadTexts: filterSubTable.setStatus('mandatory')
filterTableEntry = MibTableRow((1, 3, 6, 1, 4, 1, 72, 7, 32, 1, 1), ).setIndexNames((0, "RETIX-MIB", "filterTableEntryValue"))
if mibBuilder.loadTexts: filterTableEntry.setStatus('mandatory')
filterTableEntryValue = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 7, 32, 1, 1, 1), Integer32()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: filterTableEntryValue.setStatus('mandatory')
filterTableEntryType = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 7, 32, 1, 1, 2), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2))).clone(namedValues=NamedValues(("valid", 1), ("invalid", 2)))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: filterTableEntryType.setStatus('mandatory')
filterTableAction = MibScalar((1, 3, 6, 1, 4, 1, 72, 7, 32, 2), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2))).clone(namedValues=NamedValues(("noAction", 1), ("clearTable", 2)))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: filterTableAction.setStatus('mandatory')
filterPage = MibScalar((1, 3, 6, 1, 4, 1, 72, 7, 32, 3), OctetString().subtype(subtypeSpec=ValueSizeConstraint(16, 16)).setFixedLength(16)).setMaxAccess("readwrite")
if mibBuilder.loadTexts: filterPage.setStatus('mandatory')
ipRSTable = MibTable((1, 3, 6, 1, 4, 1, 72, 10, 1), )
if mibBuilder.loadTexts: ipRSTable.setStatus('mandatory')
ipRSEntry = MibTableRow((1, 3, 6, 1, 4, 1, 72, 10, 1, 1), ).setIndexNames((0, "RETIX-MIB", "ipRSIndex"))
if mibBuilder.loadTexts: ipRSEntry.setStatus('mandatory')
ipRSIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 10, 1, 1, 1), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: ipRSIndex.setStatus('mandatory')
gwProtocol = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 10, 1, 1, 2), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 8))).clone(namedValues=NamedValues(("none", 1), ("rip", 8)))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: gwProtocol.setStatus('mandatory')
ifStatus = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 10, 1, 1, 3), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: ifStatus.setStatus('mandatory')
receivedTotalDgms = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 10, 1, 1, 4), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: receivedTotalDgms.setStatus('mandatory')
transmittedTotalDgms = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 10, 1, 1, 5), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: transmittedTotalDgms.setStatus('mandatory')
outDiscardsTotalDgms = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 10, 1, 1, 6), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: outDiscardsTotalDgms.setStatus('mandatory')
noRouteTotalDgms = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 10, 1, 1, 7), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: noRouteTotalDgms.setStatus('mandatory')
icmpRSTable = MibIdentifier((1, 3, 6, 1, 4, 1, 72, 10, 2))
destUnreachLastRx = MibScalar((1, 3, 6, 1, 4, 1, 72, 10, 2, 1), OctetString().subtype(subtypeSpec=ValueSizeConstraint(13, 13)).setFixedLength(13)).setMaxAccess("readonly")
if mibBuilder.loadTexts: destUnreachLastRx.setStatus('mandatory')
destUnreachLastTx = MibScalar((1, 3, 6, 1, 4, 1, 72, 10, 2, 2), OctetString().subtype(subtypeSpec=ValueSizeConstraint(13, 13)).setFixedLength(13)).setMaxAccess("readonly")
if mibBuilder.loadTexts: destUnreachLastTx.setStatus('mandatory')
sourceQuenchLastRx = MibScalar((1, 3, 6, 1, 4, 1, 72, 10, 2, 3), OctetString().subtype(subtypeSpec=ValueSizeConstraint(13, 13)).setFixedLength(13)).setMaxAccess("readonly")
if mibBuilder.loadTexts: sourceQuenchLastRx.setStatus('mandatory')
sourceQuenchLastTx = MibScalar((1, 3, 6, 1, 4, 1, 72, 10, 2, 4), OctetString().subtype(subtypeSpec=ValueSizeConstraint(13, 13)).setFixedLength(13)).setMaxAccess("readonly")
if mibBuilder.loadTexts: sourceQuenchLastTx.setStatus('mandatory')
redirectsLastRx = MibScalar((1, 3, 6, 1, 4, 1, 72, 10, 2, 5), OctetString().subtype(subtypeSpec=ValueSizeConstraint(13, 13)).setFixedLength(13)).setMaxAccess("readonly")
if mibBuilder.loadTexts: redirectsLastRx.setStatus('mandatory')
redirectsLastTx = MibScalar((1, 3, 6, 1, 4, 1, 72, 10, 2, 6), OctetString().subtype(subtypeSpec=ValueSizeConstraint(13, 13)).setFixedLength(13)).setMaxAccess("readonly")
if mibBuilder.loadTexts: redirectsLastTx.setStatus('mandatory')
echoRequestsLastRx = MibScalar((1, 3, 6, 1, 4, 1, 72, 10, 2, 7), OctetString().subtype(subtypeSpec=ValueSizeConstraint(13, 13)).setFixedLength(13)).setMaxAccess("readonly")
if mibBuilder.loadTexts: echoRequestsLastRx.setStatus('mandatory')
echoRequestsLastTx = MibScalar((1, 3, 6, 1, 4, 1, 72, 10, 2, 8), OctetString().subtype(subtypeSpec=ValueSizeConstraint(13, 13)).setFixedLength(13)).setMaxAccess("readonly")
if mibBuilder.loadTexts: echoRequestsLastTx.setStatus('mandatory')
timeExceededLastRx = MibScalar((1, 3, 6, 1, 4, 1, 72, 10, 2, 9), OctetString().subtype(subtypeSpec=ValueSizeConstraint(13, 13)).setFixedLength(13)).setMaxAccess("readonly")
if mibBuilder.loadTexts: timeExceededLastRx.setStatus('mandatory')
timeExceededLastTx = MibScalar((1, 3, 6, 1, 4, 1, 72, 10, 2, 10), OctetString().subtype(subtypeSpec=ValueSizeConstraint(13, 13)).setFixedLength(13)).setMaxAccess("readonly")
if mibBuilder.loadTexts: timeExceededLastTx.setStatus('mandatory')
paramProbLastRx = MibScalar((1, 3, 6, 1, 4, 1, 72, 10, 2, 11), OctetString().subtype(subtypeSpec=ValueSizeConstraint(13, 13)).setFixedLength(13)).setMaxAccess("readonly")
if mibBuilder.loadTexts: paramProbLastRx.setStatus('mandatory')
paramProbLastTx = MibScalar((1, 3, 6, 1, 4, 1, 72, 10, 2, 12), OctetString().subtype(subtypeSpec=ValueSizeConstraint(13, 13)).setFixedLength(13)).setMaxAccess("readonly")
if mibBuilder.loadTexts: paramProbLastTx.setStatus('mandatory')
ipRouting = MibScalar((1, 3, 6, 1, 4, 1, 72, 10, 3), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 1))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: ipRouting.setStatus('mandatory')
bootpRetryCount = MibScalar((1, 3, 6, 1, 4, 1, 72, 11, 1), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 65535))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: bootpRetryCount.setStatus('mandatory')
downloadRetryCount = MibScalar((1, 3, 6, 1, 4, 1, 72, 11, 2), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 65535))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: downloadRetryCount.setStatus('mandatory')
downloadFilename = MibScalar((1, 3, 6, 1, 4, 1, 72, 11, 3), OctetString().subtype(subtypeSpec=ValueSizeConstraint(0, 128))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: downloadFilename.setStatus('mandatory')
bootserverIpAddress = MibScalar((1, 3, 6, 1, 4, 1, 72, 11, 4), IpAddress()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: bootserverIpAddress.setStatus('mandatory')
loadserverIpAddress = MibScalar((1, 3, 6, 1, 4, 1, 72, 11, 5), IpAddress()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: loadserverIpAddress.setStatus('mandatory')
uniqueBroadcastAddress = MibScalar((1, 3, 6, 1, 4, 1, 72, 11, 6), IpAddress()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: uniqueBroadcastAddress.setStatus('mandatory')
tftpRetryCount = MibScalar((1, 3, 6, 1, 4, 1, 72, 11, 7), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 65535))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: tftpRetryCount.setStatus('mandatory')
tftpRetryPeriod = MibScalar((1, 3, 6, 1, 4, 1, 72, 11, 8), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 65535))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: tftpRetryPeriod.setStatus('mandatory')
initiateBootpDll = MibScalar((1, 3, 6, 1, 4, 1, 72, 11, 9), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2))).clone(namedValues=NamedValues(("noAction", 1), ("initiateBoot", 2)))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: initiateBootpDll.setStatus('mandatory')
boothelperEnabled = MibScalar((1, 3, 6, 1, 4, 1, 72, 12, 1), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 1))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: boothelperEnabled.setStatus('mandatory')
boothelperHopsLimit = MibScalar((1, 3, 6, 1, 4, 1, 72, 12, 2), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 255))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: boothelperHopsLimit.setStatus('mandatory')
boothelperForwardingAddress = MibScalar((1, 3, 6, 1, 4, 1, 72, 12, 3), IpAddress()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: boothelperForwardingAddress.setStatus('mandatory')
ipxRouting = MibScalar((1, 3, 6, 1, 4, 1, 72, 13, 1, 1), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 1))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: ipxRouting.setStatus('mandatory')
ipxIfNumber = MibScalar((1, 3, 6, 1, 4, 1, 72, 13, 1, 2), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: ipxIfNumber.setStatus('mandatory')
ipxIfTable = MibTable((1, 3, 6, 1, 4, 1, 72, 13, 1, 3), )
if mibBuilder.loadTexts: ipxIfTable.setStatus('mandatory')
ipxIfEntry = MibTableRow((1, 3, 6, 1, 4, 1, 72, 13, 1, 3, 1), ).setIndexNames((0, "RETIX-MIB", "ipxIfIndex"))
if mibBuilder.loadTexts: ipxIfEntry.setStatus('mandatory')
ipxIfIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 1, 3, 1, 1), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: ipxIfIndex.setStatus('mandatory')
ipxIfNwkNumber = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 1, 3, 1, 2), OctetString().subtype(subtypeSpec=ValueSizeConstraint(8, 8)).setFixedLength(8)).setMaxAccess("readwrite")
if mibBuilder.loadTexts: ipxIfNwkNumber.setStatus('mandatory')
ipxIfIPXAddress = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 1, 3, 1, 3), OctetString().subtype(subtypeSpec=ValueSizeConstraint(26, 26)).setFixedLength(26)).setMaxAccess("readonly")
if mibBuilder.loadTexts: ipxIfIPXAddress.setStatus('mandatory')
ipxIfEncapsulation = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 1, 3, 1, 4), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 6))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: ipxIfEncapsulation.setStatus('mandatory')
ipxIfDelay = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 1, 3, 1, 5), Integer32()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: ipxIfDelay.setStatus('mandatory')
ipxRoutingTable = MibTable((1, 3, 6, 1, 4, 1, 72, 13, 1, 4), )
if mibBuilder.loadTexts: ipxRoutingTable.setStatus('mandatory')
ipxRITEntry = MibTableRow((1, 3, 6, 1, 4, 1, 72, 13, 1, 4, 1), ).setIndexNames((0, "RETIX-MIB", "ipxRITDestNwkNumber"))
if mibBuilder.loadTexts: ipxRITEntry.setStatus('mandatory')
ipxRITDestNwkNumber = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 1, 4, 1, 1), OctetString()).setMaxAccess("readonly")
if mibBuilder.loadTexts: ipxRITDestNwkNumber.setStatus('mandatory')
ipxRITGwyHostAddress = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 1, 4, 1, 2), OctetString().subtype(subtypeSpec=ValueSizeConstraint(10, 10)).setFixedLength(10)).setMaxAccess("readonly")
if mibBuilder.loadTexts: ipxRITGwyHostAddress.setStatus('mandatory')
ipxRITHopCount = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 1, 4, 1, 3), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: ipxRITHopCount.setStatus('mandatory')
ipxRITDelay = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 1, 4, 1, 4), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: ipxRITDelay.setStatus('mandatory')
ipxRITInterface = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 1, 4, 1, 5), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: ipxRITInterface.setStatus('mandatory')
ipxRITDirectConnect = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 1, 4, 1, 6), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: ipxRITDirectConnect.setStatus('mandatory')
ipxSAPBinderyTable = MibTable((1, 3, 6, 1, 4, 1, 72, 13, 1, 5), )
if mibBuilder.loadTexts: ipxSAPBinderyTable.setStatus('mandatory')
ipxSAPBinderyEntry = MibTableRow((1, 3, 6, 1, 4, 1, 72, 13, 1, 5, 1), ).setIndexNames((0, "RETIX-MIB", "ipxSAPBinderyType"), (0, "RETIX-MIB", "ipxSAPBinderyServerIPXAddress"))
if mibBuilder.loadTexts: ipxSAPBinderyEntry.setStatus('mandatory')
ipxSAPBinderyType = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 1, 5, 1, 1), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 36, 71, 65535))).clone(namedValues=NamedValues(("user", 1), ("userGroup", 2), ("printQueue", 3), ("fileServer", 4), ("jobServer", 5), ("gateway", 6), ("printServer", 7), ("archiveQueue", 8), ("archiveServer", 9), ("jobQueue", 10), ("administration", 11), ("remoteBridgeServer", 36), ("advertizingPrintServer", 71), ("wild", 65535)))).setMaxAccess("readonly")
if mibBuilder.loadTexts: ipxSAPBinderyType.setStatus('mandatory')
ipxSAPBinderyServerIPXAddress = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 1, 5, 1, 2), OctetString().subtype(subtypeSpec=ValueSizeConstraint(26, 26)).setFixedLength(26)).setMaxAccess("readonly")
if mibBuilder.loadTexts: ipxSAPBinderyServerIPXAddress.setStatus('mandatory')
ipxSAPBinderyServerName = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 1, 5, 1, 3), OctetString().subtype(subtypeSpec=ValueSizeConstraint(0, 48))).setMaxAccess("readonly")
if mibBuilder.loadTexts: ipxSAPBinderyServerName.setStatus('mandatory')
ipxSAPBinderyHopCount = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 1, 5, 1, 4), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: ipxSAPBinderyHopCount.setStatus('mandatory')
ipxSAPBinderySocket = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 1, 5, 1, 5), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: ipxSAPBinderySocket.setStatus('mandatory')
ipxReceivedDgms = MibScalar((1, 3, 6, 1, 4, 1, 72, 13, 1, 6), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: ipxReceivedDgms.setStatus('mandatory')
ipxTransmittedDgms = MibScalar((1, 3, 6, 1, 4, 1, 72, 13, 1, 7), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: ipxTransmittedDgms.setStatus('mandatory')
ipxNotRoutedRxDgms = MibScalar((1, 3, 6, 1, 4, 1, 72, 13, 1, 8), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: ipxNotRoutedRxDgms.setStatus('mandatory')
ipxForwardedDgms = MibScalar((1, 3, 6, 1, 4, 1, 72, 13, 1, 9), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: ipxForwardedDgms.setStatus('mandatory')
ipxInDelivers = MibScalar((1, 3, 6, 1, 4, 1, 72, 13, 1, 10), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: ipxInDelivers.setStatus('mandatory')
ipxInHdrErrors = MibScalar((1, 3, 6, 1, 4, 1, 72, 13, 1, 11), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: ipxInHdrErrors.setStatus('mandatory')
ipxAccessViolations = MibScalar((1, 3, 6, 1, 4, 1, 72, 13, 1, 12), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: ipxAccessViolations.setStatus('mandatory')
ipxInDiscards = MibScalar((1, 3, 6, 1, 4, 1, 72, 13, 1, 13), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: ipxInDiscards.setStatus('mandatory')
ipxOutDiscards = MibScalar((1, 3, 6, 1, 4, 1, 72, 13, 1, 14), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: ipxOutDiscards.setStatus('mandatory')
ipxOtherDiscards = MibScalar((1, 3, 6, 1, 4, 1, 72, 13, 1, 15), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: ipxOtherDiscards.setStatus('mandatory')
dcntRouting = MibScalar((1, 3, 6, 1, 4, 1, 72, 13, 2, 1), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 1))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: dcntRouting.setStatus('mandatory')
dcntIfNumber = MibScalar((1, 3, 6, 1, 4, 1, 72, 13, 2, 2), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: dcntIfNumber.setStatus('mandatory')
dcntIfTable = MibTable((1, 3, 6, 1, 4, 1, 72, 13, 2, 3), )
if mibBuilder.loadTexts: dcntIfTable.setStatus('mandatory')
dcntIfTableEntry = MibTableRow((1, 3, 6, 1, 4, 1, 72, 13, 2, 3, 1), ).setIndexNames((0, "RETIX-MIB", "dcntIfIndex"))
if mibBuilder.loadTexts: dcntIfTableEntry.setStatus('mandatory')
dcntIfIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 2, 3, 1, 1), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: dcntIfIndex.setStatus('mandatory')
dcntIfCost = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 2, 3, 1, 2), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 1023))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: dcntIfCost.setStatus('mandatory')
dcntIfRtrPriority = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 2, 3, 1, 3), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 127))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: dcntIfRtrPriority.setStatus('mandatory')
dcntIfDesgntdRtr = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 2, 3, 1, 4), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 1))).setMaxAccess("readonly")
if mibBuilder.loadTexts: dcntIfDesgntdRtr.setStatus('mandatory')
dcntIfHelloTimerBCT3 = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 2, 3, 1, 5), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 8191))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: dcntIfHelloTimerBCT3.setStatus('mandatory')
dcntRoutingTable = MibTable((1, 3, 6, 1, 4, 1, 72, 13, 2, 4), )
if mibBuilder.loadTexts: dcntRoutingTable.setStatus('mandatory')
dcntRITEntry = MibTableRow((1, 3, 6, 1, 4, 1, 72, 13, 2, 4, 1), ).setIndexNames((0, "RETIX-MIB", "dcntRITDestNode"))
if mibBuilder.loadTexts: dcntRITEntry.setStatus('mandatory')
dcntRITDestNode = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 2, 4, 1, 1), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: dcntRITDestNode.setStatus('mandatory')
dcntRITNextHop = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 2, 4, 1, 2), OctetString()).setMaxAccess("readonly")
if mibBuilder.loadTexts: dcntRITNextHop.setStatus('mandatory')
dcntRITCost = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 2, 4, 1, 3), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: dcntRITCost.setStatus('mandatory')
dcntRITHops = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 2, 4, 1, 4), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: dcntRITHops.setStatus('mandatory')
dcntRITInterface = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 2, 4, 1, 5), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: dcntRITInterface.setStatus('mandatory')
dcntAreaRoutingTable = MibTable((1, 3, 6, 1, 4, 1, 72, 13, 2, 5), )
if mibBuilder.loadTexts: dcntAreaRoutingTable.setStatus('mandatory')
dcntAreaRITEntry = MibTableRow((1, 3, 6, 1, 4, 1, 72, 13, 2, 5, 1), ).setIndexNames((0, "RETIX-MIB", "dcntAreaRITDestArea"))
if mibBuilder.loadTexts: dcntAreaRITEntry.setStatus('mandatory')
dcntAreaRITDestArea = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 2, 5, 1, 1), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: dcntAreaRITDestArea.setStatus('mandatory')
dcntAreaRITNextHop = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 2, 5, 1, 2), OctetString()).setMaxAccess("readonly")
if mibBuilder.loadTexts: dcntAreaRITNextHop.setStatus('mandatory')
dcntAreaRITCost = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 2, 5, 1, 3), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: dcntAreaRITCost.setStatus('mandatory')
dcntAreaRITHops = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 2, 5, 1, 4), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: dcntAreaRITHops.setStatus('mandatory')
dcntAreaRITInterface = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 2, 5, 1, 5), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: dcntAreaRITInterface.setStatus('mandatory')
dcntNodeAddress = MibScalar((1, 3, 6, 1, 4, 1, 72, 13, 2, 6), OctetString()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: dcntNodeAddress.setStatus('mandatory')
dcntInterAreaMaxCost = MibScalar((1, 3, 6, 1, 4, 1, 72, 13, 2, 7), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 1023))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: dcntInterAreaMaxCost.setStatus('mandatory')
dcntInterAreaMaxHops = MibScalar((1, 3, 6, 1, 4, 1, 72, 13, 2, 8), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 1023))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: dcntInterAreaMaxHops.setStatus('mandatory')
dcntIntraAreaMaxCost = MibScalar((1, 3, 6, 1, 4, 1, 72, 13, 2, 9), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 1023))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: dcntIntraAreaMaxCost.setStatus('mandatory')
dcntIntraAreaMaxHops = MibScalar((1, 3, 6, 1, 4, 1, 72, 13, 2, 10), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 1023))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: dcntIntraAreaMaxHops.setStatus('mandatory')
dcntMaxVisits = MibScalar((1, 3, 6, 1, 4, 1, 72, 13, 2, 11), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 63))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: dcntMaxVisits.setStatus('mandatory')
dcntRtngMsgTimerBCT1 = MibScalar((1, 3, 6, 1, 4, 1, 72, 13, 2, 12), Integer32().subtype(subtypeSpec=ValueRangeConstraint(5, 30))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: dcntRtngMsgTimerBCT1.setStatus('mandatory')
dcntRateControlFreqTimerT2 = MibScalar((1, 3, 6, 1, 4, 1, 72, 13, 2, 13), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 5))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: dcntRateControlFreqTimerT2.setStatus('mandatory')
dcntReveivedDgms = MibScalar((1, 3, 6, 1, 4, 1, 72, 13, 2, 14), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: dcntReveivedDgms.setStatus('mandatory')
dcntForwardedDgms = MibScalar((1, 3, 6, 1, 4, 1, 72, 13, 2, 15), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: dcntForwardedDgms.setStatus('mandatory')
dcntOutRequestedDgms = MibScalar((1, 3, 6, 1, 4, 1, 72, 13, 2, 16), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: dcntOutRequestedDgms.setStatus('mandatory')
dcntInDiscards = MibScalar((1, 3, 6, 1, 4, 1, 72, 13, 2, 17), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: dcntInDiscards.setStatus('mandatory')
dcntOutDiscards = MibScalar((1, 3, 6, 1, 4, 1, 72, 13, 2, 18), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: dcntOutDiscards.setStatus('mandatory')
dcntNoRoutes = MibScalar((1, 3, 6, 1, 4, 1, 72, 13, 2, 19), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: dcntNoRoutes.setStatus('mandatory')
dcntInHdrErrors = MibScalar((1, 3, 6, 1, 4, 1, 72, 13, 2, 20), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: dcntInHdrErrors.setStatus('mandatory')
rmtLapbConfigTable = MibTable((1, 3, 6, 1, 4, 1, 72, 13, 3, 1), )
if mibBuilder.loadTexts: rmtLapbConfigTable.setStatus('mandatory')
rmtLapbCTEntry = MibTableRow((1, 3, 6, 1, 4, 1, 72, 13, 3, 1, 1), ).setIndexNames((0, "RETIX-MIB", "rmtLapbCTIndex"))
if mibBuilder.loadTexts: rmtLapbCTEntry.setStatus('mandatory')
rmtLapbCTIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 3, 1, 1, 1), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: rmtLapbCTIndex.setStatus('mandatory')
rmtLapbCTLinkAddr = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 3, 1, 1, 2), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 1))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: rmtLapbCTLinkAddr.setStatus('mandatory')
rmtLapbCTExtSeqNumbering = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 3, 1, 1, 3), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 1))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: rmtLapbCTExtSeqNumbering.setStatus('mandatory')
rmtLapbCTWindow = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 3, 1, 1, 4), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 127))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: rmtLapbCTWindow.setStatus('mandatory')
rmtLapbCTModeT1 = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 3, 1, 1, 5), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 1))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: rmtLapbCTModeT1.setStatus('mandatory')
rmtLapbCTManualT1Value = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 3, 1, 1, 6), Integer32().subtype(subtypeSpec=ValueRangeConstraint(10, 5000))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: rmtLapbCTManualT1Value.setStatus('mandatory')
rmtLapbCTT3LinkIdleTimer = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 3, 1, 1, 7), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 65535))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: rmtLapbCTT3LinkIdleTimer.setStatus('mandatory')
rmtLapbCTN2RetryCount = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 3, 1, 1, 8), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 255))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: rmtLapbCTN2RetryCount.setStatus('mandatory')
rmtLapbCTLinkReset = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 3, 1, 1, 9), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2))).clone(namedValues=NamedValues(("noAction", 1), ("resetLink", 2)))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: rmtLapbCTLinkReset.setStatus('mandatory')
rmtLapbCTX25PortLineSpeed = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 3, 1, 1, 10), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1200, 2400, 4800, 9600, 19200, 32000, 48000, 64000))).clone(namedValues=NamedValues(("b1200", 1200), ("b2400", 2400), ("b4800", 4800), ("b9600", 9600), ("b19200", 19200), ("b32000", 32000), ("b48000", 48000), ("b64000", 64000)))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: rmtLapbCTX25PortLineSpeed.setStatus('mandatory')
rmtLapbCTInitLinkConnect = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 3, 1, 1, 11), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2))).clone(namedValues=NamedValues(("noAction", 1), ("connect", 2)))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: rmtLapbCTInitLinkConnect.setStatus('mandatory')
rmtLapbStatsTable = MibTable((1, 3, 6, 1, 4, 1, 72, 13, 3, 2), )
if mibBuilder.loadTexts: rmtLapbStatsTable.setStatus('mandatory')
rmtLapbSTEntry = MibTableRow((1, 3, 6, 1, 4, 1, 72, 13, 3, 2, 1), ).setIndexNames((0, "RETIX-MIB", "rmtLapbSTIndex"))
if mibBuilder.loadTexts: rmtLapbSTEntry.setStatus('mandatory')
rmtLapbSTIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 3, 2, 1, 1), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: rmtLapbSTIndex.setStatus('mandatory')
rmtLapbSTState = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 3, 2, 1, 2), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 3))).setMaxAccess("readonly")
if mibBuilder.loadTexts: rmtLapbSTState.setStatus('mandatory')
rmtLapbSTAutoT1value = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 3, 2, 1, 3), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: rmtLapbSTAutoT1value.setStatus('mandatory')
rmtLapbSTLastResetTime = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 3, 2, 1, 4), OctetString().subtype(subtypeSpec=ValueSizeConstraint(13, 13)).setFixedLength(13)).setMaxAccess("readonly")
if mibBuilder.loadTexts: rmtLapbSTLastResetTime.setStatus('mandatory')
rmtLapbSTLastResetReason = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 3, 2, 1, 5), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 8))).setMaxAccess("readonly")
if mibBuilder.loadTexts: rmtLapbSTLastResetReason.setStatus('mandatory')
rmtLapbSTCountResets = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 3, 2, 1, 6), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: rmtLapbSTCountResets.setStatus('mandatory')
rmtLapbSTCountSentFrames = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 3, 2, 1, 7), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: rmtLapbSTCountSentFrames.setStatus('mandatory')
rmtLapbSTCountRcvFrames = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 3, 2, 1, 8), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: rmtLapbSTCountRcvFrames.setStatus('mandatory')
rmtLapbSTCountSentOctets = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 3, 2, 1, 9), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: rmtLapbSTCountSentOctets.setStatus('mandatory')
rmtLapbSTCountRcvOctets = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 3, 2, 1, 10), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: rmtLapbSTCountRcvOctets.setStatus('mandatory')
rmtLapbSTCountAborts = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 3, 2, 1, 11), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: rmtLapbSTCountAborts.setStatus('mandatory')
rmtLapbSTCountCrcErrors = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 3, 2, 1, 12), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: rmtLapbSTCountCrcErrors.setStatus('mandatory')
x25Operation = MibScalar((1, 3, 6, 1, 4, 1, 72, 13, 4, 1), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 1))).setMaxAccess("readonly")
if mibBuilder.loadTexts: x25Operation.setStatus('mandatory')
x25OperNextReset = MibScalar((1, 3, 6, 1, 4, 1, 72, 13, 4, 2), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 1))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: x25OperNextReset.setStatus('mandatory')
x25ConSetupTable = MibTable((1, 3, 6, 1, 4, 1, 72, 13, 4, 3), )
if mibBuilder.loadTexts: x25ConSetupTable.setStatus('mandatory')
x25CSTEntry = MibTableRow((1, 3, 6, 1, 4, 1, 72, 13, 4, 3, 1), ).setIndexNames((0, "RETIX-MIB", "x25CSTIndex"))
if mibBuilder.loadTexts: x25CSTEntry.setStatus('mandatory')
x25CSTIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 4, 3, 1, 1), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: x25CSTIndex.setStatus('mandatory')
x25CST8084Switch = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 4, 3, 1, 2), Integer32()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: x25CST8084Switch.setStatus('mandatory')
x25CSTSrcDTEAddr = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 4, 3, 1, 3), OctetString().subtype(subtypeSpec=ValueSizeConstraint(15, 15)).setFixedLength(15)).setMaxAccess("readwrite")
if mibBuilder.loadTexts: x25CSTSrcDTEAddr.setStatus('mandatory')
x25CSTDestDTEAddr = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 4, 3, 1, 4), OctetString().subtype(subtypeSpec=ValueSizeConstraint(15, 15)).setFixedLength(15)).setMaxAccess("readwrite")
if mibBuilder.loadTexts: x25CSTDestDTEAddr.setStatus('mandatory')
x25CST2WayLgclChanNum = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 4, 3, 1, 5), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 4095))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: x25CST2WayLgclChanNum.setStatus('mandatory')
x25CSTPktSeqNumFlg = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 4, 3, 1, 6), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 4))).clone(namedValues=NamedValues(("mod8", 1), ("mod128", 4)))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: x25CSTPktSeqNumFlg.setStatus('mandatory')
x25CSTFlowCntrlNeg = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 4, 3, 1, 7), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 1))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: x25CSTFlowCntrlNeg.setStatus('mandatory')
x25CSTDefaultWinSize = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 4, 3, 1, 8), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 127))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: x25CSTDefaultWinSize.setStatus('mandatory')
x25CSTDefaultPktSize = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 4, 3, 1, 9), Integer32()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: x25CSTDefaultPktSize.setStatus('mandatory')
x25CSTNegWinSize = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 4, 3, 1, 10), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 127))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: x25CSTNegWinSize.setStatus('mandatory')
x25CSTNegPktSize = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 4, 3, 1, 11), Integer32()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: x25CSTNegPktSize.setStatus('mandatory')
x25CSTCUGSub = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 4, 3, 1, 12), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 4))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: x25CSTCUGSub.setStatus('mandatory')
x25CSTLclCUGValue = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 4, 3, 1, 13), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 99))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: x25CSTLclCUGValue.setStatus('mandatory')
x25CSTRvrsChrgReq = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 4, 3, 1, 14), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 1))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: x25CSTRvrsChrgReq.setStatus('mandatory')
x25CSTRvrsChrgAcc = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 4, 3, 1, 15), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 1))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: x25CSTRvrsChrgAcc.setStatus('mandatory')
x25ConControlTable = MibTable((1, 3, 6, 1, 4, 1, 72, 13, 4, 4), )
if mibBuilder.loadTexts: x25ConControlTable.setStatus('mandatory')
x25CCTEntry = MibTableRow((1, 3, 6, 1, 4, 1, 72, 13, 4, 4, 1), ).setIndexNames((0, "RETIX-MIB", "x25CCTIndex"))
if mibBuilder.loadTexts: x25CCTEntry.setStatus('mandatory')
x25CCTIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 4, 4, 1, 1), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: x25CCTIndex.setStatus('mandatory')
x25CCTManualConnect = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 4, 4, 1, 2), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2))).clone(namedValues=NamedValues(("noAction", 1), ("connect", 2)))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: x25CCTManualConnect.setStatus('mandatory')
x25CCTManualDisconnect = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 4, 4, 1, 3), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2))).clone(namedValues=NamedValues(("noAction", 1), ("disconnect", 2)))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: x25CCTManualDisconnect.setStatus('mandatory')
x25CCTCfgAutoConRetry = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 4, 4, 1, 4), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 1))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: x25CCTCfgAutoConRetry.setStatus('mandatory')
x25CCTOperAutoConRetryFlg = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 4, 4, 1, 5), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 1))).setMaxAccess("readonly")
if mibBuilder.loadTexts: x25CCTOperAutoConRetryFlg.setStatus('mandatory')
x25CCTAutoConRetryTimer = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 4, 4, 1, 6), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 3600))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: x25CCTAutoConRetryTimer.setStatus('mandatory')
x25CCTMaxAutoConRetries = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 4, 4, 1, 7), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 255))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: x25CCTMaxAutoConRetries.setStatus('mandatory')
x25CCTCfgTODControl = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 4, 4, 1, 8), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 1))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: x25CCTCfgTODControl.setStatus('mandatory')
x25CCTCurrentTODControl = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 4, 4, 1, 9), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 1))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: x25CCTCurrentTODControl.setStatus('mandatory')
x25CCTTODToConnect = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 4, 4, 1, 10), OctetString().subtype(subtypeSpec=ValueSizeConstraint(4, 4)).setFixedLength(4)).setMaxAccess("readwrite")
if mibBuilder.loadTexts: x25CCTTODToConnect.setStatus('mandatory')
x25CCTTODToDisconnect = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 4, 4, 1, 11), OctetString().subtype(subtypeSpec=ValueSizeConstraint(4, 4)).setFixedLength(4)).setMaxAccess("readwrite")
if mibBuilder.loadTexts: x25CCTTODToDisconnect.setStatus('mandatory')
x25TimerTable = MibTable((1, 3, 6, 1, 4, 1, 72, 13, 4, 5), )
if mibBuilder.loadTexts: x25TimerTable.setStatus('mandatory')
x25TTEntry = MibTableRow((1, 3, 6, 1, 4, 1, 72, 13, 4, 5, 1), ).setIndexNames((0, "RETIX-MIB", "x25TTIndex"))
if mibBuilder.loadTexts: x25TTEntry.setStatus('mandatory')
x25TTIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 4, 5, 1, 1), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: x25TTIndex.setStatus('mandatory')
x25TTT20Timer = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 4, 5, 1, 2), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 1024))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: x25TTT20Timer.setStatus('mandatory')
x25TTT21Timer = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 4, 5, 1, 3), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 1024))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: x25TTT21Timer.setStatus('mandatory')
x25TTT22Timer = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 4, 5, 1, 4), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 1024))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: x25TTT22Timer.setStatus('mandatory')
x25TTT23Timer = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 4, 5, 1, 5), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 1024))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: x25TTT23Timer.setStatus('mandatory')
x25TTR20Limit = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 4, 5, 1, 6), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 255))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: x25TTR20Limit.setStatus('mandatory')
x25TTR22Limit = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 4, 5, 1, 7), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 255))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: x25TTR22Limit.setStatus('mandatory')
x25TTR23Limit = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 4, 5, 1, 8), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 255))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: x25TTR23Limit.setStatus('mandatory')
x25StatusTable = MibTable((1, 3, 6, 1, 4, 1, 72, 13, 4, 6), )
if mibBuilder.loadTexts: x25StatusTable.setStatus('mandatory')
x25StatusTableEntry = MibTableRow((1, 3, 6, 1, 4, 1, 72, 13, 4, 6, 1), ).setIndexNames((0, "RETIX-MIB", "x25StatusIndex"))
if mibBuilder.loadTexts: x25StatusTableEntry.setStatus('mandatory')
x25StatusIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 4, 6, 1, 1), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: x25StatusIndex.setStatus('mandatory')
x25StatusIfStatus = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 4, 6, 1, 2), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: x25StatusIfStatus.setStatus('mandatory')
x25StatusSVCStatus = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 4, 6, 1, 3), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: x25StatusSVCStatus.setStatus('mandatory')
x25StatusWinSize = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 4, 6, 1, 4), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: x25StatusWinSize.setStatus('mandatory')
x25StatusPktSize = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 4, 6, 1, 5), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: x25StatusPktSize.setStatus('mandatory')
x25StatusCauseLastInClear = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 4, 6, 1, 6), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 255))).setMaxAccess("readonly")
if mibBuilder.loadTexts: x25StatusCauseLastInClear.setStatus('mandatory')
x25StatusDiagLastInClear = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 4, 6, 1, 7), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 255))).setMaxAccess("readonly")
if mibBuilder.loadTexts: x25StatusDiagLastInClear.setStatus('mandatory')
x25StatsTable = MibTable((1, 3, 6, 1, 4, 1, 72, 13, 4, 7), )
if mibBuilder.loadTexts: x25StatsTable.setStatus('mandatory')
x25StatsTableEntry = MibTableRow((1, 3, 6, 1, 4, 1, 72, 13, 4, 7, 1), ).setIndexNames((0, "RETIX-MIB", "x25STSVCIndex"))
if mibBuilder.loadTexts: x25StatsTableEntry.setStatus('mandatory')
x25STSVCIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 4, 7, 1, 1), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: x25STSVCIndex.setStatus('mandatory')
x25STTxDataPkts = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 4, 7, 1, 2), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: x25STTxDataPkts.setStatus('mandatory')
x25STRxDataPkts = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 4, 7, 1, 3), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: x25STRxDataPkts.setStatus('mandatory')
x25STTxConnectReqPkts = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 4, 7, 1, 4), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: x25STTxConnectReqPkts.setStatus('mandatory')
x25STRxIncomingCallPkts = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 4, 7, 1, 5), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: x25STRxIncomingCallPkts.setStatus('mandatory')
x25STTxClearReqPkts = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 4, 7, 1, 6), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: x25STTxClearReqPkts.setStatus('mandatory')
x25STRxClearIndPkts = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 4, 7, 1, 7), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: x25STRxClearIndPkts.setStatus('mandatory')
x25STTxResetReqPkts = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 4, 7, 1, 8), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: x25STTxResetReqPkts.setStatus('mandatory')
x25STRxResetIndPkts = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 4, 7, 1, 9), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: x25STRxResetIndPkts.setStatus('mandatory')
x25STTxRestartReqPkts = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 4, 7, 1, 10), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: x25STTxRestartReqPkts.setStatus('mandatory')
x25STRxRestartIndPkts = MibTableColumn((1, 3, 6, 1, 4, 1, 72, 13, 4, 7, 1, 11), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: x25STRxRestartIndPkts.setStatus('mandatory')
mibBuilder.exportSymbols("RETIX-MIB", x25StatsTable=x25StatsTable, ipxOtherDiscards=ipxOtherDiscards, mlink=mlink, triangulation=triangulation, x25STTxDataPkts=x25STTxDataPkts, redirectsLastTx=redirectsLastTx, trapDestEntry=trapDestEntry, serialLoading=serialLoading, x25StatusDiagLastInClear=x25StatusDiagLastInClear, receivedTotalDgms=receivedTotalDgms, snmpAccessPolicyTable=snmpAccessPolicyTable, phySerIfT1frameAndCode=phySerIfT1frameAndCode, x25CSTDefaultWinSize=x25CSTDefaultWinSize, maxRejectedFrames=maxRejectedFrames, x25CCTEntry=x25CCTEntry, x25CSTSrcDTEAddr=x25CSTSrcDTEAddr, filterTableAction=filterTableAction, authenticationTrapStatus=authenticationTrapStatus, ipRouting=ipRouting, operatingMode=operatingMode, lapbCountRcvOctets=lapbCountRcvOctets, ipxRITInterface=ipxRITInterface, phySerIfTransitDelay=phySerIfTransitDelay, priorityMatches=priorityMatches, x25STTxConnectReqPkts=x25STTxConnectReqPkts, x25CSTFlowCntrlNeg=x25CSTFlowCntrlNeg, ipxRITEntry=ipxRITEntry, ieee8023Entry=ieee8023Entry, averagePeriod=averagePeriod, remote=remote, x25=x25, x25STTxRestartReqPkts=x25STTxRestartReqPkts, dcntIfCost=dcntIfCost, lapbEntry=lapbEntry, ifStatus=ifStatus, ipxIfEntry=ipxIfEntry, mlinkTable=mlinkTable, ipxNotRoutedRxDgms=ipxNotRoutedRxDgms, ieee8023FrameTooLongs=ieee8023FrameTooLongs, portPriorityAutoValue=portPriorityAutoValue, phySerIfT1SlotLvalue=phySerIfT1SlotLvalue, spatHelloTimer=spatHelloTimer, rmtLapbStatsTable=rmtLapbStatsTable, internalQueueCurrentLength=internalQueueCurrentLength, ipxRITGwyHostAddress=ipxRITGwyHostAddress, dcntIntraAreaMaxCost=dcntIntraAreaMaxCost, bridge=bridge, ieee8023NewMACAddressIndex=ieee8023NewMACAddressIndex, echoRequestsLastTx=echoRequestsLastTx, rmtLapbSTCountSentOctets=rmtLapbSTCountSentOctets, mlinkIndex=mlinkIndex, lapbLastResetReason=lapbLastResetReason, x25CSTDestDTEAddr=x25CSTDestDTEAddr, ipxForwardedDgms=ipxForwardedDgms, boothelper=boothelper, dcntRITCost=dcntRITCost, dcntNodeAddress=dcntNodeAddress, rmtLapbSTIndex=rmtLapbSTIndex, ieee8023FramesReceivedOks=ieee8023FramesReceivedOks, sourceQuenchLastTx=sourceQuenchLastTx, lanAccepts=lanAccepts, ieee8023SingleCollisionFrames=ieee8023SingleCollisionFrames, snmpAccessPolicyAction=snmpAccessPolicyAction, ipxSAPBinderyEntry=ipxSAPBinderyEntry, maxSerialLoading=maxSerialLoading, ipxTransmittedDgms=ipxTransmittedDgms, phySerIfT1dRatePerChan=phySerIfT1dRatePerChan, x25CCTMaxAutoConRetries=x25CCTMaxAutoConRetries, x25CSTIndex=x25CSTIndex, portSpatState=portSpatState, x25StatusIfStatus=x25StatusIfStatus, lapbIndex=lapbIndex, downloadRetryCount=downloadRetryCount, x25ConControlTable=x25ConControlTable, x25STRxIncomingCallPkts=x25STRxIncomingCallPkts, ipxIfNwkNumber=ipxIfNwkNumber, stpTable=stpTable, dcntForwardedDgms=dcntForwardedDgms, ieee8023LateCollisions=ieee8023LateCollisions, activeRemote=activeRemote, ipxRITDirectConnect=ipxRITDirectConnect, filterSubTable=filterSubTable, x25CCTManualDisconnect=x25CCTManualDisconnect, lapbCountAborts=lapbCountAborts, rmtLapbSTLastResetReason=rmtLapbSTLastResetReason, x25StatusCauseLastInClear=x25StatusCauseLastInClear, x25TTT23Timer=x25TTT23Timer, ieee8023MulticastReceiveStatus=ieee8023MulticastReceiveStatus, ieee8023NewMACAddressEntry=ieee8023NewMACAddressEntry, dynamicLearningInLM=dynamicLearningInLM, mlinkEntry=mlinkEntry, retix=retix, dcntIfHelloTimerBCT3=dcntIfHelloTimerBCT3, ieee8023MulticastFramesReceivedOks=ieee8023MulticastFramesReceivedOks, rmtLapbCTExtSeqNumbering=rmtLapbCTExtSeqNumbering, dcntAreaRITEntry=dcntAreaRITEntry, x25StatusTable=x25StatusTable, redirectsLastRx=redirectsLastRx, ieee8023OctetsTransmittedOks=ieee8023OctetsTransmittedOks, ieee8023InternalMACTransmitErrors=ieee8023InternalMACTransmitErrors, snmpAccessPolicyType=snmpAccessPolicyType, ieee8023FramesTransmittedOks=ieee8023FramesTransmittedOks, x25CCTIndex=x25CCTIndex, dcntAreaRoutingTable=dcntAreaRoutingTable, ieee8023MulticastFramesTransmittedOks=ieee8023MulticastFramesTransmittedOks, ipxInDiscards=ipxInDiscards, product=product, x25TTT22Timer=x25TTT22Timer, typeFilter=typeFilter, ieee8023CarrierSenseErrors=ieee8023CarrierSenseErrors, stpIndex=stpIndex, uniqueBroadcastAddress=uniqueBroadcastAddress, boothelperEnabled=boothelperEnabled, trapDestAction=trapDestAction, snmpAccessPolicyObject=snmpAccessPolicyObject, dcntRITInterface=dcntRITInterface, x25STRxResetIndPkts=x25STRxResetIndPkts, trapDestinationTable=trapDestinationTable, lapbState=lapbState, expressQueueUpperLimit=expressQueueUpperLimit, ipxRITDestNwkNumber=ipxRITDestNwkNumber, accessPolicyIndex=accessPolicyIndex, filteringDbStatus=filteringDbStatus, ipxIfIndex=ipxIfIndex, phySerIfTable=phySerIfTable, rmtLapbSTCountResets=rmtLapbSTCountResets, x25StatsTableEntry=x25StatsTableEntry, station=station, dcntIntraAreaMaxHops=dcntIntraAreaMaxHops, filteringDbDisposition=filteringDbDisposition, rmtLapbCTN2RetryCount=rmtLapbCTN2RetryCount, spanningTree=spanningTree, downloadFilename=downloadFilename, ieee8023=ieee8023, filteringDbEntry=filteringDbEntry, ieee8023NewMACAddress=ieee8023NewMACAddress, phySerIfMeasuredSpeed=phySerIfMeasuredSpeed, accessMode=accessMode, x25CCTAutoConRetryTimer=x25CCTAutoConRetryTimer, lapbWindow=lapbWindow, dcntIfTableEntry=dcntIfTableEntry, typePrioritisation=typePrioritisation, loPriQueueUpperLimit=loPriQueueUpperLimit, lapbPolarity=lapbPolarity, x25CSTRvrsChrgAcc=x25CSTRvrsChrgAcc, x25CST8084Switch=x25CST8084Switch, rmtLapbSTEntry=rmtLapbSTEntry, x25STRxClearIndPkts=x25STRxClearIndPkts, dcntInterAreaMaxHops=dcntInterAreaMaxHops, rmtLapbSTLastResetTime=rmtLapbSTLastResetTime, spatVersion=spatVersion, priorityPage=priorityPage, echoRequestsLastRx=echoRequestsLastRx, rmtLapbCTLinkReset=rmtLapbCTLinkReset, dcntInterAreaMaxCost=dcntInterAreaMaxCost, phySerIfPortSpeed=phySerIfPortSpeed, ieee8023Index=ieee8023Index, dcntOutRequestedDgms=dcntOutRequestedDgms, ieee8023Number=ieee8023Number, rmtLapbCTInitLinkConnect=rmtLapbCTInitLinkConnect, priorityTableEntryValue=priorityTableEntryValue, stationTime=stationTime, forgetAddressTimer=forgetAddressTimer, ipxIfTable=ipxIfTable, x25ConSetupTable=x25ConSetupTable, phySerIfT1SlotHvalue=phySerIfT1SlotHvalue, dcntRateControlFreqTimerT2=dcntRateControlFreqTimerT2, ipxRITDelay=ipxRITDelay, ieee8023AlignmentErrors=ieee8023AlignmentErrors, rmtLapbCTModeT1=rmtLapbCTModeT1, deletedMlinkFrames=deletedMlinkFrames, stpEntry=stpEntry, filterTableEntryValue=filterTableEntryValue, ieee8023ExcessiveDeferrals=ieee8023ExcessiveDeferrals, ieee8023FCSErrors=ieee8023FCSErrors, queueUpperLimit=queueUpperLimit, x25CSTEntry=x25CSTEntry, dcntRITEntry=dcntRITEntry, ipxOutDiscards=ipxOutDiscards, dcntAreaRITCost=dcntAreaRITCost, expressQueueCurrentLength=expressQueueCurrentLength, resetStation=resetStation, ieee8023InternalMACReceiveErrors=ieee8023InternalMACReceiveErrors, icmpRSTable=icmpRSTable, ipxIfEncapsulation=ipxIfEncapsulation, dcntNoRoutes=dcntNoRoutes, ipxSAPBinderyServerIPXAddress=ipxSAPBinderyServerIPXAddress, x25Operation=x25Operation, phySerIfIsSpeedsettable=phySerIfIsSpeedsettable, ieee8023BroadcastFramesTransmittedOks=ieee8023BroadcastFramesTransmittedOks, phySerIfEntry=phySerIfEntry, lanInterfaceType=lanInterfaceType, mlinkSendSeq=mlinkSendSeq, rmtLapbSTState=rmtLapbSTState, dcntRouting=dcntRouting, ipxSAPBinderyHopCount=ipxSAPBinderyHopCount, rmtLapbConfigTable=rmtLapbConfigTable, rmtLapbSTCountCrcErrors=rmtLapbSTCountCrcErrors, lapb=lapb, rmtLapb=rmtLapb, physBlkSize=physBlkSize, ipxInDelivers=ipxInDelivers, mlinkRxTimeout=mlinkRxTimeout, trapDestEntryCommunityName=trapDestEntryCommunityName, ieeeFormatPriority=ieeeFormatPriority, x25TimerTable=x25TimerTable, lapbCountResets=lapbCountResets, x25CCTManualConnect=x25CCTManualConnect, x25TTR20Limit=x25TTR20Limit, ipxRouting=ipxRouting, trapDestEntryIpAddr=trapDestEntryIpAddr, ipxInHdrErrors=ipxInHdrErrors, x25StatusTableEntry=x25StatusTableEntry, x25CCTOperAutoConRetryFlg=x25CCTOperAutoConRetryFlg, lapbCountRcvFrames=lapbCountRcvFrames, pathCostAutoValue=pathCostAutoValue, filteringDbAction=filteringDbAction, x25OperNextReset=x25OperNextReset, loPriQueueCurrentLength=loPriQueueCurrentLength, spanningMcastAddr=spanningMcastAddr, timeExceededLastTx=timeExceededLastTx, ieee8023SQETestErrors=ieee8023SQETestErrors, newPhysBlkSize=newPhysBlkSize, portNumber=portNumber, rmtLapbSTCountRcvFrames=rmtLapbSTCountRcvFrames, rmtLapbCTX25PortLineSpeed=rmtLapbCTX25PortLineSpeed, ipxSAPBinderyTable=ipxSAPBinderyTable, filteringDbMacAddress=filteringDbMacAddress, dcntIfNumber=dcntIfNumber, paramProbLastTx=paramProbLastTx, phySerIfT1clockSource=phySerIfT1clockSource, dcntIfDesgntdRtr=dcntIfDesgntdRtr, mlinkState=mlinkState, preconfSourceFilter=preconfSourceFilter, x25STRxDataPkts=x25STRxDataPkts, ipRSEntry=ipRSEntry, tftpRetryPeriod=tftpRetryPeriod, x25TTR23Limit=x25TTR23Limit, lapbModeT1=lapbModeT1, phySerIfPartnerAddress=phySerIfPartnerAddress, phySerIfNumber=phySerIfNumber, boothelperForwardingAddress=boothelperForwardingAddress, bridgeStatsEntry=bridgeStatsEntry, ipxSAPBinderyType=ipxSAPBinderyType, rmtLapbSTCountRcvOctets=rmtLapbSTCountRcvOctets, dcntAreaRITNextHop=dcntAreaRITNextHop, rmtLapbCTEntry=rmtLapbCTEntry, phySerIf=phySerIf, lapbNumber=lapbNumber, x25StatusIndex=x25StatusIndex, ipxReceivedDgms=ipxReceivedDgms, ieee8023InitializeMAC=ieee8023InitializeMAC, portPriorityMode=portPriorityMode, x25CSTNegWinSize=x25CSTNegWinSize)
mibBuilder.exportSymbols("RETIX-MIB", ieee8023MultipleCollisionFrames=ieee8023MultipleCollisionFrames, x25CSTPktSeqNumFlg=x25CSTPktSeqNumFlg, paramProbLastRx=paramProbLastRx, lapbRetryCount=lapbRetryCount, deletedLanFrames=deletedLanFrames, x25TTIndex=x25TTIndex, priorityTableAction=priorityTableAction, boot=boot, mlinkRcvSeq=mlinkRcvSeq, spatResetTimer=spatResetTimer, mlinkLostFrames=mlinkLostFrames, ieeeFormatFilter=ieeeFormatFilter, filteringDbType=filteringDbType, snmpAccessPolicyEntry=snmpAccessPolicyEntry, timeExceededLastRx=timeExceededLastRx, standbyRemote=standbyRemote, x25TTT21Timer=x25TTT21Timer, lapbLastResetTime=lapbLastResetTime, destUnreachLastRx=destUnreachLastRx, initiateBootpDll=initiateBootpDll, ieee8023inRangeLengthErrors=ieee8023inRangeLengthErrors, ipxAccessViolations=ipxAccessViolations, loadserverIpAddress=loadserverIpAddress, ipxSAPBinderySocket=ipxSAPBinderySocket, ieee8023DeferredTransmissions=ieee8023DeferredTransmissions, dcntIfRtrPriority=dcntIfRtrPriority, averageForwardedFrames=averageForwardedFrames, x25CCTTODToConnect=x25CCTTODToConnect, rmtLapbSTCountSentFrames=rmtLapbSTCountSentFrames, x25StatusWinSize=x25StatusWinSize, ipxSAPBinderyServerName=ipxSAPBinderyServerName, dcntIfIndex=dcntIfIndex, boothelperHopsLimit=boothelperHopsLimit, router=router, serialLoadPeriod=serialLoadPeriod, hiPriQueueCurrentLength=hiPriQueueCurrentLength, ipxIfIPXAddress=ipxIfIPXAddress, standbyLocal=standbyLocal, spatPriority=spatPriority, ieee8023BroadcastFramesReceivedOks=ieee8023BroadcastFramesReceivedOks, destUnreachLastTx=destUnreachLastTx, multicastDisposition=multicastDisposition, gwProtocol=gwProtocol, transmittedTotalDgms=transmittedTotalDgms, pathCostMode=pathCostMode, phySerIfIndex=phySerIfIndex, x25CSTLclCUGValue=x25CSTLclCUGValue, x25CSTNegPktSize=x25CSTNegPktSize, filterTableEntry=filterTableEntry, resetStats=resetStats, lapbManualT1value=lapbManualT1value, trapDestTable=trapDestTable, x25TTEntry=x25TTEntry, dcntRITDestNode=dcntRITDestNode, dcntInDiscards=dcntInDiscards, dcntMaxVisits=dcntMaxVisits, rmtLapbSTCountAborts=rmtLapbSTCountAborts, rmtLapbSTAutoT1value=rmtLapbSTAutoT1value, rmtLapbCTLinkAddr=rmtLapbCTLinkAddr, ipxRoutingTable=ipxRoutingTable, rmtLapbCTManualT1Value=rmtLapbCTManualT1Value, ieee8023PromiscuousReceiveStatus=ieee8023PromiscuousReceiveStatus, filterTable=filterTable, x25CCTCurrentTODControl=x25CCTCurrentTODControl, ieee8023MACAddress=ieee8023MACAddress, lan=lan, sourceQuenchLastRx=sourceQuenchLastRx, x25CSTCUGSub=x25CSTCUGSub, serialTxQueueSize=serialTxQueueSize, dcntIfTable=dcntIfTable, communityName=communityName, dcntRtngMsgTimerBCT1=dcntRtngMsgTimerBCT1, filteringDbTable=filteringDbTable, maxForwardedFrames=maxForwardedFrames, lanQueueSize=lanQueueSize, x25CCTCfgAutoConRetry=x25CCTCfgAutoConRetry, x25StatusSVCStatus=x25StatusSVCStatus, noRouteTotalDgms=noRouteTotalDgms, x25TTR22Limit=x25TTR22Limit, dcntAreaRITDestArea=dcntAreaRITDestArea, initStation=initStation, priorityTableEntryType=priorityTableEntryType, dcntAreaRITInterface=dcntAreaRITInterface, x25STSVCIndex=x25STSVCIndex, filterTableEntryType=filterTableEntryType, bridgeStatsIndex=bridgeStatsIndex, mlinkWindow=mlinkWindow, ieee8023Table=ieee8023Table, filteringDataBaseTable=filteringDataBaseTable, ieee8023ExcessiveCollisions=ieee8023ExcessiveCollisions, activeLocal=activeLocal, lapbCountCrcErrors=lapbCountCrcErrors, ieee8023NewMACAddressValue=ieee8023NewMACAddressValue, x25CST2WayLgclChanNum=x25CST2WayLgclChanNum, pathCostManualValue=pathCostManualValue, dcntInHdrErrors=dcntInHdrErrors, ieee8023OctetsReceivedOks=ieee8023OctetsReceivedOks, dcntAreaRITHops=dcntAreaRITHops, lapbAutoT1value=lapbAutoT1value, ieee8023outOfRangeLengthFields=ieee8023outOfRangeLengthFields, x25STTxClearReqPkts=x25STTxClearReqPkts, filterPage=filterPage, snmpAccessPolicyPage=snmpAccessPolicyPage, ipRSTable=ipRSTable, phySerIfInterfaceType=phySerIfInterfaceType, x25TTT20Timer=x25TTT20Timer, rmtLapbCTWindow=rmtLapbCTWindow, x25STTxResetReqPkts=x25STTxResetReqPkts, bootpRetryCount=bootpRetryCount, x25CSTRvrsChrgReq=x25CSTRvrsChrgReq, dcntRITHops=dcntRITHops, adaptiveMcastAddr=adaptiveMcastAddr, passWord=passWord, priorityTableEntry=priorityTableEntry, bootserverIpAddress=bootserverIpAddress, filterMatches=filterMatches, rmtLapbCTT3LinkIdleTimer=rmtLapbCTT3LinkIdleTimer, ipxIfDelay=ipxIfDelay, hiPriQueueUpperLimit=hiPriQueueUpperLimit, x25STRxRestartIndPkts=x25STRxRestartIndPkts, lapbCountSentFrames=lapbCountSentFrames, processorLoading=processorLoading, dcntOutDiscards=dcntOutDiscards, mlinkNumber=mlinkNumber, freeBufferCount=freeBufferCount, ipxIfNumber=ipxIfNumber, mlinkSendUpperEdge=mlinkSendUpperEdge, tftpRetryCount=tftpRetryCount, ipxRITHopCount=ipxRITHopCount, trapDestEntryType=trapDestEntryType, adaptiveRouting=adaptiveRouting, lapbCountSentOctets=lapbCountSentOctets, lapbLinkReset=lapbLinkReset, bridgeStatsTable=bridgeStatsTable, arAddressInfo=arAddressInfo, dcntRoutingTable=dcntRoutingTable, prioritySubTable=prioritySubTable, decnet=decnet, ieee8023TransmitStatus=ieee8023TransmitStatus, averageRejectedFrames=averageRejectedFrames, stationCountResets=stationCountResets, x25CCTCfgTODControl=x25CCTCfgTODControl, x25CSTDefaultPktSize=x25CSTDefaultPktSize, x25StatusPktSize=x25StatusPktSize, mlinkRcvUpperEdge=mlinkRcvUpperEdge, lanRejects=lanRejects, dcntReveivedDgms=dcntReveivedDgms, rmtLapbCTIndex=rmtLapbCTIndex, outDiscardsTotalDgms=outDiscardsTotalDgms, priorityTable=priorityTable, lapbTable=lapbTable, ipRSIndex=ipRSIndex, trapDestPage=trapDestPage, x25CCTTODToDisconnect=x25CCTTODToDisconnect, ieee8023MACSubLayerStatus=ieee8023MACSubLayerStatus, freeHeaderCount=freeHeaderCount, portPriorityManualValue=portPriorityManualValue, ipx=ipx, deleteAddressTimer=deleteAddressTimer, dcntRITNextHop=dcntRITNextHop)
| (octet_string, integer, object_identifier) = mibBuilder.importSymbols('ASN1', 'OctetString', 'Integer', 'ObjectIdentifier')
(named_values,) = mibBuilder.importSymbols('ASN1-ENUMERATION', 'NamedValues')
(constraints_intersection, constraints_union, value_range_constraint, single_value_constraint, value_size_constraint) = mibBuilder.importSymbols('ASN1-REFINEMENT', 'ConstraintsIntersection', 'ConstraintsUnion', 'ValueRangeConstraint', 'SingleValueConstraint', 'ValueSizeConstraint')
(mib_scalar, mib_table, mib_table_row, mib_table_column) = mibBuilder.importSymbols('RFC1212', 'MibScalar', 'MibTable', 'MibTableRow', 'MibTableColumn')
(notification_group, module_compliance) = mibBuilder.importSymbols('SNMPv2-CONF', 'NotificationGroup', 'ModuleCompliance')
(iso, bits, unsigned32, object_identity, mib_identifier, gauge32, notification_type, module_identity, mib_scalar, mib_table, mib_table_row, mib_table_column, enterprises, ip_address, counter32, counter64, integer32, time_ticks) = mibBuilder.importSymbols('SNMPv2-SMI', 'iso', 'Bits', 'Unsigned32', 'ObjectIdentity', 'MibIdentifier', 'Gauge32', 'NotificationType', 'ModuleIdentity', 'MibScalar', 'MibTable', 'MibTableRow', 'MibTableColumn', 'enterprises', 'IpAddress', 'Counter32', 'Counter64', 'Integer32', 'TimeTicks')
(textual_convention, display_string) = mibBuilder.importSymbols('SNMPv2-TC', 'TextualConvention', 'DisplayString')
retix = mib_identifier((1, 3, 6, 1, 4, 1, 72))
station = mib_identifier((1, 3, 6, 1, 4, 1, 72, 1))
lapb = mib_identifier((1, 3, 6, 1, 4, 1, 72, 2))
ieee8023 = mib_identifier((1, 3, 6, 1, 4, 1, 72, 3))
phy_ser_if = mib_identifier((1, 3, 6, 1, 4, 1, 72, 4))
mlink = mib_identifier((1, 3, 6, 1, 4, 1, 72, 5))
lan = mib_identifier((1, 3, 6, 1, 4, 1, 72, 6))
bridge = mib_identifier((1, 3, 6, 1, 4, 1, 72, 7))
product = mib_identifier((1, 3, 6, 1, 4, 1, 72, 8))
router = mib_identifier((1, 3, 6, 1, 4, 1, 72, 10))
boot = mib_identifier((1, 3, 6, 1, 4, 1, 72, 11))
boothelper = mib_identifier((1, 3, 6, 1, 4, 1, 72, 12))
remote = mib_identifier((1, 3, 6, 1, 4, 1, 72, 13))
ipx = mib_identifier((1, 3, 6, 1, 4, 1, 72, 13, 1))
decnet = mib_identifier((1, 3, 6, 1, 4, 1, 72, 13, 2))
rmt_lapb = mib_identifier((1, 3, 6, 1, 4, 1, 72, 13, 3))
x25 = mib_identifier((1, 3, 6, 1, 4, 1, 72, 13, 4))
station_time = mib_scalar((1, 3, 6, 1, 4, 1, 72, 1, 1), octet_string().subtype(subtypeSpec=value_size_constraint(13, 13)).setFixedLength(13)).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
stationTime.setStatus('mandatory')
station_count_resets = mib_scalar((1, 3, 6, 1, 4, 1, 72, 1, 2), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
stationCountResets.setStatus('mandatory')
free_buffer_count = mib_scalar((1, 3, 6, 1, 4, 1, 72, 1, 3), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
freeBufferCount.setStatus('mandatory')
free_header_count = mib_scalar((1, 3, 6, 1, 4, 1, 72, 1, 4), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
freeHeaderCount.setStatus('mandatory')
phys_blk_size = mib_scalar((1, 3, 6, 1, 4, 1, 72, 1, 5), integer32().subtype(subtypeSpec=value_range_constraint(300, 1600))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
physBlkSize.setStatus('mandatory')
new_phys_blk_size = mib_scalar((1, 3, 6, 1, 4, 1, 72, 1, 6), integer32().subtype(subtypeSpec=value_range_constraint(300, 1600))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
newPhysBlkSize.setStatus('mandatory')
reset_station = mib_scalar((1, 3, 6, 1, 4, 1, 72, 1, 7), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2))).clone(namedValues=named_values(('noAction', 1), ('resetStation', 2)))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
resetStation.setStatus('mandatory')
init_station = mib_scalar((1, 3, 6, 1, 4, 1, 72, 1, 8), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2))).clone(namedValues=named_values(('noAction', 1), ('initialize', 2)))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
initStation.setStatus('mandatory')
reset_stats = mib_scalar((1, 3, 6, 1, 4, 1, 72, 1, 9), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2))).clone(namedValues=named_values(('noAction', 1), ('resetStats', 2)))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
resetStats.setStatus('mandatory')
processor_loading = mib_scalar((1, 3, 6, 1, 4, 1, 72, 1, 10), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
processorLoading.setStatus('mandatory')
trap_destination_table = mib_identifier((1, 3, 6, 1, 4, 1, 72, 1, 11))
trap_dest_table = mib_table((1, 3, 6, 1, 4, 1, 72, 1, 11, 1))
if mibBuilder.loadTexts:
trapDestTable.setStatus('mandatory')
trap_dest_entry = mib_table_row((1, 3, 6, 1, 4, 1, 72, 1, 11, 1, 1)).setIndexNames((0, 'RETIX-MIB', 'trapDestEntryIpAddr'))
if mibBuilder.loadTexts:
trapDestEntry.setStatus('mandatory')
trap_dest_entry_ip_addr = mib_table_column((1, 3, 6, 1, 4, 1, 72, 1, 11, 1, 1, 1), ip_address()).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
trapDestEntryIpAddr.setStatus('mandatory')
trap_dest_entry_community_name = mib_table_column((1, 3, 6, 1, 4, 1, 72, 1, 11, 1, 1, 2), octet_string().subtype(subtypeSpec=value_size_constraint(0, 10))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
trapDestEntryCommunityName.setStatus('mandatory')
trap_dest_entry_type = mib_table_column((1, 3, 6, 1, 4, 1, 72, 1, 11, 1, 1, 3), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2))).clone(namedValues=named_values(('valid', 1), ('invalid', 2)))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
trapDestEntryType.setStatus('mandatory')
trap_dest_action = mib_scalar((1, 3, 6, 1, 4, 1, 72, 1, 11, 2), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2))).clone(namedValues=named_values(('noAction', 1), ('clearTable', 2)))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
trapDestAction.setStatus('mandatory')
trap_dest_page = mib_scalar((1, 3, 6, 1, 4, 1, 72, 1, 11, 3), octet_string().subtype(subtypeSpec=value_size_constraint(240, 240)).setFixedLength(240)).setMaxAccess('readonly')
if mibBuilder.loadTexts:
trapDestPage.setStatus('mandatory')
pass_word = mib_scalar((1, 3, 6, 1, 4, 1, 72, 1, 12), octet_string().subtype(subtypeSpec=value_size_constraint(0, 10))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
passWord.setStatus('mandatory')
snmp_access_policy_object = mib_identifier((1, 3, 6, 1, 4, 1, 72, 1, 13))
snmp_access_policy_table = mib_table((1, 3, 6, 1, 4, 1, 72, 1, 13, 1))
if mibBuilder.loadTexts:
snmpAccessPolicyTable.setStatus('mandatory')
snmp_access_policy_entry = mib_table_row((1, 3, 6, 1, 4, 1, 72, 1, 13, 1, 1)).setIndexNames((0, 'RETIX-MIB', 'accessPolicyIndex'))
if mibBuilder.loadTexts:
snmpAccessPolicyEntry.setStatus('mandatory')
access_policy_index = mib_table_column((1, 3, 6, 1, 4, 1, 72, 1, 13, 1, 1, 1), integer32()).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
accessPolicyIndex.setStatus('mandatory')
community_name = mib_table_column((1, 3, 6, 1, 4, 1, 72, 1, 13, 1, 1, 2), octet_string().subtype(subtypeSpec=value_size_constraint(0, 10))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
communityName.setStatus('mandatory')
access_mode = mib_table_column((1, 3, 6, 1, 4, 1, 72, 1, 13, 1, 1, 3), integer32().subtype(subtypeSpec=value_range_constraint(0, 3))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
accessMode.setStatus('mandatory')
snmp_access_policy_type = mib_table_column((1, 3, 6, 1, 4, 1, 72, 1, 13, 1, 1, 4), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2))).clone(namedValues=named_values(('valid', 1), ('invalid', 2)))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
snmpAccessPolicyType.setStatus('mandatory')
snmp_access_policy_action = mib_scalar((1, 3, 6, 1, 4, 1, 72, 1, 13, 2), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2))).clone(namedValues=named_values(('noAction', 1), ('clearTable', 2)))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
snmpAccessPolicyAction.setStatus('mandatory')
snmp_access_policy_page = mib_scalar((1, 3, 6, 1, 4, 1, 72, 1, 13, 3), octet_string().subtype(subtypeSpec=value_size_constraint(256, 256)).setFixedLength(256)).setMaxAccess('readonly')
if mibBuilder.loadTexts:
snmpAccessPolicyPage.setStatus('mandatory')
authentication_trap_status = mib_scalar((1, 3, 6, 1, 4, 1, 72, 1, 14), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2))).clone(namedValues=named_values(('enabled', 1), ('disabled', 2)))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
authenticationTrapStatus.setStatus('mandatory')
serial_tx_queue_size = mib_scalar((1, 3, 6, 1, 4, 1, 72, 1, 15), integer32().subtype(subtypeSpec=value_range_constraint(1, 127))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
serialTxQueueSize.setStatus('mandatory')
internal_queue_current_length = mib_scalar((1, 3, 6, 1, 4, 1, 72, 1, 16), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
internalQueueCurrentLength.setStatus('mandatory')
queue_upper_limit = mib_scalar((1, 3, 6, 1, 4, 1, 72, 1, 17), integer32()).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
queueUpperLimit.setStatus('mandatory')
lan_queue_size = mib_scalar((1, 3, 6, 1, 4, 1, 72, 1, 18), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
lanQueueSize.setStatus('mandatory')
lapb_number = mib_scalar((1, 3, 6, 1, 4, 1, 72, 2, 1), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
lapbNumber.setStatus('mandatory')
lapb_table = mib_table((1, 3, 6, 1, 4, 1, 72, 2, 2))
if mibBuilder.loadTexts:
lapbTable.setStatus('mandatory')
lapb_entry = mib_table_row((1, 3, 6, 1, 4, 1, 72, 2, 2, 1)).setIndexNames((0, 'RETIX-MIB', 'lapbIndex'))
if mibBuilder.loadTexts:
lapbEntry.setStatus('mandatory')
lapb_index = mib_table_column((1, 3, 6, 1, 4, 1, 72, 2, 2, 1, 1), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
lapbIndex.setStatus('mandatory')
lapb_mode_t1 = mib_table_column((1, 3, 6, 1, 4, 1, 72, 2, 2, 1, 2), integer32().subtype(subtypeSpec=value_range_constraint(0, 1))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
lapbModeT1.setStatus('mandatory')
lapb_auto_t1value = mib_table_column((1, 3, 6, 1, 4, 1, 72, 2, 2, 1, 3), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
lapbAutoT1value.setStatus('mandatory')
lapb_manual_t1value = mib_table_column((1, 3, 6, 1, 4, 1, 72, 2, 2, 1, 4), integer32().subtype(subtypeSpec=value_range_constraint(10, 5000))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
lapbManualT1value.setStatus('mandatory')
lapb_window = mib_table_column((1, 3, 6, 1, 4, 1, 72, 2, 2, 1, 5), integer32().subtype(subtypeSpec=value_range_constraint(7, 127))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
lapbWindow.setStatus('mandatory')
lapb_polarity = mib_table_column((1, 3, 6, 1, 4, 1, 72, 2, 2, 1, 6), integer32().subtype(subtypeSpec=value_range_constraint(0, 1))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
lapbPolarity.setStatus('mandatory')
lapb_count_resets = mib_table_column((1, 3, 6, 1, 4, 1, 72, 2, 2, 1, 7), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
lapbCountResets.setStatus('mandatory')
lapb_count_sent_frames = mib_table_column((1, 3, 6, 1, 4, 1, 72, 2, 2, 1, 8), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
lapbCountSentFrames.setStatus('mandatory')
lapb_count_rcv_frames = mib_table_column((1, 3, 6, 1, 4, 1, 72, 2, 2, 1, 9), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
lapbCountRcvFrames.setStatus('mandatory')
lapb_count_sent_octets = mib_table_column((1, 3, 6, 1, 4, 1, 72, 2, 2, 1, 10), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
lapbCountSentOctets.setStatus('mandatory')
lapb_count_rcv_octets = mib_table_column((1, 3, 6, 1, 4, 1, 72, 2, 2, 1, 11), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
lapbCountRcvOctets.setStatus('mandatory')
lapb_count_aborts = mib_table_column((1, 3, 6, 1, 4, 1, 72, 2, 2, 1, 12), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
lapbCountAborts.setStatus('mandatory')
lapb_count_crc_errors = mib_table_column((1, 3, 6, 1, 4, 1, 72, 2, 2, 1, 13), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
lapbCountCrcErrors.setStatus('mandatory')
lapb_state = mib_table_column((1, 3, 6, 1, 4, 1, 72, 2, 2, 1, 14), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
lapbState.setStatus('mandatory')
lapb_last_reset_time = mib_table_column((1, 3, 6, 1, 4, 1, 72, 2, 2, 1, 15), octet_string().subtype(subtypeSpec=value_size_constraint(13, 13)).setFixedLength(13)).setMaxAccess('readonly')
if mibBuilder.loadTexts:
lapbLastResetTime.setStatus('mandatory')
lapb_last_reset_reason = mib_table_column((1, 3, 6, 1, 4, 1, 72, 2, 2, 1, 16), integer32().subtype(subtypeSpec=value_range_constraint(0, 8))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
lapbLastResetReason.setStatus('mandatory')
lapb_link_reset = mib_table_column((1, 3, 6, 1, 4, 1, 72, 2, 2, 1, 17), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2))).clone(namedValues=named_values(('noAction', 1), ('reset', 2)))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
lapbLinkReset.setStatus('mandatory')
lapb_retry_count = mib_scalar((1, 3, 6, 1, 4, 1, 72, 2, 3), integer32()).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
lapbRetryCount.setStatus('mandatory')
ieee8023_number = mib_scalar((1, 3, 6, 1, 4, 1, 72, 3, 1), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ieee8023Number.setStatus('mandatory')
ieee8023_table = mib_table((1, 3, 6, 1, 4, 1, 72, 3, 2))
if mibBuilder.loadTexts:
ieee8023Table.setStatus('mandatory')
ieee8023_entry = mib_table_row((1, 3, 6, 1, 4, 1, 72, 3, 2, 1)).setIndexNames((0, 'RETIX-MIB', 'ieee8023Index'))
if mibBuilder.loadTexts:
ieee8023Entry.setStatus('mandatory')
ieee8023_index = mib_table_column((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 1), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ieee8023Index.setStatus('mandatory')
ieee8023_frames_transmitted_oks = mib_table_column((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 2), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ieee8023FramesTransmittedOks.setStatus('mandatory')
ieee8023_single_collision_frames = mib_table_column((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 3), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ieee8023SingleCollisionFrames.setStatus('mandatory')
ieee8023_multiple_collision_frames = mib_table_column((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 4), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ieee8023MultipleCollisionFrames.setStatus('mandatory')
ieee8023_octets_transmitted_oks = mib_table_column((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 5), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ieee8023OctetsTransmittedOks.setStatus('mandatory')
ieee8023_deferred_transmissions = mib_table_column((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 6), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ieee8023DeferredTransmissions.setStatus('mandatory')
ieee8023_multicast_frames_transmitted_oks = mib_table_column((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 7), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ieee8023MulticastFramesTransmittedOks.setStatus('mandatory')
ieee8023_broadcast_frames_transmitted_oks = mib_table_column((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 8), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ieee8023BroadcastFramesTransmittedOks.setStatus('mandatory')
ieee8023_late_collisions = mib_table_column((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 9), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ieee8023LateCollisions.setStatus('mandatory')
ieee8023_excessive_collisions = mib_table_column((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 10), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ieee8023ExcessiveCollisions.setStatus('mandatory')
ieee8023_internal_mac_transmit_errors = mib_table_column((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 11), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ieee8023InternalMACTransmitErrors.setStatus('mandatory')
ieee8023_carrier_sense_errors = mib_table_column((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 12), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ieee8023CarrierSenseErrors.setStatus('mandatory')
ieee8023_excessive_deferrals = mib_table_column((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 13), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ieee8023ExcessiveDeferrals.setStatus('mandatory')
ieee8023_frames_received_oks = mib_table_column((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 14), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ieee8023FramesReceivedOks.setStatus('mandatory')
ieee8023_octets_received_oks = mib_table_column((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 15), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ieee8023OctetsReceivedOks.setStatus('mandatory')
ieee8023_multicast_frames_received_oks = mib_table_column((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 16), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ieee8023MulticastFramesReceivedOks.setStatus('mandatory')
ieee8023_broadcast_frames_received_oks = mib_table_column((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 17), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ieee8023BroadcastFramesReceivedOks.setStatus('mandatory')
ieee8023_frame_too_longs = mib_table_column((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 18), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ieee8023FrameTooLongs.setStatus('mandatory')
ieee8023_alignment_errors = mib_table_column((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 19), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ieee8023AlignmentErrors.setStatus('mandatory')
ieee8023_fcs_errors = mib_table_column((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 20), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ieee8023FCSErrors.setStatus('mandatory')
ieee8023in_range_length_errors = mib_table_column((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 21), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ieee8023inRangeLengthErrors.setStatus('mandatory')
ieee8023out_of_range_length_fields = mib_table_column((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 22), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ieee8023outOfRangeLengthFields.setStatus('mandatory')
ieee8023_internal_mac_receive_errors = mib_table_column((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 23), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ieee8023InternalMACReceiveErrors.setStatus('mandatory')
ieee8023_initialize_mac = mib_table_column((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 24), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1))).clone(namedValues=named_values(('initialize', 1)))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
ieee8023InitializeMAC.setStatus('mandatory')
ieee8023_promiscuous_receive_status = mib_table_column((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 25), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1))).clone(namedValues=named_values(('enabled', 1)))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
ieee8023PromiscuousReceiveStatus.setStatus('mandatory')
ieee8023_mac_sub_layer_status = mib_table_column((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 26), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1))).clone(namedValues=named_values(('enabled', 1)))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
ieee8023MACSubLayerStatus.setStatus('mandatory')
ieee8023_transmit_status = mib_table_column((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 27), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2))).clone(namedValues=named_values(('enabled', 1), ('disabled', 2)))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
ieee8023TransmitStatus.setStatus('mandatory')
ieee8023_multicast_receive_status = mib_table_column((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 28), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1))).clone(namedValues=named_values(('enabled', 1)))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
ieee8023MulticastReceiveStatus.setStatus('mandatory')
ieee8023_mac_address = mib_table_column((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 29), octet_string().subtype(subtypeSpec=value_size_constraint(6, 6)).setFixedLength(6)).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ieee8023MACAddress.setStatus('mandatory')
ieee8023_sqe_test_errors = mib_table_column((1, 3, 6, 1, 4, 1, 72, 3, 2, 1, 30), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ieee8023SQETestErrors.setStatus('mandatory')
ieee8023_new_mac_address = mib_table((1, 3, 6, 1, 4, 1, 72, 3, 3))
if mibBuilder.loadTexts:
ieee8023NewMACAddress.setStatus('mandatory')
ieee8023_new_mac_address_entry = mib_table_row((1, 3, 6, 1, 4, 1, 72, 3, 3, 1)).setIndexNames((0, 'RETIX-MIB', 'ieee8023NewMACAddressIndex'))
if mibBuilder.loadTexts:
ieee8023NewMACAddressEntry.setStatus('mandatory')
ieee8023_new_mac_address_index = mib_table_column((1, 3, 6, 1, 4, 1, 72, 3, 3, 1, 1), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ieee8023NewMACAddressIndex.setStatus('mandatory')
ieee8023_new_mac_address_value = mib_table_column((1, 3, 6, 1, 4, 1, 72, 3, 3, 1, 2), octet_string().subtype(subtypeSpec=value_size_constraint(6, 6)).setFixedLength(6)).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
ieee8023NewMACAddressValue.setStatus('mandatory')
phy_ser_if_number = mib_scalar((1, 3, 6, 1, 4, 1, 72, 4, 1), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
phySerIfNumber.setStatus('mandatory')
phy_ser_if_table = mib_table((1, 3, 6, 1, 4, 1, 72, 4, 2))
if mibBuilder.loadTexts:
phySerIfTable.setStatus('mandatory')
phy_ser_if_entry = mib_table_row((1, 3, 6, 1, 4, 1, 72, 4, 2, 1)).setIndexNames((0, 'RETIX-MIB', 'phySerIfIndex'))
if mibBuilder.loadTexts:
phySerIfEntry.setStatus('mandatory')
phy_ser_if_index = mib_table_column((1, 3, 6, 1, 4, 1, 72, 4, 2, 1, 1), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
phySerIfIndex.setStatus('mandatory')
phy_ser_if_interface_type = mib_table_column((1, 3, 6, 1, 4, 1, 72, 4, 2, 1, 2), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2, 3, 4, 5, 6, 7, 8))).clone(namedValues=named_values(('x21dte', 1), ('x21dce', 2), ('rs449', 3), ('g703', 4), ('v35', 5), ('v35btb', 6), ('rs232', 7), ('t1', 8)))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
phySerIfInterfaceType.setStatus('mandatory')
phy_ser_if_measured_speed = mib_table_column((1, 3, 6, 1, 4, 1, 72, 4, 2, 1, 3), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
phySerIfMeasuredSpeed.setStatus('mandatory')
phy_ser_if_is_speedsettable = mib_table_column((1, 3, 6, 1, 4, 1, 72, 4, 2, 1, 4), integer32().subtype(subtypeSpec=value_range_constraint(0, 1))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
phySerIfIsSpeedsettable.setStatus('mandatory')
phy_ser_if_port_speed = mib_table_column((1, 3, 6, 1, 4, 1, 72, 4, 2, 1, 5), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1200, 2400, 4800, 9600, 19200, 24000, 32000, 48000, 64000, 256000, 512000, 1024000, 2048000))).clone(namedValues=named_values(('b1200', 1200), ('b2400', 2400), ('b4800', 4800), ('b9600', 9600), ('b19200', 19200), ('b24000', 24000), ('b32000', 32000), ('b48000', 48000), ('b64000', 64000), ('b256000', 256000), ('b512000', 512000), ('b1024000', 1024000), ('b2048000', 2048000)))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
phySerIfPortSpeed.setStatus('mandatory')
phy_ser_if_transit_delay = mib_table_column((1, 3, 6, 1, 4, 1, 72, 4, 2, 1, 6), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
phySerIfTransitDelay.setStatus('mandatory')
phy_ser_if_t1clock_source = mib_table_column((1, 3, 6, 1, 4, 1, 72, 4, 2, 1, 7), integer32()).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
phySerIfT1clockSource.setStatus('mandatory')
phy_ser_if_t1_slot_lvalue = mib_table_column((1, 3, 6, 1, 4, 1, 72, 4, 2, 1, 8), integer32().subtype(subtypeSpec=value_range_constraint(1, 24))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
phySerIfT1SlotLvalue.setStatus('mandatory')
phy_ser_if_t1_slot_hvalue = mib_table_column((1, 3, 6, 1, 4, 1, 72, 4, 2, 1, 9), integer32().subtype(subtypeSpec=value_range_constraint(1, 24))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
phySerIfT1SlotHvalue.setStatus('mandatory')
phy_ser_if_t1d_rate_per_chan = mib_table_column((1, 3, 6, 1, 4, 1, 72, 4, 2, 1, 10), integer32().subtype(subtypeSpec=value_range_constraint(0, 1))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
phySerIfT1dRatePerChan.setStatus('mandatory')
phy_ser_if_t1frame_and_code = mib_table_column((1, 3, 6, 1, 4, 1, 72, 4, 2, 1, 11), integer32().subtype(subtypeSpec=value_range_constraint(0, 3))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
phySerIfT1frameAndCode.setStatus('mandatory')
phy_ser_if_partner_address = mib_table_column((1, 3, 6, 1, 4, 1, 72, 4, 2, 1, 12), octet_string().subtype(subtypeSpec=value_size_constraint(0, 6))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
phySerIfPartnerAddress.setStatus('mandatory')
mlink_number = mib_scalar((1, 3, 6, 1, 4, 1, 72, 5, 1), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
mlinkNumber.setStatus('mandatory')
mlink_table = mib_table((1, 3, 6, 1, 4, 1, 72, 5, 2))
if mibBuilder.loadTexts:
mlinkTable.setStatus('mandatory')
mlink_entry = mib_table_row((1, 3, 6, 1, 4, 1, 72, 5, 2, 1)).setIndexNames((0, 'RETIX-MIB', 'mlinkIndex'))
if mibBuilder.loadTexts:
mlinkEntry.setStatus('mandatory')
mlink_index = mib_table_column((1, 3, 6, 1, 4, 1, 72, 5, 2, 1, 1), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
mlinkIndex.setStatus('mandatory')
mlink_state = mib_table_column((1, 3, 6, 1, 4, 1, 72, 5, 2, 1, 2), integer32().subtype(subtypeSpec=value_range_constraint(0, 3))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
mlinkState.setStatus('mandatory')
mlink_send_seq = mib_table_column((1, 3, 6, 1, 4, 1, 72, 5, 2, 1, 3), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
mlinkSendSeq.setStatus('mandatory')
mlink_rcv_seq = mib_table_column((1, 3, 6, 1, 4, 1, 72, 5, 2, 1, 4), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
mlinkRcvSeq.setStatus('mandatory')
mlink_send_upper_edge = mib_table_column((1, 3, 6, 1, 4, 1, 72, 5, 2, 1, 5), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
mlinkSendUpperEdge.setStatus('mandatory')
mlink_rcv_upper_edge = mib_table_column((1, 3, 6, 1, 4, 1, 72, 5, 2, 1, 6), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
mlinkRcvUpperEdge.setStatus('mandatory')
mlink_lost_frames = mib_table_column((1, 3, 6, 1, 4, 1, 72, 5, 2, 1, 7), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
mlinkLostFrames.setStatus('mandatory')
deleted_mlink_frames = mib_table_column((1, 3, 6, 1, 4, 1, 72, 5, 2, 1, 8), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
deletedMlinkFrames.setStatus('mandatory')
express_queue_current_length = mib_table_column((1, 3, 6, 1, 4, 1, 72, 5, 2, 1, 9), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
expressQueueCurrentLength.setStatus('mandatory')
express_queue_upper_limit = mib_table_column((1, 3, 6, 1, 4, 1, 72, 5, 2, 1, 10), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
expressQueueUpperLimit.setStatus('mandatory')
hi_pri_queue_current_length = mib_table_column((1, 3, 6, 1, 4, 1, 72, 5, 2, 1, 11), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
hiPriQueueCurrentLength.setStatus('mandatory')
hi_pri_queue_upper_limit = mib_table_column((1, 3, 6, 1, 4, 1, 72, 5, 2, 1, 12), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
hiPriQueueUpperLimit.setStatus('mandatory')
lo_pri_queue_current_length = mib_table_column((1, 3, 6, 1, 4, 1, 72, 5, 2, 1, 13), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
loPriQueueCurrentLength.setStatus('mandatory')
lo_pri_queue_upper_limit = mib_table_column((1, 3, 6, 1, 4, 1, 72, 5, 2, 1, 14), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
loPriQueueUpperLimit.setStatus('mandatory')
mlink_window = mib_scalar((1, 3, 6, 1, 4, 1, 72, 5, 3), integer32()).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
mlinkWindow.setStatus('mandatory')
mlink_rx_timeout = mib_scalar((1, 3, 6, 1, 4, 1, 72, 5, 4), integer32()).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
mlinkRxTimeout.setStatus('mandatory')
lan_interface_type = mib_scalar((1, 3, 6, 1, 4, 1, 72, 6, 1), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2, 3))).clone(namedValues=named_values(('tenBase5', 1), ('oneBase5', 2), ('tenBase2', 3)))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
lanInterfaceType.setStatus('mandatory')
port_number = mib_scalar((1, 3, 6, 1, 4, 1, 72, 7, 1), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
portNumber.setStatus('mandatory')
bridge_stats_table = mib_table((1, 3, 6, 1, 4, 1, 72, 7, 2))
if mibBuilder.loadTexts:
bridgeStatsTable.setStatus('mandatory')
bridge_stats_entry = mib_table_row((1, 3, 6, 1, 4, 1, 72, 7, 2, 1)).setIndexNames((0, 'RETIX-MIB', 'bridgeStatsIndex'))
if mibBuilder.loadTexts:
bridgeStatsEntry.setStatus('mandatory')
bridge_stats_index = mib_table_column((1, 3, 6, 1, 4, 1, 72, 7, 2, 1, 1), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
bridgeStatsIndex.setStatus('mandatory')
average_forwarded_frames = mib_table_column((1, 3, 6, 1, 4, 1, 72, 7, 2, 1, 2), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
averageForwardedFrames.setStatus('mandatory')
max_forwarded_frames = mib_table_column((1, 3, 6, 1, 4, 1, 72, 7, 2, 1, 3), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
maxForwardedFrames.setStatus('mandatory')
average_rejected_frames = mib_table_column((1, 3, 6, 1, 4, 1, 72, 7, 2, 1, 4), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
averageRejectedFrames.setStatus('mandatory')
max_rejected_frames = mib_table_column((1, 3, 6, 1, 4, 1, 72, 7, 2, 1, 5), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
maxRejectedFrames.setStatus('mandatory')
lan_accepts = mib_table_column((1, 3, 6, 1, 4, 1, 72, 7, 2, 1, 6), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
lanAccepts.setStatus('mandatory')
lan_rejects = mib_table_column((1, 3, 6, 1, 4, 1, 72, 7, 2, 1, 7), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
lanRejects.setStatus('mandatory')
deleted_lan_frames = mib_table_column((1, 3, 6, 1, 4, 1, 72, 7, 2, 1, 8), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
deletedLanFrames.setStatus('mandatory')
stp_table = mib_table((1, 3, 6, 1, 4, 1, 72, 7, 3))
if mibBuilder.loadTexts:
stpTable.setStatus('mandatory')
stp_entry = mib_table_row((1, 3, 6, 1, 4, 1, 72, 7, 3, 1)).setIndexNames((0, 'RETIX-MIB', 'stpIndex'))
if mibBuilder.loadTexts:
stpEntry.setStatus('mandatory')
stp_index = mib_table_column((1, 3, 6, 1, 4, 1, 72, 7, 3, 1, 1), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
stpIndex.setStatus('mandatory')
path_cost_mode = mib_table_column((1, 3, 6, 1, 4, 1, 72, 7, 3, 1, 2), integer32().subtype(subtypeSpec=value_range_constraint(0, 1))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
pathCostMode.setStatus('mandatory')
path_cost_auto_value = mib_table_column((1, 3, 6, 1, 4, 1, 72, 7, 3, 1, 3), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
pathCostAutoValue.setStatus('mandatory')
path_cost_manual_value = mib_table_column((1, 3, 6, 1, 4, 1, 72, 7, 3, 1, 4), integer32().subtype(subtypeSpec=value_range_constraint(0, 65535))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
pathCostManualValue.setStatus('mandatory')
port_spat_state = mib_table_column((1, 3, 6, 1, 4, 1, 72, 7, 3, 1, 5), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
portSpatState.setStatus('mandatory')
port_priority_mode = mib_table_column((1, 3, 6, 1, 4, 1, 72, 7, 3, 1, 6), integer32().subtype(subtypeSpec=value_range_constraint(0, 1))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
portPriorityMode.setStatus('mandatory')
port_priority_auto_value = mib_table_column((1, 3, 6, 1, 4, 1, 72, 7, 3, 1, 7), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
portPriorityAutoValue.setStatus('mandatory')
port_priority_manual_value = mib_table_column((1, 3, 6, 1, 4, 1, 72, 7, 3, 1, 8), integer32().subtype(subtypeSpec=value_range_constraint(0, 255))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
portPriorityManualValue.setStatus('mandatory')
spanning_tree = mib_scalar((1, 3, 6, 1, 4, 1, 72, 7, 4), integer32().subtype(subtypeSpec=value_range_constraint(0, 1))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
spanningTree.setStatus('mandatory')
spat_priority = mib_scalar((1, 3, 6, 1, 4, 1, 72, 7, 5), integer32().subtype(subtypeSpec=value_range_constraint(1, 65535))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
spatPriority.setStatus('mandatory')
spat_hello_timer = mib_scalar((1, 3, 6, 1, 4, 1, 72, 7, 6), integer32().subtype(subtypeSpec=value_range_constraint(1, 10))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
spatHelloTimer.setStatus('mandatory')
spat_reset_timer = mib_scalar((1, 3, 6, 1, 4, 1, 72, 7, 7), integer32().subtype(subtypeSpec=value_range_constraint(1, 1800))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
spatResetTimer.setStatus('mandatory')
spat_version = mib_scalar((1, 3, 6, 1, 4, 1, 72, 7, 8), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(3, 8))).clone(namedValues=named_values(('revisionC', 3), ('revision8', 8)))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
spatVersion.setStatus('mandatory')
spanning_mcast_addr = mib_scalar((1, 3, 6, 1, 4, 1, 72, 7, 9), octet_string().subtype(subtypeSpec=value_size_constraint(6, 6)).setFixedLength(6)).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
spanningMcastAddr.setStatus('mandatory')
operating_mode = mib_scalar((1, 3, 6, 1, 4, 1, 72, 7, 10), integer32().subtype(subtypeSpec=value_range_constraint(0, 1))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
operatingMode.setStatus('mandatory')
preconf_source_filter = mib_scalar((1, 3, 6, 1, 4, 1, 72, 7, 11), integer32().subtype(subtypeSpec=value_range_constraint(0, 1))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
preconfSourceFilter.setStatus('mandatory')
type_filter = mib_scalar((1, 3, 6, 1, 4, 1, 72, 7, 12), integer32().subtype(subtypeSpec=value_range_constraint(0, 1))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
typeFilter.setStatus('mandatory')
type_prioritisation = mib_scalar((1, 3, 6, 1, 4, 1, 72, 7, 13), integer32().subtype(subtypeSpec=value_range_constraint(0, 1))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
typePrioritisation.setStatus('mandatory')
dynamic_learning_in_lm = mib_scalar((1, 3, 6, 1, 4, 1, 72, 7, 14), integer32().subtype(subtypeSpec=value_range_constraint(0, 1))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
dynamicLearningInLM.setStatus('mandatory')
forget_address_timer = mib_scalar((1, 3, 6, 1, 4, 1, 72, 7, 15), integer32().subtype(subtypeSpec=value_range_constraint(24, 1000))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
forgetAddressTimer.setStatus('mandatory')
delete_address_timer = mib_scalar((1, 3, 6, 1, 4, 1, 72, 7, 16), integer32().subtype(subtypeSpec=value_range_constraint(1, 20000))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
deleteAddressTimer.setStatus('mandatory')
multicast_disposition = mib_scalar((1, 3, 6, 1, 4, 1, 72, 7, 17), integer32().subtype(subtypeSpec=value_range_constraint(0, 1))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
multicastDisposition.setStatus('mandatory')
filter_matches = mib_scalar((1, 3, 6, 1, 4, 1, 72, 7, 18), integer32().subtype(subtypeSpec=value_range_constraint(0, 1))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
filterMatches.setStatus('mandatory')
ieee_format_filter = mib_scalar((1, 3, 6, 1, 4, 1, 72, 7, 19), integer32().subtype(subtypeSpec=value_range_constraint(0, 1))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
ieeeFormatFilter.setStatus('mandatory')
priority_matches = mib_scalar((1, 3, 6, 1, 4, 1, 72, 7, 20), integer32().subtype(subtypeSpec=value_range_constraint(0, 1))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
priorityMatches.setStatus('mandatory')
ieee_format_priority = mib_scalar((1, 3, 6, 1, 4, 1, 72, 7, 21), integer32().subtype(subtypeSpec=value_range_constraint(0, 1))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
ieeeFormatPriority.setStatus('mandatory')
average_period = mib_scalar((1, 3, 6, 1, 4, 1, 72, 7, 22), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
averagePeriod.setStatus('mandatory')
triangulation = mib_scalar((1, 3, 6, 1, 4, 1, 72, 7, 23), integer32().subtype(subtypeSpec=value_range_constraint(0, 1))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
triangulation.setStatus('mandatory')
adaptive_routing = mib_scalar((1, 3, 6, 1, 4, 1, 72, 7, 24), integer32().subtype(subtypeSpec=value_range_constraint(0, 1))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
adaptiveRouting.setStatus('mandatory')
adaptive_mcast_addr = mib_scalar((1, 3, 6, 1, 4, 1, 72, 7, 25), octet_string().subtype(subtypeSpec=value_size_constraint(6, 6)).setFixedLength(6)).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
adaptiveMcastAddr.setStatus('mandatory')
ar_address_info = mib_identifier((1, 3, 6, 1, 4, 1, 72, 7, 26))
standby_remote = mib_scalar((1, 3, 6, 1, 4, 1, 72, 7, 26, 1), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
standbyRemote.setStatus('mandatory')
standby_local = mib_scalar((1, 3, 6, 1, 4, 1, 72, 7, 26, 2), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
standbyLocal.setStatus('mandatory')
active_remote = mib_scalar((1, 3, 6, 1, 4, 1, 72, 7, 26, 3), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
activeRemote.setStatus('mandatory')
active_local = mib_scalar((1, 3, 6, 1, 4, 1, 72, 7, 26, 4), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
activeLocal.setStatus('mandatory')
max_serial_loading = mib_scalar((1, 3, 6, 1, 4, 1, 72, 7, 27), integer32()).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
maxSerialLoading.setStatus('mandatory')
serial_load_period = mib_scalar((1, 3, 6, 1, 4, 1, 72, 7, 28), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(10, 20, 30, 40, 50, 60))).clone(namedValues=named_values(('ten', 10), ('twenty', 20), ('thirty', 30), ('forty', 40), ('fifty', 50), ('sixty', 60)))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
serialLoadPeriod.setStatus('mandatory')
serial_loading = mib_scalar((1, 3, 6, 1, 4, 1, 72, 7, 29), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
serialLoading.setStatus('mandatory')
filtering_data_base_table = mib_identifier((1, 3, 6, 1, 4, 1, 72, 7, 30))
filtering_db_table = mib_table((1, 3, 6, 1, 4, 1, 72, 7, 30, 1))
if mibBuilder.loadTexts:
filteringDbTable.setStatus('mandatory')
filtering_db_entry = mib_table_row((1, 3, 6, 1, 4, 1, 72, 7, 30, 1, 1)).setIndexNames((0, 'RETIX-MIB', 'filteringDbMacAddress'))
if mibBuilder.loadTexts:
filteringDbEntry.setStatus('mandatory')
filtering_db_mac_address = mib_table_column((1, 3, 6, 1, 4, 1, 72, 7, 30, 1, 1, 1), octet_string().subtype(subtypeSpec=value_size_constraint(6, 6)).setFixedLength(6)).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
filteringDbMacAddress.setStatus('mandatory')
filtering_db_disposition = mib_table_column((1, 3, 6, 1, 4, 1, 72, 7, 30, 1, 1, 2), integer32()).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
filteringDbDisposition.setStatus('mandatory')
filtering_db_status = mib_table_column((1, 3, 6, 1, 4, 1, 72, 7, 30, 1, 1, 3), integer32()).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
filteringDbStatus.setStatus('mandatory')
filtering_db_type = mib_table_column((1, 3, 6, 1, 4, 1, 72, 7, 30, 1, 1, 4), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2))).clone(namedValues=named_values(('valid', 1), ('invalid', 2)))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
filteringDbType.setStatus('mandatory')
filtering_db_action = mib_scalar((1, 3, 6, 1, 4, 1, 72, 7, 30, 2), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2))).clone(namedValues=named_values(('noAction', 1), ('clearTable', 2)))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
filteringDbAction.setStatus('mandatory')
priority_table = mib_identifier((1, 3, 6, 1, 4, 1, 72, 7, 31))
priority_sub_table = mib_table((1, 3, 6, 1, 4, 1, 72, 7, 31, 1))
if mibBuilder.loadTexts:
prioritySubTable.setStatus('mandatory')
priority_table_entry = mib_table_row((1, 3, 6, 1, 4, 1, 72, 7, 31, 1, 1)).setIndexNames((0, 'RETIX-MIB', 'priorityTableEntryValue'))
if mibBuilder.loadTexts:
priorityTableEntry.setStatus('mandatory')
priority_table_entry_value = mib_table_column((1, 3, 6, 1, 4, 1, 72, 7, 31, 1, 1, 1), integer32()).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
priorityTableEntryValue.setStatus('mandatory')
priority_table_entry_type = mib_table_column((1, 3, 6, 1, 4, 1, 72, 7, 31, 1, 1, 2), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2))).clone(namedValues=named_values(('valid', 1), ('invalid', 2)))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
priorityTableEntryType.setStatus('mandatory')
priority_table_action = mib_scalar((1, 3, 6, 1, 4, 1, 72, 7, 31, 2), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2))).clone(namedValues=named_values(('noAction', 1), ('clearTable', 2)))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
priorityTableAction.setStatus('mandatory')
priority_page = mib_scalar((1, 3, 6, 1, 4, 1, 72, 7, 31, 3), octet_string().subtype(subtypeSpec=value_size_constraint(16, 16)).setFixedLength(16)).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
priorityPage.setStatus('optional')
filter_table = mib_identifier((1, 3, 6, 1, 4, 1, 72, 7, 32))
filter_sub_table = mib_table((1, 3, 6, 1, 4, 1, 72, 7, 32, 1))
if mibBuilder.loadTexts:
filterSubTable.setStatus('mandatory')
filter_table_entry = mib_table_row((1, 3, 6, 1, 4, 1, 72, 7, 32, 1, 1)).setIndexNames((0, 'RETIX-MIB', 'filterTableEntryValue'))
if mibBuilder.loadTexts:
filterTableEntry.setStatus('mandatory')
filter_table_entry_value = mib_table_column((1, 3, 6, 1, 4, 1, 72, 7, 32, 1, 1, 1), integer32()).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
filterTableEntryValue.setStatus('mandatory')
filter_table_entry_type = mib_table_column((1, 3, 6, 1, 4, 1, 72, 7, 32, 1, 1, 2), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2))).clone(namedValues=named_values(('valid', 1), ('invalid', 2)))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
filterTableEntryType.setStatus('mandatory')
filter_table_action = mib_scalar((1, 3, 6, 1, 4, 1, 72, 7, 32, 2), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2))).clone(namedValues=named_values(('noAction', 1), ('clearTable', 2)))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
filterTableAction.setStatus('mandatory')
filter_page = mib_scalar((1, 3, 6, 1, 4, 1, 72, 7, 32, 3), octet_string().subtype(subtypeSpec=value_size_constraint(16, 16)).setFixedLength(16)).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
filterPage.setStatus('mandatory')
ip_rs_table = mib_table((1, 3, 6, 1, 4, 1, 72, 10, 1))
if mibBuilder.loadTexts:
ipRSTable.setStatus('mandatory')
ip_rs_entry = mib_table_row((1, 3, 6, 1, 4, 1, 72, 10, 1, 1)).setIndexNames((0, 'RETIX-MIB', 'ipRSIndex'))
if mibBuilder.loadTexts:
ipRSEntry.setStatus('mandatory')
ip_rs_index = mib_table_column((1, 3, 6, 1, 4, 1, 72, 10, 1, 1, 1), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ipRSIndex.setStatus('mandatory')
gw_protocol = mib_table_column((1, 3, 6, 1, 4, 1, 72, 10, 1, 1, 2), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 8))).clone(namedValues=named_values(('none', 1), ('rip', 8)))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
gwProtocol.setStatus('mandatory')
if_status = mib_table_column((1, 3, 6, 1, 4, 1, 72, 10, 1, 1, 3), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ifStatus.setStatus('mandatory')
received_total_dgms = mib_table_column((1, 3, 6, 1, 4, 1, 72, 10, 1, 1, 4), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
receivedTotalDgms.setStatus('mandatory')
transmitted_total_dgms = mib_table_column((1, 3, 6, 1, 4, 1, 72, 10, 1, 1, 5), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
transmittedTotalDgms.setStatus('mandatory')
out_discards_total_dgms = mib_table_column((1, 3, 6, 1, 4, 1, 72, 10, 1, 1, 6), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
outDiscardsTotalDgms.setStatus('mandatory')
no_route_total_dgms = mib_table_column((1, 3, 6, 1, 4, 1, 72, 10, 1, 1, 7), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
noRouteTotalDgms.setStatus('mandatory')
icmp_rs_table = mib_identifier((1, 3, 6, 1, 4, 1, 72, 10, 2))
dest_unreach_last_rx = mib_scalar((1, 3, 6, 1, 4, 1, 72, 10, 2, 1), octet_string().subtype(subtypeSpec=value_size_constraint(13, 13)).setFixedLength(13)).setMaxAccess('readonly')
if mibBuilder.loadTexts:
destUnreachLastRx.setStatus('mandatory')
dest_unreach_last_tx = mib_scalar((1, 3, 6, 1, 4, 1, 72, 10, 2, 2), octet_string().subtype(subtypeSpec=value_size_constraint(13, 13)).setFixedLength(13)).setMaxAccess('readonly')
if mibBuilder.loadTexts:
destUnreachLastTx.setStatus('mandatory')
source_quench_last_rx = mib_scalar((1, 3, 6, 1, 4, 1, 72, 10, 2, 3), octet_string().subtype(subtypeSpec=value_size_constraint(13, 13)).setFixedLength(13)).setMaxAccess('readonly')
if mibBuilder.loadTexts:
sourceQuenchLastRx.setStatus('mandatory')
source_quench_last_tx = mib_scalar((1, 3, 6, 1, 4, 1, 72, 10, 2, 4), octet_string().subtype(subtypeSpec=value_size_constraint(13, 13)).setFixedLength(13)).setMaxAccess('readonly')
if mibBuilder.loadTexts:
sourceQuenchLastTx.setStatus('mandatory')
redirects_last_rx = mib_scalar((1, 3, 6, 1, 4, 1, 72, 10, 2, 5), octet_string().subtype(subtypeSpec=value_size_constraint(13, 13)).setFixedLength(13)).setMaxAccess('readonly')
if mibBuilder.loadTexts:
redirectsLastRx.setStatus('mandatory')
redirects_last_tx = mib_scalar((1, 3, 6, 1, 4, 1, 72, 10, 2, 6), octet_string().subtype(subtypeSpec=value_size_constraint(13, 13)).setFixedLength(13)).setMaxAccess('readonly')
if mibBuilder.loadTexts:
redirectsLastTx.setStatus('mandatory')
echo_requests_last_rx = mib_scalar((1, 3, 6, 1, 4, 1, 72, 10, 2, 7), octet_string().subtype(subtypeSpec=value_size_constraint(13, 13)).setFixedLength(13)).setMaxAccess('readonly')
if mibBuilder.loadTexts:
echoRequestsLastRx.setStatus('mandatory')
echo_requests_last_tx = mib_scalar((1, 3, 6, 1, 4, 1, 72, 10, 2, 8), octet_string().subtype(subtypeSpec=value_size_constraint(13, 13)).setFixedLength(13)).setMaxAccess('readonly')
if mibBuilder.loadTexts:
echoRequestsLastTx.setStatus('mandatory')
time_exceeded_last_rx = mib_scalar((1, 3, 6, 1, 4, 1, 72, 10, 2, 9), octet_string().subtype(subtypeSpec=value_size_constraint(13, 13)).setFixedLength(13)).setMaxAccess('readonly')
if mibBuilder.loadTexts:
timeExceededLastRx.setStatus('mandatory')
time_exceeded_last_tx = mib_scalar((1, 3, 6, 1, 4, 1, 72, 10, 2, 10), octet_string().subtype(subtypeSpec=value_size_constraint(13, 13)).setFixedLength(13)).setMaxAccess('readonly')
if mibBuilder.loadTexts:
timeExceededLastTx.setStatus('mandatory')
param_prob_last_rx = mib_scalar((1, 3, 6, 1, 4, 1, 72, 10, 2, 11), octet_string().subtype(subtypeSpec=value_size_constraint(13, 13)).setFixedLength(13)).setMaxAccess('readonly')
if mibBuilder.loadTexts:
paramProbLastRx.setStatus('mandatory')
param_prob_last_tx = mib_scalar((1, 3, 6, 1, 4, 1, 72, 10, 2, 12), octet_string().subtype(subtypeSpec=value_size_constraint(13, 13)).setFixedLength(13)).setMaxAccess('readonly')
if mibBuilder.loadTexts:
paramProbLastTx.setStatus('mandatory')
ip_routing = mib_scalar((1, 3, 6, 1, 4, 1, 72, 10, 3), integer32().subtype(subtypeSpec=value_range_constraint(0, 1))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
ipRouting.setStatus('mandatory')
bootp_retry_count = mib_scalar((1, 3, 6, 1, 4, 1, 72, 11, 1), integer32().subtype(subtypeSpec=value_range_constraint(0, 65535))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
bootpRetryCount.setStatus('mandatory')
download_retry_count = mib_scalar((1, 3, 6, 1, 4, 1, 72, 11, 2), integer32().subtype(subtypeSpec=value_range_constraint(0, 65535))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
downloadRetryCount.setStatus('mandatory')
download_filename = mib_scalar((1, 3, 6, 1, 4, 1, 72, 11, 3), octet_string().subtype(subtypeSpec=value_size_constraint(0, 128))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
downloadFilename.setStatus('mandatory')
bootserver_ip_address = mib_scalar((1, 3, 6, 1, 4, 1, 72, 11, 4), ip_address()).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
bootserverIpAddress.setStatus('mandatory')
loadserver_ip_address = mib_scalar((1, 3, 6, 1, 4, 1, 72, 11, 5), ip_address()).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
loadserverIpAddress.setStatus('mandatory')
unique_broadcast_address = mib_scalar((1, 3, 6, 1, 4, 1, 72, 11, 6), ip_address()).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
uniqueBroadcastAddress.setStatus('mandatory')
tftp_retry_count = mib_scalar((1, 3, 6, 1, 4, 1, 72, 11, 7), integer32().subtype(subtypeSpec=value_range_constraint(0, 65535))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
tftpRetryCount.setStatus('mandatory')
tftp_retry_period = mib_scalar((1, 3, 6, 1, 4, 1, 72, 11, 8), integer32().subtype(subtypeSpec=value_range_constraint(0, 65535))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
tftpRetryPeriod.setStatus('mandatory')
initiate_bootp_dll = mib_scalar((1, 3, 6, 1, 4, 1, 72, 11, 9), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2))).clone(namedValues=named_values(('noAction', 1), ('initiateBoot', 2)))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
initiateBootpDll.setStatus('mandatory')
boothelper_enabled = mib_scalar((1, 3, 6, 1, 4, 1, 72, 12, 1), integer32().subtype(subtypeSpec=value_range_constraint(0, 1))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
boothelperEnabled.setStatus('mandatory')
boothelper_hops_limit = mib_scalar((1, 3, 6, 1, 4, 1, 72, 12, 2), integer32().subtype(subtypeSpec=value_range_constraint(0, 255))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
boothelperHopsLimit.setStatus('mandatory')
boothelper_forwarding_address = mib_scalar((1, 3, 6, 1, 4, 1, 72, 12, 3), ip_address()).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
boothelperForwardingAddress.setStatus('mandatory')
ipx_routing = mib_scalar((1, 3, 6, 1, 4, 1, 72, 13, 1, 1), integer32().subtype(subtypeSpec=value_range_constraint(0, 1))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
ipxRouting.setStatus('mandatory')
ipx_if_number = mib_scalar((1, 3, 6, 1, 4, 1, 72, 13, 1, 2), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ipxIfNumber.setStatus('mandatory')
ipx_if_table = mib_table((1, 3, 6, 1, 4, 1, 72, 13, 1, 3))
if mibBuilder.loadTexts:
ipxIfTable.setStatus('mandatory')
ipx_if_entry = mib_table_row((1, 3, 6, 1, 4, 1, 72, 13, 1, 3, 1)).setIndexNames((0, 'RETIX-MIB', 'ipxIfIndex'))
if mibBuilder.loadTexts:
ipxIfEntry.setStatus('mandatory')
ipx_if_index = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 1, 3, 1, 1), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ipxIfIndex.setStatus('mandatory')
ipx_if_nwk_number = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 1, 3, 1, 2), octet_string().subtype(subtypeSpec=value_size_constraint(8, 8)).setFixedLength(8)).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
ipxIfNwkNumber.setStatus('mandatory')
ipx_if_ipx_address = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 1, 3, 1, 3), octet_string().subtype(subtypeSpec=value_size_constraint(26, 26)).setFixedLength(26)).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ipxIfIPXAddress.setStatus('mandatory')
ipx_if_encapsulation = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 1, 3, 1, 4), integer32().subtype(subtypeSpec=value_range_constraint(0, 6))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
ipxIfEncapsulation.setStatus('mandatory')
ipx_if_delay = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 1, 3, 1, 5), integer32()).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
ipxIfDelay.setStatus('mandatory')
ipx_routing_table = mib_table((1, 3, 6, 1, 4, 1, 72, 13, 1, 4))
if mibBuilder.loadTexts:
ipxRoutingTable.setStatus('mandatory')
ipx_rit_entry = mib_table_row((1, 3, 6, 1, 4, 1, 72, 13, 1, 4, 1)).setIndexNames((0, 'RETIX-MIB', 'ipxRITDestNwkNumber'))
if mibBuilder.loadTexts:
ipxRITEntry.setStatus('mandatory')
ipx_rit_dest_nwk_number = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 1, 4, 1, 1), octet_string()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ipxRITDestNwkNumber.setStatus('mandatory')
ipx_rit_gwy_host_address = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 1, 4, 1, 2), octet_string().subtype(subtypeSpec=value_size_constraint(10, 10)).setFixedLength(10)).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ipxRITGwyHostAddress.setStatus('mandatory')
ipx_rit_hop_count = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 1, 4, 1, 3), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ipxRITHopCount.setStatus('mandatory')
ipx_rit_delay = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 1, 4, 1, 4), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ipxRITDelay.setStatus('mandatory')
ipx_rit_interface = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 1, 4, 1, 5), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ipxRITInterface.setStatus('mandatory')
ipx_rit_direct_connect = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 1, 4, 1, 6), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ipxRITDirectConnect.setStatus('mandatory')
ipx_sap_bindery_table = mib_table((1, 3, 6, 1, 4, 1, 72, 13, 1, 5))
if mibBuilder.loadTexts:
ipxSAPBinderyTable.setStatus('mandatory')
ipx_sap_bindery_entry = mib_table_row((1, 3, 6, 1, 4, 1, 72, 13, 1, 5, 1)).setIndexNames((0, 'RETIX-MIB', 'ipxSAPBinderyType'), (0, 'RETIX-MIB', 'ipxSAPBinderyServerIPXAddress'))
if mibBuilder.loadTexts:
ipxSAPBinderyEntry.setStatus('mandatory')
ipx_sap_bindery_type = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 1, 5, 1, 1), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 36, 71, 65535))).clone(namedValues=named_values(('user', 1), ('userGroup', 2), ('printQueue', 3), ('fileServer', 4), ('jobServer', 5), ('gateway', 6), ('printServer', 7), ('archiveQueue', 8), ('archiveServer', 9), ('jobQueue', 10), ('administration', 11), ('remoteBridgeServer', 36), ('advertizingPrintServer', 71), ('wild', 65535)))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ipxSAPBinderyType.setStatus('mandatory')
ipx_sap_bindery_server_ipx_address = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 1, 5, 1, 2), octet_string().subtype(subtypeSpec=value_size_constraint(26, 26)).setFixedLength(26)).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ipxSAPBinderyServerIPXAddress.setStatus('mandatory')
ipx_sap_bindery_server_name = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 1, 5, 1, 3), octet_string().subtype(subtypeSpec=value_size_constraint(0, 48))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ipxSAPBinderyServerName.setStatus('mandatory')
ipx_sap_bindery_hop_count = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 1, 5, 1, 4), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ipxSAPBinderyHopCount.setStatus('mandatory')
ipx_sap_bindery_socket = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 1, 5, 1, 5), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ipxSAPBinderySocket.setStatus('mandatory')
ipx_received_dgms = mib_scalar((1, 3, 6, 1, 4, 1, 72, 13, 1, 6), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ipxReceivedDgms.setStatus('mandatory')
ipx_transmitted_dgms = mib_scalar((1, 3, 6, 1, 4, 1, 72, 13, 1, 7), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ipxTransmittedDgms.setStatus('mandatory')
ipx_not_routed_rx_dgms = mib_scalar((1, 3, 6, 1, 4, 1, 72, 13, 1, 8), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ipxNotRoutedRxDgms.setStatus('mandatory')
ipx_forwarded_dgms = mib_scalar((1, 3, 6, 1, 4, 1, 72, 13, 1, 9), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ipxForwardedDgms.setStatus('mandatory')
ipx_in_delivers = mib_scalar((1, 3, 6, 1, 4, 1, 72, 13, 1, 10), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ipxInDelivers.setStatus('mandatory')
ipx_in_hdr_errors = mib_scalar((1, 3, 6, 1, 4, 1, 72, 13, 1, 11), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ipxInHdrErrors.setStatus('mandatory')
ipx_access_violations = mib_scalar((1, 3, 6, 1, 4, 1, 72, 13, 1, 12), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ipxAccessViolations.setStatus('mandatory')
ipx_in_discards = mib_scalar((1, 3, 6, 1, 4, 1, 72, 13, 1, 13), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ipxInDiscards.setStatus('mandatory')
ipx_out_discards = mib_scalar((1, 3, 6, 1, 4, 1, 72, 13, 1, 14), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ipxOutDiscards.setStatus('mandatory')
ipx_other_discards = mib_scalar((1, 3, 6, 1, 4, 1, 72, 13, 1, 15), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
ipxOtherDiscards.setStatus('mandatory')
dcnt_routing = mib_scalar((1, 3, 6, 1, 4, 1, 72, 13, 2, 1), integer32().subtype(subtypeSpec=value_range_constraint(0, 1))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
dcntRouting.setStatus('mandatory')
dcnt_if_number = mib_scalar((1, 3, 6, 1, 4, 1, 72, 13, 2, 2), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
dcntIfNumber.setStatus('mandatory')
dcnt_if_table = mib_table((1, 3, 6, 1, 4, 1, 72, 13, 2, 3))
if mibBuilder.loadTexts:
dcntIfTable.setStatus('mandatory')
dcnt_if_table_entry = mib_table_row((1, 3, 6, 1, 4, 1, 72, 13, 2, 3, 1)).setIndexNames((0, 'RETIX-MIB', 'dcntIfIndex'))
if mibBuilder.loadTexts:
dcntIfTableEntry.setStatus('mandatory')
dcnt_if_index = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 2, 3, 1, 1), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
dcntIfIndex.setStatus('mandatory')
dcnt_if_cost = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 2, 3, 1, 2), integer32().subtype(subtypeSpec=value_range_constraint(0, 1023))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
dcntIfCost.setStatus('mandatory')
dcnt_if_rtr_priority = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 2, 3, 1, 3), integer32().subtype(subtypeSpec=value_range_constraint(0, 127))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
dcntIfRtrPriority.setStatus('mandatory')
dcnt_if_desgntd_rtr = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 2, 3, 1, 4), integer32().subtype(subtypeSpec=value_range_constraint(0, 1))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
dcntIfDesgntdRtr.setStatus('mandatory')
dcnt_if_hello_timer_bct3 = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 2, 3, 1, 5), integer32().subtype(subtypeSpec=value_range_constraint(1, 8191))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
dcntIfHelloTimerBCT3.setStatus('mandatory')
dcnt_routing_table = mib_table((1, 3, 6, 1, 4, 1, 72, 13, 2, 4))
if mibBuilder.loadTexts:
dcntRoutingTable.setStatus('mandatory')
dcnt_rit_entry = mib_table_row((1, 3, 6, 1, 4, 1, 72, 13, 2, 4, 1)).setIndexNames((0, 'RETIX-MIB', 'dcntRITDestNode'))
if mibBuilder.loadTexts:
dcntRITEntry.setStatus('mandatory')
dcnt_rit_dest_node = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 2, 4, 1, 1), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
dcntRITDestNode.setStatus('mandatory')
dcnt_rit_next_hop = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 2, 4, 1, 2), octet_string()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
dcntRITNextHop.setStatus('mandatory')
dcnt_rit_cost = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 2, 4, 1, 3), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
dcntRITCost.setStatus('mandatory')
dcnt_rit_hops = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 2, 4, 1, 4), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
dcntRITHops.setStatus('mandatory')
dcnt_rit_interface = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 2, 4, 1, 5), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
dcntRITInterface.setStatus('mandatory')
dcnt_area_routing_table = mib_table((1, 3, 6, 1, 4, 1, 72, 13, 2, 5))
if mibBuilder.loadTexts:
dcntAreaRoutingTable.setStatus('mandatory')
dcnt_area_rit_entry = mib_table_row((1, 3, 6, 1, 4, 1, 72, 13, 2, 5, 1)).setIndexNames((0, 'RETIX-MIB', 'dcntAreaRITDestArea'))
if mibBuilder.loadTexts:
dcntAreaRITEntry.setStatus('mandatory')
dcnt_area_rit_dest_area = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 2, 5, 1, 1), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
dcntAreaRITDestArea.setStatus('mandatory')
dcnt_area_rit_next_hop = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 2, 5, 1, 2), octet_string()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
dcntAreaRITNextHop.setStatus('mandatory')
dcnt_area_rit_cost = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 2, 5, 1, 3), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
dcntAreaRITCost.setStatus('mandatory')
dcnt_area_rit_hops = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 2, 5, 1, 4), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
dcntAreaRITHops.setStatus('mandatory')
dcnt_area_rit_interface = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 2, 5, 1, 5), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
dcntAreaRITInterface.setStatus('mandatory')
dcnt_node_address = mib_scalar((1, 3, 6, 1, 4, 1, 72, 13, 2, 6), octet_string()).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
dcntNodeAddress.setStatus('mandatory')
dcnt_inter_area_max_cost = mib_scalar((1, 3, 6, 1, 4, 1, 72, 13, 2, 7), integer32().subtype(subtypeSpec=value_range_constraint(0, 1023))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
dcntInterAreaMaxCost.setStatus('mandatory')
dcnt_inter_area_max_hops = mib_scalar((1, 3, 6, 1, 4, 1, 72, 13, 2, 8), integer32().subtype(subtypeSpec=value_range_constraint(0, 1023))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
dcntInterAreaMaxHops.setStatus('mandatory')
dcnt_intra_area_max_cost = mib_scalar((1, 3, 6, 1, 4, 1, 72, 13, 2, 9), integer32().subtype(subtypeSpec=value_range_constraint(0, 1023))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
dcntIntraAreaMaxCost.setStatus('mandatory')
dcnt_intra_area_max_hops = mib_scalar((1, 3, 6, 1, 4, 1, 72, 13, 2, 10), integer32().subtype(subtypeSpec=value_range_constraint(0, 1023))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
dcntIntraAreaMaxHops.setStatus('mandatory')
dcnt_max_visits = mib_scalar((1, 3, 6, 1, 4, 1, 72, 13, 2, 11), integer32().subtype(subtypeSpec=value_range_constraint(0, 63))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
dcntMaxVisits.setStatus('mandatory')
dcnt_rtng_msg_timer_bct1 = mib_scalar((1, 3, 6, 1, 4, 1, 72, 13, 2, 12), integer32().subtype(subtypeSpec=value_range_constraint(5, 30))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
dcntRtngMsgTimerBCT1.setStatus('mandatory')
dcnt_rate_control_freq_timer_t2 = mib_scalar((1, 3, 6, 1, 4, 1, 72, 13, 2, 13), integer32().subtype(subtypeSpec=value_range_constraint(1, 5))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
dcntRateControlFreqTimerT2.setStatus('mandatory')
dcnt_reveived_dgms = mib_scalar((1, 3, 6, 1, 4, 1, 72, 13, 2, 14), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
dcntReveivedDgms.setStatus('mandatory')
dcnt_forwarded_dgms = mib_scalar((1, 3, 6, 1, 4, 1, 72, 13, 2, 15), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
dcntForwardedDgms.setStatus('mandatory')
dcnt_out_requested_dgms = mib_scalar((1, 3, 6, 1, 4, 1, 72, 13, 2, 16), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
dcntOutRequestedDgms.setStatus('mandatory')
dcnt_in_discards = mib_scalar((1, 3, 6, 1, 4, 1, 72, 13, 2, 17), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
dcntInDiscards.setStatus('mandatory')
dcnt_out_discards = mib_scalar((1, 3, 6, 1, 4, 1, 72, 13, 2, 18), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
dcntOutDiscards.setStatus('mandatory')
dcnt_no_routes = mib_scalar((1, 3, 6, 1, 4, 1, 72, 13, 2, 19), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
dcntNoRoutes.setStatus('mandatory')
dcnt_in_hdr_errors = mib_scalar((1, 3, 6, 1, 4, 1, 72, 13, 2, 20), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
dcntInHdrErrors.setStatus('mandatory')
rmt_lapb_config_table = mib_table((1, 3, 6, 1, 4, 1, 72, 13, 3, 1))
if mibBuilder.loadTexts:
rmtLapbConfigTable.setStatus('mandatory')
rmt_lapb_ct_entry = mib_table_row((1, 3, 6, 1, 4, 1, 72, 13, 3, 1, 1)).setIndexNames((0, 'RETIX-MIB', 'rmtLapbCTIndex'))
if mibBuilder.loadTexts:
rmtLapbCTEntry.setStatus('mandatory')
rmt_lapb_ct_index = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 3, 1, 1, 1), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
rmtLapbCTIndex.setStatus('mandatory')
rmt_lapb_ct_link_addr = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 3, 1, 1, 2), integer32().subtype(subtypeSpec=value_range_constraint(0, 1))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
rmtLapbCTLinkAddr.setStatus('mandatory')
rmt_lapb_ct_ext_seq_numbering = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 3, 1, 1, 3), integer32().subtype(subtypeSpec=value_range_constraint(0, 1))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
rmtLapbCTExtSeqNumbering.setStatus('mandatory')
rmt_lapb_ct_window = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 3, 1, 1, 4), integer32().subtype(subtypeSpec=value_range_constraint(1, 127))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
rmtLapbCTWindow.setStatus('mandatory')
rmt_lapb_ct_mode_t1 = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 3, 1, 1, 5), integer32().subtype(subtypeSpec=value_range_constraint(0, 1))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
rmtLapbCTModeT1.setStatus('mandatory')
rmt_lapb_ct_manual_t1_value = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 3, 1, 1, 6), integer32().subtype(subtypeSpec=value_range_constraint(10, 5000))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
rmtLapbCTManualT1Value.setStatus('mandatory')
rmt_lapb_ctt3_link_idle_timer = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 3, 1, 1, 7), integer32().subtype(subtypeSpec=value_range_constraint(1, 65535))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
rmtLapbCTT3LinkIdleTimer.setStatus('mandatory')
rmt_lapb_ctn2_retry_count = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 3, 1, 1, 8), integer32().subtype(subtypeSpec=value_range_constraint(1, 255))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
rmtLapbCTN2RetryCount.setStatus('mandatory')
rmt_lapb_ct_link_reset = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 3, 1, 1, 9), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2))).clone(namedValues=named_values(('noAction', 1), ('resetLink', 2)))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
rmtLapbCTLinkReset.setStatus('mandatory')
rmt_lapb_ctx25_port_line_speed = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 3, 1, 1, 10), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1200, 2400, 4800, 9600, 19200, 32000, 48000, 64000))).clone(namedValues=named_values(('b1200', 1200), ('b2400', 2400), ('b4800', 4800), ('b9600', 9600), ('b19200', 19200), ('b32000', 32000), ('b48000', 48000), ('b64000', 64000)))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
rmtLapbCTX25PortLineSpeed.setStatus('mandatory')
rmt_lapb_ct_init_link_connect = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 3, 1, 1, 11), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2))).clone(namedValues=named_values(('noAction', 1), ('connect', 2)))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
rmtLapbCTInitLinkConnect.setStatus('mandatory')
rmt_lapb_stats_table = mib_table((1, 3, 6, 1, 4, 1, 72, 13, 3, 2))
if mibBuilder.loadTexts:
rmtLapbStatsTable.setStatus('mandatory')
rmt_lapb_st_entry = mib_table_row((1, 3, 6, 1, 4, 1, 72, 13, 3, 2, 1)).setIndexNames((0, 'RETIX-MIB', 'rmtLapbSTIndex'))
if mibBuilder.loadTexts:
rmtLapbSTEntry.setStatus('mandatory')
rmt_lapb_st_index = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 3, 2, 1, 1), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
rmtLapbSTIndex.setStatus('mandatory')
rmt_lapb_st_state = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 3, 2, 1, 2), integer32().subtype(subtypeSpec=value_range_constraint(0, 3))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
rmtLapbSTState.setStatus('mandatory')
rmt_lapb_st_auto_t1value = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 3, 2, 1, 3), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
rmtLapbSTAutoT1value.setStatus('mandatory')
rmt_lapb_st_last_reset_time = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 3, 2, 1, 4), octet_string().subtype(subtypeSpec=value_size_constraint(13, 13)).setFixedLength(13)).setMaxAccess('readonly')
if mibBuilder.loadTexts:
rmtLapbSTLastResetTime.setStatus('mandatory')
rmt_lapb_st_last_reset_reason = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 3, 2, 1, 5), integer32().subtype(subtypeSpec=value_range_constraint(0, 8))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
rmtLapbSTLastResetReason.setStatus('mandatory')
rmt_lapb_st_count_resets = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 3, 2, 1, 6), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
rmtLapbSTCountResets.setStatus('mandatory')
rmt_lapb_st_count_sent_frames = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 3, 2, 1, 7), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
rmtLapbSTCountSentFrames.setStatus('mandatory')
rmt_lapb_st_count_rcv_frames = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 3, 2, 1, 8), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
rmtLapbSTCountRcvFrames.setStatus('mandatory')
rmt_lapb_st_count_sent_octets = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 3, 2, 1, 9), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
rmtLapbSTCountSentOctets.setStatus('mandatory')
rmt_lapb_st_count_rcv_octets = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 3, 2, 1, 10), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
rmtLapbSTCountRcvOctets.setStatus('mandatory')
rmt_lapb_st_count_aborts = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 3, 2, 1, 11), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
rmtLapbSTCountAborts.setStatus('mandatory')
rmt_lapb_st_count_crc_errors = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 3, 2, 1, 12), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
rmtLapbSTCountCrcErrors.setStatus('mandatory')
x25_operation = mib_scalar((1, 3, 6, 1, 4, 1, 72, 13, 4, 1), integer32().subtype(subtypeSpec=value_range_constraint(0, 1))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
x25Operation.setStatus('mandatory')
x25_oper_next_reset = mib_scalar((1, 3, 6, 1, 4, 1, 72, 13, 4, 2), integer32().subtype(subtypeSpec=value_range_constraint(0, 1))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
x25OperNextReset.setStatus('mandatory')
x25_con_setup_table = mib_table((1, 3, 6, 1, 4, 1, 72, 13, 4, 3))
if mibBuilder.loadTexts:
x25ConSetupTable.setStatus('mandatory')
x25_cst_entry = mib_table_row((1, 3, 6, 1, 4, 1, 72, 13, 4, 3, 1)).setIndexNames((0, 'RETIX-MIB', 'x25CSTIndex'))
if mibBuilder.loadTexts:
x25CSTEntry.setStatus('mandatory')
x25_cst_index = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 4, 3, 1, 1), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
x25CSTIndex.setStatus('mandatory')
x25_cst8084_switch = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 4, 3, 1, 2), integer32()).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
x25CST8084Switch.setStatus('mandatory')
x25_cst_src_dte_addr = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 4, 3, 1, 3), octet_string().subtype(subtypeSpec=value_size_constraint(15, 15)).setFixedLength(15)).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
x25CSTSrcDTEAddr.setStatus('mandatory')
x25_cst_dest_dte_addr = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 4, 3, 1, 4), octet_string().subtype(subtypeSpec=value_size_constraint(15, 15)).setFixedLength(15)).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
x25CSTDestDTEAddr.setStatus('mandatory')
x25_cst2_way_lgcl_chan_num = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 4, 3, 1, 5), integer32().subtype(subtypeSpec=value_range_constraint(1, 4095))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
x25CST2WayLgclChanNum.setStatus('mandatory')
x25_cst_pkt_seq_num_flg = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 4, 3, 1, 6), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 4))).clone(namedValues=named_values(('mod8', 1), ('mod128', 4)))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
x25CSTPktSeqNumFlg.setStatus('mandatory')
x25_cst_flow_cntrl_neg = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 4, 3, 1, 7), integer32().subtype(subtypeSpec=value_range_constraint(0, 1))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
x25CSTFlowCntrlNeg.setStatus('mandatory')
x25_cst_default_win_size = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 4, 3, 1, 8), integer32().subtype(subtypeSpec=value_range_constraint(1, 127))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
x25CSTDefaultWinSize.setStatus('mandatory')
x25_cst_default_pkt_size = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 4, 3, 1, 9), integer32()).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
x25CSTDefaultPktSize.setStatus('mandatory')
x25_cst_neg_win_size = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 4, 3, 1, 10), integer32().subtype(subtypeSpec=value_range_constraint(1, 127))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
x25CSTNegWinSize.setStatus('mandatory')
x25_cst_neg_pkt_size = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 4, 3, 1, 11), integer32()).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
x25CSTNegPktSize.setStatus('mandatory')
x25_cstcug_sub = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 4, 3, 1, 12), integer32().subtype(subtypeSpec=value_range_constraint(0, 4))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
x25CSTCUGSub.setStatus('mandatory')
x25_cst_lcl_cug_value = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 4, 3, 1, 13), integer32().subtype(subtypeSpec=value_range_constraint(0, 99))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
x25CSTLclCUGValue.setStatus('mandatory')
x25_cst_rvrs_chrg_req = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 4, 3, 1, 14), integer32().subtype(subtypeSpec=value_range_constraint(0, 1))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
x25CSTRvrsChrgReq.setStatus('mandatory')
x25_cst_rvrs_chrg_acc = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 4, 3, 1, 15), integer32().subtype(subtypeSpec=value_range_constraint(0, 1))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
x25CSTRvrsChrgAcc.setStatus('mandatory')
x25_con_control_table = mib_table((1, 3, 6, 1, 4, 1, 72, 13, 4, 4))
if mibBuilder.loadTexts:
x25ConControlTable.setStatus('mandatory')
x25_cct_entry = mib_table_row((1, 3, 6, 1, 4, 1, 72, 13, 4, 4, 1)).setIndexNames((0, 'RETIX-MIB', 'x25CCTIndex'))
if mibBuilder.loadTexts:
x25CCTEntry.setStatus('mandatory')
x25_cct_index = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 4, 4, 1, 1), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
x25CCTIndex.setStatus('mandatory')
x25_cct_manual_connect = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 4, 4, 1, 2), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2))).clone(namedValues=named_values(('noAction', 1), ('connect', 2)))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
x25CCTManualConnect.setStatus('mandatory')
x25_cct_manual_disconnect = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 4, 4, 1, 3), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2))).clone(namedValues=named_values(('noAction', 1), ('disconnect', 2)))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
x25CCTManualDisconnect.setStatus('mandatory')
x25_cct_cfg_auto_con_retry = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 4, 4, 1, 4), integer32().subtype(subtypeSpec=value_range_constraint(0, 1))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
x25CCTCfgAutoConRetry.setStatus('mandatory')
x25_cct_oper_auto_con_retry_flg = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 4, 4, 1, 5), integer32().subtype(subtypeSpec=value_range_constraint(0, 1))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
x25CCTOperAutoConRetryFlg.setStatus('mandatory')
x25_cct_auto_con_retry_timer = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 4, 4, 1, 6), integer32().subtype(subtypeSpec=value_range_constraint(1, 3600))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
x25CCTAutoConRetryTimer.setStatus('mandatory')
x25_cct_max_auto_con_retries = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 4, 4, 1, 7), integer32().subtype(subtypeSpec=value_range_constraint(0, 255))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
x25CCTMaxAutoConRetries.setStatus('mandatory')
x25_cct_cfg_tod_control = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 4, 4, 1, 8), integer32().subtype(subtypeSpec=value_range_constraint(0, 1))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
x25CCTCfgTODControl.setStatus('mandatory')
x25_cct_current_tod_control = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 4, 4, 1, 9), integer32().subtype(subtypeSpec=value_range_constraint(0, 1))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
x25CCTCurrentTODControl.setStatus('mandatory')
x25_ccttod_to_connect = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 4, 4, 1, 10), octet_string().subtype(subtypeSpec=value_size_constraint(4, 4)).setFixedLength(4)).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
x25CCTTODToConnect.setStatus('mandatory')
x25_ccttod_to_disconnect = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 4, 4, 1, 11), octet_string().subtype(subtypeSpec=value_size_constraint(4, 4)).setFixedLength(4)).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
x25CCTTODToDisconnect.setStatus('mandatory')
x25_timer_table = mib_table((1, 3, 6, 1, 4, 1, 72, 13, 4, 5))
if mibBuilder.loadTexts:
x25TimerTable.setStatus('mandatory')
x25_tt_entry = mib_table_row((1, 3, 6, 1, 4, 1, 72, 13, 4, 5, 1)).setIndexNames((0, 'RETIX-MIB', 'x25TTIndex'))
if mibBuilder.loadTexts:
x25TTEntry.setStatus('mandatory')
x25_tt_index = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 4, 5, 1, 1), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
x25TTIndex.setStatus('mandatory')
x25_ttt20_timer = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 4, 5, 1, 2), integer32().subtype(subtypeSpec=value_range_constraint(1, 1024))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
x25TTT20Timer.setStatus('mandatory')
x25_ttt21_timer = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 4, 5, 1, 3), integer32().subtype(subtypeSpec=value_range_constraint(1, 1024))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
x25TTT21Timer.setStatus('mandatory')
x25_ttt22_timer = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 4, 5, 1, 4), integer32().subtype(subtypeSpec=value_range_constraint(1, 1024))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
x25TTT22Timer.setStatus('mandatory')
x25_ttt23_timer = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 4, 5, 1, 5), integer32().subtype(subtypeSpec=value_range_constraint(1, 1024))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
x25TTT23Timer.setStatus('mandatory')
x25_ttr20_limit = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 4, 5, 1, 6), integer32().subtype(subtypeSpec=value_range_constraint(1, 255))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
x25TTR20Limit.setStatus('mandatory')
x25_ttr22_limit = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 4, 5, 1, 7), integer32().subtype(subtypeSpec=value_range_constraint(1, 255))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
x25TTR22Limit.setStatus('mandatory')
x25_ttr23_limit = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 4, 5, 1, 8), integer32().subtype(subtypeSpec=value_range_constraint(1, 255))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
x25TTR23Limit.setStatus('mandatory')
x25_status_table = mib_table((1, 3, 6, 1, 4, 1, 72, 13, 4, 6))
if mibBuilder.loadTexts:
x25StatusTable.setStatus('mandatory')
x25_status_table_entry = mib_table_row((1, 3, 6, 1, 4, 1, 72, 13, 4, 6, 1)).setIndexNames((0, 'RETIX-MIB', 'x25StatusIndex'))
if mibBuilder.loadTexts:
x25StatusTableEntry.setStatus('mandatory')
x25_status_index = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 4, 6, 1, 1), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
x25StatusIndex.setStatus('mandatory')
x25_status_if_status = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 4, 6, 1, 2), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
x25StatusIfStatus.setStatus('mandatory')
x25_status_svc_status = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 4, 6, 1, 3), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
x25StatusSVCStatus.setStatus('mandatory')
x25_status_win_size = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 4, 6, 1, 4), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
x25StatusWinSize.setStatus('mandatory')
x25_status_pkt_size = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 4, 6, 1, 5), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
x25StatusPktSize.setStatus('mandatory')
x25_status_cause_last_in_clear = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 4, 6, 1, 6), integer32().subtype(subtypeSpec=value_range_constraint(0, 255))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
x25StatusCauseLastInClear.setStatus('mandatory')
x25_status_diag_last_in_clear = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 4, 6, 1, 7), integer32().subtype(subtypeSpec=value_range_constraint(0, 255))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
x25StatusDiagLastInClear.setStatus('mandatory')
x25_stats_table = mib_table((1, 3, 6, 1, 4, 1, 72, 13, 4, 7))
if mibBuilder.loadTexts:
x25StatsTable.setStatus('mandatory')
x25_stats_table_entry = mib_table_row((1, 3, 6, 1, 4, 1, 72, 13, 4, 7, 1)).setIndexNames((0, 'RETIX-MIB', 'x25STSVCIndex'))
if mibBuilder.loadTexts:
x25StatsTableEntry.setStatus('mandatory')
x25_stsvc_index = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 4, 7, 1, 1), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
x25STSVCIndex.setStatus('mandatory')
x25_st_tx_data_pkts = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 4, 7, 1, 2), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
x25STTxDataPkts.setStatus('mandatory')
x25_st_rx_data_pkts = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 4, 7, 1, 3), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
x25STRxDataPkts.setStatus('mandatory')
x25_st_tx_connect_req_pkts = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 4, 7, 1, 4), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
x25STTxConnectReqPkts.setStatus('mandatory')
x25_st_rx_incoming_call_pkts = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 4, 7, 1, 5), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
x25STRxIncomingCallPkts.setStatus('mandatory')
x25_st_tx_clear_req_pkts = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 4, 7, 1, 6), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
x25STTxClearReqPkts.setStatus('mandatory')
x25_st_rx_clear_ind_pkts = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 4, 7, 1, 7), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
x25STRxClearIndPkts.setStatus('mandatory')
x25_st_tx_reset_req_pkts = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 4, 7, 1, 8), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
x25STTxResetReqPkts.setStatus('mandatory')
x25_st_rx_reset_ind_pkts = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 4, 7, 1, 9), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
x25STRxResetIndPkts.setStatus('mandatory')
x25_st_tx_restart_req_pkts = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 4, 7, 1, 10), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
x25STTxRestartReqPkts.setStatus('mandatory')
x25_st_rx_restart_ind_pkts = mib_table_column((1, 3, 6, 1, 4, 1, 72, 13, 4, 7, 1, 11), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
x25STRxRestartIndPkts.setStatus('mandatory')
mibBuilder.exportSymbols('RETIX-MIB', x25StatsTable=x25StatsTable, ipxOtherDiscards=ipxOtherDiscards, mlink=mlink, triangulation=triangulation, x25STTxDataPkts=x25STTxDataPkts, redirectsLastTx=redirectsLastTx, trapDestEntry=trapDestEntry, serialLoading=serialLoading, x25StatusDiagLastInClear=x25StatusDiagLastInClear, receivedTotalDgms=receivedTotalDgms, snmpAccessPolicyTable=snmpAccessPolicyTable, phySerIfT1frameAndCode=phySerIfT1frameAndCode, x25CSTDefaultWinSize=x25CSTDefaultWinSize, maxRejectedFrames=maxRejectedFrames, x25CCTEntry=x25CCTEntry, x25CSTSrcDTEAddr=x25CSTSrcDTEAddr, filterTableAction=filterTableAction, authenticationTrapStatus=authenticationTrapStatus, ipRouting=ipRouting, operatingMode=operatingMode, lapbCountRcvOctets=lapbCountRcvOctets, ipxRITInterface=ipxRITInterface, phySerIfTransitDelay=phySerIfTransitDelay, priorityMatches=priorityMatches, x25STTxConnectReqPkts=x25STTxConnectReqPkts, x25CSTFlowCntrlNeg=x25CSTFlowCntrlNeg, ipxRITEntry=ipxRITEntry, ieee8023Entry=ieee8023Entry, averagePeriod=averagePeriod, remote=remote, x25=x25, x25STTxRestartReqPkts=x25STTxRestartReqPkts, dcntIfCost=dcntIfCost, lapbEntry=lapbEntry, ifStatus=ifStatus, ipxIfEntry=ipxIfEntry, mlinkTable=mlinkTable, ipxNotRoutedRxDgms=ipxNotRoutedRxDgms, ieee8023FrameTooLongs=ieee8023FrameTooLongs, portPriorityAutoValue=portPriorityAutoValue, phySerIfT1SlotLvalue=phySerIfT1SlotLvalue, spatHelloTimer=spatHelloTimer, rmtLapbStatsTable=rmtLapbStatsTable, internalQueueCurrentLength=internalQueueCurrentLength, ipxRITGwyHostAddress=ipxRITGwyHostAddress, dcntIntraAreaMaxCost=dcntIntraAreaMaxCost, bridge=bridge, ieee8023NewMACAddressIndex=ieee8023NewMACAddressIndex, echoRequestsLastTx=echoRequestsLastTx, rmtLapbSTCountSentOctets=rmtLapbSTCountSentOctets, mlinkIndex=mlinkIndex, lapbLastResetReason=lapbLastResetReason, x25CSTDestDTEAddr=x25CSTDestDTEAddr, ipxForwardedDgms=ipxForwardedDgms, boothelper=boothelper, dcntRITCost=dcntRITCost, dcntNodeAddress=dcntNodeAddress, rmtLapbSTIndex=rmtLapbSTIndex, ieee8023FramesReceivedOks=ieee8023FramesReceivedOks, sourceQuenchLastTx=sourceQuenchLastTx, lanAccepts=lanAccepts, ieee8023SingleCollisionFrames=ieee8023SingleCollisionFrames, snmpAccessPolicyAction=snmpAccessPolicyAction, ipxSAPBinderyEntry=ipxSAPBinderyEntry, maxSerialLoading=maxSerialLoading, ipxTransmittedDgms=ipxTransmittedDgms, phySerIfT1dRatePerChan=phySerIfT1dRatePerChan, x25CCTMaxAutoConRetries=x25CCTMaxAutoConRetries, x25CSTIndex=x25CSTIndex, portSpatState=portSpatState, x25StatusIfStatus=x25StatusIfStatus, lapbIndex=lapbIndex, downloadRetryCount=downloadRetryCount, x25ConControlTable=x25ConControlTable, x25STRxIncomingCallPkts=x25STRxIncomingCallPkts, ipxIfNwkNumber=ipxIfNwkNumber, stpTable=stpTable, dcntForwardedDgms=dcntForwardedDgms, ieee8023LateCollisions=ieee8023LateCollisions, activeRemote=activeRemote, ipxRITDirectConnect=ipxRITDirectConnect, filterSubTable=filterSubTable, x25CCTManualDisconnect=x25CCTManualDisconnect, lapbCountAborts=lapbCountAborts, rmtLapbSTLastResetReason=rmtLapbSTLastResetReason, x25StatusCauseLastInClear=x25StatusCauseLastInClear, x25TTT23Timer=x25TTT23Timer, ieee8023MulticastReceiveStatus=ieee8023MulticastReceiveStatus, ieee8023NewMACAddressEntry=ieee8023NewMACAddressEntry, dynamicLearningInLM=dynamicLearningInLM, mlinkEntry=mlinkEntry, retix=retix, dcntIfHelloTimerBCT3=dcntIfHelloTimerBCT3, ieee8023MulticastFramesReceivedOks=ieee8023MulticastFramesReceivedOks, rmtLapbCTExtSeqNumbering=rmtLapbCTExtSeqNumbering, dcntAreaRITEntry=dcntAreaRITEntry, x25StatusTable=x25StatusTable, redirectsLastRx=redirectsLastRx, ieee8023OctetsTransmittedOks=ieee8023OctetsTransmittedOks, ieee8023InternalMACTransmitErrors=ieee8023InternalMACTransmitErrors, snmpAccessPolicyType=snmpAccessPolicyType, ieee8023FramesTransmittedOks=ieee8023FramesTransmittedOks, x25CCTIndex=x25CCTIndex, dcntAreaRoutingTable=dcntAreaRoutingTable, ieee8023MulticastFramesTransmittedOks=ieee8023MulticastFramesTransmittedOks, ipxInDiscards=ipxInDiscards, product=product, x25TTT22Timer=x25TTT22Timer, typeFilter=typeFilter, ieee8023CarrierSenseErrors=ieee8023CarrierSenseErrors, stpIndex=stpIndex, uniqueBroadcastAddress=uniqueBroadcastAddress, boothelperEnabled=boothelperEnabled, trapDestAction=trapDestAction, snmpAccessPolicyObject=snmpAccessPolicyObject, dcntRITInterface=dcntRITInterface, x25STRxResetIndPkts=x25STRxResetIndPkts, trapDestinationTable=trapDestinationTable, lapbState=lapbState, expressQueueUpperLimit=expressQueueUpperLimit, ipxRITDestNwkNumber=ipxRITDestNwkNumber, accessPolicyIndex=accessPolicyIndex, filteringDbStatus=filteringDbStatus, ipxIfIndex=ipxIfIndex, phySerIfTable=phySerIfTable, rmtLapbSTCountResets=rmtLapbSTCountResets, x25StatsTableEntry=x25StatsTableEntry, station=station, dcntIntraAreaMaxHops=dcntIntraAreaMaxHops, filteringDbDisposition=filteringDbDisposition, rmtLapbCTN2RetryCount=rmtLapbCTN2RetryCount, spanningTree=spanningTree, downloadFilename=downloadFilename, ieee8023=ieee8023, filteringDbEntry=filteringDbEntry, ieee8023NewMACAddress=ieee8023NewMACAddress, phySerIfMeasuredSpeed=phySerIfMeasuredSpeed, accessMode=accessMode, x25CCTAutoConRetryTimer=x25CCTAutoConRetryTimer, lapbWindow=lapbWindow, dcntIfTableEntry=dcntIfTableEntry, typePrioritisation=typePrioritisation, loPriQueueUpperLimit=loPriQueueUpperLimit, lapbPolarity=lapbPolarity, x25CSTRvrsChrgAcc=x25CSTRvrsChrgAcc, x25CST8084Switch=x25CST8084Switch, rmtLapbSTEntry=rmtLapbSTEntry, x25STRxClearIndPkts=x25STRxClearIndPkts, dcntInterAreaMaxHops=dcntInterAreaMaxHops, rmtLapbSTLastResetTime=rmtLapbSTLastResetTime, spatVersion=spatVersion, priorityPage=priorityPage, echoRequestsLastRx=echoRequestsLastRx, rmtLapbCTLinkReset=rmtLapbCTLinkReset, dcntInterAreaMaxCost=dcntInterAreaMaxCost, phySerIfPortSpeed=phySerIfPortSpeed, ieee8023Index=ieee8023Index, dcntOutRequestedDgms=dcntOutRequestedDgms, ieee8023Number=ieee8023Number, rmtLapbCTInitLinkConnect=rmtLapbCTInitLinkConnect, priorityTableEntryValue=priorityTableEntryValue, stationTime=stationTime, forgetAddressTimer=forgetAddressTimer, ipxIfTable=ipxIfTable, x25ConSetupTable=x25ConSetupTable, phySerIfT1SlotHvalue=phySerIfT1SlotHvalue, dcntRateControlFreqTimerT2=dcntRateControlFreqTimerT2, ipxRITDelay=ipxRITDelay, ieee8023AlignmentErrors=ieee8023AlignmentErrors, rmtLapbCTModeT1=rmtLapbCTModeT1, deletedMlinkFrames=deletedMlinkFrames, stpEntry=stpEntry, filterTableEntryValue=filterTableEntryValue, ieee8023ExcessiveDeferrals=ieee8023ExcessiveDeferrals, ieee8023FCSErrors=ieee8023FCSErrors, queueUpperLimit=queueUpperLimit, x25CSTEntry=x25CSTEntry, dcntRITEntry=dcntRITEntry, ipxOutDiscards=ipxOutDiscards, dcntAreaRITCost=dcntAreaRITCost, expressQueueCurrentLength=expressQueueCurrentLength, resetStation=resetStation, ieee8023InternalMACReceiveErrors=ieee8023InternalMACReceiveErrors, icmpRSTable=icmpRSTable, ipxIfEncapsulation=ipxIfEncapsulation, dcntNoRoutes=dcntNoRoutes, ipxSAPBinderyServerIPXAddress=ipxSAPBinderyServerIPXAddress, x25Operation=x25Operation, phySerIfIsSpeedsettable=phySerIfIsSpeedsettable, ieee8023BroadcastFramesTransmittedOks=ieee8023BroadcastFramesTransmittedOks, phySerIfEntry=phySerIfEntry, lanInterfaceType=lanInterfaceType, mlinkSendSeq=mlinkSendSeq, rmtLapbSTState=rmtLapbSTState, dcntRouting=dcntRouting, ipxSAPBinderyHopCount=ipxSAPBinderyHopCount, rmtLapbConfigTable=rmtLapbConfigTable, rmtLapbSTCountCrcErrors=rmtLapbSTCountCrcErrors, lapb=lapb, rmtLapb=rmtLapb, physBlkSize=physBlkSize, ipxInDelivers=ipxInDelivers, mlinkRxTimeout=mlinkRxTimeout, trapDestEntryCommunityName=trapDestEntryCommunityName, ieeeFormatPriority=ieeeFormatPriority, x25TimerTable=x25TimerTable, lapbCountResets=lapbCountResets, x25CCTManualConnect=x25CCTManualConnect, x25TTR20Limit=x25TTR20Limit, ipxRouting=ipxRouting, trapDestEntryIpAddr=trapDestEntryIpAddr, ipxInHdrErrors=ipxInHdrErrors, x25StatusTableEntry=x25StatusTableEntry, x25CCTOperAutoConRetryFlg=x25CCTOperAutoConRetryFlg, lapbCountRcvFrames=lapbCountRcvFrames, pathCostAutoValue=pathCostAutoValue, filteringDbAction=filteringDbAction, x25OperNextReset=x25OperNextReset, loPriQueueCurrentLength=loPriQueueCurrentLength, spanningMcastAddr=spanningMcastAddr, timeExceededLastTx=timeExceededLastTx, ieee8023SQETestErrors=ieee8023SQETestErrors, newPhysBlkSize=newPhysBlkSize, portNumber=portNumber, rmtLapbSTCountRcvFrames=rmtLapbSTCountRcvFrames, rmtLapbCTX25PortLineSpeed=rmtLapbCTX25PortLineSpeed, ipxSAPBinderyTable=ipxSAPBinderyTable, filteringDbMacAddress=filteringDbMacAddress, dcntIfNumber=dcntIfNumber, paramProbLastTx=paramProbLastTx, phySerIfT1clockSource=phySerIfT1clockSource, dcntIfDesgntdRtr=dcntIfDesgntdRtr, mlinkState=mlinkState, preconfSourceFilter=preconfSourceFilter, x25STRxDataPkts=x25STRxDataPkts, ipRSEntry=ipRSEntry, tftpRetryPeriod=tftpRetryPeriod, x25TTR23Limit=x25TTR23Limit, lapbModeT1=lapbModeT1, phySerIfPartnerAddress=phySerIfPartnerAddress, phySerIfNumber=phySerIfNumber, boothelperForwardingAddress=boothelperForwardingAddress, bridgeStatsEntry=bridgeStatsEntry, ipxSAPBinderyType=ipxSAPBinderyType, rmtLapbSTCountRcvOctets=rmtLapbSTCountRcvOctets, dcntAreaRITNextHop=dcntAreaRITNextHop, rmtLapbCTEntry=rmtLapbCTEntry, phySerIf=phySerIf, lapbNumber=lapbNumber, x25StatusIndex=x25StatusIndex, ipxReceivedDgms=ipxReceivedDgms, ieee8023InitializeMAC=ieee8023InitializeMAC, portPriorityMode=portPriorityMode, x25CSTNegWinSize=x25CSTNegWinSize)
mibBuilder.exportSymbols('RETIX-MIB', ieee8023MultipleCollisionFrames=ieee8023MultipleCollisionFrames, x25CSTPktSeqNumFlg=x25CSTPktSeqNumFlg, paramProbLastRx=paramProbLastRx, lapbRetryCount=lapbRetryCount, deletedLanFrames=deletedLanFrames, x25TTIndex=x25TTIndex, priorityTableAction=priorityTableAction, boot=boot, mlinkRcvSeq=mlinkRcvSeq, spatResetTimer=spatResetTimer, mlinkLostFrames=mlinkLostFrames, ieeeFormatFilter=ieeeFormatFilter, filteringDbType=filteringDbType, snmpAccessPolicyEntry=snmpAccessPolicyEntry, timeExceededLastRx=timeExceededLastRx, standbyRemote=standbyRemote, x25TTT21Timer=x25TTT21Timer, lapbLastResetTime=lapbLastResetTime, destUnreachLastRx=destUnreachLastRx, initiateBootpDll=initiateBootpDll, ieee8023inRangeLengthErrors=ieee8023inRangeLengthErrors, ipxAccessViolations=ipxAccessViolations, loadserverIpAddress=loadserverIpAddress, ipxSAPBinderySocket=ipxSAPBinderySocket, ieee8023DeferredTransmissions=ieee8023DeferredTransmissions, dcntIfRtrPriority=dcntIfRtrPriority, averageForwardedFrames=averageForwardedFrames, x25CCTTODToConnect=x25CCTTODToConnect, rmtLapbSTCountSentFrames=rmtLapbSTCountSentFrames, x25StatusWinSize=x25StatusWinSize, ipxSAPBinderyServerName=ipxSAPBinderyServerName, dcntIfIndex=dcntIfIndex, boothelperHopsLimit=boothelperHopsLimit, router=router, serialLoadPeriod=serialLoadPeriod, hiPriQueueCurrentLength=hiPriQueueCurrentLength, ipxIfIPXAddress=ipxIfIPXAddress, standbyLocal=standbyLocal, spatPriority=spatPriority, ieee8023BroadcastFramesReceivedOks=ieee8023BroadcastFramesReceivedOks, destUnreachLastTx=destUnreachLastTx, multicastDisposition=multicastDisposition, gwProtocol=gwProtocol, transmittedTotalDgms=transmittedTotalDgms, pathCostMode=pathCostMode, phySerIfIndex=phySerIfIndex, x25CSTLclCUGValue=x25CSTLclCUGValue, x25CSTNegPktSize=x25CSTNegPktSize, filterTableEntry=filterTableEntry, resetStats=resetStats, lapbManualT1value=lapbManualT1value, trapDestTable=trapDestTable, x25TTEntry=x25TTEntry, dcntRITDestNode=dcntRITDestNode, dcntInDiscards=dcntInDiscards, dcntMaxVisits=dcntMaxVisits, rmtLapbSTCountAborts=rmtLapbSTCountAborts, rmtLapbSTAutoT1value=rmtLapbSTAutoT1value, rmtLapbCTLinkAddr=rmtLapbCTLinkAddr, ipxRoutingTable=ipxRoutingTable, rmtLapbCTManualT1Value=rmtLapbCTManualT1Value, ieee8023PromiscuousReceiveStatus=ieee8023PromiscuousReceiveStatus, filterTable=filterTable, x25CCTCurrentTODControl=x25CCTCurrentTODControl, ieee8023MACAddress=ieee8023MACAddress, lan=lan, sourceQuenchLastRx=sourceQuenchLastRx, x25CSTCUGSub=x25CSTCUGSub, serialTxQueueSize=serialTxQueueSize, dcntIfTable=dcntIfTable, communityName=communityName, dcntRtngMsgTimerBCT1=dcntRtngMsgTimerBCT1, filteringDbTable=filteringDbTable, maxForwardedFrames=maxForwardedFrames, lanQueueSize=lanQueueSize, x25CCTCfgAutoConRetry=x25CCTCfgAutoConRetry, x25StatusSVCStatus=x25StatusSVCStatus, noRouteTotalDgms=noRouteTotalDgms, x25TTR22Limit=x25TTR22Limit, dcntAreaRITDestArea=dcntAreaRITDestArea, initStation=initStation, priorityTableEntryType=priorityTableEntryType, dcntAreaRITInterface=dcntAreaRITInterface, x25STSVCIndex=x25STSVCIndex, filterTableEntryType=filterTableEntryType, bridgeStatsIndex=bridgeStatsIndex, mlinkWindow=mlinkWindow, ieee8023Table=ieee8023Table, filteringDataBaseTable=filteringDataBaseTable, ieee8023ExcessiveCollisions=ieee8023ExcessiveCollisions, activeLocal=activeLocal, lapbCountCrcErrors=lapbCountCrcErrors, ieee8023NewMACAddressValue=ieee8023NewMACAddressValue, x25CST2WayLgclChanNum=x25CST2WayLgclChanNum, pathCostManualValue=pathCostManualValue, dcntInHdrErrors=dcntInHdrErrors, ieee8023OctetsReceivedOks=ieee8023OctetsReceivedOks, dcntAreaRITHops=dcntAreaRITHops, lapbAutoT1value=lapbAutoT1value, ieee8023outOfRangeLengthFields=ieee8023outOfRangeLengthFields, x25STTxClearReqPkts=x25STTxClearReqPkts, filterPage=filterPage, snmpAccessPolicyPage=snmpAccessPolicyPage, ipRSTable=ipRSTable, phySerIfInterfaceType=phySerIfInterfaceType, x25TTT20Timer=x25TTT20Timer, rmtLapbCTWindow=rmtLapbCTWindow, x25STTxResetReqPkts=x25STTxResetReqPkts, bootpRetryCount=bootpRetryCount, x25CSTRvrsChrgReq=x25CSTRvrsChrgReq, dcntRITHops=dcntRITHops, adaptiveMcastAddr=adaptiveMcastAddr, passWord=passWord, priorityTableEntry=priorityTableEntry, bootserverIpAddress=bootserverIpAddress, filterMatches=filterMatches, rmtLapbCTT3LinkIdleTimer=rmtLapbCTT3LinkIdleTimer, ipxIfDelay=ipxIfDelay, hiPriQueueUpperLimit=hiPriQueueUpperLimit, x25STRxRestartIndPkts=x25STRxRestartIndPkts, lapbCountSentFrames=lapbCountSentFrames, processorLoading=processorLoading, dcntOutDiscards=dcntOutDiscards, mlinkNumber=mlinkNumber, freeBufferCount=freeBufferCount, ipxIfNumber=ipxIfNumber, mlinkSendUpperEdge=mlinkSendUpperEdge, tftpRetryCount=tftpRetryCount, ipxRITHopCount=ipxRITHopCount, trapDestEntryType=trapDestEntryType, adaptiveRouting=adaptiveRouting, lapbCountSentOctets=lapbCountSentOctets, lapbLinkReset=lapbLinkReset, bridgeStatsTable=bridgeStatsTable, arAddressInfo=arAddressInfo, dcntRoutingTable=dcntRoutingTable, prioritySubTable=prioritySubTable, decnet=decnet, ieee8023TransmitStatus=ieee8023TransmitStatus, averageRejectedFrames=averageRejectedFrames, stationCountResets=stationCountResets, x25CCTCfgTODControl=x25CCTCfgTODControl, x25CSTDefaultPktSize=x25CSTDefaultPktSize, x25StatusPktSize=x25StatusPktSize, mlinkRcvUpperEdge=mlinkRcvUpperEdge, lanRejects=lanRejects, dcntReveivedDgms=dcntReveivedDgms, rmtLapbCTIndex=rmtLapbCTIndex, outDiscardsTotalDgms=outDiscardsTotalDgms, priorityTable=priorityTable, lapbTable=lapbTable, ipRSIndex=ipRSIndex, trapDestPage=trapDestPage, x25CCTTODToDisconnect=x25CCTTODToDisconnect, ieee8023MACSubLayerStatus=ieee8023MACSubLayerStatus, freeHeaderCount=freeHeaderCount, portPriorityManualValue=portPriorityManualValue, ipx=ipx, deleteAddressTimer=deleteAddressTimer, dcntRITNextHop=dcntRITNextHop) |
class StudentAssignmentService:
def __init__(self, student, AssignmentClass):
self.assignment = AssignmentClass()
self.assignment.student = student
self.attempts = 0
self.correct_attempts = 0
def check(self, code):
self.attempts += 1
result = self.assignment.check(code)
if result:
self.correct_attempts += 1
return result
def lesson(self):
return self.assignment.lesson()
| class Studentassignmentservice:
def __init__(self, student, AssignmentClass):
self.assignment = assignment_class()
self.assignment.student = student
self.attempts = 0
self.correct_attempts = 0
def check(self, code):
self.attempts += 1
result = self.assignment.check(code)
if result:
self.correct_attempts += 1
return result
def lesson(self):
return self.assignment.lesson() |
# get the dimension of the query location i.e. latitude and logitude
# raise an exception of the given query Id not found in the input file
def getDimensionsofQueryLoc(inputFile, queryLocId):
with open(inputFile) as infile:
header = infile.readline().strip()
headerIndex={ headerName.lower():index for index,headerName in enumerate(header.split(","))}
for line in infile:
values = line.strip().split(",")
if values[headerIndex["locid"]].lower()==queryLocId:
return float(values[headerIndex["latitude"]]),float(values[headerIndex["longitude"]]),values[headerIndex["category"]]
return None,None,None
# Calculate the euclidean distance between 2 points
def calculateDistance(x1, y1, x2, y2):
distance =((x2-x1)*(x2-x1) + (y2-y1)*(y2-y1))**0.5
return distance
# Calculate the standard deviation
def getStandardDeviation(distSorted, avg):
std = 0
for distance in distSorted:
std += (avg - distance)*(avg - distance)
std/=len(distSorted)
std=std**0.5
return std
# All the distances are round off to 4 decimal place at the end
def main(inputFile,queryLocId,d1,d2):
queryLocId=queryLocId.lower()
#get the dimensions of the given query location id
X1, Y1, category = getDimensionsofQueryLoc(inputFile, queryLocId)
category=category.lower()
if not X1:
print("Invalid location ID")
return [],[],[],[]
# calculate the cordinates of top right and bottom left corner of the rectangle formed
topRightX, topRightY = X1+d1, Y1+d2
bottomLeftX, bottomLeftY = X1-d1, Y1-d2
locList=[] # list of location falls inside the rectangle
simLocList=[] # list of locations with same category as given query location category
distSorted=[] # list containing distance of locations in ascending order with same location category
sumDistance=0 # sum of distances in distSorted list
with open(inputFile) as infile:
# next(infile) # skip the header row
header = infile.readline().strip()
headerIndex={ headerName.lower():index for index,headerName in enumerate(header.split(","))}
for line in infile:
values = line.strip().split(",")
if not (values[headerIndex["latitude"]] and values[headerIndex["longitude"]]):
continue
# get dimensions of the iterated location
X2, Y2 = float(values[headerIndex["latitude"]]), float(values[headerIndex["longitude"]])
#check if the iterated location is not same as query location and it falls under the defined rectangle
if values[headerIndex["locid"]].lower()!=queryLocId and X2<=topRightX and X2>=bottomLeftX and Y2<=topRightY and Y2>=bottomLeftY:
#add the location to loclist
locList.append(values[headerIndex["locid"]])
#if location category is same then
# 1. Add it to simList
# 2. Calculate its distance with query location and add it to distSorted list
# 3. Add its value to sumDistance (it will help in calculating the average distance)
if values[headerIndex["category"]].lower() == category:
simLocList.append(values[headerIndex["locid"]])
distance=calculateDistance(X1, Y1 ,X2, Y2)
distSorted.append(distance)
sumDistance += distance
if not distSorted:
return simLocList,[],[],[]
# calculate the average distance and the standard deviation of all the distances
avg = sumDistance/len(distSorted);
std = getStandardDeviation(distSorted, avg)
# sort the distance list and return the result
for i, dist in enumerate(distSorted):
distSorted[i] = round(dist,4)
return locList, simLocList, sorted(distSorted), [round(avg,4), round(std,4)]
| def get_dimensionsof_query_loc(inputFile, queryLocId):
with open(inputFile) as infile:
header = infile.readline().strip()
header_index = {headerName.lower(): index for (index, header_name) in enumerate(header.split(','))}
for line in infile:
values = line.strip().split(',')
if values[headerIndex['locid']].lower() == queryLocId:
return (float(values[headerIndex['latitude']]), float(values[headerIndex['longitude']]), values[headerIndex['category']])
return (None, None, None)
def calculate_distance(x1, y1, x2, y2):
distance = ((x2 - x1) * (x2 - x1) + (y2 - y1) * (y2 - y1)) ** 0.5
return distance
def get_standard_deviation(distSorted, avg):
std = 0
for distance in distSorted:
std += (avg - distance) * (avg - distance)
std /= len(distSorted)
std = std ** 0.5
return std
def main(inputFile, queryLocId, d1, d2):
query_loc_id = queryLocId.lower()
(x1, y1, category) = get_dimensionsof_query_loc(inputFile, queryLocId)
category = category.lower()
if not X1:
print('Invalid location ID')
return ([], [], [], [])
(top_right_x, top_right_y) = (X1 + d1, Y1 + d2)
(bottom_left_x, bottom_left_y) = (X1 - d1, Y1 - d2)
loc_list = []
sim_loc_list = []
dist_sorted = []
sum_distance = 0
with open(inputFile) as infile:
header = infile.readline().strip()
header_index = {headerName.lower(): index for (index, header_name) in enumerate(header.split(','))}
for line in infile:
values = line.strip().split(',')
if not (values[headerIndex['latitude']] and values[headerIndex['longitude']]):
continue
(x2, y2) = (float(values[headerIndex['latitude']]), float(values[headerIndex['longitude']]))
if values[headerIndex['locid']].lower() != queryLocId and X2 <= topRightX and (X2 >= bottomLeftX) and (Y2 <= topRightY) and (Y2 >= bottomLeftY):
locList.append(values[headerIndex['locid']])
if values[headerIndex['category']].lower() == category:
simLocList.append(values[headerIndex['locid']])
distance = calculate_distance(X1, Y1, X2, Y2)
distSorted.append(distance)
sum_distance += distance
if not distSorted:
return (simLocList, [], [], [])
avg = sumDistance / len(distSorted)
std = get_standard_deviation(distSorted, avg)
for (i, dist) in enumerate(distSorted):
distSorted[i] = round(dist, 4)
return (locList, simLocList, sorted(distSorted), [round(avg, 4), round(std, 4)]) |
n = int(input())
s = input().lower()
output = 'YES'
for letter in 'abcdefghijklmnopqrstuvwxyz':
if letter not in s:
output = 'NO'
break
print(output) | n = int(input())
s = input().lower()
output = 'YES'
for letter in 'abcdefghijklmnopqrstuvwxyz':
if letter not in s:
output = 'NO'
break
print(output) |
num1, num2 = 5,0
try:
quotient = num1/num2
message = "Quotient is" + ' ' + str(quotient)
where (quotient = num1/num2)
except ZeroDivisionError:
message = "Cannot divide by zero"
print(message)
| (num1, num2) = (5, 0)
try:
quotient = num1 / num2
message = 'Quotient is' + ' ' + str(quotient)
where(quotient=num1 / num2)
except ZeroDivisionError:
message = 'Cannot divide by zero'
print(message) |
'''
Created on 30-Oct-2017
@author: Gokulraj
'''
def mergesort(a,left,right):
if len(right)-len(left)<=1:
return(left)
elif right-left>1:
mid=(right+left)//2;
l=a[left:mid]
r=a[mid+1:right]
mergesort(a,l,r)
mergesort(a,l,r)
merge(a,l,r)
def merge(A,B):
(c,m,n)=([],len(A),len(B))
i,j=0,0
if i==m:
c.append(B[j])
j=j+1
elif A[i]<=B[j]:
c.append(A[i])
i=i+1
elif A[i]>B[j]:
c.append(B[j])
j=j+1
else:
c.append(A[i])
i=i+1
return(c)
a=[10,20,3,19,8,15,2,1]
left=0
right=len(a)-1
d=mergesort(a,left,right)
print(d)
| """
Created on 30-Oct-2017
@author: Gokulraj
"""
def mergesort(a, left, right):
if len(right) - len(left) <= 1:
return left
elif right - left > 1:
mid = (right + left) // 2
l = a[left:mid]
r = a[mid + 1:right]
mergesort(a, l, r)
mergesort(a, l, r)
merge(a, l, r)
def merge(A, B):
(c, m, n) = ([], len(A), len(B))
(i, j) = (0, 0)
if i == m:
c.append(B[j])
j = j + 1
elif A[i] <= B[j]:
c.append(A[i])
i = i + 1
elif A[i] > B[j]:
c.append(B[j])
j = j + 1
else:
c.append(A[i])
i = i + 1
return c
a = [10, 20, 3, 19, 8, 15, 2, 1]
left = 0
right = len(a) - 1
d = mergesort(a, left, right)
print(d) |
class UnknownTagFormat(Exception):
"""
occurs when a tag's contents violate expected format
"""
pass
class MalformedLine(Exception):
"""
occurs when an nbib line doesn't conform to the standard {Tag|spaces}-value format
"""
pass
| class Unknowntagformat(Exception):
"""
occurs when a tag's contents violate expected format
"""
pass
class Malformedline(Exception):
"""
occurs when an nbib line doesn't conform to the standard {Tag|spaces}-value format
"""
pass |
"""
keys for data from config.yml
"""
LIQUID = "Liquid"
INVEST = "Investment"
COLOR_NAME = "color_name"
COLOR_INDEX = "color_index"
ACCOUNTS = "accounts"
| """
keys for data from config.yml
"""
liquid = 'Liquid'
invest = 'Investment'
color_name = 'color_name'
color_index = 'color_index'
accounts = 'accounts' |
class Enum:
def __init__(self, name, value):
self.name = name
self.value = value
def __init_subclass__(cls):
cls._enum_names_ = {}
cls._enum_values_ = {}
for key, value in cls.__dict__.items():
if not key.startswith('_') and isinstance(value, cls._enum_type_):
enum = cls(key, value)
cls._enum_names_[key] = enum
cls._enum_values_[value] = enum
def __class_getitem__(cls, klass):
if isinstance(klass, type):
return type(cls.__name__, (cls,), {'_enum_type_': klass})
return klass
def __repr__(self):
return f'<{self.__class__.__name__} name={self.name}, value={self.value!r}>'
def __eq__(self, value):
if isinstance(value, self.__class__):
value = value.value
if not isinstance(value, self._enum_type_):
return NotImplemented
return self.value == value
def __ne__(self, value):
if isinstance(value, self.__class__):
value = value.value
if not isinstance(value, self._enum_type_):
return NotImplemented
return self.value != value
@classmethod
def try_enum(cls, value):
try:
return cls._enum_values_[value]
except KeyError:
return cls('undefined', value)
@classmethod
def try_value(cls, enum):
if isinstance(enum, cls):
return enum.value
elif isinstance(enum, cls._enum_type_):
return enum
raise ValueError(f'{enum!r} is not a valid {cls.__name__}')
class ChannelType(Enum[int]):
GUILD_TEXT = 0
DM = 1
GUILD_VOICE = 2
GROUP_DM = 3
GUILD_CATEGORY = 4
GUILD_NEWS = 5
GUILD_STORE = 6
GUILD_NEWS_THREAD = 10
GUILD_PUBLIC_THREAD = 11
GUILD_PRIVATE_THREAD = 12
GUILD_STAGE_VOICE = 13
class VideoQualityMode(Enum[int]):
AUTO = 1
FULL = 2
class EmbedType(Enum[str]):
RICH = 'rich'
IMAGE = 'image'
VIDEO = 'video'
GIFV = 'gifv'
ARTICLE = 'article'
LINK = 'link'
class MessageNotificationsLevel(Enum[int]):
ALL_MESSAGES = 0
ONLY_MENTIONS = 1
class ExplicitContentFilterLevel(Enum[int]):
DISABLED = 0
MEMBERS_WITHOUT_ROLES = 1
ALL_MEMBERS = 2
class MFALevel(Enum[int]):
NONE = 0
ELEVATED = 1
class VerificationLevel(Enum[int]):
NONE = 0
LOW = 1
MEDIUM = 2
HIGH = 3
VERY_HIGH = 4
class GuildNSFWLevel(Enum[int]):
DEFAULT = 0
EXPLICIT = 1
SAFE = 2
AGE_RESTRICTED = 3
class PremiumTier(Enum[int]):
NONE = 0
TIER_1 = 1
TIER_2 = 2
TIER_3 = 3
class GuildFeature(Enum[str]):
ANIMATED_ICON = 'ANIMATED_ICON'
BANNER = 'BANNER'
COMMERCE = 'COMMERCE'
COMMUNITY = 'COMMUNITY'
DISCOVERABLE = 'DISCOVERABLE'
FEATURABLE = 'FEATURABLE'
INVITE_SPLASH = 'INVITE_SPLASH'
MEMBER_VERIFIVATION_GATE_ENABLED = 'MEMBER_VEFIFICATION_GATE_ENNABLED'
NEWS = 'NEWS'
PARTNERED = 'PARTNERED'
PREVIEW_ENABLED = 'PREVIEW_ENABLED'
VANITY_URL = 'VANITY_URL'
VERIFIED = 'VERIFIED'
VIP_REGIONS = 'VIP_REGIONS'
WELCOME_SCREEN_ENABLED = 'WELCOME_SCREEN_ENABLED'
TICKETED_EVENTS_ENABLED = 'TICKETED_EVENTS_ENABLED'
MONETIZATION_ENABLED = 'MONETIZATION_ENABLED'
MORE_STICKERS = 'MORE_STICKERS'
class IntegrationType(Enum[str]):
TWITCH = 'twitch'
YOUTUBE = 'youtube'
DISCORD = 'discord'
class IntegrationExpireBehavior(Enum[int]):
REMOVE_ROLE = 0
KICK = 1
class InviteTargetType(Enum[int]):
STREAM = 1
EMBEDDED_APPLICATION = 2
class MessageType(Enum[int]):
DEFAULT = 0
RECIPIENT_ADD = 1
RECIPIENT_REMOVE = 2
CALL = 3
CHANNEL_NAME_CHANGE = 4
CHANNEL_ICON_CHANGE = 5
CHANNEL_PINNED_MESSAGE = 6
GUILD_MEMBER_JOIN = 7
USER_PERMIUM_GUILD_SUBSCRIPTION = 8
USER_PERMIUM_GUILD_SUBSCRIPTION_TIER_1 = 9
USER_PREMIUM_GUILD_SUBSCRIPTION_TIER_2 = 10
USER_PREMIUM_GUILD_SUBSCRIPTION_TIER_3 = 11
CHANNEL_FOLLOW_ADD = 12
GUILD_DISCOVERY_DISQUALIFIED = 14
GUILD_DISCOVERY_REQUALIFIED = 15
GUILD_DISCOVERY_GRACE_PERIOD_INITIAL_WARNING = 16
GUILD_DISCOVERY_GRACE_PERIOD_FINAL_WARNING = 17
THREAD_CREATED = 18
REPLY = 19
APPLICATION_COMMAND = 20
THREAD_STARTER_MESSAGE = 21
GUILD_INVITE_REMINDER = 22
class PermissionOverwriteType(Enum[int]):
ROLE = 0
MEMBER = 1
class StageInstancePrivacyLevel(Enum[int]):
PUBLIC = 1
GUILD_ONLY = 2
class PremiumType(Enum[int]):
NONE = 0
NITRO_CLASSIC = 1
NITRO = 2
class StickerType(Enum[int]):
STANDARD = 1
GUILD = 2
class StickerFormatType(Enum[int]):
PNG = 1
APNG = 2
LOTTIE = 3
class MessageActivityType(Enum[int]):
JOIN = 1
SPECTATE = 2
LISTEN = 3
JOIN_REQUEST = 5
class TeamMembershipState(Enum[int]):
INVITED = 1
ACCEPTED = 2
class WebhookType(Enum[int]):
INCOMING = 1
CHANNEL_FOLLOWER = 2
APPLICATION = 3
| class Enum:
def __init__(self, name, value):
self.name = name
self.value = value
def __init_subclass__(cls):
cls._enum_names_ = {}
cls._enum_values_ = {}
for (key, value) in cls.__dict__.items():
if not key.startswith('_') and isinstance(value, cls._enum_type_):
enum = cls(key, value)
cls._enum_names_[key] = enum
cls._enum_values_[value] = enum
def __class_getitem__(cls, klass):
if isinstance(klass, type):
return type(cls.__name__, (cls,), {'_enum_type_': klass})
return klass
def __repr__(self):
return f'<{self.__class__.__name__} name={self.name}, value={self.value!r}>'
def __eq__(self, value):
if isinstance(value, self.__class__):
value = value.value
if not isinstance(value, self._enum_type_):
return NotImplemented
return self.value == value
def __ne__(self, value):
if isinstance(value, self.__class__):
value = value.value
if not isinstance(value, self._enum_type_):
return NotImplemented
return self.value != value
@classmethod
def try_enum(cls, value):
try:
return cls._enum_values_[value]
except KeyError:
return cls('undefined', value)
@classmethod
def try_value(cls, enum):
if isinstance(enum, cls):
return enum.value
elif isinstance(enum, cls._enum_type_):
return enum
raise value_error(f'{enum!r} is not a valid {cls.__name__}')
class Channeltype(Enum[int]):
guild_text = 0
dm = 1
guild_voice = 2
group_dm = 3
guild_category = 4
guild_news = 5
guild_store = 6
guild_news_thread = 10
guild_public_thread = 11
guild_private_thread = 12
guild_stage_voice = 13
class Videoqualitymode(Enum[int]):
auto = 1
full = 2
class Embedtype(Enum[str]):
rich = 'rich'
image = 'image'
video = 'video'
gifv = 'gifv'
article = 'article'
link = 'link'
class Messagenotificationslevel(Enum[int]):
all_messages = 0
only_mentions = 1
class Explicitcontentfilterlevel(Enum[int]):
disabled = 0
members_without_roles = 1
all_members = 2
class Mfalevel(Enum[int]):
none = 0
elevated = 1
class Verificationlevel(Enum[int]):
none = 0
low = 1
medium = 2
high = 3
very_high = 4
class Guildnsfwlevel(Enum[int]):
default = 0
explicit = 1
safe = 2
age_restricted = 3
class Premiumtier(Enum[int]):
none = 0
tier_1 = 1
tier_2 = 2
tier_3 = 3
class Guildfeature(Enum[str]):
animated_icon = 'ANIMATED_ICON'
banner = 'BANNER'
commerce = 'COMMERCE'
community = 'COMMUNITY'
discoverable = 'DISCOVERABLE'
featurable = 'FEATURABLE'
invite_splash = 'INVITE_SPLASH'
member_verifivation_gate_enabled = 'MEMBER_VEFIFICATION_GATE_ENNABLED'
news = 'NEWS'
partnered = 'PARTNERED'
preview_enabled = 'PREVIEW_ENABLED'
vanity_url = 'VANITY_URL'
verified = 'VERIFIED'
vip_regions = 'VIP_REGIONS'
welcome_screen_enabled = 'WELCOME_SCREEN_ENABLED'
ticketed_events_enabled = 'TICKETED_EVENTS_ENABLED'
monetization_enabled = 'MONETIZATION_ENABLED'
more_stickers = 'MORE_STICKERS'
class Integrationtype(Enum[str]):
twitch = 'twitch'
youtube = 'youtube'
discord = 'discord'
class Integrationexpirebehavior(Enum[int]):
remove_role = 0
kick = 1
class Invitetargettype(Enum[int]):
stream = 1
embedded_application = 2
class Messagetype(Enum[int]):
default = 0
recipient_add = 1
recipient_remove = 2
call = 3
channel_name_change = 4
channel_icon_change = 5
channel_pinned_message = 6
guild_member_join = 7
user_permium_guild_subscription = 8
user_permium_guild_subscription_tier_1 = 9
user_premium_guild_subscription_tier_2 = 10
user_premium_guild_subscription_tier_3 = 11
channel_follow_add = 12
guild_discovery_disqualified = 14
guild_discovery_requalified = 15
guild_discovery_grace_period_initial_warning = 16
guild_discovery_grace_period_final_warning = 17
thread_created = 18
reply = 19
application_command = 20
thread_starter_message = 21
guild_invite_reminder = 22
class Permissionoverwritetype(Enum[int]):
role = 0
member = 1
class Stageinstanceprivacylevel(Enum[int]):
public = 1
guild_only = 2
class Premiumtype(Enum[int]):
none = 0
nitro_classic = 1
nitro = 2
class Stickertype(Enum[int]):
standard = 1
guild = 2
class Stickerformattype(Enum[int]):
png = 1
apng = 2
lottie = 3
class Messageactivitytype(Enum[int]):
join = 1
spectate = 2
listen = 3
join_request = 5
class Teammembershipstate(Enum[int]):
invited = 1
accepted = 2
class Webhooktype(Enum[int]):
incoming = 1
channel_follower = 2
application = 3 |
# config.sample.py
# Rename this file to config.py before running this application and change the database values below
# LED GPIO Pin numbers - these are the default values, feel free to change them as needed
LED_PINS = {
'green': 12,
'yellow': 25,
'red': 18
}
EMAIL_CONFIG = {
'username': '<USERNAME>',
'password': '<PASSWORD>',
'smtpServer': 'smtp.gmail.com',
'port': 465,
'sender': 'Email of who will send it',
'recipient': 'Email of who will receive it'
}
DATABASE_CONFIG = {
'host' : 'localhost',
'dbname' : 'uptime',
'dbuser' : 'DATABASE_USER',
'dbpass' : 'DATABASE_PASSWORD'
}
| led_pins = {'green': 12, 'yellow': 25, 'red': 18}
email_config = {'username': '<USERNAME>', 'password': '<PASSWORD>', 'smtpServer': 'smtp.gmail.com', 'port': 465, 'sender': 'Email of who will send it', 'recipient': 'Email of who will receive it'}
database_config = {'host': 'localhost', 'dbname': 'uptime', 'dbuser': 'DATABASE_USER', 'dbpass': 'DATABASE_PASSWORD'} |
def selection_sort(A: list):
for i in range(len(A) - 1):
smallest_index = i
for j in range(i + 1, len(A)):
if A[i] > A[j]:
smallest_index = j
A[i], A[smallest_index] = A[smallest_index], A[i]
A = [4, 2, 1, 5, 62, 5]
B = [3, 3, 2, 4, 6, 65, 8, 5]
C = [5, 4, 3, 2, 1]
D = [1, 2, 3, 4, 5]
selection_sort(A)
selection_sort(B)
selection_sort(C)
selection_sort(D)
print(A, B, C, D)
| def selection_sort(A: list):
for i in range(len(A) - 1):
smallest_index = i
for j in range(i + 1, len(A)):
if A[i] > A[j]:
smallest_index = j
(A[i], A[smallest_index]) = (A[smallest_index], A[i])
a = [4, 2, 1, 5, 62, 5]
b = [3, 3, 2, 4, 6, 65, 8, 5]
c = [5, 4, 3, 2, 1]
d = [1, 2, 3, 4, 5]
selection_sort(A)
selection_sort(B)
selection_sort(C)
selection_sort(D)
print(A, B, C, D) |
inventory = [
{"name": "apples", "quantity": 2},
{"name": "bananas", "quantity": 0},
{"name": "cherries", "quantity": 5},
{"name": "oranges", "quantity": 10},
{"name": "berries", "quantity": 7},
]
def checkIfFruitPresent(foodlist: list, target: str):
# Check if the name is present ins the list or not
print(f"We keep {target} inventory") if target in list(
map(lambda x: x["name"], foodlist)
) else print(f"We dont keep {target} at our store")
def checkIfFruitInStock(foodlist: list, target: str):
# First check if the fruit is present in the list
if target in list(map(lambda x: x["name"], foodlist)):
# If fruit is present then check if the quantity of the fruit is greater than 0
print(f"{target} is in stock") if list(
filter(lambda fruit: fruit["name"] == target, foodlist)
)[0]["quantity"] > 0 else print(f"{target} is out of stock")
else:
print(f"We dont keep {target} at our store")
checkIfFruitPresent(inventory, "apples")
checkIfFruitInStock(inventory, "apples")
checkIfFruitInStock(inventory, "bananas")
checkIfFruitInStock(inventory, "tomatoes")
| inventory = [{'name': 'apples', 'quantity': 2}, {'name': 'bananas', 'quantity': 0}, {'name': 'cherries', 'quantity': 5}, {'name': 'oranges', 'quantity': 10}, {'name': 'berries', 'quantity': 7}]
def check_if_fruit_present(foodlist: list, target: str):
print(f'We keep {target} inventory') if target in list(map(lambda x: x['name'], foodlist)) else print(f'We dont keep {target} at our store')
def check_if_fruit_in_stock(foodlist: list, target: str):
if target in list(map(lambda x: x['name'], foodlist)):
print(f'{target} is in stock') if list(filter(lambda fruit: fruit['name'] == target, foodlist))[0]['quantity'] > 0 else print(f'{target} is out of stock')
else:
print(f'We dont keep {target} at our store')
check_if_fruit_present(inventory, 'apples')
check_if_fruit_in_stock(inventory, 'apples')
check_if_fruit_in_stock(inventory, 'bananas')
check_if_fruit_in_stock(inventory, 'tomatoes') |
"""
A Trie is a special data structure used to store strings that can be visualized like a graph. It consists of nodes and edges.
Each node consists of at max 26 children and edges connect each parent node to its children.
These 26 pointers are nothing but pointers for each of the 26 letters of the English alphabet A separate edge is maintained for every edge.
Strings are stored in a top to bottom manner on the basis of their prefix in a trie. All prefixes of length 1 are stored at until level 1,
all prefixes of length 2 are sorted at until level 2 and so on.
Now, one would be wondering why to use a data structure such as a trie for processing a single string? Actually, Tries are generally used on groups of strings,
rather than a single string. When given multiple strings , we can solve a variety of problems based on them. For example, consider an English dictionary and a
single string , find the prefix of maximum length from the dictionary strings matching the string . Solving this problem using a naive approach would require us
to match the prefix of the given string with the prefix of every other word in the dictionary and note the maximum. The is an expensive process considering the
amount of time it would take. Tries can solve this problem in much more efficient way.
Before processing each Query of the type where we need to search the length of the longest prefix, we first need to add all the existing words into the dictionary.
A Trie consists of a special node called the root node. This node doesn't have any incoming edges. It only contains 26 outgoing edfes for each letter in the
alphabet and is the root of the Trie.
So, the insertion of any string into a Trie starts from the root node. All prefixes of length one are direct children of the root node.
In addition, all prefixes of length 2 become children of the nodes existing at level one.
"""
class Trie:
def __init__(self):
self.dic = {}
def insert(self, word):
cur = self.dic
for c in word:
if c not in cur:
cur[c] = {}
cur = cur[c]
cur['end'] = {}
def search(self, word):
cur = self.dic
for c in word:
if c in cur:
cur = cur[c]
else:
return False
if 'end' in cur:
return True
return False
def startsWith(self, prefix):
cur = self.dic
for c in prefix:
if c in cur:
cur = cur[c]
else:
return False
return True
obj = Trie() # Creating object of Trie Class
obj.insert("hello") # Insert "hello" into Trie
obj.insert("hi") # Insert "hi" into Trie
obj.insert("hey") # Insert "hey" into Trie
print(obj.search("hi")) # return True
print(obj.startsWith("he")) # return True
print(obj.startsWith("heyy")) # return False | """
A Trie is a special data structure used to store strings that can be visualized like a graph. It consists of nodes and edges.
Each node consists of at max 26 children and edges connect each parent node to its children.
These 26 pointers are nothing but pointers for each of the 26 letters of the English alphabet A separate edge is maintained for every edge.
Strings are stored in a top to bottom manner on the basis of their prefix in a trie. All prefixes of length 1 are stored at until level 1,
all prefixes of length 2 are sorted at until level 2 and so on.
Now, one would be wondering why to use a data structure such as a trie for processing a single string? Actually, Tries are generally used on groups of strings,
rather than a single string. When given multiple strings , we can solve a variety of problems based on them. For example, consider an English dictionary and a
single string , find the prefix of maximum length from the dictionary strings matching the string . Solving this problem using a naive approach would require us
to match the prefix of the given string with the prefix of every other word in the dictionary and note the maximum. The is an expensive process considering the
amount of time it would take. Tries can solve this problem in much more efficient way.
Before processing each Query of the type where we need to search the length of the longest prefix, we first need to add all the existing words into the dictionary.
A Trie consists of a special node called the root node. This node doesn't have any incoming edges. It only contains 26 outgoing edfes for each letter in the
alphabet and is the root of the Trie.
So, the insertion of any string into a Trie starts from the root node. All prefixes of length one are direct children of the root node.
In addition, all prefixes of length 2 become children of the nodes existing at level one.
"""
class Trie:
def __init__(self):
self.dic = {}
def insert(self, word):
cur = self.dic
for c in word:
if c not in cur:
cur[c] = {}
cur = cur[c]
cur['end'] = {}
def search(self, word):
cur = self.dic
for c in word:
if c in cur:
cur = cur[c]
else:
return False
if 'end' in cur:
return True
return False
def starts_with(self, prefix):
cur = self.dic
for c in prefix:
if c in cur:
cur = cur[c]
else:
return False
return True
obj = trie()
obj.insert('hello')
obj.insert('hi')
obj.insert('hey')
print(obj.search('hi'))
print(obj.startsWith('he'))
print(obj.startsWith('heyy')) |
# The goal is divide a bill
print("Let's go divide the bill in Brazil. Insert the values and insert '0' for finish")
sum = 0
valor = 1
while valor != 0:
valor = float(input('Enter the value here in R$: '))
sum = sum + valor
p = float(input('Enter the number of payers: '))
print(input('The total was R$ {}. Getting R$ {:.2f} for each person'.format(sum, (sum / p))))
| print("Let's go divide the bill in Brazil. Insert the values and insert '0' for finish")
sum = 0
valor = 1
while valor != 0:
valor = float(input('Enter the value here in R$: '))
sum = sum + valor
p = float(input('Enter the number of payers: '))
print(input('The total was R$ {}. Getting R$ {:.2f} for each person'.format(sum, sum / p))) |
#SearchEmployeeScreen
BACK_BUTTON_TEXT = u"Back"
CODE_TEXT = u"Code"
DEPARTMENT_TEXT = u"Department"
DOB_TEXT = u"DOB"
DROPDOWN_DEPARTMENT_TEXT = u"Department"
DROPDOWN_DOB_TEXT = u"DOB"
DROPDOWN_EMPCODE_TEXT = u"Employee Code"
DROPDOWN_NAME_TEXT = u"Name"
DROPDOWN_SALARY_TEXT = u"Salary"
GENDER_TEXT = u"Gender"
HELP_OPTION_TEXT = u"Here you can search for employee records by field."
NAME_TEXT = u"Name"
NO_EMP_RECORDS_TEXT = u"There are no employee records."
REGISTER_BUTTON_TEXT = u"Create Account"
SALARY_TEXT = u"Salary"
SEARCH_BUTTON_TEXT = u"Search"
SEARCH_BY_TEXT = u"Search By: "
SEARCH_EMP_SCREEN_NONETYPE_ERROR_TEXT = u"Please enter Search Criteria."
SEARCH_FOR_TEXT = u"Search For: "
SEARCH_FOR_EMPLOYEES_TEXT = u"Search for Employees : "
SPACE_TEXT = u"------------------------"
| back_button_text = u'Back'
code_text = u'Code'
department_text = u'Department'
dob_text = u'DOB'
dropdown_department_text = u'Department'
dropdown_dob_text = u'DOB'
dropdown_empcode_text = u'Employee Code'
dropdown_name_text = u'Name'
dropdown_salary_text = u'Salary'
gender_text = u'Gender'
help_option_text = u'Here you can search for employee records by field.'
name_text = u'Name'
no_emp_records_text = u'There are no employee records.'
register_button_text = u'Create Account'
salary_text = u'Salary'
search_button_text = u'Search'
search_by_text = u'Search By: '
search_emp_screen_nonetype_error_text = u'Please enter Search Criteria.'
search_for_text = u'Search For: '
search_for_employees_text = u'Search for Employees : '
space_text = u'------------------------' |
print ("Pythagorean Triplets with smaller side upto 10 -->")
# form : (m^2 - n^2, 2*m*n, m^2 + n^2)
# generate all (m, n) pairs such that m^2 - n^2 <= 10
# if we take (m > n), for m >= 6, m^2 - n^2 will always be greater than 10
# so m ranges from 1 to 5 and n ranges from 1 to m-1
pythTriplets = [(m*m - n*n, 2*m*n, m*m + n*n) for (m,n) in [(x, y) for x in range (1, 6) for y in range (1, x)] if m*m - n*n <= 10]
print (pythTriplets) | print('Pythagorean Triplets with smaller side upto 10 -->')
pyth_triplets = [(m * m - n * n, 2 * m * n, m * m + n * n) for (m, n) in [(x, y) for x in range(1, 6) for y in range(1, x)] if m * m - n * n <= 10]
print(pythTriplets) |
print("What is your name?")
name = input()
print("How old are you?")
age = int(input())
print("Where do you live?")
residency = input()
print("This is `{0}` \nIt is `{1}` \n(S)he live in `{2}` ".format(name, age, residency))
| print('What is your name?')
name = input()
print('How old are you?')
age = int(input())
print('Where do you live?')
residency = input()
print('This is `{0}` \nIt is `{1}` \n(S)he live in `{2}` '.format(name, age, residency)) |
#!/usr/bin/env python3
class TypeCacher():
def __init__(self):
self.cached_types = {}
self.num_cached_types = 0
def get_cached_type_str(self, type_str):
if type_str in self.cached_types:
cached_type_str = 'cached_type_%d' % self.cached_types[type_str]
else:
cached_type_str = 'cached_type_%d' % self.num_cached_types
self.cached_types[type_str] = self.num_cached_types
self.num_cached_types += 1
return cached_type_str
def dump_to_file(self, path):
with open(path, 'w') as output:
output.write('// Generated file, please do not edit directly\n\n')
for cached_type, val in self.cached_types.items():
type_id_str = cached_type.split(' ')[0]
s = 'static %s cached_type_%d = %s;\n' % (type_id_str, val, cached_type)
output.write(s)
type_cacher = TypeCacher()
class CodeGenerator():
def __init__(self, path, vector_element_name, enclose_element_with, rw):
self.file = open(path, 'w')
self.write_header()
self.vector_element_name = vector_element_name
self.enclose_element_with = enclose_element_with
self.rw = rw
# if you do not exclude these, when you run code like `Architecture['x86_64']`,
# if will create integer of size 576
self.excluded_intrinsics = [
'INTRINSIC_XED_IFORM_XSAVE_MEMmxsave',
'INTRINSIC_XED_IFORM_XSAVE64_MEMmxsave',
'INTRINSIC_XED_IFORM_XSAVEOPT_MEMmxsave',
'INTRINSIC_XED_IFORM_XSAVEOPT64_MEMmxsave',
'INTRINSIC_XED_IFORM_XSAVES_MEMmxsave',
'INTRINSIC_XED_IFORM_XSAVES64_MEMmxsave',
'INTRINSIC_XED_IFORM_XSAVEC_MEMmxsave',
'INTRINSIC_XED_IFORM_XSAVEC64_MEMmxsave',
'INTRINSIC_XED_IFORM_XRSTOR_MEMmxsave',
'INTRINSIC_XED_IFORM_XRSTOR64_MEMmxsave',
'INTRINSIC_XED_IFORM_XRSTORS_MEMmxsave',
'INTRINSIC_XED_IFORM_XRSTORS64_MEMmxsave',
]
def clean_up(self):
self.file.close()
def write_header(self):
self.file.write('// Generated file, please do not edit directly\n\n')
def generate_intrinsic(self, ins):
global type_cacher
if ins.iform in self.excluded_intrinsics:
return
s = 'case %s:' % ins.iform
s += '\n\treturn '
return_str = 'vector<%s> ' % self.vector_element_name
return_str += '{ '
for operand in ins.operands:
if not self.rw in operand.rw:
continue
op_str = operand.generate_str()
# cached_op_str = type_cacher.get_cached_type_str(op_str)
if self.enclose_element_with == '':
return_str += '%s, ' % op_str
else:
return_str += '%s(%s), ' % (self.enclose_element_with, op_str)
if return_str.endswith(', '):
return_str = return_str[:-2]
return_str += ' }'
return_str = type_cacher.get_cached_type_str(return_str)
s += return_str
s += ';\n'
self.file.write(s)
class Intrinsic():
def __init__(self):
self.iform = ''
self.operands = []
self.vl = None
def reset(self):
self.iform = ''
self.operands = []
self.vl = None
def set_iform(self, iform):
self.iform = iform
def set_VL(self, vl):
self.vl = vl
def add_operand(self, operand):
if operand.oc2 == 'vv':
if self.vl is None:
print('cannot determine number of elements')
# more info goes here
else:
operand.oc2 = self.vl
operand.parse()
self.operands.append(operand)
class Operand():
def __init__(self, xtype, rw, oc2):
self.xtype = xtype
self.rw = rw
self.oc2 = oc2
def parse(self):
# from build/obj/dgen/all-element-types.txt
# #XTYPE TYPE BITS-PER-ELEM
# #
# var VARIABLE 0 # instruction must set NELEM and ELEMENT_SIZE
# struct STRUCT 0 # many elements of different widths
# int INT 0 # one element, all the bits, width varies
# uint UINT 0 # one element, all the bits, width varies
# #
# i1 INT 1
# i8 INT 8
# i16 INT 16
# i32 INT 32
# i64 INT 64
# u8 UINT 8
# u16 UINT 16
# u32 UINT 32
# u64 UINT 64
# u128 UINT 128
# u256 UINT 256
# f32 SINGLE 32
# f64 DOUBLE 64
# f80 LONGDOUBLE 80
# b80 LONGBCD 80
self.signed = (self.xtype[0] == 'i')
if self.xtype[0] == 'f':
self.type = 'float'
elif self.xtype == 'i1':
self.type = 'boolean'
else:
self.type = 'int'
# thse lengths are obtained from A.2.2 Codes for Operand Type
# of the Intel Dev Manual Volume 2
# See comment inside for varying sizes
size_mapping = {
'f80': 80,
'mem32real': 32,
'mem64real': 64,
'mem80real': 80,
'm32real': 32,
'm32int': 32,
'm64real': 64,
'm64int': 32,
'm80real': 80,
'mskw': 1,
'mem14': 14 * 8,
'mem28': 28 * 8,
'mem16': 16 * 8,
'mem94': 94 * 8,
'mem108': 108 * 8,
'mem32int': 32,
'mem16int': 16,
"mem80dec": 80,
'b': 8,
'w': 16,
'd': 32,
'q': 64,
'u64': 64,
'dq': 128,
'qq': 256,
'zd': 512,
'zu8': 512,
'zi8': 512,
'zi16': 512,
'zu16': 512,
'zuf64': 512,
'zuf32': 512,
'zf32': 512,
'zf64': 512,
'zi64': 512,
'zu64': 512,
'zu128': 512,
'zi32': 512,
'zu32': 512,
'VL512': 512,
'VL256': 256,
'VL128': 128,
'ss': 128,
'sd': 128,
'ps': 128,
'pd': 128,
'zbf16': 16,
's': 80,
's64': 64,
'a16': 16,
'a32': 32,
'xud': 128,
'xuq': 128,
# The specifiers below actually map to variable sizes, e.g., v can be
# "Word, doubleword or quadword (in 64-bit mode), depending on operand-size attribute".
# However, instructions that contain such operands are mostly covered by explicit liftings,
# for example, add, sub, and mov, etc. So they do not mess up the types
# Excpetions are lzcnt, tzcnt, popcnt, and crc32,
# which have to be further splitted into various finer-grained intrinsics
'v': 32,
'z': 32,
'y': 64,
# below specifiers are not found in the list, their size are determined manually
'spw': 32,
'spw8': 32,
'spw2': 32,
'spw3': 32,
'spw5': 32,
'wrd': 16,
'bnd32': 32,
'bnd64': 64,
'p': 64,
'p2': 64,
'mfpxenv': 512 * 8,
'mxsave': 576 * 8,
'mprefetch': 64,
'pmmsz16': 14 * 8,
'pmmsz32': 24 * 8,
'rFLAGS': 64,
'eFLAGS': 32,
'GPR64_R': 64,
'GPR64_B': 64,
'GPRv_R': 64,
'GPRv_B': 64,
'GPR32_R': 32,
'GPR32_B': 32,
'GPR16_R': 16,
'GPR16_B': 16,
'GPR8_R': 8,
'GPR8_B': 8,
'GPRy_B': 64,
'GPRz_B': 64,
'GPRz_R': 64,
'GPR8_SB': 64,
'A_GPR_R': 64,
'A_GPR_B': 64,
'GPRv_SB': 64,
'BND_R': 64,
'BND_B': 64,
'OeAX': 16,
'OrAX': 16,
'OrBX': 16,
'OrCX': 16,
'OrDX': 16,
'OrBP': 16,
'OrSP': 16,
'ArAX': 16,
'ArBX': 16,
'ArCX': 16,
'ArDI': 16,
'ArSI': 16,
'ArBP': 16,
'FINAL_SSEG0': 16,
'FINAL_SSEG1': 16,
'FINAL_DSEG': 16,
'FINAL_DSEG0': 16,
'FINAL_DSEG1': 16,
'FINAL_ESEG': 16,
'FINAL_ESEG1': 16,
'SEG': 16,
'SEG_MOV': 16,
'SrSP': 64,
'rIP': 64,
'CR_R': 32,
'DR_R': 32,
'XED_REG_AL': 8,
'XED_REG_AH': 8,
'XED_REG_BL': 8,
'XED_REG_BH': 8,
'XED_REG_CL': 8,
'XED_REG_DL': 8,
'XED_REG_AX': 16,
'XED_REG_BX': 16,
'XED_REG_CX': 16,
'XED_REG_DX': 16,
'XED_REG_BP': 16,
'XED_REG_SP': 16,
'XED_REG_SI': 16,
'XED_REG_DI': 16,
'XED_REG_SS': 16,
'XED_REG_DS': 16,
'XED_REG_ES': 16,
'XED_REG_IP': 16,
'XED_REG_FS': 16,
'XED_REG_GS': 16,
'XED_REG_CS': 16,
'XED_REG_EAX': 32,
'XED_REG_EBX': 32,
'XED_REG_ECX': 32,
'XED_REG_EDX': 32,
'XED_REG_EIP': 32,
'XED_REG_ESP': 32,
'XED_REG_EBP': 32,
'XED_REG_ESI': 32,
'XED_REG_EDI': 32,
'XED_REG_RAX': 64,
'XED_REG_RBX': 64,
'XED_REG_RCX': 64,
'XED_REG_RDX': 64,
'XED_REG_RIP': 64,
'XED_REG_RSP': 64,
'XED_REG_RBP': 64,
'XED_REG_RSI': 64,
'XED_REG_RDI': 64,
'XED_REG_R11': 64,
'XED_REG_X87STATUS': 16,
'XED_REG_X87CONTROL': 16,
'XED_REG_X87TAG': 16,
'XED_REG_X87PUSH': 64,
'XED_REG_X87POP': 64,
'XED_REG_X87POP2': 64,
'XED_REG_CR0': 64,
'XED_REG_XCR0': 64,
'XED_REG_MXCSR': 32,
'XED_REG_GDTR': 48,
'XED_REG_LDTR': 48,
'XED_REG_IDTR': 48,
'XED_REG_TR': 64,
'XED_REG_TSC': 64,
'XED_REG_TSCAUX': 64,
'XED_REG_MSRS': 64,
}
# if '_' in self.oc2:
# self.oc2 = self.oc2.split('_')[0]
try:
self.width = size_mapping[self.oc2]
except:
print('I do not know the width of oc2: %s' % self.oc2)
self.width = 8
if self.xtype == 'struct' or self.xtype == 'INVALID':
self.element_size = self.width
elif self.xtype == 'int':
self.element_size = 32
elif self.xtype == 'bf16':
self.element_size = 16
else:
size_str = self.xtype[1:]
self.element_size = int(size_str)
self.element_size_byte = int((self.element_size + 7) / 8)
n = int((self.width + 7) / 8) / self.element_size_byte
n = int(n)
if n < 1:
n = 1
self.n_element = n
def generate_str(self):
array = False
if self.element_size > 1:
array = True
inner_str = ''
if self.type == 'float':
inner_str = 'Type::FloatType(%d)' % self.element_size_byte
elif self.type == 'int':
signed_str = 'true' if self.signed else 'false'
inner_str = 'Type::IntegerType(%d, %s)' % (self.element_size_byte, signed_str)
else:
inner_str = 'Type::BoolType()'
if self.n_element > 1:
s = 'Type::ArrayType(%s, %d)' % (inner_str, self.n_element)
else:
s = inner_str
return s
def main():
intrinsic_input = CodeGenerator('../x86_intrinsic_input_type.include', 'NameAndType', 'NameAndType', 'r')
intrinsic_output = CodeGenerator('../x86_intrinsic_output_type.include', 'Confidence<Ref<Type>>', '', 'w')
with open('iform-type-dump.txt', 'r') as f:
ins = Intrinsic()
for line in f:
if line.strip() == '':
intrinsic_input.generate_intrinsic(ins)
intrinsic_output.generate_intrinsic(ins)
ins.reset()
continue
if line.startswith('INTRINSIC_XED_IFORM_'):
ins.set_iform(line.strip())
elif line.startswith('VL'):
ins.set_VL(line.strip())
elif line.startswith('\t'):
fields = line.strip().split('\t')
op = Operand(fields[0], fields[1], fields[2])
ins.add_operand(op)
else:
print('unexpected line! I do not know what to do with it')
print(line)
intrinsic_input.clean_up()
intrinsic_output.clean_up()
type_cacher.dump_to_file('../x86_intrinsic_cached_types.include')
if __name__ == '__main__':
main() | class Typecacher:
def __init__(self):
self.cached_types = {}
self.num_cached_types = 0
def get_cached_type_str(self, type_str):
if type_str in self.cached_types:
cached_type_str = 'cached_type_%d' % self.cached_types[type_str]
else:
cached_type_str = 'cached_type_%d' % self.num_cached_types
self.cached_types[type_str] = self.num_cached_types
self.num_cached_types += 1
return cached_type_str
def dump_to_file(self, path):
with open(path, 'w') as output:
output.write('// Generated file, please do not edit directly\n\n')
for (cached_type, val) in self.cached_types.items():
type_id_str = cached_type.split(' ')[0]
s = 'static %s cached_type_%d = %s;\n' % (type_id_str, val, cached_type)
output.write(s)
type_cacher = type_cacher()
class Codegenerator:
def __init__(self, path, vector_element_name, enclose_element_with, rw):
self.file = open(path, 'w')
self.write_header()
self.vector_element_name = vector_element_name
self.enclose_element_with = enclose_element_with
self.rw = rw
self.excluded_intrinsics = ['INTRINSIC_XED_IFORM_XSAVE_MEMmxsave', 'INTRINSIC_XED_IFORM_XSAVE64_MEMmxsave', 'INTRINSIC_XED_IFORM_XSAVEOPT_MEMmxsave', 'INTRINSIC_XED_IFORM_XSAVEOPT64_MEMmxsave', 'INTRINSIC_XED_IFORM_XSAVES_MEMmxsave', 'INTRINSIC_XED_IFORM_XSAVES64_MEMmxsave', 'INTRINSIC_XED_IFORM_XSAVEC_MEMmxsave', 'INTRINSIC_XED_IFORM_XSAVEC64_MEMmxsave', 'INTRINSIC_XED_IFORM_XRSTOR_MEMmxsave', 'INTRINSIC_XED_IFORM_XRSTOR64_MEMmxsave', 'INTRINSIC_XED_IFORM_XRSTORS_MEMmxsave', 'INTRINSIC_XED_IFORM_XRSTORS64_MEMmxsave']
def clean_up(self):
self.file.close()
def write_header(self):
self.file.write('// Generated file, please do not edit directly\n\n')
def generate_intrinsic(self, ins):
global type_cacher
if ins.iform in self.excluded_intrinsics:
return
s = 'case %s:' % ins.iform
s += '\n\treturn '
return_str = 'vector<%s> ' % self.vector_element_name
return_str += '{ '
for operand in ins.operands:
if not self.rw in operand.rw:
continue
op_str = operand.generate_str()
if self.enclose_element_with == '':
return_str += '%s, ' % op_str
else:
return_str += '%s(%s), ' % (self.enclose_element_with, op_str)
if return_str.endswith(', '):
return_str = return_str[:-2]
return_str += ' }'
return_str = type_cacher.get_cached_type_str(return_str)
s += return_str
s += ';\n'
self.file.write(s)
class Intrinsic:
def __init__(self):
self.iform = ''
self.operands = []
self.vl = None
def reset(self):
self.iform = ''
self.operands = []
self.vl = None
def set_iform(self, iform):
self.iform = iform
def set_vl(self, vl):
self.vl = vl
def add_operand(self, operand):
if operand.oc2 == 'vv':
if self.vl is None:
print('cannot determine number of elements')
else:
operand.oc2 = self.vl
operand.parse()
self.operands.append(operand)
class Operand:
def __init__(self, xtype, rw, oc2):
self.xtype = xtype
self.rw = rw
self.oc2 = oc2
def parse(self):
self.signed = self.xtype[0] == 'i'
if self.xtype[0] == 'f':
self.type = 'float'
elif self.xtype == 'i1':
self.type = 'boolean'
else:
self.type = 'int'
size_mapping = {'f80': 80, 'mem32real': 32, 'mem64real': 64, 'mem80real': 80, 'm32real': 32, 'm32int': 32, 'm64real': 64, 'm64int': 32, 'm80real': 80, 'mskw': 1, 'mem14': 14 * 8, 'mem28': 28 * 8, 'mem16': 16 * 8, 'mem94': 94 * 8, 'mem108': 108 * 8, 'mem32int': 32, 'mem16int': 16, 'mem80dec': 80, 'b': 8, 'w': 16, 'd': 32, 'q': 64, 'u64': 64, 'dq': 128, 'qq': 256, 'zd': 512, 'zu8': 512, 'zi8': 512, 'zi16': 512, 'zu16': 512, 'zuf64': 512, 'zuf32': 512, 'zf32': 512, 'zf64': 512, 'zi64': 512, 'zu64': 512, 'zu128': 512, 'zi32': 512, 'zu32': 512, 'VL512': 512, 'VL256': 256, 'VL128': 128, 'ss': 128, 'sd': 128, 'ps': 128, 'pd': 128, 'zbf16': 16, 's': 80, 's64': 64, 'a16': 16, 'a32': 32, 'xud': 128, 'xuq': 128, 'v': 32, 'z': 32, 'y': 64, 'spw': 32, 'spw8': 32, 'spw2': 32, 'spw3': 32, 'spw5': 32, 'wrd': 16, 'bnd32': 32, 'bnd64': 64, 'p': 64, 'p2': 64, 'mfpxenv': 512 * 8, 'mxsave': 576 * 8, 'mprefetch': 64, 'pmmsz16': 14 * 8, 'pmmsz32': 24 * 8, 'rFLAGS': 64, 'eFLAGS': 32, 'GPR64_R': 64, 'GPR64_B': 64, 'GPRv_R': 64, 'GPRv_B': 64, 'GPR32_R': 32, 'GPR32_B': 32, 'GPR16_R': 16, 'GPR16_B': 16, 'GPR8_R': 8, 'GPR8_B': 8, 'GPRy_B': 64, 'GPRz_B': 64, 'GPRz_R': 64, 'GPR8_SB': 64, 'A_GPR_R': 64, 'A_GPR_B': 64, 'GPRv_SB': 64, 'BND_R': 64, 'BND_B': 64, 'OeAX': 16, 'OrAX': 16, 'OrBX': 16, 'OrCX': 16, 'OrDX': 16, 'OrBP': 16, 'OrSP': 16, 'ArAX': 16, 'ArBX': 16, 'ArCX': 16, 'ArDI': 16, 'ArSI': 16, 'ArBP': 16, 'FINAL_SSEG0': 16, 'FINAL_SSEG1': 16, 'FINAL_DSEG': 16, 'FINAL_DSEG0': 16, 'FINAL_DSEG1': 16, 'FINAL_ESEG': 16, 'FINAL_ESEG1': 16, 'SEG': 16, 'SEG_MOV': 16, 'SrSP': 64, 'rIP': 64, 'CR_R': 32, 'DR_R': 32, 'XED_REG_AL': 8, 'XED_REG_AH': 8, 'XED_REG_BL': 8, 'XED_REG_BH': 8, 'XED_REG_CL': 8, 'XED_REG_DL': 8, 'XED_REG_AX': 16, 'XED_REG_BX': 16, 'XED_REG_CX': 16, 'XED_REG_DX': 16, 'XED_REG_BP': 16, 'XED_REG_SP': 16, 'XED_REG_SI': 16, 'XED_REG_DI': 16, 'XED_REG_SS': 16, 'XED_REG_DS': 16, 'XED_REG_ES': 16, 'XED_REG_IP': 16, 'XED_REG_FS': 16, 'XED_REG_GS': 16, 'XED_REG_CS': 16, 'XED_REG_EAX': 32, 'XED_REG_EBX': 32, 'XED_REG_ECX': 32, 'XED_REG_EDX': 32, 'XED_REG_EIP': 32, 'XED_REG_ESP': 32, 'XED_REG_EBP': 32, 'XED_REG_ESI': 32, 'XED_REG_EDI': 32, 'XED_REG_RAX': 64, 'XED_REG_RBX': 64, 'XED_REG_RCX': 64, 'XED_REG_RDX': 64, 'XED_REG_RIP': 64, 'XED_REG_RSP': 64, 'XED_REG_RBP': 64, 'XED_REG_RSI': 64, 'XED_REG_RDI': 64, 'XED_REG_R11': 64, 'XED_REG_X87STATUS': 16, 'XED_REG_X87CONTROL': 16, 'XED_REG_X87TAG': 16, 'XED_REG_X87PUSH': 64, 'XED_REG_X87POP': 64, 'XED_REG_X87POP2': 64, 'XED_REG_CR0': 64, 'XED_REG_XCR0': 64, 'XED_REG_MXCSR': 32, 'XED_REG_GDTR': 48, 'XED_REG_LDTR': 48, 'XED_REG_IDTR': 48, 'XED_REG_TR': 64, 'XED_REG_TSC': 64, 'XED_REG_TSCAUX': 64, 'XED_REG_MSRS': 64}
try:
self.width = size_mapping[self.oc2]
except:
print('I do not know the width of oc2: %s' % self.oc2)
self.width = 8
if self.xtype == 'struct' or self.xtype == 'INVALID':
self.element_size = self.width
elif self.xtype == 'int':
self.element_size = 32
elif self.xtype == 'bf16':
self.element_size = 16
else:
size_str = self.xtype[1:]
self.element_size = int(size_str)
self.element_size_byte = int((self.element_size + 7) / 8)
n = int((self.width + 7) / 8) / self.element_size_byte
n = int(n)
if n < 1:
n = 1
self.n_element = n
def generate_str(self):
array = False
if self.element_size > 1:
array = True
inner_str = ''
if self.type == 'float':
inner_str = 'Type::FloatType(%d)' % self.element_size_byte
elif self.type == 'int':
signed_str = 'true' if self.signed else 'false'
inner_str = 'Type::IntegerType(%d, %s)' % (self.element_size_byte, signed_str)
else:
inner_str = 'Type::BoolType()'
if self.n_element > 1:
s = 'Type::ArrayType(%s, %d)' % (inner_str, self.n_element)
else:
s = inner_str
return s
def main():
intrinsic_input = code_generator('../x86_intrinsic_input_type.include', 'NameAndType', 'NameAndType', 'r')
intrinsic_output = code_generator('../x86_intrinsic_output_type.include', 'Confidence<Ref<Type>>', '', 'w')
with open('iform-type-dump.txt', 'r') as f:
ins = intrinsic()
for line in f:
if line.strip() == '':
intrinsic_input.generate_intrinsic(ins)
intrinsic_output.generate_intrinsic(ins)
ins.reset()
continue
if line.startswith('INTRINSIC_XED_IFORM_'):
ins.set_iform(line.strip())
elif line.startswith('VL'):
ins.set_VL(line.strip())
elif line.startswith('\t'):
fields = line.strip().split('\t')
op = operand(fields[0], fields[1], fields[2])
ins.add_operand(op)
else:
print('unexpected line! I do not know what to do with it')
print(line)
intrinsic_input.clean_up()
intrinsic_output.clean_up()
type_cacher.dump_to_file('../x86_intrinsic_cached_types.include')
if __name__ == '__main__':
main() |
def txt_category_to_dict(category_str):
"""
Parameters
----------
category_str: str of nominal values from dataset meta information
Returns
-------
dict of the nominal values and their one letter encoding
Example
-------
"bell=b, convex=x" -> {"bell": "b", "convex": "x"}
"""
string_as_words = category_str.split()
result_dict = {}
for word in string_as_words:
seperator_pos = word.find("=")
key = word[: seperator_pos]
val = word[seperator_pos + 1 :][0]
result_dict[key] = val
return result_dict
# from [a, b], [c, d] -> [a, b]; [c, d]
def replace_comma_in_text(text):
result_text = ""
replace = True
for sign in text:
if sign == '[':
replace = False
if sign == ']':
replace = True
if sign == ',':
if replace:
result_text += ';'
else:
result_text += sign
else:
result_text += sign
return result_text
# ('list', 4) -> "list[0], list[1], list[2], list[3]"
def generate_str_of_list_elements_with_indices(list_name, list_size):
result_str = ""
for i in range(0, list_size):
result_str += list_name + "[" + str(i) + "], "
return result_str[: -2]
# checks if a str is a number that could be interpreted as a float
def is_number(val):
try:
float(val)
return True
except ValueError:
return False
d = txt_category_to_dict("cobwebby=c, evanescent=e, flaring=r, grooved=g")
print(d) | def txt_category_to_dict(category_str):
"""
Parameters
----------
category_str: str of nominal values from dataset meta information
Returns
-------
dict of the nominal values and their one letter encoding
Example
-------
"bell=b, convex=x" -> {"bell": "b", "convex": "x"}
"""
string_as_words = category_str.split()
result_dict = {}
for word in string_as_words:
seperator_pos = word.find('=')
key = word[:seperator_pos]
val = word[seperator_pos + 1:][0]
result_dict[key] = val
return result_dict
def replace_comma_in_text(text):
result_text = ''
replace = True
for sign in text:
if sign == '[':
replace = False
if sign == ']':
replace = True
if sign == ',':
if replace:
result_text += ';'
else:
result_text += sign
else:
result_text += sign
return result_text
def generate_str_of_list_elements_with_indices(list_name, list_size):
result_str = ''
for i in range(0, list_size):
result_str += list_name + '[' + str(i) + '], '
return result_str[:-2]
def is_number(val):
try:
float(val)
return True
except ValueError:
return False
d = txt_category_to_dict('cobwebby=c, evanescent=e, flaring=r, grooved=g')
print(d) |
#!/usr/bin/env python
# coding: utf-8
# In[172]:
#Algorithm: S(A) is like a Pascal's Triangle
#take string "ZY" for instance
#S(A) of "ZY" can look like this: row 0 " "
# row 1 Z Y
# row 2 ZZ ZY YZ YY
# row 3 ZZZ ZZY ZYZ ZYY YZZ YZY YYZ YYY
#each letter in string A is added to the end of each word in previous row
#generator first generates words from each row of triangle and append them to total_List
#converts string A to list
repetition= []
#function that generates the words from each line in triangle
#N is number of iterations that the loop goes through depending on how long the longest resulting word is
def generate_words(N, A):
#make repetition a global variable
global repetition
#convert A to list of letters
L = list(A)
# if N is 0, return original string
if N == 0 :
return L
else:
#create empty list to store new words
newList=[]
#loop through each letter in string
for elem in repetition :
# add each letter in string to end of previous word
L1 = [ e + elem for e in L ]
newList = newList + L1
return generate_words(N -1, newList)
#function that adds each line together
def append_words(A):
global repetition
#set letters to be added as permanent
repetition = list(A)
total =['']
for i in range( len(A) +1 ):
total = total + generate_words(i , repetition )
return total
#return newly appended list of words
return generate_words(len(A),repetition)
print(append_words('abc'))
# In[178]:
#Algorithm: continued from part 1, treat S(A) as list of triangle/pyramid with len(A)**N rows
#function that gets total number of words for n letters in string A
# len(A)
mutation_base_len = 0
#function that converts index to corresponding word in the Nth position
def index_to_word(N, A):
mutation_base_len = len(A)
base_length = len(A)
#first get which line in the triangle the index is in
#since number of lines cannot be more than half of total number of words, divide by 2 to narrow down
totalLoop = int(N / 2)
str_of_word = list(A)
total_index = 0
#get position of word in row by subtracting # of words in each row by index #
which_pyramid_row = get_pyramid_row(N,A)
#print("which_pyramid_row:", which_pyramid_row)
curr_row_offset = N - get_pyramid_sumup(which_pyramid_row, A)
#convert position k to its N-base equivalent
dig_index = dec_to_base(curr_row_offset, base_length)
# if length of digit_string is less than its corresponding row number
# then need to make up the digits by inserting 0s to the front
if len(dig_index)< which_pyramid_row+1:
dig_index = str(0*(which_pyramid_row-len(dig_index))) + str(dig_index)
return int(dig_index)
# finally, convert n-base to corresponding words
letter_str = ''
for digit in dig_index:
corresponding_let = str_of_word[int(digit)]
letter_str+= corresponding_let
print("word:", letter_str)
return letter_str
#function to convert decimal to its N-base equivalent
def dec_to_base(n,base):
convertString = "0123456789ABCDEF"
if n < base:
return convertString[n]
else:
return dec_to_base(n//base,base) + convertString[n%base]
#get total number of words up to current row as defined by function get_pyramid_row
def get_pyramid_sumup(curr_row, A):
total_count = 0
for i in range(curr_row+1):
total_count+= (len(A))**i
return total_count
#get current row based on index number
def get_pyramid_row(index, A):
for i in range(len(A)+1):
if index >= get_pyramid_sumup(i, A) and index < get_pyramid_sumup(i+1, A):
return i
'''
def NthCount(N, A):
count = 0
for i in range(N):
count = count + len(A)**N
return count
'''
print(index_to_word(2, 'TGCA'))
# In[169]:
#function that uses the n-base system to convert letters to 0, 1, 2, etc and then finding the decimal correspondence index number
def word_to_index(WORD, A):
str_of_word = list(WORD)
#add the assigned n-base index to the end of str digits_string for every letter
#ie.for string ZY, Z=0, Y=1 so ZZY = 001
digits_string=""
for letter in str_of_word:
k = str_of_word.index(letter)
digits_string = str(digits_string) + str(k)
#print(int(digits_string))
return str(digits_string)
# calling the built-in function int(number, base) by passing two arguments in it
# number in string form and base and store the output value in line_index
line_index = int(digits_string, len(A))
# printing the corresponding decimal number
print("index:", line_index)
# add the line index to previous word counts to get the final index of WORD
actual_index = 0
for i in range(len(WORD)):
actual_index = line_index + (len(WORD)**i)
print(int(actual_index))
print(word_to_index('bb', 'abc'))
# In[ ]:
# In[ ]:
# In[ ]:
| repetition = []
def generate_words(N, A):
global repetition
l = list(A)
if N == 0:
return L
else:
new_list = []
for elem in repetition:
l1 = [e + elem for e in L]
new_list = newList + L1
return generate_words(N - 1, newList)
def append_words(A):
global repetition
repetition = list(A)
total = ['']
for i in range(len(A) + 1):
total = total + generate_words(i, repetition)
return total
return generate_words(len(A), repetition)
print(append_words('abc'))
mutation_base_len = 0
def index_to_word(N, A):
mutation_base_len = len(A)
base_length = len(A)
total_loop = int(N / 2)
str_of_word = list(A)
total_index = 0
which_pyramid_row = get_pyramid_row(N, A)
curr_row_offset = N - get_pyramid_sumup(which_pyramid_row, A)
dig_index = dec_to_base(curr_row_offset, base_length)
if len(dig_index) < which_pyramid_row + 1:
dig_index = str(0 * (which_pyramid_row - len(dig_index))) + str(dig_index)
return int(dig_index)
letter_str = ''
for digit in dig_index:
corresponding_let = str_of_word[int(digit)]
letter_str += corresponding_let
print('word:', letter_str)
return letter_str
def dec_to_base(n, base):
convert_string = '0123456789ABCDEF'
if n < base:
return convertString[n]
else:
return dec_to_base(n // base, base) + convertString[n % base]
def get_pyramid_sumup(curr_row, A):
total_count = 0
for i in range(curr_row + 1):
total_count += len(A) ** i
return total_count
def get_pyramid_row(index, A):
for i in range(len(A) + 1):
if index >= get_pyramid_sumup(i, A) and index < get_pyramid_sumup(i + 1, A):
return i
'\ndef NthCount(N, A):\n count = 0\n for i in range(N):\n count = count + len(A)**N\n return count \n'
print(index_to_word(2, 'TGCA'))
def word_to_index(WORD, A):
str_of_word = list(WORD)
digits_string = ''
for letter in str_of_word:
k = str_of_word.index(letter)
digits_string = str(digits_string) + str(k)
return str(digits_string)
line_index = int(digits_string, len(A))
print('index:', line_index)
actual_index = 0
for i in range(len(WORD)):
actual_index = line_index + len(WORD) ** i
print(int(actual_index))
print(word_to_index('bb', 'abc')) |
def Psychiatrichelp(thoughts, eyes, eye, tongue):
return f"""
{thoughts} ____________________
{thoughts} | |
{thoughts} | PSYCHIATRIC |
{thoughts} | HELP |
{thoughts} |____________________|
{thoughts} || ,-..'\`\`. ||
{thoughts} || (,-..'\`. ) ||
|| )-c - \`)\\ ||
,.,._.-.,_,.,-||,.(\`.-- ,\`',.-,_,||.-.,.,-,._.
___||____,\`,'--._______||
|\`._||______\`'__________||
| || __ ||
| || |.-' ,|- ||
_,_,,..-,_| || ._)) \`|- ||,.,_,_.-.,_
. \`._||__________________|| ____ .
. . . . <.____\`>
.SSt . . . . . _.()\`'()\`' .
""" | def psychiatrichelp(thoughts, eyes, eye, tongue):
return f"\n {thoughts} ____________________\n {thoughts} | |\n {thoughts} | PSYCHIATRIC |\n {thoughts} | HELP |\n {thoughts} |____________________|\n {thoughts} || ,-..'\\`\\`. ||\n {thoughts} || (,-..'\\`. ) ||\n || )-c - \\`)\\ ||\n ,.,._.-.,_,.,-||,.(\\`.-- ,\\`',.-,_,||.-.,.,-,._.\n ___||____,\\`,'--._______||\n |\\`._||______\\`'__________||\n | || __ ||\n | || |.-' ,|- ||\n _,_,,..-,_| || ._)) \\`|- ||,.,_,_.-.,_\n . \\`._||__________________|| ____ .\n . . . . <.____\\`>\n .SSt . . . . . _.()\\`'()\\`' .\n" |
SECRET_KEY = ''
DEBUG = False
ALLOWED_HOSTS = [
#"example.com"
]
| secret_key = ''
debug = False
allowed_hosts = [] |
# Sort Alphabetically
presenters=[
{'name': 'Arthur', 'age': 9},
{'name': 'Nathaniel', 'age': 11}
]
presenters.sort(key=lambda item: item['name'])
print('--Alphabetically--')
print(presenters)
# Sort by length (Shortest to longest )
presenters.sort(key=lambda item: len (item['name']))
print('-- length --')
print(presenters) | presenters = [{'name': 'Arthur', 'age': 9}, {'name': 'Nathaniel', 'age': 11}]
presenters.sort(key=lambda item: item['name'])
print('--Alphabetically--')
print(presenters)
presenters.sort(key=lambda item: len(item['name']))
print('-- length --')
print(presenters) |
class SingletonMeta(type):
_instance = {}
def __call__(cls, *args, **kwargs):
if cls not in cls._instance:
cls._instance[cls] = super(SingletonMeta, cls).__call__(*args, **kwargs)
return cls._instance[cls]
| class Singletonmeta(type):
_instance = {}
def __call__(cls, *args, **kwargs):
if cls not in cls._instance:
cls._instance[cls] = super(SingletonMeta, cls).__call__(*args, **kwargs)
return cls._instance[cls] |
# Created by MechAviv
# Full of Stars Damage Skin (30 Day) | (2436479)
if sm.addDamageSkin(2436479):
sm.chat("'Full of Stars Damage Skin (30 Day)' Damage Skin has been added to your account's damage skin collection.")
sm.consumeItem() | if sm.addDamageSkin(2436479):
sm.chat("'Full of Stars Damage Skin (30 Day)' Damage Skin has been added to your account's damage skin collection.")
sm.consumeItem() |
# -*- coding: utf-8 -*-
"""
Created on 2020/12/21 15:04
@author: pipazi
"""
def L1_1_1(a):
return a + 1
| """
Created on 2020/12/21 15:04
@author: pipazi
"""
def l1_1_1(a):
return a + 1 |
FIREWALL_FORWARDING = 1
FIREWALL_INCOMING_ALLOW = 2
FIREWALL_INCOMING_BLOCK = 3
FIREWALL_OUTGOING_BLOCK = 4
FIREWALL_CFG_PATH = '/etc/clearos/firewall.conf'
def getFirewall(fw_type):
with open(FIREWALL_CFG_PATH,'r') as f:
lines = f.readlines()
lines = [line.strip('\t\r\n\\ ') for line in lines]
rules = []
rules_started = False
for line in lines:
if rules_started and line == '"':
break
if rules_started:
rule = line.split('|')
if fw_type == FIREWALL_INCOMING_ALLOW and rule[2].endswith('1'):
rules.append({
"name": rule[0],
"group": rule[1],
"proto": int(rule[3]),
"port": rule[5],
"enabled": (True if rule[2][2] == '1' else False)
})
if fw_type == FIREWALL_INCOMING_BLOCK and rule[2].endswith('2'):
rules.append({
"name": rule[0],
"group": rule[1],
"ip": rule[4],
"enabled": (True if rule[2][2] == '1' else False)
})
if fw_type == FIREWALL_OUTGOING_BLOCK and rule[2].endswith('4'):
rules.append({
"name": rule[0],
"group": rule[1],
"proto": int(rule[3]),
"ip": rule[4],
"port": rule[5],
"enabled": (True if rule[2][2] == '1' else False)
})
if fw_type == FIREWALL_FORWARDING and rule[2].endswith('8'):
rules.append({
"name": rule[0],
"group": rule[1],
"proto": int(rule[3]),
"dst_ip": rule[4],
"dst_port": rule[5],
"src_port": rule[6],
"enabled": (True if rule[2][2] == '1' else False)
})
if line == 'RULES="':
rules_started = True
return rules
def deleteFirewall(rule):
with open(FIREWALL_CFG_PATH,'r') as f:
lines = f.readlines()
success = False
i = 0
for line in lines:
if line == "\t" + rule + " \\\n": # TODO: make more checks
success = True
break
i += 1
if success:
lines.pop(i)
with open(FIREWALL_CFG_PATH,'w') as f:
lines = "".join(lines)
f.write(lines)
return success
def insertFirewall(rule):
with open(FIREWALL_CFG_PATH,'r') as f:
lines = f.readlines()
success = False
i = 0
for line in lines:
i += 1
if line.startswith('RULES="'):
success = True
break
if success:
lines.insert(i,"\t" + rule + " \\\n")
with open(FIREWALL_CFG_PATH,'w') as f:
lines = "".join(lines)
f.write(lines)
return success
def generateFirewall(rule,fw_type):
fw_rule = ""
if fw_type == FIREWALL_INCOMING_ALLOW:
fw_rule = "|".join([
rule.name,
(rule.group if rule.group else ""),
("0x10000001" if rule.enabled else "0x00000001"),
str(rule.proto),
"",
rule.port,
""
])
if fw_type == FIREWALL_INCOMING_BLOCK:
fw_rule = "|".join([
rule.name,
(rule.group if rule.group else ""),
("0x10000002" if rule.enabled else "0x00000002"),
"0",
rule.ip,
"",
""
])
if fw_type == FIREWALL_OUTGOING_BLOCK:
fw_rule = "|".join([
rule.name,
(rule.group if rule.group else ""),
("0x10000004" if rule.enabled else "0x00000004"),
str(rule.proto),
rule.ip,
rule.port,
""
])
if fw_type == FIREWALL_FORWARDING:
fw_rule = "|".join([
rule.name,
(rule.group if rule.group else ""),
("0x10000008" if rule.enabled else "0x00000008"),
str(rule.proto),
rule.dst_ip,
(rule.dst_port if rule.dst_port else ""),
rule.src_port
])
return fw_rule
def existsFirewall(name,fw_type):
for rule in getFirewall(fw_type):
if rule['name'] == name:
return True | firewall_forwarding = 1
firewall_incoming_allow = 2
firewall_incoming_block = 3
firewall_outgoing_block = 4
firewall_cfg_path = '/etc/clearos/firewall.conf'
def get_firewall(fw_type):
with open(FIREWALL_CFG_PATH, 'r') as f:
lines = f.readlines()
lines = [line.strip('\t\r\n\\ ') for line in lines]
rules = []
rules_started = False
for line in lines:
if rules_started and line == '"':
break
if rules_started:
rule = line.split('|')
if fw_type == FIREWALL_INCOMING_ALLOW and rule[2].endswith('1'):
rules.append({'name': rule[0], 'group': rule[1], 'proto': int(rule[3]), 'port': rule[5], 'enabled': True if rule[2][2] == '1' else False})
if fw_type == FIREWALL_INCOMING_BLOCK and rule[2].endswith('2'):
rules.append({'name': rule[0], 'group': rule[1], 'ip': rule[4], 'enabled': True if rule[2][2] == '1' else False})
if fw_type == FIREWALL_OUTGOING_BLOCK and rule[2].endswith('4'):
rules.append({'name': rule[0], 'group': rule[1], 'proto': int(rule[3]), 'ip': rule[4], 'port': rule[5], 'enabled': True if rule[2][2] == '1' else False})
if fw_type == FIREWALL_FORWARDING and rule[2].endswith('8'):
rules.append({'name': rule[0], 'group': rule[1], 'proto': int(rule[3]), 'dst_ip': rule[4], 'dst_port': rule[5], 'src_port': rule[6], 'enabled': True if rule[2][2] == '1' else False})
if line == 'RULES="':
rules_started = True
return rules
def delete_firewall(rule):
with open(FIREWALL_CFG_PATH, 'r') as f:
lines = f.readlines()
success = False
i = 0
for line in lines:
if line == '\t' + rule + ' \\\n':
success = True
break
i += 1
if success:
lines.pop(i)
with open(FIREWALL_CFG_PATH, 'w') as f:
lines = ''.join(lines)
f.write(lines)
return success
def insert_firewall(rule):
with open(FIREWALL_CFG_PATH, 'r') as f:
lines = f.readlines()
success = False
i = 0
for line in lines:
i += 1
if line.startswith('RULES="'):
success = True
break
if success:
lines.insert(i, '\t' + rule + ' \\\n')
with open(FIREWALL_CFG_PATH, 'w') as f:
lines = ''.join(lines)
f.write(lines)
return success
def generate_firewall(rule, fw_type):
fw_rule = ''
if fw_type == FIREWALL_INCOMING_ALLOW:
fw_rule = '|'.join([rule.name, rule.group if rule.group else '', '0x10000001' if rule.enabled else '0x00000001', str(rule.proto), '', rule.port, ''])
if fw_type == FIREWALL_INCOMING_BLOCK:
fw_rule = '|'.join([rule.name, rule.group if rule.group else '', '0x10000002' if rule.enabled else '0x00000002', '0', rule.ip, '', ''])
if fw_type == FIREWALL_OUTGOING_BLOCK:
fw_rule = '|'.join([rule.name, rule.group if rule.group else '', '0x10000004' if rule.enabled else '0x00000004', str(rule.proto), rule.ip, rule.port, ''])
if fw_type == FIREWALL_FORWARDING:
fw_rule = '|'.join([rule.name, rule.group if rule.group else '', '0x10000008' if rule.enabled else '0x00000008', str(rule.proto), rule.dst_ip, rule.dst_port if rule.dst_port else '', rule.src_port])
return fw_rule
def exists_firewall(name, fw_type):
for rule in get_firewall(fw_type):
if rule['name'] == name:
return True |
# SPDX-License-Identifier: MIT
# Copyright (c) 2021 Akumatic
#
# https://adventofcode.com/2021/day/02
def read_file() -> list:
with open(f"{__file__.rstrip('code.py')}input.txt", "r") as f:
return [(s[0], int(s[1])) for s in (line.split() for line in f.read().strip().split("\n"))]
def part1(commands: list) -> int:
position, depth = 0, 0
for com in commands:
if com[0] == "forward":
position += com[1]
elif com[0] == "down":
depth += com[1]
else: #com[1] == "up"
depth -= com[1]
return position * depth
def part2(commands: list) -> int:
position, depth, aim = 0, 0, 0
for com in commands:
if com[0] == "forward":
position += com[1]
depth += aim * com[1]
elif com[0] == "down":
aim += com[1]
else: #com[1] == "up"
aim -= com[1]
return position * depth
if __name__ == "__main__":
vals = read_file()
print(f"Part 1: {part1(vals)}")
print(f"Part 2: {part2(vals)}") | def read_file() -> list:
with open(f"{__file__.rstrip('code.py')}input.txt", 'r') as f:
return [(s[0], int(s[1])) for s in (line.split() for line in f.read().strip().split('\n'))]
def part1(commands: list) -> int:
(position, depth) = (0, 0)
for com in commands:
if com[0] == 'forward':
position += com[1]
elif com[0] == 'down':
depth += com[1]
else:
depth -= com[1]
return position * depth
def part2(commands: list) -> int:
(position, depth, aim) = (0, 0, 0)
for com in commands:
if com[0] == 'forward':
position += com[1]
depth += aim * com[1]
elif com[0] == 'down':
aim += com[1]
else:
aim -= com[1]
return position * depth
if __name__ == '__main__':
vals = read_file()
print(f'Part 1: {part1(vals)}')
print(f'Part 2: {part2(vals)}') |
#!/usr/bin/env python
# coding: utf-8
# #### We create a function cleanQ so we can do the cleaning and preperation of our data
# #### INPUT: String
# #### OUTPUT: Cleaned String
def cleanQ(query):
query = query.lower()
tokenizer = RegexpTokenizer(r'\w+')
tokens = tokenizer.tokenize(query)
stemmer=[ps.stem(i) for i in tokens]
filtered_Q = [w for w in stemmer if not w in stopwords.words('english')]
return filtered_Q
# #### We create a function computeTF so we can calculate the tf
# #### INPUT: Dictionary where the keys are the terms_id and the values are the frequencies of this term Id in the document
# #### OUTPUT: TF of the specific Term_id in the corresponding document
def computeTF(doc_words):
bow = 0
for k, v in doc_words.items():
bow = bow + v
tf_word = {}
for word, count in doc_words.items():
tf_word[word] = count / float(bow)
return tf_word
# #### We create a function tf_idf so we can calculate the tfidf
# #### INPUT: docid, termid
# #### OUTPUT: tfidf for the input
def tf_idf(docid, termid):
return((movieDatabase["Clean All"][docid][termid]*idf[termid])/sum(movieDatabase["Clean All"][docid]))
| def clean_q(query):
query = query.lower()
tokenizer = regexp_tokenizer('\\w+')
tokens = tokenizer.tokenize(query)
stemmer = [ps.stem(i) for i in tokens]
filtered_q = [w for w in stemmer if not w in stopwords.words('english')]
return filtered_Q
def compute_tf(doc_words):
bow = 0
for (k, v) in doc_words.items():
bow = bow + v
tf_word = {}
for (word, count) in doc_words.items():
tf_word[word] = count / float(bow)
return tf_word
def tf_idf(docid, termid):
return movieDatabase['Clean All'][docid][termid] * idf[termid] / sum(movieDatabase['Clean All'][docid]) |
#5times range
print('my name i')
for i in range (5):
print('jimee my name ('+ str(i) +')')
| print('my name i')
for i in range(5):
print('jimee my name (' + str(i) + ')') |
class Node():
def __init__(self, val):
self.val = val
self.left = None
self.right = None
class BST():
def __init__(self):
self.root = Node(None)
def insert(self, new_data):
if self.root is None:
self.root = Node(new_data)
else:
if self.root.val < new_data:
self.insert(self.root.right, new_data)
else:
self.insert(self.root.left, new_data)
def inorder(self):
if self.root:
self.inorder(self.root.left)
print(self.root.val)
self.inorder(self.root.right)
if __name__ == '__main__':
tree = BST()
tree.insert(5)
tree.insert(4)
tree.insert(7)
tree.inorder()
| class Node:
def __init__(self, val):
self.val = val
self.left = None
self.right = None
class Bst:
def __init__(self):
self.root = node(None)
def insert(self, new_data):
if self.root is None:
self.root = node(new_data)
elif self.root.val < new_data:
self.insert(self.root.right, new_data)
else:
self.insert(self.root.left, new_data)
def inorder(self):
if self.root:
self.inorder(self.root.left)
print(self.root.val)
self.inorder(self.root.right)
if __name__ == '__main__':
tree = bst()
tree.insert(5)
tree.insert(4)
tree.insert(7)
tree.inorder() |
# https://app.codesignal.com/arcade/code-arcade/loop-tunnel/xzeZqCQjpfDJuN72S
def additionWithoutCarrying(param1, param2):
# Add the values of each column of each number without carrying.
# Order them smaller and larger value.
param1, param2 = sorted([param1, param2])
# Convert both values to strings.
str1, str2 = str(param1), str(param2)
# Pad the smaller value with 0s so all columns have a match.
str1 = "0" * (len(str2) - len(str1)) + str1
res = ""
for i in range(len(str2)):
# Add up the integer value of each column, extract units with modulus,
# then convert back to string and create a result string.
res += str((int(str1[i]) + int(str2[i])) % 10)
return int(res)
| def addition_without_carrying(param1, param2):
(param1, param2) = sorted([param1, param2])
(str1, str2) = (str(param1), str(param2))
str1 = '0' * (len(str2) - len(str1)) + str1
res = ''
for i in range(len(str2)):
res += str((int(str1[i]) + int(str2[i])) % 10)
return int(res) |
# Author: @Iresharma
# https://leetcode.com/problems/reverse-integer/
"""
Runtime: 20 ms, faster than 99.38% of Python3 online submissions for Reverse Integer.
Memory Usage: 14.2 MB, less than 71.79% of Python3 online submissions for Reverse Integer.
"""
class Solution:
def reverse(self, x: int) -> int:
if abs(x) > 2147483648:
return 0
s = str(x)
if s[0] == '-':
x = int('-' + s[::-1][:-1:])
return x if abs(x) < 2147483648 else 0
x = int(s[::-1])
return x if x < 2147483648 else 0 | """
Runtime: 20 ms, faster than 99.38% of Python3 online submissions for Reverse Integer.
Memory Usage: 14.2 MB, less than 71.79% of Python3 online submissions for Reverse Integer.
"""
class Solution:
def reverse(self, x: int) -> int:
if abs(x) > 2147483648:
return 0
s = str(x)
if s[0] == '-':
x = int('-' + s[::-1][:-1])
return x if abs(x) < 2147483648 else 0
x = int(s[::-1])
return x if x < 2147483648 else 0 |
# 1137. N-th Tribonacci Number
# Runtime: 32 ms, faster than 35.84% of Python3 online submissions for N-th Tribonacci Number.
# Memory Usage: 14.3 MB, less than 15.94% of Python3 online submissions for N-th Tribonacci Number.
class Solution:
# Space Optimisation - Dynamic Programming
def tribonacci(self, n: int) -> int:
if n < 3:
return 1 if n else 0
x, y, z = 0, 1, 1
for _ in range(n - 2):
x, y, z = y, z, x + y + z
return z | class Solution:
def tribonacci(self, n: int) -> int:
if n < 3:
return 1 if n else 0
(x, y, z) = (0, 1, 1)
for _ in range(n - 2):
(x, y, z) = (y, z, x + y + z)
return z |
# Exercise2.p1
# Variables, Strings, Ints and Print Exercise
# Given two variables - name and age.
# Use the format() function to create a sentence that reads:
# "Hi my name is Julie and I am 42 years old"
# Set that equal to the variable called sentence
name = "Julie"
age = "42"
sentence = "Hi my name is {} and i am {} years old".format(name,age)
print(sentence) | name = 'Julie'
age = '42'
sentence = 'Hi my name is {} and i am {} years old'.format(name, age)
print(sentence) |
def ordinal(num):
suffixes = {1: 'st', 2: 'nd', 3: 'rd'}
if 10 <= num % 100 <= 20:
suffix = 'th'
else:
suffix = suffixes.get(num % 10, 'th')
return str(num) + suffix
def num_to_text(num):
texts = {
1: 'first',
2: 'second',
3: 'third',
4: 'fourth',
5: 'fifth',
6: 'sixth',
7: 'seventh',
8: 'eighth',
9: 'ninth',
10: 'tenth',
11: 'eleventh',
12: 'twelfth',
13: 'thirteenth',
14: 'fourteenth',
15: 'fifteenth',
16: 'sixteenth',
17: 'seventeenth',
18: 'eighteenth',
19: 'nineteenth',
20: 'twentieth',
}
if num in texts:
return texts[num]
else:
return ordinal(num)
| def ordinal(num):
suffixes = {1: 'st', 2: 'nd', 3: 'rd'}
if 10 <= num % 100 <= 20:
suffix = 'th'
else:
suffix = suffixes.get(num % 10, 'th')
return str(num) + suffix
def num_to_text(num):
texts = {1: 'first', 2: 'second', 3: 'third', 4: 'fourth', 5: 'fifth', 6: 'sixth', 7: 'seventh', 8: 'eighth', 9: 'ninth', 10: 'tenth', 11: 'eleventh', 12: 'twelfth', 13: 'thirteenth', 14: 'fourteenth', 15: 'fifteenth', 16: 'sixteenth', 17: 'seventeenth', 18: 'eighteenth', 19: 'nineteenth', 20: 'twentieth'}
if num in texts:
return texts[num]
else:
return ordinal(num) |
#To reverse a given number
def ReverseNo(num):
num = str(num)
reverse = ''.join(reversed(num))
print(reverse)
Num = int(input('N= '))
ReverseNo(Num)
| def reverse_no(num):
num = str(num)
reverse = ''.join(reversed(num))
print(reverse)
num = int(input('N= '))
reverse_no(Num) |
def age_assignment(*args, **kwargs):
answer = {}
for arg in args:
for k, v in kwargs.items():
if arg[0] == k:
answer[arg] = v
return answer
| def age_assignment(*args, **kwargs):
answer = {}
for arg in args:
for (k, v) in kwargs.items():
if arg[0] == k:
answer[arg] = v
return answer |
class Solution:
def restoreString(self, s: str, indices: List[int]) -> str:
answer = ""
for i in range(len(indices)):
answer += s[indices.index(i)]
return answer | class Solution:
def restore_string(self, s: str, indices: List[int]) -> str:
answer = ''
for i in range(len(indices)):
answer += s[indices.index(i)]
return answer |
{
".py": {
"from osv import osv, fields": [regex("^from osv import osv, fields$"), "from odoo import models, fields, api"],
"from osv import fields, osv": [regex("^from osv import fields, osv$"), "from odoo import models, fields, api"],
"(osv.osv)": [regex("\(osv\.osv\)"), "(models.Model)"],
"from osv.orm import except_orm": [regex("^from osv\.orm import except_orm$"), "from odoo.exceptions import except_orm"],
"from tools import config": [regex("^from tools import config$"), "from odoo.tools import config"],
"from tools.translate import _": [regex("^from tools\.translate import _$"), "from odoo import _"],
"import tools": [regex("^import tools$"), "from odoo import tools"],
"name_get()": [regex("^ def name_get\(self,.*?\):"), " @api.multi\n def name_get(self):"],
"select=1": ["select=1", "index=True"],
"select=0": ["select=0", "index=False"],
"": ["", ""],
},
".xml": {
"<openerp>": ["<openerp>", "<odoo>"],
"</openerp>": ["</openerp>", "</odoo>"],
"ir.sequence.type record": [regex('^\\s*<record model="ir.sequence.type".*?<\/record>'), ""]
}
}
| {'.py': {'from osv import osv, fields': [regex('^from osv import osv, fields$'), 'from odoo import models, fields, api'], 'from osv import fields, osv': [regex('^from osv import fields, osv$'), 'from odoo import models, fields, api'], '(osv.osv)': [regex('\\(osv\\.osv\\)'), '(models.Model)'], 'from osv.orm import except_orm': [regex('^from osv\\.orm import except_orm$'), 'from odoo.exceptions import except_orm'], 'from tools import config': [regex('^from tools import config$'), 'from odoo.tools import config'], 'from tools.translate import _': [regex('^from tools\\.translate import _$'), 'from odoo import _'], 'import tools': [regex('^import tools$'), 'from odoo import tools'], 'name_get()': [regex('^ def name_get\\(self,.*?\\):'), ' @api.multi\n def name_get(self):'], 'select=1': ['select=1', 'index=True'], 'select=0': ['select=0', 'index=False'], '': ['', '']}, '.xml': {'<openerp>': ['<openerp>', '<odoo>'], '</openerp>': ['</openerp>', '</odoo>'], 'ir.sequence.type record': [regex('^\\s*<record model="ir.sequence.type".*?<\\/record>'), '']}} |
# Definition for a binary tree node.
# class TreeNode:
# def __init__(self, val=0, left=None, right=None):
# self.val = val
# self.left = left
# self.right = right
class Solution:
def findTarget(self, root: Optional[TreeNode], k: int) -> bool:
nums = []
self.nodeValueExtract(root, nums)
for i in range(len(nums)):
if k - nums[i] in nums[i+1:]:
return True
return False
def nodeValueExtract(self, root, nums):
if root:
self.nodeValueExtract(root.left, nums)
nums.append(root.val)
self.nodeValueExtract(root.right, nums) | class Solution:
def find_target(self, root: Optional[TreeNode], k: int) -> bool:
nums = []
self.nodeValueExtract(root, nums)
for i in range(len(nums)):
if k - nums[i] in nums[i + 1:]:
return True
return False
def node_value_extract(self, root, nums):
if root:
self.nodeValueExtract(root.left, nums)
nums.append(root.val)
self.nodeValueExtract(root.right, nums) |
"""
Define your BigQuery tables as dataclasses.
"""
__version__ = "0.4"
| """
Define your BigQuery tables as dataclasses.
"""
__version__ = '0.4' |
# -*- coding: utf-8 -*-
"""
BlueButtonFHIR_API
FILE: __init__.py
Created: 12/15/15 4:42 PM
"""
__author__ = 'Mark Scrimshire:@ekivemark'
| """
BlueButtonFHIR_API
FILE: __init__.py
Created: 12/15/15 4:42 PM
"""
__author__ = 'Mark Scrimshire:@ekivemark' |
# Encapsulation: intance variables and methods can be kept private.
# Abtraction: each object should only expose a high level mechanism
# for using it. It should hide internal implementation details and only
# reveal operations relvant for other objects.
# ex. HR dept setting salary using setter method
class SoftwareEngineer:
def __init__(self, name, age):
self.name = name
self.age = age
# protected variable
# can still be accessed outside
self._salary = None
# strict private variable
# AttributeError: 'CLASS' object has no attribute '__<attribute_name>'
# However __ is not used conventionally and _ is used.
self.__salary = 5000
# protected variable
self._nums_bugs_solved = 0
def code(self):
self._nums_bugs_solved += 1
# protected method
def _calcluate_salary(self, base_value):
if self._nums_bugs_solved < 10:
return base_value
elif self._nums_bugs_solved < 100:
return base_value * 2
return base_value
# getter method: manual implementation
def get_salary(self):
return self._salary
# getter method
def get_nums_bugs_solved(self):
return self._nums_bugs_solved
# setter method
def set_salary(self, base_value):
value = self._calcluate_salary(base_value)
# check value, enforce constarints
if value < 1000:
self._salary = 1000
if value > 20000:
self._salary = 20000
self._salary = value
# pythonic implementation of getter method
# use @property decorator
# name of the method is variable_name being set
# called by print(<instance_name>.<variable_name>)
@property
def salary(self):
return self._salary
# pythonic implementation of setter method
# use @<variable>.setter decorator
# name of the method is variable_name being set
# used by <instance_name>.<variable_name> = <VALUE>
@salary.setter
def salary(self, base_value):
value = self._calcluate_salary(base_value)
# check value, enforce constarints
if value < 1000:
self._salary = 1000
if value > 20000:
self._salary = 20000
self._salary = value
# pythonic implementation of the delete method
# use @<variable>.deleter decorator
# name of the method is variable_name being deleted
# called by del <instance_name>.<variable_name>
@salary.deleter
def salary(self):
del self._salary
se = SoftwareEngineer("max", 25)
print(se.age, se.name)
print(se._salary)
# print(se.__salary)
for i in range(70):
se.code()
print(se.get_nums_bugs_solved())
se.set_salary(6000)
print(se.get_salary())
se.salary = 5000
print(se.salary)
del se.salary
print(se.salary)
'''
25 max
None
70
12000
10000
Traceback (most recent call last):
File "/home/vibha/visual_studio/oop4.py", line 106, in <module>
print(se.salary)
File "/home/vibha/visual_studio/oop4.py", line 63, in salary
return self._salary
AttributeError: 'SoftwareEngineer' object has no attribute '_salary'
'''
| class Softwareengineer:
def __init__(self, name, age):
self.name = name
self.age = age
self._salary = None
self.__salary = 5000
self._nums_bugs_solved = 0
def code(self):
self._nums_bugs_solved += 1
def _calcluate_salary(self, base_value):
if self._nums_bugs_solved < 10:
return base_value
elif self._nums_bugs_solved < 100:
return base_value * 2
return base_value
def get_salary(self):
return self._salary
def get_nums_bugs_solved(self):
return self._nums_bugs_solved
def set_salary(self, base_value):
value = self._calcluate_salary(base_value)
if value < 1000:
self._salary = 1000
if value > 20000:
self._salary = 20000
self._salary = value
@property
def salary(self):
return self._salary
@salary.setter
def salary(self, base_value):
value = self._calcluate_salary(base_value)
if value < 1000:
self._salary = 1000
if value > 20000:
self._salary = 20000
self._salary = value
@salary.deleter
def salary(self):
del self._salary
se = software_engineer('max', 25)
print(se.age, se.name)
print(se._salary)
for i in range(70):
se.code()
print(se.get_nums_bugs_solved())
se.set_salary(6000)
print(se.get_salary())
se.salary = 5000
print(se.salary)
del se.salary
print(se.salary)
'\n25 max\nNone\n70\n12000\n10000\nTraceback (most recent call last):\n File "/home/vibha/visual_studio/oop4.py", line 106, in <module>\n print(se.salary)\n File "/home/vibha/visual_studio/oop4.py", line 63, in salary\n return self._salary\nAttributeError: \'SoftwareEngineer\' object has no attribute \'_salary\'\n' |
n, m = map(int, input().split())
student = [tuple(map(int, input().split())) for _ in range(n)]
check_points = [tuple(map(int, input().split())) for _ in range(m)]
for a, b in student:
dst_min = float('inf')
ans = float('inf')
for i, (c, d) in enumerate(check_points):
now = abs(a - c) + abs(b - d)
if now < dst_min:
dst_min = now
ans = i + 1
print(ans)
| (n, m) = map(int, input().split())
student = [tuple(map(int, input().split())) for _ in range(n)]
check_points = [tuple(map(int, input().split())) for _ in range(m)]
for (a, b) in student:
dst_min = float('inf')
ans = float('inf')
for (i, (c, d)) in enumerate(check_points):
now = abs(a - c) + abs(b - d)
if now < dst_min:
dst_min = now
ans = i + 1
print(ans) |
#
# Copyright Soramitsu Co., Ltd. All Rights Reserved.
# SPDX-License-Identifier: Apache-2.0
#
grantable = {
'can_add_my_signatory': 'kAddMySignatory',
'can_remove_my_signatory': 'kRemoveMySignatory',
'can_set_my_account_detail': 'kSetMyAccountDetail',
'can_set_my_quorum': 'kSetMyQuorum',
'can_transfer_my_assets': 'kTransferMyAssets'
}
role = {
'can_add_asset_qty': 'kAddAssetQty',
'can_add_domain_asset_qty': 'kAddDomainAssetQty',
'can_add_peer': 'kAddPeer',
'can_add_signatory': 'kAddSignatory',
'can_append_role': 'kAppendRole',
'can_create_account': 'kCreateAccount',
'can_create_asset': 'kCreateAsset',
'can_create_domain': 'kCreateDomain',
'can_create_role': 'kCreateRole',
'can_detach_role': 'kDetachRole',
'can_get_all_acc_ast': 'kGetAllAccAst',
'can_get_all_acc_ast_txs': 'kGetAllAccAstTxs',
'can_get_all_acc_detail': 'kGetAllAccDetail',
'can_get_all_acc_txs': 'kGetAllAccTxs',
'can_get_all_accounts': 'kGetAllAccounts',
'can_get_all_signatories': 'kGetAllSignatories',
'can_get_all_txs': 'kGetAllTxs',
'can_get_blocks': 'kGetBlocks',
'can_get_domain_acc_ast': 'kGetDomainAccAst',
'can_get_domain_acc_ast_txs': 'kGetDomainAccAstTxs',
'can_get_domain_acc_detail': 'kGetDomainAccDetail',
'can_get_domain_acc_txs': 'kGetDomainAccTxs',
'can_get_domain_accounts': 'kGetDomainAccounts',
'can_get_domain_signatories': 'kGetDomainSignatories',
'can_get_my_acc_ast': 'kGetMyAccAst',
'can_get_my_acc_ast_txs': 'kGetMyAccAstTxs',
'can_get_my_acc_detail': 'kGetMyAccDetail',
'can_get_my_acc_txs': 'kGetMyAccTxs',
'can_get_my_account': 'kGetMyAccount',
'can_get_my_signatories': 'kGetMySignatories',
'can_get_my_txs': 'kGetMyTxs',
'can_get_roles': 'kGetRoles',
'can_grant_can_add_my_signatory': 'kAddMySignatory',
'can_grant_can_remove_my_signatory': 'kRemoveMySignatory',
'can_grant_can_set_my_account_detail': 'kSetMyAccountDetail',
'can_grant_can_set_my_quorum': 'kSetMyQuorum',
'can_grant_can_transfer_my_assets': 'kTransferMyAssets',
'can_read_assets': 'kReadAssets',
'can_receive': 'kReceive',
'can_remove_signatory': 'kRemoveSignatory',
'can_set_detail': 'kSetDetail',
'can_set_quorum': 'kSetQuorum',
'can_subtract_asset_qty': 'kSubtractAssetQty',
'can_subtract_domain_asset_qty': 'kSubtractDomainAssetQty',
'can_transfer': 'kTransfer'
}
| grantable = {'can_add_my_signatory': 'kAddMySignatory', 'can_remove_my_signatory': 'kRemoveMySignatory', 'can_set_my_account_detail': 'kSetMyAccountDetail', 'can_set_my_quorum': 'kSetMyQuorum', 'can_transfer_my_assets': 'kTransferMyAssets'}
role = {'can_add_asset_qty': 'kAddAssetQty', 'can_add_domain_asset_qty': 'kAddDomainAssetQty', 'can_add_peer': 'kAddPeer', 'can_add_signatory': 'kAddSignatory', 'can_append_role': 'kAppendRole', 'can_create_account': 'kCreateAccount', 'can_create_asset': 'kCreateAsset', 'can_create_domain': 'kCreateDomain', 'can_create_role': 'kCreateRole', 'can_detach_role': 'kDetachRole', 'can_get_all_acc_ast': 'kGetAllAccAst', 'can_get_all_acc_ast_txs': 'kGetAllAccAstTxs', 'can_get_all_acc_detail': 'kGetAllAccDetail', 'can_get_all_acc_txs': 'kGetAllAccTxs', 'can_get_all_accounts': 'kGetAllAccounts', 'can_get_all_signatories': 'kGetAllSignatories', 'can_get_all_txs': 'kGetAllTxs', 'can_get_blocks': 'kGetBlocks', 'can_get_domain_acc_ast': 'kGetDomainAccAst', 'can_get_domain_acc_ast_txs': 'kGetDomainAccAstTxs', 'can_get_domain_acc_detail': 'kGetDomainAccDetail', 'can_get_domain_acc_txs': 'kGetDomainAccTxs', 'can_get_domain_accounts': 'kGetDomainAccounts', 'can_get_domain_signatories': 'kGetDomainSignatories', 'can_get_my_acc_ast': 'kGetMyAccAst', 'can_get_my_acc_ast_txs': 'kGetMyAccAstTxs', 'can_get_my_acc_detail': 'kGetMyAccDetail', 'can_get_my_acc_txs': 'kGetMyAccTxs', 'can_get_my_account': 'kGetMyAccount', 'can_get_my_signatories': 'kGetMySignatories', 'can_get_my_txs': 'kGetMyTxs', 'can_get_roles': 'kGetRoles', 'can_grant_can_add_my_signatory': 'kAddMySignatory', 'can_grant_can_remove_my_signatory': 'kRemoveMySignatory', 'can_grant_can_set_my_account_detail': 'kSetMyAccountDetail', 'can_grant_can_set_my_quorum': 'kSetMyQuorum', 'can_grant_can_transfer_my_assets': 'kTransferMyAssets', 'can_read_assets': 'kReadAssets', 'can_receive': 'kReceive', 'can_remove_signatory': 'kRemoveSignatory', 'can_set_detail': 'kSetDetail', 'can_set_quorum': 'kSetQuorum', 'can_subtract_asset_qty': 'kSubtractAssetQty', 'can_subtract_domain_asset_qty': 'kSubtractDomainAssetQty', 'can_transfer': 'kTransfer'} |
def printName():
print("I absolutely \nlove coding \nwith Python!".format())
if __name__ == '__main__':
printName()
| def print_name():
print('I absolutely \nlove coding \nwith Python!'.format())
if __name__ == '__main__':
print_name() |
#Solution
def two_out_of_three(nums1, nums2, nums3):
stored_master = {}
stored_1 = {}
stored_2 = {}
stored_3 = {}
for i in range(0, len(nums1)):
if nums1[i] not in stored_1:
stored_1[nums1[i]] = 1
stored_master[nums1[i]] = 1
else:
pass
for i in range(0, len(nums2)):
if nums2[i] not in stored_master:
stored_2[nums2[i]] = 1
stored_master[nums2[i]] = 1
else:
if nums2[i] not in stored_2:
stored_master[nums2[i]] = 2
for i in range(0, len(nums3)):
if nums3[i] not in stored_master:
stored_3[nums3[i]] = 1
stored_master[nums3[i]] = 1
else:
if nums3[i] not in stored_3:
stored_master[nums3[i]] = 2
final_list = { key: value for key, value in stored_master.items() if value>1 }
return list(final_list.keys())
#Tests
def two_out_of_three_test():
return ( two_out_of_three([1,1,3,2],[2,3], [3]) == [3,2],
two_out_of_three([3,1], [2,3], [1,2]) == [3,1, 2],
two_out_of_three([1,2,2], [4,3,3], [5]) == [],)
print(two_out_of_three_test())
#Leetcode
class Solution(object):
def twoOutOfThree(self, nums1, nums2, nums3):
"""
:type nums1: List[int]
:type nums2: List[int]
:type nums3: List[int]
:rtype: List[int]
"""
stored_master = {}
stored_1 = {}
stored_2 = {}
stored_3 = {}
for i in range(0, len(nums1)):
if nums1[i] not in stored_1:
stored_1[nums1[i]] = 1
stored_master[nums1[i]] = 1
else:
pass
for i in range(0, len(nums2)):
if nums2[i] not in stored_master:
stored_2[nums2[i]] = 1
stored_master[nums2[i]] = 1
else:
if nums2[i] not in stored_2:
stored_master[nums2[i]] = 2
for i in range(0, len(nums3)):
if nums3[i] not in stored_master:
stored_3[nums3[i]] = 1
stored_master[nums3[i]] = 1
else:
if nums3[i] not in stored_3:
stored_master[nums3[i]] = 2
final_list = { key: value for key, value in stored_master.items() if value>1 }
return list(final_list.keys())
| def two_out_of_three(nums1, nums2, nums3):
stored_master = {}
stored_1 = {}
stored_2 = {}
stored_3 = {}
for i in range(0, len(nums1)):
if nums1[i] not in stored_1:
stored_1[nums1[i]] = 1
stored_master[nums1[i]] = 1
else:
pass
for i in range(0, len(nums2)):
if nums2[i] not in stored_master:
stored_2[nums2[i]] = 1
stored_master[nums2[i]] = 1
elif nums2[i] not in stored_2:
stored_master[nums2[i]] = 2
for i in range(0, len(nums3)):
if nums3[i] not in stored_master:
stored_3[nums3[i]] = 1
stored_master[nums3[i]] = 1
elif nums3[i] not in stored_3:
stored_master[nums3[i]] = 2
final_list = {key: value for (key, value) in stored_master.items() if value > 1}
return list(final_list.keys())
def two_out_of_three_test():
return (two_out_of_three([1, 1, 3, 2], [2, 3], [3]) == [3, 2], two_out_of_three([3, 1], [2, 3], [1, 2]) == [3, 1, 2], two_out_of_three([1, 2, 2], [4, 3, 3], [5]) == [])
print(two_out_of_three_test())
class Solution(object):
def two_out_of_three(self, nums1, nums2, nums3):
"""
:type nums1: List[int]
:type nums2: List[int]
:type nums3: List[int]
:rtype: List[int]
"""
stored_master = {}
stored_1 = {}
stored_2 = {}
stored_3 = {}
for i in range(0, len(nums1)):
if nums1[i] not in stored_1:
stored_1[nums1[i]] = 1
stored_master[nums1[i]] = 1
else:
pass
for i in range(0, len(nums2)):
if nums2[i] not in stored_master:
stored_2[nums2[i]] = 1
stored_master[nums2[i]] = 1
elif nums2[i] not in stored_2:
stored_master[nums2[i]] = 2
for i in range(0, len(nums3)):
if nums3[i] not in stored_master:
stored_3[nums3[i]] = 1
stored_master[nums3[i]] = 1
elif nums3[i] not in stored_3:
stored_master[nums3[i]] = 2
final_list = {key: value for (key, value) in stored_master.items() if value > 1}
return list(final_list.keys()) |
# Time: O(n), n is the number of cells
# Space: O(n)
class Solution(object):
def cleanRoom(self, robot):
"""
:type robot: Robot
:rtype: None
"""
directions = [(0, 1), (1, 0), (0, -1), (-1, 0)]
def goBack(robot):
robot.turnLeft()
robot.turnLeft()
robot.move()
robot.turnRight()
robot.turnRight()
def dfs(pos, robot, d, lookup):
if pos in lookup:
return
lookup.add(pos)
robot.clean()
for _ in directions:
if robot.move():
dfs((pos[0]+directions[d][0],
pos[1]+directions[d][1]),
robot, d, lookup)
goBack(robot)
robot.turnRight()
d = (d+1) % len(directions)
dfs((0, 0), robot, 0, set())
| class Solution(object):
def clean_room(self, robot):
"""
:type robot: Robot
:rtype: None
"""
directions = [(0, 1), (1, 0), (0, -1), (-1, 0)]
def go_back(robot):
robot.turnLeft()
robot.turnLeft()
robot.move()
robot.turnRight()
robot.turnRight()
def dfs(pos, robot, d, lookup):
if pos in lookup:
return
lookup.add(pos)
robot.clean()
for _ in directions:
if robot.move():
dfs((pos[0] + directions[d][0], pos[1] + directions[d][1]), robot, d, lookup)
go_back(robot)
robot.turnRight()
d = (d + 1) % len(directions)
dfs((0, 0), robot, 0, set()) |
#!/bin/python3
__author__ = "Adam Karl"
"""The Collatz sequence is defined by:
if n is even, divide it by 2
if n is odd, triple it and add 1
given N, which number less than or equal to N has the longest chain before hitting 1?"""
#first line t number of test cases, then t lines of values for N
#Constraints: 1 <= T <= 10**4; 1 <= N <= 5 * 10**6
#April 2018
MAXIMUM = 5000000 + 1 #actually 1 more than the maximum (5 million here)
steps = [None] * MAXIMUM
answers = [0] * MAXIMUM
def update(n):
"""Update the array so that now has at least an answer for key=n"""
"""likely will also fill in additional step lengths"""
if n == 1: #base case 1
return 0
s = 0
if n < MAXIMUM: #should have a n answer in this spot
if steps[n] != None: #already know answer for this spot
return steps[n]
if n % 2 == 0:
s = 1 + update(n>>1)
else:
s = 1 + update(3*n + 1)
steps[n] = s #fill in an answer
else: #calculate on the fly
if n % 2 == 0:
s = 1 + update(n>>1)
else:
s = 1 + update(3*n + 1)
return s
def populateCollatz():
"""populates collatz steps array up to n=5 000 000"""
steps[0] = 1
steps[1] = 0
for i in range(1,MAXIMUM):
if steps[i] == None:
update(i)
def populateAnswers():
"""Using the array of number of steps for N, produce an array of the value that produces
the maximum # of steps less than of equal to N (in case of a tie use the larger number).
Using this method we only have to check an array for the maximum 1 time rather than for every
test case N"""
max_steps = 0
max_index = 0
for i in range(MAXIMUM):
if max_steps <= steps[i]:
max_steps = steps[i]
max_index = i
answers[i] = max_index
def main():
populateCollatz()
populateAnswers()
a0 = int(input())
for i in range(a0):
n = int(input())
print(answers[n])
if __name__ == "__main__":
main()
| __author__ = 'Adam Karl'
'The Collatz sequence is defined by:\nif n is even, divide it by 2\nif n is odd, triple it and add 1\ngiven N, which number less than or equal to N has the longest chain before hitting 1?'
maximum = 5000000 + 1
steps = [None] * MAXIMUM
answers = [0] * MAXIMUM
def update(n):
"""Update the array so that now has at least an answer for key=n"""
'likely will also fill in additional step lengths'
if n == 1:
return 0
s = 0
if n < MAXIMUM:
if steps[n] != None:
return steps[n]
if n % 2 == 0:
s = 1 + update(n >> 1)
else:
s = 1 + update(3 * n + 1)
steps[n] = s
elif n % 2 == 0:
s = 1 + update(n >> 1)
else:
s = 1 + update(3 * n + 1)
return s
def populate_collatz():
"""populates collatz steps array up to n=5 000 000"""
steps[0] = 1
steps[1] = 0
for i in range(1, MAXIMUM):
if steps[i] == None:
update(i)
def populate_answers():
"""Using the array of number of steps for N, produce an array of the value that produces
the maximum # of steps less than of equal to N (in case of a tie use the larger number).
Using this method we only have to check an array for the maximum 1 time rather than for every
test case N"""
max_steps = 0
max_index = 0
for i in range(MAXIMUM):
if max_steps <= steps[i]:
max_steps = steps[i]
max_index = i
answers[i] = max_index
def main():
populate_collatz()
populate_answers()
a0 = int(input())
for i in range(a0):
n = int(input())
print(answers[n])
if __name__ == '__main__':
main() |
"""
Defaults for deployment.
"""
# Default work path
default_work_path: str = ""
# Default config var names
config_const: str = "const"
config_options: str = "options"
config_arg: str = "arg"
config_var: str = "var"
config_alias: str = "alias"
config_stage: str = "stage" | """
Defaults for deployment.
"""
default_work_path: str = ''
config_const: str = 'const'
config_options: str = 'options'
config_arg: str = 'arg'
config_var: str = 'var'
config_alias: str = 'alias'
config_stage: str = 'stage' |
#6 uniform distribution
p=[0.2, 0.2, 0.2, 0.2, 0.2]
print(p)
#7 generalized uniform distribution
p=[]
n=5
for i in range(n):
p.append(1/n)
print(p)
#11 pHit and pMiss
# not elegent but does the job
pHit=0.6
pMiss=0.2
p[0]=p[0]*pMiss
p[1]=p[1]*pHit
p[2]=p[2]*pHit
p[3]=p[3]*pMiss
p[4]=p[4]*pMiss
print(p)
#12 print out sum of probabilities
print(sum(p))
#13 sense function
# sense function is the measurement update, which takes as input the initial
# distribution p, measurement z, and other global variables, and outputs a normalized
# distribution Q, which reflects the non-normalized product of imput probability
# i.e.0.2 and so on, and the corresponding pHit(0.6) and or pMiss(0.2) in accordance
# to whether these colours over here agree or disagree.
# The reason for the localizer is because later on as we build our localizer we will
# this to every single measurement over and over again.
p=[0.2, 0.2, 0.2, 0.2, 0.2]
world=['green', 'red', 'red', 'green', 'green']
Z = 'red' #or green
pHit = 0.6
pMiss = 0.2
def sense(p, Z):
q=[]
for i in range(len(p)):
hit = (Z == world[i])
q.append(p[i] * (hit * pHit + (1-hit) * pMiss))
s = sum(q)
for i in range(len(p)):
q[i] = q[i]/s
return q
print(sense(p,Z))
#16 multiple measurements
# This is a way to test the code, we grab the kth measurement element and apply
# it into the current belief, then recursively update that belief into itself.
# we should get back the uniform distribution
# Modify the code so that it updates the probability twice
# and gives the posterior distribution after both
# measurements are incorporated. Make sure that your code
# allows for any sequence of measurement of any length.
p=[0.2, 0.2, 0.2, 0.2, 0.2]
world=['green', 'red', 'red', 'green', 'green']
measurements = ['red', 'green']
pHit = 0.6
pMiss = 0.2
def sense(p, Z):
q=[]
for i in range(len(p)):
hit = (Z == world[i])
q.append(p[i] * (hit * pHit + (1-hit) * pMiss))
s = sum(q)
for i in range(len(q)):
q[i] = q[i] / s
return q
for k in range(len(measurements)):
p = sense(p, measurements[k])
print(p)
#19 move function
# shift data one cell to the right
# Program a function that returns a new distribution
# q, shifted to the right by U units. If U=0, q should
# be the same as p.
p=[0, 1, 0, 0, 0]
world=['green', 'red', 'red', 'green', 'green']
measurements = ['red', 'green']
pHit = 0.6
pMiss = 0.2
#match the measurement with the belief, measurement update function
def sense(p, Z):
q=[]
for i in range(len(p)):
hit = (Z == world[i])
q.append(p[i] * (hit * pHit + (1-hit) * pMiss))
s = sum(q)
for i in range(len(q)):
q[i] = q[i] / s
return q
def move(p, U):
q = []
for i in range(len(p)):
q.append(p[(i-U)%len(p)]) #minus sign, 1 place to the left
return q
print(move(p, 1))
#23 inexact move function
# Modify the move function to accommodate the added
# probabilities of overshooting and undershooting
# the intended destination.
p=[0, 1, 0, 0, 0]
world=['green', 'red', 'red', 'green', 'green'] #specifies colour of cell
measurements = ['red', 'green']
pHit = 0.6 #probability of hitting the correct colour
pMiss = 0.2 #probability of missing the correct colour
pExact = 0.8
pOvershoot = 0.1
pUndershoot = 0.1
def sense(p, Z):
q=[]
for i in range(len(p)):
hit = (Z == world[i])
q.append(p[i] * (hit * pHit + (1-hit) * pMiss))
s = sum(q)
for i in range(len(q)):
q[i] = q[i] / s
return q
#circle shift
def move(p, U): #grid cells the robot is moving to the right
q = []
for i in range(len(p)):
#auxillary variable
s = pExact * p[(i-U) % len(p)]
s = s + pOvershoot * p[(i-U-1) % len(p)] #one step further
s = s + pUndershoot * p[(i-U+1) % len(p)] #one step behind
q.append(s)
return q
print(move(p,1))
#24 limit distribution
# [1 0 0 0 0] spreads out to [0.2 0.2 0.2 0.2 0.2] after some time
# everytime you move you lose information
# without update, no information
# moving many times without update
# p(x4) = 0.8*x2 + 0.1*x1 + 0.1*x3 balanc equation in the limit
#25 move twice quiz
# Write code that makes the robot move twice and then prints
# out the resulting distribution, starting with the initial
# distribution p = [0, 1, 0, 0, 0]
p=[0, 1, 0, 0, 0]
world=['green', 'red', 'red', 'green', 'green']
measurements = ['red', 'green']
pHit = 0.6
pMiss = 0.2
pExact = 0.8
pOvershoot = 0.1
pUndershoot = 0.1
def sense(p, Z):
q=[]
for i in range(len(p)):
hit = (Z == world[i])
q.append(p[i] * (hit * pHit + (1-hit) * pMiss))
s = sum(q)
for i in range(len(q)):
q[i] = q[i] / s
return q
def move(p, U):
q = []
for i in range(len(p)):
s = pExact * p[(i-U) % len(p)]
s = s + pOvershoot * p[(i-U-1) % len(p)]
s = s + pUndershoot * p[(i-U+1) % len(p)]
q.append(s)
return q
for i in range(1000):
p=move(p,1)
print(p)
#notes:
# localization is sense/move conbination
# everytime it moves robot loses information
# everytime it moves robot regains information
# entropy
#27 sense and move
# Given the list motions=[1,1] which means the robot
# moves right and then right again, compute the posterior
# distribution if the robot first senses red, then moves
# right one, then senses green, then moves right again,
# starting with a uniform prior distribution.
p=[0.2, 0.2, 0.2, 0.2, 0.2]
world=['green', 'red', 'red', 'green', 'green']
measurements = ['red', 'green']
motions = [1,1]
pHit = 0.6
pMiss = 0.2
pExact = 0.8
pOvershoot = 0.1
pUndershoot = 0.1
def sense(p, Z):
q=[]
for i in range(len(p)):
hit = (Z == world[i])
q.append(p[i] * (hit * pHit + (1-hit) * pMiss))
s = sum(q)
for i in range(len(q)):
q[i] = q[i] / s
return q
def move(p, U):
q = []
for i in range(len(p)):
s = pExact * p[(i-U) % len(p)]
s = s + pOvershoot * p[(i-U-1) % len(p)]
s = s + pUndershoot * p[(i-U+1) % len(p)]
q.append(s)
return q
for k in range(len(measurements)):
p = sense(p,measurements[k])
p = move(p,motions[k])
print(p) #results show that robot most likely ended up in the 5th cell
#28 move twice
# Modify the previous code so that the robot senses red twice.
p=[0.2, 0.2, 0.2, 0.2, 0.2]
world=['green', 'red', 'red', 'green', 'green']
measurements = ['red', 'red']
motions = [1,1]
pHit = 0.6
pMiss = 0.2
pExact = 0.8
pOvershoot = 0.1
pUndershoot = 0.1
def sense(p, Z):
q=[]
for i in range(len(p)):
hit = (Z == world[i])
q.append(p[i] * (hit * pHit + (1-hit) * pMiss))
s = sum(q)
for i in range(len(q)):
q[i] = q[i] / s
return q
def move(p, U):
q = []
for i in range(len(p)):
s = pExact * p[(i-U) % len(p)]
s = s + pOvershoot * p[(i-U-1) % len(p)]
s = s + pUndershoot * p[(i-U+1) % len(p)]
q.append(s)
return q
for k in range(len(measurements)):
p = sense(p, measurements[k])
p = move(p, motions[k])
print(p)
# most likely in 4th cell, it's the cell after the last observation
# this is the essense of google's self driving car code
# It is crucial that the car knows where it is.
# While the road is not painted red and green, the road has lane markers.
# instead of read and green cells over here, we plug in the colour of the pavement
# versus the colour of the lane markers, it isn't just one observation per time
# step, it is an entire field of observations. an entire camara image.
# As long as you can correspond a car image in your model, with a camera image in
# your model, then the piece of code is not much more difficult than what I have here. | p = [0.2, 0.2, 0.2, 0.2, 0.2]
print(p)
p = []
n = 5
for i in range(n):
p.append(1 / n)
print(p)
p_hit = 0.6
p_miss = 0.2
p[0] = p[0] * pMiss
p[1] = p[1] * pHit
p[2] = p[2] * pHit
p[3] = p[3] * pMiss
p[4] = p[4] * pMiss
print(p)
print(sum(p))
p = [0.2, 0.2, 0.2, 0.2, 0.2]
world = ['green', 'red', 'red', 'green', 'green']
z = 'red'
p_hit = 0.6
p_miss = 0.2
def sense(p, Z):
q = []
for i in range(len(p)):
hit = Z == world[i]
q.append(p[i] * (hit * pHit + (1 - hit) * pMiss))
s = sum(q)
for i in range(len(p)):
q[i] = q[i] / s
return q
print(sense(p, Z))
p = [0.2, 0.2, 0.2, 0.2, 0.2]
world = ['green', 'red', 'red', 'green', 'green']
measurements = ['red', 'green']
p_hit = 0.6
p_miss = 0.2
def sense(p, Z):
q = []
for i in range(len(p)):
hit = Z == world[i]
q.append(p[i] * (hit * pHit + (1 - hit) * pMiss))
s = sum(q)
for i in range(len(q)):
q[i] = q[i] / s
return q
for k in range(len(measurements)):
p = sense(p, measurements[k])
print(p)
p = [0, 1, 0, 0, 0]
world = ['green', 'red', 'red', 'green', 'green']
measurements = ['red', 'green']
p_hit = 0.6
p_miss = 0.2
def sense(p, Z):
q = []
for i in range(len(p)):
hit = Z == world[i]
q.append(p[i] * (hit * pHit + (1 - hit) * pMiss))
s = sum(q)
for i in range(len(q)):
q[i] = q[i] / s
return q
def move(p, U):
q = []
for i in range(len(p)):
q.append(p[(i - U) % len(p)])
return q
print(move(p, 1))
p = [0, 1, 0, 0, 0]
world = ['green', 'red', 'red', 'green', 'green']
measurements = ['red', 'green']
p_hit = 0.6
p_miss = 0.2
p_exact = 0.8
p_overshoot = 0.1
p_undershoot = 0.1
def sense(p, Z):
q = []
for i in range(len(p)):
hit = Z == world[i]
q.append(p[i] * (hit * pHit + (1 - hit) * pMiss))
s = sum(q)
for i in range(len(q)):
q[i] = q[i] / s
return q
def move(p, U):
q = []
for i in range(len(p)):
s = pExact * p[(i - U) % len(p)]
s = s + pOvershoot * p[(i - U - 1) % len(p)]
s = s + pUndershoot * p[(i - U + 1) % len(p)]
q.append(s)
return q
print(move(p, 1))
p = [0, 1, 0, 0, 0]
world = ['green', 'red', 'red', 'green', 'green']
measurements = ['red', 'green']
p_hit = 0.6
p_miss = 0.2
p_exact = 0.8
p_overshoot = 0.1
p_undershoot = 0.1
def sense(p, Z):
q = []
for i in range(len(p)):
hit = Z == world[i]
q.append(p[i] * (hit * pHit + (1 - hit) * pMiss))
s = sum(q)
for i in range(len(q)):
q[i] = q[i] / s
return q
def move(p, U):
q = []
for i in range(len(p)):
s = pExact * p[(i - U) % len(p)]
s = s + pOvershoot * p[(i - U - 1) % len(p)]
s = s + pUndershoot * p[(i - U + 1) % len(p)]
q.append(s)
return q
for i in range(1000):
p = move(p, 1)
print(p)
p = [0.2, 0.2, 0.2, 0.2, 0.2]
world = ['green', 'red', 'red', 'green', 'green']
measurements = ['red', 'green']
motions = [1, 1]
p_hit = 0.6
p_miss = 0.2
p_exact = 0.8
p_overshoot = 0.1
p_undershoot = 0.1
def sense(p, Z):
q = []
for i in range(len(p)):
hit = Z == world[i]
q.append(p[i] * (hit * pHit + (1 - hit) * pMiss))
s = sum(q)
for i in range(len(q)):
q[i] = q[i] / s
return q
def move(p, U):
q = []
for i in range(len(p)):
s = pExact * p[(i - U) % len(p)]
s = s + pOvershoot * p[(i - U - 1) % len(p)]
s = s + pUndershoot * p[(i - U + 1) % len(p)]
q.append(s)
return q
for k in range(len(measurements)):
p = sense(p, measurements[k])
p = move(p, motions[k])
print(p)
p = [0.2, 0.2, 0.2, 0.2, 0.2]
world = ['green', 'red', 'red', 'green', 'green']
measurements = ['red', 'red']
motions = [1, 1]
p_hit = 0.6
p_miss = 0.2
p_exact = 0.8
p_overshoot = 0.1
p_undershoot = 0.1
def sense(p, Z):
q = []
for i in range(len(p)):
hit = Z == world[i]
q.append(p[i] * (hit * pHit + (1 - hit) * pMiss))
s = sum(q)
for i in range(len(q)):
q[i] = q[i] / s
return q
def move(p, U):
q = []
for i in range(len(p)):
s = pExact * p[(i - U) % len(p)]
s = s + pOvershoot * p[(i - U - 1) % len(p)]
s = s + pUndershoot * p[(i - U + 1) % len(p)]
q.append(s)
return q
for k in range(len(measurements)):
p = sense(p, measurements[k])
p = move(p, motions[k])
print(p) |
BASE_DEPS = [
"//jflex",
"//jflex:testing",
"//java/jflex/testing/testsuite",
"//third_party/com/google/truth",
]
def jflex_testsuite(**kwargs):
args = update_args(kwargs)
native.java_test(**args)
def update_args(kwargs):
if ("deps" in kwargs):
kwargs["deps"] = kwargs["deps"] + BASE_DEPS
else:
kwargs["deps"] = BASE_DEPS
return kwargs
| base_deps = ['//jflex', '//jflex:testing', '//java/jflex/testing/testsuite', '//third_party/com/google/truth']
def jflex_testsuite(**kwargs):
args = update_args(kwargs)
native.java_test(**args)
def update_args(kwargs):
if 'deps' in kwargs:
kwargs['deps'] = kwargs['deps'] + BASE_DEPS
else:
kwargs['deps'] = BASE_DEPS
return kwargs |
# Time: O(m * n)
# Space: O(1)
class Solution(object):
def isToeplitzMatrix(self, matrix):
"""
:type matrix: List[List[int]]
:rtype: bool
"""
return all(i == 0 or j == 0 or matrix[i-1][j-1] == val
for i, row in enumerate(matrix)
for j, val in enumerate(row))
class Solution2(object):
def isToeplitzMatrix(self, matrix):
"""
:type matrix: List[List[int]]
:rtype: bool
"""
for row_index, row in enumerate(matrix):
for digit_index, digit in enumerate(row):
if not row_index or not digit_index:
continue
if matrix[row_index - 1][digit_index - 1] != digit:
return False
return True
| class Solution(object):
def is_toeplitz_matrix(self, matrix):
"""
:type matrix: List[List[int]]
:rtype: bool
"""
return all((i == 0 or j == 0 or matrix[i - 1][j - 1] == val for (i, row) in enumerate(matrix) for (j, val) in enumerate(row)))
class Solution2(object):
def is_toeplitz_matrix(self, matrix):
"""
:type matrix: List[List[int]]
:rtype: bool
"""
for (row_index, row) in enumerate(matrix):
for (digit_index, digit) in enumerate(row):
if not row_index or not digit_index:
continue
if matrix[row_index - 1][digit_index - 1] != digit:
return False
return True |
ISCSI_CONNECTIVITY_TYPE = "iscsi"
FC_CONNECTIVITY_TYPE = "fc"
SPACE_EFFICIENCY_THIN = 'thin'
SPACE_EFFICIENCY_COMPRESSED = 'compressed'
SPACE_EFFICIENCY_DEDUPLICATED = 'deduplicated'
SPACE_EFFICIENCY_THICK = 'thick'
SPACE_EFFICIENCY_NONE = 'none'
# volume context
CONTEXT_POOL = "pool"
| iscsi_connectivity_type = 'iscsi'
fc_connectivity_type = 'fc'
space_efficiency_thin = 'thin'
space_efficiency_compressed = 'compressed'
space_efficiency_deduplicated = 'deduplicated'
space_efficiency_thick = 'thick'
space_efficiency_none = 'none'
context_pool = 'pool' |
bch_code_parameters = {
3:{
1:4
},
4:{
1:11,
2:7,
3:5
},
5:{
1:26,
2:21,
3:16,
5:11,
7:6
},
6:{
1:57,
2:51,
3:45,
4:39,
5:36,
6:30,
7:24,
10:18,
11:16,
13:10,
15:7
},
7:{
1:120,
2:113,
3:106,
4:99,
5:92,
6:85,
7:78,
9:71,
10:64,
11:57,
13:50,
14:43,
15:36,
21:29,
23:22,
27:15,
31:8
},
8:{
1:247,
2:239,
3:231,
4:223,
5:215,
6:207,
7:199,
8:191,
9:187,
10:179,
11:171,
12:163,
13:155,
14:147,
15:139,
18:131,
19:123,
21:115,
22:107,
23:99,
25:91,
26:87,
27:79,
29:71,
30:63,
31:55,
42:47,
43:45,
45:37,
47:29,
55:21,
59:13,
63:9
}
}
| bch_code_parameters = {3: {1: 4}, 4: {1: 11, 2: 7, 3: 5}, 5: {1: 26, 2: 21, 3: 16, 5: 11, 7: 6}, 6: {1: 57, 2: 51, 3: 45, 4: 39, 5: 36, 6: 30, 7: 24, 10: 18, 11: 16, 13: 10, 15: 7}, 7: {1: 120, 2: 113, 3: 106, 4: 99, 5: 92, 6: 85, 7: 78, 9: 71, 10: 64, 11: 57, 13: 50, 14: 43, 15: 36, 21: 29, 23: 22, 27: 15, 31: 8}, 8: {1: 247, 2: 239, 3: 231, 4: 223, 5: 215, 6: 207, 7: 199, 8: 191, 9: 187, 10: 179, 11: 171, 12: 163, 13: 155, 14: 147, 15: 139, 18: 131, 19: 123, 21: 115, 22: 107, 23: 99, 25: 91, 26: 87, 27: 79, 29: 71, 30: 63, 31: 55, 42: 47, 43: 45, 45: 37, 47: 29, 55: 21, 59: 13, 63: 9}} |
XXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXX
| XXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXX |
"""
A collection of update operations for TinyDB.
They are used for updates like this:
>>> db.update(delete('foo'), where('foo') == 2)
This would delete the ``foo`` field from all documents where ``foo`` equals 2.
"""
def delete(field):
"""
Delete a given field from the document.
"""
def transform(doc):
del doc[field]
return transform
def add(field, n):
"""
Add ``n`` to a given field in the document.
"""
def transform(doc):
doc[field] += n
return transform
def subtract(field, n):
"""
Substract ``n`` to a given field in the document.
"""
def transform(doc):
doc[field] -= n
return transform
def set(field, val):
"""
Set a given field to ``val``.
"""
def transform(doc):
doc[field] = val
return transform
def increment(field):
"""
Increment a given field in the document by 1.
"""
def transform(doc):
doc[field] += 1
return transform
def decrement(field):
"""
Decrement a given field in the document by 1.
"""
def transform(doc):
doc[field] -= 1
return transform
| """
A collection of update operations for TinyDB.
They are used for updates like this:
>>> db.update(delete('foo'), where('foo') == 2)
This would delete the ``foo`` field from all documents where ``foo`` equals 2.
"""
def delete(field):
"""
Delete a given field from the document.
"""
def transform(doc):
del doc[field]
return transform
def add(field, n):
"""
Add ``n`` to a given field in the document.
"""
def transform(doc):
doc[field] += n
return transform
def subtract(field, n):
"""
Substract ``n`` to a given field in the document.
"""
def transform(doc):
doc[field] -= n
return transform
def set(field, val):
"""
Set a given field to ``val``.
"""
def transform(doc):
doc[field] = val
return transform
def increment(field):
"""
Increment a given field in the document by 1.
"""
def transform(doc):
doc[field] += 1
return transform
def decrement(field):
"""
Decrement a given field in the document by 1.
"""
def transform(doc):
doc[field] -= 1
return transform |
CONFIGS = {
"session": "1",
"store_location": ".",
"folder": "Estudiante_1",
"video": True,
"audio": False,
"mqtt_hostname": "10.42.0.1",
"mqtt_username" : "james",
"mqtt_password" : "james",
"mqtt_port" : 1883,
"dev_id": "1",
"rap_server": "10.42.0.1"
}
CAMERA = {
"brightness": 60,
"saturation": -60,
"contrast" : 0,
# "resolution": (1280,720),
# "resolution": (1296,972),
"resolution": (640, 480),
"framerate": 5
}
#SERVER_URL = '200.10.150.237:50052' # Servidor bio
SERVER_URL = '200.126.23.95:50052' # Servidor sala RAP
| configs = {'session': '1', 'store_location': '.', 'folder': 'Estudiante_1', 'video': True, 'audio': False, 'mqtt_hostname': '10.42.0.1', 'mqtt_username': 'james', 'mqtt_password': 'james', 'mqtt_port': 1883, 'dev_id': '1', 'rap_server': '10.42.0.1'}
camera = {'brightness': 60, 'saturation': -60, 'contrast': 0, 'resolution': (640, 480), 'framerate': 5}
server_url = '200.126.23.95:50052' |
"""
# Sample code to perform I/O:
name = input() # Reading input from STDIN
print('Hi, %s.' % name) # Writing output to STDOUT
# Warning: Printing unwanted or ill-formatted data to output will cause the test cases to fail
"""
# Write your code here
n = int(input())
directions = list(map(int, input().strip().split()))
to_right_forward = [0] * n
to_right_opposite = [0] * n
to_left_forward = [0] * n
to_left_opposite = [0] * n
for i in range(n - 1):
if not directions[i]:
to_right_opposite[i + 1] = to_right_opposite[i] + 1
else:
to_right_forward[i + 1] = to_right_forward[i] + 1
if not directions[n - 2 - i]:
to_left_forward[n - 2 - i] = to_left_forward[n - 1 - i] + 1
else:
to_left_opposite[n - 2 - i] = to_left_opposite[n - 1 - i] + 1
for i in range(n):
to_right_forward[i] += to_left_forward[i] + 1
to_right_opposite[i] += to_left_opposite[i] + 1
val = 0
q = int(input())
for _ in range(q):
q_line = input().strip().split()
if q_line[0] == 'U':
val = 1 - val
else:
if val % 2:
print(to_right_forward[int(q_line[-1]) - 1])
else:
print(to_right_opposite[int(q_line[-1]) - 1])
| """
# Sample code to perform I/O:
name = input() # Reading input from STDIN
print('Hi, %s.' % name) # Writing output to STDOUT
# Warning: Printing unwanted or ill-formatted data to output will cause the test cases to fail
"""
n = int(input())
directions = list(map(int, input().strip().split()))
to_right_forward = [0] * n
to_right_opposite = [0] * n
to_left_forward = [0] * n
to_left_opposite = [0] * n
for i in range(n - 1):
if not directions[i]:
to_right_opposite[i + 1] = to_right_opposite[i] + 1
else:
to_right_forward[i + 1] = to_right_forward[i] + 1
if not directions[n - 2 - i]:
to_left_forward[n - 2 - i] = to_left_forward[n - 1 - i] + 1
else:
to_left_opposite[n - 2 - i] = to_left_opposite[n - 1 - i] + 1
for i in range(n):
to_right_forward[i] += to_left_forward[i] + 1
to_right_opposite[i] += to_left_opposite[i] + 1
val = 0
q = int(input())
for _ in range(q):
q_line = input().strip().split()
if q_line[0] == 'U':
val = 1 - val
elif val % 2:
print(to_right_forward[int(q_line[-1]) - 1])
else:
print(to_right_opposite[int(q_line[-1]) - 1]) |
def solution(A):
exchange_0 = exchange_1 = pos = -1
idx = 1
while idx < len(A):
if A[idx] < A[idx - 1]:
if exchange_0 == -1:
exchange_0 = A[idx - 1]
exchange_1 = A[idx]
else:
return False
if exchange_0 > 0:
if A[idx] > exchange_0:
if A[idx - 1] > exchange_1:
return False
else:
pos = idx - 1
idx += 1
if exchange_0 == exchange_1 == pos == -1:
return True
else:
return True if pos != -1 else False
| def solution(A):
exchange_0 = exchange_1 = pos = -1
idx = 1
while idx < len(A):
if A[idx] < A[idx - 1]:
if exchange_0 == -1:
exchange_0 = A[idx - 1]
exchange_1 = A[idx]
else:
return False
if exchange_0 > 0:
if A[idx] > exchange_0:
if A[idx - 1] > exchange_1:
return False
else:
pos = idx - 1
idx += 1
if exchange_0 == exchange_1 == pos == -1:
return True
else:
return True if pos != -1 else False |
### WARNING WARNING WARNING WARNING WARNING WARNING WARNING WARNING WARNING
###
### This file MUST be edited properly and copied to settings.py in order for
### SMS functionality to work. Get set up on Twilio.com for the required API
### keys and phone number settings.
###
### WARNING WARNING WARNING WARNING WARNING WARNING WARNING WARNING WARNING
# These are Twilio API settings. Sign up at Twilio to get them.
account_sid = "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"
auth_token = "XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"
# The number the SMS is from. Must be valid on your Twilio account.
phone_from="+1213XXXYYYY"
# The number to send the SMS to (your cell phone number)
phone_to="+1808XXXYYYY"
| account_sid = 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX'
auth_token = 'XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX'
phone_from = '+1213XXXYYYY'
phone_to = '+1808XXXYYYY' |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.