org.apache.jackrabbit.oak.jcr.delegate
Class VersionHistoryDelegate

java.lang.Object
  extended by org.apache.jackrabbit.oak.jcr.delegate.ItemDelegate
      extended by org.apache.jackrabbit.oak.jcr.delegate.NodeDelegate
          extended by org.apache.jackrabbit.oak.jcr.delegate.VersionHistoryDelegate

public class VersionHistoryDelegate
extends NodeDelegate

VersionHistoryDelegate...


Field Summary
 
Fields inherited from class org.apache.jackrabbit.oak.jcr.delegate.ItemDelegate
sessionDelegate
 
Method Summary
 void addVersionLabel(VersionDelegate version, String oakVersionLabel, boolean moveLabel)
           
 Iterator<VersionDelegate> getAllLinearVersions()
           
 Iterator<VersionDelegate> getAllVersions()
           
 VersionDelegate getRootVersion()
           
 VersionDelegate getVersion(String versionName)
          Gets the version with the given name.
 String getVersionableIdentifier()
           
 VersionDelegate getVersionByLabel(String label)
           
 Iterable<String> getVersionLabels()
           
 Iterable<String> getVersionLabels(String identifier)
           
 void removeVersion(String oakVersionName)
           
 void removeVersionLabel(String oakVersionLabel)
           
 
Methods inherited from class org.apache.jackrabbit.oak.jcr.delegate.NodeDelegate
addChild, addMixin, canAddMixin, exists, getChild, getChildCount, getChildren, getIdentifier, getLock, getLockOwner, getName, getParent, getPath, getProperties, getProperty, getPropertyCount, getPropertyOrNull, getStatus, getTree, holdsLock, isLocked, isLockOwner, isProtected, isRoot, lock, orderBefore, remove, removeMixin, setMixins, setOrderableChildren, setProperty, toString, unlock, updateMixins
 
Methods inherited from class org.apache.jackrabbit.oak.jcr.delegate.ItemDelegate
checkAlive, checkUpdate, save, update
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Method Detail

getVersionableIdentifier

public String getVersionableIdentifier()
                                throws javax.jcr.InvalidItemStateException
Throws:
javax.jcr.InvalidItemStateException

getRootVersion

@Nonnull
public VersionDelegate getRootVersion()
                               throws javax.jcr.RepositoryException
Throws:
javax.jcr.RepositoryException

getVersion

@Nonnull
public VersionDelegate getVersion(@Nonnull
                                          String versionName)
                           throws javax.jcr.version.VersionException,
                                  javax.jcr.RepositoryException
Gets the version with the given name.

Parameters:
versionName - a version name.
Returns:
the version delegate.
Throws:
javax.jcr.version.VersionException - if there is no version with the given name.
javax.jcr.RepositoryException - if another error occurs.

getVersionByLabel

@Nonnull
public VersionDelegate getVersionByLabel(@Nonnull
                                                 String label)
                                  throws javax.jcr.version.VersionException,
                                         javax.jcr.RepositoryException
Throws:
javax.jcr.version.VersionException
javax.jcr.RepositoryException

getVersionLabels

@Nonnull
public Iterable<String> getVersionLabels()
                                  throws javax.jcr.RepositoryException
Throws:
javax.jcr.RepositoryException

getVersionLabels

@Nonnull
public Iterable<String> getVersionLabels(@Nonnull
                                                 String identifier)
                                  throws javax.jcr.RepositoryException
Throws:
javax.jcr.RepositoryException

getAllVersions

@Nonnull
public Iterator<VersionDelegate> getAllVersions()
                                         throws javax.jcr.RepositoryException
Throws:
javax.jcr.RepositoryException

getAllLinearVersions

@Nonnull
public Iterator<VersionDelegate> getAllLinearVersions()
                                               throws javax.jcr.RepositoryException
Throws:
javax.jcr.RepositoryException

addVersionLabel

public void addVersionLabel(@Nonnull
                            VersionDelegate version,
                            @Nonnull
                            String oakVersionLabel,
                            boolean moveLabel)
                     throws javax.jcr.version.LabelExistsVersionException,
                            javax.jcr.version.VersionException,
                            javax.jcr.RepositoryException
Throws:
javax.jcr.version.LabelExistsVersionException
javax.jcr.version.VersionException
javax.jcr.RepositoryException

removeVersionLabel

public void removeVersionLabel(@Nonnull
                               String oakVersionLabel)
                        throws javax.jcr.version.VersionException,
                               javax.jcr.RepositoryException
Throws:
javax.jcr.version.VersionException
javax.jcr.RepositoryException

removeVersion

public void removeVersion(@Nonnull
                          String oakVersionName)
                   throws javax.jcr.RepositoryException
Throws:
javax.jcr.RepositoryException


Copyright © 2012-2014 The Apache Software Foundation. All Rights Reserved.