This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #öffne einen neuen Neo4j Graph als den default-Graphen ($_g) | |
| $_g := neo4j:open('tmp/matrix') | |
| #die Knoten mit Namen | |
| $neo := g:add-v() | |
| $neo/name := 'Neo' | |
| $morpheus := g:add-v() | |
| $morpheus/name := 'Morpheus' | |
| $trinity := g:add-v() | |
| $trinity/name := 'Trinity' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| $_g := neo4j:open('neodb.neo') | |
| $bob := g:add-v(g:map('name','Bob')) | |
| $john := g:add-v(g:map('name','John')) | |
| $alice := g:add-v(g:map('name','Alice')) | |
| $e1 := g:add-e($bob,'link',$john) | |
| $e2 := g:add-e($john,'link',$alice) | |
| $e3 := g:add-e($alice,'link',$bob) | |
| $e1/weight := 10 | |
| $e2/weight := 1 | |
| $e3/weight := 20 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| require "rubygems" | |
| require "neo4j" | |
| class Person | |
| include Neo4j::NodeMixin | |
| # define Neo4j properties | |
| property :name | |
| # define an one way relationship to any other node |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| require "rubygems" | |
| require "neo4j" | |
| Neo4j::Transaction.run do | |
| cars = Neo4j::Node.new | |
| silver = Neo4j::Node.new | |
| saab = Neo4j::Node.new | |
| year_2000 = Neo4j::Node.new | |
| year_2000[:year] = '2000' | |
| year_2002 = Neo4j::Node.new |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Depend on | |
| ------------------- | |
| <dependency> | |
| <groupId>org.neo4j.app</groupId> | |
| <artifactId>neo4j-server</artifactId> | |
| <version>1.3-SNAPSHOT</version> | |
| </dependency> | |
| ----------------------- | |
| package org.neo4j.examples.server.plugins; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Hatim: yeah Peter, looking forward to it | |
| Nigel Small: at least i have text :/ | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /** | |
| * Licensed to Neo Technology under one or more contributor | |
| * license agreements. See the NOTICE file distributed with | |
| * this work for additional information regarding copyright | |
| * ownership. Neo Technology licenses this file to you under | |
| * the Apache License, Version 2.0 (the "License"); you may | |
| * not use this file except in compliance with the License. | |
| * You may obtain a copy of the License at | |
| * | |
| * http://www.apache.org/licenses/LICENSE-2.0 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Transaction tx = neo.beginTx(); | |
| try | |
| { | |
| final Node emil = neo.createNode(); | |
| emil.setProperty( "name", "Emil Eifrém" ); | |
| emil.setProperty( "age", 30 ); | |
| final Node tobias = neo.createNode(); | |
| tobias.setProperty( "name", "Tobias \"thobe\" Ivarsson" ); | |
| tobias.setProperty( "age", 23 ); | |
| tobias.setProperty( "hours", new int[] { 10, 10, 4, 4, 0 } ); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| digraph Neo { | |
| node [ | |
| fontname = "Bitstream Vera Sans" | |
| shape = "Mrecord" | |
| fontsize = "8" | |
| ] | |
| edge [ | |
| fontname = "Bitstream Vera Sans" | |
| fontsize = "8" | |
| ] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| deck.js and Neo4j docs | |
| ====================== | |
| == Include a live console == | |
| Cypher with syntax highlighting and a live console: | |
| [source,cypher] | |
| ---- | |
| START n=node(1) |
OlderNewer