Ejemplo n.º 1
0
 def __init__(self, entity, properties):
     Job.__init__(self, "PUT", Target(entity, "properties"),
                  PropertySet(properties))
Ejemplo n.º 2
0
 def __init__(self, node, labels):
     Job.__init__(self, "PUT", Target(node, "labels"),
                  list(LabelSet(labels)))
Ejemplo n.º 3
0
 def __init__(self, relationship):
     Job.__init__(self, "GET", Target(relationship))
Ejemplo n.º 4
0
 def __init__(self, entity, key, value):
     Job.__init__(self, "PUT", Target(entity, "properties", key), value)
Ejemplo n.º 5
0
 def __init__(self, entity):
     Job.__init__(self, "GET", Target(entity, "properties"))
Ejemplo n.º 6
0
 def __init__(self, node):
     Job.__init__(self, "GET", Target(node, "labels"))
Ejemplo n.º 7
0
 def __init__(self, start_node, rel, end_node, **properties):
     body = {"type": rel.type, "to": Target(end_node).uri_string}
     if rel.properties or properties:
         body["data"] = dict(rel.properties, **properties)
     Job.__init__(self, "POST", Target(start_node, "relationships"), body)
Ejemplo n.º 8
0
class CreateNodeJob(Job):

    target = Target("node")

    def __init__(self, **properties):
        Job.__init__(self, "POST", self.target, properties)
Ejemplo n.º 9
0
 def __init__(self, entity, label):
     Job.__init__(self, "DELETE", Target(entity, "labels", label))
Ejemplo n.º 10
0
 def __init__(self, entity, key):
     Job.__init__(self, "DELETE", Target(entity, "properties", key))
Ejemplo n.º 11
0
 def __init__(self, entity):
     Job.__init__(self, "DELETE", Target(entity))