ICU-5445 Fix some compiler warnings.
X-SVN-Rev: 21889
This commit is contained in:
parent
d87b4bbd63
commit
c29558e875
@ -1,6 +1,6 @@
|
||||
/**
|
||||
*******************************************************************************
|
||||
* Copyright (C) 2001-2005, International Business Machines Corporation and *
|
||||
* Copyright (C) 2001-2007, International Business Machines Corporation and *
|
||||
* others. All Rights Reserved. *
|
||||
*******************************************************************************
|
||||
*/
|
||||
@ -131,9 +131,9 @@ public class AnyTransliterator extends Transliterator {
|
||||
private boolean done = true;
|
||||
|
||||
|
||||
public void reset(Replaceable text, Position expanse) {
|
||||
set(this.expanse, expanse);
|
||||
this.text = text;
|
||||
public void reset(Replaceable repText, Position expansePos) {
|
||||
set(this.expanse, expansePos);
|
||||
this.text = repText;
|
||||
reset();
|
||||
}
|
||||
|
||||
|
@ -759,12 +759,12 @@ public abstract class PerfTest {
|
||||
return data;
|
||||
}
|
||||
|
||||
public String[] readLines(String fileName, String encoding, boolean bulkMode) {
|
||||
public String[] readLines(String filename, String encoding, boolean bulkMode) {
|
||||
FileInputStream fis = null;
|
||||
InputStreamReader isr = null;
|
||||
BufferedReader br = null;
|
||||
try {
|
||||
fis = new FileInputStream(fileName);
|
||||
fis = new FileInputStream(filename);
|
||||
isr = new InputStreamReader(fis, encoding);
|
||||
br = new BufferedReader(isr);
|
||||
} catch (Exception e) {
|
||||
|
@ -1,6 +1,6 @@
|
||||
/*
|
||||
*******************************************************************************
|
||||
* Copyright (C) 1998-2004, International Business Machines Corporation and *
|
||||
* Copyright (C) 1998-2007, International Business Machines Corporation and *
|
||||
* others. All Rights Reserved. *
|
||||
*******************************************************************************
|
||||
*
|
||||
@ -69,8 +69,8 @@ public class LigatureTreeWalker extends TreeWalker implements LookupSubtable
|
||||
}
|
||||
protected int firstComponentChar(int ligatureSetIndex)
|
||||
{
|
||||
Vector ligatureSet = (Vector) ligatureSets.elementAt(ligatureSetIndex);
|
||||
LigatureEntry firstEntry = (LigatureEntry) ligatureSet.elementAt(0);
|
||||
Vector aLigatureSet = (Vector) ligatureSets.elementAt(ligatureSetIndex);
|
||||
LigatureEntry firstEntry = (LigatureEntry) aLigatureSet.elementAt(0);
|
||||
|
||||
return firstEntry.getComponentChar(0);
|
||||
}
|
||||
@ -110,8 +110,8 @@ public class LigatureTreeWalker extends TreeWalker implements LookupSubtable
|
||||
for (int set = 0; set < ligatureSetCount; set += 1) {
|
||||
System.out.print(Utility.hex(firstComponentChar(set), 6) + ": ");
|
||||
|
||||
Vector ligatureSet = (Vector) ligatureSets.elementAt(set);
|
||||
int ligatureCount = ligatureSet.size();
|
||||
Vector aLigatureSet = (Vector) ligatureSets.elementAt(set);
|
||||
int ligatureCount = aLigatureSet.size();
|
||||
int ligatureSetAddress = writer.getOutputIndex();
|
||||
|
||||
System.out.println(ligatureCount + " ligatures.");
|
||||
@ -125,14 +125,14 @@ public class LigatureTreeWalker extends TreeWalker implements LookupSubtable
|
||||
}
|
||||
|
||||
for (int lig = 0; lig < ligatureCount; lig += 1) {
|
||||
LigatureEntry entry = (LigatureEntry) ligatureSet.elementAt(lig);
|
||||
int componentCount = entry.getComponentCount();
|
||||
LigatureEntry entry = (LigatureEntry) aLigatureSet.elementAt(lig);
|
||||
int compCount = entry.getComponentCount();
|
||||
|
||||
writer.fixOffset(ligatureTableOffset++, ligatureSetAddress);
|
||||
writer.writeData(entry.getLigature());
|
||||
writer.writeData(componentCount);
|
||||
writer.writeData(compCount);
|
||||
|
||||
for (int comp = 1; comp < componentCount; comp += 1) {
|
||||
for (int comp = 1; comp < compCount; comp += 1) {
|
||||
writer.writeData(entry.getComponentChar(comp));
|
||||
}
|
||||
}
|
||||
|
@ -500,8 +500,8 @@ public class ICULocaleService extends ICUService {
|
||||
return null;
|
||||
}
|
||||
|
||||
protected boolean isSupportedID(String id) {
|
||||
return this.id.equals(id);
|
||||
protected boolean isSupportedID(String idToCheck) {
|
||||
return this.id.equals(idToCheck);
|
||||
}
|
||||
|
||||
public void updateVisibleIDs(Map result) {
|
||||
|
@ -207,8 +207,8 @@ public class ICUService extends ICUNotifier {
|
||||
* If a key created from id would eventually fallback to match the
|
||||
* canonical ID of this key, return true.
|
||||
*/
|
||||
public boolean isFallbackOf(String id) {
|
||||
return canonicalID().equals(id);
|
||||
public boolean isFallbackOf(String idToCheck) {
|
||||
return canonicalID().equals(idToCheck);
|
||||
}
|
||||
}
|
||||
|
||||
@ -760,11 +760,11 @@ public class ICUService extends ICUNotifier {
|
||||
}
|
||||
|
||||
|
||||
SortedMap get(ULocale locale, Comparator com) {
|
||||
SortedMap get(ULocale loc, Comparator comp) {
|
||||
SortedMap m = (SortedMap)ref.get();
|
||||
if (m != null &&
|
||||
this.locale.equals(locale) &&
|
||||
(this.com == com || (this.com != null && this.com.equals(com)))) {
|
||||
this.locale.equals(loc) &&
|
||||
(this.com == comp || (this.com != null && this.com.equals(comp)))) {
|
||||
|
||||
return m;
|
||||
}
|
||||
|
@ -146,7 +146,7 @@ public class ITestTextPanel extends Frame implements ActionListener {
|
||||
private static final int OP_COUNT = 15;
|
||||
|
||||
public void selectOperation(Frame frame,
|
||||
Clipboard fClipboard) {
|
||||
Clipboard clipboard) {
|
||||
|
||||
int op = fTest.randInt(OP_COUNT);
|
||||
|
||||
@ -162,7 +162,7 @@ public class ITestTextPanel extends Frame implements ActionListener {
|
||||
break;
|
||||
|
||||
case 2:
|
||||
fTest._testEditMenuOperations(fClipboard);
|
||||
fTest._testEditMenuOperations(clipboard);
|
||||
break;
|
||||
|
||||
case 3:
|
||||
|
@ -90,11 +90,11 @@ public class TestTextPanel /*extends TestFmwk*/ {
|
||||
assertNotExpectingEvents(false, 0, false);
|
||||
}
|
||||
|
||||
void assertNotExpectingEvents(int iterationCount, boolean exp) {
|
||||
assertNotExpectingEvents(true, iterationCount, exp);
|
||||
void assertNotExpectingEvents(int iterCount, boolean exp) {
|
||||
assertNotExpectingEvents(true, iterCount, exp);
|
||||
}
|
||||
|
||||
private void assertNotExpectingEvents(boolean logDetails, int iterationCount, boolean exp) {
|
||||
private void assertNotExpectingEvents(boolean logDetails, int iterCount, boolean exp) {
|
||||
|
||||
boolean e = false;
|
||||
for (int i=0; i < status.length; i++) {
|
||||
@ -102,7 +102,7 @@ public class TestTextPanel /*extends TestFmwk*/ {
|
||||
if (logDetails) {
|
||||
logMessage("Expecting event " +
|
||||
(i+TextPanelEvent.TEXT_PANEL_FIRST));
|
||||
logMessage("iterationCount="+iterationCount+"; expexting="+exp);
|
||||
logMessage("iterationCount="+iterCount+"; expexting="+exp);
|
||||
}
|
||||
e = true;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user