content stringlengths 7 1.05M | fixed_cases stringlengths 1 1.28M |
|---|---|
'''
Author : kazi_amit_hasan
Problem: Hello 2019,Problem A
Solution: Just check that first input is present in next input or not
'''
t= input()
h = input()
if t[0] in h or t[1] in h:
print("YES")
else:
print("NO")
| """
Author : kazi_amit_hasan
Problem: Hello 2019,Problem A
Solution: Just check that first input is present in next input or not
"""
t = input()
h = input()
if t[0] in h or t[1] in h:
print('YES')
else:
print('NO') |
#!/usr/bin/py
# Head ends here
def pairs(a,k):
# a is the list of numbers and k is the difference value
count = 0
compls = {}
for i in a:
if i in compls:
count += compls[i]
compls[i + k] = compls[i + k] + 1 if i+k in compls else 1
compls[i - k] = compls[i - k] + 1 if i-k in compls else 1
return count
# Tail starts here
if __name__ == '__main__':
a = input().strip()
a = list(map(int, a.split(' ')))
_a_size=a[0]
_k=a[1]
b = input().strip()
b = list(map(int, b.split(' ')))
print(pairs(b,_k))
| def pairs(a, k):
count = 0
compls = {}
for i in a:
if i in compls:
count += compls[i]
compls[i + k] = compls[i + k] + 1 if i + k in compls else 1
compls[i - k] = compls[i - k] + 1 if i - k in compls else 1
return count
if __name__ == '__main__':
a = input().strip()
a = list(map(int, a.split(' ')))
_a_size = a[0]
_k = a[1]
b = input().strip()
b = list(map(int, b.split(' ')))
print(pairs(b, _k)) |
def main():
for i in range (1001, 3339):
a = i
b = a + 3330
c = b + 3330
flag = False
flag2 = False
for eachNum in str(a):
if not (eachNum in str(b) or eachNum in str(c)):
for eachOtherNum in str(b):
if not eachOtherNum in str(c):
flag = True
if flag:
for eachNum in str(a):
if isPrime(int(eachNum)):
flag2 = True
if flag2:
if isPrime(a) and isPrime(b) and isPrime(c):
print(str(a) + str(b) + str(c))
return
def isPrime(n):
for i in range(2, int(n ** 0.5) + 1):
if n%i == 0:
return True
return False
if __name__ == '__main__':
main()
| def main():
for i in range(1001, 3339):
a = i
b = a + 3330
c = b + 3330
flag = False
flag2 = False
for each_num in str(a):
if not (eachNum in str(b) or eachNum in str(c)):
for each_other_num in str(b):
if not eachOtherNum in str(c):
flag = True
if flag:
for each_num in str(a):
if is_prime(int(eachNum)):
flag2 = True
if flag2:
if is_prime(a) and is_prime(b) and is_prime(c):
print(str(a) + str(b) + str(c))
return
def is_prime(n):
for i in range(2, int(n ** 0.5) + 1):
if n % i == 0:
return True
return False
if __name__ == '__main__':
main() |
SUPPORT_PROTOCOL_VERSIONS = [3, 4]
SUPPORT_PROTOCOLS = ["MQIsdp" ,"MQTT"]
class TYPE():
R_0 = "\x00"
CONNECT = "\01"
CONNACK = "\x02"
PUBLISH = "\x03"
PUBACK = "\x04"
PUBREC = "\x05"
PUBREL = "\x06"
PUBCOMP = "\x07"
SUBSCRIBE = "\x08"
SUBACK = "\x09"
UNSUBSCRIBE = "\x0a"
UNSUBACK = "\x0b"
PINGREQ = "\x0c"
PINGRESP = "\x0d"
DISCONNECT = "\x0e"
R_15 = "\x0f"
@classmethod
def string(cls, num):
if num == cls.CONNECT:
return "CONNECT"
elif num == cls.CONNACK:
return "CONNACK"
elif num == cls.PUBLISH:
return "PUBLISH"
elif num == cls.PUBACK:
return "PUBACK"
elif num == cls.PUBREC:
return "PUBREC"
elif num == cls.PUBREL:
return "PUBREL"
elif num == cls.PUBCOMP:
return "PUBCOMP"
elif num == cls.SUBSCRIBE:
return "SUBSCRIBE"
elif num == cls.SUBACK:
return "SUBACK"
elif num == cls.UNSUBSCRIBE:
return "UNSUBSCRIBE"
elif num == cls.UNSUBACK:
return "UNSUBACK"
elif num == cls.PINGREQ:
return "PINGREQ"
elif num == cls.PINGRESP:
return "PINGRESP"
elif num == cls.DISCONNECT:
return "DISCONNECT"
else:
return "WARNNING: undefined type %s" % num
class ConnectReturn():
ACCEPTED = "\x00"
R_UNACCEPTABLE_PROTOCOL_VERSION = "\x01"
R_ID_REJECTED = "\02"
R_SERVER_UNAVAILABLE = "\x03"
R_BAD_NAME_PASS = "\04"
R_NOT_AUTHORIZED = "\x05"
@classmethod
def string(cls, num):
if num == cls.ACCEPTED:
return "CONNECTION ACCEPTED"
elif num == cls.R_UNACCEPTABLE_PROTOCOL_VERSION:
return "UNACCEPTABLE PROTOCOL VERSION"
elif num == cls.R_ID_REJECTED:
return "IDENTIFIER REJECTED"
elif num == cls.R_SERVER_UNAVAILABLE:
return "SERVER UNAVAILABLE"
elif num == cls.R_BAD_NAME_PASS:
return "BAD USER NAME OR PASSWORD"
elif num == cls.R_NOT_AUTHORIZED:
return "NOT AUTHORIZED"
else:
return "WARNNING: undefined code %s" % num
| support_protocol_versions = [3, 4]
support_protocols = ['MQIsdp', 'MQTT']
class Type:
r_0 = '\x00'
connect = '\x01'
connack = '\x02'
publish = '\x03'
puback = '\x04'
pubrec = '\x05'
pubrel = '\x06'
pubcomp = '\x07'
subscribe = '\x08'
suback = '\t'
unsubscribe = '\n'
unsuback = '\x0b'
pingreq = '\x0c'
pingresp = '\r'
disconnect = '\x0e'
r_15 = '\x0f'
@classmethod
def string(cls, num):
if num == cls.CONNECT:
return 'CONNECT'
elif num == cls.CONNACK:
return 'CONNACK'
elif num == cls.PUBLISH:
return 'PUBLISH'
elif num == cls.PUBACK:
return 'PUBACK'
elif num == cls.PUBREC:
return 'PUBREC'
elif num == cls.PUBREL:
return 'PUBREL'
elif num == cls.PUBCOMP:
return 'PUBCOMP'
elif num == cls.SUBSCRIBE:
return 'SUBSCRIBE'
elif num == cls.SUBACK:
return 'SUBACK'
elif num == cls.UNSUBSCRIBE:
return 'UNSUBSCRIBE'
elif num == cls.UNSUBACK:
return 'UNSUBACK'
elif num == cls.PINGREQ:
return 'PINGREQ'
elif num == cls.PINGRESP:
return 'PINGRESP'
elif num == cls.DISCONNECT:
return 'DISCONNECT'
else:
return 'WARNNING: undefined type %s' % num
class Connectreturn:
accepted = '\x00'
r_unacceptable_protocol_version = '\x01'
r_id_rejected = '\x02'
r_server_unavailable = '\x03'
r_bad_name_pass = '\x04'
r_not_authorized = '\x05'
@classmethod
def string(cls, num):
if num == cls.ACCEPTED:
return 'CONNECTION ACCEPTED'
elif num == cls.R_UNACCEPTABLE_PROTOCOL_VERSION:
return 'UNACCEPTABLE PROTOCOL VERSION'
elif num == cls.R_ID_REJECTED:
return 'IDENTIFIER REJECTED'
elif num == cls.R_SERVER_UNAVAILABLE:
return 'SERVER UNAVAILABLE'
elif num == cls.R_BAD_NAME_PASS:
return 'BAD USER NAME OR PASSWORD'
elif num == cls.R_NOT_AUTHORIZED:
return 'NOT AUTHORIZED'
else:
return 'WARNNING: undefined code %s' % num |
class Solution:
def diagonalSum(self, mat: List[List[int]]) -> int:
total = 0
for i in range(len(mat)):
total += mat[i][i] # elements from the primary diagonal
total += mat[i][len(mat)-1-i] # secondary diagonal
if len(mat) % 2 == 0:
return total
return total - mat[len(mat)//2][len(mat)//2]
| class Solution:
def diagonal_sum(self, mat: List[List[int]]) -> int:
total = 0
for i in range(len(mat)):
total += mat[i][i]
total += mat[i][len(mat) - 1 - i]
if len(mat) % 2 == 0:
return total
return total - mat[len(mat) // 2][len(mat) // 2] |
valorPorHora = float(input('Quanto voce ganha por hora: '))
horasTrabalhadas = float(input('Quantas horas voce trabalhou no mes: '))
salarioBruto = valorPorHora * horasTrabalhadas
impostoRenda = salarioBruto * 0.11
inss = salarioBruto * 0.08
sindicato = salarioBruto * 0.05
salarioLiquido = salarioBruto - impostoRenda - inss - sindicato
print('Salario Bruto:', salarioBruto)
print('Imposto de Renda:', impostoRenda)
print('INSS:', inss)
print('Sindicato:', sindicato)
print('Salario Liquido:', salarioLiquido)
| valor_por_hora = float(input('Quanto voce ganha por hora: '))
horas_trabalhadas = float(input('Quantas horas voce trabalhou no mes: '))
salario_bruto = valorPorHora * horasTrabalhadas
imposto_renda = salarioBruto * 0.11
inss = salarioBruto * 0.08
sindicato = salarioBruto * 0.05
salario_liquido = salarioBruto - impostoRenda - inss - sindicato
print('Salario Bruto:', salarioBruto)
print('Imposto de Renda:', impostoRenda)
print('INSS:', inss)
print('Sindicato:', sindicato)
print('Salario Liquido:', salarioLiquido) |
def define_best_name(name1, name2):
if len(name1) > len(name2):
return name1
return name2
my_name = "Tom Thompsom"
your_name = "Lauretius Maximus"
the_best_name = define_best_name(my_name, your_name) | def define_best_name(name1, name2):
if len(name1) > len(name2):
return name1
return name2
my_name = 'Tom Thompsom'
your_name = 'Lauretius Maximus'
the_best_name = define_best_name(my_name, your_name) |
BATCH_SIZE = 512
D_MODEL = 512
P_DROP = 0.1
D_FF = 2048
HEADS = 8
LAYERS = 6
LR = 1e-3
EPOCHS = 40 | batch_size = 512
d_model = 512
p_drop = 0.1
d_ff = 2048
heads = 8
layers = 6
lr = 0.001
epochs = 40 |
# Definition for singly-linked list.
# class ListNode:
# def __init__(self, val=0, next=None):
# self.val = val
# self.next = next
class Solution:
def rotateRight(self, head: Optional[ListNode], k: int) -> Optional[ListNode]:
if head is None:
return head
#Find length and last node of list
length = 1
tail = head
while tail.next is not None:
tail = tail.next
length += 1
#Reduce rotations by using k mod length
k = k % length
#In case k is 0, return head
if k == 0:
return head
#Find the node prev to Kth node from end
curr = head
for _ in range(length - k - 1):
curr = curr.next
#New head with the node next to prev, here next to the current
#Store new head, assign curr.next to None and link last node's next to head
newHead = curr.next
curr.next = None
tail.next = head
return newHead | class Solution:
def rotate_right(self, head: Optional[ListNode], k: int) -> Optional[ListNode]:
if head is None:
return head
length = 1
tail = head
while tail.next is not None:
tail = tail.next
length += 1
k = k % length
if k == 0:
return head
curr = head
for _ in range(length - k - 1):
curr = curr.next
new_head = curr.next
curr.next = None
tail.next = head
return newHead |
# Python - 3.4.3
fib = {0: 0, 1: 1}
def fibonacci(n):
if not n in fib:
fib[n - 2] = fibonacci(n - 2)
fib[n - 1] = fibonacci(n - 1)
fib[n] = fib[n - 1] + fib[n - 2]
return fib[n]
| fib = {0: 0, 1: 1}
def fibonacci(n):
if not n in fib:
fib[n - 2] = fibonacci(n - 2)
fib[n - 1] = fibonacci(n - 1)
fib[n] = fib[n - 1] + fib[n - 2]
return fib[n] |
# Try comparison operators in this quiz! This code calculates the
# population densities of Rio de Janeiro and San Francisco.
sf_population, sf_area = 864816, 231.89
rio_population, rio_area = 6453682, 486.5
san_francisco_pop_density = sf_population/sf_area
rio_de_janeiro_pop_density = rio_population/rio_area
# Write code that prints True if San Francisco is denser than Rio,
# and False otherwise
print(san_francisco_pop_density > rio_de_janeiro_pop_density)
# The bool data type holds one of the values True or False, which are
# often encoded as 1 or 0, respectively.
# There are 6 comparison operators that are common to see in order to
# obtain a bool value:
# < : Less Than
# > : Greater Than
# <= : Less Than or Equal To
# >= : Greater Than or Equal To
# == : Equal to
# != : Not Equal to
# And there are 3 logical operators you need to be familiar with:
# and - Evaluates if all provided statements are True
# or - Evaluates if at least one of many statements is True
# not - Flips the Bool Value
| (sf_population, sf_area) = (864816, 231.89)
(rio_population, rio_area) = (6453682, 486.5)
san_francisco_pop_density = sf_population / sf_area
rio_de_janeiro_pop_density = rio_population / rio_area
print(san_francisco_pop_density > rio_de_janeiro_pop_density) |
def create_matrix(rows):
result = []
for _ in range(rows):
row = [int(el) for el in input().split(", ")]
result.append(row)
return result
def get_biggest_sum_elements(matrix, r, c):
result = [matrix[r][c:c + 2], matrix[r + 1][c:c + 2]]
return result
def print_result(biggest_sum, biggest_sum_elements):
for el in biggest_sum_elements:
print(*list(map(str, el)), sep=" ")
print(biggest_sum)
rows, columns = list(map(int, input().split(", ")))
matrix = (create_matrix(rows))
sum_square = 0
biggest_sum_square = sum_square
for c in range(columns - 1):
for r in range(rows - 1):
sum_square = matrix[r][c] + matrix[r+1][c] + matrix[r+1][c+1] + matrix[r][c+1]
if sum_square > biggest_sum_square:
biggest_sum_square = sum_square
biggest_sum_elements = get_biggest_sum_elements(matrix, r, c)
print_result(biggest_sum_square, biggest_sum_elements) | def create_matrix(rows):
result = []
for _ in range(rows):
row = [int(el) for el in input().split(', ')]
result.append(row)
return result
def get_biggest_sum_elements(matrix, r, c):
result = [matrix[r][c:c + 2], matrix[r + 1][c:c + 2]]
return result
def print_result(biggest_sum, biggest_sum_elements):
for el in biggest_sum_elements:
print(*list(map(str, el)), sep=' ')
print(biggest_sum)
(rows, columns) = list(map(int, input().split(', ')))
matrix = create_matrix(rows)
sum_square = 0
biggest_sum_square = sum_square
for c in range(columns - 1):
for r in range(rows - 1):
sum_square = matrix[r][c] + matrix[r + 1][c] + matrix[r + 1][c + 1] + matrix[r][c + 1]
if sum_square > biggest_sum_square:
biggest_sum_square = sum_square
biggest_sum_elements = get_biggest_sum_elements(matrix, r, c)
print_result(biggest_sum_square, biggest_sum_elements) |
global v, foo
v = 1
v = 2
print(v)
def foo():
return 1
try:
def foo():
return 2
except RuntimeError:
print("RuntimeError1")
print(foo())
def __main__():
pass
| global v, foo
v = 1
v = 2
print(v)
def foo():
return 1
try:
def foo():
return 2
except RuntimeError:
print('RuntimeError1')
print(foo())
def __main__():
pass |
# Problem: https://www.hackerrank.com/challenges/list-comprehensions/problem
if __name__ == '__main__':
x = int(input())
y = int(input())
z = int(input())
n = int(input())
| if __name__ == '__main__':
x = int(input())
y = int(input())
z = int(input())
n = int(input()) |
class Pessoa:
tamanho_cpf = 11
p = Pessoa()
print(p.tamanho_cpf)
p.tamanho_cpf = 12
print(p.tamanho_cpf)
print(Pessoa.tamanho_cpf) | class Pessoa:
tamanho_cpf = 11
p = pessoa()
print(p.tamanho_cpf)
p.tamanho_cpf = 12
print(p.tamanho_cpf)
print(Pessoa.tamanho_cpf) |
__version__ = '1.8'
__name__ = 'Zhihu Favorite'
class Document:
def __init__(self, meta, content):
self.meta = meta
self.content = content
self.images = list()
def convert2(self, converter, file):
file.write(converter(self).tostring())
class DocBuilder:
def __init__(self, doc: Document):
self.doc = doc
class MarkdownBuilder(DocBuilder):
pass
class HtmlBuilder(DocBuilder):
pass
| __version__ = '1.8'
__name__ = 'Zhihu Favorite'
class Document:
def __init__(self, meta, content):
self.meta = meta
self.content = content
self.images = list()
def convert2(self, converter, file):
file.write(converter(self).tostring())
class Docbuilder:
def __init__(self, doc: Document):
self.doc = doc
class Markdownbuilder(DocBuilder):
pass
class Htmlbuilder(DocBuilder):
pass |
class Player:
def __init__(self, name: str, sprint: int, dribble: int, passing: int, shooting: int):
self.__name = name
self.__sprint = sprint
self.__dribble = dribble
self.__passing = passing
self.__shooting = shooting
@property
def name(self):
return self.__name
def __str__(self):
return f"Player: {self.__name}\nSprint: {self.__sprint}\nDribble: {self.__dribble}\nPassing: {self.__passing}\nShooting: {self.__shooting}"
| class Player:
def __init__(self, name: str, sprint: int, dribble: int, passing: int, shooting: int):
self.__name = name
self.__sprint = sprint
self.__dribble = dribble
self.__passing = passing
self.__shooting = shooting
@property
def name(self):
return self.__name
def __str__(self):
return f'Player: {self.__name}\nSprint: {self.__sprint}\nDribble: {self.__dribble}\nPassing: {self.__passing}\nShooting: {self.__shooting}' |
def designerPdfViewer(h, word):
word = list(word)
height = 0
width = len(word)
for x in word:
current = h[ord(x)-97]
if current > height:
height = current
return height * width | def designer_pdf_viewer(h, word):
word = list(word)
height = 0
width = len(word)
for x in word:
current = h[ord(x) - 97]
if current > height:
height = current
return height * width |
pkgname = "lame"
pkgver = "3.100"
pkgrel = 0
build_style = "gnu_configure"
configure_args = ["--enable-nasm", "--enable-shared"]
hostmakedepends = ["nasm"]
makedepends = ["ncurses-devel"]
pkgdesc = "Fast, high quality MP3 encoder"
maintainer = "q66 <q66@chimera-linux.org>"
license = "LGPL-2.1-or-later"
url = "https://lame.sourceforge.io"
source = f"$(SOURCEFORGE_SITE)/{pkgname}/{pkgname}-{pkgver}.tar.gz"
sha256 = "ddfe36cab873794038ae2c1210557ad34857a4b6bdc515785d1da9e175b1da1e"
@subpackage("lame-devel")
def _devel(self):
return self.default_devel()
| pkgname = 'lame'
pkgver = '3.100'
pkgrel = 0
build_style = 'gnu_configure'
configure_args = ['--enable-nasm', '--enable-shared']
hostmakedepends = ['nasm']
makedepends = ['ncurses-devel']
pkgdesc = 'Fast, high quality MP3 encoder'
maintainer = 'q66 <q66@chimera-linux.org>'
license = 'LGPL-2.1-or-later'
url = 'https://lame.sourceforge.io'
source = f'$(SOURCEFORGE_SITE)/{pkgname}/{pkgname}-{pkgver}.tar.gz'
sha256 = 'ddfe36cab873794038ae2c1210557ad34857a4b6bdc515785d1da9e175b1da1e'
@subpackage('lame-devel')
def _devel(self):
return self.default_devel() |
# anagram!
# remove each string that is an anagram of an earlier string, then return an ordered list of the remaining words
# example:
# input: ['code', 'doce', 'frame', 'edoc', 'framer']
# output: 'code', 'frame', 'framer'
# input = ['poke', 'ekop', 'kope', 'peok']
# output = ['poke']
# start with a brute force algorithm, then pare it down from there. Here's the text I was using as my main test case. Note that is has multiple items with anagrams, as well as a word that isn't an anagram but is similar to one of the anagrams
# text = ['code', 'doce', 'frame', 'edoc', 'framer', 'famer']
def anagram(text):
sorted_words = dict()
# reverses text list so that when it gets turned into a dictionary it will have the first instance of the anagram. Used list slice rather than the reverse method since reverse returns None.
for word in text[::-1]:
current = word #just another variable to keep the various instances of 'word' straight
# takes each word from the text list, essentially 'unanagrams' it, then appends it to the dict of sorted words. The letters are the thing being sorted, not the word order.
# removes duplicates from sorted words and returns it as a list
sorted_words.update({''.join(sorted(current)) : current})
return sorted(list(sorted_words.values()))
def anagram_oneliner(text):
return sorted(list({''.join(sorted(word)) : word for word in text[::-1]}.values()))
| def anagram(text):
sorted_words = dict()
for word in text[::-1]:
current = word
sorted_words.update({''.join(sorted(current)): current})
return sorted(list(sorted_words.values()))
def anagram_oneliner(text):
return sorted(list({''.join(sorted(word)): word for word in text[::-1]}.values())) |
class MagicList :
def __init__(self):
self.data = [0]
def findMin(self):
M = self.data
smallest= min(M)
return(smallest)
def insert(self, E):
M = self.data
M.append(E)
l=len(M)
i= l-1
while (i//2 >= 1 and M[i//2] > M[i]):
M[i],M[i//2] = M[i//2],M[i]
i=i//2
return(M)
def deleteMin(self):
M = self.data
E1= min(M)
E2= M[len(M)-1]
i=0
while(E2<M[2*i] and E2<M[2*i+1]):
if M[2*i]< M[2*i+1]:
s=M[2*i]
else:
s=M[2*i+1]
b=E2
E2=s
s=b
def K_sum(L, K):
w = MagicList()
aseem = w.data
for i in L:
w.insert(i)
ans = 0
for i in range(1,K+1):
ans+=aseem[i]
return ans
if __name__ == "__main__" :
'''Here are a few test cases'''
'''insert and findMin'''
M = MagicList()
M.insert(4)
M.insert(3)
M.insert(5)
x = M.findMin()
if x == 3 :
print("testcase 1 : Passed")
else :
print("testcase 1 : Failed")
'''deleteMin and findMin'''
M.deleteMin()
x = M.findMin()
if x == 4 :
print("testcase 2 : Passed")
else :
print("testcase 2 : Failed")
'''k-sum'''
L = [2,5,8,3,6,1,0,9,4]
K = 4
x = K_sum(L,K)
if x == 6 :
print("testcase 3 : Passed")
else :
print("testcase 3 : Failed")
| class Magiclist:
def __init__(self):
self.data = [0]
def find_min(self):
m = self.data
smallest = min(M)
return smallest
def insert(self, E):
m = self.data
M.append(E)
l = len(M)
i = l - 1
while i // 2 >= 1 and M[i // 2] > M[i]:
(M[i], M[i // 2]) = (M[i // 2], M[i])
i = i // 2
return M
def delete_min(self):
m = self.data
e1 = min(M)
e2 = M[len(M) - 1]
i = 0
while E2 < M[2 * i] and E2 < M[2 * i + 1]:
if M[2 * i] < M[2 * i + 1]:
s = M[2 * i]
else:
s = M[2 * i + 1]
b = E2
e2 = s
s = b
def k_sum(L, K):
w = magic_list()
aseem = w.data
for i in L:
w.insert(i)
ans = 0
for i in range(1, K + 1):
ans += aseem[i]
return ans
if __name__ == '__main__':
'Here are a few test cases'
'insert and findMin'
m = magic_list()
M.insert(4)
M.insert(3)
M.insert(5)
x = M.findMin()
if x == 3:
print('testcase 1 : Passed')
else:
print('testcase 1 : Failed')
'deleteMin and findMin'
M.deleteMin()
x = M.findMin()
if x == 4:
print('testcase 2 : Passed')
else:
print('testcase 2 : Failed')
'k-sum'
l = [2, 5, 8, 3, 6, 1, 0, 9, 4]
k = 4
x = k_sum(L, K)
if x == 6:
print('testcase 3 : Passed')
else:
print('testcase 3 : Failed') |
class Node:
def __init__(self, value):
self.value = value
self.next = None
max_node = 1_000_000
nodes = {i: Node(i) for i in range(1, max_node + 1)}
initial_arrangement = [1, 5, 6, 7, 9, 4, 8, 2, 3, 10]
current = nodes[initial_arrangement[0]]
for i in range(1, len(initial_arrangement)):
prev = initial_arrangement[i - 1]
nodes[prev].next = nodes[initial_arrangement[i]]
for i in range(len(initial_arrangement) + 1, max_node + 1):
nodes[i - 1].next = nodes[i]
nodes[max_node].next = current
def take_n(start, n):
cur = start
for _ in range(n):
cur = cur.next
snippet_start = start.next
start.next = cur.next
cur.next = None
return snippet_start
def insert(insertion_point, nodes):
end = insertion_point.next
insertion_point.next = nodes
cur = nodes
while cur.next is not None:
cur = cur.next
cur.next = end
def decrement_label(l):
if l <= 1:
return max_node
else:
return l - 1
for i in range(10_000_000):
picked_up = take_n(current, 3)
picked_values = set(
[picked_up.value, picked_up.next.value, picked_up.next.next.value]
)
destination = decrement_label(current.value)
while destination in picked_values:
destination = decrement_label(destination)
insert(nodes[destination], picked_up)
current = current.next
print(nodes[1].next.value * nodes[1].next.next.value)
| class Node:
def __init__(self, value):
self.value = value
self.next = None
max_node = 1000000
nodes = {i: node(i) for i in range(1, max_node + 1)}
initial_arrangement = [1, 5, 6, 7, 9, 4, 8, 2, 3, 10]
current = nodes[initial_arrangement[0]]
for i in range(1, len(initial_arrangement)):
prev = initial_arrangement[i - 1]
nodes[prev].next = nodes[initial_arrangement[i]]
for i in range(len(initial_arrangement) + 1, max_node + 1):
nodes[i - 1].next = nodes[i]
nodes[max_node].next = current
def take_n(start, n):
cur = start
for _ in range(n):
cur = cur.next
snippet_start = start.next
start.next = cur.next
cur.next = None
return snippet_start
def insert(insertion_point, nodes):
end = insertion_point.next
insertion_point.next = nodes
cur = nodes
while cur.next is not None:
cur = cur.next
cur.next = end
def decrement_label(l):
if l <= 1:
return max_node
else:
return l - 1
for i in range(10000000):
picked_up = take_n(current, 3)
picked_values = set([picked_up.value, picked_up.next.value, picked_up.next.next.value])
destination = decrement_label(current.value)
while destination in picked_values:
destination = decrement_label(destination)
insert(nodes[destination], picked_up)
current = current.next
print(nodes[1].next.value * nodes[1].next.next.value) |
# Solution to Advent of Code 2020 day 5
# Read data
with open("input.txt") as inFile:
seats = inFile.read().split("\n")
# Part 1
seatIDs = []
for seat in seats:
row = int(seat[:7].replace("F", "0").replace("B", "1"), base=2)
column = int(seat[7:].replace("L", "0").replace("R", "1"), base=2)
seatIDs.append(row * 8 + column)
print("Max seat ID:", max(seatIDs))
# Part 2
missingSeats = set(range(1023)) - set(seatIDs)
for seat in missingSeats:
if not ((seat - 1) in missingSeats or (seat + 1) in missingSeats):
mySeat = seat
break
print("My seat ID:", mySeat)
| with open('input.txt') as in_file:
seats = inFile.read().split('\n')
seat_i_ds = []
for seat in seats:
row = int(seat[:7].replace('F', '0').replace('B', '1'), base=2)
column = int(seat[7:].replace('L', '0').replace('R', '1'), base=2)
seatIDs.append(row * 8 + column)
print('Max seat ID:', max(seatIDs))
missing_seats = set(range(1023)) - set(seatIDs)
for seat in missingSeats:
if not (seat - 1 in missingSeats or seat + 1 in missingSeats):
my_seat = seat
break
print('My seat ID:', mySeat) |
def factorial(n):
if 0 < n < 13:
return n * factorial(n-1)
elif n == 0:
return 1
else:
raise ValueError
| def factorial(n):
if 0 < n < 13:
return n * factorial(n - 1)
elif n == 0:
return 1
else:
raise ValueError |
# Name or IP of the machine running vocabulary pet server
HOST = 'localhost'
# Port Name of vocabulary pet server
PORT = '8080'
# Please fill into the brakets the root directory of vocabulary pet
# Example: STATIC_PATH = '/home/user/vocabulary_pet/static'
STATIC_PATH = '/<vocabulary_pet_directory>/static'
| host = 'localhost'
port = '8080'
static_path = '/<vocabulary_pet_directory>/static' |
short_name = "anl"
name = "Accidental Noise Library"
major = 2
minor = 2
status = "dev"
| short_name = 'anl'
name = 'Accidental Noise Library'
major = 2
minor = 2
status = 'dev' |
a= "sharad"
b=25
c=3.18
d=True
print(type(a))
print(type(b))
print(type(c))
print(type(d))
| a = 'sharad'
b = 25
c = 3.18
d = True
print(type(a))
print(type(b))
print(type(c))
print(type(d)) |
#-----------------------------------------------------------------------------
# Runtime: 36ms
# Memory Usage:
# Link:
#-----------------------------------------------------------------------------
class Solution:
def isValid(self, s: str) -> bool:
result = []
for ch in s:
if ch == ')' or ch == ']' or ch == '}':
if len(result) == 0:
return False
prev = result.pop()
if not (ch == ')' and prev == '(') and not (ch == ']' and prev == '[') and not (ch == '}' and prev == '{'):
return False
else:
result.append(ch)
return len(result) == 0
| class Solution:
def is_valid(self, s: str) -> bool:
result = []
for ch in s:
if ch == ')' or ch == ']' or ch == '}':
if len(result) == 0:
return False
prev = result.pop()
if not (ch == ')' and prev == '(') and (not (ch == ']' and prev == '[')) and (not (ch == '}' and prev == '{')):
return False
else:
result.append(ch)
return len(result) == 0 |
a=int(input())
k=a%8
if k==1:
print(1)
elif k==2 or k==0:
print(2)
elif k==3 or k==7:
print(3)
elif k==4 or k==6:
print(4)
else:
print(5)
| a = int(input())
k = a % 8
if k == 1:
print(1)
elif k == 2 or k == 0:
print(2)
elif k == 3 or k == 7:
print(3)
elif k == 4 or k == 6:
print(4)
else:
print(5) |
def parse_profile(profile):
kargs = {}
try:
for kv in profile.split(','):
k, v = kv.split('=')
kargs[k] = v
except ValueError:
# more informative error message
raise ValueError(
f"Failed to parse profile: {profile}. The expected format is:"
" \"key1=value1,key2=value2,[...]\""
)
return kargs
def parse_compare_directions(compare_directions):
direcs = []
try:
for direc in compare_directions.split(';'):
left, right = direc.split('-')
left, right = int(left), int(right)
direcs.append((left, right))
except ValueError:
# more informative error message
raise ValueError(
f"Failed to parse directions: {compare_directions}."
" The expected format is: \"left1-right1;left2-right2;[...]\""
)
return direcs
def parse_files(filenames):
files = []
for f in filenames.split(';'):
files.append(f)
return files
def parse_intfloat(s):
try:
return int(s)
except ValueError:
return float(s) | def parse_profile(profile):
kargs = {}
try:
for kv in profile.split(','):
(k, v) = kv.split('=')
kargs[k] = v
except ValueError:
raise value_error(f'Failed to parse profile: {profile}. The expected format is: "key1=value1,key2=value2,[...]"')
return kargs
def parse_compare_directions(compare_directions):
direcs = []
try:
for direc in compare_directions.split(';'):
(left, right) = direc.split('-')
(left, right) = (int(left), int(right))
direcs.append((left, right))
except ValueError:
raise value_error(f'Failed to parse directions: {compare_directions}. The expected format is: "left1-right1;left2-right2;[...]"')
return direcs
def parse_files(filenames):
files = []
for f in filenames.split(';'):
files.append(f)
return files
def parse_intfloat(s):
try:
return int(s)
except ValueError:
return float(s) |
class _BaseOptimizer:
def __init__(self, learning_rate=1e-4, reg=1e-3):
self.learning_rate = learning_rate
self.reg = reg
def update(self, model):
pass
def apply_regularization(self, model):
'''
Apply L2 penalty to the model. Update the gradient dictionary in the model
:param model: The model with gradients
:return: None, but the gradient dictionary of the model should be updated
'''
#############################################################################
# TODO: #
# 1) Apply L2 penalty to model weights based on the regularization #
# coefficient #
#############################################################################
# regulariwation on weights
for wi in model.gradients:
if wi[0].lower()=='w':
model.gradients[wi]+= self.reg*model.weights[wi] # grad+ dL2/dw
#############################################################################
# END OF YOUR CODE #
############################################################################# | class _Baseoptimizer:
def __init__(self, learning_rate=0.0001, reg=0.001):
self.learning_rate = learning_rate
self.reg = reg
def update(self, model):
pass
def apply_regularization(self, model):
"""
Apply L2 penalty to the model. Update the gradient dictionary in the model
:param model: The model with gradients
:return: None, but the gradient dictionary of the model should be updated
"""
for wi in model.gradients:
if wi[0].lower() == 'w':
model.gradients[wi] += self.reg * model.weights[wi] |
# Space: O(n)
# Time: O(n)
# Definition for singly-linked list.
# class ListNode:
# def __init__(self, val=0, next=None):
# self.val = val
# self.next = next
class Solution:
def isPalindrome(self, head):
if not head: return True
if head.next is None: return True
temp = []
while head:
temp.append(head.val)
head = head.next
return True if temp == temp[::-1] else False
| class Solution:
def is_palindrome(self, head):
if not head:
return True
if head.next is None:
return True
temp = []
while head:
temp.append(head.val)
head = head.next
return True if temp == temp[::-1] else False |
# Given n non-negative integers a1, a2, ..., an , where each represents a point at coordinate (i, ai). n vertical lines are drawn such that the two endpoints of line i is at (i, ai) and (i, 0). Find two lines, which together with x-axis forms a container, such that the container contains the most water.
# Note: You may not slant the container and n is at least 2.
class Solution:
def maxArea(self, height: List[int]) -> int:
# max = 0
# for i in range(len(height)):
# for a in range(i, len(height)):
# # length = abs(i - a)
# # height_2 = min(height[i], height[a])
# container = (abs(i - a)) * (min(height[i], height[a]))
# if max < container:
# max = container
# return max
i, j = 0, len(height) - 1
water = 0
# i starts from the left, j starts from the right; testing possible combinations before they cross each other:
while i < j:
# the max of zero, or the width times the lower of (i or j):
water = max(water, (j - i) * min(height[i], height[j]))
# discarding the shorter line, and keep only the longer line; testing all possible combinations until i and j come across each other:
if height[i] < height[j]:
i += 1
else:
j -= 1
return water
| class Solution:
def max_area(self, height: List[int]) -> int:
(i, j) = (0, len(height) - 1)
water = 0
while i < j:
water = max(water, (j - i) * min(height[i], height[j]))
if height[i] < height[j]:
i += 1
else:
j -= 1
return water |
# Copyright 2019, OpenTelemetry Authors
#
# 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.
SETTINGS_SERVICE = 'opentelemetry_trace_service'
SETTINGS_TRACER = 'opentelemetry_tracer'
SETTINGS_TRACE_ENABLED = 'opentelemetry_trace_enabled'
SETTINGS_DISTRIBUTED_TRACING = 'opentelemetry_distributed_tracing'
SETTINGS_ANALYTICS_ENABLED = 'opentelemetry_analytics_enabled'
SETTINGS_ANALYTICS_SAMPLE_RATE = 'opentelemetry_analytics_sample_rate'
| settings_service = 'opentelemetry_trace_service'
settings_tracer = 'opentelemetry_tracer'
settings_trace_enabled = 'opentelemetry_trace_enabled'
settings_distributed_tracing = 'opentelemetry_distributed_tracing'
settings_analytics_enabled = 'opentelemetry_analytics_enabled'
settings_analytics_sample_rate = 'opentelemetry_analytics_sample_rate' |
class QueryDeviceGroupMembersInDTO(object):
def __init__(self):
self.devGroupId = None
self.accessAppId = None
self.pageNo = None
self.pageSize = None
def getDevGroupId(self):
return self.devGroupId
def setDevGroupId(self, devGroupId):
self.devGroupId = devGroupId
def getAccessAppId(self):
return self.accessAppId
def setAccessAppId(self, accessAppId):
self.accessAppId = accessAppId
def getPageNo(self):
return self.pageNo
def setPageNo(self, pageNo):
self.pageNo = pageNo
def getPageSize(self):
return self.pageSize
def setPageSize(self, pageSize):
self.pageSize = pageSize
| class Querydevicegroupmembersindto(object):
def __init__(self):
self.devGroupId = None
self.accessAppId = None
self.pageNo = None
self.pageSize = None
def get_dev_group_id(self):
return self.devGroupId
def set_dev_group_id(self, devGroupId):
self.devGroupId = devGroupId
def get_access_app_id(self):
return self.accessAppId
def set_access_app_id(self, accessAppId):
self.accessAppId = accessAppId
def get_page_no(self):
return self.pageNo
def set_page_no(self, pageNo):
self.pageNo = pageNo
def get_page_size(self):
return self.pageSize
def set_page_size(self, pageSize):
self.pageSize = pageSize |
# A non class to hold various constants
# Plane colors
colors = { 0 : 'r', 1 : 'g' , 2 : 'b' }
cm2tick = 17.94
cm2wire = 3.3333
| colors = {0: 'r', 1: 'g', 2: 'b'}
cm2tick = 17.94
cm2wire = 3.3333 |
def p_e_m_disamb_redirect_wikinameid_maps():
wall_start = time.time()
redirections = dict()
with open(config.base_folder + "data/basic_data/wiki_redirects.txt") as fin:
redirections_errors = 0
for line in fin:
# line = line[:-1]
line = line.rstrip()
try:
old_title, new_title = line.split("\t")
redirections[old_title] = new_title
except ValueError:
redirections_errors += 1
print("load redirections. wall time:", (time.time() - wall_start)/60, " minutes")
print("redirections_errors: ", redirections_errors)
wall_start = time.time()
disambiguations_ids = set()
disambiguations_titles = set()
disambiguations_errors = 0
with open(config.base_folder + "data/basic_data/wiki_disambiguation_pages.txt") as fin:
for line in fin:
line = line.rstrip()
try:
article_id, title = line.split("\t")
disambiguations_ids.add(int(article_id))
disambiguations_titles.add(title)
except ValueError:
disambiguations_errors += 1
print("load disambiguations. wall time:", (time.time() - wall_start)/60, " minutes")
print("disambiguations_errors: ", disambiguations_errors)
wall_start = time.time()
wiki_name_id_map = dict()
wiki_name_id_map_lower = dict() # i lowercase the names
wiki_id_name_map = dict()
wiki_name_id_map_errors = 0
with open(config.base_folder + "data/basic_data/wiki_name_id_map.txt") as fin:
for line in fin:
line = line.rstrip()
try:
wiki_title, wiki_id = line.split("\t")
wiki_name_id_map[wiki_title] = int(wiki_id)
wiki_name_id_map_lower[wiki_title.lower()] = int(wiki_id)
wiki_id_name_map[int(wiki_id)] = wiki_title
except ValueError:
wiki_name_id_map_errors += 1
print("load wiki_name_id_map. wall time:", (time.time() - wall_start)/60, " minutes")
print("wiki_name_id_map_errors: ", wiki_name_id_map_errors)
wall_start = time.time()
p_e_m = dict() # for each mention we have a list of tuples (ent_id, score)
p_e_m_errors = 0
line_cnt = 0
with open(config.base_folder + "data/p_e_m/prob_yago_crosswikis_wikipedia_p_e_m.txt") as fin:
for line in fin:
line = line.rstrip()
try:
temp = line.split("\t")
mention, entities = temp[0], temp[2:2+config.cand_ent_num]
res = []
for e in entities:
ent_id, score, _ = e.split(',', 2)
#print(ent_id, score)
res.append((int(ent_id), float(score)))
p_e_m[mention] = res # for each mention we have a list of tuples (ent_id, score)
#print(repr(line))
#print(mention, p_e_m[mention])
#except ValueError:
except Exception as esd:
exc_type, exc_obj, exc_tb = sys.exc_info()
fname = os.path.split(exc_tb.tb_frame.f_code.co_filename)[1]
print(exc_type, fname, exc_tb.tb_lineno)
p_e_m_errors += 1
print("error in line: ", repr(line))
#line_cnt += 1
#if line_cnt > 100:
# break
print("end of p_e_m reading. wall time:", (time.time() - wall_start)/60, " minutes")
print("p_e_m_errors: ", p_e_m_errors)
with open(config.base_folder+"data/serializations/p_e_m_disamb_redirect_wikinameid_maps.pickle", 'wb') as handle:
pickle.dump((p_e_m, config.cand_ent_num, disambiguations_ids, disambiguations_titles, redirections, \
wiki_name_id_map, wiki_id_name_map, wiki_name_id_map_lower), handle)
return p_e_m, disambiguations_ids, redirections, wiki_name_id_map
| def p_e_m_disamb_redirect_wikinameid_maps():
wall_start = time.time()
redirections = dict()
with open(config.base_folder + 'data/basic_data/wiki_redirects.txt') as fin:
redirections_errors = 0
for line in fin:
line = line.rstrip()
try:
(old_title, new_title) = line.split('\t')
redirections[old_title] = new_title
except ValueError:
redirections_errors += 1
print('load redirections. wall time:', (time.time() - wall_start) / 60, ' minutes')
print('redirections_errors: ', redirections_errors)
wall_start = time.time()
disambiguations_ids = set()
disambiguations_titles = set()
disambiguations_errors = 0
with open(config.base_folder + 'data/basic_data/wiki_disambiguation_pages.txt') as fin:
for line in fin:
line = line.rstrip()
try:
(article_id, title) = line.split('\t')
disambiguations_ids.add(int(article_id))
disambiguations_titles.add(title)
except ValueError:
disambiguations_errors += 1
print('load disambiguations. wall time:', (time.time() - wall_start) / 60, ' minutes')
print('disambiguations_errors: ', disambiguations_errors)
wall_start = time.time()
wiki_name_id_map = dict()
wiki_name_id_map_lower = dict()
wiki_id_name_map = dict()
wiki_name_id_map_errors = 0
with open(config.base_folder + 'data/basic_data/wiki_name_id_map.txt') as fin:
for line in fin:
line = line.rstrip()
try:
(wiki_title, wiki_id) = line.split('\t')
wiki_name_id_map[wiki_title] = int(wiki_id)
wiki_name_id_map_lower[wiki_title.lower()] = int(wiki_id)
wiki_id_name_map[int(wiki_id)] = wiki_title
except ValueError:
wiki_name_id_map_errors += 1
print('load wiki_name_id_map. wall time:', (time.time() - wall_start) / 60, ' minutes')
print('wiki_name_id_map_errors: ', wiki_name_id_map_errors)
wall_start = time.time()
p_e_m = dict()
p_e_m_errors = 0
line_cnt = 0
with open(config.base_folder + 'data/p_e_m/prob_yago_crosswikis_wikipedia_p_e_m.txt') as fin:
for line in fin:
line = line.rstrip()
try:
temp = line.split('\t')
(mention, entities) = (temp[0], temp[2:2 + config.cand_ent_num])
res = []
for e in entities:
(ent_id, score, _) = e.split(',', 2)
res.append((int(ent_id), float(score)))
p_e_m[mention] = res
except Exception as esd:
(exc_type, exc_obj, exc_tb) = sys.exc_info()
fname = os.path.split(exc_tb.tb_frame.f_code.co_filename)[1]
print(exc_type, fname, exc_tb.tb_lineno)
p_e_m_errors += 1
print('error in line: ', repr(line))
print('end of p_e_m reading. wall time:', (time.time() - wall_start) / 60, ' minutes')
print('p_e_m_errors: ', p_e_m_errors)
with open(config.base_folder + 'data/serializations/p_e_m_disamb_redirect_wikinameid_maps.pickle', 'wb') as handle:
pickle.dump((p_e_m, config.cand_ent_num, disambiguations_ids, disambiguations_titles, redirections, wiki_name_id_map, wiki_id_name_map, wiki_name_id_map_lower), handle)
return (p_e_m, disambiguations_ids, redirections, wiki_name_id_map) |
num = 1
while num > 0:
num = int( input() )
print(num)
#########################
a = ['I', 3, 0.1, 'choongam']
for i in a:
print(i)
#########################
for i in range(-6, 5):
print(i)
| num = 1
while num > 0:
num = int(input())
print(num)
a = ['I', 3, 0.1, 'choongam']
for i in a:
print(i)
for i in range(-6, 5):
print(i) |
VERSION = "2.0.0"
CONTRIBUTORS = [
{
"name": "Kyuunex",
"url": "https://github.com/Kyuunex",
"role": "BDFL"
},
{
"name": "-Keitaro",
"url": "https://github.com/rorre",
"role": "some technical help"
},
{
"name": "eenpersoon64",
"url": "https://github.com/eenpersoon64",
"role": "few lines of code"
}
]
| version = '2.0.0'
contributors = [{'name': 'Kyuunex', 'url': 'https://github.com/Kyuunex', 'role': 'BDFL'}, {'name': '-Keitaro', 'url': 'https://github.com/rorre', 'role': 'some technical help'}, {'name': 'eenpersoon64', 'url': 'https://github.com/eenpersoon64', 'role': 'few lines of code'}] |
class Cache:
def __init__(self):
self.data = []
def has_data(self, inp):
if not self.data:
[]
else:
for x in self.data:
if x[0] == inp:
return x[1]
return []
def computation_val(self, inp, output):
new_cache = [inp, output]
if not self.data:
self.data = [new_cache]
else:
self.data.append(new_cache) | class Cache:
def __init__(self):
self.data = []
def has_data(self, inp):
if not self.data:
[]
else:
for x in self.data:
if x[0] == inp:
return x[1]
return []
def computation_val(self, inp, output):
new_cache = [inp, output]
if not self.data:
self.data = [new_cache]
else:
self.data.append(new_cache) |
class VaultInitError(Exception):
pass
class NotEnoughtKeysError(VaultInitError):
def __init__(self, mandatory_count, used_count):
self.mandatory = mandatory_count
self.used = used_count
def __str__(self):
return f'NotEnoughKeys excepted {self.mandatory}, used {self.used}'
class BadKeysProvided(VaultInitError):
def __str__(self):
return 'Provided keys cannot unseal vault server'
class BadInitParameterValue(VaultInitError):
def __init__(self, message):
self.message = message
def __str__(self):
return f'Unable to init vault server - reason given ${self.message}'
| class Vaultiniterror(Exception):
pass
class Notenoughtkeyserror(VaultInitError):
def __init__(self, mandatory_count, used_count):
self.mandatory = mandatory_count
self.used = used_count
def __str__(self):
return f'NotEnoughKeys excepted {self.mandatory}, used {self.used}'
class Badkeysprovided(VaultInitError):
def __str__(self):
return 'Provided keys cannot unseal vault server'
class Badinitparametervalue(VaultInitError):
def __init__(self, message):
self.message = message
def __str__(self):
return f'Unable to init vault server - reason given ${self.message}' |
username = '' # production user
TOKEN = "" # production bot
URL = "" # production server
google_credentials = 'production/production_credentials.json' # prod credentials
google_oath = 'production/production_oath.json' # prod oath
main_folder_key = "" # production main folder id # checked
ss_keys_file = 'production/production_ss_keys.json' # test ss_keys file
| username = ''
token = ''
url = ''
google_credentials = 'production/production_credentials.json'
google_oath = 'production/production_oath.json'
main_folder_key = ''
ss_keys_file = 'production/production_ss_keys.json' |
__version__ = "2.1.6"
| __version__ = '2.1.6' |
class DimensionError(Exception):
pass
class MultivectorError(Exception):
pass
class FunctionError(Exception):
pass
class DiferentialFormError(Exception):
pass
class CasimirError(Exception):
pass
| class Dimensionerror(Exception):
pass
class Multivectorerror(Exception):
pass
class Functionerror(Exception):
pass
class Diferentialformerror(Exception):
pass
class Casimirerror(Exception):
pass |
def take_beer(fridge, number=1):
if not isinstance(fridge, dict):
raise TypeError("Invalid fridge")
if "beer" not in fridge:
raise ValueError("No more beer:(")
if number > fridge["beer"]:
raise ValueError("Not enough beer:(")
fridge["beer"] -= number
if __name__ == "__main__":
fridge1 = {}
fridge2 = "fridge_as_string"
for fridge in (fridge1, fridge2):
try:
print("I wanna drink 1 bottle of beer...")
take_beer(fridge)
print("Oooh, great!")
except TypeError as e:
print("TypeError {} occured".format(e))
except ValueError as e:
print("ValueError {} occured".format(e))
| def take_beer(fridge, number=1):
if not isinstance(fridge, dict):
raise type_error('Invalid fridge')
if 'beer' not in fridge:
raise value_error('No more beer:(')
if number > fridge['beer']:
raise value_error('Not enough beer:(')
fridge['beer'] -= number
if __name__ == '__main__':
fridge1 = {}
fridge2 = 'fridge_as_string'
for fridge in (fridge1, fridge2):
try:
print('I wanna drink 1 bottle of beer...')
take_beer(fridge)
print('Oooh, great!')
except TypeError as e:
print('TypeError {} occured'.format(e))
except ValueError as e:
print('ValueError {} occured'.format(e)) |
default_prefix = "COCOS"
known_chains = {
"COCOS": {
"chain_id": "7d89b84f22af0b150780a2b121aa6c715b19261c8b7fe0fda3a564574ed7d3e9",
"core_symbol": "COCOS",
"prefix": "COCOS"},
# "COCOS": {
# "chain_id": "9fc429a48b47447afa5e6618fde46d1a5f7b2266f00ce60866f9fdd92236e137",
# "core_symbol": "COCOS",
# "prefix": "COCOS"},
# "COCOS": {
# "chain_id": "53b98adf376459cc29e5672075ed0c0b1672ea7dce42b0b1fe5e021c02bda640",
# "core_symbol": "COCOS",
# "prefix": "COCOS"},
}
| default_prefix = 'COCOS'
known_chains = {'COCOS': {'chain_id': '7d89b84f22af0b150780a2b121aa6c715b19261c8b7fe0fda3a564574ed7d3e9', 'core_symbol': 'COCOS', 'prefix': 'COCOS'}} |
class uart_interface():
# def __init__(self, ser):
# pass
def serial_read(self, ser, message, file, first_read=False):
pass
def serial_write(self, ser, message, file=None):
pass
| class Uart_Interface:
def serial_read(self, ser, message, file, first_read=False):
pass
def serial_write(self, ser, message, file=None):
pass |
# David Markham 2019-02-17
# Solution to problem number 1
# Write a program that asks the user to input any positive integer
# And outputs the sum of all numbers between one and that number.
# Asks the user to input a positive integer number
i = int(input("Please enter a positive integer"))
# This will prevent the user from entering anything other than a positive integer.
if i <= 0:
print("Unfortunately this is not a positive integer")
total = 0
while i > 0:
total = total + i
i = i - 1
# While 'i' is greater than 0 add the total and the current value of "i" and overwrite the current total.
# This is called a compound statement using a while loop.
# i = i -1: If the user inputs the positive integer of 10, the program subtracts one from the current value and so on, down to 0.
# Prints the answer.
print(total) | i = int(input('Please enter a positive integer'))
if i <= 0:
print('Unfortunately this is not a positive integer')
total = 0
while i > 0:
total = total + i
i = i - 1
print(total) |
# -*- coding:utf-8 -*-
'''
Created on 2013/07/31
@author: Jimmy Liu
'''
DAY_PRICE_COLUMNS = ['date','open','high','close','low','amount','price_change','p_change','ma5','ma10','ma20','v_ma5','v_ma10','v_ma20','turnover']
TICK_COLUMNS = ['time','price','change','volume','cash','type']
TICK_PRICE_URL = 'http://market.finance.sina.com.cn/downxls.php?date=%s&symbol=%s'
DAY_PRICE_URL = 'http://api.finance.ifeng.com/akdaily/?code=%s&type=last'
SINA_DAY_PRICE_URL = 'http://vip.stock.finance.sina.com.cn/quotes_service/api/json_v2.php/Market_Center.getHQNodeData?num=80&sort=changepercent&asc=0&node=hs_a&symbol=&_s_r_a=page&page=%s'
DAY_TRADING_COLUMNS = ['code','symbol','name','changepercent','trade','open','high','low','settlement','volume','turnoverratio']
DAY_PRICE_PAGES = 38 | """
Created on 2013/07/31
@author: Jimmy Liu
"""
day_price_columns = ['date', 'open', 'high', 'close', 'low', 'amount', 'price_change', 'p_change', 'ma5', 'ma10', 'ma20', 'v_ma5', 'v_ma10', 'v_ma20', 'turnover']
tick_columns = ['time', 'price', 'change', 'volume', 'cash', 'type']
tick_price_url = 'http://market.finance.sina.com.cn/downxls.php?date=%s&symbol=%s'
day_price_url = 'http://api.finance.ifeng.com/akdaily/?code=%s&type=last'
sina_day_price_url = 'http://vip.stock.finance.sina.com.cn/quotes_service/api/json_v2.php/Market_Center.getHQNodeData?num=80&sort=changepercent&asc=0&node=hs_a&symbol=&_s_r_a=page&page=%s'
day_trading_columns = ['code', 'symbol', 'name', 'changepercent', 'trade', 'open', 'high', 'low', 'settlement', 'volume', 'turnoverratio']
day_price_pages = 38 |
def is_valid(isbn):
digits = [ch if ch != 'X' else '10' for ch in isbn if ch != '-']
if len(digits) != 10 or '10' in digits[:9] or any(not n.isdigit() for n in digits):
return False
return sum(int(n) * i for n, i in zip(digits, range(10, 0, -1))) % 11 == 0
| def is_valid(isbn):
digits = [ch if ch != 'X' else '10' for ch in isbn if ch != '-']
if len(digits) != 10 or '10' in digits[:9] or any((not n.isdigit() for n in digits)):
return False
return sum((int(n) * i for (n, i) in zip(digits, range(10, 0, -1)))) % 11 == 0 |
STOPWORDS = ['I',
'A',
'ABOVE',
'AFTER',
'AGAINST',
'ALL',
'ALONE',
'ALWAYS',
'AM',
'AMOUNT',
'AN',
'AND',
'ANY',
'ARE',
'AROUND',
'AS',
'AT',
'BACK',
'BE',
'BEFORE',
'BEHIND',
'BELOW',
'BETWEEN',
'BILL',
'BOTH',
'BOTTOM',
'BY',
'CALL',
'CAN',
'CO',
'CON',
'DE',
'DETAIL',
'DO',
'DONE',
'DOWN',
'DUE',
'DURING',
'EACH',
'EG',
'EIGHT',
'ELEVEN',
'EMPTY',
'EVER',
'EVERY',
'FEW',
'FILL',
'FIND',
'FIRE',
'FIRST',
'FIVE',
'FOR',
'FORMER',
'FOUR',
'FROM',
'FRONT',
'FULL',
'FURTHER',
'GET',
'GIVE',
'GO',
'HAD',
'HAS',
'HASNT',
'HE',
'HER',
'HERS',
'HIM',
'HIS',
'I',
'IE',
'IF',
'IN',
'INTO',
'IS',
'IT',
'LAST',
'LESS',
'LTD',
'MANY',
'MAY',
'ME',
'MILL',
'MINE',
'MORE',
'MOST',
'MOSTLY',
'MUST',
'MY',
'NAME',
'NEXT',
'NINE',
'NO',
'NONE',
'NOR',
'NOT',
'NOTHING',
'NOW',
'OF',
'OFF',
'OFTEN',
'ON',
'ONCE',
'ONE',
'ONLY',
'OR',
'OTHER',
'OTHERS',
'OUT',
'OVER',
'PART',
'PER',
'PUT',
'RE',
'SAME',
'SEE',
'SERIOUS',
'SEVERAL',
'SHE',
'SHOW',
'SIDE',
'SINCE',
'SIX',
'SO',
'SOME',
'SOMETIMES',
'STILL',
'TAKE',
'TEN',
'THE',
'THEN',
'THIRD',
'THIS',
'THICK',
'THIN',
'THREE',
'THROUGH',
'TO',
'TOGETHER',
'TOP',
'TOWARD',
'TOWARDS',
'TWELVE',
'TWO',
'UN',
'UNDER',
'UNTIL',
'UP',
'UPON',
'US',
'VERY',
'VIA',
'WAS',
'WE',
'WELL',
'WHEN',
'WHILE',
'WHO',
'WHOLE',
'WILL',
'WITH',
'WITHIN',
'WITHOUT',
'YOU',
'YOURSELF',
'YOURSELVE\'S']
| stopwords = ['I', 'A', 'ABOVE', 'AFTER', 'AGAINST', 'ALL', 'ALONE', 'ALWAYS', 'AM', 'AMOUNT', 'AN', 'AND', 'ANY', 'ARE', 'AROUND', 'AS', 'AT', 'BACK', 'BE', 'BEFORE', 'BEHIND', 'BELOW', 'BETWEEN', 'BILL', 'BOTH', 'BOTTOM', 'BY', 'CALL', 'CAN', 'CO', 'CON', 'DE', 'DETAIL', 'DO', 'DONE', 'DOWN', 'DUE', 'DURING', 'EACH', 'EG', 'EIGHT', 'ELEVEN', 'EMPTY', 'EVER', 'EVERY', 'FEW', 'FILL', 'FIND', 'FIRE', 'FIRST', 'FIVE', 'FOR', 'FORMER', 'FOUR', 'FROM', 'FRONT', 'FULL', 'FURTHER', 'GET', 'GIVE', 'GO', 'HAD', 'HAS', 'HASNT', 'HE', 'HER', 'HERS', 'HIM', 'HIS', 'I', 'IE', 'IF', 'IN', 'INTO', 'IS', 'IT', 'LAST', 'LESS', 'LTD', 'MANY', 'MAY', 'ME', 'MILL', 'MINE', 'MORE', 'MOST', 'MOSTLY', 'MUST', 'MY', 'NAME', 'NEXT', 'NINE', 'NO', 'NONE', 'NOR', 'NOT', 'NOTHING', 'NOW', 'OF', 'OFF', 'OFTEN', 'ON', 'ONCE', 'ONE', 'ONLY', 'OR', 'OTHER', 'OTHERS', 'OUT', 'OVER', 'PART', 'PER', 'PUT', 'RE', 'SAME', 'SEE', 'SERIOUS', 'SEVERAL', 'SHE', 'SHOW', 'SIDE', 'SINCE', 'SIX', 'SO', 'SOME', 'SOMETIMES', 'STILL', 'TAKE', 'TEN', 'THE', 'THEN', 'THIRD', 'THIS', 'THICK', 'THIN', 'THREE', 'THROUGH', 'TO', 'TOGETHER', 'TOP', 'TOWARD', 'TOWARDS', 'TWELVE', 'TWO', 'UN', 'UNDER', 'UNTIL', 'UP', 'UPON', 'US', 'VERY', 'VIA', 'WAS', 'WE', 'WELL', 'WHEN', 'WHILE', 'WHO', 'WHOLE', 'WILL', 'WITH', 'WITHIN', 'WITHOUT', 'YOU', 'YOURSELF', "YOURSELVE'S"] |
def numberToRoman(self, number):
digits = [
1000, 900, 500, 400,
100, 90, 50, 40,
10, 9, 5, 4,
1
]
symbolRoman = [
"M", "CM", "D", "CD",
"C", "XC", "L", "XL",
"X", "IX", "V", "IV",
"I"
]
romanNumber = ''
i = 0
while number > 0:
for _ in range(number // digits[i]):
romanNumber += symbolRoman[i]
number -= digits[i]
i += 1
return romanNumber
| def number_to_roman(self, number):
digits = [1000, 900, 500, 400, 100, 90, 50, 40, 10, 9, 5, 4, 1]
symbol_roman = ['M', 'CM', 'D', 'CD', 'C', 'XC', 'L', 'XL', 'X', 'IX', 'V', 'IV', 'I']
roman_number = ''
i = 0
while number > 0:
for _ in range(number // digits[i]):
roman_number += symbolRoman[i]
number -= digits[i]
i += 1
return romanNumber |
#!/usr/bin/env python3
def main():
print("Todo")
| def main():
print('Todo') |
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
classmates = ['Michael', 'Bob', 'Tracy']
print('classmates=',classmethod)
print('len(classmates) =',len(classmates))
print('classmates[0]',classmates[0])
print('classmates[1]',classmates[1])
print('classmates[-1]',classmates[-1])
classmates.pop()
print('classmates=',classmates)
| classmates = ['Michael', 'Bob', 'Tracy']
print('classmates=', classmethod)
print('len(classmates) =', len(classmates))
print('classmates[0]', classmates[0])
print('classmates[1]', classmates[1])
print('classmates[-1]', classmates[-1])
classmates.pop()
print('classmates=', classmates) |
# @file
#
# Copyright 2020, Verizon Media
# SPDX-License-Identifier: Apache-2.0
#
Test.Summary = '''
Multiple Remap Configurations.
'''
# Point of this is to test two remap configs in isolation and then both as separate remap configs.
tr = Test.TxnBoxTestAndRun("Multiple remap configurations", "multi-cfg.replay.yaml",
remap=[ [ "http://one.ex", [ 'multi-cfg.1.yaml'] ]
, [ "http://two.ex", [ 'multi-cfg.2.yaml'] ]
, [ "http://both.ex", [ 'multi-cfg.1.yaml' , 'multi-cfg.2.yaml'] ]
]
)
ts = tr.Variables.TS
ts.Setup.Copy("multi-cfg.1.yaml", ts.Variables.CONFIGDIR)
ts.Setup.Copy("multi-cfg.2.yaml", ts.Variables.CONFIGDIR)
ts.Disk.records_config.update({
'proxy.config.log.max_secs_per_buffer': 1
, 'proxy.config.diags.debug.enabled': 1
, 'proxy.config.diags.debug.tags': 'txn_box'
})
| Test.Summary = '\nMultiple Remap Configurations.\n'
tr = Test.TxnBoxTestAndRun('Multiple remap configurations', 'multi-cfg.replay.yaml', remap=[['http://one.ex', ['multi-cfg.1.yaml']], ['http://two.ex', ['multi-cfg.2.yaml']], ['http://both.ex', ['multi-cfg.1.yaml', 'multi-cfg.2.yaml']]])
ts = tr.Variables.TS
ts.Setup.Copy('multi-cfg.1.yaml', ts.Variables.CONFIGDIR)
ts.Setup.Copy('multi-cfg.2.yaml', ts.Variables.CONFIGDIR)
ts.Disk.records_config.update({'proxy.config.log.max_secs_per_buffer': 1, 'proxy.config.diags.debug.enabled': 1, 'proxy.config.diags.debug.tags': 'txn_box'}) |
LOGGING = {
'version': 1,
'disable_existing_loggers': False,
'formatters': {
'debug': {
'format': '%(asctime)s %(name)s %(filename)s[line:%(lineno)d] %(levelname)s %(message)s',
'datefmt': '%Y-%m-%d %H:%M:%S',
},
'simple': {
'format': '%(asctime)s %(levelname)s %(message)s',
'datefmt': '%Y-%m-%d %H:%M:%S',
},
},
'handlers': {
'console': {
'level': 'DEBUG',
'filters': [],
'class': 'logging.StreamHandler',
'formatter': 'debug',
},
'info_handler': {
'level': 'INFO',
'class': 'logging.handlers.TimedRotatingFileHandler',
'when': 'midnight',
'backupCount': 7,
'filename': '/var/log/gdp/memory/info/server_monitor_access.log',
'formatter': 'simple',
},
'exception_handler': {
'level': 'WARNING',
'class': 'logging.handlers.TimedRotatingFileHandler',
'when': 'midnight',
'backupCount': 7,
'filename': '/var/log/gdp/memory/error/server_monitor_exception.log',
'formatter': 'simple',
},
},
'loggers': {
'': {
'handlers': ['console', ],
'level': 'DEBUG',
'propagate': False,
},
'tornado.general': {
'handlers': ['info_handler', 'exception_handler'],
'level': 'INFO',
'propagate': True,
},
}
} | logging = {'version': 1, 'disable_existing_loggers': False, 'formatters': {'debug': {'format': '%(asctime)s %(name)s %(filename)s[line:%(lineno)d] %(levelname)s %(message)s', 'datefmt': '%Y-%m-%d %H:%M:%S'}, 'simple': {'format': '%(asctime)s %(levelname)s %(message)s', 'datefmt': '%Y-%m-%d %H:%M:%S'}}, 'handlers': {'console': {'level': 'DEBUG', 'filters': [], 'class': 'logging.StreamHandler', 'formatter': 'debug'}, 'info_handler': {'level': 'INFO', 'class': 'logging.handlers.TimedRotatingFileHandler', 'when': 'midnight', 'backupCount': 7, 'filename': '/var/log/gdp/memory/info/server_monitor_access.log', 'formatter': 'simple'}, 'exception_handler': {'level': 'WARNING', 'class': 'logging.handlers.TimedRotatingFileHandler', 'when': 'midnight', 'backupCount': 7, 'filename': '/var/log/gdp/memory/error/server_monitor_exception.log', 'formatter': 'simple'}}, 'loggers': {'': {'handlers': ['console'], 'level': 'DEBUG', 'propagate': False}, 'tornado.general': {'handlers': ['info_handler', 'exception_handler'], 'level': 'INFO', 'propagate': True}}} |
# Task 09. Factorial Division
def factorial(n):
if n > 1:
return n * factorial(n-1)
return 1
first_num = int(input())
second_num = int(input())
result = factorial(first_num) / factorial(second_num)
print(f"{result:.2f}")
| def factorial(n):
if n > 1:
return n * factorial(n - 1)
return 1
first_num = int(input())
second_num = int(input())
result = factorial(first_num) / factorial(second_num)
print(f'{result:.2f}') |
def repl(re,ye,word):
for y in range(len(c)):
if c[y]==word:
n=input('yes or no')
if n=="yes":
c[y]=re
else:
pass
k=' '.join(c)
print(k)
y=open(a,"w")
y.write(k)
y.close()
def rep(re,ye,word):
for y in range(len(c)):
if c[y]==word:
c[y]=re
k=' '.join(c)
print(k)
y=open(a,"w")
y.write(k)
y.close()
def word():
print(b)
word=input('word to be searched')
if word in c:
d=c.count(word)
print(d,word)
re=input('replaceable word')
ye=input('replace or 1.replace all')
if ye=='1' or ye=='replace all':
rep(re,ye,word)
elif ye=='2' or ye=='replace':
repl(re,ye,word)
global a
global b
global c
a=input('file name without format')
b=open(a,"r").read()
c=b.split(' ')
word()
| def repl(re, ye, word):
for y in range(len(c)):
if c[y] == word:
n = input('yes or no')
if n == 'yes':
c[y] = re
else:
pass
k = ' '.join(c)
print(k)
y = open(a, 'w')
y.write(k)
y.close()
def rep(re, ye, word):
for y in range(len(c)):
if c[y] == word:
c[y] = re
k = ' '.join(c)
print(k)
y = open(a, 'w')
y.write(k)
y.close()
def word():
print(b)
word = input('word to be searched')
if word in c:
d = c.count(word)
print(d, word)
re = input('replaceable word')
ye = input('replace or 1.replace all')
if ye == '1' or ye == 'replace all':
rep(re, ye, word)
elif ye == '2' or ye == 'replace':
repl(re, ye, word)
global a
global b
global c
a = input('file name without format')
b = open(a, 'r').read()
c = b.split(' ')
word() |
#
# PySNMP MIB module RADLAN-DIGITALKEYMANAGE-MIB (http://snmplabs.com/pysmi)
# ASN.1 source file:///Users/davwang4/Dev/mibs.snmplabs.com/asn1/RADLAN-DIGITALKEYMANAGE-MIB
# Produced by pysmi-0.3.4 at Wed May 1 14:46:21 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")
rnd, = mibBuilder.importSymbols("RADLAN-MIB", "rnd")
NotificationGroup, ModuleCompliance = mibBuilder.importSymbols("SNMPv2-CONF", "NotificationGroup", "ModuleCompliance")
Counter32, iso, TimeTicks, NotificationType, ModuleIdentity, Bits, ObjectIdentity, MibIdentifier, Unsigned32, Counter64, Gauge32, IpAddress, MibScalar, MibTable, MibTableRow, MibTableColumn, Integer32 = mibBuilder.importSymbols("SNMPv2-SMI", "Counter32", "iso", "TimeTicks", "NotificationType", "ModuleIdentity", "Bits", "ObjectIdentity", "MibIdentifier", "Unsigned32", "Counter64", "Gauge32", "IpAddress", "MibScalar", "MibTable", "MibTableRow", "MibTableColumn", "Integer32")
TruthValue, TextualConvention, RowStatus, DisplayString, DateAndTime = mibBuilder.importSymbols("SNMPv2-TC", "TruthValue", "TextualConvention", "RowStatus", "DisplayString", "DateAndTime")
rlDigitalKeyManage = ModuleIdentity((1, 3, 6, 1, 4, 1, 89, 86))
rlDigitalKeyManage.setRevisions(('2007-01-02 00:00',))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
if mibBuilder.loadTexts: rlDigitalKeyManage.setRevisionsDescriptions(('Initial revision.',))
if mibBuilder.loadTexts: rlDigitalKeyManage.setLastUpdated('200701020000Z')
if mibBuilder.loadTexts: rlDigitalKeyManage.setOrganization('Radlan - a MARVELL company. Marvell Semiconductor, Inc.')
if mibBuilder.loadTexts: rlDigitalKeyManage.setContactInfo('www.marvell.com')
if mibBuilder.loadTexts: rlDigitalKeyManage.setDescription('This private MIB module defines digital key manage private MIBs.')
rlMD5KeyChainTable = MibTable((1, 3, 6, 1, 4, 1, 89, 86, 1), )
if mibBuilder.loadTexts: rlMD5KeyChainTable.setStatus('current')
if mibBuilder.loadTexts: rlMD5KeyChainTable.setDescription('Key-chains and keys')
rlMD5KeyChainEntry = MibTableRow((1, 3, 6, 1, 4, 1, 89, 86, 1, 1), ).setIndexNames((0, "RADLAN-DIGITALKEYMANAGE-MIB", "rlMD5KeyChainName"), (0, "RADLAN-DIGITALKEYMANAGE-MIB", "rlMD5KeyChainKeyId"))
if mibBuilder.loadTexts: rlMD5KeyChainEntry.setStatus('current')
if mibBuilder.loadTexts: rlMD5KeyChainEntry.setDescription('Key-chain with key ID that belongs to this chain')
rlMD5KeyChainName = MibTableColumn((1, 3, 6, 1, 4, 1, 89, 86, 1, 1, 1), DisplayString()).setMaxAccess("readonly")
if mibBuilder.loadTexts: rlMD5KeyChainName.setStatus('current')
if mibBuilder.loadTexts: rlMD5KeyChainName.setDescription('Name of the key-chain to which belongs the secret authentication key')
rlMD5KeyChainKeyId = MibTableColumn((1, 3, 6, 1, 4, 1, 89, 86, 1, 1, 2), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 255))).setMaxAccess("readonly")
if mibBuilder.loadTexts: rlMD5KeyChainKeyId.setStatus('current')
if mibBuilder.loadTexts: rlMD5KeyChainKeyId.setDescription('A 8-bit identifier for the secret authentication key. This identifier unique only for specific key chain')
rlMD5KeyChainKey = MibTableColumn((1, 3, 6, 1, 4, 1, 89, 86, 1, 1, 3), DisplayString().subtype(subtypeSpec=ValueSizeConstraint(0, 16))).setMaxAccess("readcreate")
if mibBuilder.loadTexts: rlMD5KeyChainKey.setStatus('current')
if mibBuilder.loadTexts: rlMD5KeyChainKey.setDescription('The 128-bit secret authentication key')
rlMD5KeyChainKeyStartAccept = MibTableColumn((1, 3, 6, 1, 4, 1, 89, 86, 1, 1, 4), DateAndTime().clone(hexValue="00000000")).setMaxAccess("readcreate")
if mibBuilder.loadTexts: rlMD5KeyChainKeyStartAccept.setStatus('current')
if mibBuilder.loadTexts: rlMD5KeyChainKeyStartAccept.setDescription('The time that the router will start accepting packets that have been created with the given key')
rlMD5KeyChainKeyStartGenerate = MibTableColumn((1, 3, 6, 1, 4, 1, 89, 86, 1, 1, 5), DateAndTime().clone(hexValue="00000000")).setMaxAccess("readcreate")
if mibBuilder.loadTexts: rlMD5KeyChainKeyStartGenerate.setStatus('current')
if mibBuilder.loadTexts: rlMD5KeyChainKeyStartGenerate.setDescription('The time that the router will start using the key for packet generation')
rlMD5KeyChainKeyStopGenerate = MibTableColumn((1, 3, 6, 1, 4, 1, 89, 86, 1, 1, 6), DateAndTime().clone(hexValue="FFFFFFFF")).setMaxAccess("readcreate")
if mibBuilder.loadTexts: rlMD5KeyChainKeyStopGenerate.setStatus('current')
if mibBuilder.loadTexts: rlMD5KeyChainKeyStopGenerate.setDescription('The time that the router will stop using the key for packet generation')
rlMD5KeyChainKeyStopAccept = MibTableColumn((1, 3, 6, 1, 4, 1, 89, 86, 1, 1, 7), DateAndTime().clone(hexValue="FFFFFFFF")).setMaxAccess("readcreate")
if mibBuilder.loadTexts: rlMD5KeyChainKeyStopAccept.setStatus('current')
if mibBuilder.loadTexts: rlMD5KeyChainKeyStopAccept.setDescription('The time that the router will stop accepting packets that have been created with the given key')
rlMD5KeyChainKeyValidForAccept = MibTableColumn((1, 3, 6, 1, 4, 1, 89, 86, 1, 1, 8), TruthValue().clone('false')).setMaxAccess("readonly")
if mibBuilder.loadTexts: rlMD5KeyChainKeyValidForAccept.setStatus('current')
if mibBuilder.loadTexts: rlMD5KeyChainKeyValidForAccept.setDescription("A value of 'true' indicates that given key is valid for accepting packets")
rlMD5KeyChainKeyValidForGenerate = MibTableColumn((1, 3, 6, 1, 4, 1, 89, 86, 1, 1, 9), TruthValue().clone('false')).setMaxAccess("readonly")
if mibBuilder.loadTexts: rlMD5KeyChainKeyValidForGenerate.setStatus('current')
if mibBuilder.loadTexts: rlMD5KeyChainKeyValidForGenerate.setDescription("A value of 'true' indicates that given key is valid for packet generation")
rlMD5KeyChainRowStatus = MibTableColumn((1, 3, 6, 1, 4, 1, 89, 86, 1, 1, 10), RowStatus()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: rlMD5KeyChainRowStatus.setStatus('current')
if mibBuilder.loadTexts: rlMD5KeyChainRowStatus.setDescription('It is used to insert, update or delete an entry')
mibBuilder.exportSymbols("RADLAN-DIGITALKEYMANAGE-MIB", rlMD5KeyChainKeyStartGenerate=rlMD5KeyChainKeyStartGenerate, rlDigitalKeyManage=rlDigitalKeyManage, rlMD5KeyChainTable=rlMD5KeyChainTable, rlMD5KeyChainKey=rlMD5KeyChainKey, rlMD5KeyChainRowStatus=rlMD5KeyChainRowStatus, rlMD5KeyChainKeyValidForGenerate=rlMD5KeyChainKeyValidForGenerate, rlMD5KeyChainKeyStopAccept=rlMD5KeyChainKeyStopAccept, rlMD5KeyChainKeyStopGenerate=rlMD5KeyChainKeyStopGenerate, PYSNMP_MODULE_ID=rlDigitalKeyManage, rlMD5KeyChainName=rlMD5KeyChainName, rlMD5KeyChainKeyValidForAccept=rlMD5KeyChainKeyValidForAccept, rlMD5KeyChainKeyId=rlMD5KeyChainKeyId, rlMD5KeyChainEntry=rlMD5KeyChainEntry, rlMD5KeyChainKeyStartAccept=rlMD5KeyChainKeyStartAccept)
| (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')
(rnd,) = mibBuilder.importSymbols('RADLAN-MIB', 'rnd')
(notification_group, module_compliance) = mibBuilder.importSymbols('SNMPv2-CONF', 'NotificationGroup', 'ModuleCompliance')
(counter32, iso, time_ticks, notification_type, module_identity, bits, object_identity, mib_identifier, unsigned32, counter64, gauge32, ip_address, mib_scalar, mib_table, mib_table_row, mib_table_column, integer32) = mibBuilder.importSymbols('SNMPv2-SMI', 'Counter32', 'iso', 'TimeTicks', 'NotificationType', 'ModuleIdentity', 'Bits', 'ObjectIdentity', 'MibIdentifier', 'Unsigned32', 'Counter64', 'Gauge32', 'IpAddress', 'MibScalar', 'MibTable', 'MibTableRow', 'MibTableColumn', 'Integer32')
(truth_value, textual_convention, row_status, display_string, date_and_time) = mibBuilder.importSymbols('SNMPv2-TC', 'TruthValue', 'TextualConvention', 'RowStatus', 'DisplayString', 'DateAndTime')
rl_digital_key_manage = module_identity((1, 3, 6, 1, 4, 1, 89, 86))
rlDigitalKeyManage.setRevisions(('2007-01-02 00:00',))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
if mibBuilder.loadTexts:
rlDigitalKeyManage.setRevisionsDescriptions(('Initial revision.',))
if mibBuilder.loadTexts:
rlDigitalKeyManage.setLastUpdated('200701020000Z')
if mibBuilder.loadTexts:
rlDigitalKeyManage.setOrganization('Radlan - a MARVELL company. Marvell Semiconductor, Inc.')
if mibBuilder.loadTexts:
rlDigitalKeyManage.setContactInfo('www.marvell.com')
if mibBuilder.loadTexts:
rlDigitalKeyManage.setDescription('This private MIB module defines digital key manage private MIBs.')
rl_md5_key_chain_table = mib_table((1, 3, 6, 1, 4, 1, 89, 86, 1))
if mibBuilder.loadTexts:
rlMD5KeyChainTable.setStatus('current')
if mibBuilder.loadTexts:
rlMD5KeyChainTable.setDescription('Key-chains and keys')
rl_md5_key_chain_entry = mib_table_row((1, 3, 6, 1, 4, 1, 89, 86, 1, 1)).setIndexNames((0, 'RADLAN-DIGITALKEYMANAGE-MIB', 'rlMD5KeyChainName'), (0, 'RADLAN-DIGITALKEYMANAGE-MIB', 'rlMD5KeyChainKeyId'))
if mibBuilder.loadTexts:
rlMD5KeyChainEntry.setStatus('current')
if mibBuilder.loadTexts:
rlMD5KeyChainEntry.setDescription('Key-chain with key ID that belongs to this chain')
rl_md5_key_chain_name = mib_table_column((1, 3, 6, 1, 4, 1, 89, 86, 1, 1, 1), display_string()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
rlMD5KeyChainName.setStatus('current')
if mibBuilder.loadTexts:
rlMD5KeyChainName.setDescription('Name of the key-chain to which belongs the secret authentication key')
rl_md5_key_chain_key_id = mib_table_column((1, 3, 6, 1, 4, 1, 89, 86, 1, 1, 2), integer32().subtype(subtypeSpec=value_range_constraint(1, 255))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
rlMD5KeyChainKeyId.setStatus('current')
if mibBuilder.loadTexts:
rlMD5KeyChainKeyId.setDescription('A 8-bit identifier for the secret authentication key. This identifier unique only for specific key chain')
rl_md5_key_chain_key = mib_table_column((1, 3, 6, 1, 4, 1, 89, 86, 1, 1, 3), display_string().subtype(subtypeSpec=value_size_constraint(0, 16))).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
rlMD5KeyChainKey.setStatus('current')
if mibBuilder.loadTexts:
rlMD5KeyChainKey.setDescription('The 128-bit secret authentication key')
rl_md5_key_chain_key_start_accept = mib_table_column((1, 3, 6, 1, 4, 1, 89, 86, 1, 1, 4), date_and_time().clone(hexValue='00000000')).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
rlMD5KeyChainKeyStartAccept.setStatus('current')
if mibBuilder.loadTexts:
rlMD5KeyChainKeyStartAccept.setDescription('The time that the router will start accepting packets that have been created with the given key')
rl_md5_key_chain_key_start_generate = mib_table_column((1, 3, 6, 1, 4, 1, 89, 86, 1, 1, 5), date_and_time().clone(hexValue='00000000')).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
rlMD5KeyChainKeyStartGenerate.setStatus('current')
if mibBuilder.loadTexts:
rlMD5KeyChainKeyStartGenerate.setDescription('The time that the router will start using the key for packet generation')
rl_md5_key_chain_key_stop_generate = mib_table_column((1, 3, 6, 1, 4, 1, 89, 86, 1, 1, 6), date_and_time().clone(hexValue='FFFFFFFF')).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
rlMD5KeyChainKeyStopGenerate.setStatus('current')
if mibBuilder.loadTexts:
rlMD5KeyChainKeyStopGenerate.setDescription('The time that the router will stop using the key for packet generation')
rl_md5_key_chain_key_stop_accept = mib_table_column((1, 3, 6, 1, 4, 1, 89, 86, 1, 1, 7), date_and_time().clone(hexValue='FFFFFFFF')).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
rlMD5KeyChainKeyStopAccept.setStatus('current')
if mibBuilder.loadTexts:
rlMD5KeyChainKeyStopAccept.setDescription('The time that the router will stop accepting packets that have been created with the given key')
rl_md5_key_chain_key_valid_for_accept = mib_table_column((1, 3, 6, 1, 4, 1, 89, 86, 1, 1, 8), truth_value().clone('false')).setMaxAccess('readonly')
if mibBuilder.loadTexts:
rlMD5KeyChainKeyValidForAccept.setStatus('current')
if mibBuilder.loadTexts:
rlMD5KeyChainKeyValidForAccept.setDescription("A value of 'true' indicates that given key is valid for accepting packets")
rl_md5_key_chain_key_valid_for_generate = mib_table_column((1, 3, 6, 1, 4, 1, 89, 86, 1, 1, 9), truth_value().clone('false')).setMaxAccess('readonly')
if mibBuilder.loadTexts:
rlMD5KeyChainKeyValidForGenerate.setStatus('current')
if mibBuilder.loadTexts:
rlMD5KeyChainKeyValidForGenerate.setDescription("A value of 'true' indicates that given key is valid for packet generation")
rl_md5_key_chain_row_status = mib_table_column((1, 3, 6, 1, 4, 1, 89, 86, 1, 1, 10), row_status()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
rlMD5KeyChainRowStatus.setStatus('current')
if mibBuilder.loadTexts:
rlMD5KeyChainRowStatus.setDescription('It is used to insert, update or delete an entry')
mibBuilder.exportSymbols('RADLAN-DIGITALKEYMANAGE-MIB', rlMD5KeyChainKeyStartGenerate=rlMD5KeyChainKeyStartGenerate, rlDigitalKeyManage=rlDigitalKeyManage, rlMD5KeyChainTable=rlMD5KeyChainTable, rlMD5KeyChainKey=rlMD5KeyChainKey, rlMD5KeyChainRowStatus=rlMD5KeyChainRowStatus, rlMD5KeyChainKeyValidForGenerate=rlMD5KeyChainKeyValidForGenerate, rlMD5KeyChainKeyStopAccept=rlMD5KeyChainKeyStopAccept, rlMD5KeyChainKeyStopGenerate=rlMD5KeyChainKeyStopGenerate, PYSNMP_MODULE_ID=rlDigitalKeyManage, rlMD5KeyChainName=rlMD5KeyChainName, rlMD5KeyChainKeyValidForAccept=rlMD5KeyChainKeyValidForAccept, rlMD5KeyChainKeyId=rlMD5KeyChainKeyId, rlMD5KeyChainEntry=rlMD5KeyChainEntry, rlMD5KeyChainKeyStartAccept=rlMD5KeyChainKeyStartAccept) |
#
# PySNMP MIB module HUAWEI-EASY-OPERATION-MIB (http://snmplabs.com/pysmi)
# ASN.1 source file:///Users/davwang4/Dev/mibs.snmplabs.com/asn1/HUAWEI-EASY-OPERATION-MIB
# Produced by pysmi-0.3.4 at Wed May 1 13:44:20 2019
# On host DAVWANG4-M-1475 platform Darwin version 18.5.0 by user davwang4
# Using Python version 3.7.3 (default, Mar 27 2019, 09:23:15)
#
OctetString, ObjectIdentifier, Integer = mibBuilder.importSymbols("ASN1", "OctetString", "ObjectIdentifier", "Integer")
NamedValues, = mibBuilder.importSymbols("ASN1-ENUMERATION", "NamedValues")
SingleValueConstraint, ValueSizeConstraint, ConstraintsUnion, ValueRangeConstraint, ConstraintsIntersection = mibBuilder.importSymbols("ASN1-REFINEMENT", "SingleValueConstraint", "ValueSizeConstraint", "ConstraintsUnion", "ValueRangeConstraint", "ConstraintsIntersection")
hwDatacomm, = mibBuilder.importSymbols("HUAWEI-MIB", "hwDatacomm")
InetAddress, InetAddressType = mibBuilder.importSymbols("INET-ADDRESS-MIB", "InetAddress", "InetAddressType")
EnabledStatus, = mibBuilder.importSymbols("P-BRIDGE-MIB", "EnabledStatus")
NotificationGroup, ObjectGroup, ModuleCompliance = mibBuilder.importSymbols("SNMPv2-CONF", "NotificationGroup", "ObjectGroup", "ModuleCompliance")
MibScalar, MibTable, MibTableRow, MibTableColumn, iso, Integer32, Unsigned32, IpAddress, Counter64, Bits, NotificationType, Counter32, Gauge32, ObjectIdentity, TimeTicks, ModuleIdentity, MibIdentifier = mibBuilder.importSymbols("SNMPv2-SMI", "MibScalar", "MibTable", "MibTableRow", "MibTableColumn", "iso", "Integer32", "Unsigned32", "IpAddress", "Counter64", "Bits", "NotificationType", "Counter32", "Gauge32", "ObjectIdentity", "TimeTicks", "ModuleIdentity", "MibIdentifier")
MacAddress, DisplayString, RowStatus, TextualConvention = mibBuilder.importSymbols("SNMPv2-TC", "MacAddress", "DisplayString", "RowStatus", "TextualConvention")
hwEasyOperationMIB = ModuleIdentity((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311))
hwEasyOperationMIB.setRevisions(('2014-09-09 00:00', '2014-06-04 00:00', '2013-12-30 00:00', '2013-08-05 00:00', '2013-03-18 00:00',))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
if mibBuilder.loadTexts: hwEasyOperationMIB.setRevisionsDescriptions(('Revisions made by HUAWEI.', 'Revisions made by HUAWEI.', 'Revisions made by HUAWEI.', 'Revisions made by HUAWEI.', 'Revisions made by HUAWEI.',))
if mibBuilder.loadTexts: hwEasyOperationMIB.setLastUpdated('201409090000Z')
if mibBuilder.loadTexts: hwEasyOperationMIB.setOrganization('Huawei Technologies Co.,Ltd.')
if mibBuilder.loadTexts: hwEasyOperationMIB.setContactInfo("Huawei Industrial Base Bantian, Longgang Shenzhen 518129 People's Republic of China Website: http://www.huawei.com Email: support@huawei.com ")
if mibBuilder.loadTexts: hwEasyOperationMIB.setDescription('Huawei Easy Opearation MIB.')
hwEasyOperationGlobalObjects = MibIdentifier((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 1))
hwEasyOperationCommanderEnable = MibScalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 1, 1), EnabledStatus()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: hwEasyOperationCommanderEnable.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationCommanderEnable.setDescription('This object specifies the Easy Operation Commander operation mode.')
hwEasyOperationCommanderIpAddress = MibScalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 1, 2), InetAddress()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: hwEasyOperationCommanderIpAddress.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationCommanderIpAddress.setDescription('The IP address of commander.')
hwEasyOperationCommanderIpAddressType = MibScalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 1, 3), InetAddressType()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: hwEasyOperationCommanderIpAddressType.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationCommanderIpAddressType.setDescription('The IP address type of commander.')
hwEasyOperationCommanderUdpPort = MibScalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 1, 4), Integer32()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: hwEasyOperationCommanderUdpPort.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationCommanderUdpPort.setDescription('The UDP port of commander.')
hwEasyOperationServerType = MibScalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 1, 5), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2, 3))).clone(namedValues=NamedValues(("tftp", 1), ("ftp", 2), ("sftp", 3)))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: hwEasyOperationServerType.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationServerType.setDescription('The type of file server.')
hwEasyOperationServerIpAddress = MibScalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 1, 6), InetAddress()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: hwEasyOperationServerIpAddress.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationServerIpAddress.setDescription('The IP address of file server.')
hwEasyOperationServerIpAddressType = MibScalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 1, 7), InetAddressType()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: hwEasyOperationServerIpAddressType.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationServerIpAddressType.setDescription('The IP address type of file server.')
hwEasyOperationServerPort = MibScalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 1, 8), Integer32()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: hwEasyOperationServerPort.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationServerPort.setDescription('The port number of file server.')
hwEasyOperationAutoClearEnable = MibScalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 1, 9), EnabledStatus()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: hwEasyOperationAutoClearEnable.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationAutoClearEnable.setDescription('Whether client would clear the old software file when the free space is not enough.')
hwEasyOperationActivateMode = MibScalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 1, 10), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2))).clone(namedValues=NamedValues(("default", 1), ("reload", 2)))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: hwEasyOperationActivateMode.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationActivateMode.setDescription('The mode of activating file.')
hwEasyOperationActivateDelayTime = MibScalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 1, 11), Integer32()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: hwEasyOperationActivateDelayTime.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationActivateDelayTime.setDescription('The delay time of activating file.The unit is second(s).')
hwEasyOperationActivateInTime = MibScalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 1, 12), DisplayString()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: hwEasyOperationActivateInTime.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationActivateInTime.setDescription('The specific time of activating file.')
hwEasyOperationBackupConfigMode = MibScalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 1, 13), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2))).clone(namedValues=NamedValues(("overwrite", 1), ("duplicate", 2)))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: hwEasyOperationBackupConfigMode.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationBackupConfigMode.setDescription('The mode of file created on the server.')
hwEasyOperationBackupConfigInterval = MibScalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 1, 14), Integer32()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: hwEasyOperationBackupConfigInterval.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationBackupConfigInterval.setDescription('The interval of configuration backup .The unit is hour(s)')
hwEasyOperationDefaultSysSoftware = MibScalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 1, 15), DisplayString()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: hwEasyOperationDefaultSysSoftware.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationDefaultSysSoftware.setDescription('The default name of software file.')
hwEasyOperationDefaultSysSoftwareVer = MibScalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 1, 16), DisplayString()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: hwEasyOperationDefaultSysSoftwareVer.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationDefaultSysSoftwareVer.setDescription('The version of default software file.')
hwEasyOperationDefaultConfig = MibScalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 1, 17), DisplayString()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: hwEasyOperationDefaultConfig.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationDefaultConfig.setDescription('The default name of configuration file.')
hwEasyOperationDefaultPatch = MibScalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 1, 18), DisplayString()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: hwEasyOperationDefaultPatch.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationDefaultPatch.setDescription('The default name of patch file.')
hwEasyOperationDefaultWebfile = MibScalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 1, 19), DisplayString()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: hwEasyOperationDefaultWebfile.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationDefaultWebfile.setDescription('The default name of WEB file.')
hwEasyOperationDefaultLicense = MibScalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 1, 20), DisplayString()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: hwEasyOperationDefaultLicense.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationDefaultLicense.setDescription('The default name of license file.')
hwEasyOperationDefaultCustomfile1 = MibScalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 1, 21), DisplayString()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: hwEasyOperationDefaultCustomfile1.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationDefaultCustomfile1.setDescription('The default name of custom file.')
hwEasyOperationDefaultCustomfile2 = MibScalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 1, 22), DisplayString()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: hwEasyOperationDefaultCustomfile2.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationDefaultCustomfile2.setDescription('The default name of custom file.')
hwEasyOperationDefaultCustomfile3 = MibScalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 1, 23), DisplayString()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: hwEasyOperationDefaultCustomfile3.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationDefaultCustomfile3.setDescription('The default name of custom file.')
hwEasyOperationClientAutoJoinEnable = MibScalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 1, 24), EnabledStatus()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: hwEasyOperationClientAutoJoinEnable.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientAutoJoinEnable.setDescription('Whether commander can receive the information of new clients.')
hwEasyOperationTopologyEnable = MibScalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 1, 25), EnabledStatus()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: hwEasyOperationTopologyEnable.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationTopologyEnable.setDescription('Whether commander can collect the topology information of new clients.')
hwEasyOperationClientAgingTime = MibScalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 1, 26), Integer32()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: hwEasyOperationClientAgingTime.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientAgingTime.setDescription('The aging time of client which is lost. The unit is hour(s).')
hwEasyOperationGroup = MibIdentifier((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2))
hwEasyOperationTotalGroupNumber = MibScalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 1), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: hwEasyOperationTotalGroupNumber.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationTotalGroupNumber.setDescription('The total number of group.')
hwEasyOperationBuildInGroupNumber = MibScalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 2), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: hwEasyOperationBuildInGroupNumber.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationBuildInGroupNumber.setDescription('The number of build-in group.')
hwEasyOperationCustomGroupNumber = MibScalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 3), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: hwEasyOperationCustomGroupNumber.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationCustomGroupNumber.setDescription('The number of custom group.')
hwEasyOperationGroupTable = MibTable((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 4), )
if mibBuilder.loadTexts: hwEasyOperationGroupTable.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationGroupTable.setDescription('Group table.')
hwEasyOperationGroupEntry = MibTableRow((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 4, 1), ).setIndexNames((0, "HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationGroupIndex"))
if mibBuilder.loadTexts: hwEasyOperationGroupEntry.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationGroupEntry.setDescription('The entry of group table.')
hwEasyOperationGroupIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 4, 1, 1), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 4096)))
if mibBuilder.loadTexts: hwEasyOperationGroupIndex.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationGroupIndex.setDescription('The index of group table.')
hwEasyOperationGroupType = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 4, 1, 2), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2, 3, 4, 5, 6))).clone(namedValues=NamedValues(("buildIn", 1), ("macAddress", 2), ("esn", 3), ("model", 4), ("deviceType", 5), ("ipAddress", 6)))).setMaxAccess("readcreate")
if mibBuilder.loadTexts: hwEasyOperationGroupType.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationGroupType.setDescription('The type of group.')
hwEasyOperationGroupName = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 4, 1, 3), DisplayString()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: hwEasyOperationGroupName.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationGroupName.setDescription('The name of group.')
hwEasyOperationGroupSysSoftware = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 4, 1, 4), DisplayString()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: hwEasyOperationGroupSysSoftware.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationGroupSysSoftware.setDescription('The software file name of group.')
hwEasyOperationGroupSysSoftwareVer = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 4, 1, 5), DisplayString()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: hwEasyOperationGroupSysSoftwareVer.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationGroupSysSoftwareVer.setDescription('The software version of group.')
hwEasyOperationGroupConfig = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 4, 1, 6), DisplayString()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: hwEasyOperationGroupConfig.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationGroupConfig.setDescription('The configuration file name of group.')
hwEasyOperationGroupPatch = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 4, 1, 7), DisplayString()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: hwEasyOperationGroupPatch.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationGroupPatch.setDescription('The patch file name of group.')
hwEasyOperationGroupWebfile = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 4, 1, 8), DisplayString()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: hwEasyOperationGroupWebfile.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationGroupWebfile.setDescription('The WEB file name of group.')
hwEasyOperationGroupLicense = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 4, 1, 9), DisplayString()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: hwEasyOperationGroupLicense.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationGroupLicense.setDescription('The license file name of group.')
hwEasyOperationGroupCustomfile1 = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 4, 1, 10), DisplayString()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: hwEasyOperationGroupCustomfile1.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationGroupCustomfile1.setDescription('The custom file name of group.')
hwEasyOperationGroupCustomfile2 = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 4, 1, 11), DisplayString()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: hwEasyOperationGroupCustomfile2.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationGroupCustomfile2.setDescription('The custom file name of group.')
hwEasyOperationGroupCustomfile3 = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 4, 1, 12), DisplayString()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: hwEasyOperationGroupCustomfile3.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationGroupCustomfile3.setDescription('The custom file name of group.')
hwEasyOperationGroupActivateMode = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 4, 1, 13), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2))).clone(namedValues=NamedValues(("default", 1), ("reload", 2)))).setMaxAccess("readcreate")
if mibBuilder.loadTexts: hwEasyOperationGroupActivateMode.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationGroupActivateMode.setDescription('The mode of activating file of group.')
hwEasyOperationGroupActivateDelayTime = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 4, 1, 14), Integer32()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: hwEasyOperationGroupActivateDelayTime.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationGroupActivateDelayTime.setDescription('The delay time of activating file of group.The unit is second(s)')
hwEasyOperationGroupActivateInTime = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 4, 1, 15), DisplayString()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: hwEasyOperationGroupActivateInTime.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationGroupActivateInTime.setDescription('The specific time of activating file of group.')
hwEasyOperationGroupRowStatus = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 4, 1, 50), RowStatus()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: hwEasyOperationGroupRowStatus.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationGroupRowStatus.setDescription('The RowStatus of group table.')
hwEasyOperationGroupMatchTable = MibTable((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 5), )
if mibBuilder.loadTexts: hwEasyOperationGroupMatchTable.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationGroupMatchTable.setDescription('The match rule of group.')
hwEasyOperationGroupMatchEntry = MibTableRow((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 5, 1), ).setIndexNames((0, "HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationGroupIndex"), (0, "HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationGroupMatchIndex"))
if mibBuilder.loadTexts: hwEasyOperationGroupMatchEntry.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationGroupMatchEntry.setDescription('The entry of match rule of group.')
hwEasyOperationGroupMatchIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 5, 1, 1), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 4096)))
if mibBuilder.loadTexts: hwEasyOperationGroupMatchIndex.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationGroupMatchIndex.setDescription('The index of match rule table.')
hwEasyOperationGroupMatchMacAddress = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 5, 1, 2), MacAddress()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: hwEasyOperationGroupMatchMacAddress.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationGroupMatchMacAddress.setDescription('The match rule of MAC address.')
hwEasyOperationGroupMatchMacMask = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 5, 1, 3), Integer32()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: hwEasyOperationGroupMatchMacMask.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationGroupMatchMacMask.setDescription('The match rule of mask of MAC address.')
hwEasyOperationGroupMatchEsn = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 5, 1, 4), DisplayString()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: hwEasyOperationGroupMatchEsn.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationGroupMatchEsn.setDescription('The match rule of ESN.')
hwEasyOperationGroupMatchModel = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 5, 1, 5), DisplayString()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: hwEasyOperationGroupMatchModel.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationGroupMatchModel.setDescription('The match rule of model of device.')
hwEasyOperationGroupMatchDeviceType = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 5, 1, 6), DisplayString()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: hwEasyOperationGroupMatchDeviceType.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationGroupMatchDeviceType.setDescription('The match rule of type of device.')
hwEasyOperationGroupMatchIpAddress = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 5, 1, 7), InetAddress()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: hwEasyOperationGroupMatchIpAddress.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationGroupMatchIpAddress.setDescription('The match rule of IP address.')
hwEasyOperationGroupMatchIpAddressType = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 5, 1, 8), InetAddressType()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: hwEasyOperationGroupMatchIpAddressType.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationGroupMatchIpAddressType.setDescription('The match rule of type of IP address.')
hwEasyOperationGroupMatchIpAddressMask = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 5, 1, 9), Integer32()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: hwEasyOperationGroupMatchIpAddressMask.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationGroupMatchIpAddressMask.setDescription('The match rule of mask of IP address.')
hwEasyOperationGroupMatchRowStatus = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 5, 1, 50), RowStatus()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: hwEasyOperationGroupMatchRowStatus.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationGroupMatchRowStatus.setDescription('The RowStatus of match rule table.')
hwEasyOperationClient = MibIdentifier((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5))
hwEasyOperationClientNumber = MibScalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 1), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: hwEasyOperationClientNumber.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientNumber.setDescription('The number of client.')
hwEasyOperationClientInfoTable = MibTable((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2), )
if mibBuilder.loadTexts: hwEasyOperationClientInfoTable.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientInfoTable.setDescription('The client table.')
hwEasyOperationClientInfoEntry = MibTableRow((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1), ).setIndexNames((0, "HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientInfoClientIndex"))
if mibBuilder.loadTexts: hwEasyOperationClientInfoEntry.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientInfoEntry.setDescription('The entry of client table.')
hwEasyOperationClientInfoClientIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 1), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 4096)))
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientIndex.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientIndex.setDescription('The index of client table.')
hwEasyOperationClientInfoClientMacAddress = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 2), MacAddress()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientMacAddress.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientMacAddress.setDescription('The MAC address of client.')
hwEasyOperationClientInfoClientEsn = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 3), DisplayString()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientEsn.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientEsn.setDescription('The ESN of client.')
hwEasyOperationClientInfoClientHostName = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 4), DisplayString()).setMaxAccess("readonly")
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientHostName.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientHostName.setDescription('The host name of client.')
hwEasyOperationClientInfoClientIpAddress = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 5), InetAddress()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientIpAddress.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientIpAddress.setDescription('The IP address of client.')
hwEasyOperationClientInfoClientIpAddressType = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 6), InetAddressType()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientIpAddressType.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientIpAddressType.setDescription('The IP address type of client.')
hwEasyOperationClientInfoClientModel = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 7), DisplayString()).setMaxAccess("readonly")
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientModel.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientModel.setDescription('The model of client.')
hwEasyOperationClientInfoClientDeviceType = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 8), DisplayString()).setMaxAccess("readonly")
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientDeviceType.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientDeviceType.setDescription('The device type of client.')
hwEasyOperationClientInfoClientSysSoftware = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 9), DisplayString()).setMaxAccess("readonly")
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientSysSoftware.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientSysSoftware.setDescription('The startup software file name of client.')
hwEasyOperationClientInfoClientSysSoftwareVer = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 10), DisplayString()).setMaxAccess("readonly")
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientSysSoftwareVer.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientSysSoftwareVer.setDescription('The startup software version of client.')
hwEasyOperationClientInfoClientSysConfig = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 11), DisplayString()).setMaxAccess("readonly")
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientSysConfig.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientSysConfig.setDescription('The startup configuration file name of client.')
hwEasyOperationClientInfoClientSysPatch = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 12), DisplayString()).setMaxAccess("readonly")
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientSysPatch.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientSysPatch.setDescription('The startup patch file name of client.')
hwEasyOperationClientInfoClientSysWebFile = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 13), DisplayString()).setMaxAccess("readonly")
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientSysWebFile.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientSysWebFile.setDescription('The startup WEB file name of client.')
hwEasyOperationClientInfoClientSysLicense = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 14), DisplayString()).setMaxAccess("readonly")
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientSysLicense.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientSysLicense.setDescription('The startup license file name of client.')
hwEasyOperationClientInfoClientDownloadSoftware = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 15), DisplayString()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientDownloadSoftware.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientDownloadSoftware.setDescription('The software file name of client in downloading status.')
hwEasyOperationClientInfoClientDownloadSoftwareVer = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 16), DisplayString()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientDownloadSoftwareVer.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientDownloadSoftwareVer.setDescription('The software version of client in downloading status.')
hwEasyOperationClientInfoClientDownloadConfig = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 17), DisplayString()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientDownloadConfig.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientDownloadConfig.setDescription('The configuration file name of client in downloading status.')
hwEasyOperationClientInfoClientDownloadPatch = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 18), DisplayString()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientDownloadPatch.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientDownloadPatch.setDescription('The patch file name of client in downloading status.')
hwEasyOperationClientInfoClientDownloadWebFile = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 19), DisplayString()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientDownloadWebFile.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientDownloadWebFile.setDescription('The WEB file name of client in downloading status.')
hwEasyOperationClientInfoClientDownloadLicense = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 20), DisplayString()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientDownloadLicense.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientDownloadLicense.setDescription('The license file name of client in downloading status.')
hwEasyOperationClientInfoClientDownloadCustomfile1 = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 21), DisplayString()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientDownloadCustomfile1.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientDownloadCustomfile1.setDescription('The custom file name of client in downloading status.')
hwEasyOperationClientInfoClientDownloadCustomfile2 = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 22), DisplayString()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientDownloadCustomfile2.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientDownloadCustomfile2.setDescription('The custom file name of client in downloading status.')
hwEasyOperationClientInfoClientDownloadCustomfile3 = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 23), DisplayString()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientDownloadCustomfile3.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientDownloadCustomfile3.setDescription('The custom file name of client in downloading status.')
hwEasyOperationClientInfoClientMethod = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 24), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2, 3, 4, 255))).clone(namedValues=NamedValues(("running", 1), ("upgrade", 2), ("zeroTouch", 3), ("usbDownload", 4), ("unknown", 255)))).setMaxAccess("readonly")
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientMethod.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientMethod.setDescription('The method of upgrading.')
hwEasyOperationClientInfoClientPhase = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 25), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2, 3, 4, 5, 6, 255))).clone(namedValues=NamedValues(("initial", 1), ("requestIp", 2), ("getDownloadInfo", 3), ("downloadFile", 4), ("activateFile", 5), ("normalRunning", 6), ("unknown", 255)))).setMaxAccess("readonly")
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientPhase.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientPhase.setDescription('The downloading phase of client.')
hwEasyOperationClientInfoClientOperateState = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 26), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2, 3, 4, 5, 6, 7, 8, 9, 255))).clone(namedValues=NamedValues(("finished", 1), ("downloadSoftware", 2), ("downloadConfig", 3), ("downloadPatch", 4), ("downloadWebFile", 5), ("downloadLicense", 6), ("downloadCustomFile1", 7), ("downloadCustomFile2", 8), ("downloadCustomFile3", 9), ("unknown", 255)))).setMaxAccess("readonly")
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientOperateState.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientOperateState.setDescription('The file type in downloading.')
hwEasyOperationClientInfoClientDownloadPercent = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 27), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientDownloadPercent.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientDownloadPercent.setDescription('The percentage of file downloading.')
hwEasyOperationClientInfoClientErrorReason = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 28), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientErrorReason.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientErrorReason.setDescription('The error reason in processing.')
hwEasyOperationClientInfoClientErrorDescr = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 29), DisplayString()).setMaxAccess("readonly")
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientErrorDescr.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientErrorDescr.setDescription('The error description in processing.')
hwEasyOperationClientInfoClientBackupErrorReason = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 30), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientBackupErrorReason.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientBackupErrorReason.setDescription('The error reason in backup configuration.')
hwEasyOperationClientInfoClientBackupErrorDescr = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 31), DisplayString()).setMaxAccess("readonly")
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientBackupErrorDescr.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientBackupErrorDescr.setDescription('The error description in backup configuration.')
hwEasyOperationClientInfoClientRunState = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 32), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2, 3, 4, 5, 255))).clone(namedValues=NamedValues(("initial", 1), ("normalRunning", 2), ("upgrading", 3), ("lost", 4), ("configuring", 5), ("unknown", 255)))).setMaxAccess("readonly")
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientRunState.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientRunState.setDescription('The running state of client.')
hwEasyOperationClientInfoClientCpuUsage = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 33), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientCpuUsage.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientCpuUsage.setDescription('The cpu usage of client.')
hwEasyOperationClientInfoClientMemoryUsage = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 34), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientMemoryUsage.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientMemoryUsage.setDescription('The memory usage of client.')
hwEasyOperationClientInfoClientRowStatus = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 100), RowStatus()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientRowStatus.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientInfoClientRowStatus.setDescription('The RowStatus of client table.')
hwEasyOperationClientReplaceTable = MibTable((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 3), )
if mibBuilder.loadTexts: hwEasyOperationClientReplaceTable.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientReplaceTable.setDescription('The replace client table.')
hwEasyOperationClientReplaceEntry = MibTableRow((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 3, 1), ).setIndexNames((0, "HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientReplaceClientIndex"))
if mibBuilder.loadTexts: hwEasyOperationClientReplaceEntry.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientReplaceEntry.setDescription('The entry of replace client table.')
hwEasyOperationClientReplaceClientIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 3, 1, 1), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 4096)))
if mibBuilder.loadTexts: hwEasyOperationClientReplaceClientIndex.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientReplaceClientIndex.setDescription('The index of replace client table.')
hwEasyOperationClientReplaceNewMacAddress = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 3, 1, 2), MacAddress()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: hwEasyOperationClientReplaceNewMacAddress.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientReplaceNewMacAddress.setDescription('The MAC address of new device.')
hwEasyOperationClientReplaceNewEsn = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 3, 1, 3), DisplayString()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: hwEasyOperationClientReplaceNewEsn.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientReplaceNewEsn.setDescription('The ESN of new device.')
hwEasyOperationClientReplaceDownloadSoftware = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 3, 1, 4), DisplayString()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: hwEasyOperationClientReplaceDownloadSoftware.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientReplaceDownloadSoftware.setDescription('The software file name needs to be downloaded.')
hwEasyOperationClientReplaceDownloadSoftwareVer = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 3, 1, 5), DisplayString()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: hwEasyOperationClientReplaceDownloadSoftwareVer.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientReplaceDownloadSoftwareVer.setDescription('The software version needs to be downloaded.')
hwEasyOperationClientReplaceDownloadPatch = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 3, 1, 6), DisplayString()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: hwEasyOperationClientReplaceDownloadPatch.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientReplaceDownloadPatch.setDescription('The patch file name needs to be downloaded.')
hwEasyOperationClientReplaceDownloadWebFile = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 3, 1, 7), DisplayString()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: hwEasyOperationClientReplaceDownloadWebFile.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientReplaceDownloadWebFile.setDescription('The WEB file name needs to be downloaded.')
hwEasyOperationClientReplaceDownloadLicense = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 3, 1, 8), DisplayString()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: hwEasyOperationClientReplaceDownloadLicense.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientReplaceDownloadLicense.setDescription('The license file name needs to be downloaded.')
hwEasyOperationClientReplaceDownloadCustomfile1 = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 3, 1, 9), DisplayString()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: hwEasyOperationClientReplaceDownloadCustomfile1.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientReplaceDownloadCustomfile1.setDescription('The custom file name needs to be downloaded.')
hwEasyOperationClientReplaceDownloadCustomfile2 = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 3, 1, 10), DisplayString()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: hwEasyOperationClientReplaceDownloadCustomfile2.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientReplaceDownloadCustomfile2.setDescription('The custom file name needs to be downloaded.')
hwEasyOperationClientReplaceDownloadCustomfile3 = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 3, 1, 11), DisplayString()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: hwEasyOperationClientReplaceDownloadCustomfile3.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientReplaceDownloadCustomfile3.setDescription('The custom file name needs to be downloaded.')
hwEasyOperationClientReplaceRowStatus = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 3, 1, 50), RowStatus()).setMaxAccess("readcreate")
if mibBuilder.loadTexts: hwEasyOperationClientReplaceRowStatus.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientReplaceRowStatus.setDescription('The RowStatus of table.')
hwEasyOperationNotification = MibIdentifier((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 6))
hwEasyOperationTrapVar = MibIdentifier((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 6, 1))
hwEasyOperationTrap = MibIdentifier((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 6, 2))
hwEasyOperationClientAdded = NotificationType((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 6, 2, 1)).setObjects(("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientInfoClientHostName"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientInfoClientIpAddress"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientInfoClientMacAddress"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientInfoClientEsn"))
if mibBuilder.loadTexts: hwEasyOperationClientAdded.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientAdded.setDescription('The notification of client added.')
hwEasyOperationClientLost = NotificationType((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 6, 2, 2)).setObjects(("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientInfoClientHostName"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientInfoClientIpAddress"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientInfoClientMacAddress"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientInfoClientEsn"))
if mibBuilder.loadTexts: hwEasyOperationClientLost.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientLost.setDescription('The notification of client lost.')
hwEasyOperationClientJoinNotPermit = NotificationType((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 6, 2, 3)).setObjects(("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientInfoClientHostName"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientInfoClientIpAddress"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientInfoClientMacAddress"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientInfoClientEsn"))
if mibBuilder.loadTexts: hwEasyOperationClientJoinNotPermit.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientJoinNotPermit.setDescription('The notification of not permit client to join.')
hwEasyOperationMonitor = MibIdentifier((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7))
hwEasyOperationPowerInfo = MibIdentifier((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 1))
hwEasyOperationDevicePowerInfoTable = MibTable((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 1, 1), )
if mibBuilder.loadTexts: hwEasyOperationDevicePowerInfoTable.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationDevicePowerInfoTable.setDescription('The device power information table.')
hwEasyOperationDevicePowerInfoEntry = MibTableRow((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 1, 1, 1), ).setIndexNames((0, "HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationDevicePowerInfoIndex"))
if mibBuilder.loadTexts: hwEasyOperationDevicePowerInfoEntry.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationDevicePowerInfoEntry.setDescription('The entry of device power infomation table.')
hwEasyOperationDevicePowerInfoIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 1, 1, 1, 1), Integer32())
if mibBuilder.loadTexts: hwEasyOperationDevicePowerInfoIndex.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationDevicePowerInfoIndex.setDescription('The index of device power table.')
hwEasyOperationDevicePowerInfoCurrentPower = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 1, 1, 1, 2), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: hwEasyOperationDevicePowerInfoCurrentPower.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationDevicePowerInfoCurrentPower.setDescription('The current power of device.')
hwEasyOperationDevicePowerInfoGauge = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 1, 1, 1, 3), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2))).clone(namedValues=NamedValues(("actual", 1), ("rated", 2)))).setMaxAccess("readonly")
if mibBuilder.loadTexts: hwEasyOperationDevicePowerInfoGauge.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationDevicePowerInfoGauge.setDescription('The gauge of device power.')
hwEasyOperationDevicePowerInfoRatedPower = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 1, 1, 1, 4), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: hwEasyOperationDevicePowerInfoRatedPower.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationDevicePowerInfoRatedPower.setDescription('The rated power of device.')
hwEasyOperationDevicePowerInfoPowerManageMode = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 1, 1, 1, 5), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2, 3, 4))).clone(namedValues=NamedValues(("userDefined", 1), ("standard", 2), ("basic", 3), ("deep", 4)))).setMaxAccess("readonly")
if mibBuilder.loadTexts: hwEasyOperationDevicePowerInfoPowerManageMode.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationDevicePowerInfoPowerManageMode.setDescription('The power manage mode of device.')
hwEasyOperationPortPowerInfoTable = MibTable((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 1, 2), )
if mibBuilder.loadTexts: hwEasyOperationPortPowerInfoTable.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationPortPowerInfoTable.setDescription('The port power information table.')
hwEasyOperationPortPowerInfoEntry = MibTableRow((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 1, 2, 1), ).setIndexNames((0, "HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationPortPowerInfoDeviceIndex"), (0, "HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationPortPowerInfoPortIndex"))
if mibBuilder.loadTexts: hwEasyOperationPortPowerInfoEntry.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationPortPowerInfoEntry.setDescription('The entry of port power table.')
hwEasyOperationPortPowerInfoDeviceIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 1, 2, 1, 1), Integer32())
if mibBuilder.loadTexts: hwEasyOperationPortPowerInfoDeviceIndex.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationPortPowerInfoDeviceIndex.setDescription('The index of device.')
hwEasyOperationPortPowerInfoPortIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 1, 2, 1, 2), Integer32())
if mibBuilder.loadTexts: hwEasyOperationPortPowerInfoPortIndex.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationPortPowerInfoPortIndex.setDescription('The index of port.')
hwEasyOperationPortPowerInfoPortName = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 1, 2, 1, 3), OctetString()).setMaxAccess("readonly")
if mibBuilder.loadTexts: hwEasyOperationPortPowerInfoPortName.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationPortPowerInfoPortName.setDescription('The port name.')
hwEasyOperationPortPowerInfoCurrentPower = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 1, 2, 1, 4), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: hwEasyOperationPortPowerInfoCurrentPower.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationPortPowerInfoCurrentPower.setDescription('The current power of port.')
hwEasyOperationPortPowerInfoGauge = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 1, 2, 1, 5), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2))).clone(namedValues=NamedValues(("actual", 1), ("presumed", 2)))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: hwEasyOperationPortPowerInfoGauge.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationPortPowerInfoGauge.setDescription('The gauge of port power.')
hwEasyOperationNetPowerHistoryInfoTable = MibTable((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 1, 3), )
if mibBuilder.loadTexts: hwEasyOperationNetPowerHistoryInfoTable.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationNetPowerHistoryInfoTable.setDescription('The net power history information table.')
hwEasyOperationNetPowerHistoryInfoEntry = MibTableRow((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 1, 3, 1), ).setIndexNames((0, "HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationNetPowerHistoryInfoIndex"))
if mibBuilder.loadTexts: hwEasyOperationNetPowerHistoryInfoEntry.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationNetPowerHistoryInfoEntry.setDescription('The entry of net power history table.')
hwEasyOperationNetPowerHistoryInfoIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 1, 3, 1, 1), Integer32())
if mibBuilder.loadTexts: hwEasyOperationNetPowerHistoryInfoIndex.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationNetPowerHistoryInfoIndex.setDescription('The index of the table.')
hwEasyOperationNetPowerHistoryInfoWholePower = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 1, 3, 1, 2), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: hwEasyOperationNetPowerHistoryInfoWholePower.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationNetPowerHistoryInfoWholePower.setDescription('The total power of the whole network.')
hwEasyOperationTopologyTable = MibTable((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 3), )
if mibBuilder.loadTexts: hwEasyOperationTopologyTable.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationTopologyTable.setDescription('The topology table.')
hwEasyOperationTopologyEntry = MibTableRow((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 3, 1), ).setIndexNames((0, "HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationTopologyHopIndex"), (0, "HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationTopologyDeviceIndex"))
if mibBuilder.loadTexts: hwEasyOperationTopologyEntry.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationTopologyEntry.setDescription('The entry of topology table.')
hwEasyOperationTopologyHopIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 3, 1, 1), Integer32())
if mibBuilder.loadTexts: hwEasyOperationTopologyHopIndex.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationTopologyHopIndex.setDescription('The topoloy hop.')
hwEasyOperationTopologyDeviceIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 3, 1, 2), Integer32())
if mibBuilder.loadTexts: hwEasyOperationTopologyDeviceIndex.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationTopologyDeviceIndex.setDescription('The index of topology device.')
hwEasyOperationTopologyLocalMac = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 3, 1, 3), MacAddress()).setMaxAccess("readonly")
if mibBuilder.loadTexts: hwEasyOperationTopologyLocalMac.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationTopologyLocalMac.setDescription('The mac address of local topology node.')
hwEasyOperationTopologyFatherMac = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 3, 1, 4), MacAddress()).setMaxAccess("readonly")
if mibBuilder.loadTexts: hwEasyOperationTopologyFatherMac.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationTopologyFatherMac.setDescription('The mac address of father topology node.')
hwEasyOperationTopologyLocalPortName = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 3, 1, 5), OctetString()).setMaxAccess("readonly")
if mibBuilder.loadTexts: hwEasyOperationTopologyLocalPortName.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationTopologyLocalPortName.setDescription('The port name of local topology node.')
hwEasyOperationTopologyFatherPortName = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 3, 1, 6), OctetString()).setMaxAccess("readonly")
if mibBuilder.loadTexts: hwEasyOperationTopologyFatherPortName.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationTopologyFatherPortName.setDescription('The port name of father topology node.')
hwEasyOperationTopologyLocalDeviceId = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 3, 1, 7), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: hwEasyOperationTopologyLocalDeviceId.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationTopologyLocalDeviceId.setDescription('The device id of local topology node.')
hwEasyOperationTopologyFatherDeviceId = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 3, 1, 8), Integer32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: hwEasyOperationTopologyFatherDeviceId.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationTopologyFatherDeviceId.setDescription('The device id of father topology node.')
hwEasyOperationSavedTopologyTable = MibTable((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 4), )
if mibBuilder.loadTexts: hwEasyOperationSavedTopologyTable.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationSavedTopologyTable.setDescription('The saved topology table.')
hwEasyOperationSavedTopologyEntry = MibTableRow((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 4, 1), ).setIndexNames((0, "HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationSavedTopologyHopIndex"), (0, "HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationSavedTopologyDeviceIndex"))
if mibBuilder.loadTexts: hwEasyOperationSavedTopologyEntry.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationSavedTopologyEntry.setDescription('The entry of saved topology table.')
hwEasyOperationSavedTopologyHopIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 4, 1, 1), Integer32())
if mibBuilder.loadTexts: hwEasyOperationSavedTopologyHopIndex.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationSavedTopologyHopIndex.setDescription('The index of saved topology hop.')
hwEasyOperationSavedTopologyDeviceIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 4, 1, 2), Integer32())
if mibBuilder.loadTexts: hwEasyOperationSavedTopologyDeviceIndex.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationSavedTopologyDeviceIndex.setDescription('The index of saved topology device.')
hwEasyOperationSavedTopologyLocalMac = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 4, 1, 3), MacAddress()).setMaxAccess("readonly")
if mibBuilder.loadTexts: hwEasyOperationSavedTopologyLocalMac.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationSavedTopologyLocalMac.setDescription('The mac address of saved local topology node.')
hwEasyOperationSavedTopologyFatherMac = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 4, 1, 4), MacAddress()).setMaxAccess("readonly")
if mibBuilder.loadTexts: hwEasyOperationSavedTopologyFatherMac.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationSavedTopologyFatherMac.setDescription('The mac address of saved father topology node.')
hwEasyOperationSavedTopologyLocalPortName = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 4, 1, 5), OctetString()).setMaxAccess("readonly")
if mibBuilder.loadTexts: hwEasyOperationSavedTopologyLocalPortName.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationSavedTopologyLocalPortName.setDescription('The port name of saved local topology node.')
hwEasyOperationSavedTopologyFatherPortName = MibTableColumn((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 4, 1, 6), OctetString()).setMaxAccess("readonly")
if mibBuilder.loadTexts: hwEasyOperationSavedTopologyFatherPortName.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationSavedTopologyFatherPortName.setDescription('The port name of saved father topology node.')
hwEasyOperationCompliance = ModuleCompliance((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 100)).setObjects(("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationGlobalObjectsGroup"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationGroupObjectsGroup"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationGroupTableGroup"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationGroupMatchTableGroup"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientObjectsGroup"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientInfoGroup"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationTopologyGroup"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationPortPowerInfoGroup"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationDevicePowerInfoGroup"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationNotificationGroup"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientReplaceGroup"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationSavedTopologyGroup"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationNetPowerHistoryInfoGroup"))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
hwEasyOperationCompliance = hwEasyOperationCompliance.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationCompliance.setDescription('The compliance.')
hwEasyOperationGlobalObjectsGroup = ObjectGroup((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 100, 1)).setObjects(("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationCommanderIpAddressType"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationBackupConfigMode"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationActivateInTime"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationActivateDelayTime"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationActivateMode"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationAutoClearEnable"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationServerIpAddressType"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationServerIpAddress"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationServerType"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationDefaultSysSoftwareVer"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationDefaultConfig"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationDefaultPatch"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationDefaultWebfile"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationDefaultLicense"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationDefaultCustomfile1"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationDefaultCustomfile2"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationDefaultCustomfile3"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationDefaultSysSoftware"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationBackupConfigInterval"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationCommanderUdpPort"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationServerPort"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientAgingTime"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationTopologyEnable"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationCommanderIpAddress"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationCommanderEnable"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientAutoJoinEnable"))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
hwEasyOperationGlobalObjectsGroup = hwEasyOperationGlobalObjectsGroup.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationGlobalObjectsGroup.setDescription('The global objects group.')
hwEasyOperationGroupObjectsGroup = ObjectGroup((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 100, 2)).setObjects(("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationTotalGroupNumber"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationBuildInGroupNumber"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationCustomGroupNumber"))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
hwEasyOperationGroupObjectsGroup = hwEasyOperationGroupObjectsGroup.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationGroupObjectsGroup.setDescription('The group objects group.')
hwEasyOperationGroupTableGroup = ObjectGroup((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 100, 3)).setObjects(("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationGroupType"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationGroupName"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationGroupSysSoftware"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationGroupSysSoftwareVer"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationGroupConfig"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationGroupPatch"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationGroupWebfile"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationGroupLicense"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationGroupCustomfile1"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationGroupCustomfile2"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationGroupCustomfile3"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationGroupActivateMode"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationGroupActivateDelayTime"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationGroupActivateInTime"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationGroupRowStatus"))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
hwEasyOperationGroupTableGroup = hwEasyOperationGroupTableGroup.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationGroupTableGroup.setDescription('The group table group.')
hwEasyOperationGroupMatchTableGroup = ObjectGroup((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 100, 4)).setObjects(("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationGroupMatchMacAddress"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationGroupMatchEsn"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationGroupMatchModel"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationGroupMatchDeviceType"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationGroupMatchRowStatus"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationGroupMatchMacMask"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationGroupMatchIpAddress"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationGroupMatchIpAddressType"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationGroupMatchIpAddressMask"))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
hwEasyOperationGroupMatchTableGroup = hwEasyOperationGroupMatchTableGroup.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationGroupMatchTableGroup.setDescription('The match rule table objects group.')
hwEasyOperationClientObjectsGroup = ObjectGroup((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 100, 5)).setObjects(("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientNumber"))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
hwEasyOperationClientObjectsGroup = hwEasyOperationClientObjectsGroup.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientObjectsGroup.setDescription('The client objects group.')
hwEasyOperationClientInfoGroup = ObjectGroup((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 100, 6)).setObjects(("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientInfoClientMacAddress"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientInfoClientEsn"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientInfoClientModel"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientInfoClientDeviceType"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientInfoClientSysSoftware"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientInfoClientSysSoftwareVer"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientInfoClientSysConfig"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientInfoClientSysPatch"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientInfoClientSysWebFile"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientInfoClientSysLicense"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientInfoClientDownloadSoftware"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientInfoClientDownloadSoftwareVer"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientInfoClientDownloadConfig"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientInfoClientDownloadPatch"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientInfoClientDownloadWebFile"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientInfoClientDownloadLicense"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientInfoClientDownloadCustomfile1"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientInfoClientDownloadCustomfile2"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientInfoClientDownloadCustomfile3"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientInfoClientErrorDescr"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientInfoClientIpAddress"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientInfoClientRowStatus"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientInfoClientHostName"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientInfoClientBackupErrorDescr"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientInfoClientBackupErrorReason"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientInfoClientErrorReason"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientInfoClientDownloadPercent"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientInfoClientIpAddressType"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientInfoClientMethod"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientInfoClientPhase"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientInfoClientOperateState"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientInfoClientRunState"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientInfoClientCpuUsage"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientInfoClientMemoryUsage"))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
hwEasyOperationClientInfoGroup = hwEasyOperationClientInfoGroup.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientInfoGroup.setDescription('The client table group.')
hwEasyOperationClientReplaceGroup = ObjectGroup((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 100, 7)).setObjects(("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientReplaceRowStatus"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientReplaceDownloadCustomfile3"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientReplaceDownloadCustomfile2"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientReplaceDownloadCustomfile1"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientReplaceDownloadLicense"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientReplaceDownloadWebFile"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientReplaceDownloadPatch"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientReplaceDownloadSoftwareVer"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientReplaceDownloadSoftware"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientReplaceNewEsn"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientReplaceNewMacAddress"))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
hwEasyOperationClientReplaceGroup = hwEasyOperationClientReplaceGroup.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationClientReplaceGroup.setDescription('The replace client table group.')
hwEasyOperationNotificationGroup = NotificationGroup((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 100, 8)).setObjects(("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientAdded"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationClientLost"))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
hwEasyOperationNotificationGroup = hwEasyOperationNotificationGroup.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationNotificationGroup.setDescription('The notification objects group.')
hwEasyOperationDevicePowerInfoGroup = ObjectGroup((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 100, 9)).setObjects(("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationDevicePowerInfoCurrentPower"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationDevicePowerInfoGauge"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationDevicePowerInfoRatedPower"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationDevicePowerInfoPowerManageMode"))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
hwEasyOperationDevicePowerInfoGroup = hwEasyOperationDevicePowerInfoGroup.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationDevicePowerInfoGroup.setDescription('The device power information table group.')
hwEasyOperationPortPowerInfoGroup = ObjectGroup((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 100, 10)).setObjects(("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationPortPowerInfoPortName"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationPortPowerInfoCurrentPower"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationPortPowerInfoGauge"))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
hwEasyOperationPortPowerInfoGroup = hwEasyOperationPortPowerInfoGroup.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationPortPowerInfoGroup.setDescription('The port power information table group.')
hwEasyOperationTopologyGroup = ObjectGroup((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 100, 11)).setObjects(("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationTopologyLocalMac"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationTopologyFatherMac"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationTopologyLocalPortName"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationTopologyFatherPortName"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationTopologyLocalDeviceId"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationTopologyFatherDeviceId"))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
hwEasyOperationTopologyGroup = hwEasyOperationTopologyGroup.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationTopologyGroup.setDescription('The topology table group.')
hwEasyOperationSavedTopologyGroup = ObjectGroup((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 100, 12)).setObjects(("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationSavedTopologyLocalMac"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationSavedTopologyFatherMac"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationSavedTopologyLocalPortName"), ("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationSavedTopologyFatherPortName"))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
hwEasyOperationSavedTopologyGroup = hwEasyOperationSavedTopologyGroup.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationSavedTopologyGroup.setDescription('The saved topology table group.')
hwEasyOperationNetPowerHistoryInfoGroup = ObjectGroup((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 100, 13)).setObjects(("HUAWEI-EASY-OPERATION-MIB", "hwEasyOperationNetPowerHistoryInfoWholePower"))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
hwEasyOperationNetPowerHistoryInfoGroup = hwEasyOperationNetPowerHistoryInfoGroup.setStatus('current')
if mibBuilder.loadTexts: hwEasyOperationNetPowerHistoryInfoGroup.setDescription('The power history of whole network table group.')
mibBuilder.exportSymbols("HUAWEI-EASY-OPERATION-MIB", hwEasyOperationClientInfoClientDeviceType=hwEasyOperationClientInfoClientDeviceType, hwEasyOperationGroupCustomfile1=hwEasyOperationGroupCustomfile1, hwEasyOperationGroupMatchMacMask=hwEasyOperationGroupMatchMacMask, hwEasyOperationSavedTopologyFatherMac=hwEasyOperationSavedTopologyFatherMac, hwEasyOperationTopologyFatherMac=hwEasyOperationTopologyFatherMac, hwEasyOperationDevicePowerInfoGauge=hwEasyOperationDevicePowerInfoGauge, hwEasyOperationClientReplaceDownloadSoftware=hwEasyOperationClientReplaceDownloadSoftware, hwEasyOperationClientInfoGroup=hwEasyOperationClientInfoGroup, hwEasyOperationGroupMatchIpAddress=hwEasyOperationGroupMatchIpAddress, hwEasyOperationSavedTopologyFatherPortName=hwEasyOperationSavedTopologyFatherPortName, hwEasyOperationClientInfoClientSysWebFile=hwEasyOperationClientInfoClientSysWebFile, hwEasyOperationClientInfoClientDownloadSoftwareVer=hwEasyOperationClientInfoClientDownloadSoftwareVer, hwEasyOperationCommanderIpAddressType=hwEasyOperationCommanderIpAddressType, hwEasyOperationGroupMatchIpAddressType=hwEasyOperationGroupMatchIpAddressType, PYSNMP_MODULE_ID=hwEasyOperationMIB, hwEasyOperationClientInfoClientSysConfig=hwEasyOperationClientInfoClientSysConfig, hwEasyOperationClientInfoClientDownloadWebFile=hwEasyOperationClientInfoClientDownloadWebFile, hwEasyOperationClientInfoClientMethod=hwEasyOperationClientInfoClientMethod, hwEasyOperationClientInfoClientErrorDescr=hwEasyOperationClientInfoClientErrorDescr, hwEasyOperationDefaultWebfile=hwEasyOperationDefaultWebfile, hwEasyOperationGroupEntry=hwEasyOperationGroupEntry, hwEasyOperationSavedTopologyGroup=hwEasyOperationSavedTopologyGroup, hwEasyOperationGroupSysSoftwareVer=hwEasyOperationGroupSysSoftwareVer, hwEasyOperationCommanderEnable=hwEasyOperationCommanderEnable, hwEasyOperationGroupObjectsGroup=hwEasyOperationGroupObjectsGroup, hwEasyOperationDefaultConfig=hwEasyOperationDefaultConfig, hwEasyOperationClientReplaceDownloadLicense=hwEasyOperationClientReplaceDownloadLicense, hwEasyOperationTrapVar=hwEasyOperationTrapVar, hwEasyOperationClientInfoClientDownloadConfig=hwEasyOperationClientInfoClientDownloadConfig, hwEasyOperationClientObjectsGroup=hwEasyOperationClientObjectsGroup, hwEasyOperationNetPowerHistoryInfoGroup=hwEasyOperationNetPowerHistoryInfoGroup, hwEasyOperationSavedTopologyLocalMac=hwEasyOperationSavedTopologyLocalMac, hwEasyOperationDevicePowerInfoEntry=hwEasyOperationDevicePowerInfoEntry, hwEasyOperationClientReplaceGroup=hwEasyOperationClientReplaceGroup, hwEasyOperationClientInfoClientSysSoftwareVer=hwEasyOperationClientInfoClientSysSoftwareVer, hwEasyOperationClientReplaceDownloadSoftwareVer=hwEasyOperationClientReplaceDownloadSoftwareVer, hwEasyOperationSavedTopologyLocalPortName=hwEasyOperationSavedTopologyLocalPortName, hwEasyOperationGroup=hwEasyOperationGroup, hwEasyOperationClient=hwEasyOperationClient, hwEasyOperationNetPowerHistoryInfoTable=hwEasyOperationNetPowerHistoryInfoTable, hwEasyOperationDevicePowerInfoRatedPower=hwEasyOperationDevicePowerInfoRatedPower, hwEasyOperationClientInfoClientDownloadCustomfile2=hwEasyOperationClientInfoClientDownloadCustomfile2, hwEasyOperationClientInfoClientDownloadLicense=hwEasyOperationClientInfoClientDownloadLicense, hwEasyOperationGroupType=hwEasyOperationGroupType, hwEasyOperationGroupMatchTableGroup=hwEasyOperationGroupMatchTableGroup, hwEasyOperationGroupIndex=hwEasyOperationGroupIndex, hwEasyOperationAutoClearEnable=hwEasyOperationAutoClearEnable, hwEasyOperationActivateMode=hwEasyOperationActivateMode, hwEasyOperationSavedTopologyHopIndex=hwEasyOperationSavedTopologyHopIndex, hwEasyOperationClientInfoClientSysPatch=hwEasyOperationClientInfoClientSysPatch, hwEasyOperationDefaultCustomfile3=hwEasyOperationDefaultCustomfile3, hwEasyOperationGlobalObjectsGroup=hwEasyOperationGlobalObjectsGroup, hwEasyOperationPortPowerInfoCurrentPower=hwEasyOperationPortPowerInfoCurrentPower, hwEasyOperationGroupActivateDelayTime=hwEasyOperationGroupActivateDelayTime, hwEasyOperationCompliance=hwEasyOperationCompliance, hwEasyOperationNotificationGroup=hwEasyOperationNotificationGroup, hwEasyOperationClientInfoClientCpuUsage=hwEasyOperationClientInfoClientCpuUsage, hwEasyOperationGroupTable=hwEasyOperationGroupTable, hwEasyOperationServerType=hwEasyOperationServerType, hwEasyOperationTopologyDeviceIndex=hwEasyOperationTopologyDeviceIndex, hwEasyOperationGroupMatchMacAddress=hwEasyOperationGroupMatchMacAddress, hwEasyOperationTopologyLocalDeviceId=hwEasyOperationTopologyLocalDeviceId, hwEasyOperationGroupCustomfile3=hwEasyOperationGroupCustomfile3, hwEasyOperationDefaultPatch=hwEasyOperationDefaultPatch, hwEasyOperationClientReplaceNewMacAddress=hwEasyOperationClientReplaceNewMacAddress, hwEasyOperationClientAdded=hwEasyOperationClientAdded, hwEasyOperationClientInfoClientDownloadPercent=hwEasyOperationClientInfoClientDownloadPercent, hwEasyOperationSavedTopologyEntry=hwEasyOperationSavedTopologyEntry, hwEasyOperationClientInfoClientBackupErrorDescr=hwEasyOperationClientInfoClientBackupErrorDescr, hwEasyOperationCustomGroupNumber=hwEasyOperationCustomGroupNumber, hwEasyOperationClientInfoClientMacAddress=hwEasyOperationClientInfoClientMacAddress, hwEasyOperationTopologyEnable=hwEasyOperationTopologyEnable, hwEasyOperationDevicePowerInfoTable=hwEasyOperationDevicePowerInfoTable, hwEasyOperationServerIpAddressType=hwEasyOperationServerIpAddressType, hwEasyOperationGroupRowStatus=hwEasyOperationGroupRowStatus, hwEasyOperationGroupMatchDeviceType=hwEasyOperationGroupMatchDeviceType, hwEasyOperationClientInfoClientIndex=hwEasyOperationClientInfoClientIndex, hwEasyOperationDefaultSysSoftware=hwEasyOperationDefaultSysSoftware, hwEasyOperationClientInfoClientHostName=hwEasyOperationClientInfoClientHostName, hwEasyOperationGroupLicense=hwEasyOperationGroupLicense, hwEasyOperationGlobalObjects=hwEasyOperationGlobalObjects, hwEasyOperationTopologyTable=hwEasyOperationTopologyTable, hwEasyOperationGroupActivateMode=hwEasyOperationGroupActivateMode, hwEasyOperationClientInfoClientIpAddressType=hwEasyOperationClientInfoClientIpAddressType, hwEasyOperationBackupConfigMode=hwEasyOperationBackupConfigMode, hwEasyOperationDevicePowerInfoPowerManageMode=hwEasyOperationDevicePowerInfoPowerManageMode, hwEasyOperationClientInfoClientIpAddress=hwEasyOperationClientInfoClientIpAddress, hwEasyOperationClientReplaceDownloadCustomfile3=hwEasyOperationClientReplaceDownloadCustomfile3, hwEasyOperationPortPowerInfoDeviceIndex=hwEasyOperationPortPowerInfoDeviceIndex, hwEasyOperationPortPowerInfoTable=hwEasyOperationPortPowerInfoTable, hwEasyOperationClientInfoClientPhase=hwEasyOperationClientInfoClientPhase, hwEasyOperationTopologyFatherPortName=hwEasyOperationTopologyFatherPortName, hwEasyOperationTopologyLocalPortName=hwEasyOperationTopologyLocalPortName, hwEasyOperationSavedTopologyDeviceIndex=hwEasyOperationSavedTopologyDeviceIndex, hwEasyOperationServerPort=hwEasyOperationServerPort, hwEasyOperationDevicePowerInfoCurrentPower=hwEasyOperationDevicePowerInfoCurrentPower, hwEasyOperationGroupMatchModel=hwEasyOperationGroupMatchModel, hwEasyOperationClientInfoClientRowStatus=hwEasyOperationClientInfoClientRowStatus, hwEasyOperationCommanderUdpPort=hwEasyOperationCommanderUdpPort, hwEasyOperationTotalGroupNumber=hwEasyOperationTotalGroupNumber, hwEasyOperationClientInfoClientDownloadSoftware=hwEasyOperationClientInfoClientDownloadSoftware, hwEasyOperationDevicePowerInfoIndex=hwEasyOperationDevicePowerInfoIndex, hwEasyOperationClientReplaceClientIndex=hwEasyOperationClientReplaceClientIndex, hwEasyOperationClientInfoClientDownloadPatch=hwEasyOperationClientInfoClientDownloadPatch, hwEasyOperationGroupConfig=hwEasyOperationGroupConfig, hwEasyOperationPowerInfo=hwEasyOperationPowerInfo, hwEasyOperationGroupActivateInTime=hwEasyOperationGroupActivateInTime, hwEasyOperationMonitor=hwEasyOperationMonitor, hwEasyOperationClientAutoJoinEnable=hwEasyOperationClientAutoJoinEnable, hwEasyOperationNotification=hwEasyOperationNotification, hwEasyOperationClientReplaceEntry=hwEasyOperationClientReplaceEntry, hwEasyOperationTopologyHopIndex=hwEasyOperationTopologyHopIndex, hwEasyOperationClientInfoClientEsn=hwEasyOperationClientInfoClientEsn, hwEasyOperationClientInfoClientMemoryUsage=hwEasyOperationClientInfoClientMemoryUsage, hwEasyOperationBuildInGroupNumber=hwEasyOperationBuildInGroupNumber, hwEasyOperationClientInfoEntry=hwEasyOperationClientInfoEntry, hwEasyOperationNetPowerHistoryInfoIndex=hwEasyOperationNetPowerHistoryInfoIndex, hwEasyOperationClientJoinNotPermit=hwEasyOperationClientJoinNotPermit, hwEasyOperationGroupMatchRowStatus=hwEasyOperationGroupMatchRowStatus, hwEasyOperationTrap=hwEasyOperationTrap, hwEasyOperationNetPowerHistoryInfoEntry=hwEasyOperationNetPowerHistoryInfoEntry, hwEasyOperationTopologyFatherDeviceId=hwEasyOperationTopologyFatherDeviceId, hwEasyOperationGroupPatch=hwEasyOperationGroupPatch, hwEasyOperationDefaultCustomfile1=hwEasyOperationDefaultCustomfile1, hwEasyOperationDefaultLicense=hwEasyOperationDefaultLicense, hwEasyOperationGroupCustomfile2=hwEasyOperationGroupCustomfile2, hwEasyOperationNetPowerHistoryInfoWholePower=hwEasyOperationNetPowerHistoryInfoWholePower, hwEasyOperationClientReplaceDownloadCustomfile2=hwEasyOperationClientReplaceDownloadCustomfile2, hwEasyOperationGroupMatchIndex=hwEasyOperationGroupMatchIndex, hwEasyOperationClientAgingTime=hwEasyOperationClientAgingTime, hwEasyOperationClientReplaceDownloadPatch=hwEasyOperationClientReplaceDownloadPatch, hwEasyOperationServerIpAddress=hwEasyOperationServerIpAddress, hwEasyOperationClientLost=hwEasyOperationClientLost, hwEasyOperationClientReplaceRowStatus=hwEasyOperationClientReplaceRowStatus, hwEasyOperationDevicePowerInfoGroup=hwEasyOperationDevicePowerInfoGroup, hwEasyOperationClientInfoClientDownloadCustomfile1=hwEasyOperationClientInfoClientDownloadCustomfile1, hwEasyOperationCommanderIpAddress=hwEasyOperationCommanderIpAddress, hwEasyOperationTopologyGroup=hwEasyOperationTopologyGroup, hwEasyOperationClientInfoClientBackupErrorReason=hwEasyOperationClientInfoClientBackupErrorReason, hwEasyOperationClientReplaceNewEsn=hwEasyOperationClientReplaceNewEsn, hwEasyOperationActivateDelayTime=hwEasyOperationActivateDelayTime, hwEasyOperationPortPowerInfoPortName=hwEasyOperationPortPowerInfoPortName, hwEasyOperationActivateInTime=hwEasyOperationActivateInTime, hwEasyOperationMIB=hwEasyOperationMIB, hwEasyOperationClientInfoClientOperateState=hwEasyOperationClientInfoClientOperateState, hwEasyOperationClientReplaceDownloadWebFile=hwEasyOperationClientReplaceDownloadWebFile, hwEasyOperationGroupMatchIpAddressMask=hwEasyOperationGroupMatchIpAddressMask, hwEasyOperationGroupWebfile=hwEasyOperationGroupWebfile, hwEasyOperationPortPowerInfoPortIndex=hwEasyOperationPortPowerInfoPortIndex, hwEasyOperationClientInfoClientSysLicense=hwEasyOperationClientInfoClientSysLicense, hwEasyOperationGroupSysSoftware=hwEasyOperationGroupSysSoftware, hwEasyOperationClientInfoClientModel=hwEasyOperationClientInfoClientModel, hwEasyOperationGroupMatchTable=hwEasyOperationGroupMatchTable, hwEasyOperationGroupMatchEntry=hwEasyOperationGroupMatchEntry, hwEasyOperationGroupMatchEsn=hwEasyOperationGroupMatchEsn, hwEasyOperationTopologyLocalMac=hwEasyOperationTopologyLocalMac, hwEasyOperationGroupName=hwEasyOperationGroupName, hwEasyOperationBackupConfigInterval=hwEasyOperationBackupConfigInterval, hwEasyOperationPortPowerInfoEntry=hwEasyOperationPortPowerInfoEntry, hwEasyOperationDefaultCustomfile2=hwEasyOperationDefaultCustomfile2, hwEasyOperationClientInfoClientSysSoftware=hwEasyOperationClientInfoClientSysSoftware, hwEasyOperationClientInfoClientDownloadCustomfile3=hwEasyOperationClientInfoClientDownloadCustomfile3, hwEasyOperationClientInfoClientRunState=hwEasyOperationClientInfoClientRunState, hwEasyOperationClientInfoClientErrorReason=hwEasyOperationClientInfoClientErrorReason, hwEasyOperationClientReplaceDownloadCustomfile1=hwEasyOperationClientReplaceDownloadCustomfile1, hwEasyOperationSavedTopologyTable=hwEasyOperationSavedTopologyTable, hwEasyOperationGroupTableGroup=hwEasyOperationGroupTableGroup, hwEasyOperationClientReplaceTable=hwEasyOperationClientReplaceTable, hwEasyOperationTopologyEntry=hwEasyOperationTopologyEntry, hwEasyOperationPortPowerInfoGauge=hwEasyOperationPortPowerInfoGauge, hwEasyOperationDefaultSysSoftwareVer=hwEasyOperationDefaultSysSoftwareVer, hwEasyOperationClientInfoTable=hwEasyOperationClientInfoTable, hwEasyOperationClientNumber=hwEasyOperationClientNumber, hwEasyOperationPortPowerInfoGroup=hwEasyOperationPortPowerInfoGroup)
| (octet_string, object_identifier, integer) = mibBuilder.importSymbols('ASN1', 'OctetString', 'ObjectIdentifier', 'Integer')
(named_values,) = mibBuilder.importSymbols('ASN1-ENUMERATION', 'NamedValues')
(single_value_constraint, value_size_constraint, constraints_union, value_range_constraint, constraints_intersection) = mibBuilder.importSymbols('ASN1-REFINEMENT', 'SingleValueConstraint', 'ValueSizeConstraint', 'ConstraintsUnion', 'ValueRangeConstraint', 'ConstraintsIntersection')
(hw_datacomm,) = mibBuilder.importSymbols('HUAWEI-MIB', 'hwDatacomm')
(inet_address, inet_address_type) = mibBuilder.importSymbols('INET-ADDRESS-MIB', 'InetAddress', 'InetAddressType')
(enabled_status,) = mibBuilder.importSymbols('P-BRIDGE-MIB', 'EnabledStatus')
(notification_group, object_group, module_compliance) = mibBuilder.importSymbols('SNMPv2-CONF', 'NotificationGroup', 'ObjectGroup', 'ModuleCompliance')
(mib_scalar, mib_table, mib_table_row, mib_table_column, iso, integer32, unsigned32, ip_address, counter64, bits, notification_type, counter32, gauge32, object_identity, time_ticks, module_identity, mib_identifier) = mibBuilder.importSymbols('SNMPv2-SMI', 'MibScalar', 'MibTable', 'MibTableRow', 'MibTableColumn', 'iso', 'Integer32', 'Unsigned32', 'IpAddress', 'Counter64', 'Bits', 'NotificationType', 'Counter32', 'Gauge32', 'ObjectIdentity', 'TimeTicks', 'ModuleIdentity', 'MibIdentifier')
(mac_address, display_string, row_status, textual_convention) = mibBuilder.importSymbols('SNMPv2-TC', 'MacAddress', 'DisplayString', 'RowStatus', 'TextualConvention')
hw_easy_operation_mib = module_identity((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311))
hwEasyOperationMIB.setRevisions(('2014-09-09 00:00', '2014-06-04 00:00', '2013-12-30 00:00', '2013-08-05 00:00', '2013-03-18 00:00'))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
if mibBuilder.loadTexts:
hwEasyOperationMIB.setRevisionsDescriptions(('Revisions made by HUAWEI.', 'Revisions made by HUAWEI.', 'Revisions made by HUAWEI.', 'Revisions made by HUAWEI.', 'Revisions made by HUAWEI.'))
if mibBuilder.loadTexts:
hwEasyOperationMIB.setLastUpdated('201409090000Z')
if mibBuilder.loadTexts:
hwEasyOperationMIB.setOrganization('Huawei Technologies Co.,Ltd.')
if mibBuilder.loadTexts:
hwEasyOperationMIB.setContactInfo("Huawei Industrial Base Bantian, Longgang Shenzhen 518129 People's Republic of China Website: http://www.huawei.com Email: support@huawei.com ")
if mibBuilder.loadTexts:
hwEasyOperationMIB.setDescription('Huawei Easy Opearation MIB.')
hw_easy_operation_global_objects = mib_identifier((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 1))
hw_easy_operation_commander_enable = mib_scalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 1, 1), enabled_status()).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
hwEasyOperationCommanderEnable.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationCommanderEnable.setDescription('This object specifies the Easy Operation Commander operation mode.')
hw_easy_operation_commander_ip_address = mib_scalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 1, 2), inet_address()).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
hwEasyOperationCommanderIpAddress.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationCommanderIpAddress.setDescription('The IP address of commander.')
hw_easy_operation_commander_ip_address_type = mib_scalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 1, 3), inet_address_type()).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
hwEasyOperationCommanderIpAddressType.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationCommanderIpAddressType.setDescription('The IP address type of commander.')
hw_easy_operation_commander_udp_port = mib_scalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 1, 4), integer32()).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
hwEasyOperationCommanderUdpPort.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationCommanderUdpPort.setDescription('The UDP port of commander.')
hw_easy_operation_server_type = mib_scalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 1, 5), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2, 3))).clone(namedValues=named_values(('tftp', 1), ('ftp', 2), ('sftp', 3)))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
hwEasyOperationServerType.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationServerType.setDescription('The type of file server.')
hw_easy_operation_server_ip_address = mib_scalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 1, 6), inet_address()).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
hwEasyOperationServerIpAddress.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationServerIpAddress.setDescription('The IP address of file server.')
hw_easy_operation_server_ip_address_type = mib_scalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 1, 7), inet_address_type()).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
hwEasyOperationServerIpAddressType.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationServerIpAddressType.setDescription('The IP address type of file server.')
hw_easy_operation_server_port = mib_scalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 1, 8), integer32()).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
hwEasyOperationServerPort.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationServerPort.setDescription('The port number of file server.')
hw_easy_operation_auto_clear_enable = mib_scalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 1, 9), enabled_status()).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
hwEasyOperationAutoClearEnable.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationAutoClearEnable.setDescription('Whether client would clear the old software file when the free space is not enough.')
hw_easy_operation_activate_mode = mib_scalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 1, 10), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2))).clone(namedValues=named_values(('default', 1), ('reload', 2)))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
hwEasyOperationActivateMode.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationActivateMode.setDescription('The mode of activating file.')
hw_easy_operation_activate_delay_time = mib_scalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 1, 11), integer32()).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
hwEasyOperationActivateDelayTime.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationActivateDelayTime.setDescription('The delay time of activating file.The unit is second(s).')
hw_easy_operation_activate_in_time = mib_scalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 1, 12), display_string()).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
hwEasyOperationActivateInTime.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationActivateInTime.setDescription('The specific time of activating file.')
hw_easy_operation_backup_config_mode = mib_scalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 1, 13), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2))).clone(namedValues=named_values(('overwrite', 1), ('duplicate', 2)))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
hwEasyOperationBackupConfigMode.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationBackupConfigMode.setDescription('The mode of file created on the server.')
hw_easy_operation_backup_config_interval = mib_scalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 1, 14), integer32()).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
hwEasyOperationBackupConfigInterval.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationBackupConfigInterval.setDescription('The interval of configuration backup .The unit is hour(s)')
hw_easy_operation_default_sys_software = mib_scalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 1, 15), display_string()).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
hwEasyOperationDefaultSysSoftware.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationDefaultSysSoftware.setDescription('The default name of software file.')
hw_easy_operation_default_sys_software_ver = mib_scalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 1, 16), display_string()).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
hwEasyOperationDefaultSysSoftwareVer.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationDefaultSysSoftwareVer.setDescription('The version of default software file.')
hw_easy_operation_default_config = mib_scalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 1, 17), display_string()).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
hwEasyOperationDefaultConfig.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationDefaultConfig.setDescription('The default name of configuration file.')
hw_easy_operation_default_patch = mib_scalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 1, 18), display_string()).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
hwEasyOperationDefaultPatch.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationDefaultPatch.setDescription('The default name of patch file.')
hw_easy_operation_default_webfile = mib_scalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 1, 19), display_string()).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
hwEasyOperationDefaultWebfile.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationDefaultWebfile.setDescription('The default name of WEB file.')
hw_easy_operation_default_license = mib_scalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 1, 20), display_string()).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
hwEasyOperationDefaultLicense.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationDefaultLicense.setDescription('The default name of license file.')
hw_easy_operation_default_customfile1 = mib_scalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 1, 21), display_string()).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
hwEasyOperationDefaultCustomfile1.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationDefaultCustomfile1.setDescription('The default name of custom file.')
hw_easy_operation_default_customfile2 = mib_scalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 1, 22), display_string()).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
hwEasyOperationDefaultCustomfile2.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationDefaultCustomfile2.setDescription('The default name of custom file.')
hw_easy_operation_default_customfile3 = mib_scalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 1, 23), display_string()).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
hwEasyOperationDefaultCustomfile3.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationDefaultCustomfile3.setDescription('The default name of custom file.')
hw_easy_operation_client_auto_join_enable = mib_scalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 1, 24), enabled_status()).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
hwEasyOperationClientAutoJoinEnable.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientAutoJoinEnable.setDescription('Whether commander can receive the information of new clients.')
hw_easy_operation_topology_enable = mib_scalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 1, 25), enabled_status()).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
hwEasyOperationTopologyEnable.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationTopologyEnable.setDescription('Whether commander can collect the topology information of new clients.')
hw_easy_operation_client_aging_time = mib_scalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 1, 26), integer32()).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
hwEasyOperationClientAgingTime.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientAgingTime.setDescription('The aging time of client which is lost. The unit is hour(s).')
hw_easy_operation_group = mib_identifier((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2))
hw_easy_operation_total_group_number = mib_scalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 1), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
hwEasyOperationTotalGroupNumber.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationTotalGroupNumber.setDescription('The total number of group.')
hw_easy_operation_build_in_group_number = mib_scalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 2), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
hwEasyOperationBuildInGroupNumber.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationBuildInGroupNumber.setDescription('The number of build-in group.')
hw_easy_operation_custom_group_number = mib_scalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 3), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
hwEasyOperationCustomGroupNumber.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationCustomGroupNumber.setDescription('The number of custom group.')
hw_easy_operation_group_table = mib_table((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 4))
if mibBuilder.loadTexts:
hwEasyOperationGroupTable.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationGroupTable.setDescription('Group table.')
hw_easy_operation_group_entry = mib_table_row((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 4, 1)).setIndexNames((0, 'HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationGroupIndex'))
if mibBuilder.loadTexts:
hwEasyOperationGroupEntry.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationGroupEntry.setDescription('The entry of group table.')
hw_easy_operation_group_index = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 4, 1, 1), integer32().subtype(subtypeSpec=value_range_constraint(1, 4096)))
if mibBuilder.loadTexts:
hwEasyOperationGroupIndex.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationGroupIndex.setDescription('The index of group table.')
hw_easy_operation_group_type = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 4, 1, 2), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2, 3, 4, 5, 6))).clone(namedValues=named_values(('buildIn', 1), ('macAddress', 2), ('esn', 3), ('model', 4), ('deviceType', 5), ('ipAddress', 6)))).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
hwEasyOperationGroupType.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationGroupType.setDescription('The type of group.')
hw_easy_operation_group_name = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 4, 1, 3), display_string()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
hwEasyOperationGroupName.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationGroupName.setDescription('The name of group.')
hw_easy_operation_group_sys_software = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 4, 1, 4), display_string()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
hwEasyOperationGroupSysSoftware.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationGroupSysSoftware.setDescription('The software file name of group.')
hw_easy_operation_group_sys_software_ver = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 4, 1, 5), display_string()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
hwEasyOperationGroupSysSoftwareVer.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationGroupSysSoftwareVer.setDescription('The software version of group.')
hw_easy_operation_group_config = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 4, 1, 6), display_string()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
hwEasyOperationGroupConfig.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationGroupConfig.setDescription('The configuration file name of group.')
hw_easy_operation_group_patch = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 4, 1, 7), display_string()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
hwEasyOperationGroupPatch.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationGroupPatch.setDescription('The patch file name of group.')
hw_easy_operation_group_webfile = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 4, 1, 8), display_string()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
hwEasyOperationGroupWebfile.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationGroupWebfile.setDescription('The WEB file name of group.')
hw_easy_operation_group_license = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 4, 1, 9), display_string()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
hwEasyOperationGroupLicense.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationGroupLicense.setDescription('The license file name of group.')
hw_easy_operation_group_customfile1 = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 4, 1, 10), display_string()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
hwEasyOperationGroupCustomfile1.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationGroupCustomfile1.setDescription('The custom file name of group.')
hw_easy_operation_group_customfile2 = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 4, 1, 11), display_string()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
hwEasyOperationGroupCustomfile2.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationGroupCustomfile2.setDescription('The custom file name of group.')
hw_easy_operation_group_customfile3 = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 4, 1, 12), display_string()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
hwEasyOperationGroupCustomfile3.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationGroupCustomfile3.setDescription('The custom file name of group.')
hw_easy_operation_group_activate_mode = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 4, 1, 13), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2))).clone(namedValues=named_values(('default', 1), ('reload', 2)))).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
hwEasyOperationGroupActivateMode.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationGroupActivateMode.setDescription('The mode of activating file of group.')
hw_easy_operation_group_activate_delay_time = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 4, 1, 14), integer32()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
hwEasyOperationGroupActivateDelayTime.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationGroupActivateDelayTime.setDescription('The delay time of activating file of group.The unit is second(s)')
hw_easy_operation_group_activate_in_time = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 4, 1, 15), display_string()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
hwEasyOperationGroupActivateInTime.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationGroupActivateInTime.setDescription('The specific time of activating file of group.')
hw_easy_operation_group_row_status = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 4, 1, 50), row_status()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
hwEasyOperationGroupRowStatus.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationGroupRowStatus.setDescription('The RowStatus of group table.')
hw_easy_operation_group_match_table = mib_table((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 5))
if mibBuilder.loadTexts:
hwEasyOperationGroupMatchTable.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationGroupMatchTable.setDescription('The match rule of group.')
hw_easy_operation_group_match_entry = mib_table_row((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 5, 1)).setIndexNames((0, 'HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationGroupIndex'), (0, 'HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationGroupMatchIndex'))
if mibBuilder.loadTexts:
hwEasyOperationGroupMatchEntry.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationGroupMatchEntry.setDescription('The entry of match rule of group.')
hw_easy_operation_group_match_index = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 5, 1, 1), integer32().subtype(subtypeSpec=value_range_constraint(1, 4096)))
if mibBuilder.loadTexts:
hwEasyOperationGroupMatchIndex.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationGroupMatchIndex.setDescription('The index of match rule table.')
hw_easy_operation_group_match_mac_address = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 5, 1, 2), mac_address()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
hwEasyOperationGroupMatchMacAddress.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationGroupMatchMacAddress.setDescription('The match rule of MAC address.')
hw_easy_operation_group_match_mac_mask = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 5, 1, 3), integer32()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
hwEasyOperationGroupMatchMacMask.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationGroupMatchMacMask.setDescription('The match rule of mask of MAC address.')
hw_easy_operation_group_match_esn = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 5, 1, 4), display_string()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
hwEasyOperationGroupMatchEsn.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationGroupMatchEsn.setDescription('The match rule of ESN.')
hw_easy_operation_group_match_model = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 5, 1, 5), display_string()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
hwEasyOperationGroupMatchModel.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationGroupMatchModel.setDescription('The match rule of model of device.')
hw_easy_operation_group_match_device_type = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 5, 1, 6), display_string()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
hwEasyOperationGroupMatchDeviceType.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationGroupMatchDeviceType.setDescription('The match rule of type of device.')
hw_easy_operation_group_match_ip_address = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 5, 1, 7), inet_address()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
hwEasyOperationGroupMatchIpAddress.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationGroupMatchIpAddress.setDescription('The match rule of IP address.')
hw_easy_operation_group_match_ip_address_type = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 5, 1, 8), inet_address_type()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
hwEasyOperationGroupMatchIpAddressType.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationGroupMatchIpAddressType.setDescription('The match rule of type of IP address.')
hw_easy_operation_group_match_ip_address_mask = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 5, 1, 9), integer32()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
hwEasyOperationGroupMatchIpAddressMask.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationGroupMatchIpAddressMask.setDescription('The match rule of mask of IP address.')
hw_easy_operation_group_match_row_status = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 2, 5, 1, 50), row_status()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
hwEasyOperationGroupMatchRowStatus.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationGroupMatchRowStatus.setDescription('The RowStatus of match rule table.')
hw_easy_operation_client = mib_identifier((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5))
hw_easy_operation_client_number = mib_scalar((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 1), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
hwEasyOperationClientNumber.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientNumber.setDescription('The number of client.')
hw_easy_operation_client_info_table = mib_table((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2))
if mibBuilder.loadTexts:
hwEasyOperationClientInfoTable.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoTable.setDescription('The client table.')
hw_easy_operation_client_info_entry = mib_table_row((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1)).setIndexNames((0, 'HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientInfoClientIndex'))
if mibBuilder.loadTexts:
hwEasyOperationClientInfoEntry.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoEntry.setDescription('The entry of client table.')
hw_easy_operation_client_info_client_index = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 1), integer32().subtype(subtypeSpec=value_range_constraint(1, 4096)))
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientIndex.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientIndex.setDescription('The index of client table.')
hw_easy_operation_client_info_client_mac_address = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 2), mac_address()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientMacAddress.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientMacAddress.setDescription('The MAC address of client.')
hw_easy_operation_client_info_client_esn = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 3), display_string()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientEsn.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientEsn.setDescription('The ESN of client.')
hw_easy_operation_client_info_client_host_name = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 4), display_string()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientHostName.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientHostName.setDescription('The host name of client.')
hw_easy_operation_client_info_client_ip_address = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 5), inet_address()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientIpAddress.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientIpAddress.setDescription('The IP address of client.')
hw_easy_operation_client_info_client_ip_address_type = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 6), inet_address_type()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientIpAddressType.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientIpAddressType.setDescription('The IP address type of client.')
hw_easy_operation_client_info_client_model = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 7), display_string()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientModel.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientModel.setDescription('The model of client.')
hw_easy_operation_client_info_client_device_type = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 8), display_string()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientDeviceType.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientDeviceType.setDescription('The device type of client.')
hw_easy_operation_client_info_client_sys_software = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 9), display_string()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientSysSoftware.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientSysSoftware.setDescription('The startup software file name of client.')
hw_easy_operation_client_info_client_sys_software_ver = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 10), display_string()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientSysSoftwareVer.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientSysSoftwareVer.setDescription('The startup software version of client.')
hw_easy_operation_client_info_client_sys_config = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 11), display_string()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientSysConfig.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientSysConfig.setDescription('The startup configuration file name of client.')
hw_easy_operation_client_info_client_sys_patch = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 12), display_string()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientSysPatch.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientSysPatch.setDescription('The startup patch file name of client.')
hw_easy_operation_client_info_client_sys_web_file = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 13), display_string()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientSysWebFile.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientSysWebFile.setDescription('The startup WEB file name of client.')
hw_easy_operation_client_info_client_sys_license = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 14), display_string()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientSysLicense.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientSysLicense.setDescription('The startup license file name of client.')
hw_easy_operation_client_info_client_download_software = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 15), display_string()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientDownloadSoftware.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientDownloadSoftware.setDescription('The software file name of client in downloading status.')
hw_easy_operation_client_info_client_download_software_ver = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 16), display_string()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientDownloadSoftwareVer.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientDownloadSoftwareVer.setDescription('The software version of client in downloading status.')
hw_easy_operation_client_info_client_download_config = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 17), display_string()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientDownloadConfig.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientDownloadConfig.setDescription('The configuration file name of client in downloading status.')
hw_easy_operation_client_info_client_download_patch = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 18), display_string()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientDownloadPatch.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientDownloadPatch.setDescription('The patch file name of client in downloading status.')
hw_easy_operation_client_info_client_download_web_file = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 19), display_string()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientDownloadWebFile.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientDownloadWebFile.setDescription('The WEB file name of client in downloading status.')
hw_easy_operation_client_info_client_download_license = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 20), display_string()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientDownloadLicense.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientDownloadLicense.setDescription('The license file name of client in downloading status.')
hw_easy_operation_client_info_client_download_customfile1 = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 21), display_string()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientDownloadCustomfile1.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientDownloadCustomfile1.setDescription('The custom file name of client in downloading status.')
hw_easy_operation_client_info_client_download_customfile2 = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 22), display_string()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientDownloadCustomfile2.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientDownloadCustomfile2.setDescription('The custom file name of client in downloading status.')
hw_easy_operation_client_info_client_download_customfile3 = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 23), display_string()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientDownloadCustomfile3.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientDownloadCustomfile3.setDescription('The custom file name of client in downloading status.')
hw_easy_operation_client_info_client_method = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 24), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2, 3, 4, 255))).clone(namedValues=named_values(('running', 1), ('upgrade', 2), ('zeroTouch', 3), ('usbDownload', 4), ('unknown', 255)))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientMethod.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientMethod.setDescription('The method of upgrading.')
hw_easy_operation_client_info_client_phase = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 25), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2, 3, 4, 5, 6, 255))).clone(namedValues=named_values(('initial', 1), ('requestIp', 2), ('getDownloadInfo', 3), ('downloadFile', 4), ('activateFile', 5), ('normalRunning', 6), ('unknown', 255)))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientPhase.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientPhase.setDescription('The downloading phase of client.')
hw_easy_operation_client_info_client_operate_state = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 26), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2, 3, 4, 5, 6, 7, 8, 9, 255))).clone(namedValues=named_values(('finished', 1), ('downloadSoftware', 2), ('downloadConfig', 3), ('downloadPatch', 4), ('downloadWebFile', 5), ('downloadLicense', 6), ('downloadCustomFile1', 7), ('downloadCustomFile2', 8), ('downloadCustomFile3', 9), ('unknown', 255)))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientOperateState.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientOperateState.setDescription('The file type in downloading.')
hw_easy_operation_client_info_client_download_percent = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 27), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientDownloadPercent.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientDownloadPercent.setDescription('The percentage of file downloading.')
hw_easy_operation_client_info_client_error_reason = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 28), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientErrorReason.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientErrorReason.setDescription('The error reason in processing.')
hw_easy_operation_client_info_client_error_descr = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 29), display_string()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientErrorDescr.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientErrorDescr.setDescription('The error description in processing.')
hw_easy_operation_client_info_client_backup_error_reason = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 30), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientBackupErrorReason.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientBackupErrorReason.setDescription('The error reason in backup configuration.')
hw_easy_operation_client_info_client_backup_error_descr = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 31), display_string()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientBackupErrorDescr.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientBackupErrorDescr.setDescription('The error description in backup configuration.')
hw_easy_operation_client_info_client_run_state = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 32), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2, 3, 4, 5, 255))).clone(namedValues=named_values(('initial', 1), ('normalRunning', 2), ('upgrading', 3), ('lost', 4), ('configuring', 5), ('unknown', 255)))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientRunState.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientRunState.setDescription('The running state of client.')
hw_easy_operation_client_info_client_cpu_usage = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 33), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientCpuUsage.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientCpuUsage.setDescription('The cpu usage of client.')
hw_easy_operation_client_info_client_memory_usage = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 34), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientMemoryUsage.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientMemoryUsage.setDescription('The memory usage of client.')
hw_easy_operation_client_info_client_row_status = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 2, 1, 100), row_status()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientRowStatus.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoClientRowStatus.setDescription('The RowStatus of client table.')
hw_easy_operation_client_replace_table = mib_table((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 3))
if mibBuilder.loadTexts:
hwEasyOperationClientReplaceTable.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientReplaceTable.setDescription('The replace client table.')
hw_easy_operation_client_replace_entry = mib_table_row((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 3, 1)).setIndexNames((0, 'HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientReplaceClientIndex'))
if mibBuilder.loadTexts:
hwEasyOperationClientReplaceEntry.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientReplaceEntry.setDescription('The entry of replace client table.')
hw_easy_operation_client_replace_client_index = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 3, 1, 1), integer32().subtype(subtypeSpec=value_range_constraint(1, 4096)))
if mibBuilder.loadTexts:
hwEasyOperationClientReplaceClientIndex.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientReplaceClientIndex.setDescription('The index of replace client table.')
hw_easy_operation_client_replace_new_mac_address = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 3, 1, 2), mac_address()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
hwEasyOperationClientReplaceNewMacAddress.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientReplaceNewMacAddress.setDescription('The MAC address of new device.')
hw_easy_operation_client_replace_new_esn = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 3, 1, 3), display_string()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
hwEasyOperationClientReplaceNewEsn.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientReplaceNewEsn.setDescription('The ESN of new device.')
hw_easy_operation_client_replace_download_software = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 3, 1, 4), display_string()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
hwEasyOperationClientReplaceDownloadSoftware.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientReplaceDownloadSoftware.setDescription('The software file name needs to be downloaded.')
hw_easy_operation_client_replace_download_software_ver = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 3, 1, 5), display_string()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
hwEasyOperationClientReplaceDownloadSoftwareVer.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientReplaceDownloadSoftwareVer.setDescription('The software version needs to be downloaded.')
hw_easy_operation_client_replace_download_patch = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 3, 1, 6), display_string()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
hwEasyOperationClientReplaceDownloadPatch.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientReplaceDownloadPatch.setDescription('The patch file name needs to be downloaded.')
hw_easy_operation_client_replace_download_web_file = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 3, 1, 7), display_string()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
hwEasyOperationClientReplaceDownloadWebFile.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientReplaceDownloadWebFile.setDescription('The WEB file name needs to be downloaded.')
hw_easy_operation_client_replace_download_license = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 3, 1, 8), display_string()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
hwEasyOperationClientReplaceDownloadLicense.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientReplaceDownloadLicense.setDescription('The license file name needs to be downloaded.')
hw_easy_operation_client_replace_download_customfile1 = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 3, 1, 9), display_string()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
hwEasyOperationClientReplaceDownloadCustomfile1.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientReplaceDownloadCustomfile1.setDescription('The custom file name needs to be downloaded.')
hw_easy_operation_client_replace_download_customfile2 = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 3, 1, 10), display_string()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
hwEasyOperationClientReplaceDownloadCustomfile2.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientReplaceDownloadCustomfile2.setDescription('The custom file name needs to be downloaded.')
hw_easy_operation_client_replace_download_customfile3 = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 3, 1, 11), display_string()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
hwEasyOperationClientReplaceDownloadCustomfile3.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientReplaceDownloadCustomfile3.setDescription('The custom file name needs to be downloaded.')
hw_easy_operation_client_replace_row_status = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 5, 3, 1, 50), row_status()).setMaxAccess('readcreate')
if mibBuilder.loadTexts:
hwEasyOperationClientReplaceRowStatus.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientReplaceRowStatus.setDescription('The RowStatus of table.')
hw_easy_operation_notification = mib_identifier((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 6))
hw_easy_operation_trap_var = mib_identifier((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 6, 1))
hw_easy_operation_trap = mib_identifier((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 6, 2))
hw_easy_operation_client_added = notification_type((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 6, 2, 1)).setObjects(('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientInfoClientHostName'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientInfoClientIpAddress'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientInfoClientMacAddress'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientInfoClientEsn'))
if mibBuilder.loadTexts:
hwEasyOperationClientAdded.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientAdded.setDescription('The notification of client added.')
hw_easy_operation_client_lost = notification_type((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 6, 2, 2)).setObjects(('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientInfoClientHostName'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientInfoClientIpAddress'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientInfoClientMacAddress'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientInfoClientEsn'))
if mibBuilder.loadTexts:
hwEasyOperationClientLost.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientLost.setDescription('The notification of client lost.')
hw_easy_operation_client_join_not_permit = notification_type((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 6, 2, 3)).setObjects(('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientInfoClientHostName'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientInfoClientIpAddress'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientInfoClientMacAddress'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientInfoClientEsn'))
if mibBuilder.loadTexts:
hwEasyOperationClientJoinNotPermit.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientJoinNotPermit.setDescription('The notification of not permit client to join.')
hw_easy_operation_monitor = mib_identifier((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7))
hw_easy_operation_power_info = mib_identifier((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 1))
hw_easy_operation_device_power_info_table = mib_table((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 1, 1))
if mibBuilder.loadTexts:
hwEasyOperationDevicePowerInfoTable.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationDevicePowerInfoTable.setDescription('The device power information table.')
hw_easy_operation_device_power_info_entry = mib_table_row((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 1, 1, 1)).setIndexNames((0, 'HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationDevicePowerInfoIndex'))
if mibBuilder.loadTexts:
hwEasyOperationDevicePowerInfoEntry.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationDevicePowerInfoEntry.setDescription('The entry of device power infomation table.')
hw_easy_operation_device_power_info_index = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 1, 1, 1, 1), integer32())
if mibBuilder.loadTexts:
hwEasyOperationDevicePowerInfoIndex.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationDevicePowerInfoIndex.setDescription('The index of device power table.')
hw_easy_operation_device_power_info_current_power = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 1, 1, 1, 2), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
hwEasyOperationDevicePowerInfoCurrentPower.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationDevicePowerInfoCurrentPower.setDescription('The current power of device.')
hw_easy_operation_device_power_info_gauge = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 1, 1, 1, 3), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2))).clone(namedValues=named_values(('actual', 1), ('rated', 2)))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
hwEasyOperationDevicePowerInfoGauge.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationDevicePowerInfoGauge.setDescription('The gauge of device power.')
hw_easy_operation_device_power_info_rated_power = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 1, 1, 1, 4), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
hwEasyOperationDevicePowerInfoRatedPower.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationDevicePowerInfoRatedPower.setDescription('The rated power of device.')
hw_easy_operation_device_power_info_power_manage_mode = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 1, 1, 1, 5), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2, 3, 4))).clone(namedValues=named_values(('userDefined', 1), ('standard', 2), ('basic', 3), ('deep', 4)))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
hwEasyOperationDevicePowerInfoPowerManageMode.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationDevicePowerInfoPowerManageMode.setDescription('The power manage mode of device.')
hw_easy_operation_port_power_info_table = mib_table((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 1, 2))
if mibBuilder.loadTexts:
hwEasyOperationPortPowerInfoTable.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationPortPowerInfoTable.setDescription('The port power information table.')
hw_easy_operation_port_power_info_entry = mib_table_row((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 1, 2, 1)).setIndexNames((0, 'HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationPortPowerInfoDeviceIndex'), (0, 'HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationPortPowerInfoPortIndex'))
if mibBuilder.loadTexts:
hwEasyOperationPortPowerInfoEntry.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationPortPowerInfoEntry.setDescription('The entry of port power table.')
hw_easy_operation_port_power_info_device_index = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 1, 2, 1, 1), integer32())
if mibBuilder.loadTexts:
hwEasyOperationPortPowerInfoDeviceIndex.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationPortPowerInfoDeviceIndex.setDescription('The index of device.')
hw_easy_operation_port_power_info_port_index = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 1, 2, 1, 2), integer32())
if mibBuilder.loadTexts:
hwEasyOperationPortPowerInfoPortIndex.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationPortPowerInfoPortIndex.setDescription('The index of port.')
hw_easy_operation_port_power_info_port_name = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 1, 2, 1, 3), octet_string()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
hwEasyOperationPortPowerInfoPortName.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationPortPowerInfoPortName.setDescription('The port name.')
hw_easy_operation_port_power_info_current_power = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 1, 2, 1, 4), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
hwEasyOperationPortPowerInfoCurrentPower.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationPortPowerInfoCurrentPower.setDescription('The current power of port.')
hw_easy_operation_port_power_info_gauge = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 1, 2, 1, 5), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2))).clone(namedValues=named_values(('actual', 1), ('presumed', 2)))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
hwEasyOperationPortPowerInfoGauge.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationPortPowerInfoGauge.setDescription('The gauge of port power.')
hw_easy_operation_net_power_history_info_table = mib_table((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 1, 3))
if mibBuilder.loadTexts:
hwEasyOperationNetPowerHistoryInfoTable.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationNetPowerHistoryInfoTable.setDescription('The net power history information table.')
hw_easy_operation_net_power_history_info_entry = mib_table_row((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 1, 3, 1)).setIndexNames((0, 'HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationNetPowerHistoryInfoIndex'))
if mibBuilder.loadTexts:
hwEasyOperationNetPowerHistoryInfoEntry.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationNetPowerHistoryInfoEntry.setDescription('The entry of net power history table.')
hw_easy_operation_net_power_history_info_index = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 1, 3, 1, 1), integer32())
if mibBuilder.loadTexts:
hwEasyOperationNetPowerHistoryInfoIndex.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationNetPowerHistoryInfoIndex.setDescription('The index of the table.')
hw_easy_operation_net_power_history_info_whole_power = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 1, 3, 1, 2), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
hwEasyOperationNetPowerHistoryInfoWholePower.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationNetPowerHistoryInfoWholePower.setDescription('The total power of the whole network.')
hw_easy_operation_topology_table = mib_table((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 3))
if mibBuilder.loadTexts:
hwEasyOperationTopologyTable.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationTopologyTable.setDescription('The topology table.')
hw_easy_operation_topology_entry = mib_table_row((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 3, 1)).setIndexNames((0, 'HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationTopologyHopIndex'), (0, 'HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationTopologyDeviceIndex'))
if mibBuilder.loadTexts:
hwEasyOperationTopologyEntry.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationTopologyEntry.setDescription('The entry of topology table.')
hw_easy_operation_topology_hop_index = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 3, 1, 1), integer32())
if mibBuilder.loadTexts:
hwEasyOperationTopologyHopIndex.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationTopologyHopIndex.setDescription('The topoloy hop.')
hw_easy_operation_topology_device_index = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 3, 1, 2), integer32())
if mibBuilder.loadTexts:
hwEasyOperationTopologyDeviceIndex.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationTopologyDeviceIndex.setDescription('The index of topology device.')
hw_easy_operation_topology_local_mac = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 3, 1, 3), mac_address()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
hwEasyOperationTopologyLocalMac.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationTopologyLocalMac.setDescription('The mac address of local topology node.')
hw_easy_operation_topology_father_mac = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 3, 1, 4), mac_address()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
hwEasyOperationTopologyFatherMac.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationTopologyFatherMac.setDescription('The mac address of father topology node.')
hw_easy_operation_topology_local_port_name = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 3, 1, 5), octet_string()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
hwEasyOperationTopologyLocalPortName.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationTopologyLocalPortName.setDescription('The port name of local topology node.')
hw_easy_operation_topology_father_port_name = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 3, 1, 6), octet_string()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
hwEasyOperationTopologyFatherPortName.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationTopologyFatherPortName.setDescription('The port name of father topology node.')
hw_easy_operation_topology_local_device_id = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 3, 1, 7), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
hwEasyOperationTopologyLocalDeviceId.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationTopologyLocalDeviceId.setDescription('The device id of local topology node.')
hw_easy_operation_topology_father_device_id = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 3, 1, 8), integer32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
hwEasyOperationTopologyFatherDeviceId.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationTopologyFatherDeviceId.setDescription('The device id of father topology node.')
hw_easy_operation_saved_topology_table = mib_table((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 4))
if mibBuilder.loadTexts:
hwEasyOperationSavedTopologyTable.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationSavedTopologyTable.setDescription('The saved topology table.')
hw_easy_operation_saved_topology_entry = mib_table_row((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 4, 1)).setIndexNames((0, 'HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationSavedTopologyHopIndex'), (0, 'HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationSavedTopologyDeviceIndex'))
if mibBuilder.loadTexts:
hwEasyOperationSavedTopologyEntry.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationSavedTopologyEntry.setDescription('The entry of saved topology table.')
hw_easy_operation_saved_topology_hop_index = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 4, 1, 1), integer32())
if mibBuilder.loadTexts:
hwEasyOperationSavedTopologyHopIndex.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationSavedTopologyHopIndex.setDescription('The index of saved topology hop.')
hw_easy_operation_saved_topology_device_index = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 4, 1, 2), integer32())
if mibBuilder.loadTexts:
hwEasyOperationSavedTopologyDeviceIndex.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationSavedTopologyDeviceIndex.setDescription('The index of saved topology device.')
hw_easy_operation_saved_topology_local_mac = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 4, 1, 3), mac_address()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
hwEasyOperationSavedTopologyLocalMac.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationSavedTopologyLocalMac.setDescription('The mac address of saved local topology node.')
hw_easy_operation_saved_topology_father_mac = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 4, 1, 4), mac_address()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
hwEasyOperationSavedTopologyFatherMac.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationSavedTopologyFatherMac.setDescription('The mac address of saved father topology node.')
hw_easy_operation_saved_topology_local_port_name = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 4, 1, 5), octet_string()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
hwEasyOperationSavedTopologyLocalPortName.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationSavedTopologyLocalPortName.setDescription('The port name of saved local topology node.')
hw_easy_operation_saved_topology_father_port_name = mib_table_column((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 7, 4, 1, 6), octet_string()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
hwEasyOperationSavedTopologyFatherPortName.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationSavedTopologyFatherPortName.setDescription('The port name of saved father topology node.')
hw_easy_operation_compliance = module_compliance((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 100)).setObjects(('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationGlobalObjectsGroup'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationGroupObjectsGroup'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationGroupTableGroup'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationGroupMatchTableGroup'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientObjectsGroup'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientInfoGroup'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationTopologyGroup'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationPortPowerInfoGroup'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationDevicePowerInfoGroup'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationNotificationGroup'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientReplaceGroup'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationSavedTopologyGroup'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationNetPowerHistoryInfoGroup'))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
hw_easy_operation_compliance = hwEasyOperationCompliance.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationCompliance.setDescription('The compliance.')
hw_easy_operation_global_objects_group = object_group((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 100, 1)).setObjects(('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationCommanderIpAddressType'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationBackupConfigMode'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationActivateInTime'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationActivateDelayTime'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationActivateMode'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationAutoClearEnable'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationServerIpAddressType'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationServerIpAddress'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationServerType'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationDefaultSysSoftwareVer'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationDefaultConfig'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationDefaultPatch'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationDefaultWebfile'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationDefaultLicense'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationDefaultCustomfile1'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationDefaultCustomfile2'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationDefaultCustomfile3'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationDefaultSysSoftware'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationBackupConfigInterval'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationCommanderUdpPort'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationServerPort'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientAgingTime'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationTopologyEnable'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationCommanderIpAddress'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationCommanderEnable'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientAutoJoinEnable'))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
hw_easy_operation_global_objects_group = hwEasyOperationGlobalObjectsGroup.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationGlobalObjectsGroup.setDescription('The global objects group.')
hw_easy_operation_group_objects_group = object_group((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 100, 2)).setObjects(('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationTotalGroupNumber'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationBuildInGroupNumber'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationCustomGroupNumber'))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
hw_easy_operation_group_objects_group = hwEasyOperationGroupObjectsGroup.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationGroupObjectsGroup.setDescription('The group objects group.')
hw_easy_operation_group_table_group = object_group((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 100, 3)).setObjects(('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationGroupType'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationGroupName'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationGroupSysSoftware'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationGroupSysSoftwareVer'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationGroupConfig'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationGroupPatch'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationGroupWebfile'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationGroupLicense'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationGroupCustomfile1'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationGroupCustomfile2'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationGroupCustomfile3'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationGroupActivateMode'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationGroupActivateDelayTime'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationGroupActivateInTime'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationGroupRowStatus'))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
hw_easy_operation_group_table_group = hwEasyOperationGroupTableGroup.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationGroupTableGroup.setDescription('The group table group.')
hw_easy_operation_group_match_table_group = object_group((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 100, 4)).setObjects(('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationGroupMatchMacAddress'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationGroupMatchEsn'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationGroupMatchModel'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationGroupMatchDeviceType'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationGroupMatchRowStatus'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationGroupMatchMacMask'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationGroupMatchIpAddress'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationGroupMatchIpAddressType'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationGroupMatchIpAddressMask'))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
hw_easy_operation_group_match_table_group = hwEasyOperationGroupMatchTableGroup.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationGroupMatchTableGroup.setDescription('The match rule table objects group.')
hw_easy_operation_client_objects_group = object_group((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 100, 5)).setObjects(('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientNumber'))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
hw_easy_operation_client_objects_group = hwEasyOperationClientObjectsGroup.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientObjectsGroup.setDescription('The client objects group.')
hw_easy_operation_client_info_group = object_group((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 100, 6)).setObjects(('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientInfoClientMacAddress'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientInfoClientEsn'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientInfoClientModel'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientInfoClientDeviceType'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientInfoClientSysSoftware'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientInfoClientSysSoftwareVer'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientInfoClientSysConfig'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientInfoClientSysPatch'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientInfoClientSysWebFile'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientInfoClientSysLicense'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientInfoClientDownloadSoftware'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientInfoClientDownloadSoftwareVer'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientInfoClientDownloadConfig'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientInfoClientDownloadPatch'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientInfoClientDownloadWebFile'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientInfoClientDownloadLicense'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientInfoClientDownloadCustomfile1'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientInfoClientDownloadCustomfile2'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientInfoClientDownloadCustomfile3'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientInfoClientErrorDescr'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientInfoClientIpAddress'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientInfoClientRowStatus'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientInfoClientHostName'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientInfoClientBackupErrorDescr'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientInfoClientBackupErrorReason'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientInfoClientErrorReason'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientInfoClientDownloadPercent'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientInfoClientIpAddressType'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientInfoClientMethod'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientInfoClientPhase'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientInfoClientOperateState'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientInfoClientRunState'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientInfoClientCpuUsage'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientInfoClientMemoryUsage'))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
hw_easy_operation_client_info_group = hwEasyOperationClientInfoGroup.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientInfoGroup.setDescription('The client table group.')
hw_easy_operation_client_replace_group = object_group((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 100, 7)).setObjects(('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientReplaceRowStatus'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientReplaceDownloadCustomfile3'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientReplaceDownloadCustomfile2'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientReplaceDownloadCustomfile1'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientReplaceDownloadLicense'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientReplaceDownloadWebFile'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientReplaceDownloadPatch'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientReplaceDownloadSoftwareVer'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientReplaceDownloadSoftware'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientReplaceNewEsn'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientReplaceNewMacAddress'))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
hw_easy_operation_client_replace_group = hwEasyOperationClientReplaceGroup.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationClientReplaceGroup.setDescription('The replace client table group.')
hw_easy_operation_notification_group = notification_group((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 100, 8)).setObjects(('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientAdded'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationClientLost'))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
hw_easy_operation_notification_group = hwEasyOperationNotificationGroup.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationNotificationGroup.setDescription('The notification objects group.')
hw_easy_operation_device_power_info_group = object_group((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 100, 9)).setObjects(('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationDevicePowerInfoCurrentPower'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationDevicePowerInfoGauge'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationDevicePowerInfoRatedPower'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationDevicePowerInfoPowerManageMode'))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
hw_easy_operation_device_power_info_group = hwEasyOperationDevicePowerInfoGroup.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationDevicePowerInfoGroup.setDescription('The device power information table group.')
hw_easy_operation_port_power_info_group = object_group((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 100, 10)).setObjects(('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationPortPowerInfoPortName'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationPortPowerInfoCurrentPower'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationPortPowerInfoGauge'))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
hw_easy_operation_port_power_info_group = hwEasyOperationPortPowerInfoGroup.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationPortPowerInfoGroup.setDescription('The port power information table group.')
hw_easy_operation_topology_group = object_group((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 100, 11)).setObjects(('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationTopologyLocalMac'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationTopologyFatherMac'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationTopologyLocalPortName'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationTopologyFatherPortName'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationTopologyLocalDeviceId'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationTopologyFatherDeviceId'))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
hw_easy_operation_topology_group = hwEasyOperationTopologyGroup.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationTopologyGroup.setDescription('The topology table group.')
hw_easy_operation_saved_topology_group = object_group((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 100, 12)).setObjects(('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationSavedTopologyLocalMac'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationSavedTopologyFatherMac'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationSavedTopologyLocalPortName'), ('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationSavedTopologyFatherPortName'))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
hw_easy_operation_saved_topology_group = hwEasyOperationSavedTopologyGroup.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationSavedTopologyGroup.setDescription('The saved topology table group.')
hw_easy_operation_net_power_history_info_group = object_group((1, 3, 6, 1, 4, 1, 2011, 5, 25, 311, 100, 13)).setObjects(('HUAWEI-EASY-OPERATION-MIB', 'hwEasyOperationNetPowerHistoryInfoWholePower'))
if getattr(mibBuilder, 'version', (0, 0, 0)) > (4, 4, 0):
hw_easy_operation_net_power_history_info_group = hwEasyOperationNetPowerHistoryInfoGroup.setStatus('current')
if mibBuilder.loadTexts:
hwEasyOperationNetPowerHistoryInfoGroup.setDescription('The power history of whole network table group.')
mibBuilder.exportSymbols('HUAWEI-EASY-OPERATION-MIB', hwEasyOperationClientInfoClientDeviceType=hwEasyOperationClientInfoClientDeviceType, hwEasyOperationGroupCustomfile1=hwEasyOperationGroupCustomfile1, hwEasyOperationGroupMatchMacMask=hwEasyOperationGroupMatchMacMask, hwEasyOperationSavedTopologyFatherMac=hwEasyOperationSavedTopologyFatherMac, hwEasyOperationTopologyFatherMac=hwEasyOperationTopologyFatherMac, hwEasyOperationDevicePowerInfoGauge=hwEasyOperationDevicePowerInfoGauge, hwEasyOperationClientReplaceDownloadSoftware=hwEasyOperationClientReplaceDownloadSoftware, hwEasyOperationClientInfoGroup=hwEasyOperationClientInfoGroup, hwEasyOperationGroupMatchIpAddress=hwEasyOperationGroupMatchIpAddress, hwEasyOperationSavedTopologyFatherPortName=hwEasyOperationSavedTopologyFatherPortName, hwEasyOperationClientInfoClientSysWebFile=hwEasyOperationClientInfoClientSysWebFile, hwEasyOperationClientInfoClientDownloadSoftwareVer=hwEasyOperationClientInfoClientDownloadSoftwareVer, hwEasyOperationCommanderIpAddressType=hwEasyOperationCommanderIpAddressType, hwEasyOperationGroupMatchIpAddressType=hwEasyOperationGroupMatchIpAddressType, PYSNMP_MODULE_ID=hwEasyOperationMIB, hwEasyOperationClientInfoClientSysConfig=hwEasyOperationClientInfoClientSysConfig, hwEasyOperationClientInfoClientDownloadWebFile=hwEasyOperationClientInfoClientDownloadWebFile, hwEasyOperationClientInfoClientMethod=hwEasyOperationClientInfoClientMethod, hwEasyOperationClientInfoClientErrorDescr=hwEasyOperationClientInfoClientErrorDescr, hwEasyOperationDefaultWebfile=hwEasyOperationDefaultWebfile, hwEasyOperationGroupEntry=hwEasyOperationGroupEntry, hwEasyOperationSavedTopologyGroup=hwEasyOperationSavedTopologyGroup, hwEasyOperationGroupSysSoftwareVer=hwEasyOperationGroupSysSoftwareVer, hwEasyOperationCommanderEnable=hwEasyOperationCommanderEnable, hwEasyOperationGroupObjectsGroup=hwEasyOperationGroupObjectsGroup, hwEasyOperationDefaultConfig=hwEasyOperationDefaultConfig, hwEasyOperationClientReplaceDownloadLicense=hwEasyOperationClientReplaceDownloadLicense, hwEasyOperationTrapVar=hwEasyOperationTrapVar, hwEasyOperationClientInfoClientDownloadConfig=hwEasyOperationClientInfoClientDownloadConfig, hwEasyOperationClientObjectsGroup=hwEasyOperationClientObjectsGroup, hwEasyOperationNetPowerHistoryInfoGroup=hwEasyOperationNetPowerHistoryInfoGroup, hwEasyOperationSavedTopologyLocalMac=hwEasyOperationSavedTopologyLocalMac, hwEasyOperationDevicePowerInfoEntry=hwEasyOperationDevicePowerInfoEntry, hwEasyOperationClientReplaceGroup=hwEasyOperationClientReplaceGroup, hwEasyOperationClientInfoClientSysSoftwareVer=hwEasyOperationClientInfoClientSysSoftwareVer, hwEasyOperationClientReplaceDownloadSoftwareVer=hwEasyOperationClientReplaceDownloadSoftwareVer, hwEasyOperationSavedTopologyLocalPortName=hwEasyOperationSavedTopologyLocalPortName, hwEasyOperationGroup=hwEasyOperationGroup, hwEasyOperationClient=hwEasyOperationClient, hwEasyOperationNetPowerHistoryInfoTable=hwEasyOperationNetPowerHistoryInfoTable, hwEasyOperationDevicePowerInfoRatedPower=hwEasyOperationDevicePowerInfoRatedPower, hwEasyOperationClientInfoClientDownloadCustomfile2=hwEasyOperationClientInfoClientDownloadCustomfile2, hwEasyOperationClientInfoClientDownloadLicense=hwEasyOperationClientInfoClientDownloadLicense, hwEasyOperationGroupType=hwEasyOperationGroupType, hwEasyOperationGroupMatchTableGroup=hwEasyOperationGroupMatchTableGroup, hwEasyOperationGroupIndex=hwEasyOperationGroupIndex, hwEasyOperationAutoClearEnable=hwEasyOperationAutoClearEnable, hwEasyOperationActivateMode=hwEasyOperationActivateMode, hwEasyOperationSavedTopologyHopIndex=hwEasyOperationSavedTopologyHopIndex, hwEasyOperationClientInfoClientSysPatch=hwEasyOperationClientInfoClientSysPatch, hwEasyOperationDefaultCustomfile3=hwEasyOperationDefaultCustomfile3, hwEasyOperationGlobalObjectsGroup=hwEasyOperationGlobalObjectsGroup, hwEasyOperationPortPowerInfoCurrentPower=hwEasyOperationPortPowerInfoCurrentPower, hwEasyOperationGroupActivateDelayTime=hwEasyOperationGroupActivateDelayTime, hwEasyOperationCompliance=hwEasyOperationCompliance, hwEasyOperationNotificationGroup=hwEasyOperationNotificationGroup, hwEasyOperationClientInfoClientCpuUsage=hwEasyOperationClientInfoClientCpuUsage, hwEasyOperationGroupTable=hwEasyOperationGroupTable, hwEasyOperationServerType=hwEasyOperationServerType, hwEasyOperationTopologyDeviceIndex=hwEasyOperationTopologyDeviceIndex, hwEasyOperationGroupMatchMacAddress=hwEasyOperationGroupMatchMacAddress, hwEasyOperationTopologyLocalDeviceId=hwEasyOperationTopologyLocalDeviceId, hwEasyOperationGroupCustomfile3=hwEasyOperationGroupCustomfile3, hwEasyOperationDefaultPatch=hwEasyOperationDefaultPatch, hwEasyOperationClientReplaceNewMacAddress=hwEasyOperationClientReplaceNewMacAddress, hwEasyOperationClientAdded=hwEasyOperationClientAdded, hwEasyOperationClientInfoClientDownloadPercent=hwEasyOperationClientInfoClientDownloadPercent, hwEasyOperationSavedTopologyEntry=hwEasyOperationSavedTopologyEntry, hwEasyOperationClientInfoClientBackupErrorDescr=hwEasyOperationClientInfoClientBackupErrorDescr, hwEasyOperationCustomGroupNumber=hwEasyOperationCustomGroupNumber, hwEasyOperationClientInfoClientMacAddress=hwEasyOperationClientInfoClientMacAddress, hwEasyOperationTopologyEnable=hwEasyOperationTopologyEnable, hwEasyOperationDevicePowerInfoTable=hwEasyOperationDevicePowerInfoTable, hwEasyOperationServerIpAddressType=hwEasyOperationServerIpAddressType, hwEasyOperationGroupRowStatus=hwEasyOperationGroupRowStatus, hwEasyOperationGroupMatchDeviceType=hwEasyOperationGroupMatchDeviceType, hwEasyOperationClientInfoClientIndex=hwEasyOperationClientInfoClientIndex, hwEasyOperationDefaultSysSoftware=hwEasyOperationDefaultSysSoftware, hwEasyOperationClientInfoClientHostName=hwEasyOperationClientInfoClientHostName, hwEasyOperationGroupLicense=hwEasyOperationGroupLicense, hwEasyOperationGlobalObjects=hwEasyOperationGlobalObjects, hwEasyOperationTopologyTable=hwEasyOperationTopologyTable, hwEasyOperationGroupActivateMode=hwEasyOperationGroupActivateMode, hwEasyOperationClientInfoClientIpAddressType=hwEasyOperationClientInfoClientIpAddressType, hwEasyOperationBackupConfigMode=hwEasyOperationBackupConfigMode, hwEasyOperationDevicePowerInfoPowerManageMode=hwEasyOperationDevicePowerInfoPowerManageMode, hwEasyOperationClientInfoClientIpAddress=hwEasyOperationClientInfoClientIpAddress, hwEasyOperationClientReplaceDownloadCustomfile3=hwEasyOperationClientReplaceDownloadCustomfile3, hwEasyOperationPortPowerInfoDeviceIndex=hwEasyOperationPortPowerInfoDeviceIndex, hwEasyOperationPortPowerInfoTable=hwEasyOperationPortPowerInfoTable, hwEasyOperationClientInfoClientPhase=hwEasyOperationClientInfoClientPhase, hwEasyOperationTopologyFatherPortName=hwEasyOperationTopologyFatherPortName, hwEasyOperationTopologyLocalPortName=hwEasyOperationTopologyLocalPortName, hwEasyOperationSavedTopologyDeviceIndex=hwEasyOperationSavedTopologyDeviceIndex, hwEasyOperationServerPort=hwEasyOperationServerPort, hwEasyOperationDevicePowerInfoCurrentPower=hwEasyOperationDevicePowerInfoCurrentPower, hwEasyOperationGroupMatchModel=hwEasyOperationGroupMatchModel, hwEasyOperationClientInfoClientRowStatus=hwEasyOperationClientInfoClientRowStatus, hwEasyOperationCommanderUdpPort=hwEasyOperationCommanderUdpPort, hwEasyOperationTotalGroupNumber=hwEasyOperationTotalGroupNumber, hwEasyOperationClientInfoClientDownloadSoftware=hwEasyOperationClientInfoClientDownloadSoftware, hwEasyOperationDevicePowerInfoIndex=hwEasyOperationDevicePowerInfoIndex, hwEasyOperationClientReplaceClientIndex=hwEasyOperationClientReplaceClientIndex, hwEasyOperationClientInfoClientDownloadPatch=hwEasyOperationClientInfoClientDownloadPatch, hwEasyOperationGroupConfig=hwEasyOperationGroupConfig, hwEasyOperationPowerInfo=hwEasyOperationPowerInfo, hwEasyOperationGroupActivateInTime=hwEasyOperationGroupActivateInTime, hwEasyOperationMonitor=hwEasyOperationMonitor, hwEasyOperationClientAutoJoinEnable=hwEasyOperationClientAutoJoinEnable, hwEasyOperationNotification=hwEasyOperationNotification, hwEasyOperationClientReplaceEntry=hwEasyOperationClientReplaceEntry, hwEasyOperationTopologyHopIndex=hwEasyOperationTopologyHopIndex, hwEasyOperationClientInfoClientEsn=hwEasyOperationClientInfoClientEsn, hwEasyOperationClientInfoClientMemoryUsage=hwEasyOperationClientInfoClientMemoryUsage, hwEasyOperationBuildInGroupNumber=hwEasyOperationBuildInGroupNumber, hwEasyOperationClientInfoEntry=hwEasyOperationClientInfoEntry, hwEasyOperationNetPowerHistoryInfoIndex=hwEasyOperationNetPowerHistoryInfoIndex, hwEasyOperationClientJoinNotPermit=hwEasyOperationClientJoinNotPermit, hwEasyOperationGroupMatchRowStatus=hwEasyOperationGroupMatchRowStatus, hwEasyOperationTrap=hwEasyOperationTrap, hwEasyOperationNetPowerHistoryInfoEntry=hwEasyOperationNetPowerHistoryInfoEntry, hwEasyOperationTopologyFatherDeviceId=hwEasyOperationTopologyFatherDeviceId, hwEasyOperationGroupPatch=hwEasyOperationGroupPatch, hwEasyOperationDefaultCustomfile1=hwEasyOperationDefaultCustomfile1, hwEasyOperationDefaultLicense=hwEasyOperationDefaultLicense, hwEasyOperationGroupCustomfile2=hwEasyOperationGroupCustomfile2, hwEasyOperationNetPowerHistoryInfoWholePower=hwEasyOperationNetPowerHistoryInfoWholePower, hwEasyOperationClientReplaceDownloadCustomfile2=hwEasyOperationClientReplaceDownloadCustomfile2, hwEasyOperationGroupMatchIndex=hwEasyOperationGroupMatchIndex, hwEasyOperationClientAgingTime=hwEasyOperationClientAgingTime, hwEasyOperationClientReplaceDownloadPatch=hwEasyOperationClientReplaceDownloadPatch, hwEasyOperationServerIpAddress=hwEasyOperationServerIpAddress, hwEasyOperationClientLost=hwEasyOperationClientLost, hwEasyOperationClientReplaceRowStatus=hwEasyOperationClientReplaceRowStatus, hwEasyOperationDevicePowerInfoGroup=hwEasyOperationDevicePowerInfoGroup, hwEasyOperationClientInfoClientDownloadCustomfile1=hwEasyOperationClientInfoClientDownloadCustomfile1, hwEasyOperationCommanderIpAddress=hwEasyOperationCommanderIpAddress, hwEasyOperationTopologyGroup=hwEasyOperationTopologyGroup, hwEasyOperationClientInfoClientBackupErrorReason=hwEasyOperationClientInfoClientBackupErrorReason, hwEasyOperationClientReplaceNewEsn=hwEasyOperationClientReplaceNewEsn, hwEasyOperationActivateDelayTime=hwEasyOperationActivateDelayTime, hwEasyOperationPortPowerInfoPortName=hwEasyOperationPortPowerInfoPortName, hwEasyOperationActivateInTime=hwEasyOperationActivateInTime, hwEasyOperationMIB=hwEasyOperationMIB, hwEasyOperationClientInfoClientOperateState=hwEasyOperationClientInfoClientOperateState, hwEasyOperationClientReplaceDownloadWebFile=hwEasyOperationClientReplaceDownloadWebFile, hwEasyOperationGroupMatchIpAddressMask=hwEasyOperationGroupMatchIpAddressMask, hwEasyOperationGroupWebfile=hwEasyOperationGroupWebfile, hwEasyOperationPortPowerInfoPortIndex=hwEasyOperationPortPowerInfoPortIndex, hwEasyOperationClientInfoClientSysLicense=hwEasyOperationClientInfoClientSysLicense, hwEasyOperationGroupSysSoftware=hwEasyOperationGroupSysSoftware, hwEasyOperationClientInfoClientModel=hwEasyOperationClientInfoClientModel, hwEasyOperationGroupMatchTable=hwEasyOperationGroupMatchTable, hwEasyOperationGroupMatchEntry=hwEasyOperationGroupMatchEntry, hwEasyOperationGroupMatchEsn=hwEasyOperationGroupMatchEsn, hwEasyOperationTopologyLocalMac=hwEasyOperationTopologyLocalMac, hwEasyOperationGroupName=hwEasyOperationGroupName, hwEasyOperationBackupConfigInterval=hwEasyOperationBackupConfigInterval, hwEasyOperationPortPowerInfoEntry=hwEasyOperationPortPowerInfoEntry, hwEasyOperationDefaultCustomfile2=hwEasyOperationDefaultCustomfile2, hwEasyOperationClientInfoClientSysSoftware=hwEasyOperationClientInfoClientSysSoftware, hwEasyOperationClientInfoClientDownloadCustomfile3=hwEasyOperationClientInfoClientDownloadCustomfile3, hwEasyOperationClientInfoClientRunState=hwEasyOperationClientInfoClientRunState, hwEasyOperationClientInfoClientErrorReason=hwEasyOperationClientInfoClientErrorReason, hwEasyOperationClientReplaceDownloadCustomfile1=hwEasyOperationClientReplaceDownloadCustomfile1, hwEasyOperationSavedTopologyTable=hwEasyOperationSavedTopologyTable, hwEasyOperationGroupTableGroup=hwEasyOperationGroupTableGroup, hwEasyOperationClientReplaceTable=hwEasyOperationClientReplaceTable, hwEasyOperationTopologyEntry=hwEasyOperationTopologyEntry, hwEasyOperationPortPowerInfoGauge=hwEasyOperationPortPowerInfoGauge, hwEasyOperationDefaultSysSoftwareVer=hwEasyOperationDefaultSysSoftwareVer, hwEasyOperationClientInfoTable=hwEasyOperationClientInfoTable, hwEasyOperationClientNumber=hwEasyOperationClientNumber, hwEasyOperationPortPowerInfoGroup=hwEasyOperationPortPowerInfoGroup) |
class Solution():
def minmoves(self, nums: list) -> int:
steps = 0
min_num = min(nums)
for num in nums:
steps += abs(min_num - num)
return steps
def minmoves(self, nums: list) -> int:
max_element = max(nums)
res = 0
for i in range(len(nums)):
if i == 0:
res += max_element - nums[i]
else:
if nums[i] != nums[i - 1]:
res += max_element - nums[i]
res = res + nums.count(max_element) - 1
return res
nums = [1, 2, 3]
nums = [2, 3, 3, 4]
# 3,4,3,5
# 4,4,4
# nums = [1, 1, 2147483647]
s = Solution()
print(s.minmoves(nums))
| class Solution:
def minmoves(self, nums: list) -> int:
steps = 0
min_num = min(nums)
for num in nums:
steps += abs(min_num - num)
return steps
def minmoves(self, nums: list) -> int:
max_element = max(nums)
res = 0
for i in range(len(nums)):
if i == 0:
res += max_element - nums[i]
elif nums[i] != nums[i - 1]:
res += max_element - nums[i]
res = res + nums.count(max_element) - 1
return res
nums = [1, 2, 3]
nums = [2, 3, 3, 4]
s = solution()
print(s.minmoves(nums)) |
#
# PySNMP MIB module Nortel-MsCarrier-MscPassport-AtmMpeMIB (http://snmplabs.com/pysmi)
# ASN.1 source file:///Users/davwang4/Dev/mibs.snmplabs.com/asn1/Nortel-MsCarrier-MscPassport-AtmMpeMIB
# Produced by pysmi-0.3.4 at Mon Apr 29 20:19: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)
#
ObjectIdentifier, OctetString, Integer = mibBuilder.importSymbols("ASN1", "ObjectIdentifier", "OctetString", "Integer")
NamedValues, = mibBuilder.importSymbols("ASN1-ENUMERATION", "NamedValues")
ValueSizeConstraint, SingleValueConstraint, ValueRangeConstraint, ConstraintsUnion, ConstraintsIntersection = mibBuilder.importSymbols("ASN1-REFINEMENT", "ValueSizeConstraint", "SingleValueConstraint", "ValueRangeConstraint", "ConstraintsUnion", "ConstraintsIntersection")
Unsigned32, DisplayString, InterfaceIndex, Integer32, Counter32, StorageType, RowStatus = mibBuilder.importSymbols("Nortel-MsCarrier-MscPassport-StandardTextualConventionsMIB", "Unsigned32", "DisplayString", "InterfaceIndex", "Integer32", "Counter32", "StorageType", "RowStatus")
Link, = mibBuilder.importSymbols("Nortel-MsCarrier-MscPassport-TextualConventionsMIB", "Link")
mscComponents, mscPassportMIBs = mibBuilder.importSymbols("Nortel-MsCarrier-MscPassport-UsefulDefinitionsMIB", "mscComponents", "mscPassportMIBs")
NotificationGroup, ModuleCompliance = mibBuilder.importSymbols("SNMPv2-CONF", "NotificationGroup", "ModuleCompliance")
Unsigned32, Counter64, ModuleIdentity, Counter32, TimeTicks, ObjectIdentity, MibScalar, MibTable, MibTableRow, MibTableColumn, NotificationType, MibIdentifier, iso, Integer32, IpAddress, Bits, Gauge32 = mibBuilder.importSymbols("SNMPv2-SMI", "Unsigned32", "Counter64", "ModuleIdentity", "Counter32", "TimeTicks", "ObjectIdentity", "MibScalar", "MibTable", "MibTableRow", "MibTableColumn", "NotificationType", "MibIdentifier", "iso", "Integer32", "IpAddress", "Bits", "Gauge32")
DisplayString, TextualConvention = mibBuilder.importSymbols("SNMPv2-TC", "DisplayString", "TextualConvention")
atmMpeMIB = MibIdentifier((1, 3, 6, 1, 4, 1, 562, 36, 2, 2, 65))
mscAtmMpe = MibIdentifier((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118))
mscAtmMpeRowStatusTable = MibTable((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 1), )
if mibBuilder.loadTexts: mscAtmMpeRowStatusTable.setStatus('mandatory')
mscAtmMpeRowStatusEntry = MibTableRow((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 1, 1), ).setIndexNames((0, "Nortel-MsCarrier-MscPassport-AtmMpeMIB", "mscAtmMpeIndex"))
if mibBuilder.loadTexts: mscAtmMpeRowStatusEntry.setStatus('mandatory')
mscAtmMpeRowStatus = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 1, 1, 1), RowStatus()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: mscAtmMpeRowStatus.setStatus('mandatory')
mscAtmMpeComponentName = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 1, 1, 2), DisplayString()).setMaxAccess("readonly")
if mibBuilder.loadTexts: mscAtmMpeComponentName.setStatus('mandatory')
mscAtmMpeStorageType = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 1, 1, 4), StorageType()).setMaxAccess("readonly")
if mibBuilder.loadTexts: mscAtmMpeStorageType.setStatus('mandatory')
mscAtmMpeIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 1, 1, 10), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 255)))
if mibBuilder.loadTexts: mscAtmMpeIndex.setStatus('mandatory')
mscAtmMpeCidDataTable = MibTable((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 10), )
if mibBuilder.loadTexts: mscAtmMpeCidDataTable.setStatus('mandatory')
mscAtmMpeCidDataEntry = MibTableRow((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 10, 1), ).setIndexNames((0, "Nortel-MsCarrier-MscPassport-AtmMpeMIB", "mscAtmMpeIndex"))
if mibBuilder.loadTexts: mscAtmMpeCidDataEntry.setStatus('mandatory')
mscAtmMpeCustomerIdentifier = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 10, 1, 1), Unsigned32().subtype(subtypeSpec=ConstraintsUnion(ValueRangeConstraint(0, 0), ValueRangeConstraint(1, 8191), ))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: mscAtmMpeCustomerIdentifier.setStatus('mandatory')
mscAtmMpeIfEntryTable = MibTable((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 11), )
if mibBuilder.loadTexts: mscAtmMpeIfEntryTable.setStatus('mandatory')
mscAtmMpeIfEntryEntry = MibTableRow((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 11, 1), ).setIndexNames((0, "Nortel-MsCarrier-MscPassport-AtmMpeMIB", "mscAtmMpeIndex"))
if mibBuilder.loadTexts: mscAtmMpeIfEntryEntry.setStatus('mandatory')
mscAtmMpeIfAdminStatus = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 11, 1, 1), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2, 3))).clone(namedValues=NamedValues(("up", 1), ("down", 2), ("testing", 3))).clone('up')).setMaxAccess("readwrite")
if mibBuilder.loadTexts: mscAtmMpeIfAdminStatus.setStatus('mandatory')
mscAtmMpeIfIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 11, 1, 2), InterfaceIndex().subtype(subtypeSpec=ValueRangeConstraint(1, 65535))).setMaxAccess("readonly")
if mibBuilder.loadTexts: mscAtmMpeIfIndex.setStatus('mandatory')
mscAtmMpeProvTable = MibTable((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 12), )
if mibBuilder.loadTexts: mscAtmMpeProvTable.setStatus('mandatory')
mscAtmMpeProvEntry = MibTableRow((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 12, 1), ).setIndexNames((0, "Nortel-MsCarrier-MscPassport-AtmMpeMIB", "mscAtmMpeIndex"))
if mibBuilder.loadTexts: mscAtmMpeProvEntry.setStatus('mandatory')
mscAtmMpeMaxTransmissionUnit = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 12, 1, 1), Unsigned32().subtype(subtypeSpec=ValueRangeConstraint(256, 9188)).clone(9188)).setMaxAccess("readwrite")
if mibBuilder.loadTexts: mscAtmMpeMaxTransmissionUnit.setStatus('mandatory')
mscAtmMpeEncapType = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 12, 1, 2), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2, 3))).clone(namedValues=NamedValues(("llcEncap", 1), ("ipVcEncap", 2), ("ipxVcEncap", 3))).clone('llcEncap')).setMaxAccess("readwrite")
if mibBuilder.loadTexts: mscAtmMpeEncapType.setStatus('mandatory')
mscAtmMpeIlsForwarder = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 12, 1, 3), Link()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: mscAtmMpeIlsForwarder.setStatus('mandatory')
mscAtmMpeMediaProvTable = MibTable((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 13), )
if mibBuilder.loadTexts: mscAtmMpeMediaProvTable.setStatus('mandatory')
mscAtmMpeMediaProvEntry = MibTableRow((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 13, 1), ).setIndexNames((0, "Nortel-MsCarrier-MscPassport-AtmMpeMIB", "mscAtmMpeIndex"))
if mibBuilder.loadTexts: mscAtmMpeMediaProvEntry.setStatus('mandatory')
mscAtmMpeLinkToProtocolPort = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 13, 1, 1), Link()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: mscAtmMpeLinkToProtocolPort.setStatus('mandatory')
mscAtmMpeStateTable = MibTable((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 14), )
if mibBuilder.loadTexts: mscAtmMpeStateTable.setStatus('mandatory')
mscAtmMpeStateEntry = MibTableRow((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 14, 1), ).setIndexNames((0, "Nortel-MsCarrier-MscPassport-AtmMpeMIB", "mscAtmMpeIndex"))
if mibBuilder.loadTexts: mscAtmMpeStateEntry.setStatus('mandatory')
mscAtmMpeAdminState = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 14, 1, 1), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(0, 1, 2))).clone(namedValues=NamedValues(("locked", 0), ("unlocked", 1), ("shuttingDown", 2))).clone('unlocked')).setMaxAccess("readonly")
if mibBuilder.loadTexts: mscAtmMpeAdminState.setStatus('mandatory')
mscAtmMpeOperationalState = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 14, 1, 2), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(0, 1))).clone(namedValues=NamedValues(("disabled", 0), ("enabled", 1))).clone('disabled')).setMaxAccess("readonly")
if mibBuilder.loadTexts: mscAtmMpeOperationalState.setStatus('mandatory')
mscAtmMpeUsageState = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 14, 1, 3), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(0, 1, 2))).clone(namedValues=NamedValues(("idle", 0), ("active", 1), ("busy", 2))).clone('idle')).setMaxAccess("readonly")
if mibBuilder.loadTexts: mscAtmMpeUsageState.setStatus('mandatory')
mscAtmMpeOperStatusTable = MibTable((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 15), )
if mibBuilder.loadTexts: mscAtmMpeOperStatusTable.setStatus('mandatory')
mscAtmMpeOperStatusEntry = MibTableRow((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 15, 1), ).setIndexNames((0, "Nortel-MsCarrier-MscPassport-AtmMpeMIB", "mscAtmMpeIndex"))
if mibBuilder.loadTexts: mscAtmMpeOperStatusEntry.setStatus('mandatory')
mscAtmMpeSnmpOperStatus = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 15, 1, 1), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(1, 2, 3))).clone(namedValues=NamedValues(("up", 1), ("down", 2), ("testing", 3))).clone('up')).setMaxAccess("readonly")
if mibBuilder.loadTexts: mscAtmMpeSnmpOperStatus.setStatus('mandatory')
mscAtmMpeAc = MibIdentifier((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 2))
mscAtmMpeAcRowStatusTable = MibTable((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 2, 1), )
if mibBuilder.loadTexts: mscAtmMpeAcRowStatusTable.setStatus('mandatory')
mscAtmMpeAcRowStatusEntry = MibTableRow((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 2, 1, 1), ).setIndexNames((0, "Nortel-MsCarrier-MscPassport-AtmMpeMIB", "mscAtmMpeIndex"), (0, "Nortel-MsCarrier-MscPassport-AtmMpeMIB", "mscAtmMpeAcIndex"))
if mibBuilder.loadTexts: mscAtmMpeAcRowStatusEntry.setStatus('mandatory')
mscAtmMpeAcRowStatus = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 2, 1, 1, 1), RowStatus()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: mscAtmMpeAcRowStatus.setStatus('mandatory')
mscAtmMpeAcComponentName = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 2, 1, 1, 2), DisplayString()).setMaxAccess("readonly")
if mibBuilder.loadTexts: mscAtmMpeAcComponentName.setStatus('mandatory')
mscAtmMpeAcStorageType = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 2, 1, 1, 4), StorageType()).setMaxAccess("readonly")
if mibBuilder.loadTexts: mscAtmMpeAcStorageType.setStatus('mandatory')
mscAtmMpeAcIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 2, 1, 1, 10), Integer32().subtype(subtypeSpec=ValueRangeConstraint(1, 255)))
if mibBuilder.loadTexts: mscAtmMpeAcIndex.setStatus('mandatory')
mscAtmMpeAcProvTable = MibTable((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 2, 10), )
if mibBuilder.loadTexts: mscAtmMpeAcProvTable.setStatus('mandatory')
mscAtmMpeAcProvEntry = MibTableRow((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 2, 10, 1), ).setIndexNames((0, "Nortel-MsCarrier-MscPassport-AtmMpeMIB", "mscAtmMpeIndex"), (0, "Nortel-MsCarrier-MscPassport-AtmMpeMIB", "mscAtmMpeAcIndex"))
if mibBuilder.loadTexts: mscAtmMpeAcProvEntry.setStatus('mandatory')
mscAtmMpeAcAtmConnection = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 2, 10, 1, 1), Link()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: mscAtmMpeAcAtmConnection.setStatus('mandatory')
mscAtmMpeAcIpCoS = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 2, 10, 1, 2), Unsigned32().subtype(subtypeSpec=ValueRangeConstraint(0, 3))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: mscAtmMpeAcIpCoS.setStatus('mandatory')
mscAtmMpeAcStateTable = MibTable((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 2, 11), )
if mibBuilder.loadTexts: mscAtmMpeAcStateTable.setStatus('mandatory')
mscAtmMpeAcStateEntry = MibTableRow((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 2, 11, 1), ).setIndexNames((0, "Nortel-MsCarrier-MscPassport-AtmMpeMIB", "mscAtmMpeIndex"), (0, "Nortel-MsCarrier-MscPassport-AtmMpeMIB", "mscAtmMpeAcIndex"))
if mibBuilder.loadTexts: mscAtmMpeAcStateEntry.setStatus('mandatory')
mscAtmMpeAcAdminState = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 2, 11, 1, 1), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(0, 1, 2))).clone(namedValues=NamedValues(("locked", 0), ("unlocked", 1), ("shuttingDown", 2))).clone('unlocked')).setMaxAccess("readonly")
if mibBuilder.loadTexts: mscAtmMpeAcAdminState.setStatus('mandatory')
mscAtmMpeAcOperationalState = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 2, 11, 1, 2), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(0, 1))).clone(namedValues=NamedValues(("disabled", 0), ("enabled", 1))).clone('disabled')).setMaxAccess("readonly")
if mibBuilder.loadTexts: mscAtmMpeAcOperationalState.setStatus('mandatory')
mscAtmMpeAcUsageState = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 2, 11, 1, 3), Integer32().subtype(subtypeSpec=ConstraintsUnion(SingleValueConstraint(0, 1, 2))).clone(namedValues=NamedValues(("idle", 0), ("active", 1), ("busy", 2))).clone('idle')).setMaxAccess("readonly")
if mibBuilder.loadTexts: mscAtmMpeAcUsageState.setStatus('mandatory')
mscAtmMpeAcOperTable = MibTable((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 2, 12), )
if mibBuilder.loadTexts: mscAtmMpeAcOperTable.setStatus('mandatory')
mscAtmMpeAcOperEntry = MibTableRow((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 2, 12, 1), ).setIndexNames((0, "Nortel-MsCarrier-MscPassport-AtmMpeMIB", "mscAtmMpeIndex"), (0, "Nortel-MsCarrier-MscPassport-AtmMpeMIB", "mscAtmMpeAcIndex"))
if mibBuilder.loadTexts: mscAtmMpeAcOperEntry.setStatus('mandatory')
mscAtmMpeAcSpeed = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 2, 12, 1, 1), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: mscAtmMpeAcSpeed.setStatus('mandatory')
mscAtmMpeAcStatsTable = MibTable((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 2, 13), )
if mibBuilder.loadTexts: mscAtmMpeAcStatsTable.setStatus('mandatory')
mscAtmMpeAcStatsEntry = MibTableRow((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 2, 13, 1), ).setIndexNames((0, "Nortel-MsCarrier-MscPassport-AtmMpeMIB", "mscAtmMpeIndex"), (0, "Nortel-MsCarrier-MscPassport-AtmMpeMIB", "mscAtmMpeAcIndex"))
if mibBuilder.loadTexts: mscAtmMpeAcStatsEntry.setStatus('mandatory')
mscAtmMpeAcOutPackets = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 2, 13, 1, 1), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: mscAtmMpeAcOutPackets.setStatus('mandatory')
mscAtmMpeAcOutOctets = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 2, 13, 1, 2), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: mscAtmMpeAcOutOctets.setStatus('mandatory')
mscAtmMpeAcOutDiscards = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 2, 13, 1, 3), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: mscAtmMpeAcOutDiscards.setStatus('mandatory')
mscAtmMpeAcInPackets = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 2, 13, 1, 4), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: mscAtmMpeAcInPackets.setStatus('mandatory')
mscAtmMpeAcInOctets = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 2, 13, 1, 5), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: mscAtmMpeAcInOctets.setStatus('mandatory')
mscAtmMpeAcInUnknownProtos = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 2, 13, 1, 6), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: mscAtmMpeAcInUnknownProtos.setStatus('mandatory')
mscAtmMpeAcInErrors = MibTableColumn((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 2, 13, 1, 7), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: mscAtmMpeAcInErrors.setStatus('mandatory')
atmMpeGroup = MibIdentifier((1, 3, 6, 1, 4, 1, 562, 36, 2, 2, 65, 1))
atmMpeGroupCA = MibIdentifier((1, 3, 6, 1, 4, 1, 562, 36, 2, 2, 65, 1, 1))
atmMpeGroupCA02 = MibIdentifier((1, 3, 6, 1, 4, 1, 562, 36, 2, 2, 65, 1, 1, 3))
atmMpeGroupCA02A = MibIdentifier((1, 3, 6, 1, 4, 1, 562, 36, 2, 2, 65, 1, 1, 3, 2))
atmMpeCapabilities = MibIdentifier((1, 3, 6, 1, 4, 1, 562, 36, 2, 2, 65, 3))
atmMpeCapabilitiesCA = MibIdentifier((1, 3, 6, 1, 4, 1, 562, 36, 2, 2, 65, 3, 1))
atmMpeCapabilitiesCA02 = MibIdentifier((1, 3, 6, 1, 4, 1, 562, 36, 2, 2, 65, 3, 1, 3))
atmMpeCapabilitiesCA02A = MibIdentifier((1, 3, 6, 1, 4, 1, 562, 36, 2, 2, 65, 3, 1, 3, 2))
mibBuilder.exportSymbols("Nortel-MsCarrier-MscPassport-AtmMpeMIB", mscAtmMpeAcIpCoS=mscAtmMpeAcIpCoS, mscAtmMpeIfIndex=mscAtmMpeIfIndex, mscAtmMpeAcOperEntry=mscAtmMpeAcOperEntry, mscAtmMpeAdminState=mscAtmMpeAdminState, mscAtmMpeIfEntryEntry=mscAtmMpeIfEntryEntry, mscAtmMpeIlsForwarder=mscAtmMpeIlsForwarder, mscAtmMpeAcRowStatus=mscAtmMpeAcRowStatus, atmMpeGroup=atmMpeGroup, mscAtmMpeStateEntry=mscAtmMpeStateEntry, mscAtmMpeIfEntryTable=mscAtmMpeIfEntryTable, mscAtmMpeAcOutDiscards=mscAtmMpeAcOutDiscards, mscAtmMpeLinkToProtocolPort=mscAtmMpeLinkToProtocolPort, mscAtmMpeAcSpeed=mscAtmMpeAcSpeed, mscAtmMpeRowStatusEntry=mscAtmMpeRowStatusEntry, mscAtmMpeMaxTransmissionUnit=mscAtmMpeMaxTransmissionUnit, atmMpeCapabilities=atmMpeCapabilities, mscAtmMpeProvEntry=mscAtmMpeProvEntry, mscAtmMpeAcStatsTable=mscAtmMpeAcStatsTable, mscAtmMpeAcRowStatusEntry=mscAtmMpeAcRowStatusEntry, mscAtmMpeAcOutPackets=mscAtmMpeAcOutPackets, mscAtmMpeAcIndex=mscAtmMpeAcIndex, mscAtmMpeMediaProvEntry=mscAtmMpeMediaProvEntry, mscAtmMpeAcAtmConnection=mscAtmMpeAcAtmConnection, mscAtmMpeAcInPackets=mscAtmMpeAcInPackets, mscAtmMpeAcInOctets=mscAtmMpeAcInOctets, atmMpeMIB=atmMpeMIB, mscAtmMpeIndex=mscAtmMpeIndex, mscAtmMpeCustomerIdentifier=mscAtmMpeCustomerIdentifier, atmMpeGroupCA=atmMpeGroupCA, atmMpeCapabilitiesCA=atmMpeCapabilitiesCA, mscAtmMpeAcStateEntry=mscAtmMpeAcStateEntry, mscAtmMpeOperStatusTable=mscAtmMpeOperStatusTable, atmMpeGroupCA02A=atmMpeGroupCA02A, mscAtmMpeEncapType=mscAtmMpeEncapType, mscAtmMpeAcStorageType=mscAtmMpeAcStorageType, mscAtmMpeAc=mscAtmMpeAc, mscAtmMpeOperStatusEntry=mscAtmMpeOperStatusEntry, mscAtmMpeCidDataEntry=mscAtmMpeCidDataEntry, mscAtmMpeProvTable=mscAtmMpeProvTable, mscAtmMpeOperationalState=mscAtmMpeOperationalState, mscAtmMpeComponentName=mscAtmMpeComponentName, mscAtmMpeStorageType=mscAtmMpeStorageType, mscAtmMpeStateTable=mscAtmMpeStateTable, mscAtmMpeAcOperationalState=mscAtmMpeAcOperationalState, mscAtmMpeRowStatus=mscAtmMpeRowStatus, mscAtmMpeAcStateTable=mscAtmMpeAcStateTable, mscAtmMpeAcOutOctets=mscAtmMpeAcOutOctets, mscAtmMpeAcInErrors=mscAtmMpeAcInErrors, mscAtmMpeSnmpOperStatus=mscAtmMpeSnmpOperStatus, atmMpeCapabilitiesCA02A=atmMpeCapabilitiesCA02A, mscAtmMpeRowStatusTable=mscAtmMpeRowStatusTable, mscAtmMpeUsageState=mscAtmMpeUsageState, mscAtmMpeAcInUnknownProtos=mscAtmMpeAcInUnknownProtos, mscAtmMpe=mscAtmMpe, mscAtmMpeCidDataTable=mscAtmMpeCidDataTable, mscAtmMpeAcComponentName=mscAtmMpeAcComponentName, mscAtmMpeAcOperTable=mscAtmMpeAcOperTable, mscAtmMpeAcUsageState=mscAtmMpeAcUsageState, mscAtmMpeAcStatsEntry=mscAtmMpeAcStatsEntry, mscAtmMpeMediaProvTable=mscAtmMpeMediaProvTable, mscAtmMpeAcProvEntry=mscAtmMpeAcProvEntry, atmMpeGroupCA02=atmMpeGroupCA02, atmMpeCapabilitiesCA02=atmMpeCapabilitiesCA02, mscAtmMpeIfAdminStatus=mscAtmMpeIfAdminStatus, mscAtmMpeAcRowStatusTable=mscAtmMpeAcRowStatusTable, mscAtmMpeAcAdminState=mscAtmMpeAcAdminState, mscAtmMpeAcProvTable=mscAtmMpeAcProvTable)
| (object_identifier, octet_string, integer) = mibBuilder.importSymbols('ASN1', 'ObjectIdentifier', 'OctetString', 'Integer')
(named_values,) = mibBuilder.importSymbols('ASN1-ENUMERATION', 'NamedValues')
(value_size_constraint, single_value_constraint, value_range_constraint, constraints_union, constraints_intersection) = mibBuilder.importSymbols('ASN1-REFINEMENT', 'ValueSizeConstraint', 'SingleValueConstraint', 'ValueRangeConstraint', 'ConstraintsUnion', 'ConstraintsIntersection')
(unsigned32, display_string, interface_index, integer32, counter32, storage_type, row_status) = mibBuilder.importSymbols('Nortel-MsCarrier-MscPassport-StandardTextualConventionsMIB', 'Unsigned32', 'DisplayString', 'InterfaceIndex', 'Integer32', 'Counter32', 'StorageType', 'RowStatus')
(link,) = mibBuilder.importSymbols('Nortel-MsCarrier-MscPassport-TextualConventionsMIB', 'Link')
(msc_components, msc_passport_mi_bs) = mibBuilder.importSymbols('Nortel-MsCarrier-MscPassport-UsefulDefinitionsMIB', 'mscComponents', 'mscPassportMIBs')
(notification_group, module_compliance) = mibBuilder.importSymbols('SNMPv2-CONF', 'NotificationGroup', 'ModuleCompliance')
(unsigned32, counter64, module_identity, counter32, time_ticks, object_identity, mib_scalar, mib_table, mib_table_row, mib_table_column, notification_type, mib_identifier, iso, integer32, ip_address, bits, gauge32) = mibBuilder.importSymbols('SNMPv2-SMI', 'Unsigned32', 'Counter64', 'ModuleIdentity', 'Counter32', 'TimeTicks', 'ObjectIdentity', 'MibScalar', 'MibTable', 'MibTableRow', 'MibTableColumn', 'NotificationType', 'MibIdentifier', 'iso', 'Integer32', 'IpAddress', 'Bits', 'Gauge32')
(display_string, textual_convention) = mibBuilder.importSymbols('SNMPv2-TC', 'DisplayString', 'TextualConvention')
atm_mpe_mib = mib_identifier((1, 3, 6, 1, 4, 1, 562, 36, 2, 2, 65))
msc_atm_mpe = mib_identifier((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118))
msc_atm_mpe_row_status_table = mib_table((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 1))
if mibBuilder.loadTexts:
mscAtmMpeRowStatusTable.setStatus('mandatory')
msc_atm_mpe_row_status_entry = mib_table_row((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 1, 1)).setIndexNames((0, 'Nortel-MsCarrier-MscPassport-AtmMpeMIB', 'mscAtmMpeIndex'))
if mibBuilder.loadTexts:
mscAtmMpeRowStatusEntry.setStatus('mandatory')
msc_atm_mpe_row_status = mib_table_column((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 1, 1, 1), row_status()).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
mscAtmMpeRowStatus.setStatus('mandatory')
msc_atm_mpe_component_name = mib_table_column((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 1, 1, 2), display_string()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
mscAtmMpeComponentName.setStatus('mandatory')
msc_atm_mpe_storage_type = mib_table_column((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 1, 1, 4), storage_type()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
mscAtmMpeStorageType.setStatus('mandatory')
msc_atm_mpe_index = mib_table_column((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 1, 1, 10), integer32().subtype(subtypeSpec=value_range_constraint(0, 255)))
if mibBuilder.loadTexts:
mscAtmMpeIndex.setStatus('mandatory')
msc_atm_mpe_cid_data_table = mib_table((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 10))
if mibBuilder.loadTexts:
mscAtmMpeCidDataTable.setStatus('mandatory')
msc_atm_mpe_cid_data_entry = mib_table_row((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 10, 1)).setIndexNames((0, 'Nortel-MsCarrier-MscPassport-AtmMpeMIB', 'mscAtmMpeIndex'))
if mibBuilder.loadTexts:
mscAtmMpeCidDataEntry.setStatus('mandatory')
msc_atm_mpe_customer_identifier = mib_table_column((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 10, 1, 1), unsigned32().subtype(subtypeSpec=constraints_union(value_range_constraint(0, 0), value_range_constraint(1, 8191)))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
mscAtmMpeCustomerIdentifier.setStatus('mandatory')
msc_atm_mpe_if_entry_table = mib_table((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 11))
if mibBuilder.loadTexts:
mscAtmMpeIfEntryTable.setStatus('mandatory')
msc_atm_mpe_if_entry_entry = mib_table_row((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 11, 1)).setIndexNames((0, 'Nortel-MsCarrier-MscPassport-AtmMpeMIB', 'mscAtmMpeIndex'))
if mibBuilder.loadTexts:
mscAtmMpeIfEntryEntry.setStatus('mandatory')
msc_atm_mpe_if_admin_status = mib_table_column((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 11, 1, 1), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2, 3))).clone(namedValues=named_values(('up', 1), ('down', 2), ('testing', 3))).clone('up')).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
mscAtmMpeIfAdminStatus.setStatus('mandatory')
msc_atm_mpe_if_index = mib_table_column((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 11, 1, 2), interface_index().subtype(subtypeSpec=value_range_constraint(1, 65535))).setMaxAccess('readonly')
if mibBuilder.loadTexts:
mscAtmMpeIfIndex.setStatus('mandatory')
msc_atm_mpe_prov_table = mib_table((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 12))
if mibBuilder.loadTexts:
mscAtmMpeProvTable.setStatus('mandatory')
msc_atm_mpe_prov_entry = mib_table_row((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 12, 1)).setIndexNames((0, 'Nortel-MsCarrier-MscPassport-AtmMpeMIB', 'mscAtmMpeIndex'))
if mibBuilder.loadTexts:
mscAtmMpeProvEntry.setStatus('mandatory')
msc_atm_mpe_max_transmission_unit = mib_table_column((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 12, 1, 1), unsigned32().subtype(subtypeSpec=value_range_constraint(256, 9188)).clone(9188)).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
mscAtmMpeMaxTransmissionUnit.setStatus('mandatory')
msc_atm_mpe_encap_type = mib_table_column((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 12, 1, 2), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2, 3))).clone(namedValues=named_values(('llcEncap', 1), ('ipVcEncap', 2), ('ipxVcEncap', 3))).clone('llcEncap')).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
mscAtmMpeEncapType.setStatus('mandatory')
msc_atm_mpe_ils_forwarder = mib_table_column((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 12, 1, 3), link()).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
mscAtmMpeIlsForwarder.setStatus('mandatory')
msc_atm_mpe_media_prov_table = mib_table((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 13))
if mibBuilder.loadTexts:
mscAtmMpeMediaProvTable.setStatus('mandatory')
msc_atm_mpe_media_prov_entry = mib_table_row((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 13, 1)).setIndexNames((0, 'Nortel-MsCarrier-MscPassport-AtmMpeMIB', 'mscAtmMpeIndex'))
if mibBuilder.loadTexts:
mscAtmMpeMediaProvEntry.setStatus('mandatory')
msc_atm_mpe_link_to_protocol_port = mib_table_column((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 13, 1, 1), link()).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
mscAtmMpeLinkToProtocolPort.setStatus('mandatory')
msc_atm_mpe_state_table = mib_table((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 14))
if mibBuilder.loadTexts:
mscAtmMpeStateTable.setStatus('mandatory')
msc_atm_mpe_state_entry = mib_table_row((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 14, 1)).setIndexNames((0, 'Nortel-MsCarrier-MscPassport-AtmMpeMIB', 'mscAtmMpeIndex'))
if mibBuilder.loadTexts:
mscAtmMpeStateEntry.setStatus('mandatory')
msc_atm_mpe_admin_state = mib_table_column((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 14, 1, 1), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(0, 1, 2))).clone(namedValues=named_values(('locked', 0), ('unlocked', 1), ('shuttingDown', 2))).clone('unlocked')).setMaxAccess('readonly')
if mibBuilder.loadTexts:
mscAtmMpeAdminState.setStatus('mandatory')
msc_atm_mpe_operational_state = mib_table_column((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 14, 1, 2), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(0, 1))).clone(namedValues=named_values(('disabled', 0), ('enabled', 1))).clone('disabled')).setMaxAccess('readonly')
if mibBuilder.loadTexts:
mscAtmMpeOperationalState.setStatus('mandatory')
msc_atm_mpe_usage_state = mib_table_column((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 14, 1, 3), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(0, 1, 2))).clone(namedValues=named_values(('idle', 0), ('active', 1), ('busy', 2))).clone('idle')).setMaxAccess('readonly')
if mibBuilder.loadTexts:
mscAtmMpeUsageState.setStatus('mandatory')
msc_atm_mpe_oper_status_table = mib_table((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 15))
if mibBuilder.loadTexts:
mscAtmMpeOperStatusTable.setStatus('mandatory')
msc_atm_mpe_oper_status_entry = mib_table_row((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 15, 1)).setIndexNames((0, 'Nortel-MsCarrier-MscPassport-AtmMpeMIB', 'mscAtmMpeIndex'))
if mibBuilder.loadTexts:
mscAtmMpeOperStatusEntry.setStatus('mandatory')
msc_atm_mpe_snmp_oper_status = mib_table_column((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 15, 1, 1), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(1, 2, 3))).clone(namedValues=named_values(('up', 1), ('down', 2), ('testing', 3))).clone('up')).setMaxAccess('readonly')
if mibBuilder.loadTexts:
mscAtmMpeSnmpOperStatus.setStatus('mandatory')
msc_atm_mpe_ac = mib_identifier((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 2))
msc_atm_mpe_ac_row_status_table = mib_table((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 2, 1))
if mibBuilder.loadTexts:
mscAtmMpeAcRowStatusTable.setStatus('mandatory')
msc_atm_mpe_ac_row_status_entry = mib_table_row((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 2, 1, 1)).setIndexNames((0, 'Nortel-MsCarrier-MscPassport-AtmMpeMIB', 'mscAtmMpeIndex'), (0, 'Nortel-MsCarrier-MscPassport-AtmMpeMIB', 'mscAtmMpeAcIndex'))
if mibBuilder.loadTexts:
mscAtmMpeAcRowStatusEntry.setStatus('mandatory')
msc_atm_mpe_ac_row_status = mib_table_column((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 2, 1, 1, 1), row_status()).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
mscAtmMpeAcRowStatus.setStatus('mandatory')
msc_atm_mpe_ac_component_name = mib_table_column((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 2, 1, 1, 2), display_string()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
mscAtmMpeAcComponentName.setStatus('mandatory')
msc_atm_mpe_ac_storage_type = mib_table_column((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 2, 1, 1, 4), storage_type()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
mscAtmMpeAcStorageType.setStatus('mandatory')
msc_atm_mpe_ac_index = mib_table_column((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 2, 1, 1, 10), integer32().subtype(subtypeSpec=value_range_constraint(1, 255)))
if mibBuilder.loadTexts:
mscAtmMpeAcIndex.setStatus('mandatory')
msc_atm_mpe_ac_prov_table = mib_table((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 2, 10))
if mibBuilder.loadTexts:
mscAtmMpeAcProvTable.setStatus('mandatory')
msc_atm_mpe_ac_prov_entry = mib_table_row((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 2, 10, 1)).setIndexNames((0, 'Nortel-MsCarrier-MscPassport-AtmMpeMIB', 'mscAtmMpeIndex'), (0, 'Nortel-MsCarrier-MscPassport-AtmMpeMIB', 'mscAtmMpeAcIndex'))
if mibBuilder.loadTexts:
mscAtmMpeAcProvEntry.setStatus('mandatory')
msc_atm_mpe_ac_atm_connection = mib_table_column((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 2, 10, 1, 1), link()).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
mscAtmMpeAcAtmConnection.setStatus('mandatory')
msc_atm_mpe_ac_ip_co_s = mib_table_column((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 2, 10, 1, 2), unsigned32().subtype(subtypeSpec=value_range_constraint(0, 3))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
mscAtmMpeAcIpCoS.setStatus('mandatory')
msc_atm_mpe_ac_state_table = mib_table((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 2, 11))
if mibBuilder.loadTexts:
mscAtmMpeAcStateTable.setStatus('mandatory')
msc_atm_mpe_ac_state_entry = mib_table_row((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 2, 11, 1)).setIndexNames((0, 'Nortel-MsCarrier-MscPassport-AtmMpeMIB', 'mscAtmMpeIndex'), (0, 'Nortel-MsCarrier-MscPassport-AtmMpeMIB', 'mscAtmMpeAcIndex'))
if mibBuilder.loadTexts:
mscAtmMpeAcStateEntry.setStatus('mandatory')
msc_atm_mpe_ac_admin_state = mib_table_column((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 2, 11, 1, 1), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(0, 1, 2))).clone(namedValues=named_values(('locked', 0), ('unlocked', 1), ('shuttingDown', 2))).clone('unlocked')).setMaxAccess('readonly')
if mibBuilder.loadTexts:
mscAtmMpeAcAdminState.setStatus('mandatory')
msc_atm_mpe_ac_operational_state = mib_table_column((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 2, 11, 1, 2), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(0, 1))).clone(namedValues=named_values(('disabled', 0), ('enabled', 1))).clone('disabled')).setMaxAccess('readonly')
if mibBuilder.loadTexts:
mscAtmMpeAcOperationalState.setStatus('mandatory')
msc_atm_mpe_ac_usage_state = mib_table_column((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 2, 11, 1, 3), integer32().subtype(subtypeSpec=constraints_union(single_value_constraint(0, 1, 2))).clone(namedValues=named_values(('idle', 0), ('active', 1), ('busy', 2))).clone('idle')).setMaxAccess('readonly')
if mibBuilder.loadTexts:
mscAtmMpeAcUsageState.setStatus('mandatory')
msc_atm_mpe_ac_oper_table = mib_table((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 2, 12))
if mibBuilder.loadTexts:
mscAtmMpeAcOperTable.setStatus('mandatory')
msc_atm_mpe_ac_oper_entry = mib_table_row((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 2, 12, 1)).setIndexNames((0, 'Nortel-MsCarrier-MscPassport-AtmMpeMIB', 'mscAtmMpeIndex'), (0, 'Nortel-MsCarrier-MscPassport-AtmMpeMIB', 'mscAtmMpeAcIndex'))
if mibBuilder.loadTexts:
mscAtmMpeAcOperEntry.setStatus('mandatory')
msc_atm_mpe_ac_speed = mib_table_column((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 2, 12, 1, 1), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
mscAtmMpeAcSpeed.setStatus('mandatory')
msc_atm_mpe_ac_stats_table = mib_table((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 2, 13))
if mibBuilder.loadTexts:
mscAtmMpeAcStatsTable.setStatus('mandatory')
msc_atm_mpe_ac_stats_entry = mib_table_row((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 2, 13, 1)).setIndexNames((0, 'Nortel-MsCarrier-MscPassport-AtmMpeMIB', 'mscAtmMpeIndex'), (0, 'Nortel-MsCarrier-MscPassport-AtmMpeMIB', 'mscAtmMpeAcIndex'))
if mibBuilder.loadTexts:
mscAtmMpeAcStatsEntry.setStatus('mandatory')
msc_atm_mpe_ac_out_packets = mib_table_column((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 2, 13, 1, 1), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
mscAtmMpeAcOutPackets.setStatus('mandatory')
msc_atm_mpe_ac_out_octets = mib_table_column((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 2, 13, 1, 2), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
mscAtmMpeAcOutOctets.setStatus('mandatory')
msc_atm_mpe_ac_out_discards = mib_table_column((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 2, 13, 1, 3), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
mscAtmMpeAcOutDiscards.setStatus('mandatory')
msc_atm_mpe_ac_in_packets = mib_table_column((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 2, 13, 1, 4), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
mscAtmMpeAcInPackets.setStatus('mandatory')
msc_atm_mpe_ac_in_octets = mib_table_column((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 2, 13, 1, 5), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
mscAtmMpeAcInOctets.setStatus('mandatory')
msc_atm_mpe_ac_in_unknown_protos = mib_table_column((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 2, 13, 1, 6), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
mscAtmMpeAcInUnknownProtos.setStatus('mandatory')
msc_atm_mpe_ac_in_errors = mib_table_column((1, 3, 6, 1, 4, 1, 562, 36, 2, 1, 118, 2, 13, 1, 7), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
mscAtmMpeAcInErrors.setStatus('mandatory')
atm_mpe_group = mib_identifier((1, 3, 6, 1, 4, 1, 562, 36, 2, 2, 65, 1))
atm_mpe_group_ca = mib_identifier((1, 3, 6, 1, 4, 1, 562, 36, 2, 2, 65, 1, 1))
atm_mpe_group_ca02 = mib_identifier((1, 3, 6, 1, 4, 1, 562, 36, 2, 2, 65, 1, 1, 3))
atm_mpe_group_ca02_a = mib_identifier((1, 3, 6, 1, 4, 1, 562, 36, 2, 2, 65, 1, 1, 3, 2))
atm_mpe_capabilities = mib_identifier((1, 3, 6, 1, 4, 1, 562, 36, 2, 2, 65, 3))
atm_mpe_capabilities_ca = mib_identifier((1, 3, 6, 1, 4, 1, 562, 36, 2, 2, 65, 3, 1))
atm_mpe_capabilities_ca02 = mib_identifier((1, 3, 6, 1, 4, 1, 562, 36, 2, 2, 65, 3, 1, 3))
atm_mpe_capabilities_ca02_a = mib_identifier((1, 3, 6, 1, 4, 1, 562, 36, 2, 2, 65, 3, 1, 3, 2))
mibBuilder.exportSymbols('Nortel-MsCarrier-MscPassport-AtmMpeMIB', mscAtmMpeAcIpCoS=mscAtmMpeAcIpCoS, mscAtmMpeIfIndex=mscAtmMpeIfIndex, mscAtmMpeAcOperEntry=mscAtmMpeAcOperEntry, mscAtmMpeAdminState=mscAtmMpeAdminState, mscAtmMpeIfEntryEntry=mscAtmMpeIfEntryEntry, mscAtmMpeIlsForwarder=mscAtmMpeIlsForwarder, mscAtmMpeAcRowStatus=mscAtmMpeAcRowStatus, atmMpeGroup=atmMpeGroup, mscAtmMpeStateEntry=mscAtmMpeStateEntry, mscAtmMpeIfEntryTable=mscAtmMpeIfEntryTable, mscAtmMpeAcOutDiscards=mscAtmMpeAcOutDiscards, mscAtmMpeLinkToProtocolPort=mscAtmMpeLinkToProtocolPort, mscAtmMpeAcSpeed=mscAtmMpeAcSpeed, mscAtmMpeRowStatusEntry=mscAtmMpeRowStatusEntry, mscAtmMpeMaxTransmissionUnit=mscAtmMpeMaxTransmissionUnit, atmMpeCapabilities=atmMpeCapabilities, mscAtmMpeProvEntry=mscAtmMpeProvEntry, mscAtmMpeAcStatsTable=mscAtmMpeAcStatsTable, mscAtmMpeAcRowStatusEntry=mscAtmMpeAcRowStatusEntry, mscAtmMpeAcOutPackets=mscAtmMpeAcOutPackets, mscAtmMpeAcIndex=mscAtmMpeAcIndex, mscAtmMpeMediaProvEntry=mscAtmMpeMediaProvEntry, mscAtmMpeAcAtmConnection=mscAtmMpeAcAtmConnection, mscAtmMpeAcInPackets=mscAtmMpeAcInPackets, mscAtmMpeAcInOctets=mscAtmMpeAcInOctets, atmMpeMIB=atmMpeMIB, mscAtmMpeIndex=mscAtmMpeIndex, mscAtmMpeCustomerIdentifier=mscAtmMpeCustomerIdentifier, atmMpeGroupCA=atmMpeGroupCA, atmMpeCapabilitiesCA=atmMpeCapabilitiesCA, mscAtmMpeAcStateEntry=mscAtmMpeAcStateEntry, mscAtmMpeOperStatusTable=mscAtmMpeOperStatusTable, atmMpeGroupCA02A=atmMpeGroupCA02A, mscAtmMpeEncapType=mscAtmMpeEncapType, mscAtmMpeAcStorageType=mscAtmMpeAcStorageType, mscAtmMpeAc=mscAtmMpeAc, mscAtmMpeOperStatusEntry=mscAtmMpeOperStatusEntry, mscAtmMpeCidDataEntry=mscAtmMpeCidDataEntry, mscAtmMpeProvTable=mscAtmMpeProvTable, mscAtmMpeOperationalState=mscAtmMpeOperationalState, mscAtmMpeComponentName=mscAtmMpeComponentName, mscAtmMpeStorageType=mscAtmMpeStorageType, mscAtmMpeStateTable=mscAtmMpeStateTable, mscAtmMpeAcOperationalState=mscAtmMpeAcOperationalState, mscAtmMpeRowStatus=mscAtmMpeRowStatus, mscAtmMpeAcStateTable=mscAtmMpeAcStateTable, mscAtmMpeAcOutOctets=mscAtmMpeAcOutOctets, mscAtmMpeAcInErrors=mscAtmMpeAcInErrors, mscAtmMpeSnmpOperStatus=mscAtmMpeSnmpOperStatus, atmMpeCapabilitiesCA02A=atmMpeCapabilitiesCA02A, mscAtmMpeRowStatusTable=mscAtmMpeRowStatusTable, mscAtmMpeUsageState=mscAtmMpeUsageState, mscAtmMpeAcInUnknownProtos=mscAtmMpeAcInUnknownProtos, mscAtmMpe=mscAtmMpe, mscAtmMpeCidDataTable=mscAtmMpeCidDataTable, mscAtmMpeAcComponentName=mscAtmMpeAcComponentName, mscAtmMpeAcOperTable=mscAtmMpeAcOperTable, mscAtmMpeAcUsageState=mscAtmMpeAcUsageState, mscAtmMpeAcStatsEntry=mscAtmMpeAcStatsEntry, mscAtmMpeMediaProvTable=mscAtmMpeMediaProvTable, mscAtmMpeAcProvEntry=mscAtmMpeAcProvEntry, atmMpeGroupCA02=atmMpeGroupCA02, atmMpeCapabilitiesCA02=atmMpeCapabilitiesCA02, mscAtmMpeIfAdminStatus=mscAtmMpeIfAdminStatus, mscAtmMpeAcRowStatusTable=mscAtmMpeAcRowStatusTable, mscAtmMpeAcAdminState=mscAtmMpeAcAdminState, mscAtmMpeAcProvTable=mscAtmMpeAcProvTable) |
class IntIdSequence:
def __init__(self):
self.next_id = 0
def __next__(self):
self.next_id += 1
return self.next_id
class RepositoryIterator:
def __init__(self, repo):
self.items = repo.find_all()
self.next_id = -1
def __next__(self):
self.next_id += 1
if self.next_id < len(self.items):
return self.items[self.next_id]
else:
raise StopIteration
class BookRepository:
def __init__(self, books = {}, id_sequence = None):
self.books = books
self.id_sequence = id_sequence
def __len__(self):
return len(self.books)
def __iter__(self):
return RepositoryIterator(self)
def find_all(self):
return list(self.books.values())
def find_by_id(self, id):
return self.books[id]
def find_by_predicate(self, filter_predicate):
return filter(filter_predicate, self.find_all())
def find_by_name_part(self, name_part):
return self.find_by_predicate(lambda book : name_part in book.title)
def find_by_name_descr_part(self, part):
return self.find_by_predicate(lambda book : part in book.title or part in book.descr)
def find_by_authors_part(self, part):
return self.find_by_predicate(lambda book : part in ",".join(book.authors))
def insert(self, book):
if len(str(book.id).strip()) == 0 and self.id_sequence is not None:
book.id = next(self.id_sequence)
self.books[book.id] = book
return book
def update(self, book):
self.books[book.id] = book
return book
def delete_by_id(self, id):
removed = self.books[id]
del self.books[id]
return removed
def count(self):
return self.__len__( self.books)
# return BookRepository.__len__(self, self.books)
| class Intidsequence:
def __init__(self):
self.next_id = 0
def __next__(self):
self.next_id += 1
return self.next_id
class Repositoryiterator:
def __init__(self, repo):
self.items = repo.find_all()
self.next_id = -1
def __next__(self):
self.next_id += 1
if self.next_id < len(self.items):
return self.items[self.next_id]
else:
raise StopIteration
class Bookrepository:
def __init__(self, books={}, id_sequence=None):
self.books = books
self.id_sequence = id_sequence
def __len__(self):
return len(self.books)
def __iter__(self):
return repository_iterator(self)
def find_all(self):
return list(self.books.values())
def find_by_id(self, id):
return self.books[id]
def find_by_predicate(self, filter_predicate):
return filter(filter_predicate, self.find_all())
def find_by_name_part(self, name_part):
return self.find_by_predicate(lambda book: name_part in book.title)
def find_by_name_descr_part(self, part):
return self.find_by_predicate(lambda book: part in book.title or part in book.descr)
def find_by_authors_part(self, part):
return self.find_by_predicate(lambda book: part in ','.join(book.authors))
def insert(self, book):
if len(str(book.id).strip()) == 0 and self.id_sequence is not None:
book.id = next(self.id_sequence)
self.books[book.id] = book
return book
def update(self, book):
self.books[book.id] = book
return book
def delete_by_id(self, id):
removed = self.books[id]
del self.books[id]
return removed
def count(self):
return self.__len__(self.books) |
class InnerWidget:
_index = 0
def __init__(self, master, WidgetClass) -> None:
self.innerWidget = WidgetClass(master)
self.index = self._index
InnerWidget._index += 1
| class Innerwidget:
_index = 0
def __init__(self, master, WidgetClass) -> None:
self.innerWidget = widget_class(master)
self.index = self._index
InnerWidget._index += 1 |
class Language:
def __init__(self, name, extension, macro_prefix,
generated_suffix, columns):
self.name = name
self.extension = extension
self.macro_prefix = macro_prefix
self.generated_suffix = generated_suffix
self.columns = columns
languages = [
Language('Python', '.py', '#SILP:', '#__SILP__\n', 80),
Language('F#', '.fs', '//SILP:', '//__SILP__\n', 80),
Language('C#', '.cs', '//SILP:', '//__SILP__\n', 80),
Language('Go', '.go', '//SILP:', '//__SILP__\n', 80),
Language('Freshrc', '.freshrc', '#SILP:', '#__SILP__\n', 80),
Language('YML', '.yml', '#SILP:', '#__SILP__\n', 80),
Language('Swift', '.swift', '//SILP:', '//__SILP__\n', 80),
Language('Objective-C', '.m', '//SILP:', '//__SILP__\n', 80),
Language('Objective-C++', '.mm', '//SILP:', '//__SILP__\n', 80),
Language('Moonscript', '.moon', '--SILP:', '--__SILP__\n', 80),
Language('Lua', '.lua', '--SILP:', '--__SILP__\n', 80),
Language('Erlang', '.erl', '%SILP:', '%__SILP__\n', 80),
Language('Erlang Include', '.hrl', '%SILP:', '%__SILP__\n', 80),
Language('SQL', '.sql', '-- SILP:', '/*__SILP__*/\n', 80),
Language('CS Proj', '.csproj', '<!--SILP:', '<!--__SILP__-->\n', 80),
Language('Proj Items', '.projitems', '<!--SILP:', '<!--__SILP__-->\n', 80),
Language('Shader', '.shader', '//SILP:', '//__SILP__\n', 80),
Language('TypeScript', '.ts', '//SILP:', '//__SILP__\n', 80),
]
| class Language:
def __init__(self, name, extension, macro_prefix, generated_suffix, columns):
self.name = name
self.extension = extension
self.macro_prefix = macro_prefix
self.generated_suffix = generated_suffix
self.columns = columns
languages = [language('Python', '.py', '#SILP:', '#__SILP__\n', 80), language('F#', '.fs', '//SILP:', '//__SILP__\n', 80), language('C#', '.cs', '//SILP:', '//__SILP__\n', 80), language('Go', '.go', '//SILP:', '//__SILP__\n', 80), language('Freshrc', '.freshrc', '#SILP:', '#__SILP__\n', 80), language('YML', '.yml', '#SILP:', '#__SILP__\n', 80), language('Swift', '.swift', '//SILP:', '//__SILP__\n', 80), language('Objective-C', '.m', '//SILP:', '//__SILP__\n', 80), language('Objective-C++', '.mm', '//SILP:', '//__SILP__\n', 80), language('Moonscript', '.moon', '--SILP:', '--__SILP__\n', 80), language('Lua', '.lua', '--SILP:', '--__SILP__\n', 80), language('Erlang', '.erl', '%SILP:', '%__SILP__\n', 80), language('Erlang Include', '.hrl', '%SILP:', '%__SILP__\n', 80), language('SQL', '.sql', '-- SILP:', '/*__SILP__*/\n', 80), language('CS Proj', '.csproj', '<!--SILP:', '<!--__SILP__-->\n', 80), language('Proj Items', '.projitems', '<!--SILP:', '<!--__SILP__-->\n', 80), language('Shader', '.shader', '//SILP:', '//__SILP__\n', 80), language('TypeScript', '.ts', '//SILP:', '//__SILP__\n', 80)] |
#!/usr/bin/env python
'''
Author : Jonathan Lurie
Email : lurie.jo@gmail.com
Version : 0.1
Licence : MIT
description : Declare some EXIF tag code we will need with piexif.
'''
COPYRIGHT_FIELD = ("0th", 33432)
DESCRIPTION_FIELD = ("0th", 270)
DATE_FIELD = ("0th", 306)
| """
Author : Jonathan Lurie
Email : lurie.jo@gmail.com
Version : 0.1
Licence : MIT
description : Declare some EXIF tag code we will need with piexif.
"""
copyright_field = ('0th', 33432)
description_field = ('0th', 270)
date_field = ('0th', 306) |
class Solution(object):
def threeSum(self, nums):
res = []
amount = [0] * 200001
nums2 = sorted(nums)
for v in nums:
amount[v + 100000] += 1
# 3 different numbers
for i in range(len(nums2)):
if i > 0 and nums2[i] == nums2[i - 1]:
continue
for j in range(i+1, len(nums2)):
if nums2[j] == nums2[i] or nums2[j] == nums2[j - 1]:
continue
diff = 0 - nums2[i] - nums2[j]
if diff <= nums2[j]:
continue
if diff >= -100000 and diff <= 100000 and amount[diff + 100000] >0:
res.append([nums2[i], nums2[j], diff])
# at least two equal numbers
for i in range(len(nums2)):
if i > 0 and nums2[i] == nums2[i - 1]:
continue
if i + 1 < len(nums2) and nums2[i + 1] == nums2[i]:
diff = 0 - nums2[i] - nums2[i]
if diff >= -100000 and diff <= 100000 and (nums2[i] != 0 and amount[diff + 100000] >0 or nums2[i] == 0 and amount[diff + 100000] > 2):
res.append([nums2[i], nums2[i], diff])
return res | class Solution(object):
def three_sum(self, nums):
res = []
amount = [0] * 200001
nums2 = sorted(nums)
for v in nums:
amount[v + 100000] += 1
for i in range(len(nums2)):
if i > 0 and nums2[i] == nums2[i - 1]:
continue
for j in range(i + 1, len(nums2)):
if nums2[j] == nums2[i] or nums2[j] == nums2[j - 1]:
continue
diff = 0 - nums2[i] - nums2[j]
if diff <= nums2[j]:
continue
if diff >= -100000 and diff <= 100000 and (amount[diff + 100000] > 0):
res.append([nums2[i], nums2[j], diff])
for i in range(len(nums2)):
if i > 0 and nums2[i] == nums2[i - 1]:
continue
if i + 1 < len(nums2) and nums2[i + 1] == nums2[i]:
diff = 0 - nums2[i] - nums2[i]
if diff >= -100000 and diff <= 100000 and (nums2[i] != 0 and amount[diff + 100000] > 0 or (nums2[i] == 0 and amount[diff + 100000] > 2)):
res.append([nums2[i], nums2[i], diff])
return res |
class MedianFinder:
def __init__(self):
self.stream = []
self.size = 0
def addNum(self, num: int) -> None:
self.stream.append(num)
self.size += 1
def findMedian(self) -> float:
self.stream.sort()
# first retrieve midpoint of stream
mid = (self.size-1) // 2
# if odd sized datastream can just return mid
if self.size % 2 != 0:
return self.stream[mid]
return (self.stream[mid] + self.stream[mid+1]) / 2
# Your MedianFinder object will be instantiated and called as such:
# obj = MedianFinder()
# obj.addNum(num)
# param_2 = obj.findMedian() | class Medianfinder:
def __init__(self):
self.stream = []
self.size = 0
def add_num(self, num: int) -> None:
self.stream.append(num)
self.size += 1
def find_median(self) -> float:
self.stream.sort()
mid = (self.size - 1) // 2
if self.size % 2 != 0:
return self.stream[mid]
return (self.stream[mid] + self.stream[mid + 1]) / 2 |
def dict_interdiff(d1, d2):
'''
d1, d2: dicts whose keys and values are integers
Returns a tuple of dictionaries according to the instructions above
'''
intersection = {}
difference = {}
shorterDict = (lambda x, y: x if len(x) <= len(y) else y)(d1, d2)
longerDict = (lambda x, y: x if len(x) > len(y) else y)(d1, d2)
for key_s in shorterDict:
if key_s in longerDict:
intersection[key_s] = (lambda x,y: x > y)(d1[key_s], d2[key_s])
else:
difference[key_s] = shorterDict[key_s]
for key_l in longerDict:
if key_l not in intersection:
difference[key_l] = longerDict[key_l]
return (intersection, difference)
| def dict_interdiff(d1, d2):
"""
d1, d2: dicts whose keys and values are integers
Returns a tuple of dictionaries according to the instructions above
"""
intersection = {}
difference = {}
shorter_dict = (lambda x, y: x if len(x) <= len(y) else y)(d1, d2)
longer_dict = (lambda x, y: x if len(x) > len(y) else y)(d1, d2)
for key_s in shorterDict:
if key_s in longerDict:
intersection[key_s] = (lambda x, y: x > y)(d1[key_s], d2[key_s])
else:
difference[key_s] = shorterDict[key_s]
for key_l in longerDict:
if key_l not in intersection:
difference[key_l] = longerDict[key_l]
return (intersection, difference) |
def createFile():
f= open("loginInfo.txt", "w+")
print("Input your username")
f.write(input()+"\n")
print("Input your password")
f.write(input()+"\n")
f.close() | def create_file():
f = open('loginInfo.txt', 'w+')
print('Input your username')
f.write(input() + '\n')
print('Input your password')
f.write(input() + '\n')
f.close() |
class Network(object):
def __init__(self, variables, domains, constraints):
self.variables = variables
self.domains = domains
self.constraints = constraints
def copy(self):
return Network(self.variables,
self.domains.copy(),
self.constraints)
| class Network(object):
def __init__(self, variables, domains, constraints):
self.variables = variables
self.domains = domains
self.constraints = constraints
def copy(self):
return network(self.variables, self.domains.copy(), self.constraints) |
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
def import_data(path):
count = 0
result = []
train_path, train_dirs, train_files = next(os.walk(path))
train_files.sort()
for i in range(len(train_files)):
if "csv" in train_files[i]:
try:
result.append(pd.read_csv(train_path + "/" + train_files[i]))
print(train_files[i] , ": import")
except:
print(train_files[i], " : passed")
pass
else:
print(train_files[i],"is not csv_file")
return result
# train_set1_path, train_set2_path
# ts = time.time()
# set1 = import_data(train_set1_path)
# set2 = import_data(train_set2_path)
# print(time.time() - ts) | def import_data(path):
count = 0
result = []
(train_path, train_dirs, train_files) = next(os.walk(path))
train_files.sort()
for i in range(len(train_files)):
if 'csv' in train_files[i]:
try:
result.append(pd.read_csv(train_path + '/' + train_files[i]))
print(train_files[i], ': import')
except:
print(train_files[i], ' : passed')
pass
else:
print(train_files[i], 'is not csv_file')
return result |
# Copyright (c) 2020 Hartmut Kaiser
#
# SPDX-License-Identifier: BSL-1.0
# Distributed under the Boost Software License, Version 1.0. (See accompanying
# file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
# This cmake-format configuration file is a suggested configuration file for
# formatting CMake files for the HPX project.
# PLEASE NOTE: This file has been created and tested with cmake-format V0.6.10
# -----------------------------
# Options affecting formatting.
# -----------------------------
with section("format"):
# If true, separate function names from parentheses with a space
separate_fn_name_with_space = False
# Format command names consistently as 'lower' or 'upper' case
command_case = u"lower"
# If the statement spelling length (including space and parenthesis) is
# larger
# than the tab width by more than this amount, then force reject un-nested
# layouts.
max_prefix_chars = 10
# If the trailing parenthesis must be 'dangled' on its own line, then align
# it
# to this reference: `prefix`: the start of the statement, `prefix-indent`:
# the start of the statement, plus one indentation level, `child`: align to
# the column of the arguments
dangle_align = u"prefix"
# If an argument group contains more than this many sub-groups (parg or kwarg
# groups) then force it to a vertical layout.
max_subgroups_hwrap = 2
# If the statement spelling length (including space and parenthesis) is
# smaller than this amount, then force reject nested layouts.
min_prefix_chars = 4
# If a positional argument group contains more than this many arguments, then
# force it to a vertical layout.
max_pargs_hwrap = 6
# If a candidate layout is wrapped horizontally but it exceeds this many
# lines, then reject the layout.
max_lines_hwrap = 2
# If true, the parsers may infer whether or not an argument list is sortable
# (without annotation).
autosort = False
# What style line endings to use in the output.
line_ending = u"auto"
# How wide to allow formatted cmake files
line_width = 80
# If a statement is wrapped to more than one line, than dangle the closing
# parenthesis on its own line.
dangle_parens = True
# How many spaces to tab for indent
tab_size = 2
# A list of command names which should always be wrapped
always_wrap = []
# If true, separate flow control names from their parentheses with a space
separate_ctrl_name_with_space = False
# If a cmdline positional group consumes more than this many lines without
# nesting, then invalidate the layout (and nest)
max_rows_cmdline = 2
# By default, if cmake-format cannot successfully fit everything into the
# desired linewidth it will apply the last, most aggressive attempt that it
# made. If this flag is True, however, cmake-format will print error, exit
# with non-zero status code, and write-out nothing
require_valid_layout = False
# Format keywords consistently as 'lower' or 'upper' case
keyword_case = u"unchanged"
# If true, the argument lists which are known to be sortable will be sorted
# lexicographicall
enable_sort = True
# A dictionary mapping layout nodes to a list of wrap decisions. See the
# documentation for more information.
layout_passes = {}
# ------------------------------------------------
# Options affecting comment reflow and formatting.
# ------------------------------------------------
with section("markup"):
# If comment markup is enabled, don't reflow any comment block which matches
# this (regex) pattern. Default is `None` (disabled).
literal_comment_pattern = None
# If a comment line starts with at least this many consecutive hash
# characters, then don't lstrip() them off. This allows for lazy hash rulers
# where the first hash char is not separated by space
hashruler_min_length = 10
# Regular expression to match preformat fences in comments default=
# ``r'^\s*([`~]{3}[`~]*)(.*)$'``
fence_pattern = u"^\\s*([`~]{3}[`~]*)(.*)$"
# If true, then insert a space between the first hash char and remaining hash
# chars in a hash ruler, and normalize its length to fill the column
canonicalize_hashrulers = True
# If a comment line matches starts with this pattern then it is explicitly a
# trailing comment for the preceding argument. Default is '#<'
explicit_trailing_pattern = u"#<"
# If comment markup is enabled, don't reflow the first comment block in each
# listfile. Use this to preserve formatting of your copyright/license
# statements.
first_comment_is_literal = True
# enable comment markup parsing and reflow
enable_markup = True
# Regular expression to match rulers in comments default=
# ``r'^\s*[^\w\s]{3}.*[^\w\s]{3}$'``
ruler_pattern = u"^\\s*[^\\w\\s]{3}.*[^\\w\\s]{3}$"
# What character to use as punctuation after numerals in an enumerated list
enum_char = u"."
# What character to use for bulleted lists
bullet_char = u"*"
# ----------------------------
# Options affecting the linter
# ----------------------------
with section("lint"):
# regular expression pattern describing valid function names
function_pattern = u"[0-9a-z_]+"
# regular expression pattern describing valid names for function/macro
# arguments and loop variables.
argument_var_pattern = u"[a-z][a-z0-9_]+"
# a list of lint codes to disable
disabled_codes = []
# Require at least this many newlines between statements
min_statement_spacing = 1
# regular expression pattern describing valid macro names
macro_pattern = u"[0-9A-Z_]+"
# regular expression pattern describing valid names for public directory
# variables
public_var_pattern = u"[A-Z][0-9A-Z_]+"
max_statements = 50
# In the heuristic for C0201, how many conditionals to match within a loop in
# before considering the loop a parser.
max_conditionals_custom_parser = 2
# regular expression pattern describing valid names for variables with global
# (cache) scope
global_var_pattern = u"[A-Z][0-9A-Z_]+"
# regular expression pattern describing valid names for keywords used in
# functions or macros
keyword_pattern = u"[A-Z][0-9A-Z_]+"
max_arguments = 5
# regular expression pattern describing valid names for privatedirectory
# variables
private_var_pattern = u"_[0-9a-z_]+"
max_localvars = 15
max_branches = 12
# regular expression pattern describing valid names for variables with local
# scope
local_var_pattern = u"[a-z][a-z0-9_]+"
# Require no more than this many newlines between statements
max_statement_spacing = 2
# regular expression pattern describing valid names for variables with global
# scope (but internal semantic)
internal_var_pattern = u"_[A-Z][0-9A-Z_]+"
max_returns = 6
# -------------------------------------
# Miscellaneous configurations options.
# -------------------------------------
with section("misc"):
# A dictionary containing any per-command configuration overrides. Currently
# only `command_case` is supported.
per_command = {}
# ----------------------------------
# Options affecting listfile parsing
# ----------------------------------
with section("parse"):
# Specify structure for custom cmake functions
# (the body of this structure was generated using
# 'cmake-genparsers -f python cmake/HPX*.cmake'
#
additional_commands = {
"hpx_local_add_compile_test": {
"kwargs": {
"DEPENDENCIES": "+",
"FOLDER": 1,
"SOURCES": "+",
"SOURCE_ROOT": 1,
},
"pargs": {"flags": ["FAILURE_EXPECTED", "NOLIBS"], "nargs": "2+"},
},
"hpx_local_add_compile_test_target_dependencies": {
"kwargs": {
"DEPENDENCIES": "+",
"FOLDER": 1,
"SOURCES": "+",
"SOURCE_ROOT": 1,
},
"pargs": {"flags": ["FAILURE_EXPECTED", "NOLIBS"], "nargs": "2+"},
},
"hpx_local_add_config_test": {
"kwargs": {
"ARGS": "+",
"CMAKECXXFEATURE": 1,
"COMPILE_DEFINITIONS": "+",
"DEFINITIONS": "+",
"INCLUDE_DIRECTORIES": "+",
"LIBRARIES": "+",
"LINK_DIRECTORIES": "+",
"REQUIRED": "+",
"ROOT": 1,
"SOURCE": 1,
},
"pargs": {"flags": ["FILE", "EXECUTE"], "nargs": "1+"},
},
"hpx_local_add_example_target_dependencies": {
"kwargs": {},
"pargs": {"flags": ["DEPS_ONLY"], "nargs": "2+"},
},
"hpx_local_add_example_test": {"pargs": {"nargs": 2}},
"hpx_local_add_executable": {
"kwargs": {
"AUXILIARY": "+",
"COMPILE_FLAGS": "+",
"DEPENDENCIES": "+",
"FOLDER": 1,
"HEADERS": "+",
"HEADER_GLOB": 1,
"HEADER_ROOT": 1,
"HPX_PREFIX": 1,
"INI": 1,
"INSTALL_SUFFIX": 1,
"LANGUAGE": 1,
"LINK_FLAGS": "+",
"OUTPUT_SUFFIX": 1,
"SOURCES": "+",
"SOURCE_GLOB": 1,
"SOURCE_ROOT": 1,
},
"pargs": {
"flags": [
"EXCLUDE_FROM_ALL",
"EXCLUDE_FROM_DEFAULT_BUILD",
"AUTOGLOB",
"INTERNAL_FLAGS",
"NOLIBS",
"NOHPX_INIT",
],
"nargs": "1+",
},
},
"hpx_local_add_header_tests": {
"kwargs": {
"DEPENDENCIES": "+",
"EXCLUDE": "+",
"EXCLUDE_FROM_ALL": "+",
"HEADERS": "+",
"HEADER_ROOT": 1,
},
"pargs": {"flags": ["NOLIBS"], "nargs": "1+"},
},
"hpx_local_add_headers_compile_test": {
"kwargs": {
"DEPENDENCIES": "+",
"FOLDER": 1,
"SOURCES": "+",
"SOURCE_ROOT": 1,
},
"pargs": {"flags": ["FAILURE_EXPECTED", "NOLIBS"], "nargs": "2+"},
},
"hpx_local_add_library": {
"kwargs": {
"AUXILIARY": "+",
"COMPILER_FLAGS": "+",
"DEPENDENCIES": "+",
"FOLDER": 1,
"HEADERS": "+",
"HEADER_GLOB": 1,
"HEADER_ROOT": 1,
"INSTALL_SUFFIX": 1,
"LINK_FLAGS": "+",
"OUTPUT_SUFFIX": 1,
"SOURCES": "+",
"SOURCE_GLOB": 1,
"SOURCE_ROOT": 1,
},
"pargs": {
"flags": [
"EXCLUDE_FROM_ALL",
"INTERNAL_FLAGS",
"NOLIBS",
"NOEXPORT",
"AUTOGLOB",
"STATIC",
"NONAMEPREFIX",
],
"nargs": "1+",
},
},
"hpx_local_add_library_headers": {
"kwargs": {"EXCLUDE": "+", "GLOBS": "+"},
"pargs": {"flags": ["APPEND"], "nargs": "2+"},
},
"hpx_local_add_library_headers_noglob": {
"kwargs": {"EXCLUDE": "+", "HEADERS": "+"},
"pargs": {"flags": ["APPEND"], "nargs": "1+"},
},
"hpx_local_add_library_sources": {
"kwargs": {"EXCLUDE": "+", "GLOBS": "+"},
"pargs": {"flags": ["APPEND"], "nargs": "2+"},
},
"hpx_local_add_library_sources_noglob": {
"kwargs": {"EXCLUDE": "+", "SOURCES": "+"},
"pargs": {"flags": ["APPEND"], "nargs": "1+"},
},
"hpx_local_add_module": {
"kwargs": {
"CMAKE_SUBDIRS": "+",
"COMPAT_HEADERS": "+",
"DEPENDENCIES": "+",
"EXCLUDE_FROM_GLOBAL_HEADER": "+",
"GLOBAL_HEADER_GEN": 1,
"HEADERS": "+",
"OBJECTS": "+",
"MODULE_DEPENDENCIES": "+",
"SOURCES": "+",
},
"pargs": {
"flags": ["FORCE_LINKING_GEN", "CUDA", "CONFIG_FILES"],
"nargs": "1+",
},
},
"hpx_local_add_performance_test": {"pargs": {"nargs": 2}},
"hpx_local_add_pseudo_dependencies": {"pargs": {"nargs": 0}},
"hpx_local_add_pseudo_dependencies_no_shortening": {"pargs": {"nargs": 0}},
"hpx_local_add_pseudo_target": {"pargs": {"nargs": 0}},
"hpx_local_add_regression_compile_test": {
"kwargs": {
"DEPENDENCIES": "+",
"FOLDER": 1,
"SOURCES": "+",
"SOURCE_ROOT": 1,
},
"pargs": {"flags": ["FAILURE_EXPECTED", "NOLIBS"], "nargs": "2+"},
},
"hpx_local_add_regression_test": {"pargs": {"nargs": 2}},
"hpx_local_add_source_group": {
"kwargs": {"CLASS": 1, "NAME": 1, "ROOT": 1, "TARGETS": "+"},
"pargs": {"flags": [], "nargs": "*"},
},
"hpx_local_add_test": {
"kwargs": {
"ARGS": "+",
"EXECUTABLE": 1,
"LOCALITIES": 1,
"PARCELPORTS": "+",
"THREADS_PER_LOCALITY": 1,
},
"pargs": {"flags": ["FAILURE_EXPECTED"], "nargs": "2+"},
},
"hpx_local_add_test_target_dependencies": {
"kwargs": {"PSEUDO_DEPS_NAME": 1},
"pargs": {"flags": [], "nargs": "2+"},
},
"hpx_local_add_unit_compile_test": {
"kwargs": {
"DEPENDENCIES": "+",
"FOLDER": 1,
"SOURCES": "+",
"SOURCE_ROOT": 1,
},
"pargs": {"flags": ["FAILURE_EXPECTED", "NOLIBS"], "nargs": "2+"},
},
"hpx_local_add_unit_test": {
"kwargs": {
"DEPENDENCIES": "+",
"FOLDER": 1,
"SOURCES": "+",
"SOURCE_ROOT": 1,
},
"pargs": {"flags": ["FAILURE_EXPECTED", "NOLIBS"], "nargs": "2+"},
},
"hpx_local_add_test_and_deps_compile_test": {
"kwargs": {
"DEPENDENCIES": "+",
"FOLDER": 1,
"SOURCES": "+",
"SOURCE_ROOT": 1,
},
"pargs": {"flags": ["FAILURE_EXPECTED", "NOLIBS"], "nargs": "3+"},
},
"hpx_local_add_test_and_deps_test": {"pargs": {"nargs": 3}},
"hpx_local_create_configuration_summary": {"pargs": {"nargs": 2}},
"hpx_local_create_symbolic_link": {"pargs": {"nargs": 2}},
"hpx_local_get_target_property": {"pargs": {"nargs": 3}},
"hpx_local_add_compile_flag": {"pargs": {"nargs": 0}},
"hpx_local_add_compile_flag_if_available": {
"kwargs": {"CONFIGURATIONS": "+", "LANGUAGES": "+", "NAME": 1},
"pargs": {"flags": [], "nargs": "1+"},
},
"hpx_local_add_config_cond_define": {"pargs": {"nargs": 1}},
"hpx_local_add_config_define": {"pargs": {"nargs": 1}},
"hpx_local_add_config_define_namespace": {
"kwargs": {"DEFINE": 1, "NAMESPACE": 1, "VALUE": "+"},
"pargs": {"flags": [], "nargs": "*"},
},
"hpx_local_add_link_flag": {
"kwargs": {"CONFIGURATIONS": "+", "TARGETS": "+"},
"pargs": {"flags": [], "nargs": "1+"},
},
"hpx_local_add_link_flag_if_available": {
"kwargs": {"NAME": 1, "TARGETS": "+"},
"pargs": {"flags": [], "nargs": "1+"},
},
"hpx_local_add_target_compile_definition": {
"kwargs": {"CONFIGURATIONS": "+"},
"pargs": {"flags": ["PUBLIC"], "nargs": "1+"},
},
"hpx_local_add_target_compile_option": {
"kwargs": {"CONFIGURATIONS": "+", "LANGUAGES": "+"},
"pargs": {"flags": ["PUBLIC"], "nargs": "1+"},
},
"hpx_local_add_target_compile_option_if_available": {
"kwargs": {"CONFIGURATIONS": "+", "LANGUAGES": "+", "NAME": 1},
"pargs": {"flags": ["PUBLIC"], "nargs": "1+"},
},
"hpx_local_append_property": {"pargs": {"nargs": 2}},
"hpx_local_check_for_builtin_integer_pack": {"pargs": {"nargs": 0}},
"hpx_local_check_for_builtin_make_integer_seq": {"pargs": {"nargs": 0}},
"hpx_local_check_for_builtin_type_pack_element": {"pargs": {"nargs": 0}},
"hpx_local_check_for_cxx11_std_atomic": {"pargs": {"nargs": 0}},
"hpx_local_check_for_cxx11_std_atomic_128bit": {"pargs": {"nargs": 0}},
"hpx_local_check_for_cxx11_std_quick_exit": {"pargs": {"nargs": 0}},
"hpx_local_check_for_cxx11_std_shared_ptr_lwg3018": {"pargs": {"nargs": 0}},
"hpx_local_check_for_cxx17_aligned_new": {"pargs": {"nargs": 0}},
"hpx_local_check_for_cxx17_filesystem": {"pargs": {"nargs": 0}},
"hpx_local_check_for_cxx17_hardware_destructive_interference_size": {
"pargs": {"nargs": 0}
},
"hpx_local_check_for_libfun_std_experimental_optional": {"pargs": {"nargs": 0}},
"hpx_local_check_for_mm_prefetch": {"pargs": {"nargs": 0}},
"hpx_local_check_for_stable_inplace_merge": {"pargs": {"nargs": 0}},
"hpx_local_check_for_unistd_h": {"pargs": {"nargs": 0}},
"hpx_local_collect_usage_requirements": {
"kwargs": {"EXCLUDE": "+"},
"pargs": {"flags": [], "nargs": "10+"},
},
"hpx_local_config_loglevel": {"pargs": {"nargs": 2}},
"hpx_local_construct_cflag_list": {"pargs": {"nargs": 6}},
"hpx_local_construct_library_list": {"pargs": {"nargs": 3}},
"hpx_local_cpuid": {"pargs": {"nargs": 2}},
"hpx_local_debug": {"pargs": {"nargs": 0}},
"hpx_local_error": {"pargs": {"nargs": 0}},
"hpx_local_export_modules_targets": {"pargs": {"nargs": 0}},
"hpx_local_export_targets": {"pargs": {"nargs": 0}},
"hpx_local_force_out_of_tree_build": {"pargs": {"nargs": 1}},
"hpx_local_generate_pkgconfig_from_target": {
"kwargs": {"EXCLUDE": "+"},
"pargs": {"flags": [], "nargs": "3+"},
},
"hpx_local_handle_component_dependencies": {"pargs": {"nargs": 1}},
"hpx_local_info": {"pargs": {"nargs": 0}},
"hpx_local_message": {"pargs": {"nargs": 1}},
"hpx_local_option": {
"kwargs": {"CATEGORY": 1, "MODULE": 1, "STRINGS": "+"},
"pargs": {"flags": ["ADVANCED"], "nargs": "4+"},
},
"hpx_local_perform_cxx_feature_tests": {"pargs": {"nargs": 0}},
"hpx_local_print_list": {"pargs": {"nargs": 3}},
"hpx_local_remove_link_flag": {
"kwargs": {"CONFIGURATIONS": "+", "TARGETS": "+"},
"pargs": {"flags": [], "nargs": "1+"},
},
"hpx_local_remove_target_compile_option": {
"kwargs": {"CONFIGURATIONS": "+"},
"pargs": {"flags": ["PUBLIC"], "nargs": "1+"},
},
"hpx_local_sanitize_usage_requirements": {"pargs": {"nargs": 2}},
"hpx_local_set_cmake_policy": {"pargs": {"nargs": 2}},
"hpx_local_set_lib_name": {"pargs": {"nargs": 2}},
"hpx_local_set_option": {
"kwargs": {"HELPSTRING": 1, "TYPE": 1, "VALUE": 1},
"pargs": {"flags": ["FORCE"], "nargs": "1+"},
},
"hpx_local_setup_target": {
"kwargs": {
"COMPILE_FLAGS": "+",
"DEPENDENCIES": "+",
"FOLDER": 1,
"HEADER_ROOT": 1,
"HPX_PREFIX": 1,
"INSTALL_FLAGS": "+",
"INSTALL_PDB": "+",
"LINK_FLAGS": "+",
"NAME": 1,
"SOVERSION": 1,
"TYPE": 1,
"VERSION": 1,
},
"pargs": {
"flags": [
"EXPORT",
"INSTALL",
"INSTALL_HEADERS",
"INTERNAL_FLAGS",
"NOLIBS",
"NONAMEPREFIX",
"NOTLLKEYWORD",
],
"nargs": "1+",
},
},
"hpx_local_warn": {"pargs": {"nargs": 0}},
"hpx_local_setup_mpi": {"pargs": {"nargs": 0}},
"hpx_local_shorten_pseudo_target": {"pargs": {"nargs": 2}},
"hpx_local_write_config_defines_file": {
"kwargs": {"FILENAME": 1, "NAMESPACE": 1, "TEMPLATE": 1},
"pargs": {"flags": [], "nargs": "*"},
},
}
# Specify property tags.
proptags = []
# Specify variable tags.
vartags = []
# -------------------------------
# Options affecting file encoding
# -------------------------------
with section("encode"):
# If true, emit the unicode byte-order mark (BOM) at the start of the file
emit_byteorder_mark = False
# Specify the encoding of the input file. Defaults to utf-8
input_encoding = u"utf-8"
# Specify the encoding of the output file. Defaults to utf-8. Note that
# cmake
# only claims to support utf-8 so be careful when using anything else
output_encoding = u"utf-8"
| with section('format'):
separate_fn_name_with_space = False
command_case = u'lower'
max_prefix_chars = 10
dangle_align = u'prefix'
max_subgroups_hwrap = 2
min_prefix_chars = 4
max_pargs_hwrap = 6
max_lines_hwrap = 2
autosort = False
line_ending = u'auto'
line_width = 80
dangle_parens = True
tab_size = 2
always_wrap = []
separate_ctrl_name_with_space = False
max_rows_cmdline = 2
require_valid_layout = False
keyword_case = u'unchanged'
enable_sort = True
layout_passes = {}
with section('markup'):
literal_comment_pattern = None
hashruler_min_length = 10
fence_pattern = u'^\\s*([`~]{3}[`~]*)(.*)$'
canonicalize_hashrulers = True
explicit_trailing_pattern = u'#<'
first_comment_is_literal = True
enable_markup = True
ruler_pattern = u'^\\s*[^\\w\\s]{3}.*[^\\w\\s]{3}$'
enum_char = u'.'
bullet_char = u'*'
with section('lint'):
function_pattern = u'[0-9a-z_]+'
argument_var_pattern = u'[a-z][a-z0-9_]+'
disabled_codes = []
min_statement_spacing = 1
macro_pattern = u'[0-9A-Z_]+'
public_var_pattern = u'[A-Z][0-9A-Z_]+'
max_statements = 50
max_conditionals_custom_parser = 2
global_var_pattern = u'[A-Z][0-9A-Z_]+'
keyword_pattern = u'[A-Z][0-9A-Z_]+'
max_arguments = 5
private_var_pattern = u'_[0-9a-z_]+'
max_localvars = 15
max_branches = 12
local_var_pattern = u'[a-z][a-z0-9_]+'
max_statement_spacing = 2
internal_var_pattern = u'_[A-Z][0-9A-Z_]+'
max_returns = 6
with section('misc'):
per_command = {}
with section('parse'):
additional_commands = {'hpx_local_add_compile_test': {'kwargs': {'DEPENDENCIES': '+', 'FOLDER': 1, 'SOURCES': '+', 'SOURCE_ROOT': 1}, 'pargs': {'flags': ['FAILURE_EXPECTED', 'NOLIBS'], 'nargs': '2+'}}, 'hpx_local_add_compile_test_target_dependencies': {'kwargs': {'DEPENDENCIES': '+', 'FOLDER': 1, 'SOURCES': '+', 'SOURCE_ROOT': 1}, 'pargs': {'flags': ['FAILURE_EXPECTED', 'NOLIBS'], 'nargs': '2+'}}, 'hpx_local_add_config_test': {'kwargs': {'ARGS': '+', 'CMAKECXXFEATURE': 1, 'COMPILE_DEFINITIONS': '+', 'DEFINITIONS': '+', 'INCLUDE_DIRECTORIES': '+', 'LIBRARIES': '+', 'LINK_DIRECTORIES': '+', 'REQUIRED': '+', 'ROOT': 1, 'SOURCE': 1}, 'pargs': {'flags': ['FILE', 'EXECUTE'], 'nargs': '1+'}}, 'hpx_local_add_example_target_dependencies': {'kwargs': {}, 'pargs': {'flags': ['DEPS_ONLY'], 'nargs': '2+'}}, 'hpx_local_add_example_test': {'pargs': {'nargs': 2}}, 'hpx_local_add_executable': {'kwargs': {'AUXILIARY': '+', 'COMPILE_FLAGS': '+', 'DEPENDENCIES': '+', 'FOLDER': 1, 'HEADERS': '+', 'HEADER_GLOB': 1, 'HEADER_ROOT': 1, 'HPX_PREFIX': 1, 'INI': 1, 'INSTALL_SUFFIX': 1, 'LANGUAGE': 1, 'LINK_FLAGS': '+', 'OUTPUT_SUFFIX': 1, 'SOURCES': '+', 'SOURCE_GLOB': 1, 'SOURCE_ROOT': 1}, 'pargs': {'flags': ['EXCLUDE_FROM_ALL', 'EXCLUDE_FROM_DEFAULT_BUILD', 'AUTOGLOB', 'INTERNAL_FLAGS', 'NOLIBS', 'NOHPX_INIT'], 'nargs': '1+'}}, 'hpx_local_add_header_tests': {'kwargs': {'DEPENDENCIES': '+', 'EXCLUDE': '+', 'EXCLUDE_FROM_ALL': '+', 'HEADERS': '+', 'HEADER_ROOT': 1}, 'pargs': {'flags': ['NOLIBS'], 'nargs': '1+'}}, 'hpx_local_add_headers_compile_test': {'kwargs': {'DEPENDENCIES': '+', 'FOLDER': 1, 'SOURCES': '+', 'SOURCE_ROOT': 1}, 'pargs': {'flags': ['FAILURE_EXPECTED', 'NOLIBS'], 'nargs': '2+'}}, 'hpx_local_add_library': {'kwargs': {'AUXILIARY': '+', 'COMPILER_FLAGS': '+', 'DEPENDENCIES': '+', 'FOLDER': 1, 'HEADERS': '+', 'HEADER_GLOB': 1, 'HEADER_ROOT': 1, 'INSTALL_SUFFIX': 1, 'LINK_FLAGS': '+', 'OUTPUT_SUFFIX': 1, 'SOURCES': '+', 'SOURCE_GLOB': 1, 'SOURCE_ROOT': 1}, 'pargs': {'flags': ['EXCLUDE_FROM_ALL', 'INTERNAL_FLAGS', 'NOLIBS', 'NOEXPORT', 'AUTOGLOB', 'STATIC', 'NONAMEPREFIX'], 'nargs': '1+'}}, 'hpx_local_add_library_headers': {'kwargs': {'EXCLUDE': '+', 'GLOBS': '+'}, 'pargs': {'flags': ['APPEND'], 'nargs': '2+'}}, 'hpx_local_add_library_headers_noglob': {'kwargs': {'EXCLUDE': '+', 'HEADERS': '+'}, 'pargs': {'flags': ['APPEND'], 'nargs': '1+'}}, 'hpx_local_add_library_sources': {'kwargs': {'EXCLUDE': '+', 'GLOBS': '+'}, 'pargs': {'flags': ['APPEND'], 'nargs': '2+'}}, 'hpx_local_add_library_sources_noglob': {'kwargs': {'EXCLUDE': '+', 'SOURCES': '+'}, 'pargs': {'flags': ['APPEND'], 'nargs': '1+'}}, 'hpx_local_add_module': {'kwargs': {'CMAKE_SUBDIRS': '+', 'COMPAT_HEADERS': '+', 'DEPENDENCIES': '+', 'EXCLUDE_FROM_GLOBAL_HEADER': '+', 'GLOBAL_HEADER_GEN': 1, 'HEADERS': '+', 'OBJECTS': '+', 'MODULE_DEPENDENCIES': '+', 'SOURCES': '+'}, 'pargs': {'flags': ['FORCE_LINKING_GEN', 'CUDA', 'CONFIG_FILES'], 'nargs': '1+'}}, 'hpx_local_add_performance_test': {'pargs': {'nargs': 2}}, 'hpx_local_add_pseudo_dependencies': {'pargs': {'nargs': 0}}, 'hpx_local_add_pseudo_dependencies_no_shortening': {'pargs': {'nargs': 0}}, 'hpx_local_add_pseudo_target': {'pargs': {'nargs': 0}}, 'hpx_local_add_regression_compile_test': {'kwargs': {'DEPENDENCIES': '+', 'FOLDER': 1, 'SOURCES': '+', 'SOURCE_ROOT': 1}, 'pargs': {'flags': ['FAILURE_EXPECTED', 'NOLIBS'], 'nargs': '2+'}}, 'hpx_local_add_regression_test': {'pargs': {'nargs': 2}}, 'hpx_local_add_source_group': {'kwargs': {'CLASS': 1, 'NAME': 1, 'ROOT': 1, 'TARGETS': '+'}, 'pargs': {'flags': [], 'nargs': '*'}}, 'hpx_local_add_test': {'kwargs': {'ARGS': '+', 'EXECUTABLE': 1, 'LOCALITIES': 1, 'PARCELPORTS': '+', 'THREADS_PER_LOCALITY': 1}, 'pargs': {'flags': ['FAILURE_EXPECTED'], 'nargs': '2+'}}, 'hpx_local_add_test_target_dependencies': {'kwargs': {'PSEUDO_DEPS_NAME': 1}, 'pargs': {'flags': [], 'nargs': '2+'}}, 'hpx_local_add_unit_compile_test': {'kwargs': {'DEPENDENCIES': '+', 'FOLDER': 1, 'SOURCES': '+', 'SOURCE_ROOT': 1}, 'pargs': {'flags': ['FAILURE_EXPECTED', 'NOLIBS'], 'nargs': '2+'}}, 'hpx_local_add_unit_test': {'kwargs': {'DEPENDENCIES': '+', 'FOLDER': 1, 'SOURCES': '+', 'SOURCE_ROOT': 1}, 'pargs': {'flags': ['FAILURE_EXPECTED', 'NOLIBS'], 'nargs': '2+'}}, 'hpx_local_add_test_and_deps_compile_test': {'kwargs': {'DEPENDENCIES': '+', 'FOLDER': 1, 'SOURCES': '+', 'SOURCE_ROOT': 1}, 'pargs': {'flags': ['FAILURE_EXPECTED', 'NOLIBS'], 'nargs': '3+'}}, 'hpx_local_add_test_and_deps_test': {'pargs': {'nargs': 3}}, 'hpx_local_create_configuration_summary': {'pargs': {'nargs': 2}}, 'hpx_local_create_symbolic_link': {'pargs': {'nargs': 2}}, 'hpx_local_get_target_property': {'pargs': {'nargs': 3}}, 'hpx_local_add_compile_flag': {'pargs': {'nargs': 0}}, 'hpx_local_add_compile_flag_if_available': {'kwargs': {'CONFIGURATIONS': '+', 'LANGUAGES': '+', 'NAME': 1}, 'pargs': {'flags': [], 'nargs': '1+'}}, 'hpx_local_add_config_cond_define': {'pargs': {'nargs': 1}}, 'hpx_local_add_config_define': {'pargs': {'nargs': 1}}, 'hpx_local_add_config_define_namespace': {'kwargs': {'DEFINE': 1, 'NAMESPACE': 1, 'VALUE': '+'}, 'pargs': {'flags': [], 'nargs': '*'}}, 'hpx_local_add_link_flag': {'kwargs': {'CONFIGURATIONS': '+', 'TARGETS': '+'}, 'pargs': {'flags': [], 'nargs': '1+'}}, 'hpx_local_add_link_flag_if_available': {'kwargs': {'NAME': 1, 'TARGETS': '+'}, 'pargs': {'flags': [], 'nargs': '1+'}}, 'hpx_local_add_target_compile_definition': {'kwargs': {'CONFIGURATIONS': '+'}, 'pargs': {'flags': ['PUBLIC'], 'nargs': '1+'}}, 'hpx_local_add_target_compile_option': {'kwargs': {'CONFIGURATIONS': '+', 'LANGUAGES': '+'}, 'pargs': {'flags': ['PUBLIC'], 'nargs': '1+'}}, 'hpx_local_add_target_compile_option_if_available': {'kwargs': {'CONFIGURATIONS': '+', 'LANGUAGES': '+', 'NAME': 1}, 'pargs': {'flags': ['PUBLIC'], 'nargs': '1+'}}, 'hpx_local_append_property': {'pargs': {'nargs': 2}}, 'hpx_local_check_for_builtin_integer_pack': {'pargs': {'nargs': 0}}, 'hpx_local_check_for_builtin_make_integer_seq': {'pargs': {'nargs': 0}}, 'hpx_local_check_for_builtin_type_pack_element': {'pargs': {'nargs': 0}}, 'hpx_local_check_for_cxx11_std_atomic': {'pargs': {'nargs': 0}}, 'hpx_local_check_for_cxx11_std_atomic_128bit': {'pargs': {'nargs': 0}}, 'hpx_local_check_for_cxx11_std_quick_exit': {'pargs': {'nargs': 0}}, 'hpx_local_check_for_cxx11_std_shared_ptr_lwg3018': {'pargs': {'nargs': 0}}, 'hpx_local_check_for_cxx17_aligned_new': {'pargs': {'nargs': 0}}, 'hpx_local_check_for_cxx17_filesystem': {'pargs': {'nargs': 0}}, 'hpx_local_check_for_cxx17_hardware_destructive_interference_size': {'pargs': {'nargs': 0}}, 'hpx_local_check_for_libfun_std_experimental_optional': {'pargs': {'nargs': 0}}, 'hpx_local_check_for_mm_prefetch': {'pargs': {'nargs': 0}}, 'hpx_local_check_for_stable_inplace_merge': {'pargs': {'nargs': 0}}, 'hpx_local_check_for_unistd_h': {'pargs': {'nargs': 0}}, 'hpx_local_collect_usage_requirements': {'kwargs': {'EXCLUDE': '+'}, 'pargs': {'flags': [], 'nargs': '10+'}}, 'hpx_local_config_loglevel': {'pargs': {'nargs': 2}}, 'hpx_local_construct_cflag_list': {'pargs': {'nargs': 6}}, 'hpx_local_construct_library_list': {'pargs': {'nargs': 3}}, 'hpx_local_cpuid': {'pargs': {'nargs': 2}}, 'hpx_local_debug': {'pargs': {'nargs': 0}}, 'hpx_local_error': {'pargs': {'nargs': 0}}, 'hpx_local_export_modules_targets': {'pargs': {'nargs': 0}}, 'hpx_local_export_targets': {'pargs': {'nargs': 0}}, 'hpx_local_force_out_of_tree_build': {'pargs': {'nargs': 1}}, 'hpx_local_generate_pkgconfig_from_target': {'kwargs': {'EXCLUDE': '+'}, 'pargs': {'flags': [], 'nargs': '3+'}}, 'hpx_local_handle_component_dependencies': {'pargs': {'nargs': 1}}, 'hpx_local_info': {'pargs': {'nargs': 0}}, 'hpx_local_message': {'pargs': {'nargs': 1}}, 'hpx_local_option': {'kwargs': {'CATEGORY': 1, 'MODULE': 1, 'STRINGS': '+'}, 'pargs': {'flags': ['ADVANCED'], 'nargs': '4+'}}, 'hpx_local_perform_cxx_feature_tests': {'pargs': {'nargs': 0}}, 'hpx_local_print_list': {'pargs': {'nargs': 3}}, 'hpx_local_remove_link_flag': {'kwargs': {'CONFIGURATIONS': '+', 'TARGETS': '+'}, 'pargs': {'flags': [], 'nargs': '1+'}}, 'hpx_local_remove_target_compile_option': {'kwargs': {'CONFIGURATIONS': '+'}, 'pargs': {'flags': ['PUBLIC'], 'nargs': '1+'}}, 'hpx_local_sanitize_usage_requirements': {'pargs': {'nargs': 2}}, 'hpx_local_set_cmake_policy': {'pargs': {'nargs': 2}}, 'hpx_local_set_lib_name': {'pargs': {'nargs': 2}}, 'hpx_local_set_option': {'kwargs': {'HELPSTRING': 1, 'TYPE': 1, 'VALUE': 1}, 'pargs': {'flags': ['FORCE'], 'nargs': '1+'}}, 'hpx_local_setup_target': {'kwargs': {'COMPILE_FLAGS': '+', 'DEPENDENCIES': '+', 'FOLDER': 1, 'HEADER_ROOT': 1, 'HPX_PREFIX': 1, 'INSTALL_FLAGS': '+', 'INSTALL_PDB': '+', 'LINK_FLAGS': '+', 'NAME': 1, 'SOVERSION': 1, 'TYPE': 1, 'VERSION': 1}, 'pargs': {'flags': ['EXPORT', 'INSTALL', 'INSTALL_HEADERS', 'INTERNAL_FLAGS', 'NOLIBS', 'NONAMEPREFIX', 'NOTLLKEYWORD'], 'nargs': '1+'}}, 'hpx_local_warn': {'pargs': {'nargs': 0}}, 'hpx_local_setup_mpi': {'pargs': {'nargs': 0}}, 'hpx_local_shorten_pseudo_target': {'pargs': {'nargs': 2}}, 'hpx_local_write_config_defines_file': {'kwargs': {'FILENAME': 1, 'NAMESPACE': 1, 'TEMPLATE': 1}, 'pargs': {'flags': [], 'nargs': '*'}}}
proptags = []
vartags = []
with section('encode'):
emit_byteorder_mark = False
input_encoding = u'utf-8'
output_encoding = u'utf-8' |
def Solve(N,A):
# write your code here
# return your answer
min_diff, res_dict = None, dict()
for i in A:
if i==0:
return 0
sign = -1 if i<0 else 1
min_diff = i*sign if min_diff is None else min(i*sign, min_diff)
if min_diff==(i*sign):
if (min_diff) in res_dict:
res_dict[min_diff] = i if res_dict[min_diff]<i else res_dict[min_diff]
else:
res_dict[min_diff] = i
return res_dict[min_diff]
N = int(input())
A = list(map(int,input().split()))
out_ = Solve(N,A)
print(out_) | def solve(N, A):
(min_diff, res_dict) = (None, dict())
for i in A:
if i == 0:
return 0
sign = -1 if i < 0 else 1
min_diff = i * sign if min_diff is None else min(i * sign, min_diff)
if min_diff == i * sign:
if min_diff in res_dict:
res_dict[min_diff] = i if res_dict[min_diff] < i else res_dict[min_diff]
else:
res_dict[min_diff] = i
return res_dict[min_diff]
n = int(input())
a = list(map(int, input().split()))
out_ = solve(N, A)
print(out_) |
def maior(* num):
cont = 0
for valor in num:
cont = cont + 1
if cont == 1:
maiore = valor
else:
if valor > maiore:
maiore = valor
print(f'analizando os valores passados.....')
print(f'{num} foram informados {len(num)} ao todo.')
print(f'o maior valor informado foi {maiore}')
maior(9, 74, 20, 13, 17)
| def maior(*num):
cont = 0
for valor in num:
cont = cont + 1
if cont == 1:
maiore = valor
elif valor > maiore:
maiore = valor
print(f'analizando os valores passados.....')
print(f'{num} foram informados {len(num)} ao todo.')
print(f'o maior valor informado foi {maiore}')
maior(9, 74, 20, 13, 17) |
#
# PySNMP MIB module ZYXEL-OUT-OF-BAND-MIB (http://snmplabs.com/pysmi)
# ASN.1 source file:///Users/davwang4/Dev/mibs.snmplabs.com/asn1/ZYXEL-OUT-OF-BAND-MIB
# Produced by pysmi-0.3.4 at Mon Apr 29 21:45:06 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)
#
Integer, ObjectIdentifier, OctetString = mibBuilder.importSymbols("ASN1", "Integer", "ObjectIdentifier", "OctetString")
NamedValues, = mibBuilder.importSymbols("ASN1-ENUMERATION", "NamedValues")
ValueSizeConstraint, ValueRangeConstraint, ConstraintsIntersection, ConstraintsUnion, SingleValueConstraint = mibBuilder.importSymbols("ASN1-REFINEMENT", "ValueSizeConstraint", "ValueRangeConstraint", "ConstraintsIntersection", "ConstraintsUnion", "SingleValueConstraint")
ModuleCompliance, NotificationGroup = mibBuilder.importSymbols("SNMPv2-CONF", "ModuleCompliance", "NotificationGroup")
ModuleIdentity, Counter32, Unsigned32, iso, ObjectIdentity, IpAddress, TimeTicks, Gauge32, Integer32, Bits, NotificationType, MibIdentifier, Counter64, MibScalar, MibTable, MibTableRow, MibTableColumn = mibBuilder.importSymbols("SNMPv2-SMI", "ModuleIdentity", "Counter32", "Unsigned32", "iso", "ObjectIdentity", "IpAddress", "TimeTicks", "Gauge32", "Integer32", "Bits", "NotificationType", "MibIdentifier", "Counter64", "MibScalar", "MibTable", "MibTableRow", "MibTableColumn")
TextualConvention, DisplayString = mibBuilder.importSymbols("SNMPv2-TC", "TextualConvention", "DisplayString")
esMgmt, = mibBuilder.importSymbols("ZYXEL-ES-SMI", "esMgmt")
zyxelOutOfBand = ModuleIdentity((1, 3, 6, 1, 4, 1, 890, 1, 15, 3, 58))
if mibBuilder.loadTexts: zyxelOutOfBand.setLastUpdated('201207010000Z')
if mibBuilder.loadTexts: zyxelOutOfBand.setOrganization('Enterprise Solution ZyXEL')
zyxelOutOfBandIpSetup = MibIdentifier((1, 3, 6, 1, 4, 1, 890, 1, 15, 3, 58, 1))
zyOutOfBandIpAddress = MibScalar((1, 3, 6, 1, 4, 1, 890, 1, 15, 3, 58, 1, 1), IpAddress()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: zyOutOfBandIpAddress.setStatus('current')
zyOutOfBandSubnetMask = MibScalar((1, 3, 6, 1, 4, 1, 890, 1, 15, 3, 58, 1, 2), IpAddress()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: zyOutOfBandSubnetMask.setStatus('current')
zyOutOfBandGateway = MibScalar((1, 3, 6, 1, 4, 1, 890, 1, 15, 3, 58, 1, 3), IpAddress()).setMaxAccess("readwrite")
if mibBuilder.loadTexts: zyOutOfBandGateway.setStatus('current')
mibBuilder.exportSymbols("ZYXEL-OUT-OF-BAND-MIB", zyOutOfBandGateway=zyOutOfBandGateway, zyOutOfBandSubnetMask=zyOutOfBandSubnetMask, zyxelOutOfBand=zyxelOutOfBand, zyOutOfBandIpAddress=zyOutOfBandIpAddress, PYSNMP_MODULE_ID=zyxelOutOfBand, zyxelOutOfBandIpSetup=zyxelOutOfBandIpSetup)
| (integer, object_identifier, octet_string) = mibBuilder.importSymbols('ASN1', 'Integer', 'ObjectIdentifier', 'OctetString')
(named_values,) = mibBuilder.importSymbols('ASN1-ENUMERATION', 'NamedValues')
(value_size_constraint, value_range_constraint, constraints_intersection, constraints_union, single_value_constraint) = mibBuilder.importSymbols('ASN1-REFINEMENT', 'ValueSizeConstraint', 'ValueRangeConstraint', 'ConstraintsIntersection', 'ConstraintsUnion', 'SingleValueConstraint')
(module_compliance, notification_group) = mibBuilder.importSymbols('SNMPv2-CONF', 'ModuleCompliance', 'NotificationGroup')
(module_identity, counter32, unsigned32, iso, object_identity, ip_address, time_ticks, gauge32, integer32, bits, notification_type, mib_identifier, counter64, mib_scalar, mib_table, mib_table_row, mib_table_column) = mibBuilder.importSymbols('SNMPv2-SMI', 'ModuleIdentity', 'Counter32', 'Unsigned32', 'iso', 'ObjectIdentity', 'IpAddress', 'TimeTicks', 'Gauge32', 'Integer32', 'Bits', 'NotificationType', 'MibIdentifier', 'Counter64', 'MibScalar', 'MibTable', 'MibTableRow', 'MibTableColumn')
(textual_convention, display_string) = mibBuilder.importSymbols('SNMPv2-TC', 'TextualConvention', 'DisplayString')
(es_mgmt,) = mibBuilder.importSymbols('ZYXEL-ES-SMI', 'esMgmt')
zyxel_out_of_band = module_identity((1, 3, 6, 1, 4, 1, 890, 1, 15, 3, 58))
if mibBuilder.loadTexts:
zyxelOutOfBand.setLastUpdated('201207010000Z')
if mibBuilder.loadTexts:
zyxelOutOfBand.setOrganization('Enterprise Solution ZyXEL')
zyxel_out_of_band_ip_setup = mib_identifier((1, 3, 6, 1, 4, 1, 890, 1, 15, 3, 58, 1))
zy_out_of_band_ip_address = mib_scalar((1, 3, 6, 1, 4, 1, 890, 1, 15, 3, 58, 1, 1), ip_address()).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
zyOutOfBandIpAddress.setStatus('current')
zy_out_of_band_subnet_mask = mib_scalar((1, 3, 6, 1, 4, 1, 890, 1, 15, 3, 58, 1, 2), ip_address()).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
zyOutOfBandSubnetMask.setStatus('current')
zy_out_of_band_gateway = mib_scalar((1, 3, 6, 1, 4, 1, 890, 1, 15, 3, 58, 1, 3), ip_address()).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
zyOutOfBandGateway.setStatus('current')
mibBuilder.exportSymbols('ZYXEL-OUT-OF-BAND-MIB', zyOutOfBandGateway=zyOutOfBandGateway, zyOutOfBandSubnetMask=zyOutOfBandSubnetMask, zyxelOutOfBand=zyxelOutOfBand, zyOutOfBandIpAddress=zyOutOfBandIpAddress, PYSNMP_MODULE_ID=zyxelOutOfBand, zyxelOutOfBandIpSetup=zyxelOutOfBandIpSetup) |
# -*- coding: utf-8 -*-
YEAR_CHOICES = (
('', '---------'),
('1', 'Freshman'),
('2', 'Sophmore'),
('3', 'Junior'),
('4', 'Senior'),
)
GRADUATE_DEGREE = (
('M.S.', 'M.S.'),
('Ph.D', 'Ph.D'),
('M.D.', 'M.D.'),
('Other', 'Other'),
)
GRANTS_PROCESS_STAGES = (
('', '---------'),
('Pre-Award (Application Process)', 'Pre-Award (Application Process)'),
(
'Post-Award (Award Acceptance/Grant Management)',
'Post-Award (Award Acceptance/Grant Management)',
),
('Both', 'Both'),
)
UNDERGRADUATE_DEGREE = (
("Bachelor's degree", "Bachelor's degree"),
("Associate's degree/certificate", "Associate's degree/certificate"),
)
WSGC_SCHOOL = (
('Alverno College', 'Alverno College'),
('Carthage College', 'Carthage College'),
('Chief Dull Knife College', 'Chief Dull Knife College'),
('College of Menominee Nation', 'College of Menominee Nation'),
('Colorado School of Mines', 'Colorado School of Mines'),
('Concordia University', 'Concordia University'),
('Lawrence University', 'Lawrence University'),
('Leech Lake Tribal College', 'Leech Lake Tribal College'),
('Little Big Horn College', 'Little Big Horn College'),
('Marquette University', 'Marquette University'),
('Medical College of Wisconsin', 'Medical College of Wisconsin'),
('Milwaukee School of Engineering', 'Milwaukee School of Engineering'),
('Moraine Park Technical College', 'Moraine Park Technical College'),
('Northern Arizona University', 'Northern Arizona University'),
('Northwest Indian College', 'Northwest Indian College'),
('Ripon College', 'Ripon College'),
('St. Norbert College', 'St. Norbert College'),
('Turtle Mountain Community College', 'Turtle Mountain Community College'),
('University of Alaska-Fairbanks', 'University of Alaska-Fairbanks'),
('University of California-Los Angeles', 'University of California-Los Angeles'),
('UW Fox Valley', 'UW Fox Valley'),
('UW Green Bay', 'UW Green Bay'),
('UW LaCrosse', 'UW LaCrosse'),
('UW Madison', 'UW Madison'),
('UW Milwaukee', 'UW Milwaukee'),
('UW Oshkosh', 'UW Oshkosh'),
('UW Parkside', 'UW Parkside'),
('UW Platteville', 'UW Platteville'),
('UW River Falls', 'UW River Falls'),
('UW Sheboygan', 'UW Sheboygan'),
('UW Stevens Point', 'UW Stevens Point'),
('UW Stout', 'UW Stout'),
('UW Superior', 'UW Superior'),
('UW Washington County', 'UW Washington County'),
('UW Whitewater', 'UW Whitewater'),
('Utah State University-Eastern Blanding', 'Utah State University-Eastern Blanding'),
('Western Technical College', 'Western Technical College'),
('Wisconsin Lutheran College', 'Wisconsin Lutheran College'),
('Other', 'Other'),
)
MAJORS = (
('Aeronautical Engineering', 'Aeronautical Engineering'),
('Aerospace Engineering', 'Aerospace Engineering'),
('Applied Physics', 'Applied Physics'),
('Astronomy', 'Astronomy'),
('Astrophysics', 'Astrophysics'),
('Atmoshperic Sciences', 'Atmoshperic Sciences'),
('Biochemistry', 'Biochemistry'),
('Biology', 'Biology'),
('Biomedical Engineering', 'Biomedical Engineering'),
('Biomedical Science', 'Biomedical Science'),
('Biophysics', 'Biophysics'),
('Biotechnology', 'Biotechnology'),
('Chemical Engineering', 'Chemical Engineering'),
('Chemistry', 'Chemistry'),
('Civil Engineering', 'Civil Engineering'),
('Computer Engineering', 'Computer Engineering'),
('Computer Science', 'Computer Science'),
('Electrical Engineering', 'Electrical Engineering'),
('Environmental Science', 'Environmental Science'),
('Environmental Studies', 'Environmental Studies'),
('Geography', 'Geography'),
('Geology', 'Geology'),
('Geophysics', 'Geophysics'),
('Geoscience', 'Geoscience'),
('Industrial Engineering', 'Industrial Engineering'),
('Kinesiology', 'Kinesiology'),
('Mathematics', 'Mathematics'),
('Mechanical Engineering', 'Mechanical Engineering'),
('Meteorology', 'Meteorology'),
('Microbiology', 'Microbiology'),
('Molecular and Cell Biology', 'Molecular and Cell Biology'),
(
'Molecular and Environmental Plant Science',
'Molecular and Environmental Plant Science',
),
('Neuroscience', 'Neuroscience'),
('Nuclear Engineering', 'Nuclear Engineering'),
('Oceanography', 'Oceanography'),
('Other', 'Other'),
('Physics', 'Physics'),
('Statistics', 'Statistics'),
('Systems Engineering', 'Systems Engineering'),
)
PROGRAM_CHOICES = (
('AerospaceOutreach', 'Aerospace Outreach'),
('ClarkGraduateFellowship', 'Dr. Laurel Salton Clark Memorial Research Fellowship'),
('CollegiateRocketCompetition', 'Collegiate Rocket Competition'),
('EarlyStageInvestigator', 'Early-Stage Investigator'),
('FirstNationsRocketCompetition', 'First Nations Rocket Competition'),
('GraduateFellowship', 'WSGC Graduate and Professional Research Fellowship'),
('HighAltitudeBalloonLaunch', 'High Altitude Balloon Launch'),
('HighAltitudeBalloonPayload', 'High Altitude Balloon Payload'),
('HigherEducationInitiatives', 'Higher Education Initiatives'),
('IndustryInternship', 'Industry Internship'),
('MidwestHighPoweredRocketCompetition', 'Midwest High Powered Rocket Competition'),
('NasaCompetition', 'NASA Competition'),
('ProfessionalProgramStudent', 'Professional Program Student'),
('ResearchInfrastructure', 'Research Infrastructure'),
('RocketLaunchTeam', 'Rocket Launch Team'),
('SpecialInitiatives', 'Special Initiatives'),
('StemBridgeScholarship', 'STEM Bridge Scholarship'),
('UndergraduateResearch', 'Undergraduate Research Fellowship'),
('UndergraduateScholarship', 'Undergraduate Scholarship'),
(
'UnmannedAerialVehiclesResearchScholarship',
'Unmanned Aerial Vehicles Research Scholarship',
),
('WomenInAviationScholarship', 'Women in Aviation Scholarship'),
)
| year_choices = (('', '---------'), ('1', 'Freshman'), ('2', 'Sophmore'), ('3', 'Junior'), ('4', 'Senior'))
graduate_degree = (('M.S.', 'M.S.'), ('Ph.D', 'Ph.D'), ('M.D.', 'M.D.'), ('Other', 'Other'))
grants_process_stages = (('', '---------'), ('Pre-Award (Application Process)', 'Pre-Award (Application Process)'), ('Post-Award (Award Acceptance/Grant Management)', 'Post-Award (Award Acceptance/Grant Management)'), ('Both', 'Both'))
undergraduate_degree = (("Bachelor's degree", "Bachelor's degree"), ("Associate's degree/certificate", "Associate's degree/certificate"))
wsgc_school = (('Alverno College', 'Alverno College'), ('Carthage College', 'Carthage College'), ('Chief Dull Knife College', 'Chief Dull Knife College'), ('College of Menominee Nation', 'College of Menominee Nation'), ('Colorado School of Mines', 'Colorado School of Mines'), ('Concordia University', 'Concordia University'), ('Lawrence University', 'Lawrence University'), ('Leech Lake Tribal College', 'Leech Lake Tribal College'), ('Little Big Horn College', 'Little Big Horn College'), ('Marquette University', 'Marquette University'), ('Medical College of Wisconsin', 'Medical College of Wisconsin'), ('Milwaukee School of Engineering', 'Milwaukee School of Engineering'), ('Moraine Park Technical College', 'Moraine Park Technical College'), ('Northern Arizona University', 'Northern Arizona University'), ('Northwest Indian College', 'Northwest Indian College'), ('Ripon College', 'Ripon College'), ('St. Norbert College', 'St. Norbert College'), ('Turtle Mountain Community College', 'Turtle Mountain Community College'), ('University of Alaska-Fairbanks', 'University of Alaska-Fairbanks'), ('University of California-Los Angeles', 'University of California-Los Angeles'), ('UW Fox Valley', 'UW Fox Valley'), ('UW Green Bay', 'UW Green Bay'), ('UW LaCrosse', 'UW LaCrosse'), ('UW Madison', 'UW Madison'), ('UW Milwaukee', 'UW Milwaukee'), ('UW Oshkosh', 'UW Oshkosh'), ('UW Parkside', 'UW Parkside'), ('UW Platteville', 'UW Platteville'), ('UW River Falls', 'UW River Falls'), ('UW Sheboygan', 'UW Sheboygan'), ('UW Stevens Point', 'UW Stevens Point'), ('UW Stout', 'UW Stout'), ('UW Superior', 'UW Superior'), ('UW Washington County', 'UW Washington County'), ('UW Whitewater', 'UW Whitewater'), ('Utah State University-Eastern Blanding', 'Utah State University-Eastern Blanding'), ('Western Technical College', 'Western Technical College'), ('Wisconsin Lutheran College', 'Wisconsin Lutheran College'), ('Other', 'Other'))
majors = (('Aeronautical Engineering', 'Aeronautical Engineering'), ('Aerospace Engineering', 'Aerospace Engineering'), ('Applied Physics', 'Applied Physics'), ('Astronomy', 'Astronomy'), ('Astrophysics', 'Astrophysics'), ('Atmoshperic Sciences', 'Atmoshperic Sciences'), ('Biochemistry', 'Biochemistry'), ('Biology', 'Biology'), ('Biomedical Engineering', 'Biomedical Engineering'), ('Biomedical Science', 'Biomedical Science'), ('Biophysics', 'Biophysics'), ('Biotechnology', 'Biotechnology'), ('Chemical Engineering', 'Chemical Engineering'), ('Chemistry', 'Chemistry'), ('Civil Engineering', 'Civil Engineering'), ('Computer Engineering', 'Computer Engineering'), ('Computer Science', 'Computer Science'), ('Electrical Engineering', 'Electrical Engineering'), ('Environmental Science', 'Environmental Science'), ('Environmental Studies', 'Environmental Studies'), ('Geography', 'Geography'), ('Geology', 'Geology'), ('Geophysics', 'Geophysics'), ('Geoscience', 'Geoscience'), ('Industrial Engineering', 'Industrial Engineering'), ('Kinesiology', 'Kinesiology'), ('Mathematics', 'Mathematics'), ('Mechanical Engineering', 'Mechanical Engineering'), ('Meteorology', 'Meteorology'), ('Microbiology', 'Microbiology'), ('Molecular and Cell Biology', 'Molecular and Cell Biology'), ('Molecular and Environmental Plant Science', 'Molecular and Environmental Plant Science'), ('Neuroscience', 'Neuroscience'), ('Nuclear Engineering', 'Nuclear Engineering'), ('Oceanography', 'Oceanography'), ('Other', 'Other'), ('Physics', 'Physics'), ('Statistics', 'Statistics'), ('Systems Engineering', 'Systems Engineering'))
program_choices = (('AerospaceOutreach', 'Aerospace Outreach'), ('ClarkGraduateFellowship', 'Dr. Laurel Salton Clark Memorial Research Fellowship'), ('CollegiateRocketCompetition', 'Collegiate Rocket Competition'), ('EarlyStageInvestigator', 'Early-Stage Investigator'), ('FirstNationsRocketCompetition', 'First Nations Rocket Competition'), ('GraduateFellowship', 'WSGC Graduate and Professional Research Fellowship'), ('HighAltitudeBalloonLaunch', 'High Altitude Balloon Launch'), ('HighAltitudeBalloonPayload', 'High Altitude Balloon Payload'), ('HigherEducationInitiatives', 'Higher Education Initiatives'), ('IndustryInternship', 'Industry Internship'), ('MidwestHighPoweredRocketCompetition', 'Midwest High Powered Rocket Competition'), ('NasaCompetition', 'NASA Competition'), ('ProfessionalProgramStudent', 'Professional Program Student'), ('ResearchInfrastructure', 'Research Infrastructure'), ('RocketLaunchTeam', 'Rocket Launch Team'), ('SpecialInitiatives', 'Special Initiatives'), ('StemBridgeScholarship', 'STEM Bridge Scholarship'), ('UndergraduateResearch', 'Undergraduate Research Fellowship'), ('UndergraduateScholarship', 'Undergraduate Scholarship'), ('UnmannedAerialVehiclesResearchScholarship', 'Unmanned Aerial Vehicles Research Scholarship'), ('WomenInAviationScholarship', 'Women in Aviation Scholarship')) |
legacy_dummy_settings = {
"name": "Rosalind Franklin",
"version": 42,
"steps_per_mm": "M92 X80.00 Y80.00 Z400 A400 B768 C768",
"gantry_steps_per_mm": {"X": 80.00, "Y": 80.00, "Z": 400, "A": 400},
"acceleration": {"X": 3, "Y": 2, "Z": 15, "A": 15, "B": 2, "C": 2},
"z_retract_distance": 2,
"tip_length": 999,
"left_mount_offset": [-34, 0, 0],
"serial_speed": 888,
"default_current": {"X": 1, "Y": 2, "Z": 3, "A": 4, "B": 5, "C": 6},
"low_current": {"X": 1, "Y": 2, "Z": 3, "A": 4, "B": 5, "C": 6},
"high_current": {"X": 1, "Y": 2, "Z": 3, "A": 4, "B": 5, "C": 6},
"default_max_speed": {"X": 1, "Y": 2, "Z": 3, "A": 4, "B": 5, "C": 6},
"default_pipette_configs": {
"homePosition": 220,
"maxTravel": 30,
"stepsPerMM": 768,
},
"log_level": "NADA",
}
migrated_dummy_settings = {
"name": "Rosalind Franklin",
"version": 4,
"gantry_steps_per_mm": {"X": 80.0, "Y": 80.0, "Z": 400.0, "A": 400.0},
"acceleration": {"X": 3, "Y": 2, "Z": 15, "A": 15, "B": 2, "C": 2},
"z_retract_distance": 2,
"left_mount_offset": [-34, 0, 0],
"serial_speed": 888,
"default_current": {
"default": {"X": 1.25, "Y": 1.25, "Z": 0.5, "A": 0.5, "B": 0.05, "C": 0.05},
"2.1": {"X": 1, "Y": 2, "Z": 3, "A": 4, "B": 5, "C": 6},
},
"low_current": {
"default": {"X": 0.7, "Y": 0.7, "Z": 0.1, "A": 0.1, "B": 0.05, "C": 0.05},
"2.1": {"X": 1, "Y": 2, "Z": 3, "A": 4, "B": 5, "C": 6},
},
"high_current": {
"default": {"X": 1.25, "Y": 1.25, "Z": 0.5, "A": 0.5, "B": 0.05, "C": 0.05},
"2.1": {"X": 1, "Y": 2, "Z": 3, "A": 4, "B": 5, "C": 6},
},
"default_max_speed": {"X": 1, "Y": 2, "Z": 3, "A": 4, "B": 5, "C": 6},
"default_pipette_configs": {
"homePosition": 220,
"maxTravel": 30,
"stepsPerMM": 768,
},
"log_level": "NADA",
}
new_dummy_settings = {
"name": "Marie Curie",
"version": 4,
"gantry_steps_per_mm": {"X": 80.0, "Y": 80.0, "Z": 400.0, "A": 400.0},
"acceleration": {"X": 3, "Y": 2, "Z": 15, "A": 15, "B": 2, "C": 2},
"z_retract_distance": 2,
"left_mount_offset": [-34, 0, 0],
"serial_speed": 888,
"default_current": {
"default": {"X": 1.25, "Y": 1.25, "Z": 0.8, "A": 0.8, "B": 0.05, "C": 0.05},
"2.1": {"X": 1, "Y": 2, "Z": 3, "A": 4, "B": 5, "C": 6},
},
"low_current": {
"default": {"X": 0.7, "Y": 0.7, "Z": 0.7, "A": 0.7, "B": 0.7, "C": 0.7},
"2.1": {"X": 1, "Y": 2, "Z": 3, "A": 4, "B": 5, "C": 6},
},
"high_current": {
"default": {"X": 0.7, "Y": 0.7, "Z": 0.7, "A": 0.7, "B": 0.7, "C": 0.7},
"2.1": {"X": 1, "Y": 2, "Z": 3, "A": 4, "B": 5, "C": 6},
},
"default_max_speed": {"X": 1, "Y": 2, "Z": 3, "A": 4, "B": 5, "C": 6},
"default_pipette_configs": {
"homePosition": 220,
"maxTravel": 30,
"stepsPerMM": 768,
},
"log_level": "NADA",
}
| legacy_dummy_settings = {'name': 'Rosalind Franklin', 'version': 42, 'steps_per_mm': 'M92 X80.00 Y80.00 Z400 A400 B768 C768', 'gantry_steps_per_mm': {'X': 80.0, 'Y': 80.0, 'Z': 400, 'A': 400}, 'acceleration': {'X': 3, 'Y': 2, 'Z': 15, 'A': 15, 'B': 2, 'C': 2}, 'z_retract_distance': 2, 'tip_length': 999, 'left_mount_offset': [-34, 0, 0], 'serial_speed': 888, 'default_current': {'X': 1, 'Y': 2, 'Z': 3, 'A': 4, 'B': 5, 'C': 6}, 'low_current': {'X': 1, 'Y': 2, 'Z': 3, 'A': 4, 'B': 5, 'C': 6}, 'high_current': {'X': 1, 'Y': 2, 'Z': 3, 'A': 4, 'B': 5, 'C': 6}, 'default_max_speed': {'X': 1, 'Y': 2, 'Z': 3, 'A': 4, 'B': 5, 'C': 6}, 'default_pipette_configs': {'homePosition': 220, 'maxTravel': 30, 'stepsPerMM': 768}, 'log_level': 'NADA'}
migrated_dummy_settings = {'name': 'Rosalind Franklin', 'version': 4, 'gantry_steps_per_mm': {'X': 80.0, 'Y': 80.0, 'Z': 400.0, 'A': 400.0}, 'acceleration': {'X': 3, 'Y': 2, 'Z': 15, 'A': 15, 'B': 2, 'C': 2}, 'z_retract_distance': 2, 'left_mount_offset': [-34, 0, 0], 'serial_speed': 888, 'default_current': {'default': {'X': 1.25, 'Y': 1.25, 'Z': 0.5, 'A': 0.5, 'B': 0.05, 'C': 0.05}, '2.1': {'X': 1, 'Y': 2, 'Z': 3, 'A': 4, 'B': 5, 'C': 6}}, 'low_current': {'default': {'X': 0.7, 'Y': 0.7, 'Z': 0.1, 'A': 0.1, 'B': 0.05, 'C': 0.05}, '2.1': {'X': 1, 'Y': 2, 'Z': 3, 'A': 4, 'B': 5, 'C': 6}}, 'high_current': {'default': {'X': 1.25, 'Y': 1.25, 'Z': 0.5, 'A': 0.5, 'B': 0.05, 'C': 0.05}, '2.1': {'X': 1, 'Y': 2, 'Z': 3, 'A': 4, 'B': 5, 'C': 6}}, 'default_max_speed': {'X': 1, 'Y': 2, 'Z': 3, 'A': 4, 'B': 5, 'C': 6}, 'default_pipette_configs': {'homePosition': 220, 'maxTravel': 30, 'stepsPerMM': 768}, 'log_level': 'NADA'}
new_dummy_settings = {'name': 'Marie Curie', 'version': 4, 'gantry_steps_per_mm': {'X': 80.0, 'Y': 80.0, 'Z': 400.0, 'A': 400.0}, 'acceleration': {'X': 3, 'Y': 2, 'Z': 15, 'A': 15, 'B': 2, 'C': 2}, 'z_retract_distance': 2, 'left_mount_offset': [-34, 0, 0], 'serial_speed': 888, 'default_current': {'default': {'X': 1.25, 'Y': 1.25, 'Z': 0.8, 'A': 0.8, 'B': 0.05, 'C': 0.05}, '2.1': {'X': 1, 'Y': 2, 'Z': 3, 'A': 4, 'B': 5, 'C': 6}}, 'low_current': {'default': {'X': 0.7, 'Y': 0.7, 'Z': 0.7, 'A': 0.7, 'B': 0.7, 'C': 0.7}, '2.1': {'X': 1, 'Y': 2, 'Z': 3, 'A': 4, 'B': 5, 'C': 6}}, 'high_current': {'default': {'X': 0.7, 'Y': 0.7, 'Z': 0.7, 'A': 0.7, 'B': 0.7, 'C': 0.7}, '2.1': {'X': 1, 'Y': 2, 'Z': 3, 'A': 4, 'B': 5, 'C': 6}}, 'default_max_speed': {'X': 1, 'Y': 2, 'Z': 3, 'A': 4, 'B': 5, 'C': 6}, 'default_pipette_configs': {'homePosition': 220, 'maxTravel': 30, 'stepsPerMM': 768}, 'log_level': 'NADA'} |
#!/usr/bin/env python
# -*- coding: utf-8 -*-
# LeetCode 1832. Check if the Sentence Is Pangram
# https://leetcode.com/problems/check-if-the-sentence-is-pangram/
class CheckIfTheSentenceIsPangram:
def checkIfPangram(self, sentence: str) -> bool:
return len(set(sentence)) == 26
if __name__ == "__main__":
pass
# EOF
| class Checkifthesentenceispangram:
def check_if_pangram(self, sentence: str) -> bool:
return len(set(sentence)) == 26
if __name__ == '__main__':
pass |
#!/usr/bin/env python
# Justin's shot at optimizing QAOA parameters
def optimize_obj(obj_val, params=None):
beta = 0.5
gamma = 0.7
return (
beta, gamma, obj_val(beta, gamma)
) # return some optimization trace. It will eventually go into optimize.optimize_modularity, so it should at least contain optimal angles
| def optimize_obj(obj_val, params=None):
beta = 0.5
gamma = 0.7
return (beta, gamma, obj_val(beta, gamma)) |
__title__ = 'evernote2'
__description__ = 'another Evernote SDK for Python'
__url__ = 'https://github.com/JackonYang/evernote2'
__version__ = '1.0.0'
# __build__ = 0x022500
__author__ = 'Jackon Yang'
__author_email__ = 'i@jackon.me'
__license__ = 'BSD'
__copyright__ = 'Copyright 2020 Jackon Yang'
| __title__ = 'evernote2'
__description__ = 'another Evernote SDK for Python'
__url__ = 'https://github.com/JackonYang/evernote2'
__version__ = '1.0.0'
__author__ = 'Jackon Yang'
__author_email__ = 'i@jackon.me'
__license__ = 'BSD'
__copyright__ = 'Copyright 2020 Jackon Yang' |
lw = np.linspace(.5, 15, 8)
for i in xrange(8):
plt.plot(x, i*y, colors[i], linewidth=lw[i])
plt.ylim([-1, 8])
plt.show() | lw = np.linspace(0.5, 15, 8)
for i in xrange(8):
plt.plot(x, i * y, colors[i], linewidth=lw[i])
plt.ylim([-1, 8])
plt.show() |
# -*- coding: utf-8 -*-
def main():
a = int(input())
b = int(input())
c = int(input())
d = int(input())
diff = a * b - c * d
print('DIFERENCA =', diff)
if __name__ == '__main__':
main() | def main():
a = int(input())
b = int(input())
c = int(input())
d = int(input())
diff = a * b - c * d
print('DIFERENCA =', diff)
if __name__ == '__main__':
main() |
class Solution:
# Optimised Row by Row (Accepted), O(n) time and space, where n = total elems in pascal triangle
def generate(self, numRows: int) -> List[List[int]]:
n, res = 1, [[1]]
while n < numRows:
n += 1
l = [1]*n
for i in range((n-1)//2):
l[i+1] = l[n-2-i] = res[n-2][i] + res[n-2][i+1]
res.append(l)
return res
# Map (Top Voted), O(n) time and space
def generate(self, numRows):
res = [[1]]
for i in range(1, numRows):
res.append(
list(map(lambda x, y: x+y, res[-1] + [0], [0] + res[-1])))
return res
# 4 Liner (Top Voted), O(n) time and space
def generate(self, numRows):
pascal = [[1]*(i+1) for i in range(numRows)]
for i in range(numRows):
for j in range(1, i):
pascal[i][j] = pascal[i-1][j-1] + pascal[i-1][j]
return pascal
| class Solution:
def generate(self, numRows: int) -> List[List[int]]:
(n, res) = (1, [[1]])
while n < numRows:
n += 1
l = [1] * n
for i in range((n - 1) // 2):
l[i + 1] = l[n - 2 - i] = res[n - 2][i] + res[n - 2][i + 1]
res.append(l)
return res
def generate(self, numRows):
res = [[1]]
for i in range(1, numRows):
res.append(list(map(lambda x, y: x + y, res[-1] + [0], [0] + res[-1])))
return res
def generate(self, numRows):
pascal = [[1] * (i + 1) for i in range(numRows)]
for i in range(numRows):
for j in range(1, i):
pascal[i][j] = pascal[i - 1][j - 1] + pascal[i - 1][j]
return pascal |
# Python 3
testcases = int(input().strip())
for test in range(testcases):
string = input().strip()
ascii_string = [ord(c) for c in string]
length = len(string)
funny = True
for i in range(1, length):
if abs(ascii_string[i] - ascii_string[i - 1]) != abs(ascii_string[length - i - 1] - ascii_string[length - i]):
funny = False
break
if funny:
print('Funny')
else:
print('Not Funny')
| testcases = int(input().strip())
for test in range(testcases):
string = input().strip()
ascii_string = [ord(c) for c in string]
length = len(string)
funny = True
for i in range(1, length):
if abs(ascii_string[i] - ascii_string[i - 1]) != abs(ascii_string[length - i - 1] - ascii_string[length - i]):
funny = False
break
if funny:
print('Funny')
else:
print('Not Funny') |
#!/usr/bin/env python
# CHATBOT PARAMETERS:
# CLIENT PARAMETERS:
CLIENTBUFFERSIZE = 64 # buffer size
# SERVER PARAMETERS:
SERVERBUFFERSIZE = 64 # buffer size
HOST = "127.0.0.1"
PORT = 9000
# wireprotocol PARAMETERS:
# (probably best not to change DELIM)
| clientbuffersize = 64
serverbuffersize = 64
host = '127.0.0.1'
port = 9000 |
def maxSlidingWindow(nums, k):
ans = []
queue = []
for i, v in enumerate(nums):
# corner case, when front element is outside the window
if queue and queue[0] == i - k:
queue.pop(0)
# pop all elements smaller than new element to be added
# so after the new element is added, maximum is at queue front
while queue and nums[queue[-1]] < v:
queue.pop()
queue.append(i)
# when i reaches k - 1, there are k elements in window
# from now on, append sliding max in every step
if i + 1 >= k:
ans.append(nums[queue[0]])
return ans
maxSlidingWindow([1,3,-1,-3,5,3,6,7], 3) | def max_sliding_window(nums, k):
ans = []
queue = []
for (i, v) in enumerate(nums):
if queue and queue[0] == i - k:
queue.pop(0)
while queue and nums[queue[-1]] < v:
queue.pop()
queue.append(i)
if i + 1 >= k:
ans.append(nums[queue[0]])
return ans
max_sliding_window([1, 3, -1, -3, 5, 3, 6, 7], 3) |
#
# PySNMP MIB module ELTEX-MES-SWITCH-RATE-LIMITER-MIB (http://snmplabs.com/pysmi)
# ASN.1 source file:///Users/davwang4/Dev/mibs.snmplabs.com/asn1/ELTEX-MES-SWITCH-RATE-LIMITER-MIB
# Produced by pysmi-0.3.4 at Wed May 1 13:01:58 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)
#
Integer, ObjectIdentifier, OctetString = mibBuilder.importSymbols("ASN1", "Integer", "ObjectIdentifier", "OctetString")
NamedValues, = mibBuilder.importSymbols("ASN1-ENUMERATION", "NamedValues")
ValueSizeConstraint, ConstraintsUnion, SingleValueConstraint, ValueRangeConstraint, ConstraintsIntersection = mibBuilder.importSymbols("ASN1-REFINEMENT", "ValueSizeConstraint", "ConstraintsUnion", "SingleValueConstraint", "ValueRangeConstraint", "ConstraintsIntersection")
eltMesSwitchRateLimiterMIB, = mibBuilder.importSymbols("ELTEX-MES-MNG-MIB", "eltMesSwitchRateLimiterMIB")
ModuleCompliance, NotificationGroup = mibBuilder.importSymbols("SNMPv2-CONF", "ModuleCompliance", "NotificationGroup")
MibScalar, MibTable, MibTableRow, MibTableColumn, NotificationType, ModuleIdentity, IpAddress, MibIdentifier, Gauge32, Counter32, TimeTicks, Integer32, Unsigned32, ObjectIdentity, Counter64, iso, Bits = mibBuilder.importSymbols("SNMPv2-SMI", "MibScalar", "MibTable", "MibTableRow", "MibTableColumn", "NotificationType", "ModuleIdentity", "IpAddress", "MibIdentifier", "Gauge32", "Counter32", "TimeTicks", "Integer32", "Unsigned32", "ObjectIdentity", "Counter64", "iso", "Bits")
DisplayString, TextualConvention = mibBuilder.importSymbols("SNMPv2-TC", "DisplayString", "TextualConvention")
eltMesSwitchRateLimiterObjects = MibIdentifier((1, 3, 6, 1, 4, 1, 35265, 1, 23, 1, 773, 1))
eltMesSwitchRateLimiterConfig = MibIdentifier((1, 3, 6, 1, 4, 1, 35265, 1, 23, 1, 773, 1, 1))
eltMesSwitchRateLimiterStatistics = MibIdentifier((1, 3, 6, 1, 4, 1, 35265, 1, 23, 1, 773, 1, 2))
class EltCpuRateLimiterTrafficType(TextualConvention, Integer32):
description = 'Traffic types for rate limiting on CPU.'
status = 'current'
subtypeSpec = Integer32.subtypeSpec + ConstraintsUnion(SingleValueConstraint(1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21))
namedValues = NamedValues(("http", 1), ("telnet", 2), ("ssh", 3), ("snmp", 4), ("ip", 5), ("linkLocal", 6), ("arp", 7), ("arpInspec", 8), ("stpBpdu", 9), ("otherBpdu", 10), ("ipRouting", 11), ("ipOptions", 12), ("dhcpSnoop", 13), ("igmpSnoop", 14), ("mldSnoop", 15), ("sflow", 16), ("ace", 17), ("ipErrors", 18), ("other", 19), ("dhcpv6Snoop", 20), ("vrrp", 21))
class EltCpuRateStatisticsTrafficType(TextualConvention, Integer32):
description = 'Traffic types for input rates on CPU.'
status = 'current'
subtypeSpec = Integer32.subtypeSpec + ConstraintsUnion(SingleValueConstraint(1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28))
namedValues = NamedValues(("stack", 1), ("http", 2), ("telnet", 3), ("ssh", 4), ("snmp", 5), ("ip", 6), ("arp", 7), ("arpInspec", 8), ("stp", 9), ("ieee", 10), ("routeUnknown", 11), ("ipHopByHop", 12), ("mtuExceeded", 13), ("ipv4Multicast", 14), ("ipv6Multicast", 15), ("dhcpSnooping", 16), ("igmpSnooping", 17), ("mldSnooping", 18), ("ttlExceeded", 19), ("ipv4IllegalAddress", 20), ("ipv4HeaderError", 21), ("ipDaMismatch", 22), ("sflow", 23), ("logDenyAces", 24), ("dhcpv6Snooping", 25), ("vrrp", 26), ("logPermitAces", 27), ("ipv6HeaderError", 28))
eltCpuRateLimiterTable = MibTable((1, 3, 6, 1, 4, 1, 35265, 1, 23, 1, 773, 1, 1, 1), )
if mibBuilder.loadTexts: eltCpuRateLimiterTable.setStatus('current')
if mibBuilder.loadTexts: eltCpuRateLimiterTable.setDescription('A list of CPU rate limiters.')
eltCpuRateLimiterEntry = MibTableRow((1, 3, 6, 1, 4, 1, 35265, 1, 23, 1, 773, 1, 1, 1, 1), ).setIndexNames((0, "ELTEX-MES-SWITCH-RATE-LIMITER-MIB", "eltCpuRateLimiterIndex"))
if mibBuilder.loadTexts: eltCpuRateLimiterEntry.setStatus('current')
if mibBuilder.loadTexts: eltCpuRateLimiterEntry.setDescription('An entry containing the custom CPU rate limiter information for specific traffic type.')
eltCpuRateLimiterIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 35265, 1, 23, 1, 773, 1, 1, 1, 1, 1), EltCpuRateLimiterTrafficType()).setMaxAccess("readonly")
if mibBuilder.loadTexts: eltCpuRateLimiterIndex.setStatus('current')
if mibBuilder.loadTexts: eltCpuRateLimiterIndex.setDescription('Traffic type')
eltCpuRateLimiterValue = MibTableColumn((1, 3, 6, 1, 4, 1, 35265, 1, 23, 1, 773, 1, 1, 1, 1, 2), Integer32().subtype(subtypeSpec=ValueRangeConstraint(0, 65535))).setMaxAccess("readwrite")
if mibBuilder.loadTexts: eltCpuRateLimiterValue.setStatus('current')
if mibBuilder.loadTexts: eltCpuRateLimiterValue.setDescription('Value of rate-limiter')
eltCpuRateStatisticsTable = MibTable((1, 3, 6, 1, 4, 1, 35265, 1, 23, 1, 773, 1, 2, 1), )
if mibBuilder.loadTexts: eltCpuRateStatisticsTable.setStatus('current')
if mibBuilder.loadTexts: eltCpuRateStatisticsTable.setDescription('A list of CPU input rates per traffic type.')
eltCpuRateStatisticsEntry = MibTableRow((1, 3, 6, 1, 4, 1, 35265, 1, 23, 1, 773, 1, 2, 1, 1), ).setIndexNames((0, "ELTEX-MES-SWITCH-RATE-LIMITER-MIB", "eltCpuRateStatisticsIndex"))
if mibBuilder.loadTexts: eltCpuRateStatisticsEntry.setStatus('current')
if mibBuilder.loadTexts: eltCpuRateStatisticsEntry.setDescription('An entry containing the CPU input rates for specific traffic type.')
eltCpuRateStatisticsIndex = MibTableColumn((1, 3, 6, 1, 4, 1, 35265, 1, 23, 1, 773, 1, 2, 1, 1, 1), EltCpuRateStatisticsTrafficType()).setMaxAccess("readonly")
if mibBuilder.loadTexts: eltCpuRateStatisticsIndex.setStatus('current')
if mibBuilder.loadTexts: eltCpuRateStatisticsIndex.setDescription('Traffic type')
eltCpuRateStatisticsRate = MibTableColumn((1, 3, 6, 1, 4, 1, 35265, 1, 23, 1, 773, 1, 2, 1, 1, 2), Gauge32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: eltCpuRateStatisticsRate.setStatus('current')
if mibBuilder.loadTexts: eltCpuRateStatisticsRate.setDescription('Input rate int packets per second.')
eltCpuRateStatisticsCounter = MibTableColumn((1, 3, 6, 1, 4, 1, 35265, 1, 23, 1, 773, 1, 2, 1, 1, 3), Counter32()).setMaxAccess("readonly")
if mibBuilder.loadTexts: eltCpuRateStatisticsCounter.setStatus('current')
if mibBuilder.loadTexts: eltCpuRateStatisticsCounter.setDescription('Total counter of packets.')
mibBuilder.exportSymbols("ELTEX-MES-SWITCH-RATE-LIMITER-MIB", eltMesSwitchRateLimiterStatistics=eltMesSwitchRateLimiterStatistics, eltCpuRateStatisticsTable=eltCpuRateStatisticsTable, eltCpuRateStatisticsIndex=eltCpuRateStatisticsIndex, eltMesSwitchRateLimiterObjects=eltMesSwitchRateLimiterObjects, EltCpuRateStatisticsTrafficType=EltCpuRateStatisticsTrafficType, eltCpuRateStatisticsEntry=eltCpuRateStatisticsEntry, eltCpuRateLimiterEntry=eltCpuRateLimiterEntry, eltCpuRateStatisticsRate=eltCpuRateStatisticsRate, eltCpuRateLimiterTable=eltCpuRateLimiterTable, eltCpuRateLimiterIndex=eltCpuRateLimiterIndex, eltMesSwitchRateLimiterConfig=eltMesSwitchRateLimiterConfig, EltCpuRateLimiterTrafficType=EltCpuRateLimiterTrafficType, eltCpuRateLimiterValue=eltCpuRateLimiterValue, eltCpuRateStatisticsCounter=eltCpuRateStatisticsCounter)
| (integer, object_identifier, octet_string) = mibBuilder.importSymbols('ASN1', 'Integer', 'ObjectIdentifier', 'OctetString')
(named_values,) = mibBuilder.importSymbols('ASN1-ENUMERATION', 'NamedValues')
(value_size_constraint, constraints_union, single_value_constraint, value_range_constraint, constraints_intersection) = mibBuilder.importSymbols('ASN1-REFINEMENT', 'ValueSizeConstraint', 'ConstraintsUnion', 'SingleValueConstraint', 'ValueRangeConstraint', 'ConstraintsIntersection')
(elt_mes_switch_rate_limiter_mib,) = mibBuilder.importSymbols('ELTEX-MES-MNG-MIB', 'eltMesSwitchRateLimiterMIB')
(module_compliance, notification_group) = mibBuilder.importSymbols('SNMPv2-CONF', 'ModuleCompliance', 'NotificationGroup')
(mib_scalar, mib_table, mib_table_row, mib_table_column, notification_type, module_identity, ip_address, mib_identifier, gauge32, counter32, time_ticks, integer32, unsigned32, object_identity, counter64, iso, bits) = mibBuilder.importSymbols('SNMPv2-SMI', 'MibScalar', 'MibTable', 'MibTableRow', 'MibTableColumn', 'NotificationType', 'ModuleIdentity', 'IpAddress', 'MibIdentifier', 'Gauge32', 'Counter32', 'TimeTicks', 'Integer32', 'Unsigned32', 'ObjectIdentity', 'Counter64', 'iso', 'Bits')
(display_string, textual_convention) = mibBuilder.importSymbols('SNMPv2-TC', 'DisplayString', 'TextualConvention')
elt_mes_switch_rate_limiter_objects = mib_identifier((1, 3, 6, 1, 4, 1, 35265, 1, 23, 1, 773, 1))
elt_mes_switch_rate_limiter_config = mib_identifier((1, 3, 6, 1, 4, 1, 35265, 1, 23, 1, 773, 1, 1))
elt_mes_switch_rate_limiter_statistics = mib_identifier((1, 3, 6, 1, 4, 1, 35265, 1, 23, 1, 773, 1, 2))
class Eltcpuratelimitertraffictype(TextualConvention, Integer32):
description = 'Traffic types for rate limiting on CPU.'
status = 'current'
subtype_spec = Integer32.subtypeSpec + constraints_union(single_value_constraint(1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21))
named_values = named_values(('http', 1), ('telnet', 2), ('ssh', 3), ('snmp', 4), ('ip', 5), ('linkLocal', 6), ('arp', 7), ('arpInspec', 8), ('stpBpdu', 9), ('otherBpdu', 10), ('ipRouting', 11), ('ipOptions', 12), ('dhcpSnoop', 13), ('igmpSnoop', 14), ('mldSnoop', 15), ('sflow', 16), ('ace', 17), ('ipErrors', 18), ('other', 19), ('dhcpv6Snoop', 20), ('vrrp', 21))
class Eltcpuratestatisticstraffictype(TextualConvention, Integer32):
description = 'Traffic types for input rates on CPU.'
status = 'current'
subtype_spec = Integer32.subtypeSpec + constraints_union(single_value_constraint(1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28))
named_values = named_values(('stack', 1), ('http', 2), ('telnet', 3), ('ssh', 4), ('snmp', 5), ('ip', 6), ('arp', 7), ('arpInspec', 8), ('stp', 9), ('ieee', 10), ('routeUnknown', 11), ('ipHopByHop', 12), ('mtuExceeded', 13), ('ipv4Multicast', 14), ('ipv6Multicast', 15), ('dhcpSnooping', 16), ('igmpSnooping', 17), ('mldSnooping', 18), ('ttlExceeded', 19), ('ipv4IllegalAddress', 20), ('ipv4HeaderError', 21), ('ipDaMismatch', 22), ('sflow', 23), ('logDenyAces', 24), ('dhcpv6Snooping', 25), ('vrrp', 26), ('logPermitAces', 27), ('ipv6HeaderError', 28))
elt_cpu_rate_limiter_table = mib_table((1, 3, 6, 1, 4, 1, 35265, 1, 23, 1, 773, 1, 1, 1))
if mibBuilder.loadTexts:
eltCpuRateLimiterTable.setStatus('current')
if mibBuilder.loadTexts:
eltCpuRateLimiterTable.setDescription('A list of CPU rate limiters.')
elt_cpu_rate_limiter_entry = mib_table_row((1, 3, 6, 1, 4, 1, 35265, 1, 23, 1, 773, 1, 1, 1, 1)).setIndexNames((0, 'ELTEX-MES-SWITCH-RATE-LIMITER-MIB', 'eltCpuRateLimiterIndex'))
if mibBuilder.loadTexts:
eltCpuRateLimiterEntry.setStatus('current')
if mibBuilder.loadTexts:
eltCpuRateLimiterEntry.setDescription('An entry containing the custom CPU rate limiter information for specific traffic type.')
elt_cpu_rate_limiter_index = mib_table_column((1, 3, 6, 1, 4, 1, 35265, 1, 23, 1, 773, 1, 1, 1, 1, 1), elt_cpu_rate_limiter_traffic_type()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
eltCpuRateLimiterIndex.setStatus('current')
if mibBuilder.loadTexts:
eltCpuRateLimiterIndex.setDescription('Traffic type')
elt_cpu_rate_limiter_value = mib_table_column((1, 3, 6, 1, 4, 1, 35265, 1, 23, 1, 773, 1, 1, 1, 1, 2), integer32().subtype(subtypeSpec=value_range_constraint(0, 65535))).setMaxAccess('readwrite')
if mibBuilder.loadTexts:
eltCpuRateLimiterValue.setStatus('current')
if mibBuilder.loadTexts:
eltCpuRateLimiterValue.setDescription('Value of rate-limiter')
elt_cpu_rate_statistics_table = mib_table((1, 3, 6, 1, 4, 1, 35265, 1, 23, 1, 773, 1, 2, 1))
if mibBuilder.loadTexts:
eltCpuRateStatisticsTable.setStatus('current')
if mibBuilder.loadTexts:
eltCpuRateStatisticsTable.setDescription('A list of CPU input rates per traffic type.')
elt_cpu_rate_statistics_entry = mib_table_row((1, 3, 6, 1, 4, 1, 35265, 1, 23, 1, 773, 1, 2, 1, 1)).setIndexNames((0, 'ELTEX-MES-SWITCH-RATE-LIMITER-MIB', 'eltCpuRateStatisticsIndex'))
if mibBuilder.loadTexts:
eltCpuRateStatisticsEntry.setStatus('current')
if mibBuilder.loadTexts:
eltCpuRateStatisticsEntry.setDescription('An entry containing the CPU input rates for specific traffic type.')
elt_cpu_rate_statistics_index = mib_table_column((1, 3, 6, 1, 4, 1, 35265, 1, 23, 1, 773, 1, 2, 1, 1, 1), elt_cpu_rate_statistics_traffic_type()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
eltCpuRateStatisticsIndex.setStatus('current')
if mibBuilder.loadTexts:
eltCpuRateStatisticsIndex.setDescription('Traffic type')
elt_cpu_rate_statistics_rate = mib_table_column((1, 3, 6, 1, 4, 1, 35265, 1, 23, 1, 773, 1, 2, 1, 1, 2), gauge32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
eltCpuRateStatisticsRate.setStatus('current')
if mibBuilder.loadTexts:
eltCpuRateStatisticsRate.setDescription('Input rate int packets per second.')
elt_cpu_rate_statistics_counter = mib_table_column((1, 3, 6, 1, 4, 1, 35265, 1, 23, 1, 773, 1, 2, 1, 1, 3), counter32()).setMaxAccess('readonly')
if mibBuilder.loadTexts:
eltCpuRateStatisticsCounter.setStatus('current')
if mibBuilder.loadTexts:
eltCpuRateStatisticsCounter.setDescription('Total counter of packets.')
mibBuilder.exportSymbols('ELTEX-MES-SWITCH-RATE-LIMITER-MIB', eltMesSwitchRateLimiterStatistics=eltMesSwitchRateLimiterStatistics, eltCpuRateStatisticsTable=eltCpuRateStatisticsTable, eltCpuRateStatisticsIndex=eltCpuRateStatisticsIndex, eltMesSwitchRateLimiterObjects=eltMesSwitchRateLimiterObjects, EltCpuRateStatisticsTrafficType=EltCpuRateStatisticsTrafficType, eltCpuRateStatisticsEntry=eltCpuRateStatisticsEntry, eltCpuRateLimiterEntry=eltCpuRateLimiterEntry, eltCpuRateStatisticsRate=eltCpuRateStatisticsRate, eltCpuRateLimiterTable=eltCpuRateLimiterTable, eltCpuRateLimiterIndex=eltCpuRateLimiterIndex, eltMesSwitchRateLimiterConfig=eltMesSwitchRateLimiterConfig, EltCpuRateLimiterTrafficType=EltCpuRateLimiterTrafficType, eltCpuRateLimiterValue=eltCpuRateLimiterValue, eltCpuRateStatisticsCounter=eltCpuRateStatisticsCounter) |
#prime number
# n=int(input("enter any number"))
# count=0
# i=1
# while (i<=n):
# if (n%i)==0:
# count=count+1
# i=i+1
# if (count==2):
# print("prime number")
# else:
# print("composite number")
i=0
b=0
while i<=100:
j=2
count=0
while j<=i//2:
if i%j==0:
count=count+1
break
j+=1
if count==0 and i!=1:
print(i,"prime")
else:
print(i,"not prime")
i+=1 | i = 0
b = 0
while i <= 100:
j = 2
count = 0
while j <= i // 2:
if i % j == 0:
count = count + 1
break
j += 1
if count == 0 and i != 1:
print(i, 'prime')
else:
print(i, 'not prime')
i += 1 |
# 01234567890123456789012
# Mary had a little lamb.
# |--| |---------| GOLD
# |--| |-| |---| PRED
# || |---| INTERSECT
def merge_and_add(out, one, two):
a = max(one[0], two[0])
b = min(one[1], two[1])
if a <= b:
out.append([a, b])
def calculate_intersect(gold, pred):
out = []
id_gold = 0
id_pred = 0
while id_gold < len(gold) and id_pred < len(pred):
curr_gold = gold[id_gold]
curr_pred = pred[id_pred]
merge_and_add(out, curr_gold, curr_pred)
if curr_pred[1] >= curr_gold[1]:
id_gold += 1
if curr_pred[1] <= curr_gold[1]:
id_pred += 1
return out
calculate_intersect([[0, 5], [10, 16]], [[2, 4], [8, 10], [14, 15]])
| def merge_and_add(out, one, two):
a = max(one[0], two[0])
b = min(one[1], two[1])
if a <= b:
out.append([a, b])
def calculate_intersect(gold, pred):
out = []
id_gold = 0
id_pred = 0
while id_gold < len(gold) and id_pred < len(pred):
curr_gold = gold[id_gold]
curr_pred = pred[id_pred]
merge_and_add(out, curr_gold, curr_pred)
if curr_pred[1] >= curr_gold[1]:
id_gold += 1
if curr_pred[1] <= curr_gold[1]:
id_pred += 1
return out
calculate_intersect([[0, 5], [10, 16]], [[2, 4], [8, 10], [14, 15]]) |
# Dimmer Switch class
class DimmerSwitch():
def __init__(self, label):
self.label = label
self.isOn = False
self.brightness = 0
def turnOn(self):
self.isOn = True
# turn the light on at self.brightness
def turnOff(self):
self.isOn = False
# turn the light off
def raiseLevel(self):
if self.brightness < 10:
self.brightness = self.brightness + 1
def lowerLevel(self):
if self.brightness > 0:
self.brightness = self.brightness - 1
# Extra method for debugging
def show(self):
print('Label:', self.label)
print('Light is on?', self.isOn)
print('Brightness is:', self.brightness)
print()
# Main code (to demo with Python Tutor)
# Create two DimmerSwitch objects
oDimmer1 = DimmerSwitch('Dimmer1')
oDimmer2 = DimmerSwitch('Dimmer2')
# Tell oDimmer1 to raise its level
oDimmer1.raiseLevel()
# Tell oDimmer2 to raise its level
oDimmer2.raiseLevel()
| class Dimmerswitch:
def __init__(self, label):
self.label = label
self.isOn = False
self.brightness = 0
def turn_on(self):
self.isOn = True
def turn_off(self):
self.isOn = False
def raise_level(self):
if self.brightness < 10:
self.brightness = self.brightness + 1
def lower_level(self):
if self.brightness > 0:
self.brightness = self.brightness - 1
def show(self):
print('Label:', self.label)
print('Light is on?', self.isOn)
print('Brightness is:', self.brightness)
print()
o_dimmer1 = dimmer_switch('Dimmer1')
o_dimmer2 = dimmer_switch('Dimmer2')
oDimmer1.raiseLevel()
oDimmer2.raiseLevel() |
#func What we should get after the Module 1
chatbot_name = "Garik"
user_name = input("Hello! What's you name? ")
#1
phrase = input(chatbot_name + ": What do you think? ")
print("Yes, " + user_name + ", " + phrase)
#2
phrase = input(chatbot_name + ": What do you think? ")
print("Yes, " + user_name + ", " + phrase)
#3
phrase = input(chatbot_name + ": What do you think? ")
print("Yes, " + user_name + ", " + phrase)
#4
phrase = input(chatbot_name + ": What do you think? ")
print("Yes, " + user_name + ", " + phrase)
# ... and so on and so forth
| chatbot_name = 'Garik'
user_name = input("Hello! What's you name? ")
phrase = input(chatbot_name + ': What do you think? ')
print('Yes, ' + user_name + ', ' + phrase)
phrase = input(chatbot_name + ': What do you think? ')
print('Yes, ' + user_name + ', ' + phrase)
phrase = input(chatbot_name + ': What do you think? ')
print('Yes, ' + user_name + ', ' + phrase)
phrase = input(chatbot_name + ': What do you think? ')
print('Yes, ' + user_name + ', ' + phrase) |
# For more info check out https://github.com/etianen/django-python3-ldap#available-settings
# TODO Read this info from enviornment variables
# The URL of the LDAP server.
LDAP_AUTH_URL = "ldap://localhost:389"
# Initiate TLS on connection.
LDAP_AUTH_USE_TLS = False
# The LDAP search base for looking up users.
LDAP_AUTH_SEARCH_BASE = "ou=people,dc=example,dc=com"
# The LDAP class that represents a user.
LDAP_AUTH_OBJECT_CLASS = "inetOrgPerson"
# User model fields mapped to the LDAP
# attributes that represent them.
LDAP_AUTH_USER_FIELDS = {
"username": "uid",
"first_name": "givenName",
"last_name": "sn",
"email": "mail",
}
# A tuple of django model fields used to uniquely identify a user.
LDAP_AUTH_USER_LOOKUP_FIELDS = ("username",)
# Path to a callable that takes a dict of {model_field_name: value},
# returning a dict of clean model data.
# Use this to customize how data loaded from LDAP is saved to the User model.
LDAP_AUTH_CLEAN_USER_DATA = "django_python3_ldap.utils.clean_user_data"
# Path to a callable that takes a user model and a dict of {ldap_field_name: [value]},
# and saves any additional user relationships based on the LDAP data.
# Use this to customize how data loaded from LDAP is saved to User model relations.
# For customizing non-related User model fields, use LDAP_AUTH_CLEAN_USER_DATA.
LDAP_AUTH_SYNC_USER_RELATIONS = "django_python3_ldap.utils.sync_user_relations"
# Path to a callable that takes a dict of {ldap_field_name: value},
# returning a list of [ldap_search_filter]. The search filters will then be AND'd
# together when creating the final search filter.
LDAP_AUTH_FORMAT_SEARCH_FILTERS = "django_python3_ldap.utils.format_search_filters"
# Path to a callable that takes a dict of {model_field_name: value}, and returns
# a string of the username to bind to the LDAP server.
# Use this to support different types of LDAP server.
LDAP_AUTH_FORMAT_USERNAME = "django_python3_ldap.utils.format_username_openldap"
# Sets the login domain for Active Directory users.
LDAP_AUTH_ACTIVE_DIRECTORY_DOMAIN = None
# The LDAP username and password of a user for authenticating the `ldap_sync_users`
# management command. Set to None if you allow anonymous queries.
LDAP_AUTH_CONNECTION_USERNAME = None
LDAP_AUTH_CONNECTION_PASSWORD = None | ldap_auth_url = 'ldap://localhost:389'
ldap_auth_use_tls = False
ldap_auth_search_base = 'ou=people,dc=example,dc=com'
ldap_auth_object_class = 'inetOrgPerson'
ldap_auth_user_fields = {'username': 'uid', 'first_name': 'givenName', 'last_name': 'sn', 'email': 'mail'}
ldap_auth_user_lookup_fields = ('username',)
ldap_auth_clean_user_data = 'django_python3_ldap.utils.clean_user_data'
ldap_auth_sync_user_relations = 'django_python3_ldap.utils.sync_user_relations'
ldap_auth_format_search_filters = 'django_python3_ldap.utils.format_search_filters'
ldap_auth_format_username = 'django_python3_ldap.utils.format_username_openldap'
ldap_auth_active_directory_domain = None
ldap_auth_connection_username = None
ldap_auth_connection_password = None |
class Solution:
def canThreePartsEqualSum(self, A: List[int]) -> bool:
s = sum(A)
if s % 3 != 0:
return False
avg = s // 3
cnt = 0
s = 0
for i in A:
s += i
if s == avg:
cnt += 1
s = 0
return cnt == 3
| class Solution:
def can_three_parts_equal_sum(self, A: List[int]) -> bool:
s = sum(A)
if s % 3 != 0:
return False
avg = s // 3
cnt = 0
s = 0
for i in A:
s += i
if s == avg:
cnt += 1
s = 0
return cnt == 3 |
new = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"
def to_base_64(string):
res=""
for i in string:
res+=binary(i)
if len(res)%6!=0: res=res+"0"*(6-len(res)%6)
result=""
for i in range(0,len(res),6):
result+=new[int(res[i:i+6], 2)]
return result
def from_base_64(string):
res=""
for i in string:
res+=binary2(i)
result=""
for i in range(0,len(res),8):
result+=chr(int(res[i:i+8], 2))
return result.rstrip('\x00')
def binary(string):
res=bin(ord(string))[2:]
return "0"*(8-len(res))+res
def binary2(string):
res=bin(new.index(string))[2:]
return "0"*(6-len(res))+res | new = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/'
def to_base_64(string):
res = ''
for i in string:
res += binary(i)
if len(res) % 6 != 0:
res = res + '0' * (6 - len(res) % 6)
result = ''
for i in range(0, len(res), 6):
result += new[int(res[i:i + 6], 2)]
return result
def from_base_64(string):
res = ''
for i in string:
res += binary2(i)
result = ''
for i in range(0, len(res), 8):
result += chr(int(res[i:i + 8], 2))
return result.rstrip('\x00')
def binary(string):
res = bin(ord(string))[2:]
return '0' * (8 - len(res)) + res
def binary2(string):
res = bin(new.index(string))[2:]
return '0' * (6 - len(res)) + res |
inp = open("input/day6.txt", "r")
prvotne_ribe = [int(x) for x in inp.readline().split(",")]
inp.close()
prvotna_populacija = [0 for _ in range(9)]
for riba in prvotne_ribe:
prvotna_populacija[riba] += 1
def zivljenje(N):
populacija = prvotna_populacija
for _ in range(N):
nova_populacija = [0 for _ in range(9)]
for k in range(9):
if k == 0:
nova_populacija[8] += populacija[k]
nova_populacija[6] += populacija[k]
else:
nova_populacija[k-1] += populacija[k]
populacija = nova_populacija
return sum(populacija)
# --------------------------
print("1. del: ")
print(zivljenje(80))
print("2. del: ")
print(zivljenje(256))
| inp = open('input/day6.txt', 'r')
prvotne_ribe = [int(x) for x in inp.readline().split(',')]
inp.close()
prvotna_populacija = [0 for _ in range(9)]
for riba in prvotne_ribe:
prvotna_populacija[riba] += 1
def zivljenje(N):
populacija = prvotna_populacija
for _ in range(N):
nova_populacija = [0 for _ in range(9)]
for k in range(9):
if k == 0:
nova_populacija[8] += populacija[k]
nova_populacija[6] += populacija[k]
else:
nova_populacija[k - 1] += populacija[k]
populacija = nova_populacija
return sum(populacija)
print('1. del: ')
print(zivljenje(80))
print('2. del: ')
print(zivljenje(256)) |
class MockLROPoller(object):
def result(self, timeout: None):
pass
class MockVirtualMachineScaleSetVMsOperations(object):
def begin_power_off(self, resource_group_name, scale_set_name, instance_id):
return MockLROPoller()
def begin_delete(self, resource_group_name, scale_set_name, instance_id):
return MockLROPoller()
def begin_restart(self, resource_group_name, scale_set_name, instance_id):
return MockLROPoller()
def begin_deallocate(self, resource_group_name, scale_set_name, instance_id):
return MockLROPoller()
class MockComputeManagementClient(object):
def __init__(self):
self.operations = MockVirtualMachineScaleSetVMsOperations()
@property
def virtual_machine_scale_set_vms(self):
return self.operations
| class Mocklropoller(object):
def result(self, timeout: None):
pass
class Mockvirtualmachinescalesetvmsoperations(object):
def begin_power_off(self, resource_group_name, scale_set_name, instance_id):
return mock_lro_poller()
def begin_delete(self, resource_group_name, scale_set_name, instance_id):
return mock_lro_poller()
def begin_restart(self, resource_group_name, scale_set_name, instance_id):
return mock_lro_poller()
def begin_deallocate(self, resource_group_name, scale_set_name, instance_id):
return mock_lro_poller()
class Mockcomputemanagementclient(object):
def __init__(self):
self.operations = mock_virtual_machine_scale_set_v_ms_operations()
@property
def virtual_machine_scale_set_vms(self):
return self.operations |
def assert_event_handler(expected_event, mocked_handler):
assert mocked_handler.call_count == 1
actual_event = mocked_handler.call_args[0][0]
assert actual_event == expected_event
| def assert_event_handler(expected_event, mocked_handler):
assert mocked_handler.call_count == 1
actual_event = mocked_handler.call_args[0][0]
assert actual_event == expected_event |
class RoleDisabledException(Exception):
def __init__(self):
self.name = "Your role is disable."
| class Roledisabledexception(Exception):
def __init__(self):
self.name = 'Your role is disable.' |
def run_pg_GB(
n_iter,
min_timesteps_per_batch,
max_path_length,
animate,
logdir,
nn_baseline,
seed,
n_layers,
output_activation,
size,
save_models,
save_best_model,
run_model_only,
script_optimizing_dir,
relative_positions,
death_penalty,
reward_circle,
num_enemies):
start = time.time()
if script_optimizing_dir is not None:
logdir = logdir[:5]+script_optimizing_dir+'/'+logdir[5:]
#========================================================================================#
# Set Up Logger
#========================================================================================#
setup_logger(logdir, locals())
#========================================================================================#
# Set Up Env
#========================================================================================#
# Make the gym environment
env = GB_game(num_char = num_enemies, reward_circle = reward_circle, death_penalty = death_penalty, relative_positions = relative_positions)
tf.set_random_seed(seed)
np.random.seed(seed)
env.seed(seed)
# Maximum length for episodes
max_path_length = max_path_length or env.spec.max_episode_steps
# Is this env continuous, or self.discrete?
discrete = isinstance(env.action_space, gym.spaces.Discrete)
# Observation and action sizes
ob_dim = env.observation_space.shape[0]
ac_dim = env.action_space.n if discrete else env.action_space.shape[0]
#========================================================================================#
# Initialize Agent
#========================================================================================#
computation_graph_args = {
'n_layers': n_layers,
'output_activation': output_activation,
'ob_dim': ob_dim,
'ac_dim': ac_dim,
'discrete': discrete,
'size': size,
'learning_rate': learning_rate,
'baseline_lr' : baseline_lr,
}
sample_trajectory_args = {
'animate': animate,
'max_path_length': max_path_length,
'min_timesteps_per_batch': min_timesteps_per_batch,
}
estimate_return_args = {
'gamma': gamma,
'reward_to_go': reward_to_go,
'nn_baseline': nn_baseline,
'normalize_advantages': normalize_advantages,
}
agent = Agent(computation_graph_args, sample_trajectory_args, estimate_return_args)
# build computation graph
agent.build_computation_graph()
# tensorflow: config, session, variable initialization
agent.init_tf_sess()
# Now we'll try to load...
if run_model_only is not None:
agent.load_models_action(run_model_only)
agent.running_only = True
#========================================================================================#
# Training Loop
#========================================================================================#
best_avg_return = -(5e10)
total_timesteps = 0
for itr in range(n_iter):
print("********** Iteration %i ************"%itr)
paths, timesteps_this_batch = agent.sample_trajectories(itr, env)
total_timesteps += timesteps_this_batch
# Build arrays for observation, action for the policy gradient update by concatenating
# across paths
if run_model_only is not None:
continue
ob_no = np.concatenate([path["observation"] for path in paths])
ac_na = np.concatenate([path["action"] for path in paths])
re_n = [path["reward"] for path in paths]
q_n, adv_n = agent.estimate_return(ob_no, re_n)
agent.update_parameters(ob_no, ac_na, q_n, adv_n)
# Log diagnostics
returns = [path["reward"].sum() for path in paths]
ep_lengths = [pathlength(path) for path in paths]
logz.log_tabular("Time", time.time() - start)
logz.log_tabular("Iteration", itr)
mean_return = np.mean(returns)
if mean_return > best_avg_return:
best_avg_return = mean_return
if save_best_model==True:
save_string = logdir[5:-2]
agent.save_models_action(save_string)
logz.log_tabular("AverageReturn", mean_return)
logz.log_tabular("StdReturn", np.std(returns))
logz.log_tabular("MaxReturn", np.max(returns))
logz.log_tabular("MinReturn", np.min(returns))
logz.log_tabular("EpLenMean", np.mean(ep_lengths))
logz.log_tabular("EpLenStd", np.std(ep_lengths))
logz.log_tabular("TimestepsThisBatch", timesteps_this_batch)
logz.log_tabular("TimestepsSoFar", total_timesteps)
# My own
if hasattr(agent,'batch_baseline_loss'):
logz.log_tabular("BaselineLoss", agent.batch_baseline_loss)
logz.log_tabular("UnscaledLoss", agent.batch_unscaled_loss)
logz.log_tabular("Loss", agent.batch_loss)
logz.dump_tabular()
logz.pickle_tf_vars()
# if script_optimizing == True:
# print(np.max(returns))
if save_models == True and save_best_model==False:
save_string = logdir[5:-2]
agent.save_models_action(save_string) | def run_pg_gb(n_iter, min_timesteps_per_batch, max_path_length, animate, logdir, nn_baseline, seed, n_layers, output_activation, size, save_models, save_best_model, run_model_only, script_optimizing_dir, relative_positions, death_penalty, reward_circle, num_enemies):
start = time.time()
if script_optimizing_dir is not None:
logdir = logdir[:5] + script_optimizing_dir + '/' + logdir[5:]
setup_logger(logdir, locals())
env = gb_game(num_char=num_enemies, reward_circle=reward_circle, death_penalty=death_penalty, relative_positions=relative_positions)
tf.set_random_seed(seed)
np.random.seed(seed)
env.seed(seed)
max_path_length = max_path_length or env.spec.max_episode_steps
discrete = isinstance(env.action_space, gym.spaces.Discrete)
ob_dim = env.observation_space.shape[0]
ac_dim = env.action_space.n if discrete else env.action_space.shape[0]
computation_graph_args = {'n_layers': n_layers, 'output_activation': output_activation, 'ob_dim': ob_dim, 'ac_dim': ac_dim, 'discrete': discrete, 'size': size, 'learning_rate': learning_rate, 'baseline_lr': baseline_lr}
sample_trajectory_args = {'animate': animate, 'max_path_length': max_path_length, 'min_timesteps_per_batch': min_timesteps_per_batch}
estimate_return_args = {'gamma': gamma, 'reward_to_go': reward_to_go, 'nn_baseline': nn_baseline, 'normalize_advantages': normalize_advantages}
agent = agent(computation_graph_args, sample_trajectory_args, estimate_return_args)
agent.build_computation_graph()
agent.init_tf_sess()
if run_model_only is not None:
agent.load_models_action(run_model_only)
agent.running_only = True
best_avg_return = -50000000000.0
total_timesteps = 0
for itr in range(n_iter):
print('********** Iteration %i ************' % itr)
(paths, timesteps_this_batch) = agent.sample_trajectories(itr, env)
total_timesteps += timesteps_this_batch
if run_model_only is not None:
continue
ob_no = np.concatenate([path['observation'] for path in paths])
ac_na = np.concatenate([path['action'] for path in paths])
re_n = [path['reward'] for path in paths]
(q_n, adv_n) = agent.estimate_return(ob_no, re_n)
agent.update_parameters(ob_no, ac_na, q_n, adv_n)
returns = [path['reward'].sum() for path in paths]
ep_lengths = [pathlength(path) for path in paths]
logz.log_tabular('Time', time.time() - start)
logz.log_tabular('Iteration', itr)
mean_return = np.mean(returns)
if mean_return > best_avg_return:
best_avg_return = mean_return
if save_best_model == True:
save_string = logdir[5:-2]
agent.save_models_action(save_string)
logz.log_tabular('AverageReturn', mean_return)
logz.log_tabular('StdReturn', np.std(returns))
logz.log_tabular('MaxReturn', np.max(returns))
logz.log_tabular('MinReturn', np.min(returns))
logz.log_tabular('EpLenMean', np.mean(ep_lengths))
logz.log_tabular('EpLenStd', np.std(ep_lengths))
logz.log_tabular('TimestepsThisBatch', timesteps_this_batch)
logz.log_tabular('TimestepsSoFar', total_timesteps)
if hasattr(agent, 'batch_baseline_loss'):
logz.log_tabular('BaselineLoss', agent.batch_baseline_loss)
logz.log_tabular('UnscaledLoss', agent.batch_unscaled_loss)
logz.log_tabular('Loss', agent.batch_loss)
logz.dump_tabular()
logz.pickle_tf_vars()
if save_models == True and save_best_model == False:
save_string = logdir[5:-2]
agent.save_models_action(save_string) |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.