本文整理汇总了Python中java.util.HashSet.toString方法的典型用法代码示例。如果您正苦于以下问题:Python HashSet.toString方法的具体用法?Python HashSet.toString怎么用?Python HashSet.toString使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类java.util.HashSet
的用法示例。
在下文中一共展示了HashSet.toString方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: getAvailMethodsUser
# 需要导入模块: from java.util import HashSet [as 别名]
# 或者: from java.util.HashSet import toString [as 别名]
def getAvailMethodsUser(self, user, skip=None):
methods = HashSet()
for method in self.authenticators:
try:
module = self.authenticators[method]
if module.hasEnrollments(module.configAttrs, user):
methods.add(method)
except:
print "Casa. getAvailMethodsUser. hasEnrollments call could not be issued for %s module" % method
try:
if skip != None:
# skip is guaranteed to be a member of methods (if hasEnrollments routines are properly implemented).
# A call to remove strangely crashes when skip is absent
methods.remove(skip)
except:
print "Casa. getAvailMethodsUser. methods list does not contain %s" % skip
print "Casa. getAvailMethodsUser %s" % methods.toString()
return methods