[
https://issues.apache.org/jira/browse/CMIS-665?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13676857#comment-13676857
]
Mouad EL BAKKALI edited comment on CMIS-665 at 6/6/13 9:02 AM:
---------------------------------------------------------------
In debug mode, I can see that properties.get(PropertyIds.OBJECT_TYPE_ID)
returns [cmis:document] but objectTypeIdsValues keeps getting null.
I tried to reproduce the issue by a sample code but I couldn't, the
objectTypeIdsValues gets valued:
{code:title=Sample.java}
Map<String, List<String>> result = new LinkedHashMap<String,
List<String>>();
List<String> values = null;
values = Collections.singletonList("value1");
result.put(PropertyIds.OBJECT_TYPE_ID, values);
values = Collections.singletonList("valu2");
result.put(PropertyIds.NAME, values);
Map<String, List<String>> properties = result;
List<String> objectTypeIdsValues = properties
.get(PropertyIds.OBJECT_TYPE_ID);
{code}
was (Author: emowpy):
In debug mode, I can see that properties.get(PropertyIds.OBJECT_TYPE_ID)
returns [cmis:document] but objectTypeIdsValues keeps getting null.
I tried to reproduce the issue by a sample code but I couldn't:
{code:title=Sample.java}
Map<String, List<String>> result = new LinkedHashMap<String,
List<String>>();
List<String> values = null;
values = Collections.singletonList("value1");
result.put(PropertyIds.OBJECT_TYPE_ID, values);
values = Collections.singletonList("valu2");
result.put(PropertyIds.NAME, values);
Map<String, List<String>> properties = result;
List<String> objectTypeIdsValues = properties
.get(PropertyIds.OBJECT_TYPE_ID);
{code}
> load primary type in AbstractBrowserServiceCall
> -----------------------------------------------
>
> Key: CMIS-665
> URL: https://issues.apache.org/jira/browse/CMIS-665
> Project: Chemistry
> Issue Type: Bug
> Components: opencmis-server
> Reporter: Mouad EL BAKKALI
>
> While trying to create a document, loading the primary type fails in:
> {code:title=AbstractBrowserService.java}
> ....
> // load primary type
> List<String> objectTypeIdsValues =
> properties.get(PropertyIds.OBJECT_TYPE_ID);
> if (objectTypeIdsValues != null && !objectTypeIdsValues.isEmpty()) {
> TypeDefinition typeDef =
> typeCache.getTypeDefinition(objectTypeIdsValues.get(0));
> if (typeDef == null) {
> throw new CmisInvalidArgumentException("Invalid type: " +
> objectTypeIdsValues.get(0));
> }
> }
> ....
> {code}
> objectTypeIdsValues = null.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira