mirror of https://github.com/apache/lucene.git
clear up more compiler warnings
git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/trunk@1003906 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
2579edf45f
commit
c8b7a21b4b
|
@ -30,6 +30,7 @@ package org.apache.lucene.spatial.tier.projections;
|
|||
*
|
||||
* @deprecated Until we can put in place proper tests and a proper fix.
|
||||
*/
|
||||
@Deprecated
|
||||
public class SinusoidalProjector implements IProjector {
|
||||
|
||||
|
||||
|
|
|
@ -3860,6 +3860,7 @@ public class TestIndexWriter extends LuceneTestCase {
|
|||
break;
|
||||
case 3:
|
||||
writer2.optimize();
|
||||
break;
|
||||
case 4:
|
||||
writer2.commit();
|
||||
}
|
||||
|
|
|
@ -258,7 +258,7 @@ public class TernaryTree implements Cloneable, Serializable {
|
|||
}
|
||||
}
|
||||
if (a[start + i] != 0) {
|
||||
return (int) -a[start + i];
|
||||
return -a[start + i];
|
||||
}
|
||||
return 0;
|
||||
|
||||
|
|
|
@ -15,8 +15,8 @@
|
|||
*/
|
||||
|
||||
// Generated from IANA Root Zone Database <http://www.internic.net/zones/root.zone>
|
||||
// file version from Tuesday, September 14, 2010 11:34:20 AM UTC
|
||||
// generated on Wednesday, September 15, 2010 7:00:44 AM UTC
|
||||
// file version from Saturday, October 2, 2010 11:34:09 AM UTC
|
||||
// generated on Saturday, October 2, 2010 10:07:09 PM UTC
|
||||
// by org.apache.lucene.analysis.standard.GenerateJflexTLDMacros
|
||||
|
||||
ASCIITLD = "." (
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* The following code was generated by JFlex 1.5.0-SNAPSHOT on 9/15/10 3:01 AM */
|
||||
/* The following code was generated by JFlex 1.5.0-SNAPSHOT on 10/2/10 6:07 PM */
|
||||
|
||||
package org.apache.lucene.analysis.standard;
|
||||
|
||||
|
@ -33,8 +33,8 @@ import org.apache.lucene.analysis.tokenattributes.CharTermAttribute;
|
|||
/**
|
||||
* This class is a scanner generated by
|
||||
* <a href="http://www.jflex.de/">JFlex</a> 1.5.0-SNAPSHOT
|
||||
* on 9/15/10 3:01 AM from the specification file
|
||||
* <tt>c:/Users/us/IdeaProjects/lucene/test-dev-trunk/modules/analysis/common/src/java/org/apache/lucene/analysis/standard/ClassicTokenizerImpl.jflex</tt>
|
||||
* on 10/2/10 6:07 PM from the specification file
|
||||
* <tt>C:/Users/rmuir/workspace/lucene-clean/modules/analysis/common/src/java/org/apache/lucene/analysis/standard/ClassicTokenizerImpl.jflex</tt>
|
||||
*/
|
||||
class ClassicTokenizerImpl implements StandardTokenizerInterface {
|
||||
|
||||
|
@ -359,6 +359,7 @@ public static final int CJ = StandardTokenizer.CJ;
|
|||
* @deprecated this solves a bug where HOSTs that end with '.' are identified
|
||||
* as ACRONYMs.
|
||||
*/
|
||||
@Deprecated
|
||||
public static final int ACRONYM_DEP = StandardTokenizer.ACRONYM_DEP;
|
||||
|
||||
public static final String [] TOKEN_TYPES = StandardTokenizer.TOKEN_TYPES;
|
||||
|
@ -680,45 +681,45 @@ public final void getText(CharTermAttribute t) {
|
|||
zzMarkedPos = zzMarkedPosL;
|
||||
|
||||
switch (zzAction < 0 ? zzAction : ZZ_ACTION[zzAction]) {
|
||||
case 5:
|
||||
{ return NUM;
|
||||
}
|
||||
case 11: break;
|
||||
case 9:
|
||||
{ return ACRONYM;
|
||||
}
|
||||
case 12: break;
|
||||
case 7:
|
||||
{ return COMPANY;
|
||||
}
|
||||
case 13: break;
|
||||
case 10:
|
||||
{ return EMAIL;
|
||||
}
|
||||
case 14: break;
|
||||
case 1:
|
||||
{ /* ignore */
|
||||
}
|
||||
case 15: break;
|
||||
case 6:
|
||||
{ return APOSTROPHE;
|
||||
}
|
||||
case 16: break;
|
||||
case 3:
|
||||
{ return CJ;
|
||||
}
|
||||
case 17: break;
|
||||
case 8:
|
||||
{ return ACRONYM_DEP;
|
||||
}
|
||||
case 18: break;
|
||||
case 11: break;
|
||||
case 2:
|
||||
{ return ALPHANUM;
|
||||
}
|
||||
case 19: break;
|
||||
case 12: break;
|
||||
case 4:
|
||||
{ return HOST;
|
||||
}
|
||||
case 13: break;
|
||||
case 1:
|
||||
{ /* ignore */
|
||||
}
|
||||
case 14: break;
|
||||
case 8:
|
||||
{ return ACRONYM_DEP;
|
||||
}
|
||||
case 15: break;
|
||||
case 5:
|
||||
{ return NUM;
|
||||
}
|
||||
case 16: break;
|
||||
case 9:
|
||||
{ return ACRONYM;
|
||||
}
|
||||
case 17: break;
|
||||
case 7:
|
||||
{ return COMPANY;
|
||||
}
|
||||
case 18: break;
|
||||
case 6:
|
||||
{ return APOSTROPHE;
|
||||
}
|
||||
case 19: break;
|
||||
case 3:
|
||||
{ return CJ;
|
||||
}
|
||||
case 20: break;
|
||||
default:
|
||||
if (zzInput == YYEOF && zzStartRead == zzCurrentPos) {
|
||||
|
|
|
@ -51,6 +51,7 @@ public static final int CJ = StandardTokenizer.CJ;
|
|||
* @deprecated this solves a bug where HOSTs that end with '.' are identified
|
||||
* as ACRONYMs.
|
||||
*/
|
||||
@Deprecated
|
||||
public static final int ACRONYM_DEP = StandardTokenizer.ACRONYM_DEP;
|
||||
|
||||
public static final String [] TOKEN_TYPES = StandardTokenizer.TOKEN_TYPES;
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* The following code was generated by JFlex 1.5.0-SNAPSHOT on 9/15/10 3:01 AM */
|
||||
/* The following code was generated by JFlex 1.5.0-SNAPSHOT on 10/2/10 6:07 PM */
|
||||
|
||||
package org.apache.lucene.analysis.standard;
|
||||
|
||||
|
@ -2712,36 +2712,36 @@ public final class StandardTokenizerImpl implements StandardTokenizerInterface {
|
|||
zzMarkedPos = zzMarkedPosL;
|
||||
|
||||
switch (zzAction < 0 ? zzAction : ZZ_ACTION[zzAction]) {
|
||||
case 1:
|
||||
{ /* Not numeric, word, ideographic, hiragana, or SE Asian -- ignore it. */
|
||||
}
|
||||
case 9: break;
|
||||
case 6:
|
||||
{ return HIRAGANA_TYPE;
|
||||
}
|
||||
case 10: break;
|
||||
case 2:
|
||||
{ return WORD_TYPE;
|
||||
}
|
||||
case 11: break;
|
||||
case 9: break;
|
||||
case 4:
|
||||
{ return SOUTH_EAST_ASIAN_TYPE;
|
||||
}
|
||||
case 10: break;
|
||||
case 8:
|
||||
{ return URL_TYPE;
|
||||
}
|
||||
case 11: break;
|
||||
case 7:
|
||||
{ return EMAIL_TYPE;
|
||||
}
|
||||
case 12: break;
|
||||
case 5:
|
||||
{ return IDEOGRAPHIC_TYPE;
|
||||
}
|
||||
case 13: break;
|
||||
case 7:
|
||||
{ return EMAIL_TYPE;
|
||||
case 1:
|
||||
{ /* Not numeric, word, ideographic, hiragana, or SE Asian -- ignore it. */
|
||||
}
|
||||
case 14: break;
|
||||
case 3:
|
||||
{ return NUMERIC_TYPE;
|
||||
}
|
||||
case 15: break;
|
||||
case 4:
|
||||
{ return SOUTH_EAST_ASIAN_TYPE;
|
||||
case 6:
|
||||
{ return HIRAGANA_TYPE;
|
||||
}
|
||||
case 16: break;
|
||||
default:
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* The following code was generated by JFlex 1.5.0-SNAPSHOT on 9/15/10 3:01 AM */
|
||||
/* The following code was generated by JFlex 1.5.0-SNAPSHOT on 10/2/10 6:07 PM */
|
||||
|
||||
package org.apache.lucene.analysis.standard;
|
||||
|
||||
|
@ -802,28 +802,28 @@ public final class UAX29Tokenizer extends Tokenizer {
|
|||
zzMarkedPos = zzMarkedPosL;
|
||||
|
||||
switch (zzAction < 0 ? zzAction : ZZ_ACTION[zzAction]) {
|
||||
case 5:
|
||||
{ if (populateAttributes(IDEOGRAPHIC_TYPE)) return true;
|
||||
case 2:
|
||||
{ if (populateAttributes(WORD_TYPE)) return true;
|
||||
}
|
||||
case 7: break;
|
||||
case 1:
|
||||
{ /* Not numeric, word, ideographic, hiragana, or SE Asian -- ignore it. */
|
||||
}
|
||||
case 8: break;
|
||||
case 3:
|
||||
{ if (populateAttributes(NUMERIC_TYPE)) return true;
|
||||
}
|
||||
case 9: break;
|
||||
case 6:
|
||||
{ if (populateAttributes(HIRAGANA_TYPE)) return true;
|
||||
}
|
||||
case 10: break;
|
||||
case 8: break;
|
||||
case 5:
|
||||
{ if (populateAttributes(IDEOGRAPHIC_TYPE)) return true;
|
||||
}
|
||||
case 9: break;
|
||||
case 4:
|
||||
{ if (populateAttributes(SOUTH_EAST_ASIAN_TYPE)) return true;
|
||||
}
|
||||
case 10: break;
|
||||
case 3:
|
||||
{ if (populateAttributes(NUMERIC_TYPE)) return true;
|
||||
}
|
||||
case 11: break;
|
||||
case 2:
|
||||
{ if (populateAttributes(WORD_TYPE)) return true;
|
||||
case 1:
|
||||
{ /* Not numeric, word, ideographic, hiragana, or SE Asian -- ignore it. */
|
||||
}
|
||||
case 12: break;
|
||||
default:
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* The following code was generated by JFlex 1.5.0-SNAPSHOT on 5/31/10 3:11 PM */
|
||||
/* The following code was generated by JFlex 1.5.0-SNAPSHOT on 10/2/10 6:07 PM */
|
||||
|
||||
package org.apache.lucene.analysis.wikipedia;
|
||||
|
||||
|
@ -25,8 +25,8 @@ import org.apache.lucene.analysis.tokenattributes.CharTermAttribute;
|
|||
/**
|
||||
* This class is a scanner generated by
|
||||
* <a href="http://www.jflex.de/">JFlex</a> 1.5.0-SNAPSHOT
|
||||
* on 5/31/10 3:11 PM from the specification file
|
||||
* <tt>C:/Users/rmuir/workspace/solrcene/modules/analysis/common/src/java/org/apache/lucene/analysis/wikipedia/WikipediaTokenizerImpl.jflex</tt>
|
||||
* on 10/2/10 6:07 PM from the specification file
|
||||
* <tt>C:/Users/rmuir/workspace/lucene-clean/modules/analysis/common/src/java/org/apache/lucene/analysis/wikipedia/WikipediaTokenizerImpl.jflex</tt>
|
||||
*/
|
||||
class WikipediaTokenizerImpl {
|
||||
|
||||
|
|
|
@ -113,8 +113,8 @@ abstract class AbstractDictionary {
|
|||
// Should be a two-byte character
|
||||
return -1;
|
||||
}
|
||||
int b0 = (int) (buffer[0] & 0x0FF) - 161; // Code starts from A1, therefore subtract 0xA1=161
|
||||
int b1 = (int) (buffer[1] & 0x0FF) - 161; // There is no Chinese char for the first and last symbol.
|
||||
int b0 = (buffer[0] & 0x0FF) - 161; // Code starts from A1, therefore subtract 0xA1=161
|
||||
int b1 = (buffer[1] & 0x0FF) - 161; // There is no Chinese char for the first and last symbol.
|
||||
// Therefore, each code page only has 16*6-2=94 characters.
|
||||
return (short) (b0 * 94 + b1);
|
||||
} catch (UnsupportedEncodingException e) {
|
||||
|
|
|
@ -208,7 +208,7 @@ class BiSegGraph {
|
|||
current = preNode;
|
||||
}
|
||||
for (int j = rpath.size() - 1; j >= 0; j--) {
|
||||
Integer idInteger = (Integer) rpath.get(j);
|
||||
Integer idInteger = rpath.get(j);
|
||||
int id = idInteger.intValue();
|
||||
SegToken t = segTokenList.get(id);
|
||||
resultPath.add(t);
|
||||
|
|
|
@ -38,6 +38,7 @@ public class HHMMSegmenter {
|
|||
* @param sentence input sentence, without start and end markers
|
||||
* @return {@link SegGraph} corresponding to the input sentence.
|
||||
*/
|
||||
@SuppressWarnings("fallthrough")
|
||||
private SegGraph createSegGraph(String sentence) {
|
||||
int i = 0, j;
|
||||
int length = sentence.length();
|
||||
|
@ -100,7 +101,7 @@ public class HHMMSegmenter {
|
|||
i++;
|
||||
break;
|
||||
case CharType.FULLWIDTH_LETTER:
|
||||
hasFullWidth = true;
|
||||
hasFullWidth = true; /* intentional fallthrough */
|
||||
case CharType.LETTER:
|
||||
j = i + 1;
|
||||
while (j < length
|
||||
|
@ -118,7 +119,7 @@ public class HHMMSegmenter {
|
|||
i = j;
|
||||
break;
|
||||
case CharType.FULLWIDTH_DIGIT:
|
||||
hasFullWidth = true;
|
||||
hasFullWidth = true; /* intentional fallthrough */
|
||||
case CharType.DIGIT:
|
||||
j = i + 1;
|
||||
while (j < length
|
||||
|
|
|
@ -314,6 +314,7 @@ public class MultiTrie2 extends MultiTrie {
|
|||
return -1;
|
||||
}
|
||||
|
||||
@SuppressWarnings("fallthrough")
|
||||
private int lengthPP(CharSequence cmd) {
|
||||
int len = 0;
|
||||
for (int i = 0; i < cmd.length(); i++) {
|
||||
|
@ -323,7 +324,7 @@ public class MultiTrie2 extends MultiTrie {
|
|||
len += cmd.charAt(i) - 'a' + 1;
|
||||
break;
|
||||
case 'R':
|
||||
len++;
|
||||
len++; /* intentional fallthrough */
|
||||
case 'I':
|
||||
break;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue