public void save(final String path) throws RepositoryException {
if (denotesRoot(path)) {
save();
} else {
try {
root.commit(null, new EditorHook(new EditorProvider() {
@Override
public Editor getRootEditor(NodeState before, NodeState after, NodeBuilder builder) {
return new ItemSaveValidator(path);
}
}));