RM-2812 Update following review comments.

The class dependency used to determine the classes to include based on the initial services is:

Depth 0: Service interfaces.

Depth 1:
ClearanceLevel <- SecurityClearanceService
RecordsManagementActionCondition <- RecordsManagementActionService
ClassificationAspectProperties <- ContentClassificationService
Version <- RecordableVersionConfigService, RecordableVersionService
Role <- FilePlanRoleService
CaveatGroupType <- CaveatSchemeService
RecordsManagementEvent <- RecordsManagementEventService
Group <- CapabilityService
RelationshipDisplayName <- RelationshipService
RecordsManagementActionResult <- RecordsManagementActionService
RecordsManagementAction <- RecordsManagementActionService
Relationship <- RelationshipService
ProtectedModelArtifact <- ModelSecurityService
ReportGenerator <- ReportService
RecordsManagementSearchParameters <- RecordsManagementSearchService
SecurityClearance <- SecurityClearanceService
SortDirection <- CaveatSchemeService
RecordsManagementEventType <- RecordsManagementEventService
Report <- ReportService
UserQueryParams <- SecurityClearanceService
CaveatMarkSortField <- CaveatSchemeService
ProtectedProperty <- ModelSecurityService
RelationshipDefinition <- RelationshipService
Capability <- FilePlanRoleService, CapabilityService
ExemptionCategory <- ClassificationSchemeService
CaveatGroup <- CaveatMarkingService, CaveatSchemeService
ClassificationReason <- ClassificationSchemeService
ProtectedAspect <- ModelSecurityService
MetadataReferral <- ReferralAdminService, ReferredMetadataService
CaveatMark <- CaveatClearanceService, CaveatMarkingService, ContentClassificationService, CaveatSchemeService, ClassificationSchemeService
SavedSearchDetails <- RecordsManagementSearchService
IdentifierGenerator <- IdentifierService

Depth 2:
RecordsManagementActionConditionDefinition <- RecordsManagementActionCondition
ReferralRegistry <- MetadataReferral
ClassificationSchemeEntity <- ExemptionCategory, ClassificationReason
RecordsManagementActionDefinition <- RecordsManagementAction
ReportDetails <- SavedSearchDetails
SortItem <- RecordsManagementSearchParameters
SavedSearchDetailsCompatibility <- SavedSearchDetails

Depth 3:
RecordsManagementModel <- SavedSearchDetailsCompatibility

Depth 4:
RecordsManagementCustomModel <- RecordsManagementModel
This commit is contained in:
Tom Page
2016-04-20 13:46:37 +01:00
parent fca0030c50
commit ebd8e09f88
16 changed files with 45 additions and 68 deletions

View File

@@ -33,11 +33,9 @@ import java.util.List;
import java.util.Map; import java.util.Map;
import java.util.Set; import java.util.Set;
import org.alfresco.api.AlfrescoPublicApi;
import org.alfresco.error.AlfrescoRuntimeException; import org.alfresco.error.AlfrescoRuntimeException;
import org.alfresco.service.cmr.repository.NodeRef; import org.alfresco.service.cmr.repository.NodeRef;
@AlfrescoPublicApi
public interface RMCaveatConfigService public interface RMCaveatConfigService
{ {
void init(); void init();

View File

@@ -29,9 +29,6 @@ package org.alfresco.module.org_alfresco_module_rm.caveat;
import java.util.Arrays; import java.util.Arrays;
import org.alfresco.api.AlfrescoPublicApi;
@AlfrescoPublicApi
public class RMConstraintInfo public class RMConstraintInfo
{ {
private String name; private String name;

View File

@@ -33,7 +33,6 @@ import java.util.HashMap;
import java.util.List; import java.util.List;
import java.util.Map; import java.util.Map;
import org.alfresco.api.AlfrescoPublicApi;
import org.alfresco.repo.dictionary.constraint.ListOfValuesConstraint; import org.alfresco.repo.dictionary.constraint.ListOfValuesConstraint;
import org.alfresco.repo.security.authentication.AuthenticationUtil; import org.alfresco.repo.security.authentication.AuthenticationUtil;
import org.alfresco.service.cmr.dictionary.ConstraintException; import org.alfresco.service.cmr.dictionary.ConstraintException;
@@ -60,7 +59,6 @@ public class RMListOfValuesConstraint extends ListOfValuesConstraint
// defined match logic used by caveat matching (default = "AND") // defined match logic used by caveat matching (default = "AND")
private MatchLogic matchLogic = MatchLogic.AND; private MatchLogic matchLogic = MatchLogic.AND;
@AlfrescoPublicApi
public enum MatchLogic public enum MatchLogic
{ {
// closed marking - all values must match // closed marking - all values must match

View File

@@ -27,29 +27,26 @@
package org.alfresco.module.org_alfresco_module_rm.dataset; package org.alfresco.module.org_alfresco_module_rm.dataset;
import org.alfresco.api.AlfrescoPublicApi;
@AlfrescoPublicApi
public interface DataSet public interface DataSet
{ {
/** /**
* Gets the label of the data set * Gets the label of the data set
* *
* @return String the label of the data set * @return String the label of the data set
*/ */
String getLabel(); String getLabel();
/** /**
* Gets the id of the data set * Gets the id of the data set
* *
* @return String the id of the data set * @return String the id of the data set
*/ */
String getId(); String getId();
/** /**
* Gets the path of the data set * Gets the path of the data set
* *
* @return String the path of the data set * @return String the path of the data set
*/ */
String getPath(); String getPath();

View File

@@ -29,23 +29,21 @@ package org.alfresco.module.org_alfresco_module_rm.dataset;
import java.util.Map; import java.util.Map;
import org.alfresco.api.AlfrescoPublicApi;
import org.alfresco.service.cmr.repository.NodeRef; import org.alfresco.service.cmr.repository.NodeRef;
@AlfrescoPublicApi
public interface DataSetService public interface DataSetService
{ {
/** /**
* Register a data set implementation with the service * Register a data set implementation with the service
* *
* @param dataSet the data set * @param dataSet the data set
*/ */
void register(DataSet dataSet); void register(DataSet dataSet);
/** /**
* Gets the details of all available data sets. * Gets the details of all available data sets.
* *
* @return Map<String, DataSet> details of all available data sets * @return Map<String, DataSet> details of all available data sets
*/ */
Map<String, DataSet> getDataSets(); Map<String, DataSet> getDataSets();
@@ -53,7 +51,7 @@ public interface DataSetService
/** /**
* Gets the details of all available data sets for a file plan depending on * Gets the details of all available data sets for a file plan depending on
* the parameter "excludeLoaded". * the parameter "excludeLoaded".
* *
* @param filePlan the file plan for which the details should be retrieved * @param filePlan the file plan for which the details should be retrieved
* @param excludeLoaded if true only data sets will be retrieved which has * @param excludeLoaded if true only data sets will be retrieved which has
* not been loaded * not been loaded
@@ -65,7 +63,7 @@ public interface DataSetService
/** /**
* Gets the details of all loaded data sets for a specified file plan * Gets the details of all loaded data sets for a specified file plan
* *
* @param filePlan the file plan for which the loaded data sets should be * @param filePlan the file plan for which the loaded data sets should be
* retrieved * retrieved
* @return Map<String, DataSet> details of all loaded data sets or an empty * @return Map<String, DataSet> details of all loaded data sets or an empty
@@ -76,7 +74,7 @@ public interface DataSetService
/** /**
* Loads the data set with the specified id into the specified file plan * Loads the data set with the specified id into the specified file plan
* *
* @param filePlan the file plan which the data set will load into * @param filePlan the file plan which the data set will load into
* @param dataSetId the id of the data set which will be imported * @param dataSetId the id of the data set which will be imported
*/ */
@@ -84,7 +82,7 @@ public interface DataSetService
/** /**
* Checks if a data set exists with the given data set id * Checks if a data set exists with the given data set id
* *
* @param dataSetId the id of the data set which will be checked * @param dataSetId the id of the data set which will be checked
* @return true if the data set exists, false otherwise * @return true if the data set exists, false otherwise
*/ */
@@ -93,7 +91,7 @@ public interface DataSetService
/** /**
* Checks if a data set with the id "dataSetId" has been loaded into the * Checks if a data set with the id "dataSetId" has been loaded into the
* specified file plan * specified file plan
* *
* @param filePlan the file plan for which the check should be done * @param filePlan the file plan for which the check should be done
* @param dataSetId the id of the data set which should be checked if it has * @param dataSetId the id of the data set which should be checked if it has
* been loaded to the file plan * been loaded to the file plan

View File

@@ -32,7 +32,6 @@ import java.util.Date;
import java.util.Map; import java.util.Map;
import java.util.Set; import java.util.Set;
import org.alfresco.api.AlfrescoPublicApi;
import org.alfresco.error.AlfrescoRuntimeException; import org.alfresco.error.AlfrescoRuntimeException;
import org.alfresco.module.org_alfresco_module_rm.disposition.DispositionAction; import org.alfresco.module.org_alfresco_module_rm.disposition.DispositionAction;
import org.alfresco.module.org_alfresco_module_rm.disposition.DispositionActionDefinition; import org.alfresco.module.org_alfresco_module_rm.disposition.DispositionActionDefinition;
@@ -56,7 +55,6 @@ import org.alfresco.service.namespace.QName;
* *
* @author Roy Wetherall * @author Roy Wetherall
*/ */
@AlfrescoPublicApi
@BehaviourBean @BehaviourBean
public class DispositionProperty extends BaseBehaviourBean public class DispositionProperty extends BaseBehaviourBean
implements NodeServicePolicies.OnUpdatePropertiesPolicy implements NodeServicePolicies.OnUpdatePropertiesPolicy

View File

@@ -30,12 +30,9 @@ package org.alfresco.module.org_alfresco_module_rm.email;
import java.util.List; import java.util.List;
import java.util.Set; import java.util.Set;
import org.alfresco.api.AlfrescoPublicApi;
/** /**
* Custom EMail Mapping Service * Custom EMail Mapping Service
*/ */
@AlfrescoPublicApi
public interface CustomEmailMappingService public interface CustomEmailMappingService
{ {
/** /**

View File

@@ -27,12 +27,9 @@
package org.alfresco.module.org_alfresco_module_rm.email; package org.alfresco.module.org_alfresco_module_rm.email;
import org.alfresco.api.AlfrescoPublicApi;
/** /**
* Custom EMail Mapping * Custom EMail Mapping
*/ */
@AlfrescoPublicApi
public class CustomMapping public class CustomMapping
{ {
private String from; private String from;

View File

@@ -30,7 +30,6 @@ package org.alfresco.module.org_alfresco_module_rm.model;
import java.util.HashMap; import java.util.HashMap;
import java.util.Map; import java.util.Map;
import org.alfresco.api.AlfrescoPublicApi;
import org.alfresco.error.AlfrescoRuntimeException; import org.alfresco.error.AlfrescoRuntimeException;
import org.alfresco.module.org_alfresco_module_rm.util.ServiceBaseImpl; import org.alfresco.module.org_alfresco_module_rm.util.ServiceBaseImpl;
import org.alfresco.repo.policy.BehaviourFilter; import org.alfresco.repo.policy.BehaviourFilter;
@@ -44,7 +43,6 @@ import org.apache.commons.logging.LogFactory;
* @author Roy Wetherall * @author Roy Wetherall
* @since 2.2 * @since 2.2
*/ */
@AlfrescoPublicApi
public abstract class BaseBehaviourBean extends ServiceBaseImpl public abstract class BaseBehaviourBean extends ServiceBaseImpl
implements RecordsManagementModel, implements RecordsManagementModel,
BehaviourRegistry BehaviourRegistry

View File

@@ -30,12 +30,15 @@ package org.alfresco.module.org_alfresco_module_rm.script.slingshot;
import static org.alfresco.util.ParameterCheck.mandatory; import static org.alfresco.util.ParameterCheck.mandatory;
import static org.alfresco.util.ParameterCheck.mandatoryString; import static org.alfresco.util.ParameterCheck.mandatoryString;
import org.alfresco.api.AlfrescoPublicApi;
/** /**
* Recordable version class * Recordable version class
* *
* @author Tuna Aksoy * @author Tuna Aksoy
* @since 2.3 * @since 2.3
*/ */
@AlfrescoPublicApi
public class Version public class Version
{ {
/** The version policy */ /** The version policy */

View File

@@ -31,7 +31,6 @@ import java.util.ArrayList;
import java.util.List; import java.util.List;
import java.util.Map.Entry; import java.util.Map.Entry;
import org.alfresco.api.AlfrescoPublicApi;
import org.alfresco.error.AlfrescoRuntimeException; import org.alfresco.error.AlfrescoRuntimeException;
import org.alfresco.model.ContentModel; import org.alfresco.model.ContentModel;
import org.alfresco.module.org_alfresco_module_rm.model.RecordsManagementModel; import org.alfresco.module.org_alfresco_module_rm.model.RecordsManagementModel;
@@ -64,7 +63,6 @@ import org.springframework.extensions.surf.util.I18NUtil;
* *
* @author Roy Wetherall * @author Roy Wetherall
*/ */
@AlfrescoPublicApi
public class RecordsManagementSearchServiceImpl implements RecordsManagementSearchService public class RecordsManagementSearchServiceImpl implements RecordsManagementSearchService
{ {
private static final String SITES_SPACE_QNAME_PATH = "/app:company_home/st:sites/"; private static final String SITES_SPACE_QNAME_PATH = "/app:company_home/st:sites/";
@@ -216,12 +214,12 @@ public class RecordsManagementSearchServiceImpl implements RecordsManagementSear
// execute query // execute query
ResultSet resultSet = searchService.query(searchParameters); ResultSet resultSet = searchService.query(searchParameters);
// process results // process results
List<Pair<NodeRef, NodeRef>> result = new ArrayList<Pair<NodeRef, NodeRef>>(resultSet.length()); List<Pair<NodeRef, NodeRef>> result = new ArrayList<Pair<NodeRef, NodeRef>>(resultSet.length());
for (ChildAssociationRef childAssoc : resultSet.getChildAssocRefs()) for (ChildAssociationRef childAssoc : resultSet.getChildAssocRefs())
{ {
result.add(new Pair<NodeRef, NodeRef>(childAssoc.getParentRef(), childAssoc.getChildRef())); result.add(new Pair<NodeRef, NodeRef>(childAssoc.getParentRef(), childAssoc.getChildRef()));
} }
// return results // return results

View File

@@ -27,52 +27,55 @@
package org.alfresco.module.org_alfresco_module_rm.search; package org.alfresco.module.org_alfresco_module_rm.search;
import org.alfresco.api.AlfrescoPublicApi;
/** /**
* Report details. * Report details.
* *
* @author Roy Wetherall * @author Roy Wetherall
*/ */
public class ReportDetails @AlfrescoPublicApi
public class ReportDetails
{ {
/** Name */ /** Name */
protected String name; protected String name;
/** Description */ /** Description */
protected String description; protected String description;
/** Search */ /** Search */
protected String search; protected String search;
/** Search parameters */ /** Search parameters */
protected RecordsManagementSearchParameters searchParameters; protected RecordsManagementSearchParameters searchParameters;
/** /**
* *
* @param name * @param name
* @param description * @param description
* @param search * @param search
* @param searchParameters * @param searchParameters
*/ */
public ReportDetails(String name, String description, String search, RecordsManagementSearchParameters searchParameters) public ReportDetails(String name, String description, String search, RecordsManagementSearchParameters searchParameters)
{ {
this.name = name; this.name = name;
this.description = description; this.description = description;
this.search = search; this.search = search;
this.searchParameters = searchParameters; this.searchParameters = searchParameters;
} }
/** /**
* @return {@link String} name * @return {@link String} name
*/ */
public String getName() public String getName()
{ {
return name; return name;
} }
/** /**
* @return {@link String} description * @return {@link String} description
*/ */
public String getDescription() public String getDescription()
{ {
return description; return description;
} }
@@ -80,7 +83,7 @@ public class ReportDetails
/** /**
* @param description description * @param description description
*/ */
public void setDescription(String description) public void setDescription(String description)
{ {
this.description = description; this.description = description;
} }
@@ -92,15 +95,15 @@ public class ReportDetails
{ {
return search; return search;
} }
/** /**
* @param query query string * @param query query string
*/ */
public void setSearch(String search) public void setSearch(String search)
{ {
this.search = search; this.search = search;
} }
/** /**
* @return * @return
*/ */
@@ -108,7 +111,7 @@ public class ReportDetails
{ {
return searchParameters; return searchParameters;
} }
/** /**
* @param searchParameters * @param searchParameters
*/ */

View File

@@ -27,8 +27,10 @@
package org.alfresco.module.org_alfresco_module_rm.search; package org.alfresco.module.org_alfresco_module_rm.search;
import org.alfresco.api.AlfrescoPublicApi;
import org.alfresco.service.namespace.QName; import org.alfresco.service.namespace.QName;
@AlfrescoPublicApi
/*package*/ class SortItem /*package*/ class SortItem
{ {
public QName property = null; public QName property = null;

View File

@@ -27,7 +27,6 @@
package org.alfresco.module.org_alfresco_module_rm.util; package org.alfresco.module.org_alfresco_module_rm.util;
import org.alfresco.api.AlfrescoPublicApi;
import org.alfresco.repo.security.authentication.AuthenticationException; import org.alfresco.repo.security.authentication.AuthenticationException;
import org.alfresco.repo.security.authentication.AuthenticationUtil.RunAsWork; import org.alfresco.repo.security.authentication.AuthenticationUtil.RunAsWork;
@@ -39,7 +38,6 @@ import org.alfresco.repo.security.authentication.AuthenticationUtil.RunAsWork;
* @author Roy Wetherall * @author Roy Wetherall
* @since 2.3 * @since 2.3
*/ */
@AlfrescoPublicApi
public class AuthenticationUtil public class AuthenticationUtil
{ {
/** /**

View File

@@ -31,7 +31,6 @@ import java.util.Map;
import java.util.Set; import java.util.Set;
import java.util.WeakHashMap; import java.util.WeakHashMap;
import org.alfresco.api.AlfrescoPublicApi;
import org.alfresco.module.org_alfresco_module_rm.fileplan.FilePlanComponentKind; import org.alfresco.module.org_alfresco_module_rm.fileplan.FilePlanComponentKind;
import org.alfresco.module.org_alfresco_module_rm.fileplan.FilePlanService; import org.alfresco.module.org_alfresco_module_rm.fileplan.FilePlanService;
import org.alfresco.module.org_alfresco_module_rm.hold.HoldService; import org.alfresco.module.org_alfresco_module_rm.hold.HoldService;
@@ -53,7 +52,6 @@ import org.springframework.context.ApplicationContextAware;
* @author Roy Wetherall * @author Roy Wetherall
* @since 2.1 * @since 2.1
*/ */
@AlfrescoPublicApi
public class ServiceBaseImpl implements RecordsManagementModel, ApplicationContextAware public class ServiceBaseImpl implements RecordsManagementModel, ApplicationContextAware
{ {
/** Node service */ /** Node service */
@@ -73,9 +71,9 @@ public class ServiceBaseImpl implements RecordsManagementModel, ApplicationConte
/** authentication helper */ /** authentication helper */
protected AuthenticationUtil authenticationUtil; protected AuthenticationUtil authenticationUtil;
/** transactional resource helper */ /** transactional resource helper */
protected TransactionalResourceHelper transactionalResourceHelper; protected TransactionalResourceHelper transactionalResourceHelper;
/** /**
* @see org.springframework.context.ApplicationContextAware#setApplicationContext(org.springframework.context.ApplicationContext) * @see org.springframework.context.ApplicationContextAware#setApplicationContext(org.springframework.context.ApplicationContext)
@@ -117,7 +115,7 @@ public class ServiceBaseImpl implements RecordsManagementModel, ApplicationConte
{ {
this.authenticationUtil = authenticationUtil; this.authenticationUtil = authenticationUtil;
} }
/** /**
* @param transactionalResourceHelper transactional resource helper * @param transactionalResourceHelper transactional resource helper
*/ */

View File

@@ -32,16 +32,13 @@ import java.util.Map;
import java.util.Set; import java.util.Set;
import java.util.TreeSet; import java.util.TreeSet;
import org.alfresco.api.AlfrescoPublicApi;
/** /**
* Delegate spring bean for TransactionResourceHelper * Delegate spring bean for TransactionResourceHelper
* *
* @author Roy Wetherall * @author Roy Wetherall
* @since 2.3 * @since 2.3
* @see org.alfresco.repo.transaction.TransactionalResourceHelper * @see org.alfresco.repo.transaction.TransactionalResourceHelper
*/ */
@AlfrescoPublicApi
public class TransactionalResourceHelper public class TransactionalResourceHelper
{ {
/** /**
@@ -51,7 +48,7 @@ public class TransactionalResourceHelper
{ {
return org.alfresco.repo.transaction.TransactionalResourceHelper.getCount(resourceKey); return org.alfresco.repo.transaction.TransactionalResourceHelper.getCount(resourceKey);
} }
/** /**
* @see org.alfresco.repo.transaction.TransactionalResourceHelper#getCount(Object) * @see org.alfresco.repo.transaction.TransactionalResourceHelper#getCount(Object)
*/ */
@@ -59,7 +56,7 @@ public class TransactionalResourceHelper
{ {
org.alfresco.repo.transaction.TransactionalResourceHelper.resetCount(resourceKey); org.alfresco.repo.transaction.TransactionalResourceHelper.resetCount(resourceKey);
} }
/** /**
* @see org.alfresco.repo.transaction.TransactionalResourceHelper#incrementCount(Object) * @see org.alfresco.repo.transaction.TransactionalResourceHelper#incrementCount(Object)
*/ */
@@ -67,7 +64,7 @@ public class TransactionalResourceHelper
{ {
return org.alfresco.repo.transaction.TransactionalResourceHelper.incrementCount(resourceKey); return org.alfresco.repo.transaction.TransactionalResourceHelper.incrementCount(resourceKey);
} }
/** /**
* @see org.alfresco.repo.transaction.TransactionalResourceHelper#decrementCount(Object, boolean) * @see org.alfresco.repo.transaction.TransactionalResourceHelper#decrementCount(Object, boolean)
*/ */
@@ -75,7 +72,7 @@ public class TransactionalResourceHelper
{ {
return org.alfresco.repo.transaction.TransactionalResourceHelper.decrementCount(resourceKey, allowNegative); return org.alfresco.repo.transaction.TransactionalResourceHelper.decrementCount(resourceKey, allowNegative);
} }
/** /**
* @see org.alfresco.repo.transaction.TransactionalResourceHelper#getCount(Object) * @see org.alfresco.repo.transaction.TransactionalResourceHelper#getCount(Object)
*/ */
@@ -83,7 +80,7 @@ public class TransactionalResourceHelper
{ {
return org.alfresco.repo.transaction.TransactionalResourceHelper.isResourcePresent(resourceKey); return org.alfresco.repo.transaction.TransactionalResourceHelper.isResourcePresent(resourceKey);
} }
/** /**
* @see org.alfresco.repo.transaction.TransactionalResourceHelper#getMap(Object) * @see org.alfresco.repo.transaction.TransactionalResourceHelper#getMap(Object)
*/ */