@Override
  protected LockObjectsResult confirming(CDODataInput in) throws IOException {
    boolean succesful = in.readBoolean();
    boolean timeout = in.readBoolean();
    boolean waitForUpdate = in.readBoolean();
    long requiredTimestamp = in.readLong();

    int nStaleRevisions = in.readInt();
    CDORevisionKey[] staleRevisions = new CDORevisionKey[nStaleRevisions];
    for (int i = 0; i < nStaleRevisions; i++) {
      staleRevisions[i] = in.readCDORevisionKey();
    }

    long timestamp = in.readLong();

    int n = in.readInt();
    CDOLockState[] newLockStates = new CDOLockState[n];
    for (int i = 0; i < n; i++) {
      newLockStates[i] = in.readCDOLockState();
    }

    return new LockObjectsResult(
        succesful,
        timeout,
        waitForUpdate,
        requiredTimestamp,
        staleRevisions,
        newLockStates,
        timestamp);
  }
Exemple #2
0
 @Override
 protected UnlockObjectsResult confirming(CDODataInput in) throws IOException {
   long timestamp = in.readLong();
   int n = in.readInt();
   CDOLockState[] newLockStates = new CDOLockState[n];
   for (int i = 0; i < n; i++) {
     newLockStates[i] = in.readCDOLockState();
   }
   return new UnlockObjectsResult(newLockStates, timestamp);
 }