Package io.ocfl.api.model
Class VersionDetails
java.lang.Object
io.ocfl.api.model.VersionDetails
Details about a specific version of an object
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionboolean
containsFile
(String path) Returns true if the version contains a file at the specified pathboolean
The timestamp of when the version was createdReturns the FileDetails for the file at the given path or null if it does not existReturns a map of logical paths to file details that represents the state of the object at this version.getFiles()
Collection of all of the files in this version of the objectThe object's idThe ObjectVersionId of the versionDescription of the versionThe version number of this versionint
hashCode()
boolean
Returns true only if the version is a mutable HEAD version that is used to stage changes.setCreated
(OffsetDateTime created) setFileMap
(Map<String, FileDetails> fileMap) setMutable
(boolean mutable) setObjectOcflVersion
(OcflVersion objectOcflVersion) setObjectVersionId
(ObjectVersionId objectVersionId) setVersionInfo
(VersionInfo versionInfo) toString()
-
Constructor Details
-
VersionDetails
public VersionDetails()
-
-
Method Details
-
getObjectVersionId
The ObjectVersionId of the version- Returns:
- the ObjectVersionId of the version
-
setObjectVersionId
-
getObjectId
The object's id- Returns:
- the object's id
-
getVersionNum
The version number of this version- Returns:
- the version number
-
getCreated
The timestamp of when the version was created- Returns:
- created timestamp
-
setCreated
-
getVersionInfo
Description of the version- Returns:
- VersionInfo
-
setVersionInfo
-
isMutable
public boolean isMutable()Returns true only if the version is a mutable HEAD version that is used to stage changes.- Returns:
- true if mutable HEAD
-
setMutable
-
getObjectOcflVersion
- Returns:
- the OCFL version the object adheres to
-
setObjectOcflVersion
-
getFiles
Collection of all of the files in this version of the object- Returns:
- all of the files in the version
-
containsFile
Returns true if the version contains a file at the specified path- Parameters:
path
- logical path to an object file- Returns:
- true if the version contains the file
-
getFile
Returns the FileDetails for the file at the given path or null if it does not exist- Parameters:
path
- logical path to the file- Returns:
- FileDetails or null
-
setFileMap
-
getFileMap
Returns a map of logical paths to file details that represents the state of the object at this version.- Returns:
- file state map
-
toString
-
equals
-
hashCode
public int hashCode()
-