Drop unneeded generic type specifiers
[yangtools.git] / common / util / src / test / java / org / opendaylight / yangtools / util / concurrent / QueuedNotificationManagerTest.java
index 7cc028a9f0ae1caee48b58f8f57f1e218440b275..455ccdd1b0b974ad248bd46b7b01945a54cc1a81 100644 (file)
@@ -48,7 +48,7 @@ public class QueuedNotificationManagerTest {
 
         TestListener( int expCount, int id ) {
             name = "TestListener " + id;
-            actual = Collections.synchronizedList( Lists.<N>newArrayListWithCapacity( expCount ) );
+            actual = Collections.synchronizedList( Lists.newArrayListWithCapacity( expCount ) );
             reset( expCount );
         }
 
@@ -148,7 +148,7 @@ public class QueuedNotificationManagerTest {
 
         queueExecutor = Executors.newFixedThreadPool( 2 );
         NotificationManager<TestListener<Integer>, Integer> manager =
-                new QueuedNotificationManager<>( queueExecutor, new TestNotifier<Integer>(),
+                new QueuedNotificationManager<>( queueExecutor, new TestNotifier<>(),
                 10, "TestMgr" );
 
         int initialCount = 6;
@@ -162,7 +162,7 @@ public class QueuedNotificationManagerTest {
         manager.submitNotifications( listener, Arrays.asList( 4, 5 ) );
         manager.submitNotification( listener, 6 );
 
-        manager.submitNotifications( null, Collections.<Integer>emptyList() );
+        manager.submitNotifications( null, Collections.emptyList() );
         manager.submitNotifications( listener, null );
         manager.submitNotification( listener, null );
 
@@ -188,7 +188,7 @@ public class QueuedNotificationManagerTest {
         queueExecutor = Executors.newFixedThreadPool( nListeners );
         final ExecutorService stagingExecutor = Executors.newFixedThreadPool( nListeners );
         final NotificationManager<TestListener<Integer>, Integer> manager =
-                new QueuedNotificationManager<>( queueExecutor, new TestNotifier<Integer>(),
+                new QueuedNotificationManager<>( queueExecutor, new TestNotifier<>(),
                 5000, "TestMgr" );
 
         final int nNotifications = 100000;
@@ -206,9 +206,9 @@ public class QueuedNotificationManagerTest {
         List<TestListener<Integer>> listeners = Lists.newArrayList();
         for( int i = 1; i <= nListeners; i++ ) {
             final TestListener<Integer> listener =
-                    i == 2 ? new TestListener2<Integer>( nNotifications, i ) :
-                    i == 3 ? new TestListener3<Integer>( nNotifications, i ) :
-                                      new TestListener<Integer>( nNotifications, i );
+                    i == 2 ? new TestListener2<>(nNotifications, i) :
+                    i == 3 ? new TestListener3<>(nNotifications, i) :
+                            new TestListener<>(nNotifications, i);
             listeners.add( listener );
 
             new Thread( new Runnable() {
@@ -247,7 +247,7 @@ public class QueuedNotificationManagerTest {
 
         queueExecutor = Executors.newFixedThreadPool( 1 );
         NotificationManager<TestListener<Integer>, Integer> manager =
-                new QueuedNotificationManager<>( queueExecutor, new TestNotifier<Integer>(),
+                new QueuedNotificationManager<>( queueExecutor, new TestNotifier<>(),
                 10, "TestMgr" );
 
 
@@ -265,7 +265,7 @@ public class QueuedNotificationManagerTest {
 
         final CountDownLatch errorCaughtLatch = new CountDownLatch( 1 );
         queueExecutor = new ThreadPoolExecutor( 1, 1, 0, TimeUnit.SECONDS,
-                                                new LinkedBlockingQueue<Runnable>() ) {
+                new LinkedBlockingQueue<>() ) {
              @Override
              public void execute( final Runnable command ) {
                  super.execute( new Runnable() {
@@ -282,7 +282,7 @@ public class QueuedNotificationManagerTest {
         };
 
         NotificationManager<TestListener<Integer>, Integer> manager =
-                new QueuedNotificationManager<>( queueExecutor, new TestNotifier<Integer>(),
+                new QueuedNotificationManager<>( queueExecutor, new TestNotifier<>(),
                 10, "TestMgr" );
 
         TestListener<Integer> listener = new TestListener<>( 2, 1 );