本文整理汇总了Python中com.googlecode.fascinator.common.JsonSimple.toJavaMap方法的典型用法代码示例。如果您正苦于以下问题:Python JsonSimple.toJavaMap方法的具体用法?Python JsonSimple.toJavaMap怎么用?Python JsonSimple.toJavaMap使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类com.googlecode.fascinator.common.JsonSimple
的用法示例。
在下文中一共展示了JsonSimple.toJavaMap方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: __getPackageTypes
# 需要导入模块: from com.googlecode.fascinator.common import JsonSimple [as 别名]
# 或者: from com.googlecode.fascinator.common.JsonSimple import toJavaMap [as 别名]
def __getPackageTypes(self):
object = self.sysConfig.getObject(["portal", "packageTypes"])
packageTypes = JsonSimple.toJavaMap(object)
if packageTypes.isEmpty():
defaultPackage = JsonObject()
defaultPackage.put("jsonconfig", "packaging-config.json")
packageTypes.put("default", JsonSimple(defaultPackage))
return packageTypes
示例2: __activate__
# 需要导入模块: from com.googlecode.fascinator.common import JsonSimple [as 别名]
# 或者: from com.googlecode.fascinator.common.JsonSimple import toJavaMap [as 别名]
def __activate__(self, context):
self.roles = context["page"].authentication.get_roles_list()
self.config = context["systemConfig"]
workflows = JsonSimple.toJavaMap(self.config.getObject(["uploader"]))
self.uploaders = LinkedHashMap()
for workflow in workflows.keySet():
if workflows.get(workflow).getString("", ["upload-template"]):
for role in workflows.get(workflow).getArray(["security"]):
if str(role) in self.roles:
self.uploaders.put(workflow, workflows.get(workflow))