Class DocumentWorkspaceModule
- java.lang.Object
-
- org.ametys.runtime.plugin.component.AbstractLogEnabled
-
- org.ametys.plugins.workspaces.AbstractWorkspaceModule
-
- org.ametys.plugins.workspaces.documents.DocumentWorkspaceModule
-
- All Implemented Interfaces:
Comparable<WorkspaceModule>,WorkspaceModule,LogEnabled,PluginAware,Contextualizable,Serviceable
public class DocumentWorkspaceModule extends AbstractWorkspaceModule
Helper component for managing documents
-
-
Field Summary
Fields Modifier and Type Field Description static StringDODUMENT_MODULE_IDThe id of document modulestatic StringWORKSPACES_DOCUMENTS_NODE_NAMEWorkspaces documents node name-
Fields inherited from class org.ametys.plugins.workspaces.AbstractWorkspaceModule
_context, _currentUserProvider, _i18nUtils, _modulesEP, _observationManager, _pageDAO, _pluginName, _projectManager, _projectRightHelper, _resolver, _rightManager, _serviceEP, _skinsManager, _userHelper, _userManager
-
Fields inherited from interface org.ametys.plugins.workspaces.project.modules.WorkspaceModule
ORDER_ALERTS, ORDER_CALENDAR, ORDER_DOCUMENTS, ORDER_MEMBERS, ORDER_NEWS, ORDER_TASKS, ORDER_THREADS, ORDER_WALLCONTENT, ORDER_WIKI
-
-
Constructor Summary
Constructors Constructor Description DocumentWorkspaceModule()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidcontextualize(Context context)Set<String>getAllowedEventTypes()Get the set of allowed event type for the moduleStringgetFolderUri(Project project, String collectionId)Get the URI of a folder in project'siteStringgetId()Get the module IdMap<String,Object>getModuleBaseRights()Retrieves the set of general rights used in the document module for the current userI18nizableTextgetModuleDescription()Get the module titleStringgetModuleName()Get the module nameprotected StringgetModulePageName()Returns the module page's nameprotected I18nizableTextgetModulePageTitle()Returns the module page's title as i18nModifiableResourceCollectiongetModuleRoot(Project project, boolean create)Get the module root node for the given projectI18nizableTextgetModuleTitle()Get the module titleintgetOrder()Get the module orderprotected voidinitializeModulePage(ModifiablePage documentPage)Initialize the module page-
Methods inherited from class org.ametys.plugins.workspaces.AbstractWorkspaceModule
_createModulePage, _deleteEvents, _deletePages, _getAmetysObject, _getDefaultXslt, _getModulePages, _internalActivateModule, _internalDeactivateModule, _internalDeleteData, _setPagesVisibility, activateModule, deactivateModule, deleteData, getModulePageTemplate, getModuleUrl, initializeSitemap, service, setPluginInfo
-
Methods inherited from class org.ametys.runtime.plugin.component.AbstractLogEnabled
getLogger, setLogger
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.ametys.plugins.workspaces.project.modules.WorkspaceModule
compareTo
-
-
-
-
Field Detail
-
DODUMENT_MODULE_ID
public static final String DODUMENT_MODULE_ID
The id of document module
-
WORKSPACES_DOCUMENTS_NODE_NAME
public static final String WORKSPACES_DOCUMENTS_NODE_NAME
Workspaces documents node name- See Also:
- Constant Field Values
-
-
Constructor Detail
-
DocumentWorkspaceModule
public DocumentWorkspaceModule()
-
-
Method Detail
-
contextualize
public void contextualize(Context context) throws ContextException
- Specified by:
contextualizein interfaceContextualizable- Overrides:
contextualizein classAbstractWorkspaceModule- Throws:
ContextException
-
getId
public String getId()
Description copied from interface:WorkspaceModuleGet the module Id- Returns:
- The module ID
-
getModuleName
public String getModuleName()
Description copied from interface:WorkspaceModuleGet the module name- Returns:
- the module name
-
getOrder
public int getOrder()
Description copied from interface:WorkspaceModuleGet the module order- Returns:
- the priority in menus
-
getModulePageName
protected String getModulePageName()
Description copied from class:AbstractWorkspaceModuleReturns the module page's name- Specified by:
getModulePageNamein classAbstractWorkspaceModule- Returns:
- The module page's name
-
getModuleTitle
public I18nizableText getModuleTitle()
Description copied from interface:WorkspaceModuleGet the module title- Returns:
- The title
-
getModuleDescription
public I18nizableText getModuleDescription()
Description copied from interface:WorkspaceModuleGet the module title- Returns:
- The title
-
getModulePageTitle
protected I18nizableText getModulePageTitle()
Description copied from class:AbstractWorkspaceModuleReturns the module page's title as i18n- Specified by:
getModulePageTitlein classAbstractWorkspaceModule- Returns:
- The module page's title
-
initializeModulePage
protected void initializeModulePage(ModifiablePage documentPage)
Description copied from class:AbstractWorkspaceModuleInitialize the module page- Specified by:
initializeModulePagein classAbstractWorkspaceModule- Parameters:
documentPage- The module page
-
getFolderUri
public String getFolderUri(Project project, String collectionId)
Get the URI of a folder in project'site- Parameters:
project- The projectcollectionId- The id of collection- Returns:
- The thread uri
-
getModuleBaseRights
public Map<String,Object> getModuleBaseRights()
Retrieves the set of general rights used in the document module for the current user- Returns:
- The map of right data. Keys are the rights id, and values indicates whether the current user has the right or not.
-
getModuleRoot
public ModifiableResourceCollection getModuleRoot(Project project, boolean create)
Description copied from interface:WorkspaceModuleGet the module root node for the given project- Parameters:
project- The project containing the modulecreate- True to create the node if it does not exists- Returns:
- The root node, or null if it does not exists and was not created
-
getAllowedEventTypes
public Set<String> getAllowedEventTypes()
Description copied from interface:WorkspaceModuleGet the set of allowed event type for the module- Returns:
- The set of allowed event types
-
-