[
https://issues.apache.org/jira/browse/CMIS-439?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Tobias Mattsson updated CMIS-439:
---------------------------------
Attachment: JcrTypeManager.patch
This patch breaks out the registration of the default types from JcrTypeManager
and introduces a new sub-class DefaultJcrTypeManager which registers them.
* The method addType() in JcrTypeManager is changed to also accept base types.
The static methods in JcrTypeManager for creating type definitions are made
public.
* The constant JcrTypeManager.DOCUMENT_UNVERSIONED_TYPE_ID is moved to
DefaultJcrTypeManager.DOCUMENT_UNVERSIONED_TYPE_ID.
* It also introduces a new factory method in JcrServiceFactory for creating the
JcrTypeManager.
* The constanct JcrTypeManager.NAMESPACE is made public.
> Allow customization of the default object types in JcrTypeManager and allow
> registration of base object types
> -------------------------------------------------------------------------------------------------------------
>
> Key: CMIS-439
> URL: https://issues.apache.org/jira/browse/CMIS-439
> Project: Chemistry
> Issue Type: Improvement
> Components: opencmis-server-jcr
> Affects Versions: OpenCMIS 0.6.0
> Reporter: Tobias Mattsson
> Attachments: JcrTypeManager.patch
>
>
> I want our repository to expose only two object types, cmis:folder and
> cmis:document which should be set as non-versionable.
> However it's not possible to remove a type from JcrTypeManager and since the
> default ones are registered in the default constructor of JcrTypeManager its
> not possible to avoid them being registered. So I cannot get rid of the
> cmis:unversioned-document.
> I would like it if JcrTypeManager did not add any default types when it is
> created, instead they could be added by JcrServiceFactory. Currently it's not
> possible to add additional new base types to JcrTypeManager so that will need
> to change too.
> Also, this change means that addBasePropertyDefinitions,
> addFolderPropertyDefinitions, addDocumentPropertyDefinitions and
> createPropDef need to be made public or possible moved elsewhere, possibly to
> a util class, as they are very useful when creating type definitions.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators:
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira