本文整理汇总了Python中DBManager.DBManager.documentByUUID方法的典型用法代码示例。如果您正苦于以下问题:Python DBManager.documentByUUID方法的具体用法?Python DBManager.documentByUUID怎么用?Python DBManager.documentByUUID使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类DBManager.DBManager
的用法示例。
在下文中一共展示了DBManager.documentByUUID方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: str
# 需要导入模块: from DBManager import DBManager [as 别名]
# 或者: from DBManager.DBManager import documentByUUID [as 别名]
missingUUID += 1
for uuid in uuids:
if (uuid != None and uuid.text != None):
uuid = uuid.text
date = xml.findall("//PublicationStartDate")
if (date != None and len(date) > 0 and date[0] != None and date[0].text != None):
newFile.write(uuid + "," + date[0].text + "\n")
print "wrote " + uuid + "," + date[0].text
else:
newFile.write(uuid + "\n")
print "wrote " + uuid
try:
doc = conn.documentByUUID(uuid)
if (doc != None):
matches += 1
else:
noMatches += 1
except couchdb.http.ResourceNotFound:
noMatches += 1
newFile.close()
print str(docs) + " total docs"
print str(errors) + " Parse Errors"
print str(missingUUID) + " docs have no UUID"
print str(matches) + " matches"
print str(noMatches) + " not matches"