node.addMixin("mix:lockable");
session.save();
}
}
Lock lock;
if (bodyIsEmpty)
{
lock = node.getLock();
lock.refresh();
body = new HierarchicalProperty(new QName("DAV", "activelock", "D"));
HierarchicalProperty owner = new HierarchicalProperty(PropertyConstants.OWNER);
HierarchicalProperty href = new HierarchicalProperty(new QName("D", "href"), lock.getLockOwner());
body.addChild(owner).addChild(href);
}
else
{
lock = node.lock((depth.getIntValue() != 1), false);
}
lockToken = lock.getLockToken();
}
catch (PathNotFoundException pexc)
{
lockToken = nullResourceLocks.addLock(session, path);
}