From 35a408038c1de64a6f13f0e7b246a645e9945e3c Mon Sep 17 00:00:00 2001
From: boli <boli@localhost>
Date: Tue, 18 Mar 2008 22:44:58 +0000
Subject: [PATCH] With this refactoring:

---
 opends/src/server/org/opends/server/core/OperationWrapper.java |   66 ++++++++-------------------------
 1 files changed, 16 insertions(+), 50 deletions(-)

diff --git a/opends/src/server/org/opends/server/core/OperationWrapper.java b/opends/src/server/org/opends/server/core/OperationWrapper.java
index 31389bf..5027094 100644
--- a/opends/src/server/org/opends/server/core/OperationWrapper.java
+++ b/opends/src/server/org/opends/server/core/OperationWrapper.java
@@ -33,16 +33,7 @@
 import java.util.Map;
 
 import org.opends.server.api.ClientConnection;
-import org.opends.server.types.CancelRequest;
-import org.opends.server.types.CancelResult;
-import org.opends.server.types.Control;
-import org.opends.server.types.DN;
-import org.opends.server.types.DirectoryException;
-import org.opends.server.types.DisconnectReason;
-import org.opends.server.types.Entry;
-import org.opends.server.types.Operation;
-import org.opends.server.types.OperationType;
-import org.opends.server.types.ResultCode;
+import org.opends.server.types.*;
 
 
 /**
@@ -108,6 +99,14 @@
   /**
    * {@inheritDoc}
    */
+  public void abort(CancelRequest cancelRequest)
+  {
+    operation.abort(cancelRequest);
+  }
+
+  /**
+   * {@inheritDoc}
+   */
   public void disconnectClient(
           DisconnectReason disconnectReason,
           boolean sendNotification,
@@ -329,14 +328,6 @@
   /**
    * {@inheritDoc}
    */
-  public void indicateCancelled(CancelRequest cancelRequest)
-  {
-    operation.indicateCancelled(cancelRequest);
-  }
-
-  /**
-   * {@inheritDoc}
-   */
   public boolean isInternalOperation()
   {
     return operation.isInternalOperation();
@@ -417,22 +408,6 @@
   /**
    * {@inheritDoc}
    */
-  public boolean setCancelRequest(CancelRequest cancelRequest)
-  {
-    return operation.setCancelRequest(cancelRequest);
-  }
-
-  /**
-   * {@inheritDoc}
-   */
-  public void setCancelResult(CancelResult cancelResult)
-  {
-    operation.setCancelResult(cancelResult);
-  }
-
-  /**
-   * {@inheritDoc}
-   */
   public void setDontSynchronize(boolean dontSynchronize)
   {
     operation.setDontSynchronize(dontSynchronize);
@@ -465,22 +440,6 @@
   /**
    * {@inheritDoc}
    */
-  public void setProcessingStartTime()
-  {
-    operation.setProcessingStartTime();
-  }
-
-  /**
-   * {@inheritDoc}
-   */
-  public void setProcessingStopTime()
-  {
-    operation.setProcessingStopTime();
-  }
-
-  /**
-   * {@inheritDoc}
-   */
   public void setReferralURLs(List<String> referralURLs)
   {
     operation.setReferralURLs(referralURLs);
@@ -518,5 +477,12 @@
     operation.toString(buffer);
   }
 
+  /**
+   * {@inheritDoc}
+   */
+  public synchronized final void checkIfCanceled(boolean signalTooLate)
+      throws CanceledOperationException {
+    operation.checkIfCanceled(signalTooLate);
+  }
 }
 

--
Gitblit v1.10.0