public class DocumentId extends Object
Modifier and Type | Field and Description |
---|---|
private String |
descriptorKey |
private String |
id |
private String |
spaceKey |
private String |
versionId |
Constructor and Description |
---|
DocumentId(DocumentId latestVersionId,
String versionId)
Constructor for an older version of a document
|
DocumentId(String descriptorKey,
String spaceKey,
String id)
Constructor when the document is the current version
|
Modifier and Type | Method and Description |
---|---|
boolean |
equals(Object o) |
String |
getDescriptorKey() |
String |
getId() |
String |
getSpaceKey() |
String |
getVersionId() |
int |
hashCode() |
boolean |
isLatestVersion() |
String |
toString() |
private final String descriptorKey
private final String spaceKey
private final String id
private final String versionId
public DocumentId(@Nonnull String descriptorKey, @Nonnull String spaceKey, @Nonnull String id)
descriptorKey
- the key of the descriptor. It will be Descriptor.getKey()
in most cases,
unless the descriptor is managing several types of documents (like the DefaultDescriptor).
For Excel, it will be DBLink.APP_EXCEL.spaceKey
- the space key in Confluence where the document will be importedid
- an arbitrary string, uniquely identifying the document. For Excel attachments,
we use the attachmentId, but there is no constraint on this.public DocumentId(@Nonnull DocumentId latestVersionId, @Nonnull String versionId)
latestVersionId
- the DocumentId for the current/latest version of the document.versionId
- an arbitrary string, uniquely identifying the version of the document. It is unique for this document
only. It doesn't need to be in alphabetical order for the moment, as requirements are displayed
per baseline, but it may help in the future if we have to display a list. For Excel attachments,
we use the attachmentVersionId, but there is no constraint on this.Copyright © 2022 Requirement Yogi. All rights reserved.