public class ChannelHelper extends Object
Constructor and Description |
---|
ChannelHelper() |
ChannelHelper(ServiceRegistry serviceRegistry,
PublishingEventHelper eventHelper) |
Modifier and Type | Method and Description |
---|---|
void |
addPublishedAspect(org.alfresco.service.cmr.repository.NodeRef publishedNode,
org.alfresco.service.cmr.repository.NodeRef channelNode) |
Channel |
buildChannelObject(org.alfresco.service.cmr.repository.NodeRef nodeRef,
ChannelService channelService) |
boolean |
canPublish(org.alfresco.service.cmr.repository.NodeRef nodeToPublish,
ChannelType type) |
org.alfresco.service.cmr.repository.NodeRef |
createChannelNode(org.alfresco.service.cmr.repository.NodeRef parent,
ChannelType channelType,
String channelName,
Map<org.alfresco.service.namespace.QName,Serializable> props) |
org.alfresco.service.cmr.repository.AssociationRef |
createMapping(org.alfresco.service.cmr.repository.NodeRef source,
org.alfresco.service.cmr.repository.NodeRef publishedNode) |
List<Channel> |
filterAuthorisedChannels(Collection<Channel> channels) |
org.alfresco.util.Pair<org.alfresco.service.cmr.repository.NodeRef,String> |
findChannelAndType(org.alfresco.service.cmr.repository.NodeRef node)
Finds the
Channel NodeRef and ChannelType id for a given node, if such a Channel exists. |
List<Channel> |
getAllChannels(org.alfresco.service.cmr.repository.NodeRef channelContainer,
ChannelService channelService) |
Map<org.alfresco.service.namespace.QName,Serializable> |
getChannelProperties(org.alfresco.service.cmr.repository.NodeRef channel) |
List<Channel> |
getChannelsByType(org.alfresco.service.cmr.repository.NodeRef containerNode,
String channelTypeId,
ChannelService channelService,
boolean checkPermissions) |
List<Channel> |
getChannelsForTypes(org.alfresco.service.cmr.repository.NodeRef containerNode,
List<ChannelType> types,
ChannelService channelService,
boolean checkPermissions) |
List<ChannelType> |
getReleventChannelTypes(org.alfresco.service.cmr.repository.NodeRef nodeToPublish,
Collection<ChannelType> channelTypes) |
List<ChannelType> |
getStatusUpdateChannelTypes(Collection<ChannelType> channelTypes) |
boolean |
hasPublishPermissions(org.alfresco.service.cmr.repository.NodeRef channelNode) |
boolean |
isChannelAuthorised(org.alfresco.service.cmr.repository.NodeRef channelNode) |
org.alfresco.service.cmr.repository.NodeRef |
mapEnvironmentToSource(org.alfresco.service.cmr.repository.NodeRef publishedNode)
Given a published noderef, this returns the corresponding source noderef in the editorial space (doclib).
|
static org.alfresco.service.cmr.repository.NodeRef |
mapEnvironmentToSource(org.alfresco.service.cmr.repository.NodeRef publishedNode,
org.alfresco.service.cmr.repository.NodeService nodeService)
Given a published noderef, this returns the corresponding source noderef in the editorial space (doclib).
|
org.alfresco.service.cmr.repository.NodeRef |
mapSourceToEnvironment(org.alfresco.service.cmr.repository.NodeRef source,
org.alfresco.service.cmr.repository.NodeRef channelNode)
Given a noderef from the editorial space (e.g.
|
static org.alfresco.service.cmr.repository.NodeRef |
mapSourceToEnvironment(org.alfresco.service.cmr.repository.NodeRef source,
org.alfresco.service.cmr.repository.NodeRef channelNode,
org.alfresco.service.cmr.repository.NodeService nodeService)
Given a noderef from the editorial space (e.g.
|
void |
setDictionaryService(org.alfresco.service.cmr.dictionary.DictionaryService dictionaryService) |
void |
setEventHelper(PublishingEventHelper eventHelper) |
void |
setFileFolderService(FileFolderService fileFolderService) |
void |
setNodeService(org.alfresco.service.cmr.repository.NodeService nodeService) |
void |
setPermissionService(org.alfresco.service.cmr.security.PermissionService permissionService) |
void |
setServiceRegistry(ServiceRegistry serviceRegistry) |
public static final String NAME
public ChannelHelper()
public ChannelHelper(ServiceRegistry serviceRegistry, PublishingEventHelper eventHelper)
public org.alfresco.service.cmr.repository.NodeRef createChannelNode(org.alfresco.service.cmr.repository.NodeRef parent, ChannelType channelType, String channelName, Map<org.alfresco.service.namespace.QName,Serializable> props)
public Channel buildChannelObject(org.alfresco.service.cmr.repository.NodeRef nodeRef, ChannelService channelService)
public org.alfresco.service.cmr.repository.NodeRef mapSourceToEnvironment(org.alfresco.service.cmr.repository.NodeRef source, org.alfresco.service.cmr.repository.NodeRef channelNode)
source
- NodeRefchannelNode
- NodeRefpublic static org.alfresco.service.cmr.repository.NodeRef mapSourceToEnvironment(org.alfresco.service.cmr.repository.NodeRef source, org.alfresco.service.cmr.repository.NodeRef channelNode, org.alfresco.service.cmr.repository.NodeService nodeService)
source
- NodeRefchannelNode
- NodeRefnodeService
- NodeServicepublic org.alfresco.service.cmr.repository.NodeRef mapEnvironmentToSource(org.alfresco.service.cmr.repository.NodeRef publishedNode)
publishedNode
- NodeRefpublic static org.alfresco.service.cmr.repository.NodeRef mapEnvironmentToSource(org.alfresco.service.cmr.repository.NodeRef publishedNode, org.alfresco.service.cmr.repository.NodeService nodeService)
publishedNode
- NodeRefnodeService
- NodeServicepublic org.alfresco.util.Pair<org.alfresco.service.cmr.repository.NodeRef,String> findChannelAndType(org.alfresco.service.cmr.repository.NodeRef node)
Channel
NodeRef and ChannelType
id for a given node, if such a Channel exists.node
- NodeRefPair
containing the Channel NodeRef
and ChannelType Id.public Map<org.alfresco.service.namespace.QName,Serializable> getChannelProperties(org.alfresco.service.cmr.repository.NodeRef channel)
public org.alfresco.service.cmr.repository.AssociationRef createMapping(org.alfresco.service.cmr.repository.NodeRef source, org.alfresco.service.cmr.repository.NodeRef publishedNode)
public boolean canPublish(org.alfresco.service.cmr.repository.NodeRef nodeToPublish, ChannelType type)
public List<Channel> getAllChannels(org.alfresco.service.cmr.repository.NodeRef channelContainer, ChannelService channelService)
public List<Channel> getChannelsForTypes(org.alfresco.service.cmr.repository.NodeRef containerNode, List<ChannelType> types, ChannelService channelService, boolean checkPermissions)
public List<Channel> getChannelsByType(org.alfresco.service.cmr.repository.NodeRef containerNode, String channelTypeId, ChannelService channelService, boolean checkPermissions)
public List<Channel> filterAuthorisedChannels(Collection<Channel> channels)
public List<ChannelType> getReleventChannelTypes(org.alfresco.service.cmr.repository.NodeRef nodeToPublish, Collection<ChannelType> channelTypes)
public List<ChannelType> getStatusUpdateChannelTypes(Collection<ChannelType> channelTypes)
public void addPublishedAspect(org.alfresco.service.cmr.repository.NodeRef publishedNode, org.alfresco.service.cmr.repository.NodeRef channelNode)
public boolean hasPublishPermissions(org.alfresco.service.cmr.repository.NodeRef channelNode)
public boolean isChannelAuthorised(org.alfresco.service.cmr.repository.NodeRef channelNode)
public void setNodeService(org.alfresco.service.cmr.repository.NodeService nodeService)
nodeService
- the nodeService to setpublic void setDictionaryService(org.alfresco.service.cmr.dictionary.DictionaryService dictionaryService)
dictionaryService
- the dictionaryService to setpublic void setFileFolderService(FileFolderService fileFolderService)
fileFolderService
- the fileFolderService to setpublic void setPermissionService(org.alfresco.service.cmr.security.PermissionService permissionService)
permissionService
- the permissionService to setpublic void setServiceRegistry(ServiceRegistry serviceRegistry)
public void setEventHelper(PublishingEventHelper eventHelper)
Copyright © 2005–2017 Alfresco Software. All rights reserved.