mirror of https://github.com/apache/lucene.git
clear up some compiler warnings (non-generics)
git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/trunk@1004082 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
2e3329b331
commit
8051dfce1a
|
@ -154,7 +154,7 @@ public class TestEvaluatorBag extends SolrTestCaseJ4 {
|
|||
values.put("key", entry.getKey());
|
||||
resolver.addNamespace("A", values);
|
||||
|
||||
String expected = (String) entry.getValue();
|
||||
String expected = entry.getValue();
|
||||
String actual = evaluator.evaluate("A.key", ctx);
|
||||
assertEquals(expected, actual);
|
||||
}
|
||||
|
|
|
@ -55,7 +55,7 @@ public class FastWriter extends Writer {
|
|||
sink.write(buf,0,pos);
|
||||
pos=0;
|
||||
}
|
||||
buf[pos++] = (char)c;
|
||||
buf[pos++] = c;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -64,7 +64,7 @@ public class FastWriter extends Writer {
|
|||
sink.write(buf,0,pos);
|
||||
pos=0;
|
||||
}
|
||||
buf[pos++] = (char)c;
|
||||
buf[pos++] = c;
|
||||
return this;
|
||||
}
|
||||
|
||||
|
|
|
@ -32,6 +32,7 @@ import java.io.IOException;
|
|||
*
|
||||
* @deprecated Use SnowballPorterFilterFactory with language="English" instead
|
||||
*/
|
||||
@Deprecated
|
||||
public class EnglishPorterFilterFactory extends BaseTokenFilterFactory implements ResourceLoaderAware {
|
||||
public static final String PROTECTED_TOKENS = "protected";
|
||||
|
||||
|
|
|
@ -65,7 +65,7 @@ public final class TokenizerChain extends SolrAnalyzer {
|
|||
|
||||
@Override
|
||||
public TokenStreamInfo getStream(String fieldName, Reader reader) {
|
||||
Tokenizer tk = (Tokenizer)tokenizer.create(charStream(reader));
|
||||
Tokenizer tk = tokenizer.create(charStream(reader));
|
||||
TokenStream ts = tk;
|
||||
for (int i=0; i<filters.length; i++) {
|
||||
ts = filters[i].create(ts);
|
||||
|
|
|
@ -86,6 +86,7 @@ public class CoreContainer
|
|||
/**
|
||||
* @deprecated all cores now abort on configuration error regardless of configuration
|
||||
*/
|
||||
@Deprecated
|
||||
public boolean isAbortOnConfigurationError() {
|
||||
return true;
|
||||
}
|
||||
|
@ -94,6 +95,7 @@ public class CoreContainer
|
|||
* @exception generates an error if you attempt to set this value to false
|
||||
* @deprecated all cores now abort on configuration error regardless of configuration
|
||||
*/
|
||||
@Deprecated
|
||||
public void setAbortOnConfigurationError(boolean abortOnConfigurationError) {
|
||||
if (false == abortOnConfigurationError)
|
||||
throw new SolrException
|
||||
|
|
|
@ -180,7 +180,7 @@ public class SolrConfig extends Config {
|
|||
|
||||
httpCachingConfig = new HttpCachingConfig(this);
|
||||
|
||||
Node jmx = (Node) getNode("jmx", false);
|
||||
Node jmx = getNode("jmx", false);
|
||||
if (jmx != null) {
|
||||
jmxConfig = new JmxConfiguration(true,
|
||||
get("jmx/@agentId", null),
|
||||
|
|
|
@ -48,6 +48,7 @@ import java.util.Collection;
|
|||
*
|
||||
* @deprecated Use {@link org.apache.solr.handler.DocumentAnalysisRequestHandler} instead.
|
||||
**/
|
||||
@Deprecated
|
||||
public class AnalysisRequestHandler extends RequestHandlerBase {
|
||||
|
||||
public static Logger log = LoggerFactory.getLogger(AnalysisRequestHandler.class);
|
||||
|
|
|
@ -263,18 +263,12 @@ public abstract class AnalysisRequestHandlerBase extends RequestHandlerBase {
|
|||
private final List<Token> tokens;
|
||||
private Iterator<Token> tokenIterator;
|
||||
|
||||
private final CharTermAttribute termAtt = (CharTermAttribute)
|
||||
addAttribute(CharTermAttribute.class);
|
||||
private final OffsetAttribute offsetAtt = (OffsetAttribute)
|
||||
addAttribute(OffsetAttribute.class);
|
||||
private final TypeAttribute typeAtt = (TypeAttribute)
|
||||
addAttribute(TypeAttribute.class);
|
||||
private final FlagsAttribute flagsAtt = (FlagsAttribute)
|
||||
addAttribute(FlagsAttribute.class);
|
||||
private final PayloadAttribute payloadAtt = (PayloadAttribute)
|
||||
addAttribute(PayloadAttribute.class);
|
||||
private final PositionIncrementAttribute posIncAtt = (PositionIncrementAttribute)
|
||||
addAttribute(PositionIncrementAttribute.class);
|
||||
private final CharTermAttribute termAtt = addAttribute(CharTermAttribute.class);
|
||||
private final OffsetAttribute offsetAtt = addAttribute(OffsetAttribute.class);
|
||||
private final TypeAttribute typeAtt = addAttribute(TypeAttribute.class);
|
||||
private final FlagsAttribute flagsAtt = addAttribute(FlagsAttribute.class);
|
||||
private final PayloadAttribute payloadAtt = addAttribute(PayloadAttribute.class);
|
||||
private final PositionIncrementAttribute posIncAtt = addAttribute(PositionIncrementAttribute.class);
|
||||
/**
|
||||
* Creates a new ListBasedTokenStream which uses the given tokens as its token source.
|
||||
*
|
||||
|
|
|
@ -60,16 +60,19 @@ public class XmlUpdateRequestHandler extends ContentStreamHandlerBase {
|
|||
/**
|
||||
* @deprecated use {@link #OVERWRITE}
|
||||
*/
|
||||
@Deprecated
|
||||
public static final String OVERWRITE_COMMITTED = "overwriteCommitted";
|
||||
|
||||
/**
|
||||
* @deprecated use {@link #OVERWRITE}
|
||||
*/
|
||||
@Deprecated
|
||||
public static final String OVERWRITE_PENDING = "overwritePending";
|
||||
|
||||
/**
|
||||
* @deprecated use {@link #OVERWRITE}
|
||||
*/
|
||||
@Deprecated
|
||||
public static final String ALLOW_DUPS = "allowDups";
|
||||
|
||||
XMLInputFactory inputFactory;
|
||||
|
|
|
@ -251,7 +251,7 @@ public class FacetComponent extends SearchComponent
|
|||
NamedList facet_queries = (NamedList)facet_counts.get("facet_queries");
|
||||
if (facet_queries != null) {
|
||||
for (int i=0; i<facet_queries.size(); i++) {
|
||||
String returnedKey = (String)facet_queries.getName(i);
|
||||
String returnedKey = facet_queries.getName(i);
|
||||
long count = ((Number)facet_queries.getVal(i)).longValue();
|
||||
QueryFacet qf = fi.queryFacets.get(returnedKey);
|
||||
qf.count += count;
|
||||
|
@ -341,7 +341,7 @@ public class FacetComponent extends SearchComponent
|
|||
|
||||
for (int i=0; i<facet_fields.size(); i++) {
|
||||
String key = facet_fields.getName(i);
|
||||
DistribFieldFacet dff = (DistribFieldFacet)fi.facets.get(key);
|
||||
DistribFieldFacet dff = fi.facets.get(key);
|
||||
if (dff == null) continue;
|
||||
|
||||
NamedList shardCounts = (NamedList)facet_fields.getVal(i);
|
||||
|
|
|
@ -329,7 +329,7 @@ public class SpellCheckComponent extends SearchComponent implements SolrCoreAwar
|
|||
sugQueue.insertWithOverflow(sug);
|
||||
if (sugQueue.size() == numSug) {
|
||||
// if queue full, maintain the minScore score
|
||||
min = ((SuggestWord) sugQueue.top()).score;
|
||||
min = sugQueue.top().score;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -343,7 +343,7 @@ public class SpellCheckComponent extends SearchComponent implements SolrCoreAwar
|
|||
for (int k=0; k < sugQueue.size() - count; k++) sugQueue.pop();
|
||||
// now collect the top 'count' responses
|
||||
for (int k = Math.min(count, sugQueue.size()) - 1; k >= 0; k--) {
|
||||
suggestions[k] = ((SuggestWord) sugQueue.pop());
|
||||
suggestions[k] = sugQueue.pop();
|
||||
}
|
||||
|
||||
if (extendedResults) {
|
||||
|
|
|
@ -562,7 +562,7 @@ final class TokenOrderingFilter extends TokenFilter {
|
|||
private final int windowSize;
|
||||
private final LinkedList<OrderedToken> queue = new LinkedList<OrderedToken>();
|
||||
private boolean done=false;
|
||||
private final OffsetAttribute offsetAtt = (OffsetAttribute) addAttribute(OffsetAttribute.class);
|
||||
private final OffsetAttribute offsetAtt = addAttribute(OffsetAttribute.class);
|
||||
|
||||
protected TokenOrderingFilter(TokenStream input, int windowSize) {
|
||||
super(input);
|
||||
|
@ -622,7 +622,7 @@ class TermOffsetsTokenStream {
|
|||
|
||||
public TermOffsetsTokenStream( TokenStream tstream ){
|
||||
bufferedTokenStream = tstream;
|
||||
bufferedOffsetAtt = (OffsetAttribute) bufferedTokenStream.addAttribute(OffsetAttribute.class);
|
||||
bufferedOffsetAtt = bufferedTokenStream.addAttribute(OffsetAttribute.class);
|
||||
startOffset = 0;
|
||||
bufferedToken = null;
|
||||
}
|
||||
|
@ -634,7 +634,7 @@ class TermOffsetsTokenStream {
|
|||
|
||||
final class MultiValuedStream extends TokenStream {
|
||||
private final int length;
|
||||
OffsetAttribute offsetAtt = (OffsetAttribute) addAttribute(OffsetAttribute.class);
|
||||
OffsetAttribute offsetAtt = addAttribute(OffsetAttribute.class);
|
||||
|
||||
MultiValuedStream(int length) {
|
||||
super(bufferedTokenStream.cloneAttributes());
|
||||
|
|
|
@ -93,8 +93,8 @@ class LuceneGapFragmenter extends SimpleFragmenter {
|
|||
* @see org.apache.lucene.search.highlight.TextFragmenter#start(java.lang.String)
|
||||
*/
|
||||
public void start(String originalText, TokenStream tokenStream) {
|
||||
offsetAtt = (OffsetAttribute) tokenStream.getAttribute(OffsetAttribute.class);
|
||||
posIncAtt = (PositionIncrementAttribute) tokenStream.getAttribute(PositionIncrementAttribute.class);
|
||||
offsetAtt = tokenStream.getAttribute(OffsetAttribute.class);
|
||||
posIncAtt = tokenStream.getAttribute(PositionIncrementAttribute.class);
|
||||
fragOffset = 0;
|
||||
}
|
||||
|
||||
|
|
|
@ -202,8 +202,8 @@ class LuceneRegexFragmenter implements Fragmenter
|
|||
currentNumFrags = 1;
|
||||
currentOffset = 0;
|
||||
addHotSpots(originalText);
|
||||
posIncAtt = (PositionIncrementAttribute) tokenStream.getAttribute(PositionIncrementAttribute.class);
|
||||
offsetAtt = (OffsetAttribute) tokenStream.getAttribute(OffsetAttribute.class);
|
||||
posIncAtt = tokenStream.getAttribute(PositionIncrementAttribute.class);
|
||||
offsetAtt = tokenStream.getAttribute(OffsetAttribute.class);
|
||||
}
|
||||
|
||||
////////////////////////////////////
|
||||
|
|
|
@ -20,6 +20,7 @@ package org.apache.solr.request;
|
|||
/**
|
||||
* @deprecated use org.apache.solr.response.BinaryQueryResponseWriter
|
||||
*/
|
||||
@Deprecated
|
||||
public interface BinaryQueryResponseWriter extends org.apache.solr.response.BinaryQueryResponseWriter
|
||||
{
|
||||
|
||||
|
|
|
@ -23,6 +23,7 @@ import org.slf4j.LoggerFactory;
|
|||
/**
|
||||
* @deprecated use org.apache.solr.response.BinaryResponseWriter
|
||||
*/
|
||||
@Deprecated
|
||||
public class BinaryResponseWriter extends org.apache.solr.response.BinaryResponseWriter
|
||||
{
|
||||
private static Logger log = LoggerFactory.getLogger(BinaryResponseWriter.class.getName());
|
||||
|
|
|
@ -23,6 +23,7 @@ import org.slf4j.LoggerFactory;
|
|||
/**
|
||||
* @deprecated use org.apache.solr.response.JSONResponseWriter
|
||||
*/
|
||||
@Deprecated
|
||||
public class JSONResponseWriter extends org.apache.solr.response.JSONResponseWriter
|
||||
{
|
||||
|
||||
|
|
|
@ -23,6 +23,7 @@ import org.slf4j.LoggerFactory;
|
|||
/**
|
||||
* @deprecated use org.apache.solr.response.PHPResponseWriter
|
||||
*/
|
||||
@Deprecated
|
||||
public class PHPResponseWriter extends org.apache.solr.response.PHPResponseWriter
|
||||
{
|
||||
private static Logger log = LoggerFactory.getLogger(PHPResponseWriter.class.getName());
|
||||
|
|
|
@ -23,6 +23,7 @@ import org.slf4j.LoggerFactory;
|
|||
/**
|
||||
* @deprecated use org.apache.solr.response.PHPSerializedResponseWriter
|
||||
*/
|
||||
@Deprecated
|
||||
public class PHPSerializedResponseWriter extends org.apache.solr.response.PHPSerializedResponseWriter
|
||||
{
|
||||
private static Logger log = LoggerFactory.getLogger(PHPSerializedResponseWriter.class.getName());
|
||||
|
|
|
@ -23,6 +23,7 @@ import org.slf4j.LoggerFactory;
|
|||
/**
|
||||
* @deprecated use org.apache.solr.response.PythonResponseWriter
|
||||
*/
|
||||
@Deprecated
|
||||
public class PythonResponseWriter extends org.apache.solr.response.PythonResponseWriter
|
||||
{
|
||||
private static Logger log = LoggerFactory.getLogger(PythonResponseWriter.class.getName());
|
||||
|
|
|
@ -20,6 +20,7 @@ package org.apache.solr.request;
|
|||
/**
|
||||
* @deprecated use org.apache.solr.response.QueryResponseWriter
|
||||
*/
|
||||
@Deprecated
|
||||
public interface QueryResponseWriter extends org.apache.solr.response.QueryResponseWriter
|
||||
{
|
||||
|
||||
|
|
|
@ -23,6 +23,7 @@ import org.slf4j.LoggerFactory;
|
|||
/**
|
||||
* @deprecated use org.apache.solr.response.RawResponseWriter
|
||||
*/
|
||||
@Deprecated
|
||||
public class RawResponseWriter extends org.apache.solr.response.RawResponseWriter
|
||||
{
|
||||
private static Logger log = LoggerFactory.getLogger(RawResponseWriter.class.getName());
|
||||
|
|
|
@ -23,6 +23,7 @@ import org.slf4j.LoggerFactory;
|
|||
/**
|
||||
* @deprecated use org.apache.solr.response.RubyResponseWriter
|
||||
*/
|
||||
@Deprecated
|
||||
public class RubyResponseWriter extends org.apache.solr.response.RubyResponseWriter
|
||||
{
|
||||
private static Logger log = LoggerFactory.getLogger(RubyResponseWriter.class.getName());
|
||||
|
|
|
@ -23,6 +23,7 @@ import org.slf4j.LoggerFactory;
|
|||
/**
|
||||
* @deprecated use org.apache.solr.response.SolrQueryResponse
|
||||
*/
|
||||
@Deprecated
|
||||
public class SolrQueryResponse extends org.apache.solr.response.SolrQueryResponse
|
||||
{
|
||||
private static Logger log = LoggerFactory.getLogger(SolrQueryResponse.class.getName());
|
||||
|
|
|
@ -26,6 +26,7 @@ import org.slf4j.LoggerFactory;
|
|||
/**
|
||||
* @deprecated use org.apache.solr.response.TextResponseWriter
|
||||
*/
|
||||
@Deprecated
|
||||
public abstract class TextResponseWriter extends org.apache.solr.response.TextResponseWriter
|
||||
{
|
||||
private static Logger log = LoggerFactory.getLogger(TextResponseWriter.class.getName());
|
||||
|
|
|
@ -23,6 +23,7 @@ import org.slf4j.LoggerFactory;
|
|||
/**
|
||||
* @deprecated use org.apache.solr.response.XMLResponseWriter
|
||||
*/
|
||||
@Deprecated
|
||||
public class XMLResponseWriter extends org.apache.solr.response.XMLResponseWriter
|
||||
{
|
||||
private static Logger log = LoggerFactory.getLogger(XMLResponseWriter.class.getName());
|
||||
|
|
|
@ -23,6 +23,7 @@ import org.slf4j.LoggerFactory;
|
|||
/**
|
||||
* @deprecated use org.apache.solr.response.XSLTResponseWriter
|
||||
*/
|
||||
@Deprecated
|
||||
public class XSLTResponseWriter extends org.apache.solr.response.XSLTResponseWriter
|
||||
{
|
||||
private static Logger log = LoggerFactory.getLogger(XSLTResponseWriter.class.getName());
|
||||
|
|
|
@ -167,7 +167,7 @@ public abstract class BaseResponseWriter {
|
|||
private static SolrDocument getDoc(int id, IdxInfo info) throws IOException {
|
||||
Document doc = info.searcher.doc(id);
|
||||
SolrDocument solrDoc = new SolrDocument();
|
||||
for (Fieldable f : (List<Fieldable>) doc.getFields()) {
|
||||
for (Fieldable f : doc.getFields()) {
|
||||
String fieldName = f.name();
|
||||
if (info.returnFields != null && !info.returnFields.contains(fieldName))
|
||||
continue;
|
||||
|
|
|
@ -132,7 +132,7 @@ public class BinaryResponseWriter implements BinaryQueryResponseWriter {
|
|||
|
||||
public SolrDocument getDoc(Document doc) {
|
||||
SolrDocument solrDoc = new SolrDocument();
|
||||
for (Fieldable f : (List<Fieldable>) doc.getFields()) {
|
||||
for (Fieldable f : doc.getFields()) {
|
||||
String fieldName = f.name();
|
||||
if (returnFields != null && !returnFields.contains(fieldName)) continue;
|
||||
SchemaField sf = schema.getFieldOrNull(fieldName);
|
||||
|
|
|
@ -447,7 +447,7 @@ class JSONWriter extends TextResponseWriter {
|
|||
other = scoreMap;
|
||||
scoreMap.put("score",score);
|
||||
}
|
||||
writeDoc(name, (List<Fieldable>)(doc.getFields()), returnFields, other);
|
||||
writeDoc(name, doc.getFields(), returnFields, other);
|
||||
}
|
||||
|
||||
public void writeDocList(String name, DocList ids, Set<String> fields, Map otherFields) throws IOException {
|
||||
|
|
|
@ -236,6 +236,7 @@ public class DateField extends FieldType {
|
|||
*
|
||||
* @deprecated - use formatDate(Date) instead
|
||||
*/
|
||||
@Deprecated
|
||||
protected DateFormat getThreadLocalDateFormat() {
|
||||
return fmtThreadLocal.get();
|
||||
}
|
||||
|
|
|
@ -132,6 +132,7 @@ public final class IndexSchema {
|
|||
/**
|
||||
* @deprecated -- get access to SolrConfig some other way...
|
||||
*/
|
||||
@Deprecated
|
||||
public SolrConfig getSolrConfig() {
|
||||
return solrConfig;
|
||||
}
|
||||
|
@ -274,6 +275,7 @@ public final class IndexSchema {
|
|||
* @param defaultField if non-null overrides the schema default
|
||||
* @deprecated
|
||||
*/
|
||||
@Deprecated
|
||||
public SolrQueryParser getSolrQueryParser(String defaultField) {
|
||||
SolrQueryParser qp = new SolrQueryParser(this,defaultField);
|
||||
String operator = getQueryParserDefaultOperator();
|
||||
|
@ -550,7 +552,7 @@ public final class IndexSchema {
|
|||
log.trace("Dynamic Field Ordering:" + dFields);
|
||||
|
||||
// stuff it in a normal array for faster access
|
||||
dynamicFields = (DynamicField[])dFields.toArray(new DynamicField[dFields.size()]);
|
||||
dynamicFields = dFields.toArray(new DynamicField[dFields.size()]);
|
||||
|
||||
|
||||
Node node = (Node) xpath.evaluate("/schema/similarity", document, XPathConstants.NODE);
|
||||
|
|
|
@ -167,7 +167,7 @@ public class RandomSortField extends FieldType {
|
|||
|
||||
@Override
|
||||
public int intVal(int doc) {
|
||||
return (int)hash(doc+seed);
|
||||
return hash(doc+seed);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -135,7 +135,7 @@ public final class SchemaField extends FieldProperties {
|
|||
|
||||
String defaultValue = null;
|
||||
if( props.containsKey( "default" ) ) {
|
||||
defaultValue = (String)props.get( "default" );
|
||||
defaultValue = props.get( "default" );
|
||||
}
|
||||
return new SchemaField(name, ft, calcProps(name, ft, props), defaultValue );
|
||||
}
|
||||
|
|
|
@ -65,7 +65,7 @@ class LuceneQueryOptimizer {
|
|||
BooleanQuery query = new BooleanQuery();
|
||||
BooleanQuery filterQuery = null;
|
||||
|
||||
for (BooleanClause c : (List<BooleanClause>)original.clauses()) {
|
||||
for (BooleanClause c : original.clauses()) {
|
||||
|
||||
/***
|
||||
System.out.println("required="+c.required);
|
||||
|
|
|
@ -408,7 +408,7 @@ public class QueryParsing {
|
|||
return null;
|
||||
}
|
||||
|
||||
return new Sort((SortField[]) lst.toArray(new SortField[lst.size()]));
|
||||
return new Sort(lst.toArray(new SortField[lst.size()]));
|
||||
}
|
||||
|
||||
|
||||
|
@ -508,7 +508,7 @@ public class QueryParsing {
|
|||
out.append('(');
|
||||
}
|
||||
boolean first = true;
|
||||
for (BooleanClause c : (List<BooleanClause>) q.clauses()) {
|
||||
for (BooleanClause c : q.clauses()) {
|
||||
if (!first) {
|
||||
out.append(' ');
|
||||
} else {
|
||||
|
|
|
@ -91,6 +91,7 @@ public class SolrIndexSearcher extends IndexSearcher implements SolrInfoMBean {
|
|||
*
|
||||
* @deprecated use alternate constructor
|
||||
*/
|
||||
@Deprecated
|
||||
public SolrIndexSearcher(SolrCore core, IndexSchema schema, String name, String path, boolean enableCache) throws IOException {
|
||||
this(core, schema,name, core.getIndexReaderFactory().newReader(core.getDirectoryFactory().open(path), false), true, enableCache);
|
||||
}
|
||||
|
@ -421,7 +422,7 @@ public class SolrIndexSearcher extends IndexSearcher implements SolrInfoMBean {
|
|||
|
||||
Document d;
|
||||
if (documentCache != null) {
|
||||
d = (Document)documentCache.get(i);
|
||||
d = documentCache.get(i);
|
||||
if (d!=null) return d;
|
||||
}
|
||||
|
||||
|
@ -538,7 +539,7 @@ public class SolrIndexSearcher extends IndexSearcher implements SolrInfoMBean {
|
|||
boolean positive = query==absQ;
|
||||
|
||||
if (filterCache != null) {
|
||||
DocSet absAnswer = (DocSet)filterCache.get(absQ);
|
||||
DocSet absAnswer = filterCache.get(absQ);
|
||||
if (absAnswer!=null) {
|
||||
if (positive) return absAnswer;
|
||||
else return getPositiveDocSet(matchAllDocsQuery).andNot(absAnswer);
|
||||
|
@ -564,7 +565,7 @@ public class SolrIndexSearcher extends IndexSearcher implements SolrInfoMBean {
|
|||
boolean positive = query==absQ;
|
||||
|
||||
if (filterCache != null) {
|
||||
DocSet absAnswer = (DocSet)filterCache.get(absQ);
|
||||
DocSet absAnswer = filterCache.get(absQ);
|
||||
if (absAnswer!=null) {
|
||||
if (positive) return absAnswer;
|
||||
else return getPositiveDocSet(matchAllDocsQuery).andNot(absAnswer);
|
||||
|
@ -586,7 +587,7 @@ public class SolrIndexSearcher extends IndexSearcher implements SolrInfoMBean {
|
|||
DocSet getPositiveDocSet(Query q) throws IOException {
|
||||
DocSet answer;
|
||||
if (filterCache != null) {
|
||||
answer = (DocSet)filterCache.get(q);
|
||||
answer = filterCache.get(q);
|
||||
if (answer!=null) return answer;
|
||||
}
|
||||
answer = getDocSetNC(q,null);
|
||||
|
@ -598,7 +599,7 @@ public class SolrIndexSearcher extends IndexSearcher implements SolrInfoMBean {
|
|||
DocSet getPositiveDocSet(Query q, DocsEnumState deState) throws IOException {
|
||||
DocSet answer;
|
||||
if (filterCache != null) {
|
||||
answer = (DocSet)filterCache.get(q);
|
||||
answer = filterCache.get(q);
|
||||
if (answer!=null) return answer;
|
||||
}
|
||||
answer = getDocSetNC(q,null,deState);
|
||||
|
@ -880,7 +881,7 @@ public class SolrIndexSearcher extends IndexSearcher implements SolrInfoMBean {
|
|||
|
||||
DocSet first;
|
||||
if (filterCache != null) {
|
||||
first = (DocSet)filterCache.get(absQ);
|
||||
first = filterCache.get(absQ);
|
||||
if (first==null) {
|
||||
first = getDocSetNC(absQ,null);
|
||||
filterCache.put(absQ,first);
|
||||
|
@ -1064,7 +1065,7 @@ public class SolrIndexSearcher extends IndexSearcher implements SolrInfoMBean {
|
|||
NamedList grouped = new SimpleOrderedMap();
|
||||
for (int cmdnum=0; cmdnum<cmd.groupCommands.size(); cmdnum++) {
|
||||
Grouping.Command groupCommand = cmd.groupCommands.get(cmdnum);
|
||||
GroupCollector gcollector = (GroupCollector)collectors.get(cmdnum);
|
||||
GroupCollector gcollector = collectors.get(cmdnum);
|
||||
|
||||
NamedList groupResult = new SimpleOrderedMap();
|
||||
grouped.add(groupCommand.key, groupResult); // grouped={ key={
|
||||
|
@ -1194,7 +1195,7 @@ public class SolrIndexSearcher extends IndexSearcher implements SolrInfoMBean {
|
|||
// so set all of them on the cache key.
|
||||
key = new QueryResultKey(cmd.getQuery(), cmd.getFilterList(), cmd.getSort(), cmd.getFlags());
|
||||
if ((cmd.getFlags() & NO_CHECK_QCACHE)==0) {
|
||||
superset = (DocList)queryResultCache.get(key);
|
||||
superset = queryResultCache.get(key);
|
||||
|
||||
if (superset != null) {
|
||||
// check that the cache entry has scores recorded if we need them
|
||||
|
|
|
@ -52,7 +52,7 @@ public class ByteFieldSource extends NumericFieldCacheSource<ByteValues> {
|
|||
return new DocValues() {
|
||||
@Override
|
||||
public byte byteVal(int doc) {
|
||||
return (byte) arr[doc];
|
||||
return arr[doc];
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -60,7 +60,7 @@ public class IntFieldSource extends NumericFieldCacheSource<IntValues> {
|
|||
}
|
||||
|
||||
public int intVal(int doc) {
|
||||
return (int)arr[doc];
|
||||
return arr[doc];
|
||||
}
|
||||
|
||||
public long longVal(int doc) {
|
||||
|
|
|
@ -63,7 +63,7 @@ public class LongFieldSource extends NumericFieldCacheSource<LongValues> {
|
|||
}
|
||||
|
||||
public long longVal(int doc) {
|
||||
return (long) arr[doc];
|
||||
return arr[doc];
|
||||
}
|
||||
|
||||
public double doubleVal(int doc) {
|
||||
|
|
|
@ -66,7 +66,7 @@ public class ReverseOrdFieldSource extends ValueSource {
|
|||
}
|
||||
|
||||
public int intVal(int doc) {
|
||||
return (int)(end - sindex.getOrd(doc));
|
||||
return (end - sindex.getOrd(doc));
|
||||
}
|
||||
|
||||
public long longVal(int doc) {
|
||||
|
|
|
@ -55,7 +55,7 @@ public class ShortFieldSource extends NumericFieldCacheSource<ShortValues> {
|
|||
|
||||
@Override
|
||||
public short shortVal(int doc) {
|
||||
return (short) arr[doc];
|
||||
return arr[doc];
|
||||
}
|
||||
|
||||
public float floatVal(int doc) {
|
||||
|
|
|
@ -72,7 +72,7 @@ public class GeohashHaversineFunction extends ValueSource {
|
|||
}
|
||||
|
||||
public double doubleVal(int doc) {
|
||||
return (double) distance(doc, gh1DV, gh2DV);
|
||||
return distance(doc, gh1DV, gh2DV);
|
||||
}
|
||||
|
||||
public String strVal(int doc) {
|
||||
|
|
|
@ -113,7 +113,7 @@ public class HaversineFunction extends ValueSource {
|
|||
}
|
||||
|
||||
public double doubleVal(int doc) {
|
||||
return (double) distance(doc, vals1, vals2);
|
||||
return distance(doc, vals1, vals2);
|
||||
}
|
||||
|
||||
public String strVal(int doc) {
|
||||
|
|
|
@ -37,7 +37,7 @@ public class StringDistanceFunction extends ValueSource {
|
|||
return new DocValues() {
|
||||
|
||||
public float floatVal(int doc) {
|
||||
return (float) dist.getDistance(str1DV.strVal(doc), str2DV.strVal(doc));
|
||||
return dist.getDistance(str1DV.strVal(doc), str2DV.strVal(doc));
|
||||
}
|
||||
|
||||
public int intVal(int doc) {
|
||||
|
|
|
@ -167,7 +167,7 @@ public abstract class AbstractLuceneSpellChecker extends SolrSpellChecker {
|
|||
Term term = field != null ? new Term(field, "") : null;
|
||||
float theAccuracy = (options.accuracy == Float.MIN_VALUE) ? spellChecker.getAccuracy() : options.accuracy;
|
||||
|
||||
int count = (int) Math.max(options.count, AbstractLuceneSpellChecker.DEFAULT_SUGGESTION_COUNT);
|
||||
int count = Math.max(options.count, AbstractLuceneSpellChecker.DEFAULT_SUGGESTION_COUNT);
|
||||
for (Token token : options.tokens) {
|
||||
String tokenText = new String(token.buffer(), 0, token.length());
|
||||
String[] suggestions = spellChecker.suggestSimilar(tokenText,
|
||||
|
|
|
@ -122,7 +122,7 @@ public class TSTAutocomplete {
|
|||
Stack<TernaryTreeNode> st = new Stack<TernaryTreeNode>();
|
||||
st.push(p);
|
||||
while (!st.empty()) {
|
||||
TernaryTreeNode top = (TernaryTreeNode) st.peek();
|
||||
TernaryTreeNode top = st.peek();
|
||||
st.pop();
|
||||
if (top.token != null) {
|
||||
suggest.add(top);
|
||||
|
|
|
@ -52,7 +52,7 @@ import org.apache.solr.core.SolrCore;
|
|||
*
|
||||
* @deprecated Use {@link DirectUpdateHandler2} instead. This is only kept around for back-compatibility (way back).
|
||||
*/
|
||||
|
||||
@Deprecated
|
||||
public class DirectUpdateHandler extends UpdateHandler {
|
||||
|
||||
// the set of ids in the "pending set" (those docs that have been added, but
|
||||
|
|
|
@ -144,6 +144,7 @@ public class SolrIndexWriter extends IndexWriter {
|
|||
}
|
||||
|
||||
/** @deprecated remove when getDirectory(String,SolrIndexConfig) is gone */
|
||||
@Deprecated
|
||||
private static DirectoryFactory LEGACY_DIR_FACTORY
|
||||
= new StandardDirectoryFactory();
|
||||
static {
|
||||
|
@ -153,6 +154,7 @@ public class SolrIndexWriter extends IndexWriter {
|
|||
/**
|
||||
* @deprecated use getDirectory(String path, DirectoryFactory directoryFactory, SolrIndexConfig config)
|
||||
*/
|
||||
@Deprecated
|
||||
public static Directory getDirectory(String path, SolrIndexConfig config) throws IOException {
|
||||
log.warn("SolrIndexWriter is using LEGACY_DIR_FACTORY which means deprecated code is likely in use and SolrIndexWriter is ignoring any custom DirectoryFactory.");
|
||||
return getDirectory(path, LEGACY_DIR_FACTORY, config);
|
||||
|
@ -175,6 +177,7 @@ public class SolrIndexWriter extends IndexWriter {
|
|||
/**
|
||||
* @deprecated
|
||||
*/
|
||||
@Deprecated
|
||||
public SolrIndexWriter(String name, String path, boolean create, IndexSchema schema) throws IOException {
|
||||
super(getDirectory(path, null), schema.getAnalyzer(), create, MaxFieldLength.LIMITED);
|
||||
init(name, schema, null);
|
||||
|
@ -183,6 +186,7 @@ public class SolrIndexWriter extends IndexWriter {
|
|||
/**
|
||||
* @deprecated
|
||||
*/
|
||||
@Deprecated
|
||||
public SolrIndexWriter(String name, String path, boolean create, IndexSchema schema, SolrIndexConfig config) throws IOException {
|
||||
super(getDirectory(path, config), schema.getAnalyzer(), create, MaxFieldLength.LIMITED);
|
||||
init(name, schema, config);
|
||||
|
|
|
@ -26,6 +26,7 @@ import org.apache.lucene.util.OpenBitSet;
|
|||
* @deprecated Use {@link org.apache.lucene.util.OpenBitSetIterator} instead.
|
||||
* @version $Id$
|
||||
*/
|
||||
@Deprecated
|
||||
public class BitSetIterator {
|
||||
|
||||
// The General Idea: instead of having an array per byte that has
|
||||
|
|
|
@ -21,6 +21,7 @@ package org.apache.solr.util;
|
|||
* @deprecated Use {@link org.apache.lucene.util.BitUtil} directly
|
||||
* @version $Id$
|
||||
*/
|
||||
@Deprecated
|
||||
public class BitUtil extends org.apache.lucene.util.BitUtil {
|
||||
// just inherit for backwards-compatibility reasons
|
||||
}
|
||||
|
|
|
@ -35,47 +35,56 @@ public class DisMaxParams extends CommonParams implements org.apache.solr.common
|
|||
/** query and init param for filtering query
|
||||
* @deprecated use SolrParams.FQ or SolrPluginUtils.parseFilterQueries
|
||||
*/
|
||||
@Deprecated
|
||||
public static String FQ = "fq";
|
||||
|
||||
/**
|
||||
* the default tie breaker to use in DisjunctionMaxQueries
|
||||
* @deprecated - use explicit default with SolrParams.getFloat
|
||||
*/
|
||||
@Deprecated
|
||||
public float tiebreaker = 0.0f;
|
||||
/**
|
||||
* the default query fields to be used
|
||||
* @deprecated - use explicit default with SolrParams.get
|
||||
*/
|
||||
@Deprecated
|
||||
public String qf = null;
|
||||
/**
|
||||
* the default phrase boosting fields to be used
|
||||
* @deprecated - use explicit default with SolrParams.get
|
||||
*/
|
||||
@Deprecated
|
||||
public String pf = null;
|
||||
/**
|
||||
* the default min should match to be used
|
||||
* @deprecated - use explicit default with SolrParams.get
|
||||
*/
|
||||
@Deprecated
|
||||
public String mm = "100%";
|
||||
/**
|
||||
* the default phrase slop to be used
|
||||
* @deprecated - use explicit default with SolrParams.getInt
|
||||
*/
|
||||
@Deprecated
|
||||
public int pslop = 0;
|
||||
/**
|
||||
* the default boosting query to be used
|
||||
* @deprecated - use explicit default with SolrParams.get
|
||||
*/
|
||||
@Deprecated
|
||||
public String bq = null;
|
||||
/**
|
||||
* the default boosting functions to be used
|
||||
* @deprecated - use explicit default with SolrParams.get
|
||||
*/
|
||||
@Deprecated
|
||||
public String bf = null;
|
||||
/**
|
||||
* the default filtering query to be used
|
||||
* @deprecated - use explicit default with SolrParams.get
|
||||
*/
|
||||
@Deprecated
|
||||
public String fq = null;
|
||||
|
||||
|
||||
|
@ -94,6 +103,7 @@ public class DisMaxParams extends CommonParams implements org.apache.solr.common
|
|||
* </p>
|
||||
* @deprecated use SolrParams.toSolrParams
|
||||
*/
|
||||
@Deprecated
|
||||
public void setValues(NamedList args) {
|
||||
|
||||
super.setValues(args);
|
||||
|
|
|
@ -51,6 +51,7 @@ import org.apache.lucene.search.highlight.*;
|
|||
* @deprecated use DefaultSolrHighlighter
|
||||
* @see DefaultSolrHighlighter
|
||||
*/
|
||||
@Deprecated
|
||||
public class HighlightingUtils implements HighlightParams {
|
||||
|
||||
static SolrParams DEFAULTS = null;
|
||||
|
@ -76,6 +77,7 @@ public class HighlightingUtils implements HighlightParams {
|
|||
* @deprecated use DefaultSolrHighlighter
|
||||
* @see DefaultSolrHighlighter#isHighlightingEnabled
|
||||
*/
|
||||
@Deprecated
|
||||
public static boolean isHighlightingEnabled(SolrQueryRequest request) {
|
||||
return HIGHLIGHTER.isHighlightingEnabled(getParams(request));
|
||||
}
|
||||
|
@ -84,6 +86,7 @@ public class HighlightingUtils implements HighlightParams {
|
|||
* @deprecated use DefaultSolrHighlighter
|
||||
* @see DefaultSolrHighlighter
|
||||
*/
|
||||
@Deprecated
|
||||
public static Highlighter getHighlighter(Query query, String fieldName, SolrQueryRequest request) {
|
||||
return HIGHLIGHTER.getHighlighterX(query, fieldName, request);
|
||||
}
|
||||
|
@ -92,6 +95,7 @@ public class HighlightingUtils implements HighlightParams {
|
|||
* @deprecated use DefaultSolrHighlighter
|
||||
* @see DefaultSolrHighlighter#getHighlightFields
|
||||
*/
|
||||
@Deprecated
|
||||
public static String[] getHighlightFields(Query query, SolrQueryRequest request, String[] defaultFields) {
|
||||
return HIGHLIGHTER.getHighlightFields(query, request, defaultFields);
|
||||
}
|
||||
|
@ -100,6 +104,7 @@ public class HighlightingUtils implements HighlightParams {
|
|||
* @deprecated use DefaultSolrHighlighter
|
||||
* @see DefaultSolrHighlighter
|
||||
*/
|
||||
@Deprecated
|
||||
public static int getMaxSnippets(String fieldName, SolrQueryRequest request) {
|
||||
return HIGHLIGHTER.getMaxSnippetsX(fieldName, request);
|
||||
}
|
||||
|
@ -108,6 +113,7 @@ public class HighlightingUtils implements HighlightParams {
|
|||
* @deprecated use DefaultSolrHighlighter
|
||||
* @see DefaultSolrHighlighter
|
||||
*/
|
||||
@Deprecated
|
||||
public static Formatter getFormatter(String fieldName, SolrQueryRequest request) {
|
||||
return HIGHLIGHTER.getFormatterX(fieldName, request);
|
||||
}
|
||||
|
@ -116,6 +122,7 @@ public class HighlightingUtils implements HighlightParams {
|
|||
* @deprecated use DefaultSolrHighlighter
|
||||
* @see DefaultSolrHighlighter
|
||||
*/
|
||||
@Deprecated
|
||||
public static Fragmenter getFragmenter(String fieldName, SolrQueryRequest request) {
|
||||
return HIGHLIGHTER.getFragmenterX(fieldName, request);
|
||||
}
|
||||
|
@ -124,7 +131,7 @@ public class HighlightingUtils implements HighlightParams {
|
|||
* @deprecated use DefaultSolrHighlighter
|
||||
* @see DefaultSolrHighlighter#doHighlighting
|
||||
*/
|
||||
@SuppressWarnings("unchecked")
|
||||
@Deprecated @SuppressWarnings("unchecked")
|
||||
public static NamedList doHighlighting(DocList docs, Query query, SolrQueryRequest req, String[] defaultFields) throws IOException {
|
||||
return HIGHLIGHTER.doHighlighting(docs, query, req, defaultFields);
|
||||
}
|
||||
|
|
|
@ -73,7 +73,7 @@ Test system: AMD Opteron, 64 bit linux, Sun Java 1.5_06 -server -Xbatch -Xmx64M
|
|||
@deprecated Use {@link org.apache.lucene.util.OpenBitSet} directly.
|
||||
* @version $Id$
|
||||
*/
|
||||
|
||||
@Deprecated
|
||||
public class OpenBitSet extends org.apache.lucene.util.OpenBitSet implements Cloneable, Serializable {
|
||||
/** Constructs an OpenBitSet large enough to hold numBits.
|
||||
*
|
||||
|
|
|
@ -127,6 +127,7 @@ public class SolrPluginUtils {
|
|||
* Returns the param, or the default if it's empty or not specified.
|
||||
* @deprecated use SolrParam.get(String,String)
|
||||
*/
|
||||
@Deprecated
|
||||
public static String getParam(SolrQueryRequest req,
|
||||
String param, String def) {
|
||||
|
||||
|
@ -144,6 +145,7 @@ public class SolrPluginUtils {
|
|||
* there or if it's not a number.
|
||||
* @deprecated use SolrParam.getFloat(String,float)
|
||||
*/
|
||||
@Deprecated
|
||||
public static Number getNumberParam(SolrQueryRequest req,
|
||||
String param, Number def) {
|
||||
|
||||
|
@ -165,6 +167,7 @@ public class SolrPluginUtils {
|
|||
* any other non-empty string is true.
|
||||
* @deprecated use SolrParam.getBool(String,boolean)
|
||||
*/
|
||||
@Deprecated
|
||||
public static boolean getBooleanParam(SolrQueryRequest req,
|
||||
String param, boolean def) {
|
||||
String v = req.getParam(param);
|
||||
|
@ -543,6 +546,7 @@ public class SolrPluginUtils {
|
|||
* @see #parseFieldBoosts
|
||||
* @deprecated
|
||||
*/
|
||||
@Deprecated
|
||||
public static List<Query> parseFuncs(IndexSchema s, String in)
|
||||
throws ParseException {
|
||||
|
||||
|
@ -592,7 +596,7 @@ public class SolrPluginUtils {
|
|||
public static void setMinShouldMatch(BooleanQuery q, String spec) {
|
||||
|
||||
int optionalClauses = 0;
|
||||
for (BooleanClause c : (List<BooleanClause>)q.clauses()) {
|
||||
for (BooleanClause c : q.clauses()) {
|
||||
if (c.getOccur() == Occur.SHOULD) {
|
||||
optionalClauses++;
|
||||
}
|
||||
|
@ -659,7 +663,7 @@ public class SolrPluginUtils {
|
|||
*/
|
||||
public static void flattenBooleanQuery(BooleanQuery to, BooleanQuery from) {
|
||||
|
||||
for (BooleanClause clause : (List<BooleanClause>)from.clauses()) {
|
||||
for (BooleanClause clause : from.clauses()) {
|
||||
|
||||
Query cq = clause.getQuery();
|
||||
cq.setBoost(cq.getBoost() * from.getBoost());
|
||||
|
|
|
@ -409,6 +409,7 @@ public class TestHarness {
|
|||
* to a StringBuffer.
|
||||
* @deprecated see {@link #appendSimpleDoc(StringBuilder, String...)}
|
||||
*/
|
||||
@Deprecated
|
||||
public void appendSimpleDoc(StringBuffer buf, String... fieldsAndValues)
|
||||
throws IOException {
|
||||
|
||||
|
|
|
@ -364,6 +364,7 @@ public class SolrQuery extends ModifiableSolrParams
|
|||
/**
|
||||
* @deprecated use {@link #setFacetMissing(Boolean)}
|
||||
*/
|
||||
@Deprecated
|
||||
public SolrQuery setMissing(String fld) {
|
||||
return setFacetMissing(Boolean.valueOf(fld));
|
||||
}
|
||||
|
|
|
@ -213,7 +213,7 @@ public class JavaBinUpdateRequestCodec {
|
|||
List<String> l = (List) nl.getVal(i);
|
||||
if (l != null)
|
||||
solrParams.add(nl.getName(i),
|
||||
(String[]) l.toArray(new String[l.size()]));
|
||||
l.toArray(new String[l.size()]));
|
||||
}
|
||||
return solrParams;
|
||||
}
|
||||
|
|
|
@ -47,6 +47,7 @@ public class UpdateRequest extends AbstractUpdateRequest {
|
|||
*
|
||||
* @deprecated Use {@link AbstractUpdateRequest.ACTION} instead
|
||||
*/
|
||||
@Deprecated
|
||||
public enum ACTION {
|
||||
COMMIT,
|
||||
OPTIMIZE
|
||||
|
@ -137,6 +138,7 @@ public class UpdateRequest extends AbstractUpdateRequest {
|
|||
*
|
||||
* @deprecated Use {@link org.apache.solr.client.solrj.request.AbstractUpdateRequest.ACTION} instead
|
||||
* */
|
||||
@Deprecated
|
||||
public UpdateRequest setAction(ACTION action, boolean waitFlush, boolean waitSearcher ) {
|
||||
return setAction(action, waitFlush, waitSearcher, 1);
|
||||
}
|
||||
|
@ -145,6 +147,7 @@ public class UpdateRequest extends AbstractUpdateRequest {
|
|||
*
|
||||
* @deprecated Use {@link org.apache.solr.client.solrj.request.AbstractUpdateRequest.ACTION} instead
|
||||
*/
|
||||
@Deprecated
|
||||
public UpdateRequest setAction(ACTION action, boolean waitFlush, boolean waitSearcher, int maxSegments ) {
|
||||
if (params == null)
|
||||
params = new ModifiableSolrParams();
|
||||
|
@ -166,6 +169,7 @@ public class UpdateRequest extends AbstractUpdateRequest {
|
|||
*
|
||||
* @deprecated Use {@link org.apache.solr.client.solrj.request.AbstractUpdateRequest.ACTION} instead
|
||||
*/
|
||||
@Deprecated
|
||||
public UpdateRequest setAction(ACTION action, boolean waitFlush, boolean waitSearcher, int maxSegments , boolean expungeDeletes) {
|
||||
setAction(action, waitFlush, waitSearcher,maxSegments) ;
|
||||
params.set(UpdateParams.EXPUNGE_DELETES,""+expungeDeletes);
|
||||
|
|
|
@ -259,7 +259,7 @@ public class QueryResponse extends SolrResponseBase
|
|||
for( NamedList nl : list ) {
|
||||
// NOTE, this is cheating, but we know the order they are written in, so no need to check
|
||||
String f = (String)nl.getVal( 0 );
|
||||
Object v = (Object)nl.getVal( 1 );
|
||||
Object v = nl.getVal( 1 );
|
||||
int cnt = ((Integer)nl.getVal( 2 )).intValue();
|
||||
List<PivotField> p = (nl.size()<4)?null:readPivots((List<NamedList>)nl.getVal(3) );
|
||||
values.add( new PivotField( f, v, cnt, p ) );
|
||||
|
|
|
@ -143,6 +143,7 @@ public class ClientUtils
|
|||
/**
|
||||
* @deprecated Use {@link org.apache.solr.common.util.DateUtil#DEFAULT_DATE_FORMATS}
|
||||
*/
|
||||
@Deprecated
|
||||
public static final Collection<String> fmts = DateUtil.DEFAULT_DATE_FORMATS;
|
||||
|
||||
/**
|
||||
|
@ -153,6 +154,7 @@ public class ClientUtils
|
|||
*
|
||||
* @deprecated Use {@link org.apache.solr.common.util.DateUtil#parseDate(String)}
|
||||
*/
|
||||
@Deprecated
|
||||
public static Date parseDate( String d ) throws ParseException, DateParseException
|
||||
{
|
||||
return DateUtil.parseDate(d);
|
||||
|
@ -164,6 +166,7 @@ public class ClientUtils
|
|||
*
|
||||
* @deprecated use {@link org.apache.solr.common.util.DateUtil#getThreadLocalDateFormat()}
|
||||
*/
|
||||
@Deprecated
|
||||
public static DateFormat getThreadLocalDateFormat() {
|
||||
|
||||
return DateUtil.getThreadLocalDateFormat();
|
||||
|
@ -172,6 +175,7 @@ public class ClientUtils
|
|||
/**
|
||||
* @deprecated Use {@link org.apache.solr.common.util.DateUtil#UTC}.
|
||||
*/
|
||||
@Deprecated
|
||||
public static TimeZone UTC = DateUtil.UTC;
|
||||
|
||||
|
||||
|
|
|
@ -258,7 +258,7 @@ public class TestSynonymMap extends LuceneTestCase {
|
|||
}
|
||||
|
||||
private void assertTokIncludes( SynonymMap map, String src, String exp ) throws Exception {
|
||||
Token[] tokens = ((SynonymMap)map.submap.get( src )).synonyms;
|
||||
Token[] tokens = map.submap.get( src ).synonyms;
|
||||
boolean inc = false;
|
||||
for( Token token : tokens ){
|
||||
if( exp.equals( new String(token.buffer(), 0, token.length()) ) )
|
||||
|
@ -268,6 +268,6 @@ public class TestSynonymMap extends LuceneTestCase {
|
|||
}
|
||||
|
||||
private SynonymMap getSubSynonymMap( SynonymMap map, String src ){
|
||||
return (SynonymMap)map.submap.get( src );
|
||||
return map.submap.get( src );
|
||||
}
|
||||
}
|
||||
|
|
|
@ -28,6 +28,7 @@ import org.apache.lucene.search.DocIdSetIterator;
|
|||
* @deprecated
|
||||
* @version $Id$
|
||||
*/
|
||||
@Deprecated
|
||||
public class TestOpenBitSet extends LuceneTestCase {
|
||||
static Random rand = new Random();
|
||||
|
||||
|
|
|
@ -245,6 +245,7 @@ public class EmbeddedSolrServer extends SolrServer
|
|||
*
|
||||
* @deprecated use {@link BinaryResponseWriter#getParsedResponse(SolrQueryRequest, SolrQueryResponse)}
|
||||
*/
|
||||
@Deprecated
|
||||
public NamedList<Object> getParsedResponse( SolrQueryRequest req, SolrQueryResponse rsp )
|
||||
{
|
||||
return BinaryResponseWriter.getParsedResponse(req, rsp);
|
||||
|
|
Loading…
Reference in New Issue