|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.alfresco.repo.forms.processor.AbstractFormProcessor
org.alfresco.repo.forms.processor.FilteredFormProcessor
org.alfresco.repo.forms.processor.node.ContentModelFormProcessor
org.alfresco.repo.forms.processor.node.TypeFormProcessor
public class TypeFormProcessor
FormProcessor implementation that can generate and persist Form objects for types in the Alfresco content model.
| Field Summary | |
|---|---|
static java.lang.String |
DESTINATION
|
protected static java.lang.String |
NAME_PROP_DATA
|
| Fields inherited from class org.alfresco.repo.forms.processor.node.ContentModelFormProcessor |
|---|
associationNamePattern, contentService, dictionaryService, fileFolderService, namespaceService, nodeService, propertyNamePattern, transientPropertyPattern |
| Fields inherited from class org.alfresco.repo.forms.processor.FilteredFormProcessor |
|---|
fieldProcessorRegistry, filterRegistry |
| Fields inherited from class org.alfresco.repo.forms.processor.AbstractFormProcessor |
|---|
active, matchPattern, patternMatcher, processorRegistry |
| Constructor Summary | |
|---|---|
TypeFormProcessor()
|
|
| Method Summary | |
|---|---|
protected org.alfresco.service.cmr.repository.NodeRef |
createNode(org.alfresco.service.cmr.dictionary.TypeDefinition typeDef,
FormData data)
Creates a new instance of the given type. |
protected java.util.Map |
getAssociationValues(org.alfresco.service.cmr.dictionary.TypeDefinition item)
|
protected org.alfresco.service.cmr.dictionary.TypeDefinition |
getBaseType(org.alfresco.service.cmr.dictionary.TypeDefinition type)
|
protected java.util.List |
getDefaultIgnoredFields()
When a Form is generated with no field names specifically set then a default Form is created. |
protected java.lang.String |
getItemType(org.alfresco.service.cmr.dictionary.TypeDefinition item)
Returns a String describing the type fo the specified item. |
protected java.lang.String |
getItemURI(org.alfresco.service.cmr.dictionary.TypeDefinition item)
Returns the URI location of the specified item. |
protected org.apache.commons.logging.Log |
getLogger()
Retrieves a logger instance to log to. |
protected java.util.Map |
getPropertyValues(org.alfresco.service.cmr.dictionary.TypeDefinition item)
|
protected java.util.Map |
getTransientValues(org.alfresco.service.cmr.dictionary.TypeDefinition item)
|
protected org.alfresco.service.cmr.dictionary.TypeDefinition |
getTypedItem(Item item)
Returns a typed Object representing the given item. |
protected org.alfresco.service.cmr.repository.NodeRef |
internalPersist(org.alfresco.service.cmr.dictionary.TypeDefinition item,
FormData data)
Persists the form data. |
| Methods inherited from class org.alfresco.repo.forms.processor.node.ContentModelFormProcessor |
|---|
addPropertyDataIfRequired, determineDefaultMimetype, generateDefaultFields, getAspectNames, makeItemData, persistNode, processAssociationPersist, processContentPropertyPersist, processEncodingPropertyPersist, processMimetypePropertyPersist, processNamePropertyPersist, processPropertyPersist, setContentService, setDictionaryService, setFileFolderService, setNamespaceService, setNodeService |
| Methods inherited from class org.alfresco.repo.forms.processor.FilteredFormProcessor |
|---|
generate, generateSelectedFields, internalGenerate, persist, populateForm, setFieldProcessorRegistry, setFilterRegistry, setIgnoredFields |
| Methods inherited from class org.alfresco.repo.forms.processor.AbstractFormProcessor |
|---|
isActive, isApplicable, register, setActive, setFormItemType, setFormItemUrl, setMatchPattern, setProcessorRegistry, toString |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
protected static final java.lang.String NAME_PROP_DATA
public static final java.lang.String DESTINATION
| Constructor Detail |
|---|
public TypeFormProcessor()
| Method Detail |
|---|
protected org.apache.commons.logging.Log getLogger()
FilteredFormProcessor
getLogger in class FilteredFormProcessorprotected org.alfresco.service.cmr.dictionary.TypeDefinition getTypedItem(Item item)
FilteredFormProcessorSubclasses that represent a form type will return a typed object that is then passed to each of it's handlers, the handlers can therefore safely cast the Object to the type they expect.
getTypedItem in class FilteredFormProcessoritem - The item to get a typed object for
protected org.alfresco.service.cmr.repository.NodeRef internalPersist(org.alfresco.service.cmr.dictionary.TypeDefinition item,
FormData data)
FilteredFormProcessor
internalPersist in class FilteredFormProcessoritem - The object to persist the form fordata - The data to persist
protected org.alfresco.service.cmr.repository.NodeRef createNode(org.alfresco.service.cmr.dictionary.TypeDefinition typeDef,
FormData data)
If the form data has the name property present it is used as the name of the node.
The new node is placed in the location defined by the "destination" data item in the form data (this will usually be a hidden field), this will also be the NodeRef representation of the parent for the new node.
typeDef - The type defintion of the type to createdata - The form data
protected java.lang.String getItemType(org.alfresco.service.cmr.dictionary.TypeDefinition item)
FilteredFormProcessorString describing the type fo the specified item.
getItemType in class FilteredFormProcessorprotected java.lang.String getItemURI(org.alfresco.service.cmr.dictionary.TypeDefinition item)
FilteredFormProcessor
getItemURI in class FilteredFormProcessorprotected org.alfresco.service.cmr.dictionary.TypeDefinition getBaseType(org.alfresco.service.cmr.dictionary.TypeDefinition type)
getBaseType in class ContentModelFormProcessorprotected java.util.Map getAssociationValues(org.alfresco.service.cmr.dictionary.TypeDefinition item)
getAssociationValues in class ContentModelFormProcessorprotected java.util.Map getPropertyValues(org.alfresco.service.cmr.dictionary.TypeDefinition item)
getPropertyValues in class ContentModelFormProcessorprotected java.util.Map getTransientValues(org.alfresco.service.cmr.dictionary.TypeDefinition item)
getTransientValues in class ContentModelFormProcessorprotected java.util.List getDefaultIgnoredFields()
FilteredFormProcessorForm is generated with no field names specifically set then a default Form is created.
The default Form contains all the properties and associations related to the Item, excluding a
blacklist of ignored fields which defaults to the return value of this method.
The default ignored values can be overridden by setting the property ignoredFields.
getDefaultIgnoredFields in class FilteredFormProcessorForm if no defaultFields property is explicitly set.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||