コード例 #1
0
def addDataToKnowledgeInstance(root):
    kdmanager = KnowledgeDomainManager()
    domain = kdmanager.getDomain()
    usrmanager = UserManager()
    userBox = usrmanager.getUserBoxForUser("jonathan")

    domain.dataSourceManager.addToKnowledgeInstance(userBox, None, domain)
    return "<success></success>"
コード例 #2
0
def getKnowledgeInstanceForUser(root):
    usrmanager = UserManager()
    userBox = usrmanager.getUserBoxForUser("jonathan")
    return userBox.knowledgeInstance.asXML()
コード例 #3
0
def resetKnowledgeInstanceForUser(root):
    usrmanager = UserManager()
    userBox = usrmanager.getUserBoxForUser("jonathan")
    userBox.resetKnowledgeInstance()

    return "<success></success>"