Interface Version
- All Superinterfaces:
DeltaVItem
,HierarchyItem
Defines the properties and methods that item version must implement. In addition to methods and properties provided by
DeltaVItem
this interface also provides methods for getting version name, next version and previous version.
Usually you will implement Version interface for your resource version objects together with File
interface.
While Resource interface is optional for resource versions it may be useful if your DeltaV client application will request
content of the resource version. In this case File.read(java.io.OutputStream, long, long)
, File.getContentLength()
and File.getContentType()
members of the File
interface will be requested by the engine.
Copying, moving, updating properties and content are not allowed for a version, your HierarchyItem.copyTo(com.ithit.webdav.server.Folder, java.lang.String, boolean)
,
HierarchyItem.moveTo(com.ithit.webdav.server.Folder, java.lang.String)
, HierarchyItem.updateProperties(com.ithit.webdav.server.Property[], com.ithit.webdav.server.Property[])
and File.write(java.io.InputStream, java.lang.String, long, long)
implementations must throw ServerException
with status WebDavStatus.NOT_ALLOWED
-
Method Summary
Modifier and TypeMethodDescriptionPrevious version or null if no previous version exists.Next version or null if no next version exists.Hierarchy item for this version.Name of the version.Methods inherited from interface com.ithit.webdav.server.deltav.DeltaVItem
getComment, getCreatorDisplayName, setComment, setCreatorDisplayName
Methods inherited from interface com.ithit.webdav.server.HierarchyItem
copyTo, delete, getCreated, getModified, getName, getPath, getProperties, getPropertyNames, moveTo, updateProperties
-
Method Details
-
getSuccessor
Next version or null if no next version exists.- Returns:
- Version item representing next version in the list of versions or null if no next version exists.
- Throws:
ServerException
- in case of an error.
-
getPredecessor
Previous version or null if no previous version exists.- Returns:
- Version item representing previous version in the list of versions or null if no previous version exists.
- Throws:
ServerException
- in case of an error.
-
getVersionableItem
Hierarchy item for this version.- Returns:
- Hierarchy item for this version.
- Throws:
ServerException
- in case of an error.
-
getVersionName
Name of the version.Must be unique among version items for a given hierarchy item. This string is intended for display for a user.
- Returns:
- Name of the version.
- Throws:
ServerException
- in case of an error.
-