Repository: cayenne Updated Branches: refs/heads/master 49dd10410 -> fb8660e76
http://git-wip-us.apache.org/repos/asf/cayenne/blob/fb8660e7/cayenne-server/src/test/resources/cayenne-meaningful-pk.xml ---------------------------------------------------------------------- diff --git a/cayenne-server/src/test/resources/cayenne-meaningful-pk.xml b/cayenne-server/src/test/resources/cayenne-meaningful-pk.xml new file mode 100644 index 0000000..d8b9204 --- /dev/null +++ b/cayenne-server/src/test/resources/cayenne-meaningful-pk.xml @@ -0,0 +1,4 @@ +<?xml version="1.0" encoding="utf-8"?> +<domain project-version="7"> + <map name="meaningful-pk"/> +</domain> \ No newline at end of file http://git-wip-us.apache.org/repos/asf/cayenne/blob/fb8660e7/cayenne-server/src/test/resources/cayenne-persistent.xml ---------------------------------------------------------------------- diff --git a/cayenne-server/src/test/resources/cayenne-persistent.xml b/cayenne-server/src/test/resources/cayenne-persistent.xml new file mode 100644 index 0000000..bc6e543 --- /dev/null +++ b/cayenne-server/src/test/resources/cayenne-persistent.xml @@ -0,0 +1,4 @@ +<?xml version="1.0" encoding="utf-8"?> +<domain project-version="7"> + <map name="persistent"/> +</domain> \ No newline at end of file http://git-wip-us.apache.org/repos/asf/cayenne/blob/fb8660e7/cayenne-server/src/test/resources/cayenne-reflexive.xml ---------------------------------------------------------------------- diff --git a/cayenne-server/src/test/resources/cayenne-reflexive.xml b/cayenne-server/src/test/resources/cayenne-reflexive.xml new file mode 100644 index 0000000..7e05dcf --- /dev/null +++ b/cayenne-server/src/test/resources/cayenne-reflexive.xml @@ -0,0 +1,4 @@ +<?xml version="1.0" encoding="utf-8"?> +<domain project-version="7"> + <map name="reflexive"/> +</domain> \ No newline at end of file http://git-wip-us.apache.org/repos/asf/cayenne/blob/fb8660e7/cayenne-server/src/test/resources/cayenne-table-primitives.xml ---------------------------------------------------------------------- diff --git a/cayenne-server/src/test/resources/cayenne-table-primitives.xml b/cayenne-server/src/test/resources/cayenne-table-primitives.xml new file mode 100644 index 0000000..642c18b --- /dev/null +++ b/cayenne-server/src/test/resources/cayenne-table-primitives.xml @@ -0,0 +1,4 @@ +<?xml version="1.0" encoding="utf-8"?> +<domain project-version="7"> + <map name="table-primitives"/> +</domain> \ No newline at end of file http://git-wip-us.apache.org/repos/asf/cayenne/blob/fb8660e7/cayenne-server/src/test/resources/cayenne-toone.xml ---------------------------------------------------------------------- diff --git a/cayenne-server/src/test/resources/cayenne-toone.xml b/cayenne-server/src/test/resources/cayenne-toone.xml new file mode 100644 index 0000000..b856947 --- /dev/null +++ b/cayenne-server/src/test/resources/cayenne-toone.xml @@ -0,0 +1,4 @@ +<?xml version="1.0" encoding="utf-8"?> +<domain project-version="7"> + <map name="toone"/> +</domain> \ No newline at end of file http://git-wip-us.apache.org/repos/asf/cayenne/blob/fb8660e7/cayenne-server/src/test/resources/delete-rules.map.xml ---------------------------------------------------------------------- diff --git a/cayenne-server/src/test/resources/delete-rules.map.xml b/cayenne-server/src/test/resources/delete-rules.map.xml new file mode 100644 index 0000000..9d6f5ed --- /dev/null +++ b/cayenne-server/src/test/resources/delete-rules.map.xml @@ -0,0 +1,64 @@ +<?xml version="1.0" encoding="utf-8"?> +<data-map xmlns="http://cayenne.apache.org/schema/7/modelMap" + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:schemaLocation="http://cayenne.apache.org/schema/7/modelMap http://cayenne.apache.org/schema/7/modelMap.xsd" + project-version="7"> + <property name="defaultPackage" value="org.apache.cayenne.testdo.deleterules"/> + <property name="clientSupported" value="true"/> + <property name="defaultClientPackage" value="org.apache.cayenne.testdo.deleterules"/> + <db-entity name="DELETE_CASCADE"> + <db-attribute name="DELETE_CASCADE_ID" type="INTEGER" isPrimaryKey="true" isMandatory="true"/> + <db-attribute name="DELETE_RULE_ID" type="INTEGER"/> + <db-attribute name="NAME" type="VARCHAR" length="200"/> + </db-entity> + <db-entity name="DELETE_DENY"> + <db-attribute name="DELETE_DENY_ID" type="INTEGER" isPrimaryKey="true" isMandatory="true"/> + <db-attribute name="DELETE_RULE_ID" type="INTEGER"/> + <db-attribute name="NAME" type="VARCHAR" length="200"/> + </db-entity> + <db-entity name="DELETE_NULLIFY"> + <db-attribute name="DELETE_NULLIFY_ID" type="INTEGER" isPrimaryKey="true" isMandatory="true"/> + <db-attribute name="DELETE_RULE_ID" type="INTEGER"/> + <db-attribute name="NAME" type="VARCHAR" length="200"/> + </db-entity> + <db-entity name="DELETE_RULE"> + <db-attribute name="DELETE_RULE_ID" type="INTEGER" isPrimaryKey="true" isMandatory="true"/> + <db-attribute name="NAME" type="VARCHAR" length="200"/> + </db-entity> + <obj-entity name="DeleteCascade" className="org.apache.cayenne.testdo.deleterules.DeleteCascade" clientClassName="org.apache.cayenne.testdo.deleterules.ClientDeleteCascade" dbEntityName="DELETE_CASCADE"> + <obj-attribute name="name" type="java.lang.String" db-attribute-path="NAME"/> + </obj-entity> + <obj-entity name="DeleteDeny" className="org.apache.cayenne.testdo.deleterules.DeleteDeny" clientClassName="org.apache.cayenne.testdo.deleterules.ClientDeleteDeny" dbEntityName="DELETE_DENY"> + <obj-attribute name="name" type="java.lang.String" db-attribute-path="NAME"/> + </obj-entity> + <obj-entity name="DeleteNullify" className="org.apache.cayenne.testdo.deleterules.DeleteNullify" clientClassName="org.apache.cayenne.testdo.deleterules.ClientDeleteNullify" dbEntityName="DELETE_NULLIFY"> + <obj-attribute name="name" type="java.lang.String" db-attribute-path="NAME"/> + </obj-entity> + <obj-entity name="DeleteRule" className="org.apache.cayenne.testdo.deleterules.DeleteRule" clientClassName="org.apache.cayenne.testdo.deleterules.ClientDeleteRule" dbEntityName="DELETE_RULE"> + <obj-attribute name="name" type="java.lang.String" db-attribute-path="NAME"/> + </obj-entity> + <db-relationship name="cascade" source="DELETE_CASCADE" target="DELETE_RULE" toMany="false"> + <db-attribute-pair source="DELETE_RULE_ID" target="DELETE_RULE_ID"/> + </db-relationship> + <db-relationship name="deny" source="DELETE_DENY" target="DELETE_RULE" toMany="false"> + <db-attribute-pair source="DELETE_RULE_ID" target="DELETE_RULE_ID"/> + </db-relationship> + <db-relationship name="nullify" source="DELETE_NULLIFY" target="DELETE_RULE" toMany="false"> + <db-attribute-pair source="DELETE_RULE_ID" target="DELETE_RULE_ID"/> + </db-relationship> + <db-relationship name="fromCascade" source="DELETE_RULE" target="DELETE_CASCADE" toMany="true"> + <db-attribute-pair source="DELETE_RULE_ID" target="DELETE_RULE_ID"/> + </db-relationship> + <db-relationship name="fromDeny" source="DELETE_RULE" target="DELETE_DENY" toMany="true"> + <db-attribute-pair source="DELETE_RULE_ID" target="DELETE_RULE_ID"/> + </db-relationship> + <db-relationship name="fromNullify" source="DELETE_RULE" target="DELETE_NULLIFY" toMany="true"> + <db-attribute-pair source="DELETE_RULE_ID" target="DELETE_RULE_ID"/> + </db-relationship> + <obj-relationship name="cascade" source="DeleteCascade" target="DeleteRule" deleteRule="Cascade" db-relationship-path="cascade"/> + <obj-relationship name="deny" source="DeleteDeny" target="DeleteRule" deleteRule="Deny" db-relationship-path="deny"/> + <obj-relationship name="nullify" source="DeleteNullify" target="DeleteRule" deleteRule="Nullify" db-relationship-path="nullify"/> + <obj-relationship name="fromCascade" source="DeleteRule" target="DeleteCascade" db-relationship-path="fromCascade"/> + <obj-relationship name="fromDeny" source="DeleteRule" target="DeleteDeny" db-relationship-path="fromDeny"/> + <obj-relationship name="fromNullify" source="DeleteRule" target="DeleteNullify" db-relationship-path="fromNullify"/> +</data-map> \ No newline at end of file http://git-wip-us.apache.org/repos/asf/cayenne/blob/fb8660e7/cayenne-server/src/test/resources/lifecycles.map.xml ---------------------------------------------------------------------- diff --git a/cayenne-server/src/test/resources/lifecycles.map.xml b/cayenne-server/src/test/resources/lifecycles.map.xml new file mode 100644 index 0000000..fdbfc7e --- /dev/null +++ b/cayenne-server/src/test/resources/lifecycles.map.xml @@ -0,0 +1,16 @@ +<?xml version="1.0" encoding="utf-8"?> +<data-map xmlns="http://cayenne.apache.org/schema/7/modelMap" + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:schemaLocation="http://cayenne.apache.org/schema/7/modelMap http://cayenne.apache.org/schema/7/modelMap.xsd" + project-version="7"> + <property name="defaultPackage" value="org.apache.cayenne.testdo.lifecycles"/> + <property name="clientSupported" value="true"/> + <property name="defaultClientPackage" value="org.apache.cayenne.testdo.lifecycles"/> + <db-entity name="LIFECYCLES"> + <db-attribute name="ID" type="INTEGER" isPrimaryKey="true" isMandatory="true"/> + <db-attribute name="NAME" type="VARCHAR" isMandatory="true" length="100"/> + </db-entity> + <obj-entity name="Lifecycles" className="org.apache.cayenne.testdo.lifecycles.Lifecycles" clientClassName="org.apache.cayenne.testdo.lifecycles.ClientLifecycles" dbEntityName="LIFECYCLES"> + <obj-attribute name="name" type="java.lang.String" db-attribute-path="NAME"/> + </obj-entity> +</data-map> \ No newline at end of file http://git-wip-us.apache.org/repos/asf/cayenne/blob/fb8660e7/cayenne-server/src/test/resources/map-to-many.map.xml ---------------------------------------------------------------------- diff --git a/cayenne-server/src/test/resources/map-to-many.map.xml b/cayenne-server/src/test/resources/map-to-many.map.xml new file mode 100644 index 0000000..bdfd5a4 --- /dev/null +++ b/cayenne-server/src/test/resources/map-to-many.map.xml @@ -0,0 +1,57 @@ +<?xml version="1.0" encoding="utf-8"?> +<data-map xmlns="http://cayenne.apache.org/schema/7/modelMap" + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:schemaLocation="http://cayenne.apache.org/schema/7/modelMap http://cayenne.apache.org/schema/7/modelMap.xsd" + project-version="7"> + <property name="defaultPackage" value="org.apache.cayenne.testdo.map_to_many"/> + <property name="clientSupported" value="true"/> + <property name="defaultClientPackage" value="org.apache.cayenne.testdo.map_to_many"/> + + <db-entity name="ID_MAP_TO_MANY"> + <db-attribute name="ID" type="INTEGER" isPrimaryKey="true" isMandatory="true"/> + </db-entity> + <db-entity name="ID_MAP_TO_MANY_TARGET"> + <db-attribute name="ID" type="INTEGER" isPrimaryKey="true" isMandatory="true"/> + <db-attribute name="MAP_TO_MANY_ID" type="INTEGER"/> + </db-entity> + + <db-entity name="MAP_TO_MANY"> + <db-attribute name="ID" type="INTEGER" isPrimaryKey="true" isMandatory="true"/> + </db-entity> + <db-entity name="MAP_TO_MANY_TARGET"> + <db-attribute name="ID" type="INTEGER" isPrimaryKey="true" isMandatory="true"/> + <db-attribute name="MAP_TO_MANY_ID" type="INTEGER"/> + <db-attribute name="NAME" type="VARCHAR" isMandatory="true" length="100"/> + </db-entity> + + <obj-entity name="IdMapToMany" className="org.apache.cayenne.testdo.map_to_many.IdMapToMany" clientClassName="org.apache.cayenne.testdo.map_to_many.ClientIdMapToMany" dbEntityName="ID_MAP_TO_MANY"> + </obj-entity> + <obj-entity name="IdMapToManyTarget" className="org.apache.cayenne.testdo.map_to_many.IdMapToManyTarget" clientClassName="org.apache.cayenne.testdo.map_to_many.ClientIdMapToManyTarget" dbEntityName="ID_MAP_TO_MANY_TARGET"> + </obj-entity> + + <obj-entity name="MapToMany" className="org.apache.cayenne.testdo.map_to_many.MapToMany" dbEntityName="MAP_TO_MANY"> + </obj-entity> + <obj-entity name="MapToManyTarget" className="org.apache.cayenne.testdo.map_to_many.MapToManyTarget" dbEntityName="MAP_TO_MANY_TARGET"> + <obj-attribute name="name" type="java.lang.String" db-attribute-path="NAME"/> + </obj-entity> + + <db-relationship name="targets" source="ID_MAP_TO_MANY" target="ID_MAP_TO_MANY_TARGET" toMany="true"> + <db-attribute-pair source="ID" target="MAP_TO_MANY_ID"/> + </db-relationship> + <db-relationship name="mapToMany" source="ID_MAP_TO_MANY_TARGET" target="ID_MAP_TO_MANY" toMany="false"> + <db-attribute-pair source="MAP_TO_MANY_ID" target="ID"/> + </db-relationship> + + <db-relationship name="targets" source="MAP_TO_MANY" target="MAP_TO_MANY_TARGET" toMany="true"> + <db-attribute-pair source="ID" target="MAP_TO_MANY_ID"/> + </db-relationship> + <db-relationship name="mapToMany" source="MAP_TO_MANY_TARGET" target="MAP_TO_MANY" toMany="false"> + <db-attribute-pair source="MAP_TO_MANY_ID" target="ID"/> + </db-relationship> + + <obj-relationship name="targets" source="IdMapToMany" target="IdMapToManyTarget" collection-type="java.util.Map" db-relationship-path="targets"/> + <obj-relationship name="mapToMany" source="IdMapToManyTarget" target="IdMapToMany" db-relationship-path="mapToMany"/> + + <obj-relationship name="targets" source="MapToMany" target="MapToManyTarget" collection-type="java.util.Map" map-key="name" db-relationship-path="targets"/> + <obj-relationship name="mapToMany" source="MapToManyTarget" target="MapToMany" db-relationship-path="mapToMany"/> +</data-map> \ No newline at end of file http://git-wip-us.apache.org/repos/asf/cayenne/blob/fb8660e7/cayenne-server/src/test/resources/meaningful-pk.map.xml ---------------------------------------------------------------------- diff --git a/cayenne-server/src/test/resources/meaningful-pk.map.xml b/cayenne-server/src/test/resources/meaningful-pk.map.xml new file mode 100644 index 0000000..fdddca4 --- /dev/null +++ b/cayenne-server/src/test/resources/meaningful-pk.map.xml @@ -0,0 +1,15 @@ +<?xml version="1.0" encoding="utf-8"?> +<data-map xmlns="http://cayenne.apache.org/schema/7/modelMap" + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:schemaLocation="http://cayenne.apache.org/schema/7/modelMap http://cayenne.apache.org/schema/7/modelMap.xsd" + project-version="7"> + <property name="defaultPackage" value="org.apache.cayenne.testdo.meaningful_pk"/> + <property name="clientSupported" value="true"/> + <property name="defaultClientPackage" value="org.apache.cayenne.testdo.meaningful_pk"/> + <db-entity name="MEANINGFUL_PK"> + <db-attribute name="PK" type="VARCHAR" isPrimaryKey="true" isMandatory="true" length="100"/> + </db-entity> + <obj-entity name="MeaningfulPk" className="org.apache.cayenne.testdo.meaningful_pk.MeaningfulPk" clientClassName="org.apache.cayenne.testdo.meaningful_pk.ClientMeaningfulPk" dbEntityName="MEANINGFUL_PK"> + <obj-attribute name="pk" type="java.lang.String" db-attribute-path="PK"/> + </obj-entity> +</data-map> \ No newline at end of file http://git-wip-us.apache.org/repos/asf/cayenne/blob/fb8660e7/cayenne-server/src/test/resources/multi-tier.map.xml ---------------------------------------------------------------------- diff --git a/cayenne-server/src/test/resources/multi-tier.map.xml b/cayenne-server/src/test/resources/multi-tier.map.xml index ce494ac..04257c6 100644 --- a/cayenne-server/src/test/resources/multi-tier.map.xml +++ b/cayenne-server/src/test/resources/multi-tier.map.xml @@ -6,57 +6,10 @@ <property name="defaultPackage" value="org.apache.cayenne.testdo.mt"/> <property name="clientSupported" value="true"/> <property name="defaultClientPackage" value="org.apache.cayenne.testdo.mt"/> - <db-entity name="CONTINENT"> - <db-attribute name="CONTINENTD" type="BIGINT" isPrimaryKey="true" isMandatory="true"/> - <db-attribute name="NAME" type="VARCHAR" isMandatory="true" length="100"/> - </db-entity> - <db-entity name="COUNTRY"> - <db-attribute name="CONTINENTID" type="BIGINT" isMandatory="true"/> - <db-attribute name="COUNTRYID" type="BIGINT" isPrimaryKey="true" isMandatory="true"/> - <db-attribute name="NAME" type="VARCHAR" isMandatory="true" length="100"/> - </db-entity> - <db-entity name="MT_DELETE_CASCADE"> - <db-attribute name="DELETE_CASCADE_ID" type="INTEGER" isPrimaryKey="true" isMandatory="true"/> - <db-attribute name="DELETE_RULE_ID" type="INTEGER"/> - <db-attribute name="NAME" type="VARCHAR" length="200"/> - </db-entity> - <db-entity name="MT_DELETE_DENY"> - <db-attribute name="DELETE_DENY_ID" type="INTEGER" isPrimaryKey="true" isMandatory="true"/> - <db-attribute name="DELETE_RULE_ID" type="INTEGER"/> - <db-attribute name="NAME" type="VARCHAR" length="200"/> - </db-entity> - <db-entity name="MT_DELETE_NULLIFY"> - <db-attribute name="DELETE_NULLIFY_ID" type="INTEGER" isPrimaryKey="true" isMandatory="true"/> - <db-attribute name="DELETE_RULE_ID" type="INTEGER"/> - <db-attribute name="NAME" type="VARCHAR" length="200"/> - </db-entity> - <db-entity name="MT_DELETE_RULE"> - <db-attribute name="DELETE_RULE_ID" type="INTEGER" isPrimaryKey="true" isMandatory="true"/> - <db-attribute name="NAME" type="VARCHAR" length="200"/> - </db-entity> <db-entity name="MT_JOIN45"> <db-attribute name="TABLE4_ID" type="INTEGER" isPrimaryKey="true" isMandatory="true"/> <db-attribute name="TABLE5_ID" type="INTEGER" isPrimaryKey="true" isMandatory="true"/> </db-entity> - <db-entity name="MT_LIFECYCLES"> - <db-attribute name="ID" type="INTEGER" isPrimaryKey="true" isMandatory="true"/> - <db-attribute name="NAME" type="VARCHAR" isMandatory="true" length="100"/> - </db-entity> - <db-entity name="MT_MAP_TO_MANY"> - <db-attribute name="ID" type="INTEGER" isPrimaryKey="true" isMandatory="true"/> - </db-entity> - <db-entity name="MT_MAP_TO_MANY_TARGET"> - <db-attribute name="ID" type="INTEGER" isPrimaryKey="true" isMandatory="true"/> - <db-attribute name="MAP_TO_MANY_ID" type="INTEGER"/> - </db-entity> - <db-entity name="MT_MEANINGFUL_PK"> - <db-attribute name="PK" type="VARCHAR" isPrimaryKey="true" isMandatory="true" length="100"/> - </db-entity> - <db-entity name="MT_REFLEXIVE"> - <db-attribute name="ID" type="INTEGER" isPrimaryKey="true" isMandatory="true"/> - <db-attribute name="NAME" type="VARCHAR" isMandatory="true" length="200"/> - <db-attribute name="PARENT_ID" type="INTEGER"/> - </db-entity> <db-entity name="MT_TABLE1"> <db-attribute name="GLOBAL_ATTRIBUTE1" type="VARCHAR" length="100"/> <db-attribute name="SERVER_ATTRIBUTE1" type="VARCHAR" length="100"/> @@ -81,48 +34,6 @@ <db-entity name="MT_TABLE5"> <db-attribute name="ID" type="INTEGER" isPrimaryKey="true" isMandatory="true"/> </db-entity> - <db-entity name="MT_TABLE_PRIMITIVES"> - <db-attribute name="BOOLEAN_COLUMN" type="BOOLEAN"/> - <db-attribute name="ID" type="INTEGER" isPrimaryKey="true" isMandatory="true"/> - <db-attribute name="INT_COLUMN" type="INTEGER"/> - </db-entity> - <db-entity name="MT_TOONE_DEP"> - <db-attribute name="ID" type="INTEGER" isPrimaryKey="true" isMandatory="true"/> - </db-entity> - <db-entity name="MT_TOONE_MASTER"> - <db-attribute name="ID" type="INTEGER" isPrimaryKey="true" isMandatory="true"/> - </db-entity> - <obj-entity name="Continent" className="org.apache.cayenne.testdo.persistent.Continent" clientClassName="org.apache.cayenne.testdo.persistent.Continent" dbEntityName="CONTINENT" superClassName="org.apache.cayenne.PersistentObject"> - <obj-attribute name="name" type="java.lang.String" db-attribute-path="NAME"/> - </obj-entity> - <obj-entity name="Country" className="org.apache.cayenne.testdo.persistent.Country" clientClassName="org.apache.cayenne.testdo.persistent.Country" dbEntityName="COUNTRY" superClassName="org.apache.cayenne.PersistentObject"> - <obj-attribute name="name" type="java.lang.String" db-attribute-path="NAME"/> - </obj-entity> - <obj-entity name="MtDeleteCascade" className="org.apache.cayenne.testdo.mt.MtDeleteCascade" clientClassName="org.apache.cayenne.testdo.mt.ClientMtDeleteCascade" dbEntityName="MT_DELETE_CASCADE"> - <obj-attribute name="name" type="java.lang.String" db-attribute-path="NAME"/> - </obj-entity> - <obj-entity name="MtDeleteDeny" className="org.apache.cayenne.testdo.mt.MtDeleteDeny" clientClassName="org.apache.cayenne.testdo.mt.ClientMtDeleteDeny" dbEntityName="MT_DELETE_DENY"> - <obj-attribute name="name" type="java.lang.String" db-attribute-path="NAME"/> - </obj-entity> - <obj-entity name="MtDeleteNullify" className="org.apache.cayenne.testdo.mt.MtDeleteNullify" clientClassName="org.apache.cayenne.testdo.mt.ClientMtDeleteNullify" dbEntityName="MT_DELETE_NULLIFY"> - <obj-attribute name="name" type="java.lang.String" db-attribute-path="NAME"/> - </obj-entity> - <obj-entity name="MtDeleteRule" className="org.apache.cayenne.testdo.mt.MtDeleteRule" clientClassName="org.apache.cayenne.testdo.mt.ClientMtDeleteRule" dbEntityName="MT_DELETE_RULE"> - <obj-attribute name="name" type="java.lang.String" db-attribute-path="NAME"/> - </obj-entity> - <obj-entity name="MtLifecycles" className="org.apache.cayenne.testdo.mt.MtLifecycles" clientClassName="org.apache.cayenne.testdo.mt.ClientMtLifecycles" dbEntityName="MT_LIFECYCLES"> - <obj-attribute name="name" type="java.lang.String" db-attribute-path="NAME"/> - </obj-entity> - <obj-entity name="MtMapToMany" className="org.apache.cayenne.testdo.mt.MtMapToMany" clientClassName="org.apache.cayenne.testdo.mt.ClientMtMapToMany" dbEntityName="MT_MAP_TO_MANY"> - </obj-entity> - <obj-entity name="MtMapToManyTarget" className="org.apache.cayenne.testdo.mt.MtMapToManyTarget" clientClassName="org.apache.cayenne.testdo.mt.ClientMtMapToManyTarget" dbEntityName="MT_MAP_TO_MANY_TARGET"> - </obj-entity> - <obj-entity name="MtMeaningfulPk" className="org.apache.cayenne.testdo.mt.MtMeaningfulPk" clientClassName="org.apache.cayenne.testdo.mt.ClientMtMeaningfulPk" dbEntityName="MT_MEANINGFUL_PK"> - <obj-attribute name="pk" type="java.lang.String" db-attribute-path="PK"/> - </obj-entity> - <obj-entity name="MtReflexive" className="org.apache.cayenne.testdo.mt.MtReflexive" clientClassName="org.apache.cayenne.testdo.mt.ClientMtReflexive" dbEntityName="MT_REFLEXIVE"> - <obj-attribute name="name" type="java.lang.String" db-attribute-path="NAME"/> - </obj-entity> <obj-entity name="MtTable1" className="org.apache.cayenne.testdo.mt.MtTable1" clientClassName="org.apache.cayenne.testdo.mt.ClientMtTable1" dbEntityName="MT_TABLE1"> <obj-attribute name="globalAttribute1" type="java.lang.String" db-attribute-path="GLOBAL_ATTRIBUTE1"/> <obj-attribute name="serverAttribute1" type="java.lang.String" db-attribute-path="SERVER_ATTRIBUTE1"/> @@ -147,56 +58,12 @@ </obj-entity> <obj-entity name="MtTable5" className="org.apache.cayenne.testdo.mt.MtTable5" clientClassName="org.apache.cayenne.testdo.mt.ClientMtTable5" dbEntityName="MT_TABLE5"> </obj-entity> - <obj-entity name="MtTablePrimitives" className="org.apache.cayenne.testdo.mt.MtTablePrimitives" clientClassName="org.apache.cayenne.testdo.mt.ClientMtTablePrimitives" dbEntityName="MT_TABLE_PRIMITIVES"> - <obj-attribute name="booleanColumn" type="boolean" db-attribute-path="BOOLEAN_COLUMN"/> - <obj-attribute name="intColumn" type="int" db-attribute-path="INT_COLUMN"/> - </obj-entity> - <obj-entity name="MtTooneDep" className="org.apache.cayenne.testdo.mt.MtTooneDep" clientClassName="org.apache.cayenne.testdo.mt.ClientMtTooneDep" dbEntityName="MT_TOONE_DEP"> - </obj-entity> - <obj-entity name="MtTooneMaster" className="org.apache.cayenne.testdo.mt.MtTooneMaster" clientClassName="org.apache.cayenne.testdo.mt.ClientMtTooneMaster" dbEntityName="MT_TOONE_MASTER"> - </obj-entity> - <db-relationship name="countries" source="CONTINENT" target="COUNTRY" toMany="true"> - <db-attribute-pair source="CONTINENTD" target="CONTINENTID"/> - </db-relationship> - <db-relationship name="continent" source="COUNTRY" target="CONTINENT" toMany="false"> - <db-attribute-pair source="CONTINENTID" target="CONTINENTD"/> - </db-relationship> - <db-relationship name="cascade" source="MT_DELETE_CASCADE" target="MT_DELETE_RULE" toMany="false"> - <db-attribute-pair source="DELETE_RULE_ID" target="DELETE_RULE_ID"/> - </db-relationship> - <db-relationship name="deny" source="MT_DELETE_DENY" target="MT_DELETE_RULE" toMany="false"> - <db-attribute-pair source="DELETE_RULE_ID" target="DELETE_RULE_ID"/> - </db-relationship> - <db-relationship name="nullify" source="MT_DELETE_NULLIFY" target="MT_DELETE_RULE" toMany="false"> - <db-attribute-pair source="DELETE_RULE_ID" target="DELETE_RULE_ID"/> - </db-relationship> - <db-relationship name="fromCascade" source="MT_DELETE_RULE" target="MT_DELETE_CASCADE" toMany="true"> - <db-attribute-pair source="DELETE_RULE_ID" target="DELETE_RULE_ID"/> - </db-relationship> - <db-relationship name="fromDeny" source="MT_DELETE_RULE" target="MT_DELETE_DENY" toMany="true"> - <db-attribute-pair source="DELETE_RULE_ID" target="DELETE_RULE_ID"/> - </db-relationship> - <db-relationship name="fromNullify" source="MT_DELETE_RULE" target="MT_DELETE_NULLIFY" toMany="true"> - <db-attribute-pair source="DELETE_RULE_ID" target="DELETE_RULE_ID"/> - </db-relationship> <db-relationship name="toTable4" source="MT_JOIN45" target="MT_TABLE4" toMany="false"> <db-attribute-pair source="TABLE4_ID" target="ID"/> </db-relationship> <db-relationship name="toTable5" source="MT_JOIN45" target="MT_TABLE5" toMany="false"> <db-attribute-pair source="TABLE5_ID" target="ID"/> </db-relationship> - <db-relationship name="targets" source="MT_MAP_TO_MANY" target="MT_MAP_TO_MANY_TARGET" toMany="true"> - <db-attribute-pair source="ID" target="MAP_TO_MANY_ID"/> - </db-relationship> - <db-relationship name="mapToMany" source="MT_MAP_TO_MANY_TARGET" target="MT_MAP_TO_MANY" toMany="false"> - <db-attribute-pair source="MAP_TO_MANY_ID" target="ID"/> - </db-relationship> - <db-relationship name="children" source="MT_REFLEXIVE" target="MT_REFLEXIVE" toMany="true"> - <db-attribute-pair source="ID" target="PARENT_ID"/> - </db-relationship> - <db-relationship name="toParent" source="MT_REFLEXIVE" target="MT_REFLEXIVE" toMany="false"> - <db-attribute-pair source="PARENT_ID" target="ID"/> - </db-relationship> <db-relationship name="table2Array" source="MT_TABLE1" target="MT_TABLE2" toMany="true"> <db-attribute-pair source="TABLE1_ID" target="TABLE1_ID"/> </db-relationship> @@ -215,32 +82,12 @@ <db-relationship name="joins" source="MT_TABLE5" target="MT_JOIN45" toMany="true"> <db-attribute-pair source="ID" target="TABLE5_ID"/> </db-relationship> - <db-relationship name="toMaster" source="MT_TOONE_DEP" target="MT_TOONE_MASTER" toMany="false"> - <db-attribute-pair source="ID" target="ID"/> - </db-relationship> - <db-relationship name="toDependent" source="MT_TOONE_MASTER" target="MT_TOONE_DEP" toDependentPK="true" toMany="false"> - <db-attribute-pair source="ID" target="ID"/> - </db-relationship> - <obj-relationship name="countries" source="Continent" target="Country" deleteRule="Cascade" db-relationship-path="countries"/> - <obj-relationship name="continent" source="Country" target="Continent" deleteRule="Nullify" db-relationship-path="continent"/> - <obj-relationship name="cascade" source="MtDeleteCascade" target="MtDeleteRule" deleteRule="Cascade" db-relationship-path="cascade"/> - <obj-relationship name="deny" source="MtDeleteDeny" target="MtDeleteRule" deleteRule="Deny" db-relationship-path="deny"/> - <obj-relationship name="nullify" source="MtDeleteNullify" target="MtDeleteRule" deleteRule="Nullify" db-relationship-path="nullify"/> - <obj-relationship name="fromCascade" source="MtDeleteRule" target="MtDeleteCascade" db-relationship-path="fromCascade"/> - <obj-relationship name="fromDeny" source="MtDeleteRule" target="MtDeleteDeny" db-relationship-path="fromDeny"/> - <obj-relationship name="fromNullify" source="MtDeleteRule" target="MtDeleteNullify" db-relationship-path="fromNullify"/> - <obj-relationship name="targets" source="MtMapToMany" target="MtMapToManyTarget" collection-type="java.util.Map" db-relationship-path="targets"/> - <obj-relationship name="mapToMany" source="MtMapToManyTarget" target="MtMapToMany" db-relationship-path="mapToMany"/> - <obj-relationship name="children" source="MtReflexive" target="MtReflexive" db-relationship-path="children"/> - <obj-relationship name="toParent" source="MtReflexive" target="MtReflexive" db-relationship-path="toParent"/> <obj-relationship name="table2Array" source="MtTable1" target="MtTable2" db-relationship-path="table2Array"/> <obj-relationship name="table1" source="MtTable2" target="MtTable1" db-relationship-path="table1"/> <obj-relationship name="table3" source="MtTable2" target="MtTable3" deleteRule="Nullify" db-relationship-path="table3"/> <obj-relationship name="table2Array" source="MtTable3" target="MtTable2" deleteRule="Deny" db-relationship-path="table2Array"/> <obj-relationship name="table5s" source="MtTable4" target="MtTable5" db-relationship-path="joins.toTable5"/> <obj-relationship name="table4s" source="MtTable5" target="MtTable4" db-relationship-path="joins.toTable4"/> - <obj-relationship name="toMaster" source="MtTooneDep" target="MtTooneMaster" deleteRule="Nullify" db-relationship-path="toMaster"/> - <obj-relationship name="toDependent" source="MtTooneMaster" target="MtTooneDep" deleteRule="Cascade" db-relationship-path="toDependent"/> <query name="AllMtTable1" factory="org.apache.cayenne.map.SelectQueryBuilder" root="obj-entity" root-name="MtTable1"> </query> <query name="MtQueryWithLocalCache" factory="org.apache.cayenne.map.SelectQueryBuilder" root="obj-entity" root-name="MtTable1"> http://git-wip-us.apache.org/repos/asf/cayenne/blob/fb8660e7/cayenne-server/src/test/resources/persistent.map.xml ---------------------------------------------------------------------- diff --git a/cayenne-server/src/test/resources/persistent.map.xml b/cayenne-server/src/test/resources/persistent.map.xml new file mode 100644 index 0000000..7e50534 --- /dev/null +++ b/cayenne-server/src/test/resources/persistent.map.xml @@ -0,0 +1,32 @@ +<?xml version="1.0" encoding="utf-8"?> +<data-map xmlns="http://cayenne.apache.org/schema/7/modelMap" + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:schemaLocation="http://cayenne.apache.org/schema/7/modelMap http://cayenne.apache.org/schema/7/modelMap.xsd" + project-version="7"> + <property name="defaultPackage" value="org.apache.cayenne.testdo.persistent"/> + <property name="clientSupported" value="true"/> + <property name="defaultClientPackage" value="org.apache.cayenne.testdo.persistent"/> + <db-entity name="CONTINENT"> + <db-attribute name="CONTINENTD" type="BIGINT" isPrimaryKey="true" isMandatory="true"/> + <db-attribute name="NAME" type="VARCHAR" isMandatory="true" length="100"/> + </db-entity> + <db-entity name="COUNTRY"> + <db-attribute name="CONTINENTID" type="BIGINT" isMandatory="true"/> + <db-attribute name="COUNTRYID" type="BIGINT" isPrimaryKey="true" isMandatory="true"/> + <db-attribute name="NAME" type="VARCHAR" isMandatory="true" length="100"/> + </db-entity> + <obj-entity name="Continent" className="org.apache.cayenne.testdo.persistent.Continent" clientClassName="org.apache.cayenne.testdo.persistent.Continent" dbEntityName="CONTINENT" superClassName="org.apache.cayenne.PersistentObject"> + <obj-attribute name="name" type="java.lang.String" db-attribute-path="NAME"/> + </obj-entity> + <obj-entity name="Country" className="org.apache.cayenne.testdo.persistent.Country" clientClassName="org.apache.cayenne.testdo.persistent.Country" dbEntityName="COUNTRY" superClassName="org.apache.cayenne.PersistentObject"> + <obj-attribute name="name" type="java.lang.String" db-attribute-path="NAME"/> + </obj-entity> + <db-relationship name="countries" source="CONTINENT" target="COUNTRY" toMany="true"> + <db-attribute-pair source="CONTINENTD" target="CONTINENTID"/> + </db-relationship> + <db-relationship name="continent" source="COUNTRY" target="CONTINENT" toMany="false"> + <db-attribute-pair source="CONTINENTID" target="CONTINENTD"/> + </db-relationship> + <obj-relationship name="countries" source="Continent" target="Country" deleteRule="Cascade" db-relationship-path="countries"/> + <obj-relationship name="continent" source="Country" target="Continent" deleteRule="Nullify" db-relationship-path="continent"/> +</data-map> \ No newline at end of file http://git-wip-us.apache.org/repos/asf/cayenne/blob/fb8660e7/cayenne-server/src/test/resources/reflexive.map.xml ---------------------------------------------------------------------- diff --git a/cayenne-server/src/test/resources/reflexive.map.xml b/cayenne-server/src/test/resources/reflexive.map.xml new file mode 100644 index 0000000..28fbf77 --- /dev/null +++ b/cayenne-server/src/test/resources/reflexive.map.xml @@ -0,0 +1,25 @@ +<?xml version="1.0" encoding="utf-8"?> +<data-map xmlns="http://cayenne.apache.org/schema/7/modelMap" + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:schemaLocation="http://cayenne.apache.org/schema/7/modelMap http://cayenne.apache.org/schema/7/modelMap.xsd" + project-version="7"> + <property name="defaultPackage" value="org.apache.cayenne.testdo.reflexive"/> + <property name="clientSupported" value="true"/> + <property name="defaultClientPackage" value="org.apache.cayenne.testdo.reflexive"/> + <db-entity name="REFLEXIVE"> + <db-attribute name="ID" type="INTEGER" isPrimaryKey="true" isMandatory="true"/> + <db-attribute name="NAME" type="VARCHAR" isMandatory="true" length="200"/> + <db-attribute name="PARENT_ID" type="INTEGER"/> + </db-entity> + <obj-entity name="Reflexive" className="org.apache.cayenne.testdo.reflexive.Reflexive" clientClassName="org.apache.cayenne.testdo.reflexive.ClientReflexive" dbEntityName="REFLEXIVE"> + <obj-attribute name="name" type="java.lang.String" db-attribute-path="NAME"/> + </obj-entity> + <db-relationship name="children" source="REFLEXIVE" target="REFLEXIVE" toMany="true"> + <db-attribute-pair source="ID" target="PARENT_ID"/> + </db-relationship> + <db-relationship name="toParent" source="REFLEXIVE" target="REFLEXIVE" toMany="false"> + <db-attribute-pair source="PARENT_ID" target="ID"/> + </db-relationship> + <obj-relationship name="children" source="Reflexive" target="Reflexive" db-relationship-path="children"/> + <obj-relationship name="toParent" source="Reflexive" target="Reflexive" db-relationship-path="toParent"/> +</data-map> \ No newline at end of file http://git-wip-us.apache.org/repos/asf/cayenne/blob/fb8660e7/cayenne-server/src/test/resources/relationships.map.xml ---------------------------------------------------------------------- diff --git a/cayenne-server/src/test/resources/relationships.map.xml b/cayenne-server/src/test/resources/relationships.map.xml index d1fc117..85ce607 100644 --- a/cayenne-server/src/test/resources/relationships.map.xml +++ b/cayenne-server/src/test/resources/relationships.map.xml @@ -82,21 +82,6 @@ <db-attribute name="FT4_ID" type="INTEGER" isPrimaryKey="true" isMandatory="true"/> <db-attribute name="NAME" type="VARCHAR" isMandatory="true" length="100"/> </db-entity> - <db-entity name="ID_MAP_TO_MANY"> - <db-attribute name="ID" type="INTEGER" isPrimaryKey="true" isMandatory="true"/> - </db-entity> - <db-entity name="ID_MAP_TO_MANY_TARGET"> - <db-attribute name="ID" type="INTEGER" isPrimaryKey="true" isMandatory="true"/> - <db-attribute name="MAP_TO_MANY_ID" type="INTEGER"/> - </db-entity> - <db-entity name="MAP_TO_MANY"> - <db-attribute name="ID" type="INTEGER" isPrimaryKey="true" isMandatory="true"/> - </db-entity> - <db-entity name="MAP_TO_MANY_TARGET"> - <db-attribute name="ID" type="INTEGER" isPrimaryKey="true" isMandatory="true"/> - <db-attribute name="MAP_TO_MANY_ID" type="INTEGER"/> - <db-attribute name="NAME" type="VARCHAR" isMandatory="true" length="100"/> - </db-entity> <db-entity name="MASTER"> <db-attribute name="ID" type="INTEGER" isPrimaryKey="true" isMandatory="true"/> <db-attribute name="NAME" type="VARCHAR" length="100"/> @@ -182,15 +167,6 @@ <obj-entity name="FlattenedTest4" className="org.apache.cayenne.testdo.relationship.FlattenedTest4" dbEntityName="FLATTENED_TEST_4"> <obj-attribute name="name" type="java.lang.String" db-attribute-path="NAME"/> </obj-entity> - <obj-entity name="IdMapToMany" className="org.apache.cayenne.testdo.relationship.IdMapToMany" dbEntityName="ID_MAP_TO_MANY"> - </obj-entity> - <obj-entity name="IdMapToManyTarget" className="org.apache.cayenne.testdo.relationship.IdMapToManyTarget" dbEntityName="ID_MAP_TO_MANY_TARGET"> - </obj-entity> - <obj-entity name="MapToMany" className="org.apache.cayenne.testdo.relationship.MapToMany" dbEntityName="MAP_TO_MANY"> - </obj-entity> - <obj-entity name="MapToManyTarget" className="org.apache.cayenne.testdo.relationship.MapToManyTarget" dbEntityName="MAP_TO_MANY_TARGET"> - <obj-attribute name="name" type="java.lang.String" db-attribute-path="NAME"/> - </obj-entity> <obj-entity name="Master" className="org.apache.cayenne.testdo.relationship.Master" dbEntityName="MASTER"> <obj-attribute name="name" type="java.lang.String" db-attribute-path="NAME"/> </obj-entity> @@ -309,18 +285,6 @@ <db-relationship name="toFT3" source="FLATTENED_TEST_4" target="FLATTENED_TEST_3" toMany="false"> <db-attribute-pair source="FT3_ID" target="FT3_ID"/> </db-relationship> - <db-relationship name="targets" source="ID_MAP_TO_MANY" target="ID_MAP_TO_MANY_TARGET" toMany="true"> - <db-attribute-pair source="ID" target="MAP_TO_MANY_ID"/> - </db-relationship> - <db-relationship name="mapToMany" source="ID_MAP_TO_MANY_TARGET" target="ID_MAP_TO_MANY" toMany="false"> - <db-attribute-pair source="MAP_TO_MANY_ID" target="ID"/> - </db-relationship> - <db-relationship name="targets" source="MAP_TO_MANY" target="MAP_TO_MANY_TARGET" toMany="true"> - <db-attribute-pair source="ID" target="MAP_TO_MANY_ID"/> - </db-relationship> - <db-relationship name="mapToMany" source="MAP_TO_MANY_TARGET" target="MAP_TO_MANY" toMany="false"> - <db-attribute-pair source="MAP_TO_MANY_ID" target="ID"/> - </db-relationship> <db-relationship name="children" source="MASTER" target="CHILD" toMany="true"> <db-attribute-pair source="ID" target="MASTER_ID"/> </db-relationship> @@ -393,10 +357,6 @@ <obj-relationship name="toFT1" source="FlattenedTest3" target="FlattenedTest1" db-relationship-path="toFT2.toFT1"/> <obj-relationship name="toFT2" source="FlattenedTest3" target="FlattenedTest2" db-relationship-path="toFT2"/> <obj-relationship name="toFT3" source="FlattenedTest4" target="FlattenedTest3" db-relationship-path="toFT3"/> - <obj-relationship name="targets" source="IdMapToMany" target="IdMapToManyTarget" collection-type="java.util.Map" db-relationship-path="targets"/> - <obj-relationship name="mapToMany" source="IdMapToManyTarget" target="IdMapToMany" db-relationship-path="mapToMany"/> - <obj-relationship name="targets" source="MapToMany" target="MapToManyTarget" collection-type="java.util.Map" map-key="name" db-relationship-path="targets"/> - <obj-relationship name="mapToMany" source="MapToManyTarget" target="MapToMany" db-relationship-path="mapToMany"/> <obj-relationship name="children" source="Master" target="Child" deleteRule="Deny" db-relationship-path="children"/> <obj-relationship name="toRelationshipHelper" source="MeaningfulFK" target="RelationshipHelper" db-relationship-path="toRelationshipHelper"/> <obj-relationship name="children" source="ReflexiveAndToOne" target="ReflexiveAndToOne" db-relationship-path="children"/> http://git-wip-us.apache.org/repos/asf/cayenne/blob/fb8660e7/cayenne-server/src/test/resources/table-primitives.map.xml ---------------------------------------------------------------------- diff --git a/cayenne-server/src/test/resources/table-primitives.map.xml b/cayenne-server/src/test/resources/table-primitives.map.xml new file mode 100644 index 0000000..a2c3c23 --- /dev/null +++ b/cayenne-server/src/test/resources/table-primitives.map.xml @@ -0,0 +1,18 @@ +<?xml version="1.0" encoding="utf-8"?> +<data-map xmlns="http://cayenne.apache.org/schema/7/modelMap" + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:schemaLocation="http://cayenne.apache.org/schema/7/modelMap http://cayenne.apache.org/schema/7/modelMap.xsd" + project-version="7"> + <property name="defaultPackage" value="org.apache.cayenne.testdo.table_primitives"/> + <property name="clientSupported" value="true"/> + <property name="defaultClientPackage" value="org.apache.cayenne.testdo.table_primitives"/> + <db-entity name="TABLE_PRIMITIVES"> + <db-attribute name="BOOLEAN_COLUMN" type="BOOLEAN"/> + <db-attribute name="ID" type="INTEGER" isPrimaryKey="true" isMandatory="true"/> + <db-attribute name="INT_COLUMN" type="INTEGER"/> + </db-entity> + <obj-entity name="TablePrimitives" className="org.apache.cayenne.testdo.table_primitives.TablePrimitives" clientClassName="org.apache.cayenne.testdo.table_primitives.ClientTablePrimitives" dbEntityName="TABLE_PRIMITIVES"> + <obj-attribute name="booleanColumn" type="boolean" db-attribute-path="BOOLEAN_COLUMN"/> + <obj-attribute name="intColumn" type="int" db-attribute-path="INT_COLUMN"/> + </obj-entity> +</data-map> \ No newline at end of file http://git-wip-us.apache.org/repos/asf/cayenne/blob/fb8660e7/cayenne-server/src/test/resources/toone.map.xml ---------------------------------------------------------------------- diff --git a/cayenne-server/src/test/resources/toone.map.xml b/cayenne-server/src/test/resources/toone.map.xml new file mode 100644 index 0000000..5a30192 --- /dev/null +++ b/cayenne-server/src/test/resources/toone.map.xml @@ -0,0 +1,27 @@ +<?xml version="1.0" encoding="utf-8"?> +<data-map xmlns="http://cayenne.apache.org/schema/7/modelMap" + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:schemaLocation="http://cayenne.apache.org/schema/7/modelMap http://cayenne.apache.org/schema/7/modelMap.xsd" + project-version="7"> + <property name="defaultPackage" value="org.apache.cayenne.testdo.toone"/> + <property name="clientSupported" value="true"/> + <property name="defaultClientPackage" value="org.apache.cayenne.testdo.toone"/> + <db-entity name="TOONE_DEP"> + <db-attribute name="ID" type="INTEGER" isPrimaryKey="true" isMandatory="true"/> + </db-entity> + <db-entity name="TOONE_MASTER"> + <db-attribute name="ID" type="INTEGER" isPrimaryKey="true" isMandatory="true"/> + </db-entity> + <obj-entity name="TooneDep" className="org.apache.cayenne.testdo.toone.TooneDep" clientClassName="org.apache.cayenne.testdo.toone.ClientTooneDep" dbEntityName="TOONE_DEP"> + </obj-entity> + <obj-entity name="TooneMaster" className="org.apache.cayenne.testdo.toone.TooneMaster" clientClassName="org.apache.cayenne.testdo.toone.ClientTooneMaster" dbEntityName="TOONE_MASTER"> + </obj-entity> + <db-relationship name="toMaster" source="TOONE_DEP" target="TOONE_MASTER" toMany="false"> + <db-attribute-pair source="ID" target="ID"/> + </db-relationship> + <db-relationship name="toDependent" source="TOONE_MASTER" target="TOONE_DEP" toDependentPK="true" toMany="false"> + <db-attribute-pair source="ID" target="ID"/> + </db-relationship> + <obj-relationship name="toMaster" source="TooneDep" target="TooneMaster" deleteRule="Nullify" db-relationship-path="toMaster"/> + <obj-relationship name="toDependent" source="TooneMaster" target="TooneDep" deleteRule="Cascade" db-relationship-path="toDependent"/> +</data-map> \ No newline at end of file