public class CustomModelsImpl extends Object implements CustomModels
| Modifier and Type | Class and Description |
|---|---|
static class |
CustomModelsImpl.ConstraintValidator
Constraint validator
|
class |
CustomModelsImpl.ModelDetails |
| Modifier and Type | Field and Description |
|---|---|
static String |
ASPECT_NAME_NULL_ERR |
static String |
CONSTRAINT_NAME_NULL_ERR |
protected CustomModelService |
customModelService |
protected DictionaryService |
dictionaryService |
static String |
MODEL_NAME_NULL_ERR |
static Pattern |
NAME_PATTERN |
protected NamespaceService |
namespaceService |
protected NodeService |
nodeService |
protected PersonService |
personService |
static String |
TYPE_NAME_NULL_ERR |
static Pattern |
URI_PATTERN |
protected ValueDataTypeValidator |
valueDataTypeValidator |
| Constructor and Description |
|---|
CustomModelsImpl() |
| Modifier and Type | Method and Description |
|---|---|
CustomAspect |
createCustomAspect(String modelName,
CustomAspect aspect)
Creates custom model's aspect
|
CustomModel |
createCustomModel(CustomModel model)
Creates custom model
|
CustomModel |
createCustomModel(M2Model m2Model)
Creates custom model from the imported
M2Model. |
CustomModelConstraint |
createCustomModelConstraint(String modelName,
CustomModelConstraint constraint)
Creates custom model's constraint
|
CustomType |
createCustomType(String modelName,
CustomType type)
Creates custom model's type
|
CustomModelDownload |
createDownload(String modelName,
Parameters parameters)
Starts the creation of a downloadable archive file containing the
custom model file and its associated Share extension module file (if requested).
|
void |
deleteCustomAspect(String modelName,
String aspectName)
Deletes the custom model's aspect
|
void |
deleteCustomModel(String modelName)
Deletes the custom model
|
void |
deleteCustomType(String modelName,
String typeName)
Deletes the custom model's type
|
protected String |
getCurrentUserFullName()
Gets the fully authenticated user's full name
|
CustomAspect |
getCustomAspect(String modelName,
String aspectName,
Parameters parameters)
Gets the
org.alfresco.rest.api.model.CustomAspect representation of
the given model's aspect |
CollectionWithPagingInfo<CustomAspect> |
getCustomAspects(String modelName,
Parameters parameters)
Gets a paged list of all the given custom model's aspects
|
CustomModel |
getCustomModel(String modelName,
Parameters parameters)
Gets the
org.alfresco.rest.api.model.CustomModel representation for the given model |
CustomModelConstraint |
getCustomModelConstraint(String modelName,
String constraintName,
Parameters parameters)
Gets the
org.alfresco.rest.api.model.CustomModelConstraint
representation of the given model's constraint |
CollectionWithPagingInfo<CustomModelConstraint> |
getCustomModelConstraints(String modelName,
Parameters parameters)
Gets a paged list of all of the given custom model's constraints
|
CollectionWithPagingInfo<CustomModel> |
getCustomModels(Parameters parameters)
Gets a paged list of all custom models
|
CustomType |
getCustomType(String modelName,
String typeName,
Parameters parameters)
Gets the
org.alfresco.rest.api.model.CustomType representation of
the given model's type |
CollectionWithPagingInfo<CustomType> |
getCustomTypes(String modelName,
Parameters parameters)
Gets a paged list of all the given custom model's types
|
protected Pair<String,String> |
resolveToUriAndPrefix(String parentName)
Gets the namespace URI and prefix from the parent's name, provided that the
given name is of a valid format.
|
void |
setCustomModelService(CustomModelService customModelService) |
void |
setDictionaryService(DictionaryService dictionaryService) |
void |
setNamespaceService(NamespaceService namespaceService) |
void |
setNodeService(NodeService nodeService) |
void |
setPersonService(PersonService personService) |
void |
setValueDataTypeValidator(ValueDataTypeValidator valueDataTypeValidator) |
CustomAspect |
updateCustomAspect(String modelName,
CustomAspect aspect,
Parameters parameters)
Updates the custom model's aspect
|
CustomModel |
updateCustomModel(String modelName,
CustomModel model,
Parameters parameters)
Updates or activates/deactivates the custom model
|
CustomType |
updateCustomType(String modelName,
CustomType type,
Parameters parameters)
Updates the custom model's type
|
public static final Pattern NAME_PATTERN
public static final Pattern URI_PATTERN
public static final String MODEL_NAME_NULL_ERR
public static final String TYPE_NAME_NULL_ERR
public static final String ASPECT_NAME_NULL_ERR
public static final String CONSTRAINT_NAME_NULL_ERR
protected CustomModelService customModelService
protected DictionaryService dictionaryService
protected PersonService personService
protected NodeService nodeService
protected NamespaceService namespaceService
protected ValueDataTypeValidator valueDataTypeValidator
public void setCustomModelService(CustomModelService customModelService)
public void setDictionaryService(DictionaryService dictionaryService)
public void setPersonService(PersonService personService)
public void setNodeService(NodeService nodeService)
public void setNamespaceService(NamespaceService namespaceService)
public void setValueDataTypeValidator(ValueDataTypeValidator valueDataTypeValidator)
public CustomModel getCustomModel(String modelName, Parameters parameters)
CustomModelsorg.alfresco.rest.api.model.CustomModel representation for the given modelgetCustomModel in interface CustomModelsmodelName - the model nameparameters - the Parameters object to get the parameters passed into the requestorg.alfresco.rest.api.model.CustomModel objectpublic CollectionWithPagingInfo<CustomModel> getCustomModels(Parameters parameters)
CustomModelsgetCustomModels in interface CustomModelsparameters - the Parameters object to get the parameters passed into the requestorg.alfresco.rest.api.model.CustomModel objectspublic CustomModel createCustomModel(CustomModel model)
CustomModelscreateCustomModel in interface CustomModelsmodel - the custom model to createorg.alfresco.rest.api.model.CustomModel objectpublic CustomModel updateCustomModel(String modelName, CustomModel model, Parameters parameters)
CustomModelsupdateCustomModel in interface CustomModelsmodelName - the model namemodel - the custom model to update (JSON payload)parameters - the Parameters object to get the parameters passed into the requestorg.alfresco.rest.api.model.CustomModel objectpublic void deleteCustomModel(String modelName)
CustomModelsdeleteCustomModel in interface CustomModelsmodelName - the model namepublic CustomType getCustomType(String modelName, String typeName, Parameters parameters)
CustomModelsorg.alfresco.rest.api.model.CustomType representation of
the given model's typegetCustomType in interface CustomModelsmodelName - the model nametypeName - the model's type nameparameters - the Parameters object to get the parameters passed into the requestorg.alfresco.rest.api.model.CustomType objectpublic CollectionWithPagingInfo<CustomType> getCustomTypes(String modelName, Parameters parameters)
CustomModelsgetCustomTypes in interface CustomModelsmodelName - the model nameparameters - the Parameters object to get the parameters passed into the requestorg.alfresco.rest.api.model.CustomType objectspublic CustomType createCustomType(String modelName, CustomType type)
CustomModelscreateCustomType in interface CustomModelsmodelName - the model nametype - the custom type to create within the given modelorg.alfresco.rest.api.model.CustomType objectpublic CustomType updateCustomType(String modelName, CustomType type, Parameters parameters)
CustomModelsupdateCustomType in interface CustomModelsmodelName - the model nametype - the custom model's type to update (JSON payload)parameters - the Parameters object to get the parameters passed into the requestorg.alfresco.rest.api.model.CustomType objectpublic void deleteCustomType(String modelName, String typeName)
CustomModelsdeleteCustomType in interface CustomModelsmodelName - the model nametypeName - the model's type namepublic CustomAspect getCustomAspect(String modelName, String aspectName, Parameters parameters)
CustomModelsorg.alfresco.rest.api.model.CustomAspect representation of
the given model's aspectgetCustomAspect in interface CustomModelsmodelName - the model nameaspectName - the model's aspect nameparameters - the Parameters object to get the parameters passed into the requestorg.alfresco.rest.api.model.CustomAspect objectpublic CollectionWithPagingInfo<CustomAspect> getCustomAspects(String modelName, Parameters parameters)
CustomModelsgetCustomAspects in interface CustomModelsmodelName - the model nameparameters - the Parameters object to get the parameters passed into the requestorg.alfresco.rest.api.model.CustomAspect objectspublic CustomAspect createCustomAspect(String modelName, CustomAspect aspect)
CustomModelscreateCustomAspect in interface CustomModelsmodelName - the model nameaspect - the custom aspect to create within the given modelorg.alfresco.rest.api.model.CustomAspect objectpublic CustomAspect updateCustomAspect(String modelName, CustomAspect aspect, Parameters parameters)
CustomModelsupdateCustomAspect in interface CustomModelsmodelName - the model nameaspect - the custom model's aspect to update (JSON payload)parameters - the Parameters object to get the parameters passed into the requestorg.alfresco.rest.api.model.CustomAspect objectpublic void deleteCustomAspect(String modelName, String aspectName)
CustomModelsdeleteCustomAspect in interface CustomModelsmodelName - the model nameaspectName - the model's aspect namepublic CollectionWithPagingInfo<CustomModelConstraint> getCustomModelConstraints(String modelName, Parameters parameters)
CustomModelsgetCustomModelConstraints in interface CustomModelsmodelName - the model nameparameters - the Parameters object to get the parameters passed into the requestorg.alfresco.rest.api.model.CustomModelConstraint objectspublic CustomModelConstraint getCustomModelConstraint(String modelName, String constraintName, Parameters parameters)
CustomModelsorg.alfresco.rest.api.model.CustomModelConstraint
representation of the given model's constraintgetCustomModelConstraint in interface CustomModelsmodelName - the model nameconstraintName - the model's constraint nameparameters - the Parameters object to get the parameters passed into the requestorg.alfresco.rest.api.model.CustomModelConstraint objectpublic CustomModelConstraint createCustomModelConstraint(String modelName, CustomModelConstraint constraint)
CustomModelscreateCustomModelConstraint in interface CustomModelsmodelName - the model nameconstraint - the custom constraint to create within the given modelorg.alfresco.rest.api.model.CustomModelConstraint objectpublic CustomModelDownload createDownload(String modelName, Parameters parameters)
CustomModelscreateDownload in interface CustomModelsmodelName - the model nameparameters - the Parameters object to get the parameters
passed into the requestorg.alfresco.rest.api.model.CustomModelDownload object
containing the archive node referenceprotected String getCurrentUserFullName()
protected Pair<String,String> resolveToUriAndPrefix(String parentName)
parentName - the parent namepublic CustomModel createCustomModel(M2Model m2Model)
CustomModelsM2Model.createCustomModel in interface CustomModelsm2Model - the modelorg.alfresco.rest.api.model.CustomModel objectCopyright © 2005–2021 Alfresco Software. All rights reserved.