From fe9b2994e042be96cb148e52fc58653fcf09aa9d Mon Sep 17 00:00:00 2001
From: Jean-Noel Rouvignac <jean-noel.rouvignac@forgerock.com>
Date: Wed, 04 Sep 2013 08:43:15 +0000
Subject: [PATCH] In javadocs, variable names, method names, etc., renamed: - "draft change number" to "change number" - "draftCN" to "change number" - "sn" to "cn" in tests. Fixed wrong usage of seqnum (only defined for CSNs - see the various IETF draft)

---
 opends/src/server/org/opends/server/replication/server/changelog/je/ReplicationDraftCNKey.java |   19 +++++++++----------
 1 files changed, 9 insertions(+), 10 deletions(-)

diff --git a/opends/src/server/org/opends/server/replication/server/changelog/je/ReplicationDraftCNKey.java b/opends/src/server/org/opends/server/replication/server/changelog/je/ReplicationDraftCNKey.java
index e275295..8d01875 100644
--- a/opends/src/server/org/opends/server/replication/server/changelog/je/ReplicationDraftCNKey.java
+++ b/opends/src/server/org/opends/server/replication/server/changelog/je/ReplicationDraftCNKey.java
@@ -39,18 +39,18 @@
   private static final long serialVersionUID = 1L;
 
   /**
-   * Creates a new ReplicationKey from the given draft ChangeNumber.
-   * @param draftCN The draft change number to use.
+   * Creates a new ReplicationKey from the given change number.
+   * @param changeNumber The change number to use.
    */
-  public ReplicationDraftCNKey(int draftCN)
+  public ReplicationDraftCNKey(int changeNumber)
   {
     try
     {
-      String s = String.valueOf(draftCN);
+      String s = String.valueOf(changeNumber);
       int a = 16-s.length();
       String sscn = "0000000000000000".substring(0, a) + s;
       // Should it use StaticUtils.getBytes() to increase performances?
-      this.setData(sscn.getBytes("UTF-8"));
+      setData(sscn.getBytes("UTF-8"));
     } catch (UnsupportedEncodingException e)
     {
       // Should never happens, UTF-8 is always supported
@@ -59,12 +59,11 @@
   }
 
   /**
-   * Getter for the draft change number associated with this key.
-   * @return the draft change number associated with this key.
+   * Getter for the change number associated with this key.
+   * @return the change number associated with this key.
    */
-  public int getDraftCN()
+  public int getChangeNumber()
   {
-    String s = new String(this.getData());
-    return Integer.valueOf(s);
+    return Integer.valueOf(new String(getData()));
   }
 }

--
Gitblit v1.10.0