Class FilePlanServiceImpl
- java.lang.Object
-
- org.alfresco.module.org_alfresco_module_rm.util.ServiceBaseImpl
-
- org.alfresco.module.org_alfresco_module_rm.fileplan.FilePlanServiceImpl
-
- All Implemented Interfaces:
FilePlanService
,RecordsManagementCustomModel
,RecordsManagementModel
,org.springframework.beans.factory.Aware
,org.springframework.context.ApplicationContextAware
public class FilePlanServiceImpl extends ServiceBaseImpl implements FilePlanService, RecordsManagementModel
File plan service implementation.- Since:
- 2.1
- Author:
- Roy Wetherall
-
-
Field Summary
-
Fields inherited from class org.alfresco.module.org_alfresco_module_rm.util.ServiceBaseImpl
applicationContext, authenticationUtil, contentService, dictionaryService, nodeService, nodeTypeUtility, renditionService, transactionalResourceHelper
-
Fields inherited from interface org.alfresco.module.org_alfresco_module_rm.fileplan.FilePlanService
DEFAULT_RM_SITE_ID
-
Fields inherited from interface org.alfresco.module.org_alfresco_module_rm.model.RecordsManagementCustomModel
ASPECT_CUSTOM_ASSOCIATIONS, ASPECT_SUPPLEMENTAL_MARKING_LIST, CONSTRAINT_CUSTOM_SMLIST, CUSTOM_REF_CROSSREFERENCE, CUSTOM_REF_OBSOLETES, CUSTOM_REF_RENDITION, CUSTOM_REF_SUPERSEDES, CUSTOM_REF_SUPPORTS, CUSTOM_REF_VERSIONS, PROP_SUPPLEMENTAL_MARKING_LIST, RM_CUSTOM_MODEL, RM_CUSTOM_PREFIX, RM_CUSTOM_URI
-
Fields inherited from interface org.alfresco.module.org_alfresco_module_rm.model.RecordsManagementModel
ASPECT_ARCHIVED, ASPECT_ASCENDED, ASPECT_CAVEAT_CONFIG_ROOT, ASPECT_COMMON_RECORD_DETAILS, ASPECT_COUNTABLE, ASPECT_CUSTOM_RM_DATA, ASPECT_CUT_OFF, ASPECT_DECLARED_RECORD, ASPECT_DISPOSITION_LIFECYCLE, ASPECT_DISPOSITION_PROCESSED, ASPECT_EMAIL_CONFIG_ROOT, ASPECT_EXTENDED_SECURITY, ASPECT_FILABLE, ASPECT_FILE_PLAN_COMPONENT, ASPECT_FROZEN, ASPECT_GHOSTED, ASPECT_HELD_CHILDREN, ASPECT_LOADED_DATA_SET_ID, ASPECT_RECORD, ASPECT_RECORD_COMPONENT_ID, ASPECT_RECORD_META_DATA, ASPECT_RECORD_ORIGINATING_DETAILS, ASPECT_RECORD_REJECTION_DETAILS, ASPECT_RECORDS_MANAGEMENT_ROOT, ASPECT_RM_SEARCH, ASPECT_SAVED_SEARCH, ASPECT_SCHEDULED, ASPECT_TRANSFERRED, ASPECT_TRANSFERRING, ASPECT_UNCUT_OFF, ASPECT_UNPUBLISHED_UPDATE, ASPECT_VERSIONED_RECORD, ASPECT_VITAL_RECORD, ASPECT_VITAL_RECORD_DEFINITION, ASSOC_CAVEAT_CONFIG, ASSOC_DISPOSITION_ACTION_DEFINITIONS, ASSOC_DISPOSITION_ACTION_HISTORY, ASSOC_DISPOSITION_SCHEDULE, ASSOC_EMAIL_CONFIG, ASSOC_EVENT_EXECUTIONS, ASSOC_FROZEN_CONTENT, ASSOC_FROZEN_RECORDS, ASSOC_HOLDS, ASSOC_NEXT_DISPOSITION_ACTION, ASSOC_TRANSFERRED, ASSOC_TRANSFERS, GL_URI, PROP_COMBINE_DISPOSITION_STEP_CONDITIONS, PROP_COUNT, PROP_CUT_OFF_DATE, PROP_DATE_FILED, PROP_DB_UNIQUENESS_ID, PROP_DECLARED_AT, PROP_DECLARED_BY, PROP_DISPOSITION_ACTION, PROP_DISPOSITION_ACTION_COMPLETED_AT, PROP_DISPOSITION_ACTION_COMPLETED_BY, PROP_DISPOSITION_ACTION_GHOST_ON_DESTROY, PROP_DISPOSITION_ACTION_ID, PROP_DISPOSITION_ACTION_NAME, PROP_DISPOSITION_ACTION_STARTED_AT, PROP_DISPOSITION_ACTION_STARTED_BY, PROP_DISPOSITION_AS_OF, PROP_DISPOSITION_AUTHORITY, PROP_DISPOSITION_DESCRIPTION, PROP_DISPOSITION_EVENT, PROP_DISPOSITION_EVENT_COMBINATION, PROP_DISPOSITION_EVENTS_ELIGIBLE, PROP_DISPOSITION_INSTRUCTIONS, PROP_DISPOSITION_LOCATION, PROP_DISPOSITION_PERIOD, PROP_DISPOSITION_PERIOD_PROPERTY, PROP_EVENT_EXECUTION_AUTOMATIC, PROP_EVENT_EXECUTION_COMPLETE, PROP_EVENT_EXECUTION_COMPLETED_AT, PROP_EVENT_EXECUTION_COMPLETED_BY, PROP_EVENT_EXECUTION_NAME, PROP_FROZEN_AT, PROP_FROZEN_BY, PROP_HELD_CHILDREN_COUNT, PROP_HOLD_REASON, PROP_IDENTIFIER, PROP_IS_CLOSED, PROP_LOADED_DATA_SET_IDS, PROP_LOCATION, PROP_MANUALLY_SET_AS_OF, PROP_ORIGIONAL_NAME, PROP_PUBLISH_IN_PROGRESS, PROP_READERS, PROP_RECORD_LEVEL_DISPOSITION, PROP_RECORD_ORIGINATING_CREATION_DATE, PROP_RECORD_ORIGINATING_LOCATION, PROP_RECORD_ORIGINATING_USER_ID, PROP_RECORD_REJECTION_DATE, PROP_RECORD_REJECTION_REASON, PROP_RECORD_REJECTION_USER_ID, PROP_REVIEW_AS_OF, PROP_REVIEW_PERIOD, PROP_ROOT_NODEREF, PROP_RS_DECLASSIFICATION_REVIEW_COMPLETED_AT, PROP_RS_DECLASSIFICATION_REVIEW_COMPLETED_BY, PROP_RS_DISPOITION_AUTHORITY, PROP_RS_DISPOITION_INSTRUCTIONS, PROP_RS_DISPOSITION_ACTION_AS_OF, PROP_RS_DISPOSITION_ACTION_NAME, PROP_RS_DISPOSITION_EVENTS, PROP_RS_DISPOSITION_EVENTS_ELIGIBLE, PROP_RS_DISPOSITION_PERIOD, PROP_RS_DISPOSITION_PERIOD_EXPRESSION, PROP_RS_HAS_DISPOITION_SCHEDULE, PROP_RS_HOLD_REASON, PROP_RS_VITAL_RECORD_REVIEW_PERIOD, PROP_RS_VITAL_RECORD_REVIEW_PERIOD_EXPRESSION, PROP_TRANSFER_ACCESSION_INDICATOR, PROP_TRANSFER_LOCATION, PROP_TRANSFER_PDF_INDICATOR, PROP_UNPUBLISHED_UPDATE, PROP_UPDATE_TO, PROP_UPDATED_PROPERTIES, PROP_VITAL_RECORD_INDICATOR, PROP_WRITERS, RM_MODEL, RM_PREFIX, RM_URI, TYPE_CAVEAT_CONFIG, TYPE_DISPOSITION_ACTION, TYPE_DISPOSITION_ACTION_DEFINITION, TYPE_DISPOSITION_SCHEDULE, TYPE_EMAIL_CONFIG, TYPE_EVENT_EXECUTION, TYPE_FILE_PLAN, TYPE_HOLD, TYPE_HOLD_CONTAINER, TYPE_NON_ELECTRONIC_DOCUMENT, TYPE_RECORD_CATEGORY, TYPE_RECORD_FOLDER, TYPE_RECORDS_MANAGEMENT_CONTAINER, TYPE_RM_SITE, TYPE_TRANSFER, TYPE_TRANSFER_CONTAINER, TYPE_UNFILED_RECORD_CONTAINER, TYPE_UNFILED_RECORD_FOLDER, UPDATE_TO_DISPOSITION_ACTION_DEFINITION
-
-
Constructor Summary
Constructors Constructor Description FilePlanServiceImpl()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description NodeRef
createFilePlan(NodeRef parent, String name)
Creates a file plan with the default type.NodeRef
createFilePlan(NodeRef parent, String name, Map<QName,Serializable> properties)
Creates a file plan with the default type, specifying properties.NodeRef
createFilePlan(NodeRef parent, String name, QName type)
Creates a file plan as a child of the given parent node, with the name provided.NodeRef
createFilePlan(NodeRef parent, String name, QName type, Map<QName,Serializable> properties)
Specifies the properties to be set on the created file plan.NodeRef
createHoldContainer(NodeRef filePlan)
NodeRef
createRecordCategory(NodeRef parent, String name)
Creates a record category of type rma:recordCategoryNodeRef
createRecordCategory(NodeRef parent, String name, Map<QName,Serializable> properties)
NodeRef
createRecordCategory(NodeRef parent, String name, QName type)
Create a record category.NodeRef
createRecordCategory(NodeRef parent, String name, QName type, Map<QName,Serializable> properties)
NodeRef
createTransferContainer(NodeRef filePlan)
NodeRef
createUnfiledContainer(NodeRef filePlan)
Creates, and returns, a unfiled container for a given file plan.boolean
existsUnfiledContainer(NodeRef filePlan)
Indicates whether the unfiled container exists for a given file plan or not.List<NodeRef>
getAllContained(NodeRef container)
Only return the immediate children.List<NodeRef>
getAllContained(NodeRef container, boolean deep)
Get all the items contained within a container.List<NodeRef>
getContainedRecordCategories(NodeRef container)
Only return immediate children.List<NodeRef>
getContainedRecordCategories(NodeRef container, boolean deep)
Get all the record categories within a record category.List<NodeRef>
getContainedRecordFolders(NodeRef container)
Only return immediate children.List<NodeRef>
getContainedRecordFolders(NodeRef container, boolean deep)
Get all the record folders contained within a containerNodeRef
getFilePlanBySiteId(String siteId)
Gets a file plan by site id.FilePlanRoleService
getFilePlanRoleService()
Gets the file plan role serviceSet<NodeRef>
getFilePlans()
Gets all the file plan nodes.Set<NodeRef>
getFilePlans(StoreRef storeRef)
Getse all the file plan nodes in a store.NodeRef
getHoldContainer(NodeRef filePlan)
Gets the hold container for a given file plan.NodeDAO
getNodeDAO()
Gets the node DAOList<NodeRef>
getNodeRefPath(NodeRef nodeRef)
Gets the NodeRef sequence from theroot
down to the fileplan component given.PermissionService
getPermissionService()
Gets the permission serviceSiteService
getSiteService()
Gets the site serviceNodeRef
getTransferContainer(NodeRef filePlan)
NodeRef
getUnfiledContainer(NodeRef filePlan)
Gets the unfiled container for a given file plan.void
setRmContainerCacheManager(RMContainerCacheManager rmContainerCacheManager)
void
setRootContainerCache(SimpleCache<Pair<NodeRef,String>,NodeRef> rootContainerCache)
-
Methods inherited from class org.alfresco.module.org_alfresco_module_rm.util.ServiceBaseImpl
getFilePlan, getFilePlanComponentKind, getFilePlanComponentKindFromType, getInternalNodeService, getNextCount, getTypeAndApsects, instanceOf, instanceOf, isDeclared, isFilePlan, isFilePlanComponent, isFilePlanContainer, isHold, isRecord, isRecordCategory, isRecordFolder, isTransfer, isUnfiledRecordsContainer, setApplicationContext, setAuthenticationUtil, setContentService, setDictionaryService, setNodeService, setNodeTypeUtility, setRenditionService, setTransactionalResourceHelper
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.alfresco.module.org_alfresco_module_rm.fileplan.FilePlanService
getFilePlan, getFilePlanComponentKind, getFilePlanComponentKindFromType, isFilePlan, isFilePlanComponent, isFilePlanContainer, isRecordCategory
-
-
-
-
Method Detail
-
getFilePlanRoleService
public FilePlanRoleService getFilePlanRoleService()
Gets the file plan role service- Returns:
- The file plan role service
-
getPermissionService
public PermissionService getPermissionService()
Gets the permission service- Returns:
- The permission service
-
getNodeDAO
public NodeDAO getNodeDAO()
Gets the node DAO- Returns:
- The node DAO
-
getSiteService
public SiteService getSiteService()
Gets the site service- Returns:
- The site service
-
getFilePlans
public Set<NodeRef> getFilePlans()
Description copied from interface:FilePlanService
Gets all the file plan nodes. Looks in the SpacesStore by default.- Specified by:
getFilePlans
in interfaceFilePlanService
- Returns:
- Set
set of file plan nodes - See Also:
FilePlanService.getFilePlans()
-
setRootContainerCache
public void setRootContainerCache(SimpleCache<Pair<NodeRef,String>,NodeRef> rootContainerCache)
- Parameters:
rootContainerCache
- root container cache
-
setRmContainerCacheManager
public void setRmContainerCacheManager(RMContainerCacheManager rmContainerCacheManager)
- Parameters:
rmContainerCacheManager
- RM container cache manager
-
getFilePlans
public Set<NodeRef> getFilePlans(StoreRef storeRef)
Description copied from interface:FilePlanService
Getse all the file plan nodes in a store.- Specified by:
getFilePlans
in interfaceFilePlanService
- Parameters:
storeRef
- store reference- Returns:
- Set
set of file plan nodes - See Also:
FilePlanService.getFilePlans(org.alfresco.service.cmr.repository.StoreRef)
-
getFilePlanBySiteId
public NodeRef getFilePlanBySiteId(String siteId)
Description copied from interface:FilePlanService
Gets a file plan by site id. Assumes the site is a RM site and that the file plan node, ie the document library container, has been already created. Otherwise returns null.- Specified by:
getFilePlanBySiteId
in interfaceFilePlanService
- Parameters:
siteId
- records management site id- Returns:
- NodeRef file plan, null if can't be found
- See Also:
FilePlanService.getFilePlanBySiteId(java.lang.String)
-
existsUnfiledContainer
public boolean existsUnfiledContainer(NodeRef filePlan)
Description copied from interface:FilePlanService
Indicates whether the unfiled container exists for a given file plan or not.- Specified by:
existsUnfiledContainer
in interfaceFilePlanService
- Parameters:
filePlan
- file plan- Returns:
- boolean true if unfiled container exists, false otherwise
- See Also:
FilePlanService.existsUnfiledContainer(org.alfresco.service.cmr.repository.NodeRef)
-
getUnfiledContainer
public NodeRef getUnfiledContainer(NodeRef filePlan)
Description copied from interface:FilePlanService
Gets the unfiled container for a given file plan. Returns null if none.- Specified by:
getUnfiledContainer
in interfaceFilePlanService
- Parameters:
filePlan
- file plan- Returns:
NodeRef
unfiled container, null if none- See Also:
FilePlanService.getUnfiledContainer(org.alfresco.service.cmr.repository.NodeRef)
-
getHoldContainer
public NodeRef getHoldContainer(NodeRef filePlan)
Description copied from interface:FilePlanService
Gets the hold container for a given file plan. Returns null if none.- Specified by:
getHoldContainer
in interfaceFilePlanService
- Returns:
- See Also:
FilePlanService.getHoldContainer(org.alfresco.service.cmr.repository.NodeRef)
-
getTransferContainer
public NodeRef getTransferContainer(NodeRef filePlan)
- Specified by:
getTransferContainer
in interfaceFilePlanService
- Returns:
- See Also:
FilePlanService.getTransferContainer(org.alfresco.service.cmr.repository.NodeRef)
-
createUnfiledContainer
public NodeRef createUnfiledContainer(NodeRef filePlan)
Description copied from interface:FilePlanService
Creates, and returns, a unfiled container for a given file plan.- Specified by:
createUnfiledContainer
in interfaceFilePlanService
- Parameters:
filePlan
- file plan- Returns:
NodeRef
unfiled container- See Also:
FilePlanService.createUnfiledContainer(org.alfresco.service.cmr.repository.NodeRef)
-
createHoldContainer
public NodeRef createHoldContainer(NodeRef filePlan)
- Specified by:
createHoldContainer
in interfaceFilePlanService
- Returns:
- See Also:
FilePlanService.createHoldContainer(org.alfresco.service.cmr.repository.NodeRef)
-
createTransferContainer
public NodeRef createTransferContainer(NodeRef filePlan)
- Specified by:
createTransferContainer
in interfaceFilePlanService
- Returns:
- See Also:
FilePlanService.createTransferContainer(org.alfresco.service.cmr.repository.NodeRef)
-
createFilePlan
public NodeRef createFilePlan(NodeRef parent, String name, QName type, Map<QName,Serializable> properties)
Description copied from interface:FilePlanService
Specifies the properties to be set on the created file plan.- Specified by:
createFilePlan
in interfaceFilePlanService
- Parameters:
parent
- parent node referencename
- file plan nametype
- type, must be rma:filePlan or sub-type ofproperties
- file plan properties- Returns:
- NodeRef file plan node reference
- See Also:
FilePlanService.createFilePlan(org.alfresco.service.cmr.repository.NodeRef, java.lang.String, org.alfresco.service.namespace.QName, java.util.Map)
-
createFilePlan
public NodeRef createFilePlan(NodeRef parent, String name, Map<QName,Serializable> properties)
Description copied from interface:FilePlanService
Creates a file plan with the default type, specifying properties.- Specified by:
createFilePlan
in interfaceFilePlanService
- Parameters:
parent
- parent node referencename
- file plan nameproperties
- file plan properties- Returns:
- NodeRef file plan node reference
- See Also:
FilePlanService.createFilePlan(org.alfresco.service.cmr.repository.NodeRef, java.lang.String, java.util.Map)
-
createFilePlan
public NodeRef createFilePlan(NodeRef parent, String name)
Description copied from interface:FilePlanService
Creates a file plan with the default type.- Specified by:
createFilePlan
in interfaceFilePlanService
- Parameters:
parent
- parent node referencename
- file plan name- Returns:
- NodeRef file plan node reference
- See Also:
FilePlanService.createFilePlan(org.alfresco.service.cmr.repository.NodeRef, java.lang.String)
-
createFilePlan
public NodeRef createFilePlan(NodeRef parent, String name, QName type)
Description copied from interface:FilePlanService
Creates a file plan as a child of the given parent node, with the name provided.- Specified by:
createFilePlan
in interfaceFilePlanService
- Parameters:
parent
- parent node referencename
- file plan nametype
- type, must be rma:filePlan or sub-type of- Returns:
- NodeRef file plan node reference
- See Also:
FilePlanService.createFilePlan(org.alfresco.service.cmr.repository.NodeRef, java.lang.String, org.alfresco.service.namespace.QName)
-
getNodeRefPath
public List<NodeRef> getNodeRefPath(NodeRef nodeRef)
Description copied from interface:FilePlanService
Gets the NodeRef sequence from theroot
down to the fileplan component given. The array will start with the NodeRef of the root and end with the name of the fileplan component node given.- Specified by:
getNodeRefPath
in interfaceFilePlanService
- Parameters:
nodeRef
- a fileplan component- Returns:
- Returns a NodeRef path starting with the file plan
- See Also:
FilePlanService.getNodeRefPath(org.alfresco.service.cmr.repository.NodeRef)
-
createRecordCategory
public NodeRef createRecordCategory(NodeRef parent, String name, QName type, Map<QName,Serializable> properties)
- Specified by:
createRecordCategory
in interfaceFilePlanService
- Returns:
- See Also:
FilePlanService.createRecordCategory(org.alfresco.service.cmr.repository.NodeRef, java.lang.String, org.alfresco.service.namespace.QName, java.util.Map)
-
createRecordCategory
public NodeRef createRecordCategory(NodeRef parent, String name)
Description copied from interface:FilePlanService
Creates a record category of type rma:recordCategory- Specified by:
createRecordCategory
in interfaceFilePlanService
- Parameters:
parent
- parent node reference, must be a record category or file plan.name
- name of the record category- Returns:
- NodeRef node reference of the created record category
- See Also:
FilePlanService.createRecordCategory(org.alfresco.service.cmr.repository.NodeRef, java.lang.String)
-
createRecordCategory
public NodeRef createRecordCategory(NodeRef parent, String name, Map<QName,Serializable> properties)
- Specified by:
createRecordCategory
in interfaceFilePlanService
- Returns:
- See Also:
FilePlanService.createRecordCategory(org.alfresco.service.cmr.repository.NodeRef, java.lang.String, java.util.Map)
-
createRecordCategory
public NodeRef createRecordCategory(NodeRef parent, String name, QName type)
Description copied from interface:FilePlanService
Create a record category.- Specified by:
createRecordCategory
in interfaceFilePlanService
- Parameters:
parent
- parent node reference, must be a record category or file plan.name
- name of the new record categorytype
- type of container to create, must be a sub-type of rm:recordCategory- Returns:
- NodeRef node reference of the created record category
- See Also:
FilePlanService.createRecordCategory(org.alfresco.service.cmr.repository.NodeRef, java.lang.String, org.alfresco.service.namespace.QName)
-
getAllContained
public List<NodeRef> getAllContained(NodeRef container)
Description copied from interface:FilePlanService
Only return the immediate children.- Specified by:
getAllContained
in interfaceFilePlanService
- Parameters:
container
- record category node reference- Returns:
List
<NodeRef
> list of contained node references- See Also:
FilePlanService.getAllContained(org.alfresco.service.cmr.repository.NodeRef)
-
getAllContained
public List<NodeRef> getAllContained(NodeRef container, boolean deep)
Description copied from interface:FilePlanService
Get all the items contained within a container. This will include record folders and other record categories.- Specified by:
getAllContained
in interfaceFilePlanService
- Parameters:
container
- record category node referencedeep
- if true then return all children including sub-categories and their children in turn, if false then just return the immediate children- Returns:
List
<NodeRef
> list of contained node references- See Also:
FilePlanService.getAllContained(org.alfresco.service.cmr.repository.NodeRef, boolean)
-
getContainedRecordCategories
public List<NodeRef> getContainedRecordCategories(NodeRef container)
Description copied from interface:FilePlanService
Only return immediate children.- Specified by:
getContainedRecordCategories
in interfaceFilePlanService
- Parameters:
container
- container node reference- Returns:
List
<NodeRef
> list of container node references- See Also:
FilePlanService.getContainedRecordCategories(org.alfresco.service.cmr.repository.NodeRef)
-
getContainedRecordCategories
public List<NodeRef> getContainedRecordCategories(NodeRef container, boolean deep)
Description copied from interface:FilePlanService
Get all the record categories within a record category.- Specified by:
getContainedRecordCategories
in interfaceFilePlanService
- Parameters:
container
- record category node referencedeep
- if true then return all children including sub-categories and their children in turn, if false then just return the immediate children- Returns:
List
<NodeRef
> list of container node references- See Also:
FilePlanService.getContainedRecordCategories(org.alfresco.service.cmr.repository.NodeRef, boolean)
-
getContainedRecordFolders
public List<NodeRef> getContainedRecordFolders(NodeRef container)
Description copied from interface:FilePlanService
Only return immediate children.- Specified by:
getContainedRecordFolders
in interfaceFilePlanService
- Parameters:
container
- container node reference- Returns:
List
<NodeRef
> list of record folder node references- See Also:
FilePlanService.getContainedRecordFolders(org.alfresco.service.cmr.repository.NodeRef)
-
getContainedRecordFolders
public List<NodeRef> getContainedRecordFolders(NodeRef container, boolean deep)
Description copied from interface:FilePlanService
Get all the record folders contained within a container- Specified by:
getContainedRecordFolders
in interfaceFilePlanService
- Parameters:
container
- container node referencedeep
- if true then return all children including sub-containers and their children in turn, if false then just return the immediate children- Returns:
List
<NodeRef
> list of record folder node references- See Also:
FilePlanService.getContainedRecordFolders(org.alfresco.service.cmr.repository.NodeRef, boolean)
-
-