Merge from SEAMIST3

git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@10724 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
David Caruana
2008-09-04 10:53:14 +00:00
parent d4bb800e1d
commit 703d1a3564
34 changed files with 11523 additions and 1160 deletions

View File

@@ -1,6 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
<classpathentry kind="src" path="source/java"/>
<classpathentry kind="src" path="source/xsd"/>
<classpathentry kind="src" path="source/generated"/>
<classpathentry kind="src" path="source/test/java"/>
<classpathentry kind="src" path="source/test-resources"/>

View File

@@ -0,0 +1,83 @@
<#-- -->
<#-- ATOM Entry for Document -->
<#-- -->
<#macro document node>
<#-- ATOM syndication -->
<author><name>${node.properties.creator}</name></author>
<content type="${node.mimetype}" src="${absurl(url.serviceContext)}/api/node/${node.nodeRef.storeRef.protocol}/${node.nodeRef.storeRef.identifier}/${node.nodeRef.id}/content"/>
<id>urn:uuid:${node.id}</id>
<published>${xmldate(node.properties.created)}</published>
<summary>${node.properties.description!node.properties.title!cropContent(node, 50)}</summary>
<title>${node.name}</title>
<updated>${xmldate(node.properties.modified)}</updated>
<link rel="self" href="${absurl(url.serviceContext)}/api/node/${node.nodeRef.storeRef.protocol}/${node.nodeRef.storeRef.identifier}/${node.nodeRef.id}" type="entry"/>
<link rel="enclosure" href="${absurl(url.serviceContext)}/api/node/${node.nodeRef.storeRef.protocol}/${node.nodeRef.storeRef.identifier}/${node.nodeRef.id}/content" type="${node.mimetype}"/>
<#-- ATOM Publishing Protocol -->
<app:edited>${xmldate(node.properties.modified)}</app:edited>
<link rel="edit" href="${absurl(url.serviceContext)}/api/node/${node.nodeRef.storeRef.protocol}/${node.nodeRef.storeRef.identifier}/${node.nodeRef.id}" type="entry"/>
<link rel="edit-media" href="${absurl(url.serviceContext)}/api/node/${node.nodeRef.storeRef.protocol}/${node.nodeRef.storeRef.identifier}/${node.nodeRef.id}/content" type="${node.mimetype}"/>
<#-- Alfresco props -->
<alf:icon>${absurl(url.context)}${node.icon16}</alf:icon>
<#-- CMIS Schema -->
<link rel="cmis-allowableactions" href="${absurl(url.serviceContext)}/api/node/${node.nodeRef.storeRef.protocol}/${node.nodeRef.storeRef.identifier}/${node.nodeRef.id}/permissions" type="entry"/>
<link rel="cmis-relationships" href="${absurl(url.serviceContext)}/api/node/${node.nodeRef.storeRef.protocol}/${node.nodeRef.storeRef.identifier}/${node.nodeRef.id}/associations" type="feed"/>
<link rel="cmis-parents" href="${absurl(url.serviceContext)}/api/node/${node.nodeRef.storeRef.protocol}/${node.nodeRef.storeRef.identifier}/${node.nodeRef.id}/parents" type="feed"/>
<link rel="cmis-allversions" href="${absurl(url.serviceContext)}/api/node/${node.nodeRef.storeRef.protocol}/${node.nodeRef.storeRef.identifier}/${node.nodeRef.id}/versions" type="feed"/>
<link rel="cmis-stream" href="${absurl(url.serviceContext)}/api/node/${node.nodeRef.storeRef.protocol}/${node.nodeRef.storeRef.identifier}/${node.nodeRef.id}/content" type="${node.mimetype}"/>
<cmis:object>
<cmis:object_id>${node.nodeRef}</cmis:object_id>
<cmis:baseType>document</cmis:baseType>
<cmis:createdBy>${node.properties.creator}</cmis:createdBy>
<cmis:creationDate>${xmldate(node.properties.created)}</cmis:creationDate>
<cmis:lastModifiedBy>${node.properties.modifier}</cmis:lastModifiedBy>
<cmis:lastModificationDate>${xmldate(node.properties.modified)}</cmis:lastModificationDate>
<cmis:contentStreamLength>${node.properties.content.size}</cmis:contentStreamLength>
<cmis:contentStreamMimetype>${node.properties.content.mimetype}</cmis:contentStreamMimetype>
<cmis:contentStreamName>${node.name}</cmis:contentStreamName>
<cmis:contentStreamUri>${absurl(url.serviceContext)}/api/node/${node.nodeRef.storeRef.protocol}/${node.nodeRef.storeRef.identifier}/${node.nodeRef.id}/content</cmis:contentStreamUri>
</cmis:object>
<#-- CMIS LINKS -->
</#macro>
<#-- -->
<#-- ATOM Entry for Folder -->
<#-- -->
<#macro folder node>
<#-- ATOM syndication -->
<author><name>${node.properties.creator}</name></author>
<content>${node.id}</content> <#-- TODO -->
<id>urn:uuid:${node.id}</id>
<published>${xmldate(node.properties.created)}</published>
<summary>${node.properties.description!node.properties.title}</summary> <#-- TODO -->
<title>${node.name}</title>
<updated>${xmldate(node.properties.modified)}</updated>
<link rel="self" href="${absurl(url.serviceContext)}/api/node/${node.nodeRef.storeRef.protocol}/${node.nodeRef.storeRef.identifier}/${node.nodeRef.id}" type="entry"/>
<#-- ATOM Publishing Protocol -->
<app:edited>${xmldate(node.properties.modified)}</app:edited>
<link rel="edit" href="${absurl(url.serviceContext)}/api/node/${node.nodeRef.storeRef.protocol}/${node.nodeRef.storeRef.identifier}/${node.nodeRef.id}" type="entry"/>
<#-- Alfresco props -->
<alf:icon>${absurl(url.context)}${node.icon16}</alf:icon>
<#-- CMIS Schema -->
<link rel="cmis-allowableactions" href="${absurl(url.serviceContext)}/api/node/${node.nodeRef.storeRef.protocol}/${node.nodeRef.storeRef.identifier}/${node.nodeRef.id}/permissions" type="entry"/>
<link rel="cmis-relationships" href="${absurl(url.serviceContext)}/api/node/${node.nodeRef.storeRef.protocol}/${node.nodeRef.storeRef.identifier}/${node.nodeRef.id}/associations" type="feed"/>
<link rel="cmis-parent" href="${absurl(url.serviceContext)}/api/node/${node.nodeRef.storeRef.protocol}/${node.nodeRef.storeRef.identifier}/${node.nodeRef.id}/parent" type="feed"/>
<link rel="cmis-children" href="${absurl(url.serviceContext)}/api/node/${node.nodeRef.storeRef.protocol}/${node.nodeRef.storeRef.identifier}/${node.nodeRef.id}/children" type="feed"/>
<link rel="cmis-descendants" href="${absurl(url.serviceContext)}/api/node/${node.nodeRef.storeRef.protocol}/${node.nodeRef.storeRef.identifier}/${node.nodeRef.id}/descendants" type="feed"/>
<cmis:object>
<cmis:object_id>${node.nodeRef}</cmis:object_id>
<cmis:baseType>folder</cmis:baseType>
<cmis:createdBy>${node.properties.creator}</cmis:createdBy>
<cmis:creationDate>${xmldate(node.properties.created)}</cmis:creationDate>
<cmis:lastModifiedBy>${node.properties.modifier}</cmis:lastModifiedBy>
<cmis:lastModificationDate>${xmldate(node.properties.modified)}</cmis:lastModificationDate>
<cmis:name>${node.name}</cmis:name>
<cmis:parent>${node.parent.nodeRef}</cmis:parent>
<#-- In certain cases, if depth is specified children may appear Here. If there are children, the cmis:object tag will be nested For the children of this item -->
</cmis:object>
</#macro>
<#-- Helper to render Alfresco content type to Atom content type -->
<#macro contenttype type><#if type == "text/html">text<#elseif type == "text/xhtml">xhtml<#elseif type == "text/plain">text<#else>${type}</#if></#macro>

View File

@@ -0,0 +1,23 @@
<#-- -->
<#-- ATOM Feed for Node -->
<#-- -->
<#macro node node>
<author><name>${node.properties.creator!""}</name></author>
<generator version="${server.version}">Alfresco (${server.edition})</generator>
<icon>${absurl(url.context)}/images/logo/AlfrescoLogo16.ico</icon>
<id>urn:uuid:${node.id}</id>
<title>${node.name}</title>
<updated>${xmldate(node.properties.modified)}</updated>
<link rel="self" href="${absurl(url.full)?xml}" type="feed"/>
</#macro>
<#macro generic id title>
<author><name>System</name></author>
<generator version="${server.version}">Alfresco (${server.edition})</generator>
<icon>${absurl(url.context)}/images/logo/AlfrescoLogo16.ico</icon>
<id>${id}</id>
<title>${title}</title>
<updated>${xmldate(date)}</updated>
<link rel="self" href="${absurl(url.full)?xml}" type="feed"/>
</#macro>

View File

@@ -29,8 +29,9 @@
<cmis:keyword cmis:index="1">standards</cmis:keyword> <#-- TODO: -->
</cmis:object>
<#-- TODO: ATOM LINKS -->
<link rel="self" href="${absurl(url.full)}"/>
<link rel="alternate" href="${absurl(url.serviceContext)}${node.url}"/> <#-- TODO: -->
<link rel="self" href="${absurl(url.serviceContext)}/api/node/${node.nodeRef.storeRef.protocol}/${node.nodeRef.storeRef.identifier}/${node.nodeRef.id}" type="application/atom+xml"/>
<link rel="edit" href="${absurl(url.serviceContext)}/api/node/${node.nodeRef.storeRef.protocol}/${node.nodeRef.storeRef.identifier}/${node.nodeRef.id}" type="application/atom+xml"/>
<#-- CMIS LINKS -->
<link rel="cmis-parents" href="http://example.org/atom03?getdocumentparents"/> <#-- TODO: -->
<link rel="cmis-allowableactions" href="http://example.org/atom03?getactions"/> <#-- TODO: -->
@@ -43,7 +44,6 @@
<#macro folder node>
<#-- ATOM props -->
<title>${node.name}</title>
<link rel="alternate" href="${absurl(url.serviceContext)}${node.url}"/>
<id>urn:uuid:${node.id}</id>
<updated>${xmldate(node.properties.modified)}</updated>
<published>${xmldate(node.properties.created)}</published>
@@ -68,7 +68,9 @@
<#-- In certain cases, if depth is specified children may appear Here. If there are children, the cmis:object tag will be nested For the children of this item -->
</cmis:object>
<#-- TODO: ATOM LINKS -->
<link rel="self" href="${absurl(url.full)}"/>
<link rel="alternate" href="${absurl(url.serviceContext)}${node.url}"/>
<link rel="self" href="${absurl(url.serviceContext)}/api/node/${node.nodeRef.storeRef.protocol}/${node.nodeRef.storeRef.identifier}/${node.nodeRef.id}" type="application/atom+xml"/>
<link rel="edit" href="${absurl(url.serviceContext)}/api/node/${node.nodeRef.storeRef.protocol}/${node.nodeRef.storeRef.identifier}/${node.nodeRef.id}" type="application/atom+xml"/>
<#-- CMIS LINKS -->
<link rel="cmis-parent" href="http://example.org/folders/myfolder?getfolderparent"/> <#-- TODO: -->
<link rel="cmis-allowableactions" href="http://example.org/folders/myfolder?getactions"/> <#-- TODO: -->

View File

@@ -1,8 +1,8 @@
<#macro appNS>http://www.w3.org/2007/app</#macro>
<#macro atomNS>http://www.w3.org/2005/Atom</#macro>
<#macro cmisNS>http://www.cmis.org/CMIS/1.0</#macro>
<#macro cmisNS>http://www.cmis.org/2008/05</#macro>
<#macro alfNS>http://www.alfresco.org</#macro>
<#macro opensearchNS>http://a9.com/-/spec/opensearch/1.1/</#macro>
<#macro serviceNS>xmlns="<@appNS/>" xmlns:atom="<@atomNS/>" xmlns:cmis="<@cmisNS/>" xmlns:alf="<@alfNS/>"</#macro>
<#macro feedNS>xmlns="<@atomNS/>" xmlns:cmis="<@cmisNS/>" xmlns:alf="<@alfNS/>" xmlns:opensearch="<@opensearchNS/>"</#macro>
<#macro entryNS>xmlns="<@atomNS/>" xmlns:cmis="<@cmisNS/>" xmlns:alf="<@alfNS/>"</#macro>
<#macro feedNS>xmlns="<@atomNS/>" xmlns:app="<@appNS/>" xmlns:cmis="<@cmisNS/>" xmlns:alf="<@alfNS/>" xmlns:opensearch="<@opensearchNS/>"</#macro>
<#macro entryNS>xmlns="<@atomNS/>" xmlns:app="<@appNS/>" xmlns:cmis="<@cmisNS/>" xmlns:alf="<@alfNS/>"</#macro>

View File

@@ -17,12 +17,13 @@
<cmis:capabilityMultifiling>true</cmis:capabilityMultifiling>
<cmis:capabilityUnfiling>false</cmis:capabilityUnfiling>
<cmis:capabilityVersionSpecificFiling>false</cmis:capabilityVersionSpecificFiling>
<cmis:capabilityPWCUpdateable>true</cmis:capabilityPWCUpdateable>
<cmis:capabilityAllVersionsSearchable>false</cmis:capabilityAllVersionsSearchable>
<cmis:capabilityPWCUpdatable>true</cmis:capabilityPWCUpdatable>
<cmis:capabilityInnerJoin>true</cmis:capabilityInnerJoin>
<cmis:capabilityOuterJoin>true</cmis:capabilityOuterJoin>
<cmis:capabilityFullText>fulltextwithmetadata</cmis:capabilityFullText>
</cmis:capabilities>
<cmis:repositorySpecificInfo></cmis:repositorySpecificInfo>
<cmis:repositorySpecificInformation></cmis:repositorySpecificInformation>
</cmis:repositoryInfo>
<#-- TODO: cmis:id on collection elements - are they required by cmis? -->

View File

@@ -1,24 +1,17 @@
<#import "/org/alfresco/cmis/ns.lib.atom.ftl" as nsLib/>
<#import "/org/alfresco/cmis/entries.lib.atom.ftl" as entriesLib/>
<#import "/org/alfresco/cmis/atomfeed.lib.atom.ftl" as feedLib/>
<#import "/org/alfresco/cmis/atomentry.lib.atom.ftl" as entryLib/>
<#import "/org/alfresco/paging.lib.atom.ftl" as pagingLib/>
<?xml version="1.0" encoding="UTF-8"?>
<feed <@nsLib.feedNS/>>
<generator version="${server.version}">Alfresco (${server.edition})</generator>
<title>${node.name}</title>
<updated>${xmldate(node.properties.modified)}</updated>
<icon>${absurl(url.context)}/images/logo/AlfrescoLogo16.ico</icon>
<author>
<name>${node.properties.creator!""}</name>
</author>
<id>urn:uuid:${node.id}</id>
<link rel="self" href="${absurl(url.full)?xml}" type="${format.type}"/>
<@feedLib.node node=node/>
<@pagingLib.cursor cursor=cursor/>
<#list results as child>
<entry>
<#if child.isDocument>
<@entriesLib.document node=child/>
<@entryLib.document node=child/>
<#else>
<@entriesLib.folder node=child/>
<@entryLib.folder node=child/>
</#if>
</entry>
</#list>

View File

@@ -9,7 +9,7 @@ script:
break script;
}
// locate node
// locate parent node
var pathSegments = url.match.split("/");
var reference = [ url.templateArgs.store_type, url.templateArgs.store_id ].concat(url.templateArgs.id.split("/"));
model.parent = cmis.findNode(pathSegments[2], reference);
@@ -22,7 +22,6 @@ script:
}
// pull apart atom entry
// TODO: creation of folder
// TODO: creation of file/folder sub-types
// TODO: cmis properties
@@ -33,9 +32,14 @@ script:
var updated = entry.updated;
var author = (entry.author !== null) ? entry.author.name : null;
var content = entry.content;
var cmisObject = entry.getExtension(atom.names.cmis_object);
var baseType = (cmisObject !== null) ? cmisObject.baseType : null;
// create the item
// TODO: author/updated/id
if (baseType === null || baseType == "document")
{
var node = model.parent.createFile(name);
node.properties.title = title;
node.properties.description = description;
@@ -47,10 +51,26 @@ script:
}
node.save();
model.node = node;
}
else if (baseType == "folder")
{
var node = model.parent.createFolder(name);
node.properties.title = title;
node.properties.description = description;
node.save();
model.node = node;
}
else
{
status.code = 400;
status.message = "CMIS base type " + baseType + " not understood";
status.redirect = true;
break script;
}
// setup for 201 Created response
// TODO: set Content-Location
status.code = 201;
status.location = url.server + url.serviceContext + "/api/node/" + node.nodeRef.storeRef.protocol + "/" + node.nodeRef.storeRef.identifier + "/" + node.nodeRef.id + "/properties";
status.location = url.server + url.serviceContext + "/api/node/" + node.nodeRef.storeRef.protocol + "/" + node.nodeRef.storeRef.identifier + "/" + node.nodeRef.id;
status.redirect = true;
}

View File

@@ -1,10 +1,10 @@
<#import "/org/alfresco/cmis/ns.lib.atom.ftl" as nsLib/>
<#import "/org/alfresco/cmis/entries.lib.atom.ftl" as entriesLib/>
<#import "/org/alfresco/cmis/atomentry.lib.atom.ftl" as entryLib/>
<?xml version="1.0" encoding="UTF-8"?>
<entry <@nsLib.entryNS/>>
<#if node.isDocument>
<@entriesLib.document node=node/>
<@entryLib.document node=node/>
<#else>
<@entriesLib.folder node=node/>
<@entryLib.folder node=node/>
</#if>
</entry>

View File

@@ -0,0 +1,9 @@
<webscript>
<shortname>Delete tree</shortname>
<description>Delete tree</description>
<url>/api/node/{store_type}/{store_id}/{id}/descendants?continueOnFailure={continueOnFailure?}&amp;unfileMultiFiledDocuments={unfileMultiFiledDocuments}</url>
<url>/api/path/{store_type}/{store_id}/{id}/descendants?continueOnFailure={continueOnFailure?}&amp;unfileMultiFiledDocuments={unfileMultiFiledDocuments}</url>
<authentication>user</authentication>
<format default="atomfeed"/>
<cmis version="0.21"/>
</webscript>

View File

@@ -0,0 +1,38 @@
script:
{
// locate node
var pathSegments = url.match.split("/");
var reference = [ url.templateArgs.store_type, url.templateArgs.store_id ].concat(url.templateArgs.id.split("/"));
var node = cmis.findNode(pathSegments[2], reference);
if (node === null)
{
status.code = 404;
status.message = "Repository " + pathSegments[2] + " " + reference.join("/") + " not found";
status.redirect = true;
break script;
}
// NOTE: Ignore continueOnDelete as complete tree is deleted in single transaction
// TODO: Throw error on invalid unfileMultiFiledDocuments error
if (!node.hasPermission("Delete"))
{
status.code = 403;
status.message = "Permission to delete is denied";
status.redirect = true;
break script;
}
// TODO: Checked-out documents - are they automatically cancelled?
if (!node.remove())
{
status.code = 500;
status.message = "Failed to delete node " + pathSegments[2] + " " + reference.join("/");
status.redirect = true;
break script;
}
status.code = 204; // Success, but no response content
status.redirect = true;
}

View File

@@ -0,0 +1,9 @@
<webscript>
<shortname>Delete item</shortname>
<description>Delete item</description>
<url>/api/node/{store_type}/{store_id}/{id}?includeChildren={includeChildren?}</url>
<url>/api/path/{store_type}/{store_id}/{id}?includeChildren={includeChildren?}</url>
<authentication>user</authentication>
<format default="atomentry"/>
<cmis version="0.21"/>
</webscript>

View File

@@ -0,0 +1,49 @@
script:
{
// locate node
var pathSegments = url.match.split("/");
var reference = [ url.templateArgs.store_type, url.templateArgs.store_id ].concat(url.templateArgs.id.split("/"));
var node = cmis.findNode(pathSegments[2], reference);
if (node === null)
{
status.code = 404;
status.message = "Repository " + pathSegments[2] + " " + reference.join("/") + " not found";
status.redirect = true;
break script;
}
if (!node.hasPermission("Delete"))
{
status.code = 403;
status.message = "Permission to delete is denied";
status.redirect = true;
break script;
}
// if deleting a folder, only delete when the folder is empty or
// a force delete has been specified
// NOTE: force delete is not part of CMIS specification
if (node.isFolder)
{
if (node.children.length > 0 && !args.includeChildren)
{
status.code = 403;
status.message = "Cannot delete folder " + pathSegments[2] + " " + reference.join("/") + " as it's not empty";
status.redirect = true;
break script;
}
}
// TODO: Checked-out documents - are they automatically cancelled?
if (!node.remove())
{
status.code = 500;
status.message = "Failed to delete node " + pathSegments[2] + " " + reference.join("/");
status.redirect = true;
break script;
}
status.code = 204; // Success, but no response content
status.redirect = true;
}

View File

@@ -1,10 +1,10 @@
<#import "/org/alfresco/cmis/ns.lib.atom.ftl" as nsLib/>
<#import "/org/alfresco/cmis/entries.lib.atom.ftl" as entriesLib/>
<#import "/org/alfresco/cmis/atomentry.lib.atom.ftl" as entryLib/>
<?xml version="1.0" encoding="UTF-8"?>
<entry <@nsLib.entryNS/>>
<#if node.isDocument>
<@entriesLib.document node=node/>
<@entryLib.document node=node/>
<#else>
<@entriesLib.folder node=node/>
<@entryLib.folder node=node/>
</#if>
</entry>

View File

@@ -2,8 +2,9 @@
<shortname>Retrieve properties</shortname>
<description>Retrieves the properties of the node</description>
<!-- TODO: spec issue: returnVersion or returnCurrent? -->
<url>/api/node/{store_type}/{store_id}/{id}/properties?filter={filter?}&amp;returnVersion={returnVersion?}</url>
<url>/api/path/{store_type}/{store_id}/{id}/properties?filter={filter?}&amp;returnVersion={returnVersion?}</url>
<url>/api/node/{store_type}/{store_id}/{id}?filter={filter?}&amp;returnVersion={returnVersion?}</url>
<url>/api/path/{store_type}/{store_id}/{id}?filter={filter?}&amp;returnVersion={returnVersion?}</url>
<!-- TODO: consider /api/node/{store_type}/{store_id}/{id}/{child_node} for atom relative paths -->
<authentication>guest</authentication>
<format default="atomentry">argument</format>
<cmis version="0.21"/>

View File

@@ -1,23 +1,16 @@
<#import "/org/alfresco/cmis/ns.lib.atom.ftl" as nsLib/>
<#import "/org/alfresco/cmis/entries.lib.atom.ftl" as entriesLib/>
<#import "/org/alfresco/cmis/atomfeed.lib.atom.ftl" as feedLib/>
<#import "/org/alfresco/cmis/atomentry.lib.atom.ftl" as entryLib/>
<?xml version="1.0" encoding="UTF-8"?>
<feed <@nsLib.feedNS/>>
<generator version="${server.version}">Alfresco (${server.edition})</generator>
<title>${node.name}</title>
<updated>${xmldate(node.properties.modified)}</updated>
<icon>${absurl(url.context)}/images/logo/AlfrescoLogo16.ico</icon>
<author>
<name>${node.properties.creator!""}</name>
</author>
<id>urn:uuid:${node.id}</id>
<link rel="self" href="${absurl(url.full)?xml}" type="${format.type}"/>
<@feedLib.node node=node/>
<@parent node=node.parent recurse=returnToRoot/>
</feed>
<#macro parent node recurse=false>
<#if node?exists && node.isContainer>
<entry>
<@entriesLib.folder node=node/>
<@entryLib.folder node=node/>
</entry>
<#if recurse>
<@parent node=node.parent recurse=true/>

View File

@@ -1,16 +1,9 @@
<#import "/org/alfresco/cmis/ns.lib.atom.ftl" as nsLib/>
<#import "/org/alfresco/cmis/entries.lib.atom.ftl" as entriesLib/>
<#import "/org/alfresco/cmis/atomfeed.lib.atom.ftl" as feedLib/>
<#import "/org/alfresco/cmis/atomentry.lib.atom.ftl" as entryLib/>
<?xml version="1.0" encoding="UTF-8"?>
<feed <@nsLib.feedNS/>>
<generator version="${server.version}">Alfresco (${server.edition})</generator>
<title>${node.name}</title>
<updated>${xmldate(node.properties.modified)}</updated>
<icon>${absurl(url.context)}/images/logo/AlfrescoLogo16.ico</icon>
<author>
<name>${node.properties.creator!""}</name>
</author>
<id>urn:uuid:${node.id}</id>
<link rel="self" href="${absurl(url.full)?xml}" type="${format.type}"/>
<@feedLib.node node=node/>
<@parent node=node.parent recurse=returnToRoot/>
<#-- TODO: secondary parents loop -->
</feed>
@@ -18,7 +11,7 @@
<#macro parent node recurse=false>
<#if node?exists && node.isContainer>
<entry>
<@entriesLib.folder node=node/>
<@entryLib.folder node=node/>
</entry>
<#if recurse>
<@parent node=node.parent recurse=true/>

View File

@@ -1,13 +1,6 @@
<#import "/org/alfresco/cmis/ns.lib.atom.ftl" as nsLib/>
<#import "/org/alfresco/cmis/atomfeed.lib.atom.ftl" as feedLib/>
<?xml version="1.0" encoding="UTF-8"?>
<feed xmlns="http://www.w3.org/2005/Atom" xmlns:cmis="http://www.cmis.org/CMIS/1.0" xmlns:alf="http://www.alfresco.org" xmlns:opensearch="http://a9.com/-/spec/opensearch/1.1/">
<generator version="${server.version}">Alfresco (${server.edition})</generator>
<title>Unfiled Documents</title>
<updated>${xmldate(date)}</updated>
<icon>${absurl(url.context)}/images/logo/AlfrescoLogo16.ico</icon>
<author>
<name>System</name>
</author>
<id>urn:uuid:unfiled</id>
<link rel="self" href="${absurl(url.full)?xml}" type="${format.type}"/>
<#-- NOTE: Alfresco does not yet support unfiled documents -->
<feed <@nsLib.feedNS/>>
<@feedLib.generic id="urn:uuid:unfiled" title="Unfiled Documents"/>
</feed>

View File

@@ -427,9 +427,11 @@
<alias alias="webscriptdesc.org.alfresco.repository.repository.get" name="webscripts.cmis.description"/>
<alias alias="webscriptdesc.org.alfresco.repository.store.children.get" name="webscripts.cmis.description"/>
<alias alias="webscriptdesc.org.alfresco.repository.store.children.post" name="webscripts.cmis.description"/>
<alias alias="webscriptdesc.org.alfresco.repository.store.descendants.delete" name="webscripts.cmis.description"/>
<alias alias="webscriptdesc.org.alfresco.repository.store.parent.get" name="webscripts.cmis.description"/>
<alias alias="webscriptdesc.org.alfresco.repository.store.parents.get" name="webscripts.cmis.description"/>
<alias alias="webscriptdesc.org.alfresco.repository.store.properties.get" name="webscripts.cmis.description"/>
<alias alias="webscriptdesc.org.alfresco.repository.store.item.delete" name="webscripts.cmis.description"/>
<alias alias="webscriptdesc.org.alfresco.repository.store.item.get" name="webscripts.cmis.description"/>
<alias alias="webscriptdesc.org.alfresco.repository.store.unfiled.get" name="webscripts.cmis.description"/>
<alias alias="webscriptdesc.org.alfresco.repository.store.content.get" name="webscripts.cmis.description"/>

View File

@@ -0,0 +1,158 @@
/*
* Copyright (C) 2005-2007 Alfresco Software Limited.
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
* As a special exception to the terms and conditions of version 2.0 of
* the GPL, you may redistribute this Program in connection with Free/Libre
* and Open Source Software ("FLOSS") applications as described in Alfresco's
* FLOSS exception. You should have recieved a copy of the text describing
* the FLOSS exception, and it is also available here:
* http://www.alfresco.com/legal/licensing"
*/
package org.alfresco.repo.cmis.rest;
import java.io.IOException;
import java.io.StringReader;
import javax.xml.XMLConstants;
import javax.xml.parsers.DocumentBuilder;
import javax.xml.parsers.DocumentBuilderFactory;
import javax.xml.parsers.ParserConfigurationException;
import javax.xml.transform.Source;
import javax.xml.transform.dom.DOMSource;
import javax.xml.transform.stream.StreamSource;
import javax.xml.validation.Schema;
import javax.xml.validation.SchemaFactory;
import javax.xml.validation.Validator;
import org.alfresco.repo.web.scripts.BaseWebScriptTest;
import org.springframework.core.io.ClassPathResource;
import org.w3c.dom.Document;
import org.xml.sax.InputSource;
import org.xml.sax.SAXException;
/**
* Base CMIS Web Script Test
*
* @author davidc
*/
public class CMISWebScriptTest extends BaseWebScriptTest
{
/** XML Schema Validation */
private static DocumentBuilder documentBuilder = null;
private static Validator appValidator = null;
private static Validator atomValidator = null;
/**
* Gets document parser
*
* @return document parser
* @throws ParserConfigurationException
*/
protected static DocumentBuilder getDocumentBuilder()
throws ParserConfigurationException
{
if (documentBuilder == null)
{
DocumentBuilderFactory builderFactory = DocumentBuilderFactory.newInstance();
builderFactory.setNamespaceAware(true);
documentBuilder = builderFactory.newDocumentBuilder();
}
return documentBuilder;
}
/**
* Gets CMIS Atom Publishing Protocol XML Validator
*
* @return APP Validator
* @throws IOException
* @throws SAXException
*/
protected static Validator getAppValidator()
throws IOException, SAXException
{
if (appValidator == null)
{
SchemaFactory factory = SchemaFactory.newInstance(XMLConstants.W3C_XML_SCHEMA_NS_URI);
Source schemaFile = new StreamSource(new ClassPathResource("org/alfresco/repo/cmis/rest/xsd/APP.xsd").getFile());
Schema schema = factory.newSchema(schemaFile);
appValidator = schema.newValidator();
}
return appValidator;
}
/**
* Gets CMIS Atom Validator
*
* @return CMIS Atom Validator
* @throws IOException
* @throws SAXException
*/
protected static Validator getCMISAtomValidator()
throws IOException, SAXException
{
if (atomValidator == null)
{
SchemaFactory factory = SchemaFactory.newInstance(XMLConstants.W3C_XML_SCHEMA_NS_URI);
Source schemaFile = new StreamSource(new ClassPathResource("org/alfresco/repo/cmis/rest/xsd/ATOM4CMIS.xsd").getFile());
Schema schema = factory.newSchema(schemaFile);
atomValidator = schema.newValidator();
}
return atomValidator;
}
/**
* Asserts XML complies with specified Validator
*
* @param xml xml to assert
* @param validator validator to assert with
* @throws IOException
* @throws ParserConfigurationException
*/
public void assertValidXML(String xml, Validator validator)
throws IOException, ParserConfigurationException
{
try
{
Document document = getDocumentBuilder().parse(new InputSource(new StringReader(xml)));
validator.validate(new DOMSource(document));
}
catch (SAXException e)
{
fail(e.toString() + "\n\n" + xml);
}
}
/**
public static void main(String[] args) throws IOException, ParserConfigurationException
{
try
{
Document document = getDocumentBuilder().parse(new ClassPathResource("test.xml").getFile());
getAppValidator().validate(new DOMSource(document));
}
catch (SAXException e)
{
fail(e.toString());
}
}
*/
}

View File

@@ -0,0 +1,44 @@
/*
* Copyright (C) 2005-2008 Alfresco Software Limited.
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
* As a special exception to the terms and conditions of version 2.0 of
* the GPL, you may redistribute this Program in connection with Free/Libre
* and Open Source Software ("FLOSS") applications as described in Alfresco's
* FLOSS exception. You should have recieved a copy of the text describing
* the FLOSS exception, and it is also available here:
* http://www.alfresco.com/legal/licensing"
*/
package org.alfresco.repo.cmis.rest;
import org.springframework.mock.web.MockHttpServletResponse;
/**
* CMIS API Test Harness
*
* @author davidc
*/
public class TestCMIS extends CMISWebScriptTest
{
public void testRepository() throws Exception
{
MockHttpServletResponse res = getRequest("/api/repository", 200);
assertValidXML(res.getContentAsString(), getAppValidator());
}
}

View File

@@ -0,0 +1,54 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
-*- rnc -*-
RELAX NG Compact Syntax Grammar for the
Atom Format Specification Version 11
-->
<xs:schema
xmlns:xs="http://www.w3.org/2001/XMLSchema"
elementFormDefault="qualified"
targetNamespace="http://www.w3.org/2007/app"
xmlns:atom="http://www.w3.org/2005/Atom"
xmlns:app="http://www.w3.org/2007/app"
xmlns:cmis="http://www.cmis.org/2008/05"
>
<xs:import namespace="http://www.w3.org/2005/Atom" schemaLocation="ATOM4CMIS.xsd"/>
<xs:import namespace="http://www.cmis.org/2008/05" schemaLocation="CMIS REST.xsd"/>
<xs:element name="service" type="app:appServiceType"></xs:element>
<xs:complexType name="appServiceType">
<xs:sequence>
<!-- <xs:element ref="atom:author"></xs:element> -->
<xs:element ref="app:workspace" minOccurs="1" maxOccurs="unbounded"></xs:element>
</xs:sequence>
</xs:complexType>
<xs:element name="workspace" type="app:appWorkspaceType"></xs:element>
<xs:complexType name="appWorkspaceType">
<xs:sequence>
<xs:element ref="atom:title"></xs:element>
<xs:element ref="cmis:repositoryInfo" minOccurs="0" maxOccurs="1"></xs:element>
<xs:element ref="app:collection" minOccurs="0" maxOccurs="unbounded"></xs:element>
</xs:sequence>
<xs:attribute ref="cmis:id"></xs:attribute>
<xs:attribute ref="cmis:repositoryRelationship"></xs:attribute>
</xs:complexType>
<xs:element name="collection" type="app:appCollectionType"></xs:element>
<xs:complexType name="appCollectionType">
<xs:sequence>
<xs:element ref="atom:title"></xs:element>
</xs:sequence>
<xs:attribute name="href" type="xs:anyURI" use="required"></xs:attribute>
<xs:attribute ref="cmis:id"></xs:attribute>
<xs:attribute ref="cmis:collectionType"></xs:attribute>
</xs:complexType>
<!-- <xs:attribute name="href" type="xs:anyURI"></xs:attribute> -->
</xs:schema>
<!-- EOF -->

View File

@@ -0,0 +1,442 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
-*- rnc -*-
RELAX NG Compact Syntax Grammar for the
Atom Format Specification Version 11
-->
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
elementFormDefault="qualified"
targetNamespace="http://www.w3.org/2005/Atom"
xmlns:atom="http://www.w3.org/2005/Atom"
xmlns:xhtml="http://www.w3.org/1999/xhtml"
xmlns:cmis="http://www.cmis.org/2008/05"
xmlns:xml="http://www.w3.org/XML/1998/namespace"
>
<xs:import namespace="http://www.w3.org/1999/xhtml" schemaLocation="xhtml1-strict.xsd"/>
<xs:import namespace="http://www.w3.org/XML/1998/namespace" schemaLocation="xml.xsd"/>
<xs:import namespace="http://www.cmis.org/2008/05" schemaLocation="CMIS REST.xsd"/>
<!-- Common attributes -->
<xs:attributeGroup name="atomCommonAttributes">
<xs:attribute ref="xml:base"/>
<xs:attribute ref="xml:lang"/>
<xs:attributeGroup ref="atom:undefinedAttribute"/>
</xs:attributeGroup>
<!-- Text Constructs -->
<xs:attributeGroup name="atomPlainTextConstruct">
<xs:attributeGroup ref="atom:atomCommonAttributes"/>
<xs:attribute name="type">
<xs:simpleType>
<xs:restriction base="xs:token">
<xs:enumeration value="text"/>
<xs:enumeration value="html"/>
</xs:restriction>
</xs:simpleType>
</xs:attribute>
</xs:attributeGroup>
<xs:group name="atomXHTMLTextConstruct">
<xs:sequence>
<xs:element ref="xhtml:div"/>
</xs:sequence>
</xs:group>
<xs:attributeGroup name="atomXHTMLTextConstruct">
<xs:attributeGroup ref="atom:atomCommonAttributes"/>
<xs:attribute name="type" use="required">
<xs:simpleType>
<xs:restriction base="xs:token">
<xs:enumeration value="xhtml"/>
</xs:restriction>
</xs:simpleType>
</xs:attribute>
</xs:attributeGroup>
<xs:complexType name="atomTextConstruct" mixed="true">
<xs:group minOccurs="0" ref="atom:atomXHTMLTextConstruct"/>
<xs:attribute name="type">
<xs:simpleType>
<xs:restriction base="xs:token">
<xs:enumeration value="text"/>
<xs:enumeration value="html"/>
<xs:enumeration value="xhtml"/>
</xs:restriction>
</xs:simpleType>
</xs:attribute>
<xs:attributeGroup ref="atom:atomCommonAttributes"/>
</xs:complexType>
<!-- Person Construct -->
<xs:complexType name="atomPersonConstruct">
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element ref="atom:name"/>
<xs:element ref="atom:uri"/>
<xs:element ref="atom:email"/>
<xs:group ref="atom:extensionElement"/>
</xs:choice>
<xs:attributeGroup ref="atom:atomCommonAttributes"/>
</xs:complexType>
<xs:element name="name" type="xs:string"/>
<xs:element name="uri" type="xs:string"/>
<xs:element name="email" type="atom:atomEmailAddress"/>
<!-- Date Construct -->
<xs:complexType name="atomDateConstruct">
<xs:simpleContent>
<xs:extension base="xs:dateTime">
<xs:attributeGroup ref="atom:atomCommonAttributes"/>
</xs:extension>
</xs:simpleContent>
</xs:complexType>
<!-- atom:feed -->
<xs:element name="feed">
<xs:complexType>
<xs:sequence>
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element ref="atom:author"/>
<xs:element ref="atom:category"/>
<xs:element ref="atom:contributor"/>
<xs:element ref="atom:generator"/>
<xs:element ref="atom:icon"/>
<xs:element ref="atom:id"/>
<xs:element ref="atom:link"/>
<xs:element ref="atom:logo"/>
<xs:element ref="atom:rights"/>
<xs:element ref="atom:subtitle"/>
<xs:element ref="atom:title"/>
<xs:element ref="atom:updated"/>
<xs:group ref="atom:extensionElement"/>
</xs:choice>
<xs:element minOccurs="0" maxOccurs="unbounded" ref="atom:entry"/>
<!--
<xs:choice minOccurs="0" maxOccurs="1">
<xs:group ref="cmis:CMISFolderEntry" />
<xs:group ref="cmis:CMISTypeEntry" />
</xs:choice> -->
<xs:element minOccurs="0" maxOccurs="1" ref="cmis:hasMoreItems"/>
</xs:sequence>
<xs:attributeGroup ref="atom:atomCommonAttributes"/>
</xs:complexType>
</xs:element>
<!-- atom:entry -->
<xs:element name="entry" type="atom:entryType">
</xs:element>
<xs:complexType name="entryType">
<xs:sequence>
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element ref="atom:author" />
<xs:element ref="atom:category" />
<xs:element ref="atom:content" />
<xs:element ref="atom:contributor" />
<xs:element ref="atom:id" />
<xs:element ref="atom:link" />
<xs:element ref="atom:published" />
<xs:element ref="atom:rights" />
<xs:element ref="atom:source" />
<xs:element ref="atom:summary" />
<xs:element ref="atom:title" />
<xs:element ref="atom:updated" />
<xs:group ref="atom:extensionElement" />
<xs:element ref="atom:uri"></xs:element>
</xs:choice>
<!--
<xs:choice minOccurs="0" maxOccurs="1">
<xs:group ref="cmis:CMISDocumentEntry" />
<xs:group ref="cmis:CMISFolderEntry" />
<xs:group ref="cmis:CMISRelationshipEntry" />
<xs:group ref="cmis:CMISPolicyEntry" />
<xs:group ref="cmis:CMISActionsEntry" />
<xs:group ref="cmis:CMISTypeEntry" />
</xs:choice> -->
</xs:sequence>
<xs:attributeGroup ref="atom:atomCommonAttributes"/>
</xs:complexType>
<!-- atom:content -->
<xs:attributeGroup name="atomInlineTextConstruct">
<xs:attributeGroup ref="atom:atomCommonAttributes"/>
<xs:attribute name="type">
<xs:simpleType>
<xs:restriction base="xs:token">
<xs:enumeration value="text"/>
<xs:enumeration value="html"/>
</xs:restriction>
</xs:simpleType>
</xs:attribute>
</xs:attributeGroup>
<xs:group name="atomInlineOtherConstruct">
<xs:sequence>
<xs:group minOccurs="0" maxOccurs="unbounded" ref="atom:anyElement"/>
</xs:sequence>
</xs:group>
<xs:attributeGroup name="atomInlineOtherConstruct">
<xs:attributeGroup ref="atom:atomCommonAttributes"/>
<xs:attribute name="type">
<xs:simpleType>
<xs:union memberTypes="atom:atomMediaType">
<xs:simpleType>
<xs:restriction base="xs:token">
<xs:enumeration value="xhtml"/>
</xs:restriction>
</xs:simpleType>
</xs:union>
</xs:simpleType>
</xs:attribute>
</xs:attributeGroup>
<xs:attributeGroup name="atomOutOfLineConstruct">
<xs:attributeGroup ref="atom:atomCommonAttributes"/>
<xs:attribute name="type" type="atom:atomMediaType"/>
<xs:attribute name="src" use="required"/>
</xs:attributeGroup>
<xs:element name="content">
<xs:complexType mixed="true">
<xs:group minOccurs="0" ref="atom:atomInlineOtherConstruct"/>
<xs:attribute name="type">
<xs:simpleType>
<xs:union memberTypes="atom:atomMediaType">
<xs:simpleType>
<xs:restriction base="xs:token">
<xs:enumeration value="text"/>
<xs:enumeration value="html"/>
</xs:restriction>
</xs:simpleType>
<xs:simpleType>
<xs:union memberTypes="atom:atomMediaType">
<xs:simpleType>
<xs:restriction base="xs:token">
<xs:enumeration value="xhtml"/>
</xs:restriction>
</xs:simpleType>
</xs:union>
</xs:simpleType>
</xs:union>
</xs:simpleType>
</xs:attribute>
<xs:attributeGroup ref="atom:atomCommonAttributes"/>
<xs:attribute name="src"/>
</xs:complexType>
</xs:element>
<!-- atom:author -->
<xs:element name="author" type="atom:atomPersonConstruct"/>
<!-- atom:category -->
<xs:element name="category">
<xs:complexType>
<xs:complexContent>
<xs:extension base="atom:undefinedContent">
<xs:attributeGroup ref="atom:atomCommonAttributes"/>
<xs:attribute name="term" use="required"/>
<xs:attribute name="scheme"/>
<xs:attribute name="label"/>
</xs:extension>
</xs:complexContent>
</xs:complexType>
</xs:element>
<!-- atom:contributor -->
<xs:element name="contributor" type="atom:atomPersonConstruct"/>
<!-- atom:generator -->
<xs:element name="generator">
<xs:complexType mixed="true">
<xs:attributeGroup ref="atom:atomCommonAttributes"/>
<xs:attribute name="uri"/>
<xs:attribute name="version"/>
</xs:complexType>
</xs:element>
<!-- atom:icon -->
<xs:element name="icon">
<xs:complexType mixed="true">
<xs:attributeGroup ref="atom:atomCommonAttributes"/>
</xs:complexType>
</xs:element>
<!-- atom:id -->
<xs:element name="id">
<xs:complexType mixed="true">
<xs:attributeGroup ref="atom:atomCommonAttributes"/>
</xs:complexType>
</xs:element>
<!-- atom:logo -->
<xs:element name="logo">
<xs:complexType mixed="true">
<xs:attributeGroup ref="atom:atomCommonAttributes"/>
</xs:complexType>
</xs:element>
<!-- atom:link -->
<xs:element name="link">
<xs:annotation>
<xs:documentation>
The "atom:link" element defines a reference from an entry
or feed to a Web resource. This specification assigns no
meaning to the content (if any) of this element.
</xs:documentation>
</xs:annotation>
<xs:complexType>
<xs:complexContent>
<xs:extension base="atom:undefinedContent">
<xs:attributeGroup ref="atom:atomCommonAttributes" />
<xs:attribute name="href" use="required" />
<xs:attribute name="rel">
</xs:attribute>
<xs:attribute name="type" type="atom:atomMediaType" />
<xs:attribute name="hreflang"
type="atom:atomLanguageTag" />
<xs:attribute name="title" />
<xs:attribute name="length" />
</xs:extension>
</xs:complexContent>
</xs:complexType>
</xs:element>
<!-- atom:published -->
<xs:element name="published" type="atom:atomDateConstruct"/>
<!-- atom:rights -->
<xs:element name="rights" type="atom:atomTextConstruct"/>
<!-- atom:source -->
<xs:element name="source">
<xs:annotation>
<xs:documentation>
atom:source is used to preserve metadata of a feed when an entry is copied from a feed to another feed.
</xs:documentation>
</xs:annotation>
<xs:complexType>
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element ref="atom:author"/>
<xs:element ref="atom:category"/>
<xs:element ref="atom:contributor"/>
<xs:element ref="atom:generator"/>
<xs:element ref="atom:icon"/>
<xs:element ref="atom:id"/>
<xs:element ref="atom:link"/>
<xs:element ref="atom:logo"/>
<xs:element ref="atom:rights"/>
<xs:element ref="atom:subtitle"/>
<xs:element ref="atom:title"/>
<xs:element ref="atom:updated"/>
<xs:group ref="atom:extensionElement"/>
</xs:choice>
<xs:attributeGroup ref="atom:atomCommonAttributes"/>
</xs:complexType>
</xs:element>
<!-- atom:subtitle -->
<xs:element name="subtitle" type="atom:atomTextConstruct"/>
<!-- atom:summary -->
<xs:element name="summary" type="atom:atomTextConstruct"/>
<!-- atom:title -->
<xs:element name="title" type="atom:atomTextConstruct">
<xs:annotation>
<xs:documentation>
The "atom:title" element is a Text construct that conveys a human-
readable title for an entry or feed.
atomTitle = element atom:title { atomTextConstruct }.
</xs:documentation>
</xs:annotation>
</xs:element>
<!-- atom:updated -->
<xs:element name="updated" type="atom:atomDateConstruct">
<xs:annotation>
<xs:documentation>
The "atom:updated" element is a Date construct indicating the most
recent instant in time when an entry or feed was modified in a way
the publisher considers significant. Therefore, not all
modifications necessarily result in a changed atom:updated value.
atomUpdated = element atom:updated { atomDateConstruct }.
Publishers MAY change the value of this element over time.
</xs:documentation>
</xs:annotation>
</xs:element>
<!-- Low-level simple types -->
<xs:simpleType name="atomNCName">
<xs:restriction base="xs:string">
<xs:minLength value="1"/>
<xs:pattern value="[^:]*"/>
</xs:restriction>
</xs:simpleType>
<!-- Whatever a media type is, it contains at least one slash -->
<xs:simpleType name="atomMediaType">
<xs:restriction base="xs:string">
<xs:pattern value=".+/.+"/>
</xs:restriction>
</xs:simpleType>
<!-- As defined in RFC 3066 -->
<xs:simpleType name="atomLanguageTag">
<xs:restriction base="xs:string">
<xs:pattern value="[A-Za-z]{1,8}(-[A-Za-z0-9]{1,8})*"/>
</xs:restriction>
</xs:simpleType>
<!--
Unconstrained; it's not entirely clear how IRI fit into
xsd:anyURI so let's not try to constrain it here
-->
<!-- Whatever an email address is, it contains at least one @ -->
<xs:simpleType name="atomEmailAddress">
<xs:restriction base="xs:string">
<xs:pattern value=".+@.+"/>
</xs:restriction>
</xs:simpleType>
<!-- Simple Extension -->
<xs:group name="extensionElement">
<xs:choice>
<xs:any namespace="##other" processContents="skip"/>
<xs:any namespace="##local" processContents="skip"/>
</xs:choice>
</xs:group>
<xs:attributeGroup name="undefinedAttribute">
<xs:anyAttribute namespace="##other" processContents="skip"/>
</xs:attributeGroup>
<xs:complexType name="undefinedContent" mixed="true">
<xs:group minOccurs="0" maxOccurs="unbounded" ref="atom:anyForeignElement"/>
</xs:complexType>
<xs:group name="anyElement">
<xs:sequence>
<xs:any processContents="skip"/>
</xs:sequence>
</xs:group>
<xs:group name="anyForeignElement">
<xs:choice>
<xs:any namespace="##other" processContents="skip"/>
<xs:any namespace="##local" processContents="skip"/>
</xs:choice>
</xs:group>
<!-- XHTML -->
<xs:group name="anyXHTML">
<xs:sequence>
<xs:any namespace="http://www.w3.org/1999/xhtml" processContents="skip"/>
</xs:sequence>
</xs:group>
<xs:element name="service" type="atom:atomServiceType"></xs:element>
<xs:complexType name="atomServiceType">
<xs:sequence>
<xs:element ref="atom:author"></xs:element>
</xs:sequence>
</xs:complexType>
<xs:element name="workspace" type="atom:atomWorkspaceType"></xs:element>
<xs:complexType name="atomWorkspaceType">
<xs:sequence>
<xs:element ref="atom:title"></xs:element>
<xs:element ref="cmis:repositoryInfo"></xs:element>
</xs:sequence>
<xs:attribute ref="cmis:id"></xs:attribute>
</xs:complexType>
<xs:element name="collection" type="xs:string"></xs:element>
<xs:complexType name="atomCollectionType">
<xs:sequence>
<xs:element ref="atom:title"></xs:element>
</xs:sequence>
<xs:attribute ref="cmis:id"></xs:attribute>
<xs:attribute ref="cmis:collectionType"></xs:attribute>
</xs:complexType>
</xs:schema>
<!-- EOF -->

View File

@@ -0,0 +1,636 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
-*- rnc -*-
RELAX NG Compact Syntax Grammar for the
Atom Format Specification Version 11
-->
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
elementFormDefault="qualified"
targetNamespace="http://www.cmis.org/2008/05"
xmlns:atom="http://www.w3.org/2005/Atom"
xmlns:xhtml="http://www.w3.org/1999/xhtml"
xmlns:cmis="http://www.cmis.org/2008/05">
<xs:import namespace="http://www.w3.org/1999/xhtml" />
<xs:import namespace="http://www.w3.org/XML/1998/namespace" />
<xs:element name="repositoryInfo" type="cmis:repositoryInfoType"></xs:element>
<xs:element name="property" type="cmis:propertyDefinitionType"></xs:element>
<xs:element name="parent" type="xs:string"></xs:element>
<xs:element name="displayName" type="xs:string"></xs:element>
<xs:element name="isVersionable" type="xs:boolean"></xs:element>
<xs:element name="description" type="xs:string"></xs:element>
<xs:element name="isQueryable" type="xs:string"></xs:element>
<xs:element name="isCreatable" type="xs:string"></xs:element>
<xs:element name="queryName" type="xs:string"></xs:element>
<xs:element name="baseTypeQueryName" type="xs:string"></xs:element>
<xs:element name="isContentStreamAllowed" type="xs:boolean"></xs:element>
<xs:element name="AllowedSourceTypes" type="xs:string"></xs:element>
<xs:element name="AllowedTargetTypes" type="xs:string"></xs:element>
<xs:element name="constraints" type="xs:string"></xs:element>
<xs:element name="propertyType">
<xs:simpleType>
<xs:restriction base="xs:string">
<xs:enumeration value="String"></xs:enumeration>
<xs:enumeration value="Decimal"></xs:enumeration>
<xs:enumeration value="Integer"></xs:enumeration>
<xs:enumeration value="Boolean"></xs:enumeration>
<xs:enumeration value="DateTime"></xs:enumeration>
<xs:enumeration value="URI"></xs:enumeration>
<xs:enumeration value="HTML"></xs:enumeration>
<xs:enumeration value="XML"></xs:enumeration>
<xs:enumeration value="ID"></xs:enumeration>
<xs:enumeration value="TypeID"></xs:enumeration>
</xs:restriction>
</xs:simpleType>
</xs:element>
<xs:element name="cardinality">
<xs:simpleType>
<xs:restriction base="xs:string">
<xs:enumeration value="Single"></xs:enumeration>
<xs:enumeration value="Multi"></xs:enumeration>
</xs:restriction>
</xs:simpleType>
</xs:element>
<xs:element name="maxLength" type="xs:int"></xs:element>
<xs:element name="schemaURI" type="xs:string"></xs:element>
<xs:element name="encoding" type="xs:string"></xs:element>
<xs:element name="choices">
<xs:complexType>
<xs:simpleContent>
<xs:extension base="xs:string">
<xs:attribute name="index"
type="xs:positiveInteger" />
</xs:extension>
</xs:simpleContent>
</xs:complexType>
</xs:element>
<xs:element name="isOpenChoice" type="xs:boolean"></xs:element>
<xs:element name="isRequired" type="xs:boolean"></xs:element>
<xs:element name="defaultValue" type="xs:string"></xs:element>
<xs:element name="updateability">
<xs:simpleType>
<xs:restriction base="xs:string">
<xs:enumeration value="ro"></xs:enumeration>
<xs:enumeration value="rw"></xs:enumeration>
<xs:enumeration value="checkedout"></xs:enumeration>
</xs:restriction>
</xs:simpleType>
</xs:element>
<xs:complexType name="repositoryInfoType">
<xs:sequence minOccurs="1">
<xs:element name="repositoryId" type="xs:string"
minOccurs="1">
</xs:element>
<xs:element name="repositoryName" type="xs:string"
minOccurs="1">
</xs:element>
<xs:element name="repositoryDescription" type="xs:string"
minOccurs="1">
</xs:element>
<xs:element name="vendorName" type="xs:string"></xs:element>
<xs:element name="productName" type="xs:string"></xs:element>
<xs:element name="productVersion" type="xs:string"></xs:element>
<xs:element name="capabilities"
type="cmis:RepositoryInfoCapabilities">
</xs:element>
<xs:element name="repositorySpecificInformation"
type="xs:string" maxOccurs="1" minOccurs="0">
</xs:element>
<!--
<xs:any namespace="##any" processContents="skip"
minOccurs="0" maxOccurs="unbounded">
</xs:any> -->
</xs:sequence>
</xs:complexType>
<xs:complexType name="RepositoryInfoCapabilities">
<xs:sequence>
<xs:element name="capabilityMultifiling" type="xs:boolean"
minOccurs="1" maxOccurs="1">
</xs:element>
<xs:element name="capabilityUnfiling" type="xs:boolean"
minOccurs="1" maxOccurs="1">
</xs:element>
<xs:element name="capabilityVersionSpecificFiling"
type="xs:boolean" minOccurs="1" maxOccurs="1">
</xs:element>
<xs:element name="capabilityPWCUpdateable" type="xs:boolean"
minOccurs="1" maxOccurs="1">
</xs:element>
<xs:element name="capabilityAllVersionsSearchable"
type="xs:boolean" minOccurs="1" maxOccurs="1">
</xs:element>
<xs:element name="capabilityInnerJoin" type="xs:boolean"
minOccurs="1" maxOccurs="1">
</xs:element>
<xs:element name="capabilityOuterJoin" type="xs:boolean"
minOccurs="1" maxOccurs="1">
</xs:element>
<xs:element name="capabilityFullText">
<xs:simpleType>
<xs:restriction base="xs:string">
<xs:enumeration value="none"></xs:enumeration>
<xs:enumeration value="fulltextonly"></xs:enumeration>
<xs:enumeration value="fulltextwithmetadata"></xs:enumeration>
</xs:restriction>
</xs:simpleType>
</xs:element>
</xs:sequence>
</xs:complexType>
<xs:attribute name="id" type="xs:string"></xs:attribute>
<xs:attribute name="index" type="xs:int"></xs:attribute>
<xs:element name="creationDate" type="xs:dateTime"></xs:element>
<xs:element name="lastModifiedBy" type="xs:dateTime"></xs:element>
<xs:element name="baseType" type="cmis:baseObjectType"></xs:element>
<xs:simpleType name="baseObjectType">
<xs:restriction base="xs:string">
<xs:enumeration value="document"></xs:enumeration>
<xs:enumeration value="folder"></xs:enumeration>
<xs:enumeration value="relationship"></xs:enumeration>
<xs:enumeration value="policy"></xs:enumeration>
</xs:restriction>
</xs:simpleType>
<xs:element name="objectType" type="xs:string"></xs:element>
<xs:element name="isLatestVersion" type="xs:boolean"></xs:element>
<xs:element name="isCheckedOut" type="xs:boolean"></xs:element>
<xs:element name="contentStreamLength" type="xs:int"></xs:element>
<xs:element name="contentStreamMimetype">
<xs:simpleType>
<xs:restriction base="xs:string">
<xs:pattern value=".*/.*"></xs:pattern>
</xs:restriction>
</xs:simpleType>
</xs:element>
<xs:element name="contentStreamName" type="xs:string"></xs:element>
<xs:element name="contentStreamURI" type="xs:string"></xs:element>
<xs:group name="entryCommonElements">
<xs:sequence>
<xs:element ref="cmis:baseType" minOccurs="1"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:lastModifiedBy" minOccurs="1"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:creationDate" minOccurs="1"
maxOccurs="1">
</xs:element>
</xs:sequence>
</xs:group>
<xs:group name="entryContentStreamElements">
<xs:sequence>
<xs:element ref="cmis:contentStreamLength"></xs:element>
<xs:element ref="cmis:contentStreamMimetype"></xs:element>
<xs:element ref="cmis:contentStreamName"></xs:element>
<xs:element ref="cmis:contentStreamURI"></xs:element>
</xs:sequence>
</xs:group>
<xs:group name="propertyDefinitionElements">
<xs:sequence>
<xs:element ref="cmis:displayName" minOccurs="1"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:description" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:propertyType" minOccurs="1"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:cardinality" minOccurs="1"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:maxLength" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:schemaURI" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:encoding" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:choices" minOccurs="0"
maxOccurs="unbounded">
</xs:element>
<xs:element ref="cmis:isOpenChoice" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:isRequired" minOccurs="1"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:defaultValue" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:updateability" minOccurs="1"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:isQueryable" minOccurs="1"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:isOrderable" minOccurs="1"
maxOccurs="1">
</xs:element>
</xs:sequence>
</xs:group>
<xs:element name="isOrderable" type="xs:boolean"></xs:element>
<xs:complexType name="propertyDefinitionType">
<xs:sequence>
<xs:element ref="cmis:displayName" minOccurs="1"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:description" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:propertyType" minOccurs="1"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:cardinality" minOccurs="1"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:maxLength" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:schemaURI" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:encoding" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:choices" minOccurs="0"
maxOccurs="unbounded">
</xs:element>
<xs:element ref="cmis:isOpenChoice" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:isRequired" minOccurs="1"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:defaultValue" minOccurs="0"
maxOccurs="unbounded">
</xs:element>
<xs:element ref="cmis:updateability" minOccurs="1"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:isQueryable" minOccurs="1"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:isOrderable" minOccurs="1"
maxOccurs="1">
</xs:element>
</xs:sequence>
<xs:attribute ref="cmis:id"></xs:attribute>
</xs:complexType>
<xs:element name="canDelete" type="xs:boolean"></xs:element>
<xs:element name="canUpdateProperties" type="xs:boolean"></xs:element>
<xs:element name="canGetProperties" type="xs:boolean"></xs:element>
<xs:element name="canGetParents" type="xs:boolean"></xs:element>
<xs:element name="canMove" type="xs:boolean"></xs:element>
<xs:element name="canDeleteVersion" type="xs:boolean"></xs:element>
<xs:element name="canDeleteContent" type="xs:boolean"></xs:element>
<xs:element name="canCheckout" type="xs:boolean"></xs:element>
<xs:element name="canCancelCheckout" type="xs:boolean"></xs:element>
<xs:element name="canCheckin" type="xs:boolean"></xs:element>
<xs:element name="canSetContent" type="xs:boolean"></xs:element>
<xs:element name="canGetAllVersions" type="xs:boolean"></xs:element>
<xs:element name="canAddToFolder" type="xs:boolean"></xs:element>
<xs:element name="canRemoveFromFolder" type="xs:boolean"></xs:element>
<xs:element name="canViewContent" type="xs:boolean"></xs:element>
<xs:element name="canAddPolicy" type="xs:boolean"></xs:element>
<xs:element name="canRemovePolicy" type="xs:boolean"></xs:element>
<xs:element name="canGetChildren" type="xs:boolean"></xs:element>
<xs:element name="canGetDescendants" type="xs:boolean"></xs:element>
<xs:element name="isControllable" type="xs:boolean"></xs:element>
<xs:element name="source" type="xs:string"></xs:element>
<xs:element name="target" type="xs:string"></xs:element>
<xs:element name="isImmutable" type="xs:boolean"></xs:element>
<xs:element name="isMajorVersion" type="xs:boolean"></xs:element>
<xs:element name="isLatestMajorVersion" type="xs:boolean"></xs:element>
<xs:element name="isVersionSeriesCheckedOut" type="xs:boolean"></xs:element>
<xs:element name="versionSeriesCheckedOutBy" type="xs:string"></xs:element>
<xs:element name="versionSeriesCheckedOutID" type="xs:string"></xs:element>
<xs:element name="checkinComment" type="xs:string"></xs:element>
<xs:group name="CMISActionsEntry">
<xs:sequence>
<xs:element ref="cmis:canDelete" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:canUpdateProperties" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:canGetProperties" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:canGetParents" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:canGetDescendants" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:canMove" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:canDeleteVersion" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:canDeleteContent" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:canCheckout" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:canCancelCheckout" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:canCheckin" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:canSetContent" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:canGetAllVersions" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:canAddToFolder" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:canRemoveFromFolder" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:canViewContent" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:canAddPolicy" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:canRemovePolicy" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:canGetChildren" minOccurs="0"
maxOccurs="1">
</xs:element>
</xs:sequence>
</xs:group>
<xs:group name="CMISTypeEntry">
<xs:sequence>
<xs:group ref="cmis:entryCommonElements" minOccurs="1"
maxOccurs="1">
</xs:group>
<xs:element ref="cmis:queryName" minOccurs="1"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:displayName" minOccurs="1"
maxOccurs="1">
</xs:element>
<!--
<xs:element ref="cmis:baseType" minOccurs="1"
maxOccurs="1">
</xs:element> -->
<xs:element ref="cmis:baseTypeQueryName" minOccurs="1"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:parent" minOccurs="1" maxOccurs="1"></xs:element>
<xs:element ref="cmis:description" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:isCreatable" minOccurs="1"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:isVersionable" minOccurs="1"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:isQueryable" minOccurs="1"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:isContentStreamAllowed" minOccurs="1"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:AllowedSourceTypes" minOccurs="1" maxOccurs="1">
</xs:element>
<xs:element ref="cmis:AllowedTargetTypes" minOccurs="1" maxOccurs="1">
</xs:element>
<xs:element ref="cmis:constraints" minOccurs="0"
maxOccurs="unbounded">
</xs:element>
<xs:element ref="cmis:property"></xs:element>
<xs:element ref="cmis:isControllable"></xs:element>
</xs:sequence>
</xs:group>
<xs:group name="CMISDocumentEntry">
<xs:sequence>
<xs:group ref="cmis:entryCommonElements" minOccurs="1"
maxOccurs="1">
</xs:group>
<xs:element ref="cmis:objectType" minOccurs="1"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:isCheckedOut" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:isLatestVersion" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:isMajorVersion" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:isLatestMajorVersion" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:isImmutable" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:isVersionSeriesCheckedOut" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:versionSeriesCheckedOutBy" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:versionSeriesCheckedOutID" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:checkinComment" minOccurs="1"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:versionLabel" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:group ref="cmis:entryContentStreamElements"
minOccurs="0" maxOccurs="1">
</xs:group>
<xs:element ref="cmis:allowableActions" minOccurs="0"
maxOccurs="1">
</xs:element>
</xs:sequence>
</xs:group>
<xs:group name="CMISFolderEntry">
<xs:sequence>
<xs:group ref="cmis:entryCommonElements" minOccurs="1"
maxOccurs="1">
</xs:group>
<xs:element ref="cmis:objectType" minOccurs="1"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:parent" minOccurs="1" maxOccurs="1"></xs:element>
<xs:element ref="cmis:allowableActions" minOccurs="0"
maxOccurs="1">
</xs:element>
</xs:sequence>
</xs:group>
<xs:group name="CMISRelationshipEntry">
<xs:sequence>
<xs:group ref="cmis:entryCommonElements" minOccurs="1"
maxOccurs="1">
</xs:group>
<xs:element ref="cmis:objectType" minOccurs="1"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:source" minOccurs="1"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:target" minOccurs="1"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:allowableActions" minOccurs="0"
maxOccurs="1">
</xs:element>
</xs:sequence>
</xs:group>
<xs:group name="CMISPolicyEntry">
<xs:sequence>
<xs:group ref="cmis:entryCommonElements" minOccurs="1"
maxOccurs="1">
</xs:group>
<xs:element ref="cmis:objectType" minOccurs="1"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:allowableActions" minOccurs="0"
maxOccurs="1">
</xs:element>
</xs:sequence>
</xs:group>
<xs:element name="function" type="xs:string"></xs:element>
<xs:element name="hasMoreItems" type="xs:boolean"></xs:element>
<xs:element name="allowableActions" type="cmis:allowableActions"></xs:element>
<xs:complexType name="allowableActions">
<xs:sequence maxOccurs="1" minOccurs="1">
<xs:group ref="cmis:CMISActionsEntry"></xs:group>
</xs:sequence>
</xs:complexType>
<xs:element name="versionLabel" type="xs:string"></xs:element>
<xs:element name="query" type="cmis:queryType"></xs:element>
<xs:complexType name="queryType">
<xs:sequence>
<xs:element ref="cmis:statement" minOccurs="1" maxOccurs="1"></xs:element>
<xs:element ref="cmis:searchAllVersions" minOccurs="0" maxOccurs="1"></xs:element>
<xs:element ref="cmis:pageSize" minOccurs="0" maxOccurs="1"></xs:element>
<xs:element ref="cmis:skipCount" minOccurs="0" maxOccurs="1"></xs:element>
<xs:element ref="cmis:returnAllowableActions" minOccurs="0" maxOccurs="1"></xs:element>
</xs:sequence>
</xs:complexType>
<xs:element name="statement" type="xs:string"></xs:element>
<xs:element name="pageSize" type="xs:int"></xs:element>
<xs:element name="skipCount" type="xs:int"></xs:element>
<xs:element name="returnAllowableActions" type="xs:boolean"></xs:element>
<xs:element name="searchAllVersions" type="xs:boolean"></xs:element>
<xs:attribute name="collectionType">
<xs:simpleType>
<xs:restriction base="xs:string">
<xs:enumeration value="root"></xs:enumeration>
<xs:enumeration value="unfiled"></xs:enumeration>
<xs:enumeration value="checkedout"></xs:enumeration>
<xs:enumeration value="types"></xs:enumeration>
</xs:restriction>
</xs:simpleType>
</xs:attribute>
<xs:attribute name="repositoryRelationship">
<xs:simpleType>
<xs:restriction base="xs:string">
<xs:enumeration value="self"></xs:enumeration>
<xs:enumeration value="sibling"></xs:enumeration>
<xs:enumeration value="parent"></xs:enumeration>
<xs:enumeration value="child"></xs:enumeration>
<xs:enumeration value="replica"></xs:enumeration>
</xs:restriction>
</xs:simpleType>
</xs:attribute>
</xs:schema>
<!-- EOF -->

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,145 @@
<?xml version="1.0" encoding="UTF-8"?>
<xs:schema targetNamespace="http://www.w3.org/XML/1998/namespace" xmlns:xs="http://www.w3.org/2001/XMLSchema" xml:lang="en">
<xs:annotation>
<xs:documentation>
See http://www.w3.org/XML/1998/namespace.html and
http://www.w3.org/TR/REC-xml for information about this namespace.
This schema document describes the XML namespace, in a form
suitable for import by other schema documents.
Note that local names in this namespace are intended to be defined
only by the World Wide Web Consortium or its subgroups. The
following names are currently defined in this namespace and should
not be used with conflicting semantics by any Working Group,
specification, or document instance:
base (as an attribute name): denotes an attribute whose value
provides a URI to be used as the base for interpreting any
relative URIs in the scope of the element on which it
appears; its value is inherited. This name is reserved
by virtue of its definition in the XML Base specification.
id (as an attribute name): denotes an attribute whose value
should be interpreted as if declared to be of type ID.
This name is reserved by virtue of its definition in the
xml:id specification.
lang (as an attribute name): denotes an attribute whose value
is a language code for the natural language of the content of
any element; its value is inherited. This name is reserved
by virtue of its definition in the XML specification.
space (as an attribute name): denotes an attribute whose
value is a keyword indicating what whitespace processing
discipline is intended for the content of the element; its
value is inherited. This name is reserved by virtue of its
definition in the XML specification.
Father (in any context at all): denotes Jon Bosak, the chair of
the original XML Working Group. This name is reserved by
the following decision of the W3C XML Plenary and
XML Coordination groups:
In appreciation for his vision, leadership and dedication
the W3C XML Plenary on this 10th day of February, 2000
reserves for Jon Bosak in perpetuity the XML name
xml:Father
</xs:documentation>
</xs:annotation>
<xs:annotation>
<xs:documentation>This schema defines attributes and an attribute group
suitable for use by
schemas wishing to allow xml:base, xml:lang, xml:space or xml:id
attributes on elements they define.
To enable this, such a schema must import this schema
for the XML namespace, e.g. as follows:
&lt;schema . . .&gt;
. . .
&lt;import namespace="http://www.w3.org/XML/1998/namespace"
schemaLocation="http://www.w3.org/2001/xml.xsd"/&gt;
Subsequently, qualified reference to any of the attributes
or the group defined below will have the desired effect, e.g.
&lt;type . . .&gt;
. . .
&lt;attributeGroup ref="xml:specialAttrs"/&gt;
will define a type which will schema-validate an instance
element with any of those attributes</xs:documentation>
</xs:annotation>
<xs:annotation>
<xs:documentation>In keeping with the XML Schema WG's standard versioning
policy, this schema document will persist at
http://www.w3.org/2007/08/xml.xsd.
At the date of issue it can also be found at
http://www.w3.org/2001/xml.xsd.
The schema document at that URI may however change in the future,
in order to remain compatible with the latest version of XML Schema
itself, or with the XML namespace itself. In other words, if the XML
Schema or XML namespaces change, the version of this document at
http://www.w3.org/2001/xml.xsd will change
accordingly; the version at
http://www.w3.org/2007/08/xml.xsd will not change.
</xs:documentation>
</xs:annotation>
<xs:attribute name="lang">
<xs:annotation>
<xs:documentation>Attempting to install the relevant ISO 2- and 3-letter
codes as the enumerated possible values is probably never
going to be a realistic possibility. See
RFC 3066 at http://www.ietf.org/rfc/rfc3066.txt and the IANA registry
at http://www.iana.org/assignments/lang-tag-apps.htm for
further information.
The union allows for the 'un-declaration' of xml:lang with
the empty string.</xs:documentation>
</xs:annotation>
<xs:simpleType>
<xs:union memberTypes="xs:language">
<xs:simpleType>
<xs:restriction base="xs:string">
<xs:enumeration value=""/>
</xs:restriction>
</xs:simpleType>
</xs:union>
</xs:simpleType>
</xs:attribute>
<xs:attribute name="space">
<xs:simpleType>
<xs:restriction base="xs:NCName">
<xs:enumeration value="default"/>
<xs:enumeration value="preserve"/>
</xs:restriction>
</xs:simpleType>
</xs:attribute>
<xs:attribute name="base" type="xs:anyURI">
<xs:annotation>
<xs:documentation>See http://www.w3.org/TR/xmlbase/ for
information about this attribute.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="id" type="xs:ID">
<xs:annotation>
<xs:documentation>See http://www.w3.org/TR/xml-id/ for
information about this attribute.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attributeGroup name="specialAttrs">
<xs:attribute ref="xml:base"/>
<xs:attribute ref="xml:lang"/>
<xs:attribute ref="xml:space"/>
<xs:attribute ref="xml:id"/>
</xs:attributeGroup>
</xs:schema>

View File

@@ -97,6 +97,20 @@ public abstract class BaseWebScriptTest extends TestCase
*/
protected MockHttpServletResponse postRequest(String url, int expectedStatus, String body, String contentType)
throws IOException
{
return postRequest(url, expectedStatus, body.getBytes(), contentType);
}
/**
* "POST" the url and check for the expected status code
*
* @param url
* @param expectedStatus
* @return
* @throws IOException
*/
protected MockHttpServletResponse postRequest(String url, int expectedStatus, byte[] body, String contentType)
throws IOException
{
return sendRequest(METHOD_POST, url, expectedStatus, body, contentType);
}
@@ -125,7 +139,7 @@ public abstract class BaseWebScriptTest extends TestCase
* @return
* @throws IOException
*/
private MockHttpServletResponse sendRequest(String method, String url, int expectedStatus, String body, String contentType)
private MockHttpServletResponse sendRequest(String method, String url, int expectedStatus, byte[] body, String contentType)
throws IOException
{
MockHttpServletResponse response = BaseWebScriptTest.getServer().submitRequest(method, url, new HashMap<String, String>(), body, contentType);

View File

@@ -8,12 +8,12 @@
<content type="html">content 1</content>
<cmis:object>
<cmis:uri>http://example.org/atom04</cmis:uri>
<cmis:objectType>document</cmis:objectType>
<cmis:baseType>document</cmis:baseType>
<cmis:keyword index="0">XML</cmis:keyword>
<cmis:keyword index="1">standards</cmis:keyword>
</cmis:object>
</entry>
post /api/path/workspace/SpacesStore//children application/atom+xml <?xml version="1.0" encoding="utf-8"?> <entry xmlns="http://www.w3.org/2005/Atom" xmlns:cmis="http://www.cmis.org/CMIS/1.0"><title>Iñtërnâtiônàlizætiøn - 6</title><id>urn:uuid:12345678-1234-1234-1234-123412341234</id><summary>Create test 1 summary</summary><updated>2007-02-123T17:09:02Z</updated><author><name>Doolittle</name></author><content type="html">content 1</content><cmis:object><cmis:objectType>document</cmis:objectType></cmis:object></entry>
post /api/path/workspace/SpacesStore//children application/atom+xml <?xml version="1.0" encoding="utf-8"?> <entry xmlns="http://www.w3.org/2005/Atom" xmlns:cmis="http://www.cmis.org/CMIS/1.0"><title>Iñtërnâtiônàlizætiøn - 20</title><id>urn:uuid:12345678-1234-1234-1234-123412341234</id><summary>Create folder 1 summary</summary><updated>2007-02-123T17:09:02Z</updated><author><name>Doolittle</name></author><content type="html">content 1</content><cmis:object><cmis:baseType>folder</cmis:baseType></cmis:object></entry>
post /test/ext application/atom+xml <?xml version="1.0" encoding="utf-8"?> <entry xmlns="http://www.w3.org/2005/Atom" xmlns:cmis="http://www.cmis.org/CMIS/1.0"><title>Iñtërnâtiônàlizætiøn - 6</title><id>urn:uuid:12345678-1234-1234-1234-123412341234</id><summary>Create test 1 summary</summary><updated>2007-02-123T17:09:02Z</updated><author><name>Doolittle</name></author><content type="html">content 1</content><cmis:object><cmis:baseType>document</cmis:baseType></cmis:object></entry>

File diff suppressed because it is too large Load Diff

View File

@@ -1,19 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<entry xmlns="http://www.w3.org/2005/Atom" xmlns:cmis="http://www.cmis.org/CMIS/1.0">
<title>Iñtërnâtiônàlizætiøn - 2</title>
<id>urn:uuid:12345678-1234-1234-1234-123412341234</id>
<summary>Create test 1 summary</summary>
<updated>2007-02-123T17:09:02Z</updated>
<author><name>Doolittle</name></author>
<content type="html">content 1</content>
<cmis:object>
<cmis:uri>http://example.org/atom04</cmis:uri>
<cmis:objectType>document</cmis:objectType>
<cmis:keyword index="0">XML</cmis:keyword>
<cmis:keyword index="1">standards</cmis:keyword>
</cmis:object>
</entry>
post /api/path/workspace/SpacesStore//children application/atom+xml <?xml version="1.0" encoding="utf-8"?> <entry xmlns="http://www.w3.org/2005/Atom" xmlns:cmis="http://www.cmis.org/CMIS/1.0"><title>Iñtërnâtiônàlizætiøn - 6</title><id>urn:uuid:12345678-1234-1234-1234-123412341234</id><summary>Create test 1 summary</summary><updated>2007-02-123T17:09:02Z</updated><author><name>Doolittle</name></author><content type="html">content 1</content><cmis:object><cmis:objectType>document</cmis:objectType></cmis:object></entry>
post /test/ext application/atom+xml <?xml version="1.0" encoding="utf-8"?> <entry xmlns="http://www.w3.org/2005/Atom" xmlns:cmis="http://www.cmis.org/CMIS/1.0"><title>Iñtërnâtiônàlizætiøn - 6</title><id>urn:uuid:12345678-1234-1234-1234-123412341234</id><summary>Create test 1 summary</summary><updated>2007-02-123T17:09:02Z</updated><author><name>Doolittle</name></author><content type="html">content 1</content><cmis:object><cmis:baseType>document</cmis:baseType></cmis:object></entry>

54
source/xsd/APP.xsd Normal file
View File

@@ -0,0 +1,54 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
-*- rnc -*-
RELAX NG Compact Syntax Grammar for the
Atom Format Specification Version 11
-->
<xs:schema
xmlns:xs="http://www.w3.org/2001/XMLSchema"
elementFormDefault="qualified"
targetNamespace="http://www.w3.org/2007/app"
xmlns:atom="http://www.w3.org/2005/Atom"
xmlns:app="http://www.w3.org/2007/app"
xmlns:cmis="http://www.cmis.org/2008/05"
>
<xs:import namespace="http://www.w3.org/2005/Atom" schemaLocation="ATOM4CMIS.xsd"/>
<xs:import namespace="http://www.cmis.org/2008/05" schemaLocation="CMIS REST.xsd"/>
<xs:element name="service" type="app:appServiceType"></xs:element>
<xs:complexType name="appServiceType">
<xs:sequence>
<xs:element ref="atom:author"></xs:element>
<xs:element ref="app:workspace" minOccurs="1" maxOccurs="unbounded"></xs:element>
</xs:sequence>
</xs:complexType>
<xs:element name="workspace" type="app:appWorkspaceType"></xs:element>
<xs:complexType name="appWorkspaceType">
<xs:sequence>
<xs:element ref="atom:title"></xs:element>
<xs:element ref="cmis:repositoryInfo" minOccurs="0" maxOccurs="1"></xs:element>
<xs:element ref="app:collection" minOccurs="0" maxOccurs="unbounded"></xs:element>
</xs:sequence>
<xs:attribute ref="cmis:id"></xs:attribute>
<xs:attribute ref="cmis:repositoryRelationship"></xs:attribute>
<xs:attribute ref="app:href"></xs:attribute>
</xs:complexType>
<xs:element name="collection" type="app:appCollectionType"></xs:element>
<xs:complexType name="appCollectionType">
<xs:sequence>
<xs:element ref="atom:title"></xs:element>
</xs:sequence>
<xs:attribute ref="cmis:id"></xs:attribute>
<xs:attribute ref="cmis:collectionType"></xs:attribute>
</xs:complexType>
<xs:attribute name="href" type="xs:anyURI"></xs:attribute>
</xs:schema>
<!-- EOF -->

442
source/xsd/ATOM4CMIS.xsd Normal file
View File

@@ -0,0 +1,442 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
-*- rnc -*-
RELAX NG Compact Syntax Grammar for the
Atom Format Specification Version 11
-->
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
elementFormDefault="qualified"
targetNamespace="http://www.w3.org/2005/Atom"
xmlns:atom="http://www.w3.org/2005/Atom"
xmlns:xhtml="http://www.w3.org/1999/xhtml"
xmlns:cmis="http://www.cmis.org/2008/05"
xmlns:xml="http://www.w3.org/XML/1998/namespace"
>
<xs:import namespace="http://www.w3.org/1999/xhtml" schemaLocation="http://www.w3.org/2002/08/xhtml/xhtml1-strict.xsd"/>
<xs:import namespace="http://www.w3.org/XML/1998/namespace" schemaLocation="http://www.w3.org/2001/xml.xsd"/>
<xs:import namespace="http://www.cmis.org/2008/05" schemaLocation="CMIS REST.xsd"/>
<!-- Common attributes -->
<xs:attributeGroup name="atomCommonAttributes">
<xs:attribute ref="xml:base"/>
<xs:attribute ref="xml:lang"/>
<xs:attributeGroup ref="atom:undefinedAttribute"/>
</xs:attributeGroup>
<!-- Text Constructs -->
<xs:attributeGroup name="atomPlainTextConstruct">
<xs:attributeGroup ref="atom:atomCommonAttributes"/>
<xs:attribute name="type">
<xs:simpleType>
<xs:restriction base="xs:token">
<xs:enumeration value="text"/>
<xs:enumeration value="html"/>
</xs:restriction>
</xs:simpleType>
</xs:attribute>
</xs:attributeGroup>
<xs:group name="atomXHTMLTextConstruct">
<xs:sequence>
<xs:element ref="xhtml:div"/>
</xs:sequence>
</xs:group>
<xs:attributeGroup name="atomXHTMLTextConstruct">
<xs:attributeGroup ref="atom:atomCommonAttributes"/>
<xs:attribute name="type" use="required">
<xs:simpleType>
<xs:restriction base="xs:token">
<xs:enumeration value="xhtml"/>
</xs:restriction>
</xs:simpleType>
</xs:attribute>
</xs:attributeGroup>
<xs:complexType name="atomTextConstruct" mixed="true">
<xs:group minOccurs="0" ref="atom:atomXHTMLTextConstruct"/>
<xs:attribute name="type">
<xs:simpleType>
<xs:restriction base="xs:token">
<xs:enumeration value="text"/>
<xs:enumeration value="html"/>
<xs:enumeration value="xhtml"/>
</xs:restriction>
</xs:simpleType>
</xs:attribute>
<xs:attributeGroup ref="atom:atomCommonAttributes"/>
</xs:complexType>
<!-- Person Construct -->
<xs:complexType name="atomPersonConstruct">
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element ref="atom:name"/>
<xs:element ref="atom:uri"/>
<xs:element ref="atom:email"/>
<xs:group ref="atom:extensionElement"/>
</xs:choice>
<xs:attributeGroup ref="atom:atomCommonAttributes"/>
</xs:complexType>
<xs:element name="name" type="xs:string"/>
<xs:element name="uri" type="xs:string"/>
<xs:element name="email" type="atom:atomEmailAddress"/>
<!-- Date Construct -->
<xs:complexType name="atomDateConstruct">
<xs:simpleContent>
<xs:extension base="xs:dateTime">
<xs:attributeGroup ref="atom:atomCommonAttributes"/>
</xs:extension>
</xs:simpleContent>
</xs:complexType>
<!-- atom:feed -->
<xs:element name="feed">
<xs:complexType>
<xs:sequence>
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element ref="atom:author"/>
<xs:element ref="atom:category"/>
<xs:element ref="atom:contributor"/>
<xs:element ref="atom:generator"/>
<xs:element ref="atom:icon"/>
<xs:element ref="atom:id"/>
<xs:element ref="atom:link"/>
<xs:element ref="atom:logo"/>
<xs:element ref="atom:rights"/>
<xs:element ref="atom:subtitle"/>
<xs:element ref="atom:title"/>
<xs:element ref="atom:updated"/>
<xs:group ref="atom:extensionElement"/>
</xs:choice>
<xs:element minOccurs="0" maxOccurs="unbounded" ref="atom:entry"/>
<xs:choice minOccurs="0" maxOccurs="1">
<xs:group ref="cmis:CMISFolderEntry" />
<xs:group ref="cmis:CMISTypeEntry" />
</xs:choice>
<xs:element minOccurs="0" maxOccurs="1" ref="cmis:hasMoreItems"/>
</xs:sequence>
<xs:attributeGroup ref="atom:atomCommonAttributes"/>
</xs:complexType>
</xs:element>
<!-- atom:entry -->
<xs:element name="entry" type="atom:entryType">
</xs:element>
<xs:complexType name="entryType">
<xs:sequence>
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element ref="atom:author" />
<xs:element ref="atom:category" />
<xs:element ref="atom:content" />
<xs:element ref="atom:contributor" />
<xs:element ref="atom:id" />
<xs:element ref="atom:link" />
<xs:element ref="atom:published" />
<xs:element ref="atom:rights" />
<xs:element ref="atom:source" />
<xs:element ref="atom:summary" />
<xs:element ref="atom:title" />
<xs:element ref="atom:updated" />
<xs:group ref="atom:extensionElement" />
<xs:element ref="atom:uri"></xs:element>
</xs:choice>
<xs:choice minOccurs="0" maxOccurs="1">
<xs:group ref="cmis:CMISDocumentEntry" />
<xs:group ref="cmis:CMISFolderEntry" />
<xs:group ref="cmis:CMISRelationshipEntry" />
<xs:group ref="cmis:CMISPolicyEntry" />
<xs:group ref="cmis:CMISActionsEntry" />
<xs:group ref="cmis:CMISTypeEntry" />
</xs:choice>
</xs:sequence>
<xs:attributeGroup ref="atom:atomCommonAttributes"/>
</xs:complexType>
<!-- atom:content -->
<xs:attributeGroup name="atomInlineTextConstruct">
<xs:attributeGroup ref="atom:atomCommonAttributes"/>
<xs:attribute name="type">
<xs:simpleType>
<xs:restriction base="xs:token">
<xs:enumeration value="text"/>
<xs:enumeration value="html"/>
</xs:restriction>
</xs:simpleType>
</xs:attribute>
</xs:attributeGroup>
<xs:group name="atomInlineOtherConstruct">
<xs:sequence>
<xs:group minOccurs="0" maxOccurs="unbounded" ref="atom:anyElement"/>
</xs:sequence>
</xs:group>
<xs:attributeGroup name="atomInlineOtherConstruct">
<xs:attributeGroup ref="atom:atomCommonAttributes"/>
<xs:attribute name="type">
<xs:simpleType>
<xs:union memberTypes="atom:atomMediaType">
<xs:simpleType>
<xs:restriction base="xs:token">
<xs:enumeration value="xhtml"/>
</xs:restriction>
</xs:simpleType>
</xs:union>
</xs:simpleType>
</xs:attribute>
</xs:attributeGroup>
<xs:attributeGroup name="atomOutOfLineConstruct">
<xs:attributeGroup ref="atom:atomCommonAttributes"/>
<xs:attribute name="type" type="atom:atomMediaType"/>
<xs:attribute name="src" use="required"/>
</xs:attributeGroup>
<xs:element name="content">
<xs:complexType mixed="true">
<xs:group minOccurs="0" ref="atom:atomInlineOtherConstruct"/>
<xs:attribute name="type">
<xs:simpleType>
<xs:union memberTypes="atom:atomMediaType">
<xs:simpleType>
<xs:restriction base="xs:token">
<xs:enumeration value="text"/>
<xs:enumeration value="html"/>
</xs:restriction>
</xs:simpleType>
<xs:simpleType>
<xs:union memberTypes="atom:atomMediaType">
<xs:simpleType>
<xs:restriction base="xs:token">
<xs:enumeration value="xhtml"/>
</xs:restriction>
</xs:simpleType>
</xs:union>
</xs:simpleType>
</xs:union>
</xs:simpleType>
</xs:attribute>
<xs:attributeGroup ref="atom:atomCommonAttributes"/>
<xs:attribute name="src"/>
</xs:complexType>
</xs:element>
<!-- atom:author -->
<xs:element name="author" type="atom:atomPersonConstruct"/>
<!-- atom:category -->
<xs:element name="category">
<xs:complexType>
<xs:complexContent>
<xs:extension base="atom:undefinedContent">
<xs:attributeGroup ref="atom:atomCommonAttributes"/>
<xs:attribute name="term" use="required"/>
<xs:attribute name="scheme"/>
<xs:attribute name="label"/>
</xs:extension>
</xs:complexContent>
</xs:complexType>
</xs:element>
<!-- atom:contributor -->
<xs:element name="contributor" type="atom:atomPersonConstruct"/>
<!-- atom:generator -->
<xs:element name="generator">
<xs:complexType mixed="true">
<xs:attributeGroup ref="atom:atomCommonAttributes"/>
<xs:attribute name="uri"/>
<xs:attribute name="version"/>
</xs:complexType>
</xs:element>
<!-- atom:icon -->
<xs:element name="icon">
<xs:complexType mixed="true">
<xs:attributeGroup ref="atom:atomCommonAttributes"/>
</xs:complexType>
</xs:element>
<!-- atom:id -->
<xs:element name="id">
<xs:complexType mixed="true">
<xs:attributeGroup ref="atom:atomCommonAttributes"/>
</xs:complexType>
</xs:element>
<!-- atom:logo -->
<xs:element name="logo">
<xs:complexType mixed="true">
<xs:attributeGroup ref="atom:atomCommonAttributes"/>
</xs:complexType>
</xs:element>
<!-- atom:link -->
<xs:element name="link">
<xs:annotation>
<xs:documentation>
The "atom:link" element defines a reference from an entry
or feed to a Web resource. This specification assigns no
meaning to the content (if any) of this element.
</xs:documentation>
</xs:annotation>
<xs:complexType>
<xs:complexContent>
<xs:extension base="atom:undefinedContent">
<xs:attributeGroup ref="atom:atomCommonAttributes" />
<xs:attribute name="href" use="required" />
<xs:attribute name="rel">
</xs:attribute>
<xs:attribute name="type" type="atom:atomMediaType" />
<xs:attribute name="hreflang"
type="atom:atomLanguageTag" />
<xs:attribute name="title" />
<xs:attribute name="length" />
</xs:extension>
</xs:complexContent>
</xs:complexType>
</xs:element>
<!-- atom:published -->
<xs:element name="published" type="atom:atomDateConstruct"/>
<!-- atom:rights -->
<xs:element name="rights" type="atom:atomTextConstruct"/>
<!-- atom:source -->
<xs:element name="source">
<xs:annotation>
<xs:documentation>
atom:source is used to preserve metadata of a feed when an entry is copied from a feed to another feed.
</xs:documentation>
</xs:annotation>
<xs:complexType>
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element ref="atom:author"/>
<xs:element ref="atom:category"/>
<xs:element ref="atom:contributor"/>
<xs:element ref="atom:generator"/>
<xs:element ref="atom:icon"/>
<xs:element ref="atom:id"/>
<xs:element ref="atom:link"/>
<xs:element ref="atom:logo"/>
<xs:element ref="atom:rights"/>
<xs:element ref="atom:subtitle"/>
<xs:element ref="atom:title"/>
<xs:element ref="atom:updated"/>
<xs:group ref="atom:extensionElement"/>
</xs:choice>
<xs:attributeGroup ref="atom:atomCommonAttributes"/>
</xs:complexType>
</xs:element>
<!-- atom:subtitle -->
<xs:element name="subtitle" type="atom:atomTextConstruct"/>
<!-- atom:summary -->
<xs:element name="summary" type="atom:atomTextConstruct"/>
<!-- atom:title -->
<xs:element name="title" type="atom:atomTextConstruct">
<xs:annotation>
<xs:documentation>
The "atom:title" element is a Text construct that conveys a human-
readable title for an entry or feed.
atomTitle = element atom:title { atomTextConstruct }.
</xs:documentation>
</xs:annotation>
</xs:element>
<!-- atom:updated -->
<xs:element name="updated" type="atom:atomDateConstruct">
<xs:annotation>
<xs:documentation>
The "atom:updated" element is a Date construct indicating the most
recent instant in time when an entry or feed was modified in a way
the publisher considers significant. Therefore, not all
modifications necessarily result in a changed atom:updated value.
atomUpdated = element atom:updated { atomDateConstruct }.
Publishers MAY change the value of this element over time.
</xs:documentation>
</xs:annotation>
</xs:element>
<!-- Low-level simple types -->
<xs:simpleType name="atomNCName">
<xs:restriction base="xs:string">
<xs:minLength value="1"/>
<xs:pattern value="[^:]*"/>
</xs:restriction>
</xs:simpleType>
<!-- Whatever a media type is, it contains at least one slash -->
<xs:simpleType name="atomMediaType">
<xs:restriction base="xs:string">
<xs:pattern value=".+/.+"/>
</xs:restriction>
</xs:simpleType>
<!-- As defined in RFC 3066 -->
<xs:simpleType name="atomLanguageTag">
<xs:restriction base="xs:string">
<xs:pattern value="[A-Za-z]{1,8}(-[A-Za-z0-9]{1,8})*"/>
</xs:restriction>
</xs:simpleType>
<!--
Unconstrained; it's not entirely clear how IRI fit into
xsd:anyURI so let's not try to constrain it here
-->
<!-- Whatever an email address is, it contains at least one @ -->
<xs:simpleType name="atomEmailAddress">
<xs:restriction base="xs:string">
<xs:pattern value=".+@.+"/>
</xs:restriction>
</xs:simpleType>
<!-- Simple Extension -->
<xs:group name="extensionElement">
<xs:choice>
<xs:any namespace="##other" processContents="skip"/>
<xs:any namespace="##local" processContents="skip"/>
</xs:choice>
</xs:group>
<xs:attributeGroup name="undefinedAttribute">
<xs:anyAttribute namespace="##other" processContents="skip"/>
</xs:attributeGroup>
<xs:complexType name="undefinedContent" mixed="true">
<xs:group minOccurs="0" maxOccurs="unbounded" ref="atom:anyForeignElement"/>
</xs:complexType>
<xs:group name="anyElement">
<xs:sequence>
<xs:any processContents="skip"/>
</xs:sequence>
</xs:group>
<xs:group name="anyForeignElement">
<xs:choice>
<xs:any namespace="##other" processContents="skip"/>
<xs:any namespace="##local" processContents="skip"/>
</xs:choice>
</xs:group>
<!-- XHTML -->
<xs:group name="anyXHTML">
<xs:sequence>
<xs:any namespace="http://www.w3.org/1999/xhtml" processContents="skip"/>
</xs:sequence>
</xs:group>
<xs:element name="service" type="atom:atomServiceType"></xs:element>
<xs:complexType name="atomServiceType">
<xs:sequence>
<xs:element ref="atom:author"></xs:element>
</xs:sequence>
</xs:complexType>
<xs:element name="workspace" type="atom:atomWorkspaceType"></xs:element>
<xs:complexType name="atomWorkspaceType">
<xs:sequence>
<xs:element ref="atom:title"></xs:element>
<xs:element ref="cmis:repositoryInfo"></xs:element>
</xs:sequence>
<xs:attribute ref="cmis:id"></xs:attribute>
</xs:complexType>
<xs:element name="collection" type="xs:string"></xs:element>
<xs:complexType name="atomCollectionType">
<xs:sequence>
<xs:element ref="atom:title"></xs:element>
</xs:sequence>
<xs:attribute ref="cmis:id"></xs:attribute>
<xs:attribute ref="cmis:collectionType"></xs:attribute>
<xs:attribute ref="cmis:id"></xs:attribute>
</xs:complexType>
</xs:schema>
<!-- EOF -->

634
source/xsd/CMIS REST.xsd Normal file
View File

@@ -0,0 +1,634 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
-*- rnc -*-
RELAX NG Compact Syntax Grammar for the
Atom Format Specification Version 11
-->
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
elementFormDefault="qualified"
targetNamespace="http://www.cmis.org/2008/05"
xmlns:atom="http://www.w3.org/2005/Atom"
xmlns:xhtml="http://www.w3.org/1999/xhtml"
xmlns:cmis="http://www.cmis.org/2008/05">
<xs:import namespace="http://www.w3.org/1999/xhtml" />
<xs:import namespace="http://www.w3.org/XML/1998/namespace" />
<xs:element name="repositoryInfo" type="cmis:repositoryInfoType"></xs:element>
<xs:element name="property" type="cmis:propertyDefinitionType"></xs:element>
<xs:element name="parent" type="xs:string"></xs:element>
<xs:element name="displayName" type="xs:string"></xs:element>
<xs:element name="isVersionable" type="xs:boolean"></xs:element>
<xs:element name="description" type="xs:string"></xs:element>
<xs:element name="isQueryable" type="xs:string"></xs:element>
<xs:element name="isCreatable" type="xs:string"></xs:element>
<xs:element name="queryName" type="xs:string"></xs:element>
<xs:element name="baseTypeQueryName" type="xs:string"></xs:element>
<xs:element name="isContentStreamAllowed" type="xs:boolean"></xs:element>
<xs:element name="AllowedSourceTypes" type="xs:string"></xs:element>
<xs:element name="AllowedTargetTypes" type="xs:string"></xs:element>
<xs:element name="constraints" type="xs:string"></xs:element>
<xs:element name="propertyType">
<xs:simpleType>
<xs:restriction base="xs:string">
<xs:enumeration value="String"></xs:enumeration>
<xs:enumeration value="Decimal"></xs:enumeration>
<xs:enumeration value="Integer"></xs:enumeration>
<xs:enumeration value="Boolean"></xs:enumeration>
<xs:enumeration value="DateTime"></xs:enumeration>
<xs:enumeration value="URI"></xs:enumeration>
<xs:enumeration value="HTML"></xs:enumeration>
<xs:enumeration value="XML"></xs:enumeration>
<xs:enumeration value="ID"></xs:enumeration>
<xs:enumeration value="TypeID"></xs:enumeration>
</xs:restriction>
</xs:simpleType>
</xs:element>
<xs:element name="cardinality">
<xs:simpleType>
<xs:restriction base="xs:string">
<xs:enumeration value="Single"></xs:enumeration>
<xs:enumeration value="Multi"></xs:enumeration>
</xs:restriction>
</xs:simpleType>
</xs:element>
<xs:element name="maxLength" type="xs:int"></xs:element>
<xs:element name="schemaURI" type="xs:string"></xs:element>
<xs:element name="encoding" type="xs:string"></xs:element>
<xs:element name="choices">
<xs:complexType>
<xs:simpleContent>
<xs:extension base="xs:string">
<xs:attribute name="index"
type="xs:positiveInteger" />
</xs:extension>
</xs:simpleContent>
</xs:complexType>
</xs:element>
<xs:element name="isOpenChoice" type="xs:boolean"></xs:element>
<xs:element name="isRequired" type="xs:boolean"></xs:element>
<xs:element name="defaultValue" type="xs:string"></xs:element>
<xs:element name="updateability">
<xs:simpleType>
<xs:restriction base="xs:string">
<xs:enumeration value="ro"></xs:enumeration>
<xs:enumeration value="rw"></xs:enumeration>
<xs:enumeration value="checkedout"></xs:enumeration>
</xs:restriction>
</xs:simpleType>
</xs:element>
<xs:complexType name="repositoryInfoType">
<xs:sequence minOccurs="1">
<xs:element name="repositoryId" type="xs:string"
minOccurs="1">
</xs:element>
<xs:element name="repositoryName" type="xs:string"
minOccurs="1">
</xs:element>
<xs:element name="repositoryDescription" type="xs:string"
minOccurs="1">
</xs:element>
<xs:element name="vendorName" type="xs:string"></xs:element>
<xs:element name="productName" type="xs:string"></xs:element>
<xs:element name="productVersion" type="xs:string"></xs:element>
<xs:element name="capabilities"
type="cmis:RepositoryInfoCapabilities">
</xs:element>
<xs:element name="repositorySpecificInformation"
type="xs:string" maxOccurs="1" minOccurs="0">
</xs:element>
<xs:any namespace="##any" processContents="skip"
minOccurs="0" maxOccurs="unbounded">
</xs:any>
</xs:sequence>
</xs:complexType>
<xs:complexType name="RepositoryInfoCapabilities">
<xs:sequence>
<xs:element name="capabilityMultifiling" type="xs:boolean"
minOccurs="1" maxOccurs="1">
</xs:element>
<xs:element name="capabilityUnfiling" type="xs:boolean"
minOccurs="1" maxOccurs="1">
</xs:element>
<xs:element name="capabilityVersionSpecificFiling"
type="xs:boolean" minOccurs="1" maxOccurs="1">
</xs:element>
<xs:element name="capabilityPWCUpdateable" type="xs:boolean"
minOccurs="1" maxOccurs="1">
</xs:element>
<xs:element name="capabilityAllVersionsSearchable"
type="xs:boolean" minOccurs="1" maxOccurs="1">
</xs:element>
<xs:element name="capabilityInnerJoin" type="xs:boolean"
minOccurs="1" maxOccurs="1">
</xs:element>
<xs:element name="capabilityOuterJoin" type="xs:boolean"
minOccurs="1" maxOccurs="1">
</xs:element>
<xs:element name="capabilityFullText">
<xs:simpleType>
<xs:restriction base="xs:string">
<xs:enumeration value="none"></xs:enumeration>
<xs:enumeration value="fulltextonly"></xs:enumeration>
<xs:enumeration value="fulltextwithmetadata"></xs:enumeration>
</xs:restriction>
</xs:simpleType>
</xs:element>
</xs:sequence>
</xs:complexType>
<xs:attribute name="id" type="xs:string"></xs:attribute>
<xs:attribute name="index" type="xs:int"></xs:attribute>
<xs:element name="creationDate" type="xs:dateTime"></xs:element>
<xs:element name="lastModifiedBy" type="xs:dateTime"></xs:element>
<xs:element name="baseType" type="cmis:baseObjectType"></xs:element>
<xs:simpleType name="baseObjectType">
<xs:restriction base="xs:string">
<xs:enumeration value="document"></xs:enumeration>
<xs:enumeration value="folder"></xs:enumeration>
<xs:enumeration value="relationship"></xs:enumeration>
<xs:enumeration value="policy"></xs:enumeration>
</xs:restriction>
</xs:simpleType>
<xs:element name="objectType" type="xs:string"></xs:element>
<xs:element name="isLatestVersion" type="xs:boolean"></xs:element>
<xs:element name="isCheckedOut" type="xs:boolean"></xs:element>
<xs:element name="contentStreamLength" type="xs:int"></xs:element>
<xs:element name="contentStreamMimetype">
<xs:simpleType>
<xs:restriction base="xs:string">
<xs:pattern value=".*/.*"></xs:pattern>
</xs:restriction>
</xs:simpleType>
</xs:element>
<xs:element name="contentStreamName" type="xs:string"></xs:element>
<xs:element name="contentStreamURI" type="xs:string"></xs:element>
<xs:group name="entryCommonElements">
<xs:sequence>
<xs:element ref="cmis:baseType" minOccurs="1"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:lastModifiedBy" minOccurs="1"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:creationDate" minOccurs="1"
maxOccurs="1">
</xs:element>
</xs:sequence>
</xs:group>
<xs:group name="entryContentStreamElements">
<xs:sequence>
<xs:element ref="cmis:contentStreamLength"></xs:element>
<xs:element ref="cmis:contentStreamMimetype"></xs:element>
<xs:element ref="cmis:contentStreamName"></xs:element>
<xs:element ref="cmis:contentStreamURI"></xs:element>
</xs:sequence>
</xs:group>
<xs:group name="propertyDefinitionElements">
<xs:sequence>
<xs:element ref="cmis:displayName" minOccurs="1"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:description" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:propertyType" minOccurs="1"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:cardinality" minOccurs="1"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:maxLength" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:schemaURI" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:encoding" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:choices" minOccurs="0"
maxOccurs="unbounded">
</xs:element>
<xs:element ref="cmis:isOpenChoice" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:isRequired" minOccurs="1"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:defaultValue" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:updateability" minOccurs="1"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:isQueryable" minOccurs="1"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:isOrderable" minOccurs="1"
maxOccurs="1">
</xs:element>
</xs:sequence>
</xs:group>
<xs:element name="isOrderable" type="xs:boolean"></xs:element>
<xs:complexType name="propertyDefinitionType">
<xs:sequence>
<xs:element ref="cmis:displayName" minOccurs="1"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:description" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:propertyType" minOccurs="1"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:cardinality" minOccurs="1"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:maxLength" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:schemaURI" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:encoding" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:choices" minOccurs="0"
maxOccurs="unbounded">
</xs:element>
<xs:element ref="cmis:isOpenChoice" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:isRequired" minOccurs="1"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:defaultValue" minOccurs="0"
maxOccurs="unbounded">
</xs:element>
<xs:element ref="cmis:updateability" minOccurs="1"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:isQueryable" minOccurs="1"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:isOrderable" minOccurs="1"
maxOccurs="1">
</xs:element>
</xs:sequence>
<xs:attribute ref="cmis:id"></xs:attribute>
</xs:complexType>
<xs:element name="canDelete" type="xs:boolean"></xs:element>
<xs:element name="canUpdateProperties" type="xs:boolean"></xs:element>
<xs:element name="canGetProperties" type="xs:boolean"></xs:element>
<xs:element name="canGetParents" type="xs:boolean"></xs:element>
<xs:element name="canMove" type="xs:boolean"></xs:element>
<xs:element name="canDeleteVersion" type="xs:boolean"></xs:element>
<xs:element name="canDeleteContent" type="xs:boolean"></xs:element>
<xs:element name="canCheckout" type="xs:boolean"></xs:element>
<xs:element name="canCancelCheckout" type="xs:boolean"></xs:element>
<xs:element name="canCheckin" type="xs:boolean"></xs:element>
<xs:element name="canSetContent" type="xs:boolean"></xs:element>
<xs:element name="canGetAllVersions" type="xs:boolean"></xs:element>
<xs:element name="canAddToFolder" type="xs:boolean"></xs:element>
<xs:element name="canRemoveFromFolder" type="xs:boolean"></xs:element>
<xs:element name="canViewContent" type="xs:boolean"></xs:element>
<xs:element name="canAddPolicy" type="xs:boolean"></xs:element>
<xs:element name="canRemovePolicy" type="xs:boolean"></xs:element>
<xs:element name="canGetChildren" type="xs:boolean"></xs:element>
<xs:element name="canGetDescendants" type="xs:boolean"></xs:element>
<xs:element name="isControllable" type="xs:boolean"></xs:element>
<xs:element name="source" type="xs:string"></xs:element>
<xs:element name="target" type="xs:string"></xs:element>
<xs:element name="isImmutable" type="xs:boolean"></xs:element>
<xs:element name="isMajorVersion" type="xs:boolean"></xs:element>
<xs:element name="isLatestMajorVersion" type="xs:boolean"></xs:element>
<xs:element name="isVersionSeriesCheckedOut" type="xs:boolean"></xs:element>
<xs:element name="versionSeriesCheckedOutBy" type="xs:string"></xs:element>
<xs:element name="versionSeriesCheckedOutID" type="xs:string"></xs:element>
<xs:element name="checkinComment" type="xs:string"></xs:element>
<xs:group name="CMISActionsEntry">
<xs:sequence>
<xs:element ref="cmis:canDelete" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:canUpdateProperties" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:canGetProperties" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:canGetParents" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:canGetDescendants" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:canMove" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:canDeleteVersion" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:canDeleteContent" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:canCheckout" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:canCancelCheckout" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:canCheckin" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:canSetContent" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:canGetAllVersions" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:canAddToFolder" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:canRemoveFromFolder" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:canViewContent" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:canAddPolicy" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:canRemovePolicy" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:canGetChildren" minOccurs="0"
maxOccurs="1">
</xs:element>
</xs:sequence>
</xs:group>
<xs:group name="CMISTypeEntry">
<xs:sequence>
<xs:group ref="cmis:entryCommonElements" minOccurs="1"
maxOccurs="1">
</xs:group>
<xs:element ref="cmis:queryName" minOccurs="1"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:displayName" minOccurs="1"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:baseType" minOccurs="1"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:baseTypeQueryName" minOccurs="1"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:parent" minOccurs="1" maxOccurs="1"></xs:element>
<xs:element ref="cmis:description" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:isCreatable" minOccurs="1"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:isVersionable" minOccurs="1"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:isQueryable" minOccurs="1"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:isContentStreamAllowed" minOccurs="1"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:AllowedSourceTypes" minOccurs="1" maxOccurs="1">
</xs:element>
<xs:element ref="cmis:AllowedTargetTypes" minOccurs="1" maxOccurs="1">
</xs:element>
<xs:element ref="cmis:constraints" minOccurs="0"
maxOccurs="unbounded">
</xs:element>
<xs:element ref="cmis:property"></xs:element>
<xs:element ref="cmis:isControllable"></xs:element>
</xs:sequence>
</xs:group>
<xs:group name="CMISDocumentEntry">
<xs:sequence>
<xs:group ref="cmis:entryCommonElements" minOccurs="1"
maxOccurs="1">
</xs:group>
<xs:element ref="cmis:objectType" minOccurs="1"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:isCheckedOut" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:isLatestVersion" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:isMajorVersion" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:isLatestMajorVersion" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:isImmutable" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:isVersionSeriesCheckedOut" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:versionSeriesCheckedOutBy" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:versionSeriesCheckedOutID" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:checkinComment" minOccurs="1"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:versionLabel" minOccurs="0"
maxOccurs="1">
</xs:element>
<xs:group ref="cmis:entryContentStreamElements"
minOccurs="0" maxOccurs="1">
</xs:group>
<xs:element ref="cmis:allowableActions" minOccurs="0"
maxOccurs="1">
</xs:element>
</xs:sequence>
</xs:group>
<xs:group name="CMISFolderEntry">
<xs:sequence>
<xs:group ref="cmis:entryCommonElements" minOccurs="1"
maxOccurs="1">
</xs:group>
<xs:element ref="cmis:objectType" minOccurs="1"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:parent" minOccurs="1" maxOccurs="1"></xs:element>
<xs:element ref="cmis:allowableActions" minOccurs="0"
maxOccurs="1">
</xs:element>
</xs:sequence>
</xs:group>
<xs:group name="CMISRelationshipEntry">
<xs:sequence>
<xs:group ref="cmis:entryCommonElements" minOccurs="1"
maxOccurs="1">
</xs:group>
<xs:element ref="cmis:objectType" minOccurs="1"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:source" minOccurs="1"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:target" minOccurs="1"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:allowableActions" minOccurs="0"
maxOccurs="1">
</xs:element>
</xs:sequence>
</xs:group>
<xs:group name="CMISPolicyEntry">
<xs:sequence>
<xs:group ref="cmis:entryCommonElements" minOccurs="1"
maxOccurs="1">
</xs:group>
<xs:element ref="cmis:objectType" minOccurs="1"
maxOccurs="1">
</xs:element>
<xs:element ref="cmis:allowableActions" minOccurs="0"
maxOccurs="1">
</xs:element>
</xs:sequence>
</xs:group>
<xs:element name="function" type="xs:string"></xs:element>
<xs:element name="hasMoreItems" type="xs:boolean"></xs:element>
<xs:element name="allowableActions" type="cmis:allowableActions"></xs:element>
<xs:complexType name="allowableActions">
<xs:sequence maxOccurs="1" minOccurs="1">
<xs:group ref="cmis:CMISActionsEntry"></xs:group>
</xs:sequence>
</xs:complexType>
<xs:element name="versionLabel" type="xs:string"></xs:element>
<xs:element name="query" type="cmis:queryType"></xs:element>
<xs:complexType name="queryType">
<xs:sequence>
<xs:element ref="cmis:statement" minOccurs="1" maxOccurs="1"></xs:element>
<xs:element ref="cmis:searchAllVersions" minOccurs="0" maxOccurs="1"></xs:element>
<xs:element ref="cmis:pageSize" minOccurs="0" maxOccurs="1"></xs:element>
<xs:element ref="cmis:skipCount" minOccurs="0" maxOccurs="1"></xs:element>
<xs:element ref="cmis:returnAllowableActions" minOccurs="0" maxOccurs="1"></xs:element>
</xs:sequence>
</xs:complexType>
<xs:element name="statement" type="xs:string"></xs:element>
<xs:element name="pageSize" type="xs:int"></xs:element>
<xs:element name="skipCount" type="xs:int"></xs:element>
<xs:element name="returnAllowableActions" type="xs:boolean"></xs:element>
<xs:element name="searchAllVersions" type="xs:boolean"></xs:element>
<xs:attribute name="collectionType">
<xs:simpleType>
<xs:restriction base="xs:string">
<xs:enumeration value="root"></xs:enumeration>
<xs:enumeration value="unfiled"></xs:enumeration>
<xs:enumeration value="checkedout"></xs:enumeration>
<xs:enumeration value="types"></xs:enumeration>
</xs:restriction>
</xs:simpleType>
</xs:attribute>
<xs:attribute name="repositoryRelationship">
<xs:simpleType>
<xs:restriction base="xs:string">
<xs:enumeration value="self"></xs:enumeration>
<xs:enumeration value="sibling"></xs:enumeration>
<xs:enumeration value="parent"></xs:enumeration>
<xs:enumeration value="child"></xs:enumeration>
<xs:enumeration value="replica"></xs:enumeration>
</xs:restriction>
</xs:simpleType>
</xs:attribute>
</xs:schema>
<!-- EOF -->