[hornetq-commits] JBoss hornetq SVN: r12062 - trunk/hornetq-core/src/main/java/org/hornetq/core/settings/impl.

do-not-reply at jboss.org do-not-reply at jboss.org
Wed Feb 1 11:48:48 EST 2012


Author: borges
Date: 2012-02-01 11:48:48 -0500 (Wed, 01 Feb 2012)
New Revision: 12062

Modified:
   trunk/hornetq-core/src/main/java/org/hornetq/core/settings/impl/HierarchicalObjectRepository.java
Log:
<T extends String> is non-sense, as String is 'final'.

Modified: trunk/hornetq-core/src/main/java/org/hornetq/core/settings/impl/HierarchicalObjectRepository.java
===================================================================
--- trunk/hornetq-core/src/main/java/org/hornetq/core/settings/impl/HierarchicalObjectRepository.java	2012-02-01 16:48:31 UTC (rev 12061)
+++ trunk/hornetq-core/src/main/java/org/hornetq/core/settings/impl/HierarchicalObjectRepository.java	2012-02-01 16:48:48 UTC (rev 12062)
@@ -47,7 +47,7 @@
     * all the matches
     */
    private final Map<String, Match<T>> matches = new HashMap<String, Match<T>>();
-   
+
    /**
     * Certain values cannot be removed after installed.
     * This is because we read a few records from the main config.
@@ -60,7 +60,7 @@
    /**
     * a regex comparator
     */
-   private final MatchComparator<String> matchComparator = new MatchComparator<String>();
+   private final MatchComparator matchComparator = new MatchComparator();
 
    /**
     * a cache
@@ -72,13 +72,13 @@
     */
    private final ArrayList<HierarchicalRepositoryChangeListener> listeners = new ArrayList<HierarchicalRepositoryChangeListener>();
 
-   
+
    public void addMatch(final String match, final T value)
    {
       addMatch(match, value, false);
    }
-   
 
+
    /**
     * Add a new match to the repository
     *
@@ -98,7 +98,7 @@
       matches.put(match, match1);
       onChange();
    }
-   
+
    public int getCacheSize()
    {
       return cache.size();
@@ -220,12 +220,12 @@
       listeners.clear();
       matches.clear();
    }
-   
+
    public void clearListeners()
    {
       listeners.clear();
    }
-   
+
    public void clearCache()
    {
       cache.clear();
@@ -268,7 +268,7 @@
    /**
     * compares to matches to see which one is more specific
     */
-   private static class MatchComparator<T extends String> implements Comparator<T>
+   private static class MatchComparator implements Comparator<String>
    {
       public int compare(final String o1, final String o2)
       {



More information about the hornetq-commits mailing list