public class MetadataRevisionPortable extends MetadataRevision
MetadataRevision
.Modifier and Type | Method and Description |
---|---|
boolean |
exists()
Returns
true if this revision exists in the local history. |
boolean |
isEligibleForUnpublish()
Returns
true if this revision is eligible to be
unpublished from the local history. |
static MetadataRevisionPortable |
parse(java.lang.String str)
Parses the textual representation of an object of this class to
reconstruct the object.
|
void |
publish(java.lang.String note)
Publishes this revision to the local host.
|
java.lang.String |
toString()
Returns the textual representation of this object.
|
boolean |
unpublish()
Removes this metadata revision from the local history if it is the latest
revision in the local history.
|
create, export, get, getFromHostId, getHostId, getId, getLatest, getLatest, getLocalHostId, getNote, getRecordDate, getRecordedBy, getRepositoryBaselines, listAfter
public boolean exists()
true
if this revision exists in the local history.true
if this revision exists in the local historypublic void publish(java.lang.String note)
note
- the revision note; null
is allowed.java.lang.IllegalStateException
- if this revision exists in the local
historyjava.lang.UnsupportedOperationException
- if the current application
context does not support publishing of a portable revisionpublic boolean isEligibleForUnpublish()
true
if this revision is eligible to be
unpublished from the local history. A revision is eligible for unpublish
when it has been published and no other revisions have been published
after the revision.true
if this revision is eligible for unpublishjava.lang.UnsupportedOperationException
- if this operation is not supportedunpublish()
public boolean unpublish()
true
if this revision is successfully unpublished;
false
if this revision has never been published to
the local host, or it is not the latest revision in the local
historyjava.lang.UnsupportedOperationException
- if this operation is not supportedisEligibleForUnpublish()
public java.lang.String toString()
toString
in class java.lang.Object
parse(java.lang.String)
public static MetadataRevisionPortable parse(java.lang.String str)
str
- the textual representation of the object to be reconstructedjava.lang.IllegalArgumentException
- if the given String is not in a valid
form