From 7fdbbcbeb29ae749fb43a8767e30545f9341a7a3 Mon Sep 17 00:00:00 2001 From: Lasse Westh-Nielsen Date: Thu, 21 Jun 2012 16:58:51 +0100 Subject: [PATCH] Updated documentation to reflect relationship type precedence and new backwards-compatible transaction manager factory --- .../programming-model/relationships.xml | 35 +++++++++++++++++++ .../programming-model/transactions.xml | 32 ++++------------- 2 files changed, 42 insertions(+), 25 deletions(-) diff --git a/src/docbkx/reference/programming-model/relationships.xml b/src/docbkx/reference/programming-model/relationships.xml index 3314e8b06..000340664 100644 --- a/src/docbkx/reference/programming-model/relationships.xml +++ b/src/docbkx/reference/programming-model/relationships.xml @@ -210,4 +210,39 @@ public class Friendship { +
+ Relationship Type Precedence + In the example above we show how to specify a default relationship type, and how to provide the relationship + type using an annotation property. Here is an example of using the @RelationshipType annotation on a member + variable on the relationship entity; we call this dynamic relationship type. + + Dynamic Relationship Type (simple mapping) + + + + Because dynamic type information is, well, dynamic, it is generally not possible to read the mapping backwards + using SDN. The relationship still exists, but SDN cannot help you access it because it does not know what type you + gave it. Also, for this reason, we require you to specify a default relationship type, so that we can at least + attempt the reverse mapping. + Should you happen to provide conflicting relationship types, we have established the following precedence, in + priority order: + + Dynamic + Annotation-provided + Default + +
\ No newline at end of file diff --git a/src/docbkx/reference/programming-model/transactions.xml b/src/docbkx/reference/programming-model/transactions.xml index c8980ebc4..53a4bb98f 100644 --- a/src/docbkx/reference/programming-model/transactions.xml +++ b/src/docbkx/reference/programming-model/transactions.xml @@ -32,18 +32,9 @@ Simple transaction manager configuration - - - - - - - - - - - + + @@ -57,7 +48,7 @@ Neo4j Spring integration - + ChainedTransactionManager example - - - - - - - - - - - + class="org.springframework.data.neo4j.config.JtaTransactionManagerFactoryBean"> +