diff --git a/reference/sdo/constants.xml b/reference/sdo/constants.xml
new file mode 100644
index 0000000000..f350c979ca
--- /dev/null
+++ b/reference/sdo/constants.xml
@@ -0,0 +1,74 @@
+
+
+
+
+ &reftitle.constants;
+ &extension.constants;
+
+
+
+ SDO_DAS_ChangeSummary::NONE=0
+ (integer)
+
+
+
+ Represents a change type of 'none'.
+
+
+
+
+
+ SDO_DAS_ChangeSummary::MODIFICATION=1
+ (integer)
+
+
+
+ Represents a change type of 'modification'.
+
+
+
+
+
+ SDO_DAS_ChangeSummary::ADDITION=2
+ (integer)
+
+
+
+ Represents a change type of 'addition'.
+
+
+
+
+
+ SDO_DAS_ChangeSummary::DELETION=3
+ (integer)
+
+
+
+ Represents a change type of 'deletion'.
+
+
+
+
+
+
+
diff --git a/reference/sdo/functions.xml b/reference/sdo/functions.xml
new file mode 100644
index 0000000000..25203f38ff
--- /dev/null
+++ b/reference/sdo/functions.xml
@@ -0,0 +1,28 @@
+&reference.sdo.functions.SDO-DAS-ChangeSummary-beginLogging;
+&reference.sdo.functions.SDO-DAS-ChangeSummary-endLogging;
+&reference.sdo.functions.SDO-DAS-ChangeSummary-getChangeType;
+&reference.sdo.functions.SDO-DAS-ChangeSummary-getChangedDataObjects;
+&reference.sdo.functions.SDO-DAS-ChangeSummary-getOldContainer;
+&reference.sdo.functions.SDO-DAS-ChangeSummary-getOldValues;
+&reference.sdo.functions.SDO-DAS-ChangeSummary-isLogging;
+&reference.sdo.functions.SDO-DAS-DataFactory-addPropertyToType;
+&reference.sdo.functions.SDO-DAS-DataFactory-addType;
+&reference.sdo.functions.SDO-DAS-DataFactory-getDataFactory;
+&reference.sdo.functions.SDO-DAS-DataObject-getChangeSummary;
+&reference.sdo.functions.SDO-DAS-Setting-getListIndex;
+&reference.sdo.functions.SDO-DAS-Setting-getPropertyIndex;
+&reference.sdo.functions.SDO-DAS-Setting-getPropertyName;
+&reference.sdo.functions.SDO-DAS-Setting-getValue;
+&reference.sdo.functions.SDO-DAS-Setting-isSet;
+&reference.sdo.functions.SDO-DataFactory-create;
+&reference.sdo.functions.SDO-DataObject-clear;
+&reference.sdo.functions.SDO-DataObject-createDataObject;
+&reference.sdo.functions.SDO-DataObject-getContainer;
+&reference.sdo.functions.SDO-DataObject-getContainmentPropertyName;
+&reference.sdo.functions.SDO-DataObject-getSequence;
+&reference.sdo.functions.SDO-DataObject-getType;
+&reference.sdo.functions.SDO-List-insert;
+&reference.sdo.functions.SDO-Sequence-getPropertyIndex;
+&reference.sdo.functions.SDO-Sequence-getPropertyName;
+&reference.sdo.functions.SDO-Sequence-insert;
+&reference.sdo.functions.SDO-Sequence-move;
diff --git a/reference/sdo/functions/SDO-DAS-ChangeSummary-beginLogging.xml b/reference/sdo/functions/SDO-DAS-ChangeSummary-beginLogging.xml
new file mode 100644
index 0000000000..ff4e7bd22d
--- /dev/null
+++ b/reference/sdo/functions/SDO-DAS-ChangeSummary-beginLogging.xml
@@ -0,0 +1,140 @@
+
+
+
+
+
+ SDO_DAS_ChangeSummary::beginLogging
+
+ Begin change logging.
+
+
+
+ &reftitle.description;
+
+ void
+ SDO_DAS_ChangeSummary::beginLogging
+
+
+
+ &warn.experimental.func;
+
+
+ Begin logging changes made to the SDO_DataObject.
+
+
+
+
+ &reftitle.parameters;
+
+ None.
+
+
+
+ &reftitle.returnvalues;
+
+ None.
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/reference/sdo/functions/SDO-DAS-ChangeSummary-endLogging.xml b/reference/sdo/functions/SDO-DAS-ChangeSummary-endLogging.xml
new file mode 100644
index 0000000000..5a685e7743
--- /dev/null
+++ b/reference/sdo/functions/SDO-DAS-ChangeSummary-endLogging.xml
@@ -0,0 +1,140 @@
+
+
+
+
+
+ SDO_DAS_ChangeSummary::endLogging
+
+ End change logging.
+
+
+
+ &reftitle.description;
+
+ void
+ SDO_DAS_ChangeSummary::endLogging
+
+
+
+ &warn.experimental.func;
+
+
+ End logging changes made to an SDO_DataObject.
+
+
+
+
+ &reftitle.parameters;
+
+ None.
+
+
+
+ &reftitle.returnvalues;
+
+ None.
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/reference/sdo/functions/SDO-DAS-ChangeSummary-getChangeType.xml b/reference/sdo/functions/SDO-DAS-ChangeSummary-getChangeType.xml
new file mode 100644
index 0000000000..52514736a2
--- /dev/null
+++ b/reference/sdo/functions/SDO-DAS-ChangeSummary-getChangeType.xml
@@ -0,0 +1,171 @@
+
+
+
+
+
+ SDO_DAS_ChangeSummary::getChangeType
+
+ Get the type of change made to an SDO_DataObject.
+
+
+
+ &reftitle.description;
+
+ integerSDO_DAS_ChangeSummary::getChangeType
+ SDO_DataObjectdataObject
+
+
+ &warn.experimental.func;
+
+
+ Get the type of change which has been made to the supplied SDO_DataObject.
+
+
+
+
+ &reftitle.parameters;
+
+
+
+ dataObject
+
+
+The SDO_DataObject which has been changed.
+
+
+
+
+
+
+
+ &reftitle.returnvalues;
+
+ The type of change which has been made. The change type is expressed as an enumeration and will be one of the following four values:
+
+
+
+SDO_DAS_ChangeSummary::NONE
+
+
+
+
+SDO_DAS_ChangeSummary::MODIFICATION
+
+
+
+
+SDO_DAS_ChangeSummary::ADDITION
+
+
+
+
+SDO_DAS_ChangeSummary::DELETION
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/reference/sdo/functions/SDO-DAS-ChangeSummary-getChangedDataObjects.xml b/reference/sdo/functions/SDO-DAS-ChangeSummary-getChangedDataObjects.xml
new file mode 100644
index 0000000000..323fcb72e1
--- /dev/null
+++ b/reference/sdo/functions/SDO-DAS-ChangeSummary-getChangedDataObjects.xml
@@ -0,0 +1,140 @@
+
+
+
+
+
+ SDO_DAS_ChangeSummary::getChangedDataObjects
+
+ Get the changed data objects from a change summary.
+
+
+
+ &reftitle.description;
+
+ SDO_ListSDO_DAS_ChangeSummary::getChangedDataObjects
+
+
+
+ &warn.experimental.func;
+
+
+ Get an SDO_List of the SDO_DataObjects which have been changed.
+ These data objects can then be used to identify the types of change made to each, along with the old values.
+
+
+
+
+ &reftitle.parameters;
+
+ None.
+
+
+
+ &reftitle.returnvalues;
+
+Returns an SDO_List of SDO_DataObjects.
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/reference/sdo/functions/SDO-DAS-ChangeSummary-getOldContainer.xml b/reference/sdo/functions/SDO-DAS-ChangeSummary-getOldContainer.xml
new file mode 100644
index 0000000000..ed13ba6a17
--- /dev/null
+++ b/reference/sdo/functions/SDO-DAS-ChangeSummary-getOldContainer.xml
@@ -0,0 +1,149 @@
+
+
+
+
+
+ SDO_DAS_ChangeSummary::getOldContainer
+
+ Get the old container for a deleted SDO_DataObject.
+
+
+
+ &reftitle.description;
+
+ SDO_DataObjectSDO_DAS_ChangeSummary::getOldContainer
+ SDO_DataObjectdataObject
+
+
+ &warn.experimental.func;
+
+
+ Get the old container (SDO_DataObject) for a deleted SDO_DataObject.
+
+
+
+
+
+ &reftitle.parameters;
+
+
+
+ dataObject
+
+
+The SDO_DataObject which has been deleted and whose container we wish to identify.
+
+
+
+
+
+
+
+ &reftitle.returnvalues;
+
+The old containing data object of the deleted SDO_DataObject.
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/reference/sdo/functions/SDO-DAS-ChangeSummary-getOldValues.xml b/reference/sdo/functions/SDO-DAS-ChangeSummary-getOldValues.xml
new file mode 100644
index 0000000000..7bd9b4efa8
--- /dev/null
+++ b/reference/sdo/functions/SDO-DAS-ChangeSummary-getOldValues.xml
@@ -0,0 +1,150 @@
+
+
+
+
+
+ SDO_DAS_ChangeSummary::getOldValues
+
+ Get the old values for a given changed SDO_DataObject.
+
+
+
+ &reftitle.description;
+
+ SDO_ListSDO_DAS_ChangeSummary::getOldValues
+ SDO_DataObjectdataObject
+
+
+ &warn.experimental.func;
+
+
+ Get a list of the old values for a given changed SDO_DataObject.
+ Returns a list of SDO_DAS_Settings describing the old values for the changed properties of the SDO_DataObject.
+
+
+
+
+
+ &reftitle.parameters;
+
+
+
+ dataObject
+
+
+The data object which has been changed.
+
+
+
+
+
+
+
+ &reftitle.returnvalues;
+
+A list of SDO_DAS_Settings describing the old values for the changed properties of the SDO_DataObject
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/reference/sdo/functions/SDO-DAS-ChangeSummary-isLogging.xml b/reference/sdo/functions/SDO-DAS-ChangeSummary-isLogging.xml
new file mode 100644
index 0000000000..b84a0f5c73
--- /dev/null
+++ b/reference/sdo/functions/SDO-DAS-ChangeSummary-isLogging.xml
@@ -0,0 +1,139 @@
+
+
+
+
+
+ SDO_DAS_ChangeSummary::isLogging
+
+ Test to see whether change logging is switched on.
+
+
+
+ &reftitle.description;
+
+ booleanSDO_DAS_ChangeSummary::isLogging
+
+
+
+ &warn.experimental.func;
+
+
+ Test to see whether change logging is switched on.
Returns true if logging is on, otherwise returns false.
+
+
+
+
+ &reftitle.parameters;
+
+ None.
+
+
+
+ &reftitle.returnvalues;
+
+Returns true if change logging is on, otherwise returns false.
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/reference/sdo/functions/SDO-DAS-DataFactory-addPropertyToType.xml b/reference/sdo/functions/SDO-DAS-DataFactory-addPropertyToType.xml
new file mode 100644
index 0000000000..6f903ec45f
--- /dev/null
+++ b/reference/sdo/functions/SDO-DAS-DataFactory-addPropertyToType.xml
@@ -0,0 +1,205 @@
+
+
+
+
+
+ SDO_DAS_DataFactory::addPropertyToType
+
+ Adds a property to a type.
+
+
+
+ &reftitle.description;
+
+ voidSDO_DAS_DataFactory::addPropertyToType
+ stringparentNamespaceURI
+ stringparentTypeName
+ stringpropertyName
+ stringpropertyNamespaceURI
+ stringpropertyTypeName
+ booleanmany
+ booleanreadOnly
+ booleancontainment
+
+
+ &warn.experimental.func;
+
+
+ Adds a property to a type. The type must already be known to the
+SDO_DAS_DataFactory (i.e. have been added using addType()). The property
+becomes a property of the type. This is how the graph model for the
+structure of an SDO_DataObject is built.
+
+
+
+
+ &reftitle.parameters;
+
+
+
+ parentNamespaceURI
+
+
+The namespace URI for the parent type.
+
+
+
+
+ parentTypeName
+
+
+The type name for the parent type.
+
+
+
+
+ propertyName
+
+
+The name of by which the property will be known in the parent type.
+
+
+
+
+ propertyNamespaceURI
+
+
+The namespace URI for the type of the property.
+
+
+
+
+ propertyTypeName
+
+
+The type name for the type of the property
+
+
+
+
+ many
+
+
+A flag to say whether the property is many-valued.
+A value of 'true' adds the property as a many-valued property (default is 'false')
+
+
+
+
+ readOnly
+
+
+A flag to say whether the property is read-only.
+A value of 'true' means the property value cannot be modified through the SDO application APIs (default is 'false')
+
+
+
+
+ containment
+
+
+A flag to say whether the property is contained by the parent.
+A value of 'true' means the property is contained by the parent.
+A value of 'false' results in a non-containment reference (default is 'true').
+This flag is only interpreted when adding properties which are data object types, otherwise it is ignored.
+
+
+
+
+
+
+
+ &reftitle.returnvalues;
+
+ None.
+
+
+
+
+
+
+
+
+
+ &reftitle.examples;
+
+
+ A SDO_DAS_DataFactory::addPropertyToType example
+
+The following adds a 'name' property to a Person type. The person type is identified by its namespace, 'PersonNS', and type name, 'PersonType'.
+The type of the 'name' property is an SDO data type (primitive) with namespace 'commonj.sdo' and type name 'String'.
+
+
+addPropertyToType('PersonNS', 'PersonType',
'name', 'commonj.sdo', 'String');
+?>
+]]>
+
+
+
+
+
+
+
+
+
+
+
diff --git a/reference/sdo/functions/SDO-DAS-DataFactory-addType.xml b/reference/sdo/functions/SDO-DAS-DataFactory-addType.xml
new file mode 100644
index 0000000000..ed53fb460e
--- /dev/null
+++ b/reference/sdo/functions/SDO-DAS-DataFactory-addType.xml
@@ -0,0 +1,146 @@
+
+
+
+
+
+ SDO_DAS_DataFactory::addType
+
+ Add a new type to a model.
+
+
+
+ &reftitle.description;
+
+ voidSDO_DAS_DataFactory::addType
+ stringnamespaceURI
+ stringtypeName
+
+
+ &warn.experimental.func;
+
+
+ Add a new type to the SDO_DAS_DataFactory, defined by its namespace and type
name.
+ The type becomes part of the model of data objects that the data factory can create.
+
+
+
+
+ &reftitle.parameters;
+
+
+
+ namespaceURI
+
+
+The namespace of the type.
+
+
+
+
+ typeName
+
+
+The name of the type.
+
+
+
+
+
+
+
+ &reftitle.returnvalues;
+
+ No values returned.
+
+
+
+
+
+
+
+
+
+
+ &reftitle.examples;
+
+
+ A SDO_DAS_DataFactory::addType example
+
+The following adds a new data object type of 'CompanyType'
where that type belongs to the namespace 'CompanyNS'.
+
+
+addType('CompanyNS', 'CompanyType');
+?>
+]]>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/reference/sdo/functions/SDO-DAS-DataFactory-getDataFactory.xml b/reference/sdo/functions/SDO-DAS-DataFactory-getDataFactory.xml
new file mode 100644
index 0000000000..7b8b896c16
--- /dev/null
+++ b/reference/sdo/functions/SDO-DAS-DataFactory-getDataFactory.xml
@@ -0,0 +1,145 @@
+
+
+
+
+
+ SDO_DAS_DataFactory::getDataFactory
+
+ Get a data factory instance.
+
+
+
+
+ &reftitle.description;
+
+ SDO_DAS_DataFactorySDO_DAS_DataFactory::getDataFactory
+
+
+
+ &warn.experimental.func;
+
+
+ Static method to get an instance of an SDO_DAS_DataFactory. This instance is initially only
+configured with the basic SDO types. A Data Access Service is responsible for populating
+the data factory model and then allowing PHP applications to create SDOs based on the model
+through the SDO_DataFactory interface.
+PHP applications should always obtain a data factory from a configured Data Access Service, not through this interface.
+
+
+
+
+
+ &reftitle.parameters;
+
+ None.
+
+
+
+ &reftitle.returnvalues;
+
+Returns an SDO_DAS_DataFactory.
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/reference/sdo/functions/SDO-DAS-DataObject-getChangeSummary.xml b/reference/sdo/functions/SDO-DAS-DataObject-getChangeSummary.xml
new file mode 100644
index 0000000000..1c5bf4a190
--- /dev/null
+++ b/reference/sdo/functions/SDO-DAS-DataObject-getChangeSummary.xml
@@ -0,0 +1,139 @@
+
+
+
+
+
+ SDO_DAS_DataObject::getChangeSummary
+
+ Get a data object's change summary.
+
+
+
+ &reftitle.description;
+
+ SDO_DAS_ChangeSummarySDO_DAS_DataObject::getChangeSummary
+
+
+
+ &warn.experimental.func;
+
+
+ Get the SDO_DAS_ChangeSummary for an SDO_DAS_DataObject, or NULL if it does not have one.
+
+
+
+
+ &reftitle.parameters;
+
+ None.
+
+
+
+ &reftitle.returnvalues;
+
+Returns the SDO_DAS_ChangeSummary for an SDO_DAS_DataObject, or NULL if it does not have one.
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/reference/sdo/functions/SDO-DAS-Setting-getListIndex.xml b/reference/sdo/functions/SDO-DAS-Setting-getListIndex.xml
new file mode 100644
index 0000000000..7eba5ac781
--- /dev/null
+++ b/reference/sdo/functions/SDO-DAS-Setting-getListIndex.xml
@@ -0,0 +1,144 @@
+
+
+
+
+
+ SDO_DAS_Setting::getListIndex
+
+ Get the list index for a changed many-valued property.
+
+
+
+ &reftitle.description;
+
+ integer
+ SDO_DAS_Setting::getListIndex
+
+
+
+ &warn.experimental.func;
+
+
+Get the list index for a modification made to an element of a many-valued property. For example, if we modified the third element of a many-valued property
+we could obtain an SDO_DAS_Setting from the change summary corresponding to that modification.
+A call to
+ getListIndex
+on that setting would return the value 2 (lists are indexed from zero).
+
+
+
+
+ &reftitle.parameters;
+
+ None.
+
+
+
+ &reftitle.returnvalues;
+
+ The list index for the element of the many-valued property which has been changed.
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/reference/sdo/functions/SDO-DAS-Setting-getPropertyIndex.xml b/reference/sdo/functions/SDO-DAS-Setting-getPropertyIndex.xml
new file mode 100644
index 0000000000..6d0c8c3d82
--- /dev/null
+++ b/reference/sdo/functions/SDO-DAS-Setting-getPropertyIndex.xml
@@ -0,0 +1,140 @@
+
+
+
+
+
+ SDO_DAS_Setting::getPropertyIndex
+
+ Get the property index for a changed property.
+
+
+
+
+ &reftitle.description;
+
+ intSDO_DAS_Setting::getPropertyIndex
+
+
+
+ &warn.experimental.func;
+
+
+ Returns the property index for the changed property. This index identifies the property which was modified in data object.
+
+
+
+
+ &reftitle.parameters;
+
+ None.
+
+
+
+ &reftitle.returnvalues;
+
+ The property index for a changed property.
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/reference/sdo/functions/SDO-DAS-Setting-getPropertyName.xml b/reference/sdo/functions/SDO-DAS-Setting-getPropertyName.xml
new file mode 100644
index 0000000000..b6a50f871f
--- /dev/null
+++ b/reference/sdo/functions/SDO-DAS-Setting-getPropertyName.xml
@@ -0,0 +1,140 @@
+
+
+
+
+
+ SDO_DAS_Setting::getPropertyName
+
+ Get the property name for a changed property.
+
+
+
+
+ &reftitle.description;
+
+ stringSDO_DAS_Setting::getPropertyName
+
+
+
+ &warn.experimental.func;
+
+
+ Returns the property name for the changed property. This name identifies the property which was modified in data object.
+
+
+
+
+ &reftitle.parameters;
+
+ None.
+
+
+
+ &reftitle.returnvalues;
+
+The property name for a changed property.
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/reference/sdo/functions/SDO-DAS-Setting-getValue.xml b/reference/sdo/functions/SDO-DAS-Setting-getValue.xml
new file mode 100644
index 0000000000..babe16786e
--- /dev/null
+++ b/reference/sdo/functions/SDO-DAS-Setting-getValue.xml
@@ -0,0 +1,146 @@
+
+
+
+
+
+ SDO_DAS_Setting::getValue
+
+ Get the old value for the changed property.
+
+
+
+
+ &reftitle.description;
+
+ mixed
+ SDO_DAS_Setting::getValue
+
+
+
+ &warn.experimental.func;
+
+
+ Returns the old value for the changed property.
+ This can be used by a Data Access Service when writing updates to a data source.
+ The DAS uses the old value to detect conflicts by comparing it with the current value in the data source.
+ If they do not match, then the data source has been updated since the data object was originally populated, and therefore
+ writing any new updates risks compromising the integrity of the data.
+
+
+
+
+
+ &reftitle.parameters;
+
+ None.
+
+
+
+ &reftitle.returnvalues;
+
+Returns the old value of the changed property.
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/reference/sdo/functions/SDO-DAS-Setting-isSet.xml b/reference/sdo/functions/SDO-DAS-Setting-isSet.xml
new file mode 100644
index 0000000000..9731cb905c
--- /dev/null
+++ b/reference/sdo/functions/SDO-DAS-Setting-isSet.xml
@@ -0,0 +1,139 @@
+
+
+
+
+
+ SDO_DAS_Setting::isSet
+
+ Test whether a property was set prior to being modified.
+
+
+
+ &reftitle.description;
+
+ booleanSDO_DAS_Setting::isSet
+
+
+
+ &warn.experimental.func;
+
+
+ Test whether a property was set prior to being modified.
If it was set prior to being modified then the SDO_DAS_Setting will also contain the old value.
+
+
+
+
+ &reftitle.parameters;
+
+ None.
+
+
+
+ &reftitle.returnvalues;
+
+ Returns true if the property was set prior to being modified, otherwise returns false.
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/reference/sdo/functions/SDO-DataFactory-create.xml b/reference/sdo/functions/SDO-DataFactory-create.xml
new file mode 100644
index 0000000000..e663026fbe
--- /dev/null
+++ b/reference/sdo/functions/SDO-DataFactory-create.xml
@@ -0,0 +1,166 @@
+
+
+
+
+
+ SDO_DataFactory::create
+
+ Create an SDO_DataObject.
+
+
+
+ &reftitle.description;
+
+ voidSDO_DataFactory::create
+ stringnamespaceURI
+ stringtypeName
+
+
+ &warn.experimental.func;
+
+
+ Create a new SDO_DataObject given the data object's namespace URI and type name.
+
+
+
+
+ &reftitle.parameters;
+
+
+
+ namespaceURI
+
+
+The namespace of the type.
+
+
+
+
+ typeName
+
+
+The name of the type.
+
+
+
+
+
+
+
+ &reftitle.returnvalues;
+
+Returns the newly created SDO_DataObject.
+
+
+
+
+ &reftitle.exceptions;
+
+
+
+
+ SDO_TypeNotFoundException
+
+
+
+Thrown if the namespaceURI and typeName do not correspond to a type known to this data factory
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/reference/sdo/functions/SDO-DataObject-clear.xml b/reference/sdo/functions/SDO-DataObject-clear.xml
new file mode 100644
index 0000000000..0c4f1b559f
--- /dev/null
+++ b/reference/sdo/functions/SDO-DataObject-clear.xml
@@ -0,0 +1,139 @@
+
+
+
+
+
+ SDO_DataObject::clear
+
+ Clear an SDO_DataObject's properties.
+
+
+
+ &reftitle.description;
+
+ voidSDO_DataObject::clear
+
+
+
+ &warn.experimental.func;
+
+
+ Clear an SDO_DataObject's properties. Read-only properties are unaffected.
Subsequent calls to isset() for the data object will return false.
+
+
+
+
+ &reftitle.parameters;
+
+ None.
+
+
+
+ &reftitle.returnvalues;
+
+ No return values.
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/reference/sdo/functions/SDO-DataObject-createDataObject.xml b/reference/sdo/functions/SDO-DataObject-createDataObject.xml
new file mode 100644
index 0000000000..b46b1d85c4
--- /dev/null
+++ b/reference/sdo/functions/SDO-DataObject-createDataObject.xml
@@ -0,0 +1,160 @@
+
+
+
+
+
+ SDO_DataObject::createDataObject
+
+ Create a child SDO_DataObject.
+
+
+
+ &reftitle.description;
+
+ SDO_DataObjectSDO_DataObject::createDataObject
+ mixedidentifier
+
+
+ &warn.experimental.func;
+
+
+ Create a child SDO_DataObject of the default type for the property identified.
+ The data object is automatically inserted into the tree and a reference to it is returned.
+
+
+
+
+
+ &reftitle.parameters;
+
+
+
+ identifier
+
+
+Identifies the property for the data object type to be created. Can be either a property name (string),
+or property index (int).
+
+
+
+
+
+
+
+ &reftitle.returnvalues;
+
+Returns the newly created SDO_DataObject.
+
+
+
+
+ &reftitle.exceptions;
+
+
+
+
+ SDO_PropertyNotFoundException
+
+
+
+ Thrown if the identifier does not correspond to a property of the data object.
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/reference/sdo/functions/SDO-DataObject-getContainer.xml b/reference/sdo/functions/SDO-DataObject-getContainer.xml
new file mode 100644
index 0000000000..e575f4c23e
--- /dev/null
+++ b/reference/sdo/functions/SDO-DataObject-getContainer.xml
@@ -0,0 +1,142 @@
+
+
+
+
+
+ SDO_DataObject::getContainer
+
+ Get a data object's container.
+
+
+
+
+ &reftitle.description;
+
+ SDO_DataObjectSDO_DataObject::getContainer
+
+
+
+ &warn.experimental.func;
+
+
+ Get the data object which contains this data object.
+
+
+
+
+
+ &reftitle.parameters;
+
+ None.
+
+
+
+ &reftitle.returnvalues;
+
+Returns the SDO_DataObject which contains this SDO_DataObject, or returns NULL
+if this is a root SDO_DataObject (i.e. it has no container).
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/reference/sdo/functions/SDO-DataObject-getContainmentPropertyName.xml b/reference/sdo/functions/SDO-DataObject-getContainmentPropertyName.xml
new file mode 100644
index 0000000000..e50fbecff7
--- /dev/null
+++ b/reference/sdo/functions/SDO-DataObject-getContainmentPropertyName.xml
@@ -0,0 +1,139 @@
+
+
+
+
+
+ SDO_DataObject::getContainmentPropertyName
+
+ Get the container's property name.
+
+
+
+
+ &reftitle.description;
+
+ string
+ SDO_DataObject::getContainmentPropertyName
+
+
+
+ &warn.experimental.func;
+
+
+ Get the property name used to refer to this data object by its containing data object.
+
+
+
+
+ &reftitle.parameters;
+
+ None.
+
+
+
+ &reftitle.returnvalues;
+
+Returns the name of the container's property which references this SDO_DataObject, or returns NULL if this is a root SDO_DataObject (i.e. it has no container).
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/reference/sdo/functions/SDO-DataObject-getSequence.xml b/reference/sdo/functions/SDO-DataObject-getSequence.xml
new file mode 100644
index 0000000000..aee414dec1
--- /dev/null
+++ b/reference/sdo/functions/SDO-DataObject-getSequence.xml
@@ -0,0 +1,143 @@
+
+
+
+
+
+ SDO_DataObject::getSequence
+
+ Get the sequence for a data object.
+
+
+
+ &reftitle.description;
+
+ SDO_SequenceSDO_DataObject::getSequence
+
+
+
+ &warn.experimental.func;
+
+
+ Return the SDO_Sequence for this SDO_DataObject. Accessing the SDO_DataObject
+through the SDO_Sequence interface acts on the same SDO_DataObject instance
+data, but preserves ordering across properties.
+
+
+
+
+
+ &reftitle.parameters;
+
+ None.
+
+
+
+ &reftitle.returnvalues;
+
+The SDO_Sequence for this SDO_DataObject, or returns NULL if the
+SDO_DataObject is not of a type which can have a sequence.
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/reference/sdo/functions/SDO-DataObject-getType.xml b/reference/sdo/functions/SDO-DataObject-getType.xml
new file mode 100644
index 0000000000..f753a07c5d
--- /dev/null
+++ b/reference/sdo/functions/SDO-DataObject-getType.xml
@@ -0,0 +1,137 @@
+
+
+
+
+
+ SDO_DataObject::getType
+
+ Get the type of a data object.
+
+
+
+ &reftitle.description;
+
+ arraySDO_DataObject::getType
+
+
+
+ &warn.experimental.func;
+
+
+ Return an array containing the type information for an SDO_DataObject.
+The first element contains the namespace URI string and the second
contains the type name string.
+
+
+
+
+ &reftitle.parameters;
+
+ None.
+
+
+
+ &reftitle.returnvalues;
+
+ An array containing the namespace URI string and the type name string for the data object.
+
+
+
+
+
+
+
+
+
+
+ &reftitle.examples;
+
+
+ A SDO_DataObject::getType example
+
+For example, if the SDO_DataObject were of type 'CompanyType' from
+the namespace 'CompanyNS', then getType() would return the equivalent to
+array('CompanyNS', 'CompanyType'):
+
+
+getType();
+ echo "Namespace: $do_type[0], Type Name: $do_type[1]";
+?>
+]]>
+
+ &example.outputs;
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/reference/sdo/functions/SDO-List-insert.xml b/reference/sdo/functions/SDO-List-insert.xml
new file mode 100644
index 0000000000..0b2d533a60
--- /dev/null
+++ b/reference/sdo/functions/SDO-List-insert.xml
@@ -0,0 +1,185 @@
+
+
+
+
+
+ SDO_List::insert
+
+ Insert into a list.
+
+
+
+
+
+ &reftitle.description;
+
+ void
+ SDO_List::insert
+
+ mixed
+ value
+
+
+ integer
+ index
+
+
+
+ &warn.experimental.func;
+
+
+ Insert a new element at a specified position in the list. All subsequent list items are moved up.
+
+
+
+
+ &reftitle.parameters;
+
+
+
+
+ value
+
+
+
+The new value to be inserted. This can be either a primitive or an SDO_DataObject.
+
+
+
+
+
+ index
+
+
+
+ The position at which to insert the new element. If this argument is not specified then the new value will be appended.
+
+
+
+
+
+
+
+ &reftitle.returnvalues;
+
+ None.
+
+
+
+
+ &reftitle.exceptions;
+
+
+
+ SDO_IndexOutOfBoundsException
+
+
+ Thrown if the list index is less than zero or greater than the size of the list.
+
+
+
+
+ SDO_InvalidConversionException
+
+
+Thrown if the type of the new value does not match the type for the list (e.g. the type of the many-valued property that the list represents).
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/reference/sdo/functions/SDO-Sequence-getPropertyIndex.xml b/reference/sdo/functions/SDO-Sequence-getPropertyIndex.xml
new file mode 100644
index 0000000000..de4471fb4b
--- /dev/null
+++ b/reference/sdo/functions/SDO-Sequence-getPropertyIndex.xml
@@ -0,0 +1,155 @@
+
+
+
+
+
+ SDO_Sequence::getPropertyIndex
+
+ Return the property index for the specified sequence index.
+
+
+
+ &reftitle.description;
+
+ integerSDO_Sequence::getPropertyIndex
+ integersequenceIndex
+
+
+ &warn.experimental.func;
+
+
+ Return the property index for the specified sequence index.
+ If the sequence item is unstructured text rather than a data object property, then a value of -1 is returned.
+
+
+
+
+ &reftitle.parameters;
+
+
+
+ sequenceIndex
+
+
+ The sequence index for which we wish to determine the associated data object property index.
+
+
+
+
+
+
+
+ &reftitle.returnvalues;
+
+ The corresponding property index. A value of -1 means the element does not belong to a property and must therefore be unstructured text.
+
+
+
+
+ &reftitle.exceptions;
+
+
+
+ SDO_IndexOutOfBoundsException
+
+
+Thrown if the sequence index is less than zero or greater than the size of the sequence.
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/reference/sdo/functions/SDO-Sequence-getPropertyName.xml b/reference/sdo/functions/SDO-Sequence-getPropertyName.xml
new file mode 100644
index 0000000000..e5adda838f
--- /dev/null
+++ b/reference/sdo/functions/SDO-Sequence-getPropertyName.xml
@@ -0,0 +1,157 @@
+
+
+
+
+
+ SDO_Sequence::getPropertyName
+
+ Return the property name for the specified sequence index.
+
+
+
+ &reftitle.description;
+
+ stringSDO_Sequence::getPropertyName
+ integersequenceIndex
+
+
+ &warn.experimental.func;
+
+
+ Return the property name for the specified sequence index.
+ If the sequence item is unstructured text rather than a data object property, then a value of NULL is returned.
+
+
+
+
+
+ &reftitle.parameters;
+
+
+
+ sequenceIndex
+
+
+The sequence index for which we wish to determine the associated data object property name.
+
+
+
+
+
+
+
+ &reftitle.returnvalues;
+
+The corresponding property name. A value of NULL means the element does not belong to a property and must therefore be unstructured text.
+
+
+
+
+ &reftitle.exceptions;
+
+
+
+ SDO_IndexOutOfBoundsException
+
+
+Thrown if the sequence index is less than zero or greater than the size of the sequence.
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/reference/sdo/functions/SDO-Sequence-insert.xml b/reference/sdo/functions/SDO-Sequence-insert.xml
new file mode 100644
index 0000000000..c8d3fcd326
--- /dev/null
+++ b/reference/sdo/functions/SDO-Sequence-insert.xml
@@ -0,0 +1,182 @@
+
+
+
+
+
+ SDO_Sequence::insert
+
+ Insert into a sequence.
+
+
+
+ &reftitle.description;
+
+ voidSDO_Sequence::insert
+ mixedvalue
+ integersequenceIndex
+ mixedpropertyIdentifier
+
+
+ &warn.experimental.func;
+
+
+ Insert a new element at a specified position in the sequence. All subsequent sequence items are moved up.
+
+
+
+
+ &reftitle.parameters;
+
+
+
+ value
+
+
+The new value to be inserted. This can be either a primitive or an SDO_DataObject.
+
+
+
+
+ sequenceIndex
+
+
+The position at which to insert the new element. Default is NULL, which results in the new value being appended to the sequence.
+
+
+
+
+ propertyIdentifier
+
+
+Either a property index or property name, used to identify a property in the sequence's corresponding SDO_DataObject. A value of NULL signifies unstructured text.
+
+
+
+
+
+
+
+ &reftitle.returnvalues;
+
+ None.
+
+
+
+
+ &reftitle.exceptions;
+
+
+
+
+ SDO_IndexOutOfBoundsException
+
+
+Thrown if the sequence index is less than zero or greater than the size of the sequence.
+
+
+
+
+ SDO_InvalidConversionException
+
+
+Thrown if the type of the new value cannot be juggled to match the type for the specified data object property.
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/reference/sdo/functions/SDO-Sequence-move.xml b/reference/sdo/functions/SDO-Sequence-move.xml
new file mode 100644
index 0000000000..9cffe095d8
--- /dev/null
+++ b/reference/sdo/functions/SDO-Sequence-move.xml
@@ -0,0 +1,178 @@
+
+
+
+
+
+ SDO_Sequence::move
+
+ Move an item to another sequence position.
+
+
+
+ &reftitle.description;
+
+ void
+ SDO_Sequence::move
+
+ integer
+ toIndex
+
+
+ integer
+ fromIndex
+
+
+
+ &warn.experimental.func;
+
+
+ Modify the position of the item in the sequence, without altering the value of the property in the SDO_DataObject.
+
+
+
+
+ &reftitle.parameters;
+
+
+
+
+ toIndex
+
+
+
+The destination sequence index. If this index is less than zero or greater than the size of the sequence then the value is appended.
+
+
+
+
+
+ fromIndex
+
+
+
+The source sequence index.
+
+
+
+
+
+
+
+ &reftitle.returnvalues;
+
+ None.
+
+
+
+
+ &reftitle.exceptions;
+
+
+
+
+
+ SDO_IndexOutOfBoundsException
+
+
+
+Thrown if the fromIndex sequence index is less than zero or greater than the size of the sequence.
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/reference/sdo/reference.xml b/reference/sdo/reference.xml
new file mode 100644
index 0000000000..6d9c398f5f
--- /dev/null
+++ b/reference/sdo/reference.xml
@@ -0,0 +1,1315 @@
+
+
+
+
+ SDO Functions
+ SDO
+
+
+
+ &reftitle.intro;
+
+
+ &warn.experimental;
+
+
+ Service Data Objects (SDOs) are designed to simplify working with
+ heterogeneous data whilst also being tailored for service-oriented
+ applications. Using SDO, developers can uniformly manipulate data for
+ hetergeneous data sources, such as relational databases and XML.
+
+
+ SDOs are based on the concept of disconnected data graphs. A data
+ graph is a tree structure of data objects, navigable via their containment
+ references. A containment reference is an aggregation relationship. For
+ example, a Company data object might consists of a number of Department
+ data objects and therefore the Company would have a containment
+ reference to the Departments. A data graph also allows non-containment
+ references. These are references between data objects within the same
+ tree. For example, one Employee data object might reference another
+ to identify a career mentor.
+
+
+ The task of connecting an application to a data source is
+ performed by a Data Access Service (DAS). Applications use a DAS to retrieve
+ an SDO from a data source. The application can then manipulate the
+ SDO and use a DAS to write it back to the same, or an alternative,
+ data source.
+
+
+ See the
+ list of Data Access Services
+ for details on those
+ currently available. In addition to the provided DASs, SDO also
+ provides interfaces to enable others to be implemented (see the section on
+ SDO Data Access Services Interface
+ for more details).
+
+
+ This extension is derived from concepts taken from the
+
+ Service Data Objects specification
+
+.
+
+
+
+
+ &reftitle.required;
+
+ The SDO extension requires PHP 5.1 or higher.
+
+
+ SDO XML Data Access Service, which is built as part of this extension, requires libxml2
+ (Tested with libxml2 2.6.19) which can be downloaded from http://xmlsoft.org/downloads.html"
+
+
+
+
+
+
+ &reftitle.install;
+
+
+ An automated installation process using PEAR will be supplied soon.
+ Meanwhile, you can build the extension manually using the steps below.
+
+
+
+ Linux intallation steps
+
+ The following instructions describe how to install the SDO extension on Linux. Note, these
+ steps will also install the
+ XML Data Access Service
+ which is packaged as part of this extension.
+
+
+ Note, if you built your PHP installation in a different location, using --prefix,
+ then you will need to adjust the ./configure steps below accordingly.
+
+
+
+ Download the SDO extension from the pecl/sdo directory on CVS.
+
+
+
+
+ The SDO and SDO_DAS_XML are implemented as a separate internal 'core' C++ libraries which must be built before building the main extension.
+ This can be done by using the following steps:
+
+
+
+
+ Go to the core library directory: cd sdo/sdolib
+
+
+
+
+ Run ./configure
+
+
+
+
+ The following step is required to ensure g++, and NOT gcc
+ is used to build the the libraries.
+
+
+ Open libtool created by the configure script and
+ change the line which says CC="gcc" to CC="g++".
+
+
+
+
+ Run make; make install
+
+
+
+
+
+
+ Change to the main extension directory: cd ..
+
+
+
+
+ Run phpize, which will set up the environment to compile both SDO and the XML Data Access Service.
+
+
+
+
+ Next run ./configure; make; make install.
+
+
+ Note, the compilation process checks for internal 'core' library which was installed in the previous build steps.
+
+
+ Note, if you used --prefix for the internal 'core' library build, then you will need to add --with-sdolibs=...
+ to the ./configure to point to the destination where the libraries were built.
+
+
+
+
+ Make sure that these modules are loaded by PHP, by adding
+ extension=sdo.so and extension=sdo_das_xml.so
+ to your php.ini file.
+
+
+
+
+
+
+
+ Data Access Services
+
+ The table below lists the currently provided SDO Data Access Services:
+
+
+
+
+ DAS Name
+ Description
+
+
+
+
+
+ SDO_DAS_XML
+
+
+ An XML Data Access Service supporting reading/writing
+ SDOs as XML documents or via a Web URL to supporting things like RSS feeds.
+
+
+
+
+ SDO_DAS_Relational
+
+
+ A PDO-based Data Access Service supporting reading/writing SDO to relational
+ data sources. Implements an optimistic concurrency policy for updates.
+
+
+
+
+
+
+
+
+
+
+ Limitations
+
+ Implementation Limitations
+
+ The following are limitations in the current SDO implementation:
+
+
+
+ There is no support for multi-byte character sets.
+
+
+
+
+ The class constants SDO_DAS_ChangeSummary::NONE, SDO_DAS_ChangeSummary::MODIFICATION,
+ SDO_DAS_ChangeSummary::ADDITION, SDO_DAS_ChangeSummary::DELETION are unavailable,
+ because of an outstanding problem.
+
+
+ As a bypass, the global constants SDO_DAS_CHANGE_SUMMARY_NONE,
+ SDO_DAS_CHANGE_SUMMARY_MODIFICATION, SDO_DAS_CHANGE_SUMMARY_ADDITION,
+ SDO_DAS_CHANGE_SUMMARY_DELETION are provided.
+
+
+
+
+ You may see problems when serializing and unserializing graphs which include
+ non-containment references. We are working on these.
+
+
+
+
+ SDO Limitations
+
+ The following SDO 2.0 concepts are not supported in the current PHP implementation.
+ It is not necessarily the case that these will all be added over time.
+ Their inclusion will depend on community requirements.
+
+
+
+ Abstract types and type derivation.
+
+
+
+
+ Open types.
+
+
+
+
+ Bi-directional relationships.
+
+
+
+
+ Type and property alias names.
+
+
+
+
+ Default property values.
+
+
+
+
+ Read-only properties.
+
+
+
+
+ Model introspection.
+
+
+
+
+ XMLHelper/XSDHelper (the XML DAS provide a lot of this functionality)
+
+
+
+
+ TypeHelper (the SDO_DAS_DataFactory provides this functionality)
+
+
+
+
+
+
+ &reftitle.examples;
+
+ The examples below assume an SDO created with the schema
+ and instance information shown below, using the XML Data Access Service.
+
+
+ The schema describes a company data object. The company contains department data objects, and
+ each department contains employee data objects.
+ Each data object has a number of primitive properties to describe things like name, serial number, etc.
+ Finally, the company data object also has a non-containment reference to one of the employee data
+ objects to identify them as the 'employeeOfTheMonth'.
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+]]>
+
+
+
+
+ The instance document below describes a single company, called 'MegaCorp', w
+ hich contains a single department, called 'Advanced Technologies'.
+ The Advanced Technologies department contains three employees.
+ The company employeeOfTheMonth is referencing the second employee, 'Jane Doe'.
+
+
+
+
+
+
+
+
+
+
+
+
+]]>
+
+
+
+
+
+
+ Setting and Getting Property Values
+
+ The following examples assume
+ $company
+ is a data object created from the schema and instance document shown above.
+
+
+
+ Access via Property names
+
+ Data object properties can be accessed using the object property
+ access syntax. The following gets the list of departments (containing a
+ single department), and sets the company name to 'Acme'.
+
+
+ departments;
+ $company->name = 'Acme';
+?>
+]]>
+
+
+
+
+
+
+ Access via Property index
+
+ Data object properties can be accessed via their property index
+ using array syntax. The property index is the position at which the
+ property's definition appears in the model (in this case the xml schema).
+ We can see from the schema listing above that the departments element is the
+ first company property defined and the company name attribute is the second
+ company property (the SDO interface makes no distinction between XML attributes
+ and elements). The following gets the list of departments (containing a
+ single department), and sets the company name to 'Acme'.
+
+
+
+]]>
+
+
+
+
+
+
+ Data Object Iteration
+
+ We can iterate over the properties of a data object using foreach.
+ The following iterates over the company properties; name, departments and
+ employeeOfTheMonth.
+
+
+ $value) {
+ ...
+ }
+?>
+]]>
+
+
+ For the first iteration, $name will be 'name' and $value
+ will be 'Acme'. For the second iteration, $name will be
+ 'departments' and $value will be an SDO_List (because departments is a
+ many-valued property (stated
+ maxOccurs="unbouded"
+ in the schema)) containing a single data object of type DepartmentType.
+ For the third iteration, $name will be 'employeeOfTheMonth' and $value
+ will be a data object of type EmployeeType.
+
+
+
+
+
+
+ Many-valued Property Iteration
+
+ Many-valued properties can also be iterated over using
+ foreach. The following iterates over the company's departments.
+
+
+ departments as $department) {
+ ...
+ }
+?>
+]]>
+
+
+ Each iteration will assign the next department in the
+ list to the variable
+ $department
+.
+
+
+
+
+
+
+
+
+ Many-valued Element Access
+
+
+ We can access individual elements of many-valued properties
+ using array syntax. The following accesses the first department in the
+ company.
+
+
+ departments[0];
+?>
+]]>
+
+
+
+
+
+
+ Nested Property Access
+
+ We can use nested property access to navigate the data object
+ instance structure. The following gets and sets the name of the first
+ department.
+
+
+ departments[0]->name;
+ $company->departments[0]->name = 'Emerging Technologies';
+?>
+]]>
+
+
+
+
+
+
+
+ Simple XPath support
+
+ We can access properties using XPath-like (an augmented
+ sub-set of XPath) expressions, the simplest form of which is the property
+ name. The following sets the company name and gets the employeeOfTheMonth.
+
+
+
+]]>
+
+
+
+
+
+
+ Simple XPath support
+
+ We can use chained array access calls to navigate the data
+ object instance structure. The following gets and sets the name of the
+ first department.
+
+
+
+]]>
+
+
+
+
+
+
+ XPath Navigation
+
+ We can use XPath expressions to navigate the data object
+ instance structure. Two forms of indexing into many-valued properties are
+ supported. The first is the standard XPath array syntax with the indexing
+ starting at one, the second is an SDO extension to XPath with an index
+ starting at zero. The following both get the second employee from the
+ first department.
+
+
+
+]]>
+
+
+
+
+
+
+ XPath Querying
+
+ We can use XPath to query and identify parts of a data object based
+ on instance data. The following retrieves the manager from the
+ 'Advanced Technologies' department.
+
+
+
+]]>
+
+
+
+
+
+
+ Creating child data object
+
+ A data object can be a factory for its child data objects. A child
+ data object is automatically part of the data graph. The
+ following add a new employee to the 'Advanced Technologies' department.
+
+
+ createDataObject('employees');
+ $new_hire->name = 'John Johnson';
+ $new_hire->SN = 'E0005';
+ $new_hire->manager = false;
+?>
+]]>
+
+
+
+
+
+
+ Unset referenced data object
+
+ We can use the
+ isset
+and
+ unset
+functions to test and remove items
+ from the data object.
+
+
+ The following removes the 'employeeOfTheMonth' from the company.
+ If this were a containment reference then the
+ employee would be removed from the company (probably not a good idea to
+ sack your best employee each month!), but since this is a non-containment
+ reference, the employee being referenced will remain in the department in
+ the company, but will no longer be accessible via the employeeOfTheMonth
+ property.
+
+
+ employeeOfTheMonth) {
+ unset($company->employeeOfTheMonth);
+ }
+?>
+]]>
+
+
+
+
+
+
+ Working with Sequenced Data Objects
+
+ Sequenced data objects are SDOs which can track property
+ ordering across the properties of a data object. They can also
+ contain unstructured text elements (text element which do not
+ belong to any of the SDO's properties). Sequenced data objects are
+ useful for working with XML documents which allow unstructured text (i.e.
+ mixed=true) or if the elements can be interleaved (
+ ]]>). This can occur for example when
+ the schema defines maxOccurs>1 on a
+ element which is a complexType with a choice order indicator.
+
+
+ The examples below assume an SDO created with the following schema
+ and instance information, using the XML Data Access Service.
+
+
+ The schema below describes the format of a letter. The letter can
+ optionally contain three properties; date, firstName, and lastName.
+ The schema states
+ mixed="true"
+which means that
+ unstructured text can be interspersed between the three properties.
+
+
+
+
+
+
+
+
+
+
+
+
+
+ ]]>
+
+
+
+
+ The following is an instance letter document. It contains the
+ three letter properties; date, firstName and lastName, and has
+ unstructured text elements for the address and letter body.
+
+
+
+
+ March 1, 2005
+ Mutual of Omaha
+ Wild Kingdom, USA
+ Dear
+ Casy
+ Crocodile
+ Please buy more shark repellent.
+ Your premium is past due.
+
+ ]]>
+
+
+
+ When loaded, the letter data object will have the sequence and
+ property indices shown in the table below:
+
+
+
+
+ Sequnece Index
+ Property Index:Name
+ Value
+
+
+
+
+ 0
+ 0:date
+ March 1, 2005
+
+
+ 1
+ -
+ Mutual of Omaha
+
+
+ 2
+ -
+ Wild Kingdom, USA
+
+
+ 3
+ -
+ Dear
+
+
+ 4
+ 1:firstName
+ Casy
+
+
+ 5
+ 2:lastName
+ Crocodile
+
+
+ 6
+ -
+ Please buy more shark repellent.
+
+
+ 7
+ -
+ Your premium is past due.
+
+
+
+
+
+
+
+ To ensure sequence indices are maintained, sequenced data objects
+ should be manipulated through the SDO_Sequence interface. This allows
+ the data object's instance data to be manipulated in terms of the sequence
+ index as opposed to the property index (shown in the table above). The
+ following examples assume the letter instance has been loaded into a
+ data object referenced by the variable
+ $letter
+.
+.
+
+ Getting the SDO_Sequence interface
+
+ We obtain a data object's sequence using the
+ getSequence
+method. The follow gets the
+ sequence for the letter data object.
+
+
+ getSequence();
+?>
+]]>
+
+
+
+
+ All subsequent examples assume that the
+ $letter_seq
+ variable has been assigned the sequence for the letter data object.
+
+
+
+
+ Get/set sequence values
+
+ We can get and set individual values (including unstructured text)
+ using the sequence index. The following sets the firstName to 'Snappy'
+ and gets the last sequence values (the unstructured text, 'Your premium is
+ past due.').
+
+
+
+]]>
+
+
+
+
+
+
+ Sequence iteration
+
+ We can iterate through the individual sequence values using foreach.
+ The following runs through the individual values in sequence order.
+
+
+ getSequence() as $value) {
+ ...
+ }
+?>
+]]>
+
+
+
+
+
+
+ Sequence versus Data Object
+
+ Setting values through the data object interface may result in the
+ value not being part of the sequence. A value set through the data
+ object will only be accessible through the sequence if the property was
+ already part of the sequence. The following example sets the
+ lastName through the data object and gets it through the sequence.
+ This is fine because lastName already exists in the sequence. If
+ it had not previously been set, then lastName would be set to
+ 'Smith', but would not be part of the sequence.
+
+
+
+]]>
+
+
+
+
+
+
+ Adding to a sequence
+
+ We can add new values to a sequence using the
+
+ SDO_Sequence::insert
+
+method. The following examples assume that the 'firstName' and
+ 'lastName' properties are initially unset.
+
+
+ insert('Smith', NULL, 1);
+
+ // Append a lastName value to the sequence
+ // value: 'Jones'
+ // sequence index: NULL (append)
+ // property identifier: 'lastName' (lastName property name)
+ $letters_seq->insert('Jones', NULL, 'lastName');
+
+ // Append unstructured text
+ // value: 'Cancel Subscription.'
+ // sequence index: absent (append)
+ // propertyIdentifier: absent (unstructured text)
+ $letters_seq->insert('Cancel Subscription.');
+
+ // Insert new unstructured text. Subsequent sequence values
+ // are shifted up.
+ // value: 'Care of:'
+ // sequence index: 1 (insert as second element)
+ // propertyIdentifier: absent (unstructured text)
+ $letters_seq->insert('Care of:', 1);
+?>
+]]>
+
+
+
+
+
+
+ Removing from a sequence
+
+ We can use the
+ isset
+and
+ unset
+functions to test and remove items
+ from the sequence (Note:
+ unset
+currently
+ leaves the values in the data object, but this behaviour is
+ likely to change to also remove the data from the data object).
+ Sequence behaves like a contiguous list and therefore removing
+ from the middle results in entries at higher indices being shifted
+ down. The following example tests to see if the first sequence
+ element is set and unsets it if is.
+
+
+
+]]>
+
+
+
+
+
+
+
+
+
+ &reftitle.classes;
+
+ SDO consists to two set of interfaces. The first set covers those
+ interfaces for use by SDO client applications. These are identified by
+ the package prefix 'SDO_'. The second set is those for use by Data
+ Access Service implementations and are identified by the package prefix
+ 'SDO_DAS_'. The majority of SDO users will not need to use or understand
+ the 'SDO_DAS_' interfaces.
+
+
+
+ SDO Application Programmer Interface
+
+
+
+
+ SDO_DataObject
+
+
+ The main interface through which data objects are manipulated. In
+ addition to the methods below, SDO_DataObject extends the
+ ArrayAccess, SDO_PropertyAccess (defines
+ __get
+/
+ __set
+ methods for property access overloading), Iterator, and
+ Countable interfaces
+
+ &reftitle.methods;
+
+
+
+ getType
+ - get the type of a data object
+
+
+
+
+ getSequnece
+ - get the sequence for the data object
+
+
+
+
+ createDataObject
+ - create a child data object
+
+
+
+
+ clear
+ - unset the properties of a data object
+
+
+
+
+ getContainer
+ - get the container (also known as 'parent') of this data object
+
+
+
+
+ getContainmentPropertyName
+ - get the name by which the parent refers to this data object
+
+
+
+
+
+
+
+
+ SDO_Sequence
+
+
+ The interface through which sequenced data objects can be accessed in
+ order to preserve ordering across a data object's properties and to allow
+ unstructured text. SDO_Sequence preserves contiguous indices and
+ therefore inserting or removing elements may results in other elements shifted up or
+ down. In addition to the methods below, SDO_Sequence extends the
+ ArrayAccess, Iterator and Countable interface.
+
+
+ &reftitle.methods;
+
+
+
+ getPropertyIndex
+ - get the property index for a given sequence index
+
+
+
+
+ getPropertyName
+ - get the property name for a given sequence index
+
+
+
+
+ move
+ - move an element from one property index to another
+
+
+
+
+ insert
+ - insert a new value into the sequence
+
+
+
+
+
+
+
+
+ SDO_List
+
+
+ The interface through which many-valued properties are manipulated.
+ In addition to the method defined below, SDO_List extends ArrayAccess,
+ Iterator and Coutable. SDO_List preserves contiguous indices and
+ therefore inserting or removing elements may results in other elements
+ shifted up or down.
+
+
+ &reftitle.methods;
+
+
+
+ insert
+ - insert a new value into the list
+
+
+
+
+
+
+
+
+ SDO_DataFactory
+
+
+ The interface through which data objects can be created. A Data
+ Access Service is responsible for populating the model (i.e. configuring
+ the data factory with the type and structure information for the data
+ objects it can create.) for the factory and
+ can then optionally return an instance of, or implement, the
+ SDO_DataFactory interface.
+
+
+ &reftitle.methods;
+
+
+
+ create
+ - create a new data object
+
+
+
+
+
+
+
+
+
+
+ SDO Data Access Service Developer Interfaces
+
+
+
+
+
+ SDO_DAS_DataObject
+
+
+ The interface through which a Data Access Service can access a data object's
+ SDO_DAS_ChangeSummary.
+ The change summary is used by the Data Access Service to check for conflicts
+ when applying changes back to a data source.
+
+ &reftitle.methods;
+
+
+
+ getChangeSummary
+ - get the change summary for a data object
+
+
+
+
+
+
+
+
+
+
+ SDO_DAS_ChangeSummary
+
+
+ The interface through which the change history of a data
+ object is accessed. The change summary holds information for any
+ modifications on a data object which occurred since logging
+ was activated. In the case of deletions and modifications, the old
+ values are also held in the change summary.
+
+
+ If logging is no longer active
+ then the change summary only hold changes made up to the point when
+ logging was deactivated. Reactivating logging clears the change summary.
+ This is useful when a set of changes have been written out by a
+ DAS and the data object is to be reused.
+
+
+ &reftitle.methods;
+
+
+
+ beginLogging
+ - begin logging changes made to a data object
+
+
+
+
+ endLogging
+ - end logging changes made to a data object
+
+
+
+
+ isLogging
+ - test to see if change logging is on
+
+
+
+
+ getChangedDataObjects
+ - get a list of the data objects which have been changed
+
+
+
+
+ getChangeType
+ - get the type of change which has been made to a data object
+
+
+
+
+ getOldValues
+ - get a list of old values for a data object
+
+
+
+
+ getOldContainer
+ - get the old container data object for a deleted data object
+
+
+
+
+
+
+
+
+ SDO_DAS_Setting
+
+
+ The interface through which the old value for a property is
+ accessed. A list of settings is returned by the change summary method
+
+ getOldValues
+
+.
+
+
+ &reftitle.methods;
+
+
+
+ getPropertyIndex
+ - get the property index for the changed property
+
+
+
+
+ getPropertyName
+ - get the property name for the changed property
+
+
+
+
+ getValue
+ - get the old value for the changed property
+
+
+
+
+ getListIndex
+ - get the list index for the old value if it was part of
+ a many-valued property
+
+
+
+
+ isSet
+ - test to see if the property was set prior to being modified
+
+
+
+
+
+
+
+
+ SDO_DAS_DataFactory
+
+
+ The interface for constructing the model for an SDO_DataObject.
+ The SDO_DAS_DataFactory is an abstract class providing a static
+ method which returns a concrete data factory implementation.
+ The implementation is used by Data Access Services to create an SDO model from their model.
+ For example, a Relational Data Access Service might create and populate an
+ SDO_DAS_DataFactory model based on a schema for a relational database.
+
+
+ &reftitle.methods;
+
+
+
+ getDataFactory
+ - static methods for getting a concrete data factory instance
+
+
+
+
+
+
+ addType
+ - add a new type to the SDO model
+
+
+
+
+
+
+ addPropertyToType
+ - add a new property to a type definition in the SDO model
+
+
+
+
+
+
+
+
+ &reference.sdo.constants;
+
+
+
+ &reference.sdo.functions;
+
+
+