●方法定义
get_all_trusts(self)
●异常
如果调用失败,抛出hyperdb.HDError异常
●返回值
所有信任的迭代器
●注意事项:
使用get_next()方法获取每一条记录,当获取记录结束时get_next()返回’None’
●方法调用
def GetAllTrust(self):
try:
ret_iter = self.myServer.security_mgr.get_all_trusts()
except Exception as e:
print("get_all_trusts error: ", e.errcode)
else:
print("getting all trusts succeeds")
while True:
trust_rec = ret_iter.get_next()
if trust_rec is None:
break
else:
print("The trust' name : ", trust_rec.name,"The trust' start_ip : ", trust_rec.start_ip,"The trust' end_ip : ", trust_rec.end_ip,"The trust' user_name : ", trust_rec.user_name)