本文整理匯總了Python中py2neo.batch.core.Job類的典型用法代碼示例。如果您正苦於以下問題:Python Job類的具體用法?Python Job怎麽用?Python Job使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。
在下文中一共展示了Job類的5個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Python代碼示例。
示例1: __init__
def __init__(self, start_node, rel, end_node, **properties):
uri = self.uri_for(start_node, "relationships")
body = {"type": rel.type, "to": self.uri_for(end_node)}
if rel.properties or properties:
body["data"] = dict(rel.properties, **properties)
Job.__init__(self, "POST", uri, body)
示例2: __init__
def __init__(self, **properties):
Job.__init__(self, "POST", self.target, properties)
示例3: __init__
def __init__(self, entity, key):
Job.__init__(self, "GET", Target(entity, "properties", key))
示例4: __init__
def __init__(self, entity, properties):
Job.__init__(self, "PUT", Target(entity, "properties"), PropertySet(properties))
示例5: __init__
def __init__(self, method, entity, *segments, **kwargs):
self.entity = entity
uri = self.uri_for(entity, *segments, **kwargs)
Job.__init__(self, method, uri)