You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@jackrabbit.apache.org by AE...@idc.com on 2010/02/25 10:32:07 UTC
Version History
Hi,
Please, can any one guide me how to obtain the VersionHistory of a node in
Jackrabbit 2.0?
Here's the code how I used to obtain it in the previous release:
VersionHistory versionIterator = node.getVersionHistory();
while(versionIterator.hasNext()){
Version version = versionIterator.nextVersion();
Node frozenNode = version.getNode(JcrConstants.JCR_FROZENNODE);
...
}
However, node.getVersionHistory() is deprecated, and in version 2.0 I
should obtain it from VersionManager or something like this, but don't
know how!!
Thanks you in advance.
Re: Version History
Posted by AE...@idc.com.
Thank you so much Thomas.
Ich wünsche dir einen schönen Tag ;-)
Re: Version History
Posted by Thomas Müller <th...@day.com>.
Hi,
> should obtain it from VersionManager or something like this, but don't
> know how!!
See http://www.day.com/maven/javax.jcr/javadocs/jcr-2.0/javax/jcr/version/VersionManager.html
"The VersionManager object is accessed via
Workspace.getVersionManager()." and "The Workspace object can be
acquired by calling Session.getWorkspace() on the associated Session
object. "
Regards,
Thomas