public final class VersionManagerDelegate extends Object
VersionManagerDelegate
...public static VersionManagerDelegate create(SessionDelegate sessionDelegate)
@Nonnull public VersionDelegate checkin(@Nonnull NodeDelegate nodeDelegate) throws RepositoryException
RepositoryException
public void checkout(@Nonnull NodeDelegate nodeDelegate) throws RepositoryException
RepositoryException
public boolean isCheckedOut(@Nonnull NodeDelegate nodeDelegate) throws RepositoryException
RepositoryException
@Nonnull public VersionHistoryDelegate createVersionHistory(@Nonnull NodeDelegate versionHistory) throws RepositoryException
RepositoryException
@Nonnull public VersionDelegate createVersion(@Nonnull NodeDelegate version) throws RepositoryException
RepositoryException
@Nonnull public VersionHistoryDelegate getVersionHistory(@Nonnull NodeDelegate versionable) throws RepositoryException
RepositoryException
@Nonnull public VersionDelegate getBaseVersion(@Nonnull NodeDelegate versionable) throws RepositoryException
RepositoryException
@Nonnull public VersionDelegate getVersionByIdentifier(@Nonnull String identifier) throws RepositoryException
RepositoryException
public void restore(@Nonnull NodeDelegate parent, @Nonnull String oakName, @Nonnull VersionDelegate vd) throws RepositoryException
RepositoryException
public void addVersionLabel(@Nonnull VersionHistoryDelegate versionHistory, @Nonnull VersionDelegate version, @Nonnull String oakVersionLabel, boolean moveLabel) throws InvalidItemStateException, LabelExistsVersionException, VersionException, RepositoryException
versionHistory
- the version history.version
- the version.oakVersionLabel
- the version label.moveLabel
- whether to move the label if it already exists.InvalidItemStateException
- if any of the nodes is stale.LabelExistsVersionException
- if moveLabel is false, and an attempt
is made to add a label that already exists in this version history.VersionException
- if the specified version does not exist in this
version history or if the specified version is the root version (jcr:rootVersion).RepositoryException
- if another error occurs.public void removeVersionLabel(@Nonnull VersionHistoryDelegate versionHistory, @Nonnull String oakVersionLabel) throws InvalidItemStateException, VersionException, RepositoryException
versionHistory
- the version history.oakVersionLabel
- the version label.InvalidItemStateException
- if any of the nodes is stale.VersionException
- if the name label does not exist in this version history.RepositoryException
- if another error occurs.public void removeVersion(@Nonnull VersionHistoryDelegate versionHistory, @Nonnull String oakVersionName) throws RepositoryException
versionHistory
- the version history delegate.oakVersionName
- the version nameRepositoryException
- if an error occurs.Copyright © 2012–2018 The Apache Software Foundation. All rights reserved.