Add type parameters for org.eclipse.team.internal.ui.mapping

Add type parameters to collections for
org.eclipse.team.internal.ui.mapping

Change-Id: Ic36b17f60816692085b5232f5816774dc81a9083
Signed-off-by: Alexander Fedorov <alexander.fedorov@arsysop.ru>
diff --git a/bundles/org.eclipse.team.ui/src/org/eclipse/team/internal/ui/mapping/AbstractCompareInput.java b/bundles/org.eclipse.team.ui/src/org/eclipse/team/internal/ui/mapping/AbstractCompareInput.java
index 400e3a6..bf4e841 100644
--- a/bundles/org.eclipse.team.ui/src/org/eclipse/team/internal/ui/mapping/AbstractCompareInput.java
+++ b/bundles/org.eclipse.team.ui/src/org/eclipse/team/internal/ui/mapping/AbstractCompareInput.java
@@ -1,5 +1,5 @@
 /*******************************************************************************
- * Copyright (c) 2006 IBM Corporation and others.
+ * Copyright (c) 2006, 2020 IBM Corporation and others.
  *
  * This program and the accompanying materials
  * are made available under the terms of the Eclipse Public License 2.0
@@ -32,7 +32,7 @@
 	private ITypedElement left;
 	private ITypedElement right;
 	private int kind;
-	private final ListenerList listeners = new ListenerList(ListenerList.IDENTITY);
+	private final ListenerList<ICompareInputChangeListener> listeners = new ListenerList<>(ListenerList.IDENTITY);
 
 	public AbstractCompareInput(int kind,
 			ITypedElement ancestor,
diff --git a/bundles/org.eclipse.team.ui/src/org/eclipse/team/internal/ui/mapping/CompareInputChangeNotifier.java b/bundles/org.eclipse.team.ui/src/org/eclipse/team/internal/ui/mapping/CompareInputChangeNotifier.java
index db7fc02..5f86253 100644
--- a/bundles/org.eclipse.team.ui/src/org/eclipse/team/internal/ui/mapping/CompareInputChangeNotifier.java
+++ b/bundles/org.eclipse.team.ui/src/org/eclipse/team/internal/ui/mapping/CompareInputChangeNotifier.java
@@ -1,5 +1,5 @@
 /*******************************************************************************
- * Copyright (c) 2006, 2017 IBM Corporation and others.
+ * Copyright (c) 2006, 2020 IBM Corporation and others.
  *
  * This program and the accompanying materials
  * are made available under the terms of the Eclipse Public License 2.0
@@ -89,7 +89,7 @@
 	private class InputChangeEventHandler extends BackgroundEventHandler {
 
 		private final Set<ICompareInput> changedInputs = new HashSet<>();
-		private final List pendingRunnables = new ArrayList();
+		private final List<Event> pendingRunnables = new ArrayList<>();
 
 		protected InputChangeEventHandler() {
 			super(TeamUIMessages.CompareInputChangeNotifier_0, TeamUIMessages.CompareInputChangeNotifier_1);
@@ -105,7 +105,7 @@
 					if (changedInputs.isEmpty() && pendingRunnables.isEmpty())
 						return false;
 					toDispatch = changedInputs.toArray(new ICompareInput[changedInputs.size()]);
-					events = (RunnableEvent[]) pendingRunnables.toArray(new RunnableEvent[pendingRunnables.size()]);
+					events = pendingRunnables.toArray(new RunnableEvent[pendingRunnables.size()]);
 					changedInputs.clear();
 					pendingRunnables.clear();
 				}
diff --git a/bundles/org.eclipse.team.ui/src/org/eclipse/team/internal/ui/mapping/ModelElementSelectionPage.java b/bundles/org.eclipse.team.ui/src/org/eclipse/team/internal/ui/mapping/ModelElementSelectionPage.java
index 55e3a64..b900c19 100644
--- a/bundles/org.eclipse.team.ui/src/org/eclipse/team/internal/ui/mapping/ModelElementSelectionPage.java
+++ b/bundles/org.eclipse.team.ui/src/org/eclipse/team/internal/ui/mapping/ModelElementSelectionPage.java
@@ -1,5 +1,5 @@
 /*******************************************************************************
- * Copyright (c) 2006, 2017 IBM Corporation and others.
+ * Copyright (c) 2006, 2020 IBM Corporation and others.
  *
  * This program and the accompanying materials
  * are made available under the terms of the Eclipse Public License 2.0
@@ -166,7 +166,7 @@
 
 	@Override
 	protected boolean checkWorkingSetElements() {
-		List allWorkingSetElements = new ArrayList();
+		List<Object> allWorkingSetElements = new ArrayList<>();
 		IWorkingSet[] workingSets = getWorkingSets();
 		for (IWorkingSet set : workingSets) {
 			allWorkingSetElements.addAll(computeSelectedResources(new StructuredSelection(set.getElements())));
@@ -175,8 +175,8 @@
 		return !allWorkingSetElements.isEmpty();
 	}
 
-	private Collection computeSelectedResources(StructuredSelection selection) {
-		List result = new ArrayList();
+	private Collection<Object> computeSelectedResources(StructuredSelection selection) {
+		List<Object> result = new ArrayList<>();
 		for (Iterator iter = selection.iterator(); iter.hasNext();) {
 			Object element = iter.next();
 			ResourceMapping mapping = Utils.getResourceMapping(element);