-
Notifications
You must be signed in to change notification settings - Fork 135
Phase 2 Nodes
rdvdijk edited this page Sep 26, 2012
·
4 revisions
Neography::Node.create # Create an empty node
Neography::Node.create("age" => 31, "name" => "Max") # Create a node with some properties
@neo2 = Neography::Rest.new({:server => '192.168.10.1'})
Neography::Node.create({"age" => 31, "name" => "Max"}, @neo2) # Create a node on the server defined in @neo2
Neography::Node.load(5) # Get a node and its properties by id
Neography::Node.load(existing_node) # Get a node and its properties by Node
Neography::Node.load("http://localhost:7474/db/data/node/2") # Get a node and its properties by String
Neography::Node.load(5, @neo2) # Get a node on the server defined in @neo2
n1 = Node.create
n1.del # Deletes the node
n1.exist? # returns true/false if node exists in Neo4j