EDXL Distribution Element DOM





Proposed Sahana EDXL-DE Database Implementation



Note: This is not a true ER diagram, just a rough take on how EDXL-DE objects could be stored in Sahana.

Database Specifics


In Sahana, we would create 5 database entities, and 4 relations, for a total of 9 tables. Referential integrity would be maintained through the SQL schema. The basis is to create a method for storing a generalized EDXL-DE object upon which other XML specs (ie. LPF or CAP) can build from.

PHP Class Objects


The core usage of EDXL-DE throughout Sahana would rely upon an implementation compromised of class objects which tie directly to the 5 corresponding database entities. Other modules or framework services which needed to access EDXL-DE objects would do so via the core EDXLDistribution class object, or build atop of it and extend other class objects from this base class.

Possible base class methods


  • new() – creates a new EDXL-DE object in Sahana
  • new(dsitributionId) – creates a new EDXL-DE object in Sahana and prepopulates it with existing data from an object already stored in the database
  • newFromXML(XML) – creates a new EDXL-DE object in Sahana and populates it with data from an XML file
  • save() – saves a EDXL-DE object to the database
  • delete() – removes an EDXL-DE object from the database
  • search(term) – performs a search across all stored EDXL-DE objects in the database across all fields and return a list of distributionId's where matches occur)
  • addTargetArea()
  • delTargetArea()
  • addContentObject()
  • delContentObject()
  • export() – for exporting the EDXL document – function returns a string in XML format of the EDXL object





Examples of EDXL data used in Sahana


QR Code
QR Code wiki:user:edxl_discussion (generated for current page)