> yeah :-) but your adding the label to the same version? this one would
throw an exception:
> node.getVersionHistory().addVersionLabel("1.0", "foo", false);
> node.getVersionHistory().addVersionLabel("1.1", "foo", false);
as you can see I'm adding label to the current base version.
this is from method body "addLabel"..
> String versionName = node.getBaseVersion().getName();
> node.getVersionHistory().addVersionLabel(versionName,
> label, false);
these are steps to call this method (I don't modify node in time (don't
increase current version), just follow bellow sequence)
> Node myRoot = session.getRootNode().getNode("myRoot");
> addLabel(myRoot, "MY_LABEL");
>
> // this should throw exception
> addLabel(myRoot, "MY_LABEL");