You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@polygene.apache.org by ni...@apache.org on 2015/04/24 08:36:39 UTC

[26/50] [abbrv] zest-qi4j git commit: Added some documentation to the Neo4j Entity Store.

Added some documentation to the Neo4j Entity Store.


Project: http://git-wip-us.apache.org/repos/asf/zest-qi4j/repo
Commit: http://git-wip-us.apache.org/repos/asf/zest-qi4j/commit/c78eaf3c
Tree: http://git-wip-us.apache.org/repos/asf/zest-qi4j/tree/c78eaf3c
Diff: http://git-wip-us.apache.org/repos/asf/zest-qi4j/diff/c78eaf3c

Branch: refs/heads/master
Commit: c78eaf3c36ef1653875f5b2208ac25703b8443ff
Parents: da0fd9d
Author: Niclas Hedhman <ni...@hedhman.org>
Authored: Sat Jan 10 17:39:44 2015 +0800
Committer: Niclas Hedhman <ni...@hedhman.org>
Committed: Sat Jan 10 17:39:44 2015 +0800

----------------------------------------------------------------------
 extensions/entitystore-neo4j/dev-status.xml     |  2 +-
 .../entitystore-neo4j/src/docs/es-neo4j.txt     | 26 ++++++++++++++++++--
 .../entitystore/neo4j/NeoConfiguration.java     |  3 +++
 .../neo4j/test/SimpleNeoStoreTest.java          |  7 ++++--
 4 files changed, 33 insertions(+), 5 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/zest-qi4j/blob/c78eaf3c/extensions/entitystore-neo4j/dev-status.xml
----------------------------------------------------------------------
diff --git a/extensions/entitystore-neo4j/dev-status.xml b/extensions/entitystore-neo4j/dev-status.xml
index 3e21cdb..8078e77 100644
--- a/extensions/entitystore-neo4j/dev-status.xml
+++ b/extensions/entitystore-neo4j/dev-status.xml
@@ -8,7 +8,7 @@
         <codebase>beta</codebase>
 
         <!-- none, brief, good, complete -->
-        <documentation>none</documentation>
+        <documentation>brief</documentation>
 
         <!-- none, some, good, complete -->
         <unittests>some</unittests>

http://git-wip-us.apache.org/repos/asf/zest-qi4j/blob/c78eaf3c/extensions/entitystore-neo4j/src/docs/es-neo4j.txt
----------------------------------------------------------------------
diff --git a/extensions/entitystore-neo4j/src/docs/es-neo4j.txt b/extensions/entitystore-neo4j/src/docs/es-neo4j.txt
index b06b786..2f9cc99 100644
--- a/extensions/entitystore-neo4j/src/docs/es-neo4j.txt
+++ b/extensions/entitystore-neo4j/src/docs/es-neo4j.txt
@@ -6,8 +6,30 @@
 source=extensions/entitystore-neo4j/dev-status.xml
 --------------
 
-Neo4j EntityStore
+EntityStore service backed by the http://neo4j.org/[Neo4j] Graph Database.
 
-NOTE: This Extension has no documentation yet. Learn how to contribute in <<community-docs>>.
+It uses the embeddable Neo4j and not currently able to utilize the networked one, nor the Cypher query language that is present in more recent versions of Neo4j.
 
 include::../../build/docs/buildinfo/artifact.txt[]
+
+== Assembly ==
+
+There is currently no provided Assembler, and one has to declare the use explicitly. Note that we recommend
+[snippet,java]
+----
+source=extensions/entitystore-neo4j/src/test/java/org/qi4j/entitystore/neo4j/SimpleNeoStoreTest.java
+tag=assembly
+----
+
+== Configuration ==
+
+There is currently only a single configuration property for the Neo4j Entity Store.
+
+[snippet,java]
+----
+source=extensions/entitystore-neo4j/src/main/java/org/qi4j/entitystore/neo4j/NeoConfiguration.java
+tag=config
+----
+
++path+ the full path on the file system where the Neo4j embedded database will be written to. The default value is 'build/neodb' and tailored for the build system and should not be used. The default value may change to a more sensible value in the future. 
+

http://git-wip-us.apache.org/repos/asf/zest-qi4j/blob/c78eaf3c/extensions/entitystore-neo4j/src/main/java/org/qi4j/entitystore/neo4j/NeoConfiguration.java
----------------------------------------------------------------------
diff --git a/extensions/entitystore-neo4j/src/main/java/org/qi4j/entitystore/neo4j/NeoConfiguration.java b/extensions/entitystore-neo4j/src/main/java/org/qi4j/entitystore/neo4j/NeoConfiguration.java
index 77e61f6..b59fffe 100644
--- a/extensions/entitystore-neo4j/src/main/java/org/qi4j/entitystore/neo4j/NeoConfiguration.java
+++ b/extensions/entitystore-neo4j/src/main/java/org/qi4j/entitystore/neo4j/NeoConfiguration.java
@@ -22,9 +22,12 @@ import org.qi4j.api.common.Optional;
 import org.qi4j.api.configuration.ConfigurationComposite;
 import org.qi4j.api.property.Property;
 
+// START SNIPPET: config
 public interface NeoConfiguration
     extends ConfigurationComposite
 {
+    /** The absolute location of the embedded database. */
     @Optional
     Property<String> path();
 }
+// END SNIPPET: config

http://git-wip-us.apache.org/repos/asf/zest-qi4j/blob/c78eaf3c/extensions/entitystore-neo4j/src/test/java/org/qi4j/entitystore/neo4j/test/SimpleNeoStoreTest.java
----------------------------------------------------------------------
diff --git a/extensions/entitystore-neo4j/src/test/java/org/qi4j/entitystore/neo4j/test/SimpleNeoStoreTest.java b/extensions/entitystore-neo4j/src/test/java/org/qi4j/entitystore/neo4j/test/SimpleNeoStoreTest.java
index f7841e3..7f0e9f5 100644
--- a/extensions/entitystore-neo4j/src/test/java/org/qi4j/entitystore/neo4j/test/SimpleNeoStoreTest.java
+++ b/extensions/entitystore-neo4j/src/test/java/org/qi4j/entitystore/neo4j/test/SimpleNeoStoreTest.java
@@ -13,21 +13,24 @@ import org.qi4j.valueserialization.orgjson.OrgJsonValueSerializationAssembler;
 public class SimpleNeoStoreTest
     extends AbstractEntityStoreTest
 {
-
+// START SNIPPET: assembly
     public void assemble( ModuleAssembly module )
         throws AssemblyException
     {
+// END SNIPPET: assembly
         module.layer().application().setName( "SimpleNeoTest" );
 
         super.assemble( module );
+// START SNIPPET: assembly
         module.services( FileConfigurationService.class );
 
         module.services( NeoEntityStoreService.class );
 
         ModuleAssembly configModule = module.layer().module( "config" );
         configModule.entities( NeoConfiguration.class ).visibleIn( Visibility.layer );
-        new EntityTestAssembler().assemble( configModule );
         new OrgJsonValueSerializationAssembler().assemble( module );
+// END SNIPPET: assembly
+        new EntityTestAssembler().assemble( configModule );
     }
 
     @Override