mirror of https://github.com/apache/lucene.git
remove unused method
git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/branches/docvalues@1132422 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
e8f9e80b74
commit
f4da02857f
|
@ -181,26 +181,4 @@ public class CodecProvider {
|
|||
public synchronized void setDefaultFieldCodec(String codec) {
|
||||
defaultFieldCodec = codec;
|
||||
}
|
||||
|
||||
/**
|
||||
* Registers all codecs from the given provider including the field to codec
|
||||
* mapping and the default field codec.
|
||||
* <p>
|
||||
* NOTE: This method will pass any codec from the given codec to
|
||||
* {@link #register(Codec)} and sets fiels codecs via
|
||||
* {@link #setFieldCodec(String, String)}.
|
||||
* @return this
|
||||
*/
|
||||
public CodecProvider copyFrom(CodecProvider other) {
|
||||
final Collection<Codec> values = other.codecs.values();
|
||||
for (Codec codec : values) {
|
||||
register(codec);
|
||||
}
|
||||
final Set<Entry<String, String>> entrySet = other.perFieldMap.entrySet();
|
||||
for (Entry<String, String> entry : entrySet) {
|
||||
setFieldCodec(entry.getKey(), entry.getValue());
|
||||
}
|
||||
setDefaultFieldCodec(other.getDefaultFieldCodec());
|
||||
return this;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -65,14 +65,6 @@ public class RandomIndexWriter implements Closeable {
|
|||
// called from different threads; else test failures may
|
||||
// not be reproducible from the original seed
|
||||
this.r = new Random(r.nextInt());
|
||||
|
||||
if (r.nextBoolean()) {
|
||||
if (LuceneTestCase.VERBOSE) {
|
||||
System.out.println("NOTE: RIW ctor is setting new CodecProvider().copyFrom");
|
||||
}
|
||||
// Just to test CP.copyFrom:
|
||||
conf.setCodecProvider(new CodecProvider().copyFrom(conf.getCodecProvider()));
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
Loading…
Reference in New Issue