[java-opensaml COMMIT] in /trunk/opensaml-core/src: main/java/org/opensaml/core/xml/util/AbstractSimpleSingletonFacto...

noreply at shibboleth.net noreply at shibboleth.net
Sat Jun 13 16:22:44 EDT 2015


Author: scantor
Date: Sat Jun 13 16:22:44 2015
New Revision: 4302

URL: http://svn.shibboleth.net/view/java-opensaml?rev=4302&view=rev
Log:
Remove some redundant type arguments.

Modified:
    trunk/opensaml-core/src/main/java/org/opensaml/core/xml/util/AbstractSimpleSingletonFactory.java
    trunk/opensaml-core/src/main/java/org/opensaml/core/xml/util/AbstractWrappedSingletonFactory.java
    trunk/opensaml-core/src/main/java/org/opensaml/core/xml/util/AttributeMap.java
    trunk/opensaml-core/src/main/java/org/opensaml/core/xml/util/XMLObjectChildrenList.java
    trunk/opensaml-core/src/test/java/org/opensaml/core/xml/IDAttributeTest.java
    trunk/opensaml-core/src/test/java/org/opensaml/core/xml/mock/SimpleXMLObject.java
    trunk/opensaml-core/src/test/java/org/opensaml/core/xml/util/IndexedXMLObjectChildrenListTest.java
    trunk/opensaml-core/src/test/java/org/opensaml/core/xml/util/XMLObjectChildrenListTest.java

Modified: trunk/opensaml-core/src/main/java/org/opensaml/core/xml/util/AbstractSimpleSingletonFactory.java
URL: http://svn.shibboleth.net/view/java-opensaml/trunk/opensaml-core/src/main/java/org/opensaml/core/xml/util/AbstractSimpleSingletonFactory.java?rev=4302&r1=4301&r2=4302&view=diff
==============================================================================
--- trunk/opensaml-core/src/main/java/org/opensaml/core/xml/util/AbstractSimpleSingletonFactory.java	(original)
+++ trunk/opensaml-core/src/main/java/org/opensaml/core/xml/util/AbstractSimpleSingletonFactory.java	Sat Jun 13 16:22:44 2015
@@ -48,7 +48,7 @@
     
     /** Constructor. */
     public AbstractSimpleSingletonFactory() {
-        map = new WeakHashMap<Input, Output>();
+        map = new WeakHashMap<>();
     }
     
     /** {@inheritDoc} */
@@ -61,4 +61,4 @@
         map.put(input, output);
     }
     
-}
+}

Modified: trunk/opensaml-core/src/main/java/org/opensaml/core/xml/util/AbstractWrappedSingletonFactory.java
URL: http://svn.shibboleth.net/view/java-opensaml/trunk/opensaml-core/src/main/java/org/opensaml/core/xml/util/AbstractWrappedSingletonFactory.java?rev=4302&r1=4301&r2=4302&view=diff
==============================================================================
--- trunk/opensaml-core/src/main/java/org/opensaml/core/xml/util/AbstractWrappedSingletonFactory.java	(original)
+++ trunk/opensaml-core/src/main/java/org/opensaml/core/xml/util/AbstractWrappedSingletonFactory.java	Sat Jun 13 16:22:44 2015
@@ -103,9 +103,9 @@
      *              output instances when garbage collection is desired.
      */
     public AbstractWrappedSingletonFactory(boolean requireExplicitRelease) {
-        map = new WeakHashMap<Input, WeakReference<Output>>();
+        map = new WeakHashMap<>();
         explicitRelease = requireExplicitRelease;
-        outputSet = new HashSet<Output>();
+        outputSet = new HashSet<>();
     }
     
     /**
@@ -201,7 +201,7 @@
      * </p>
      */
     protected synchronized void put(Input input, Output output) {
-        map.put(input, new WeakReference<Output>(output));
-    }
-
-}
+        map.put(input, new WeakReference<>(output));
+    }
+
+}

Modified: trunk/opensaml-core/src/main/java/org/opensaml/core/xml/util/AttributeMap.java
URL: http://svn.shibboleth.net/view/java-opensaml/trunk/opensaml-core/src/main/java/org/opensaml/core/xml/util/AttributeMap.java?rev=4302&r1=4301&r2=4302&view=diff
==============================================================================
--- trunk/opensaml-core/src/main/java/org/opensaml/core/xml/util/AttributeMap.java	(original)
+++ trunk/opensaml-core/src/main/java/org/opensaml/core/xml/util/AttributeMap.java	Sat Jun 13 16:22:44 2015
@@ -78,9 +78,9 @@
         Constraint.isNotNull(newOwner, "Attribute owner XMLObject cannot be null");
 
         attributeOwner = newOwner;
-        attributes = new LazyMap<QName, String>();
-        idAttribNames = new LazySet<QName>();
-        qnameAttribNames = new LazySet<QName>();
+        attributes = new LazyMap<>();
+        idAttribNames = new LazySet<>();
+        qnameAttribNames = new LazySet<>();
     }
 
     /** {@inheritDoc} */
@@ -146,7 +146,7 @@
 
     /** {@inheritDoc} */
     public void clear() {
-        LazySet<QName> keys = new LazySet<QName>();
+        LazySet<QName> keys = new LazySet<>();
         keys.addAll(attributes.keySet());
         for (QName attributeName : keys) {
             remove(attributeName);

Modified: trunk/opensaml-core/src/main/java/org/opensaml/core/xml/util/XMLObjectChildrenList.java
URL: http://svn.shibboleth.net/view/java-opensaml/trunk/opensaml-core/src/main/java/org/opensaml/core/xml/util/XMLObjectChildrenList.java?rev=4302&r1=4301&r2=4302&view=diff
==============================================================================
--- trunk/opensaml-core/src/main/java/org/opensaml/core/xml/util/XMLObjectChildrenList.java	(original)
+++ trunk/opensaml-core/src/main/java/org/opensaml/core/xml/util/XMLObjectChildrenList.java	Sat Jun 13 16:22:44 2015
@@ -56,7 +56,7 @@
         Constraint.isNotNull(newParent, "Parent cannot be null");
 
         parent = newParent;

[... 198 lines stripped ...]


More information about the commits mailing list