Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--org.eclipse.ua.tests/help/org/eclipse/ua/tests/help/webextension/TitleSearchData.java8
-rw-r--r--org.eclipse.ua.tests/intro/org/eclipse/ua/tests/intro/util/IntroModelSerializerTest.java8
2 files changed, 8 insertions, 8 deletions
diff --git a/org.eclipse.ua.tests/help/org/eclipse/ua/tests/help/webextension/TitleSearchData.java b/org.eclipse.ua.tests/help/org/eclipse/ua/tests/help/webextension/TitleSearchData.java
index b6cceaa65..f6514570f 100644
--- a/org.eclipse.ua.tests/help/org/eclipse/ua/tests/help/webextension/TitleSearchData.java
+++ b/org.eclipse.ua.tests/help/org/eclipse/ua/tests/help/webextension/TitleSearchData.java
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2009 IBM Corporation and others.
+ * Copyright (c) 2009, 2011 IBM Corporation and others.
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at
@@ -29,7 +29,7 @@ public TitleSearchData(ServletContext context, HttpServletRequest request,
super(context, request, response);
}
-private List results;
+private List<SearchResult> results;
private String searchTerm;
public class SearchResult {
@@ -38,7 +38,7 @@ public class SearchResult {
}
public SearchResult[] getSearchResults() {
- results = new ArrayList();
+ results = new ArrayList<SearchResult>();
searchTerm = request.getParameter("searchWord");
IToc[] tocs = getTocs();
for (int i = 0; i < tocs.length; i++) {
@@ -47,7 +47,7 @@ public SearchResult[] getSearchResults() {
searchTopic(topics[t]);
}
}
- return (SearchResult[]) results.toArray(new SearchResult[results.size()]);
+ return results.toArray(new SearchResult[results.size()]);
}
private void searchTopic(ITopic topic) {
diff --git a/org.eclipse.ua.tests/intro/org/eclipse/ua/tests/intro/util/IntroModelSerializerTest.java b/org.eclipse.ua.tests/intro/org/eclipse/ua/tests/intro/util/IntroModelSerializerTest.java
index f5a9fd6cc..1aef09a72 100644
--- a/org.eclipse.ua.tests/intro/org/eclipse/ua/tests/intro/util/IntroModelSerializerTest.java
+++ b/org.eclipse.ua.tests/intro/org/eclipse/ua/tests/intro/util/IntroModelSerializerTest.java
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2005, 2007 IBM Corporation and others.
+ * Copyright (c) 2005, 2011 IBM Corporation and others.
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at
@@ -123,7 +123,7 @@ public class IntroModelSerializerTest extends TestCase {
*/
public static Map getXHTMLFiles(IntroModelRoot model) {
Map map = new HashMap();
- Collection pages = new ArrayList();
+ Collection<AbstractIntroPage> pages = new ArrayList<AbstractIntroPage>();
IntroHomePage home = model.getRootPage();
if (home.isXHTMLPage()) {
pages.add(home);
@@ -134,9 +134,9 @@ public class IntroModelSerializerTest extends TestCase {
pages.add(otherPages[i]);
}
}
- Iterator iter = pages.iterator();
+ Iterator<AbstractIntroPage> iter = pages.iterator();
while (iter.hasNext()) {
- AbstractIntroPage page = (AbstractIntroPage)iter.next();
+ AbstractIntroPage page = iter.next();
BrowserIntroPartImplementation impl = new BrowserIntroPartImplementation();
String xhtml = impl.generateXHTMLPage(page, new IIntroContentProviderSite() {
public void reflow(IIntroContentProvider provider, boolean incremental) {

Back to the top