throw new LockException("Node " + parent().getPath() + " is locked ");
// the new version identifier
String verIdentifier = IdGenerator.generate();
SessionChangesLog changesLog = new SessionChangesLog(session.getId());
VersionHistoryImpl vh = versionHistory(false);
vh.addVersion(this.nodeData(), verIdentifier, changesLog);
changesLog.add(ItemState.createUpdatedState(updatePropertyData(Constants.JCR_ISCHECKEDOUT,
new TransientValueData(false))));
changesLog.add(ItemState.createUpdatedState(updatePropertyData(Constants.JCR_BASEVERSION, new TransientValueData(
new Identifier(verIdentifier)))));
changesLog.add(ItemState.createUpdatedState(updatePropertyData(Constants.JCR_PREDECESSORS,
new ArrayList<ValueData>())));
dataManager.getTransactManager().save(changesLog);
VersionImpl version = (VersionImpl)dataManager.getItemByIdentifier(verIdentifier, true);