Package org.ametys.odf.tree
Class ODFContentsTreeHelper
- java.lang.Object
-
- org.ametys.runtime.plugin.component.AbstractLogEnabled
-
- org.ametys.plugins.contentstree.ContentsTreeHelper
-
- org.ametys.odf.tree.ODFContentsTreeHelper
-
- All Implemented Interfaces:
LogEnabled
,Component
,Serviceable
public class ODFContentsTreeHelper extends ContentsTreeHelper
Helper ODF contents tree
-
-
Field Summary
Fields Modifier and Type Field Description protected ODFHelper
_odfHelper
The ODF helperprotected ShareableCourseHelper
_shareableCourseHelper
The shareable course helperprotected ShareableCourseStatusHelper
_shareableStatusHelper
The shareable course status helperprotected WorkflowProvider
_workflowProvider
The workflow providerstatic String
ROLE
The Avalon role-
Fields inherited from class org.ametys.plugins.contentstree.ContentsTreeHelper
_ametysResolver, _contentTypesEP, _contentTypesHelper, _treeExtensionPoint
-
-
Constructor Summary
Constructors Constructor Description ODFContentsTreeHelper()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected Map<String,Object>
content2Json(Content content)
Get the default JSON representation of a content of the treeMap<String,Object>
getRootNodeInformations(String contentId)
Get the root node informationsprotected String
getShareableStatus(Course course)
Get the shareable course status as Stringprotected Map<String,Object>
getWorkflowStep(Content content)
Get workflow step informationprotected boolean
isContentMatching(Content content, String value)
Determines if content matches the filter regexpprotected boolean
isShared(ProgramItem programItem)
Get the shared status of this program itemvoid
service(ServiceManager smanager)
-
Methods inherited from class org.ametys.plugins.contentstree.ContentsTreeHelper
_getParentContent, _getTreeConfiguration, childContent2Json, filterChildrenContentByRegExp, getChildrenContent, getChildrenContent, getNodeInformations, hasChildrenContent
-
Methods inherited from class org.ametys.runtime.plugin.component.AbstractLogEnabled
getLogger, setLogger
-
-
-
-
Field Detail
-
_odfHelper
protected ODFHelper _odfHelper
The ODF helper
-
_workflowProvider
protected WorkflowProvider _workflowProvider
The workflow provider
-
_shareableStatusHelper
protected ShareableCourseStatusHelper _shareableStatusHelper
The shareable course status helper
-
_shareableCourseHelper
protected ShareableCourseHelper _shareableCourseHelper
The shareable course helper
-
-
Constructor Detail
-
ODFContentsTreeHelper
public ODFContentsTreeHelper()
-
-
Method Detail
-
service
public void service(ServiceManager smanager) throws ServiceException
- Specified by:
service
in interfaceServiceable
- Overrides:
service
in classContentsTreeHelper
- Throws:
ServiceException
-
getRootNodeInformations
public Map<String,Object> getRootNodeInformations(String contentId)
Description copied from class:ContentsTreeHelper
Get the root node informations- Overrides:
getRootNodeInformations
in classContentsTreeHelper
- Parameters:
contentId
- The content- Returns:
- The informations
-
content2Json
protected Map<String,Object> content2Json(Content content)
Description copied from class:ContentsTreeHelper
Get the default JSON representation of a content of the tree- Overrides:
content2Json
in classContentsTreeHelper
- Parameters:
content
- the content- Returns:
- the content as JSON
-
isContentMatching
protected boolean isContentMatching(Content content, String value)
Description copied from class:ContentsTreeHelper
Determines if content matches the filter regexp- Overrides:
isContentMatching
in classContentsTreeHelper
- Parameters:
content
- the contentvalue
- the value to match- Returns:
- true if the content match
-
getWorkflowStep
protected Map<String,Object> getWorkflowStep(Content content)
Get workflow step information- Parameters:
content
- the content the content- Returns:
- the workflow step information
-
isShared
protected boolean isShared(ProgramItem programItem)
Get the shared status of this program item- Parameters:
programItem
- the program item- Returns:
- true if the program item belongs to more than one program item
-
getShareableStatus
protected String getShareableStatus(Course course)
Get the shareable course status as String- Parameters:
course
- the course- Returns:
- the shareable status
-
-