This flow allows to browse the document space : folders, categories, documents.
The objects could be as well definition objects (administrative objects) as dynamic objects (documents).
The managed objects :
In your queries, you can define the structure (tree or not) of what you request.
For example, you may wish to obtain:
All these requests are possible with the same flow.
Indeed, it's you who will define the structure of your definition objects.
Warning: the tree must be respected in the declaration of "definitions"
Scopes tags allows to reduce the search area.
http://myvdocserver/vdoc/navigation/flow?module=library&cmd=view&_AuthenticationKey=...
Parameter | Description |
labels (default: true) | Allows to get the wording associated to retrieved elements. |
maxlevel (default: 0) | If the parameter is not specified, only elements in scope are retrieved. If the parameter is defined with a value, all elements, up to that level, are retrieved . If the parameter is set to -1, all sub-elements (starting from the scope, if we have one) are retrieved. |
attachments (default: false) | With this setting, VDoc will book a download for the file associated to documents and send you back in the response flow a GUID. This GUID will then be used with the command "download" of the "io" module. |
This list is not exhaustive as there are of course many possible combinations by modifying the structure of definitions and scopes.
<?xml version="1.0" encoding="UTF-8"?> <view xmlns:vw1="http://www.axemble.com/vdoc/view"> <header> <definition class="com.axemble.vdoc.sdk.interfaces.ILibrary" /> </header> </view>
<?xml version="1.0" encoding="UTF-8"?> <view xmlns:vw1="http://www.axemble.com/vdoc/view"> <header> <scopes> <folder protocol-uri="uri://vdoc/fileCenterFolder/031-000000-001" /> </scopes> <definition class="com.axemble.vdoc.sdk.interfaces.IFile" /> </header> </view>
<?xml version="1.0" encoding="UTF-8"?> <view xmlns:vw1="http://www.axemble.com/vdoc/view"> <header> <scopes> <library protocol-uri="uri://vdoc/datastore/032-000000-000" /> </scopes> <configuration> <param name="maxlevel" value="-1" /> </configuration> <definition class="com.axemble.vdoc.sdk.interfaces.IFolder" > <definition class="com.axemble.vdoc.sdk.interfaces.IFile" /> </definition> </header> </view>
In response, the flow will send you a tree structure related to your request. If we take the previous example flow "Retrieve all records and documents", here's what VDoc could return as answer.
<?xml version="1.0" encoding="UTF-8"?> <view xmlns:vw1="http://www.axemble.com/library/view"> <header /> <body> <folder id="3412884092616705" name="Dossier 1" protocol-uri="uri://vdoc/fileCenterFolder/031-000000-001"> <folder id="3412884092616707" name="Sous-dossier 1" protocol-uri="uri://vdoc/fileCenterFolder/031-000000-003"/> <resource id="3623990325149696" reference="2011-12-15_120803.png" protocol-uri="uri://vdoc/document/037-000000-000" description="" creator="sysadmin" editor="sysadmin" created-date="2011-12-19T16:14:28.603Z" modified-date="2011-12-19T16:14:29.617Z"/> <resource id="3623990325182464" reference="SchemaFluxSDK.png" protocol-uri="uri://vdoc/document/037-000001-000" description="sqdds" creator="sysadmin" editor="sysadmin" created-date="2011-12-22T11:13:46.640Z" modified-date="2011-12-22T11:13:47.843Z"/> </folder> <folder id="3412884092616706" name="Dossier 2" protocol-uri="uri://vdoc/fileCenterFolder/031-000000-002"> <resource id="3623990325149700" reference="Mon bien beau document" protocol-uri="uri://vdoc/document/037-000000-004" description="Et ben oui, il est joli mon document !" creator="sysadmin" editor="sysadmin" created-date="2011-12-19T16:27:40.967Z" modified-date="2011-12-19T16:27:41.027Z"/> </folder> </body> </view>
This flow allows to retrieve object informations from the element ID (the URI protocol)
The managed objects:
We do not manage the ICategory by now because this object does not carry any information.
http://myvdocserver/vdoc/navigation/flow?module=library&cmd=get&_AuthenticationKey=...
Parameter | Description |
labels (default: true) | Allows to get the wordings associated to the retrieved document. |
attachmentsContent (default: true) | It allows to retrieve a Base64 encoded file in the flow. If this parameter is set to "false", a download reservation will be made and a GUID will be provided (to used in the download command of the IO module). |
Example 1: Using ILibrary
<?xml version="1.0" encoding="UTF-8"?> <get xmlns:d1="http://www.axemble.com/vdoc/library"> <body> <element class="com.axemble.vdoc.sdk.interfaces.ILibrary"> <header protocol-uri="resource:/filecenter/datastore/042-000006-006" /> </ element> </body> </get>
Example 2: Using IFolder
<?xml version="1.0" encoding="UTF-8"?> <get xmlns:d1="http://www.axemble.com/vdoc/folder"> <body> <element class="com.axemble.vdoc.sdk.interfaces.IFolder"> <header protocol-uri="resource:/filecenter/folder/042-000006-006" /> </element> </body> </get>
Example 3: Using IFile
<?xml version="1.0" encoding="UTF-8"?> <get xmlns:d1="http://www.axemble.com/vdoc/file"> <body> <resource class="com.axemble.vdoc.sdk.interfaces.IFile"> <header protocol-uri="resource:/filecenter/document/042-000006-006" /> </resource> </body> </get>
The response flow will depend on your request.
The following example shows how to get detail informations about a document, which is the most common case.
<resource xmlns:d1="http://www.axemble.com/portal/document" class="com.axemble.vdoc.sdk.interfaces.IFile"> <header id="3623990325182464" reference="SchemaFluxSDK.png" protocol-uri="uri://vdoc/document/037-000001-000" description="un rexte" creator="sysadmin" editor="sysadmin" created-date="2011-12-22T11:13:46.640Z" modified-date="2011-12-22T11:13:47.843Z" checked-out-by=""> <library id="3448068464705536" name="ProjectSpace" protocol-uri="uri://vdoc/datastore/032-000000-000"/> <folder id="3412884092616705" name="Folder ABC" protocol-uri="uri://vdoc/fileCenterFolder/031-000000-001"/> <resource-definition id="3518437208883200" name="type-1"/> <attachments> <file> <content name="SchemaFluxSDK.png" size="22150" uri="/action/WebdriveActionEvent/oid/037-000001-000/fname/SchemaFluxSDK.png" guid="-3v4gx6c7l61liyyarnq545"/> </file> </attachments> </header> <history/> <body/> </resource>
For more informations about the available data types, please refer to VDoc data types in SDK flows.
This flow will allow us to create new objects in FileCenter.
The managed objects:
We have to send all the required informations for the creation of these elements.
To create a folder will be easy since few informations will be needed. But to create a new document, it will be a little more complex, in fact,
the creation of a document involves:
Obviously, VDoc must know where it must create the new element: at the root, in a specified folder, etc.
http://myvdocserver/vdoc/navigation/flow?module=library&cmd=create&_AuthenticationKey=...
The configuration of the request flow is quite different between creating a document or folder.
<?xml version="1.0" encoding="UTF-8"?> <create> <header /> <body> <resource class="com.axemble.vdoc.sdk.interfaces.IFolder"> <header name="My new folder" description="Example of folder remotely created" > <library protocol-uri="uri://vdoc/datastore/032-000000-000" /> </header> </resource> </body> </create>
Here we must initially perform an upload file upload control via the IO module. This exchange allows us to retrieve a GUID that can be submitted after as in the example below.
<?xml version="1.0" encoding="UTF-8"?> <create> <header /> <body> <resource class="com.axemble.vdoc.sdk.interfaces.IFile"> <header reference="Nice document" description="So, it's not beautiful !" > <library protocol-uri="uri://vdoc/datastore/032-000000-000" /> <attachments> <file> <content name="success.jpg" guid="51uwn8btdqa9e5u16gpbvj" /> </file> </attachments> </header> <body> </body> </resource> </body> </create>
In this case, we will be able to submit in addition:
<?xml version="1.0" encoding="UTF-8"?> <create> <header /> <body> <resource class="com.axemble.vdoc.sdk.interfaces.IFile"> <header reference="FileType1" description="Such a beautiful document !" > <library protocol-uri="uri://vdoc/datastore/032-000000-000" /> <resource-definition name="type-1" /> <attachments> <file> <content name="FileType1.xml" guid="-3v4gx6c7l61liyyarnq542" /> </file> </attachments> </header> <body> <string name="attr01" value="Value of an attribute" /> </body> </resource> </body> </create>
The response flow will be a standard XML that will indicate either the success of the operation or any errors.
<?xml version="1.0" encoding="UTF-8"?> <response status="success" message="Folder created [ProjetcsSpace.MyNewFolder]." detail="uri://vdoc/fileCenterFolder/031-000003-000"/>
This flow will allow update of existing elements in the document spaces. The updates can apply to folders (name, description) and to documents (new attributes or file upload).
http://myvdocserver/vdoc/navigation/flow?module=library&cmd=update&_AuthenticationKey=...
The only difference compared to the create command will be at the level of the header:
you will have to provide the URI protocol of the element that you wish to edit.
<?xml version="1.0" encoding="UTF-8"?> <update> <header /> <body> <resource class="com.axemble.vdoc.sdk.interfaces.IFolder"> <header reference="My modified folder" protocol-uri="uri://vdoc/fileCenterFolder/031-000003-000" /> </resource> </body> </update>
<?xml version="1.0" encoding="UTF-8"?> <update> <header /> <body> <resource class="com.axemble.vdoc.sdk.interfaces.IFile"> <header protocol-uri="uri://vdoc/document/037-000003-003" > <library protocol-uri="uri://vdoc/datastore/032-000000-000" /> <resource-definition name="type-1" /> </header> <body> <string name="attr01" value="value of the modified attribute" /> </body> </resource> </body> </update>
This response flow has the same format as the response flow of the create command.
This flow is very simple to use, but it must be used very carefully.
This flow allows to remove an existing item in the document space: documents, folders.
In the case of documentary publication, we use a recycle bin; thus, it will be possible to configure between permanently delete the item or just temporarily delete the item (default setting) .
The managed objects:
http://myvdocserver/vdoc/navigation/flow?module=library&cmd=delete&_AuthenticationKey=...
The syntax for the request flow is simple. You just need to forward the URI protocol of the item to delete.
parameter | Description | Mandatory |
deleteFromTrash (Default: false) | If this is true, the item will also be deleted from the trash (permanently deleted without possibility to recover). | false |
<?xml version="1.0" encoding="UTF-8"?> <delete> <header /> <body> <resource class="com.axemble.vdoc.sdk.interfaces.IFolder"> <header protocol-uri="uri://vdoc/fileCenterFolder/031-000003-000" deleteFromTrash="true" /> </resource> </body> </delete>
<?xml version="1.0" encoding="UTF-8"?> <delete> <header /> <body> <resource class="com.axemble.vdoc.sdk.interfaces.IFile"> <header protocol-uri="uri://vdoc/document/037-000000-000" /> </resource> </body> </delete>
The response flow will be a standard XML that will indicate either the success of the operation or any errors.
This flow will help to move an item to another folder. We can either move a document or a whole folder.
The managed objects:
http://myvdocserver/vdoc/navigation/flow?module=library&cmd=move&_AuthenticationKey=...
The syntax of the request flow is relatively simple, you need to pass:
<?xml version="1.0" encoding="UTF-8"?> <move> <header /> <body> <resource class="com.axemble.vdoc.sdk.interfaces.IFile"> <header protocol-uri="uri://vdoc/document/SourceFileURI" > <library protocol-uri="uri://vdoc/document/TargetDocumentURI" /> </header> </resource> </body> </move>
<?xml version="1.0" encoding="UTF-8"?> <move> <header /> <body> <resource class="com.axemble.vdoc.sdk.interfaces.IFolder"> <header protocol-uri="uri://vdoc/folder/sourceFolderURI" > <folder protocol-uri="uri://vdoc/folder/targetFolderURI" /> </header> </resource> </body> </move>
The response flow will be a standard XML that will indicate either the success of the operation or any errors.
<?xml version="1.0" encoding="UTF-8"?> <response status="success" message="Element moved[ElementName]." detail="protocol-uri" />
This flow is very simple to use; it allows to lock a document in the document spaces.
The managed object:
http://myvdocserver/vdoc/navigation/flow?module=library&cmd=checkout&_AuthenticationKey=...
The syntax for this request flow is simple; You just need to forward the URI protocol of the document to lock.
<?xml version="1.0" encoding="UTF-8"?> <checkout> <header /> <body> <resource> <header protocol-uri="uri://vdoc/document/037-000000-000" /> </resource> </body> </checkout>
The response flow will be a standard XML that will indicate either the success of the operation or any errors.
<?xml version="1.0" encoding="UTF-8"?> <response status="success" message="Element checked out[ElementName]." detail="protocol-uri" />
This flow is simple to use; it allows to cancel a lock put on a document in the document spaces.
The managed object:
http://myvdocserver/vdoc/navigation/flow?module=library&cmd=undocheckout&_AuthenticationKey=...
The request syntax is simple, you just need to forward the URI protocol of the document to unlock.
<?xml version="1.0" encoding="UTF-8"?> <undocheckout> <header /> <body> <resource> <header protocol-uri="uri://vdoc/document/037-000000-000" /> </resource> </body> </undocheckout>
The response flow will be a standard XML that will indicate either the success of the operation or any errors.
<?xml version="1.0" encoding="UTF-8"?> <response status="success" message="Element undo checked out[ElementName]." detail="protocol-uri" />
This flow is simple to use and it allows to commit an edited document in the document spaces.
The check-in will of course be preceded:
The managed object:
http://myvdocserver/vdoc/navigation/flow?module=library&cmd=checkin&_AuthenticationKey=...
The request syntax is really simple, you just need to forward the URI protocol of the document to checkin.
<?xml version="1.0" encoding="UTF-8"?> <checkin> <header /> <body> <resource> <header protocol-uri="uri://vdoc/document/037-000000-000" /> </resource> </body> </checkin>
The response flow will be a standard XML that will indicate either the success of the operation or any errors.
<?xml version="1.0" encoding="UTF-8"?> <response status="success" message="Element check in[ElementName]." detail="protocol-uri" /> +-----------