Package org.alfresco.repo.links
Class LinksServiceImpl
- java.lang.Object
-
- org.alfresco.repo.links.LinksServiceImpl
-
- All Implemented Interfaces:
LinksService
public class LinksServiceImpl extends java.lang.Object implements LinksService
- Since:
- 4.0
- Author:
- Nick Burch (based on existing webscript controllers in the REST API)
-
-
Field Summary
Fields Modifier and Type Field Description protected static java.lang.StringCANNED_QUERY_GET_CHILDRENstatic java.lang.StringLINKS_COMPONENT
-
Constructor Summary
Constructors Constructor Description LinksServiceImpl()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description LinkInfocreateLink(java.lang.String siteShortName, java.lang.String title, java.lang.String description, java.lang.String url, boolean internal)Creates a newLinkInfoin the given site, with the specified settingsvoiddeleteLink(LinkInfo link)Deletes an existingLinkInfofrom the repositoryorg.alfresco.query.PagingResults<LinkInfo>findLinks(java.lang.String siteShortName, java.lang.String user, java.util.Date from, java.util.Date to, java.lang.String tag, org.alfresco.query.PagingRequest paging)Finds allLinkInfoinstances indexed in the repository for the given site, created by the specified user in the specified date range, with the given tagLinkInfogetLink(java.lang.String siteShortName, java.lang.String linkName)Retrieves an existingLinkInfofrom the repositoryprotected org.alfresco.service.cmr.repository.NodeRefgetSiteLinksContainer(java.lang.String siteShortName, boolean create)Fetches the Links Container on a site, creating as required if requested.org.alfresco.query.PagingResults<LinkInfo>listLinks(java.lang.String siteShortName, java.lang.String user, org.alfresco.query.PagingRequest paging)Retrieves allLinkInfoinstances in the repository for the given site and the specified user.org.alfresco.query.PagingResults<LinkInfo>listLinks(java.lang.String siteShortName, java.util.Date from, java.util.Date to, org.alfresco.query.PagingRequest paging)Retrieves allLinkInfoinstances in the repository for the given site, created in the specified date rangeorg.alfresco.query.PagingResults<LinkInfo>listLinks(java.lang.String siteShortName, org.alfresco.query.PagingRequest paging)Retrieves allLinkInfoinstances in the repository for the given site.voidsetCannedQueryRegistry(org.alfresco.util.registry.NamedObjectRegistry<org.alfresco.query.CannedQueryFactory<? extends java.lang.Object>> cannedQueryRegistry)Set the registry ofcanned queriesvoidsetContentService(ContentService contentService)voidsetDictionaryService(org.alfresco.service.cmr.dictionary.DictionaryService dictionaryService)voidsetNamespaceService(org.alfresco.service.namespace.NamespaceService namespaceService)voidsetNodeDAO(NodeDAO nodeDAO)voidsetNodeService(org.alfresco.service.cmr.repository.NodeService nodeService)voidsetSearchService(org.alfresco.service.cmr.search.SearchService searchService)voidsetSiteService(SiteService siteService)voidsetTaggingService(TaggingService taggingService)voidsetTransactionService(TransactionService transactionService)LinkInfoupdateLink(LinkInfo link)Updates an existingLinkInfoin the repository.
-
-
-
Field Detail
-
LINKS_COMPONENT
public static final java.lang.String LINKS_COMPONENT
- See Also:
- Constant Field Values
-
CANNED_QUERY_GET_CHILDREN
protected static final java.lang.String CANNED_QUERY_GET_CHILDREN
- See Also:
- Constant Field Values
-
-
Method Detail
-
setNodeDAO
public void setNodeDAO(NodeDAO nodeDAO)
-
setNodeService
public void setNodeService(org.alfresco.service.cmr.repository.NodeService nodeService)
-
setSiteService
public void setSiteService(SiteService siteService)
-
setSearchService
public void setSearchService(org.alfresco.service.cmr.search.SearchService searchService)
-
setContentService
public void setContentService(ContentService contentService)
-
setTaggingService
public void setTaggingService(TaggingService taggingService)
-
setNamespaceService
public void setNamespaceService(org.alfresco.service.namespace.NamespaceService namespaceService)
-
setDictionaryService
public void setDictionaryService(org.alfresco.service.cmr.dictionary.DictionaryService dictionaryService)
-
setTransactionService
public void setTransactionService(TransactionService transactionService)
-
setCannedQueryRegistry
public void setCannedQueryRegistry(org.alfresco.util.registry.NamedObjectRegistry<org.alfresco.query.CannedQueryFactory<? extends java.lang.Object>> cannedQueryRegistry)
Set the registry ofcanned queries
-
getSiteLinksContainer
protected org.alfresco.service.cmr.repository.NodeRef getSiteLinksContainer(java.lang.String siteShortName, boolean create)Fetches the Links Container on a site, creating as required if requested.
-
getLink
public LinkInfo getLink(java.lang.String siteShortName, java.lang.String linkName)
Description copied from interface:LinksServiceRetrieves an existingLinkInfofrom the repository- Specified by:
getLinkin interfaceLinksService
-
createLink
public LinkInfo createLink(java.lang.String siteShortName, java.lang.String title, java.lang.String description, java.lang.String url, boolean internal)
Description copied from interface:LinksServiceCreates a newLinkInfoin the given site, with the specified settings- Specified by:
createLinkin interfaceLinksService- Returns:
- The newly created
LinkInfo
-
updateLink
public LinkInfo updateLink(LinkInfo link)
Description copied from interface:LinksServiceUpdates an existingLinkInfoin the repository.- Specified by:
updateLinkin interfaceLinksService- Returns:
- The updated
LinkInfo
-
deleteLink
public void deleteLink(LinkInfo link)
Description copied from interface:LinksServiceDeletes an existingLinkInfofrom the repository- Specified by:
deleteLinkin interfaceLinksService
-
listLinks
public org.alfresco.query.PagingResults<LinkInfo> listLinks(java.lang.String siteShortName, org.alfresco.query.PagingRequest paging)
Description copied from interface:LinksServiceRetrieves allLinkInfoinstances in the repository for the given site.- Specified by:
listLinksin interfaceLinksService
-
listLinks
public org.alfresco.query.PagingResults<LinkInfo> listLinks(java.lang.String siteShortName, java.lang.String user, org.alfresco.query.PagingRequest paging)
Description copied from interface:LinksServiceRetrieves allLinkInfoinstances in the repository for the given site and the specified user.- Specified by:
listLinksin interfaceLinksService
-
listLinks
public org.alfresco.query.PagingResults<LinkInfo> listLinks(java.lang.String siteShortName, java.util.Date from, java.util.Date to, org.alfresco.query.PagingRequest paging)
Description copied from interface:LinksServiceRetrieves allLinkInfoinstances in the repository for the given site, created in the specified date range- Specified by:
listLinksin interfaceLinksService
-
findLinks
public org.alfresco.query.PagingResults<LinkInfo> findLinks(java.lang.String siteShortName, java.lang.String user, java.util.Date from, java.util.Date to, java.lang.String tag, org.alfresco.query.PagingRequest paging)
Description copied from interface:LinksServiceFinds allLinkInfoinstances indexed in the repository for the given site, created by the specified user in the specified date range, with the given tag- Specified by:
findLinksin interfaceLinksService
-
-