This class acts as helper class for instantiating the Content Provider Registry. It instantiates the Spring container and returns a Spring created Content Provider Registry instance.
The Content Provider Registry is the access point to the different Content Providers and it also allows adding and removing of Content Folders . Hence it can be seen as central refuge for every functionality the image gallery provides. The View component should never talk to a Content Provider directly. Instead it asks the Content Provider Registry for a Content Folder . Each Content Folder knows the name of its Content Provider and with this name a Content Provider can be retrieved by the Content Provider Registry .
A content provider is an implementation of a fixed set of interfaces for a single storage format. It retrieves and optionally saves and manipulates all data of one storage format. Thus a content provider is the interface to the data which should be used. Within the Model View Controller Pattern it resembles the Model part of the whole gallery although of course a content provider can be separated in sublayers itself. Currently the only existing Content Provider connects to the Alfresco Content Management System, but other Content Providers can easily be added. If you want to implement a new content provider please refer to Implementing And Registerung A New Content Provider . Future Content Providers could connect to other content management systems, to the filesystem or any other storage format.
A Content Folder is similar to a folder in the filesystem. Comparing to a folder in the filesystem it does not contain the data itself. Instead it only contains a path and the name of its Content Provider . With this information and the Content Provider Registry the data can be retrieved.