From f2160f4bd1c8ac67e5a86a6710d431e8932877f9 Mon Sep 17 00:00:00 2001
From: matthew_swift <matthew_swift@localhost>
Date: Fri, 28 May 2010 11:47:51 +0000
Subject: [PATCH] Synchronize SDK on java.net with internal repository.

---
 sdk/src/org/opends/sdk/controls/ControlDecoder.java |   39 ++++++++++++++++++---------------------
 1 files changed, 18 insertions(+), 21 deletions(-)

diff --git a/sdk/src/org/opends/sdk/controls/ControlDecoder.java b/sdk/src/org/opends/sdk/controls/ControlDecoder.java
index 83f34f6..2d6c32e 100644
--- a/sdk/src/org/opends/sdk/controls/ControlDecoder.java
+++ b/sdk/src/org/opends/sdk/controls/ControlDecoder.java
@@ -22,51 +22,48 @@
  * CDDL HEADER END
  *
  *
- *      Copyright 2008 Sun Microsystems, Inc.
+ *      Copyright 2010 Sun Microsystems, Inc.
  */
+
 package org.opends.sdk.controls;
 
 
 
-import org.opends.sdk.ByteString;
 import org.opends.sdk.DecodeException;
-import org.opends.sdk.schema.Schema;
+import org.opends.sdk.DecodeOptions;
 
 
 
 /**
- * An interface for decoding controls.
+ * A factory interface for decoding a control as a control of specific type.
  *
- * @param <T>
- *          The type of control decoded by this decoder.
+ * @param <C>
+ *          The type of control decoded by this control decoder.
  */
-public interface ControlDecoder<T extends Control>
+public interface ControlDecoder<C extends Control>
 {
-
   /**
-   * Decodes the provided control.
+   * Decodes the provided control as a {@code Control} of type {@code C}.
    *
-   * @param isCritical
-   *          Indicates whether the control should be considered
-   *          critical.
-   * @param value
-   *          The value for the control.
-   * @param schema
-   *          The schema which should be used when decoding the control,
-   *          if required.
+   * @param control
+   *          The control to be decoded.
+   * @param options
+   *          The set of decode options which should be used when decoding the
+   *          control.
    * @return The decoded control.
    * @throws DecodeException
-   *           If the control could not be decoded.
+   *           If the control contained the wrong OID, it did not have a value,
+   *           or if its value could not be decoded.
    */
-  T decode(boolean isCritical, ByteString value, Schema schema)
+  C decodeControl(Control control, DecodeOptions options)
       throws DecodeException;
 
 
 
   /**
-   * Gets the OID of the control decoded by this decoded.
+   * Returns the numeric OID associated with this control decoder.
    *
-   * @return The OID of the control decoded by this decoded.
+   * @return The numeric OID associated with this control decoder.
    */
   String getOID();
 }

--
Gitblit v1.10.0