Package com.logicaldoc.webservice.soap
Interface DocumentMetadataService
-
- All Known Implementing Classes:
RestDocumentMetadataService
,RestDocumentMetadataSwagger
,SoapDocumentMetadataClient
,SoapDocumentMetadataService
public interface DocumentMetadataService
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description void
deleteAttributeSet(String sid, long setId)
Deletes an existing attribute set with the given identifier.void
deleteTemplate(String sid, long templateId)
Deletes an existing template with the given identifierString[]
getAttributeOptions(String sid, long setId, String attribute)
Retrieves the options for the given attributeWSAttributeOption[]
getAttributeOptionsByCategory(String sid, long setId, String attribute, String category)
Retrieves the options for the given attribute inside a given categoryWSAttributeSet
getAttributeSet(String sid, String name)
Gets attribute set's metadataWSAttributeSet
getAttributeSetById(String sid, long setId)
Gets attribute set's metadataWSRight[]
getGrantedGroups(String sid, long templateId)
Retrieves the list of granted groups for the given templateWSRight[]
getGrantedUsers(String sid, long templateId)
Retrieves the list of granted users for the given template.WSTemplate
getTemplate(String sid, String name)
Gets template's metadataWSTemplate
getTemplateById(String sid, long templateId)
Gets template's metadatavoid
grantGroupToTemplate(String sid, long templateId, long groupId, int permissions)
Grants group permission to the template.void
grantUserToTemplate(String sid, long templateId, long userId, int permissions)
Grants user permission to the template.boolean
isTemplateReadable(String sid, long templateId)
Tests if a template is readable.boolean
isTemplateWritable(String sid, long templateId)
Tests if a template is writableWSAttributeSet[]
listAttributeSets(String sid)
Gets metadata of all existing attribute sets.WSTemplate[]
listTemplates(String sid)
Gets metadata of all existing templates.void
setAttributeOptions(String sid, long setId, String attribute, WSAttributeOption[] options)
Saves the options for the given attributelong
storeAttributeSet(String sid, WSAttributeSet attributeSet)
Create/Update an attribute set.long
storeTemplate(String sid, WSTemplate template)
Create/Update a template.
-
-
-
Method Detail
-
listTemplates
WSTemplate[] listTemplates(String sid) throws Exception
Gets metadata of all existing templates.- Parameters:
sid
- Session identifier- Returns:
- The list of all templates
- Throws:
Exception
- error in the server application
-
getTemplate
WSTemplate getTemplate(String sid, String name) throws Exception
Gets template's metadata- Parameters:
sid
- Session identifiername
- The template's name- Returns:
- A value object containing the template's metadata.
- Throws:
Exception
- error in the server application
-
getTemplateById
WSTemplate getTemplateById(String sid, long templateId) throws Exception
Gets template's metadata- Parameters:
sid
- Session identifiertemplateId
- The template's id- Returns:
- A value object containing the template's metadata
- Throws:
Exception
- error in the server application
-
storeTemplate
long storeTemplate(String sid, WSTemplate template) throws Exception
Create/Update a template. You can completely customize the template through a value object.- Parameters:
sid
- Session identifier (need to be administrator)template
- value object containing the template's metadata- Returns:
- The ID of the new template
- Throws:
Exception
- error in the server application
-
deleteTemplate
void deleteTemplate(String sid, long templateId) throws Exception
Deletes an existing template with the given identifier- Parameters:
sid
- Session identifier (need to be administrator)templateId
- The template's id- Throws:
Exception
- error in the server application
-
listAttributeSets
WSAttributeSet[] listAttributeSets(String sid) throws Exception
Gets metadata of all existing attribute sets.- Parameters:
sid
- Session identifier- Returns:
- The list of all attribute sets
- Throws:
Exception
- error in the server application
-
getAttributeSet
WSAttributeSet getAttributeSet(String sid, String name) throws Exception
Gets attribute set's metadata- Parameters:
sid
- Session identifiername
- The attribute set's name- Returns:
- A value object containing the attribute set's metadata
- Throws:
Exception
- error in the server application
-
getAttributeSetById
WSAttributeSet getAttributeSetById(String sid, long setId) throws Exception
Gets attribute set's metadata- Parameters:
sid
- Session identifiersetId
- The attribute set's id- Returns:
- A value object containing the attribute set's metadata
- Throws:
Exception
- error in the server application
-
storeAttributeSet
long storeAttributeSet(String sid, WSAttributeSet attributeSet) throws Exception
Create/Update an attribute set. You can completely customize the attribute set through a value object containing the attribute set's metadata.- Parameters:
sid
- Session identifier (need to be administrator)attributeSet
- set's value object containing the attribute set's metadata- Returns:
- The ID of the new attribute set
- Throws:
Exception
- error in the server application
-
deleteAttributeSet
void deleteAttributeSet(String sid, long setId) throws Exception
Deletes an existing attribute set with the given identifier.- Parameters:
sid
- Session identifier (need to be administrator)setId
- The attribute set's id- Throws:
Exception
- error in the server application
-
setAttributeOptions
void setAttributeOptions(String sid, long setId, String attribute, WSAttributeOption[] options) throws Exception
Saves the options for the given attribute- Parameters:
sid
- Session identifiersetId
- The attribute set's idattribute
- The attribute's nameoptions
- The attribute's options- Throws:
Exception
- error in the server application
-
getAttributeOptions
String[] getAttributeOptions(String sid, long setId, String attribute) throws Exception
Retrieves the options for the given attribute- Parameters:
sid
- Session identifiersetId
- The attribute set's idattribute
- The attribute's name- Returns:
- the list of all the attribute's options
- Throws:
Exception
- error in the server application
-
getAttributeOptionsByCategory
WSAttributeOption[] getAttributeOptionsByCategory(String sid, long setId, String attribute, String category) throws Exception
Retrieves the options for the given attribute inside a given category- Parameters:
sid
- Session identifiersetId
- The attribute set's idattribute
- The attribute's namecategirt
- The options category (not mandatory)- Returns:
- the list of all the attribute's options
- Throws:
Exception
- error in the server application
-
isTemplateReadable
boolean isTemplateReadable(String sid, long templateId) throws Exception
Tests if a template is readable.- Parameters:
sid
- Session identifiertemplateId
- The template id- Returns:
- True if the identifier denotes a readable template, otherwise false.
- Throws:
Exception
- error in the server application
-
isTemplateWritable
boolean isTemplateWritable(String sid, long templateId) throws Exception
Tests if a template is writable- Parameters:
sid
- Session identifiertemplateId
- The template id- Returns:
- True if the identifier denotes a writable template, otherwise false
- Throws:
Exception
- error in the server application
-
grantUserToTemplate
void grantUserToTemplate(String sid, long templateId, long userId, int permissions) throws Exception
Grants user permission to the template.- Parameters:
sid
- Session identifiertemplateId
- Template iduserId
- User Idpermissions
- the permission integer representation. If '0', the user will be not granted to access the template.- Throws:
Exception
- error in the server application
-
grantGroupToTemplate
void grantGroupToTemplate(String sid, long templateId, long groupId, int permissions) throws Exception
Grants group permission to the template.- Parameters:
sid
- Session identifiertemplateId
- Template idgroupId
- Group Idpermissions
- the permission integer representation. If '0', the group will be not granted to access the template.- Throws:
Exception
- error in the server application
-
getGrantedUsers
WSRight[] getGrantedUsers(String sid, long templateId) throws Exception
Retrieves the list of granted users for the given template.- Parameters:
sid
- Session identifiertemplateId
- Template id- Returns:
- 'error' if error occurred, the right objects collection.
- Throws:
Exception
- error in the server application
-
getGrantedGroups
WSRight[] getGrantedGroups(String sid, long templateId) throws Exception
Retrieves the list of granted groups for the given template- Parameters:
sid
- Session identifiertemplateId
- Template id- Returns:
- 'error' if error occurred, the right objects collection
- Throws:
Exception
- error in the server application
-
-