CMS User Guide

Objectives

CMS module has the main goal to abstract the interaction between a DIF application and a Content Management System.

Since the interaction is product independent, the CMS module covers the main and general funcionalities of a CMS.

More technical CMS module details can be found here.

The complete CMS Module API can be inspected here.

Initialization

IContentManager interface has a similar initialization process as other interfaces in DIF2 framework.

The main initialization processes are:

  • Interface initialization by DIFIoCRegistry;
    IContentManager contentManager = DIFIoCRegistry.getRegistry().getImplementation(IContentManager.class);
    
  • Interface initialization by annotation.
    @inject
    IContentManager contentManager;
    

IContentManager and Object Operations

Operations in CMS module API can be done by two different ways: using IContentManager interface or Object operations.

Both Node and ContentItem objects support operations on that object, namely:

  • update object
  • delete object (Node objects also have deleteCascade operation)
  • move object
  • get object ACL
  • grant access to object
  • revoke access to object

All operations performed directly in the object are unit operations, which have effects exclusively in that object

Despite this object operations, all CMS operations can be done directly in the IContentManager interface.

Operation code examples

Operations in IContentManager interface focus on Node or ContentItem objects. Both operation groups have CRUD, finder and access operations.