Engine/DataModel

The Elgg data model diagram
In Elgg, everything runs on a unified data model, based on atomic units of data called entities.

Plugins are strongly discouraged from dealing with database issues themselves, which makes for a more stable system that also has visible benefits for the end user. Content created by different plugins can be mixed together in consistent ways, which are programmed using generic principles - in other words, plugins are faster to develop, and are at the same time much more powerful.

Every entity in the system inherits the ElggEntity class. This class controls access permissions, ownership and so on.

Annotations and metadata

You can extend entities with extra information in two ways:

  • Metadata This is information you can add to an object to describe it further. For example, tags, an ISBN number, a file location or language information would fall under metadata.
  • Annotations Information generally added by third parties which adds to the information provided by the entity. For example, comments and ratings are both annotations.

See also

Search docs