public class SetUGCRootClientSideElement extends AbstractPageClientSideElement
ClientSideElement.Script, ClientSideElement.ScriptFile
Modifier and Type | Field and Description |
---|---|
protected ContentTypeExtensionPoint |
_contentTypeEP
The extension point for content types
|
protected ObservationManager |
_observationManager
Observer manager.
|
protected UGCPageHandler |
_ugcPageHandler
The UGC page handler
|
_resolver, _synchronizeComponent
_currentUserProvider, _dependencies, _featureName, _id, _pluginName, _rightManager, _rights, _rightsMode, _script
Constructor and Description |
---|
SetUGCRootClientSideElement() |
Modifier and Type | Method and Description |
---|---|
private void |
_addUGCRootProperty(Page page,
String contentType,
String metadata) |
private boolean |
_isUGCRootPage(JCRAmetysObject jcrPage) |
private void |
_notifyPageUpdated(Page page) |
private void |
_removeUGCRootProperty(Page page) |
private void |
_updateUGCRootProperty(Page page,
String contentType,
String metadata) |
Map<String,Object> |
getRootPageInfo(String pageId)
Gets information about ugc root status on the given.
|
Map<String,Object> |
getStatus(String pageId)
Gets the status of the given page
|
Map<String,Object> |
removeUGCRoot(String pageId)
Remove the ugc root status to the given page
|
void |
service(ServiceManager smanager) |
Map<String,Object> |
setUGCRoot(String pageId,
String contentTypeId,
String metadataPath)
Sets the given page as the root of a ugc
|
getAllRightPageDescription, getNoModifiablePageDescription, getNoRightPageDescription, getPageDefaultParameters, hasRight
_configureClass, _configureParameters, _configureScript, configureInitialParameters
_configureDependencies, _configureImports, _configureRights, _configureRightsMode, configure, getDependencies, getId, getPluginName, getRights, getScripts, getScripts, hasRight, setPluginInfo, toString
getLogger, setLogger
protected ObservationManager _observationManager
protected ContentTypeExtensionPoint _contentTypeEP
protected UGCPageHandler _ugcPageHandler
public SetUGCRootClientSideElement()
public void service(ServiceManager smanager) throws ServiceException
service
in interface Serviceable
service
in class AbstractPageClientSideElement
ServiceException
public Map<String,Object> getStatus(String pageId)
pageId
- The page idpublic Map<String,Object> setUGCRoot(String pageId, String contentTypeId, String metadataPath) throws RepositoryException
pageId
- The id of the pagecontentTypeId
- The id of the content typemetadataPath
- The classification metadata pathRepositoryException
- if a repository error occuredpublic Map<String,Object> removeUGCRoot(String pageId) throws RepositoryException
pageId
- The id of the pageRepositoryException
- if a repository error occuredpublic Map<String,Object> getRootPageInfo(String pageId)
pageId
- The id of the pageprivate void _addUGCRootProperty(Page page, String contentType, String metadata) throws RepositoryException
RepositoryException
private void _updateUGCRootProperty(Page page, String contentType, String metadata)
private void _removeUGCRootProperty(Page page) throws RepositoryException
RepositoryException
private boolean _isUGCRootPage(JCRAmetysObject jcrPage)
private void _notifyPageUpdated(Page page)