From 83f86f11c27378d650c3bfc7e55397687062edbc Mon Sep 17 00:00:00 2001
From: Jean-Noël Rouvignac <jean-noel.rouvignac@forgerock.com>
Date: Fri, 22 Apr 2016 14:23:28 +0000
Subject: [PATCH] Improvements suggested by UCDetector: remove dead code, add final keywords, change visibilities

---
 opendj-server-legacy/src/main/java/org/opends/guitools/controlpanel/ui/TableViewEntryPanel.java |   20 ++++++++++----------
 1 files changed, 10 insertions(+), 10 deletions(-)

diff --git a/opendj-server-legacy/src/main/java/org/opends/guitools/controlpanel/ui/TableViewEntryPanel.java b/opendj-server-legacy/src/main/java/org/opends/guitools/controlpanel/ui/TableViewEntryPanel.java
index e5af34d..faf1b72 100644
--- a/opendj-server-legacy/src/main/java/org/opends/guitools/controlpanel/ui/TableViewEntryPanel.java
+++ b/opendj-server-legacy/src/main/java/org/opends/guitools/controlpanel/ui/TableViewEntryPanel.java
@@ -68,7 +68,7 @@
 import org.opends.server.util.ServerConstants;
 
 /** The panel displaying a table view of an LDAP entry. */
-public class TableViewEntryPanel extends ViewEntryPanel
+class TableViewEntryPanel extends ViewEntryPanel
 {
   private static final long serialVersionUID = 2135331526526472175L;
   private CustomSearchResult searchResult;
@@ -382,13 +382,13 @@
   }
 
   /** The table model used by the tree in the panel. */
-  protected class LDAPEntryTableModel extends SortableTableModel
+  private class LDAPEntryTableModel extends SortableTableModel
   implements Comparator<AttributeValuePair>
   {
     private static final long serialVersionUID = -1240282431326505113L;
-    private ArrayList<AttributeValuePair> dataArray = new ArrayList<>();
-    private SortedSet<AttributeValuePair> allSortedValues = new TreeSet<>(this);
-    private Set<String> requiredAttrs = new HashSet<>();
+    private final List<AttributeValuePair> dataArray = new ArrayList<>();
+    private final SortedSet<AttributeValuePair> allSortedValues = new TreeSet<>(this);
+    private final Set<String> requiredAttrs = new HashSet<>();
     private final String[] COLUMN_NAMES = new String[] {
         getHeader(LocalizableMessage.raw("Attribute"), 40),
         getHeader(LocalizableMessage.raw("Value", 40))};
@@ -399,7 +399,7 @@
      * Updates the contents of the table model with the
      * {@code TableViewEntryPanel.searchResult} object.
      */
-    public void displayEntry()
+    private void displayEntry()
     {
       updateDataArray();
       fireTableDataChanged();
@@ -809,18 +809,18 @@
    * used by the table model to be able to retrieve more easily all the values
    * for a given attribute.
    */
-  static class AttributeValuePair
+  private static class AttributeValuePair
   {
     /** The attribute name. */
-    String attrName;
+    private final String attrName;
     /** The value. */
-    Object value;
+    private Object value;
     /**
      * Constructor.
      * @param attrName the attribute name.
      * @param value the value.
      */
-    public AttributeValuePair(String attrName, Object value)
+    private AttributeValuePair(String attrName, Object value)
     {
       this.attrName = attrName;
       this.value = value;

--
Gitblit v1.10.0