What are XDOs?

XDOs - eXtensible Data Objects are one of the main features of phpSATk. They provide a unified, abstract interface to properties of manageable objects and are extensible by hierarchically attaching other XDOs to them, forming a collection. Each object is uniquely identified by its type identifier and at least one unique value (index value).

For example you might take an XDO implementing the ‘person’ objectClass (LDAP) and attach a ‘posixAccount’ object and some XDO fetching some data from a database. The attached object might now identify the data to manage using the parent (’person’) object and form a collection of all data about the given user. This is especially useful for the purpose of deletion where now a deletion of a parent object will first delete all child objects and for view generation where the (transparently) attached object now will show up in applications not even knowing about them.

For accessing a set of Data Object Collections DataSets are build. They come in two flavors, either flat (a simple set of objects) or hierarchical (a tree of objects).

What features do XDOs provide?

  • “magic” properties which can transparently invoke getters/setters (which can be delegated to other objects)
  • a event mechanism making it possible to trace changes to other objects in the collection
  • access control on per property basis
  • provide the base for automatic view generation

Ideas about XDOs

  • When building applications you might want to define a generic base object (lets take a ‘user’ as an example) storing information which might be needed by multiple other objects (let’s say ‘username’ and ‘password’). Now, if you have control over the child objects they might listen passively for changes to the generic object and update themselves based on it’s values, or if you do not have control activly push the set values to the children. This allows you to keep your data consistent.

Problems

At least at the moment the process of creating new XDOs is not implemented in a near-optimal way. You will need to do many iterations of fetching/attaching for building up a deep hierarchy of XDOs.

 
xdo.txt · Last modified: 2007/05/21 10:44 by mbechler
 
Recent changes RSS feed Creative Commons License Donate Powered by PHP Valid XHTML 1.0 Valid CSS Driven by DokuWiki