code: boolean changeLockHeldBySession( String lockToken,
                                       boolean value ) throws LockException {
          CachedNode locksNode = locksNode();
          ChildReferences childRefs = locksNode.getChildReferences(system);
          Name name = names.create(lockToken);
          ChildReference ref = childRefs.getChild(name);
          if (ref == null) {
              throw new LockException(JcrI18n.invalidLockToken.text(lockToken));
          }
          MutableCachedNode lockNode = system.mutable(ref.getKey());
          boolean isHeld = booleans.create(first(lockNode, ModeShapeLexicon.IS_HELD_BY_SESSION, false));
          if (isHeld && value) {
              // The lock is already held by a session ...
              return false;
          }
          lockNode.setProperty(system, propertyFactory.create(ModeShapeLexicon.IS_HELD_BY_SESSION, value));
          return true;
      }
docs: Updates the underlying repository directly (i.e., outside the scope of the {@link Session}) to mark the token for the given
  lock as being held (or not held) by some {@link Session}. Note that this method does not identify <i>which</i> (if any)
  session holds the token for the lock, just that <i>some</i> session holds the token for the lock.
  
  @param lockToken the lock token for which the "held" status should be modified; may not be null
  @param value the new value
  @return true if the lock "held" status was successfully changed to the desired value, or false otherwise
  @throws LockException if there is no such lock with the supplied token