From e9ff5bb70f5aee3084d405679b6c7d5b76842470 Mon Sep 17 00:00:00 2001
From: matthew_swift <matthew_swift@localhost>
Date: Fri, 06 Feb 2009 11:45:32 +0000
Subject: [PATCH] Add readStartSet and readEndSet methods to ASN1Reader for consistency with ASNWriter APIs. Also add writeStartSet(byte) method to ASN1Writer for consistency with sequence related methods.

---
 opendj-sdk/opends/src/server/org/opends/server/protocols/asn1/ASN1OutputStreamWriter.java |   12 +++++++++++-
 1 files changed, 11 insertions(+), 1 deletions(-)

diff --git a/opendj-sdk/opends/src/server/org/opends/server/protocols/asn1/ASN1OutputStreamWriter.java b/opendj-sdk/opends/src/server/org/opends/server/protocols/asn1/ASN1OutputStreamWriter.java
index 1466696..b85166e 100644
--- a/opendj-sdk/opends/src/server/org/opends/server/protocols/asn1/ASN1OutputStreamWriter.java
+++ b/opendj-sdk/opends/src/server/org/opends/server/protocols/asn1/ASN1OutputStreamWriter.java
@@ -435,7 +435,17 @@
    */
   public ASN1Writer writeStartSet() throws IOException
   {
-    return writeStartSequence(UNIVERSAL_SET_TYPE);
+    return writeStartSet(UNIVERSAL_SET_TYPE);
+  }
+
+  /**
+   * {@inheritDoc}
+   */
+  public ASN1Writer writeStartSet(byte type) throws IOException
+  {
+    // From an implementation point of view, a set is equivalent to a
+    // sequence.
+    return writeStartSequence(type);
   }
 
   /**

--
Gitblit v1.10.0