public class RandomCodec extends AssertingCodec
The same field/format assignment will happen regardless of order, a hash is computed up front that determines the mapping. This means fields can be put into things like HashSets and added to documents in different orders and the test will still be deterministic and reproducable.
Modifier and Type | Field and Description |
---|---|
Set<String> |
avoidCodecs |
Set<String> |
dvFormatNames
unique set of docvalues format names this codec knows about
|
Set<String> |
formatNames
unique set of format names this codec knows about
|
delegate
Constructor and Description |
---|
RandomCodec(Random random) |
RandomCodec(Random random,
Set<String> avoidCodecs) |
Modifier and Type | Method and Description |
---|---|
DocValuesFormat |
getDocValuesFormatForField(String name)
Returns the docvalues format that should be used for writing
new segments of
field . |
PostingsFormat |
getPostingsFormatForField(String name)
Returns the postings format that should be used for writing
new segments of
field . |
PointsFormat |
pointsFormat() |
String |
toString() |
docValuesFormat, liveDocsFormat, normsFormat, postingsFormat, storedFieldsFormat, termVectorsFormat
compoundFormat, fieldInfosFormat, segmentInfoFormat
availableCodecs, forName, getDefault, getName, reloadCodecs, setDefault
public Set<String> dvFormatNames
public RandomCodec(Random random)
public PointsFormat pointsFormat()
pointsFormat
in class AssertingCodec
public PostingsFormat getPostingsFormatForField(String name)
AssertingCodec
field
.
The default implementation always returns "Asserting"getPostingsFormatForField
in class AssertingCodec
public DocValuesFormat getDocValuesFormatForField(String name)
AssertingCodec
field
.
The default implementation always returns "Asserting"getDocValuesFormatForField
in class AssertingCodec
public String toString()
toString
in class AssertingCodec
Copyright © 2000-2016 Apache Software Foundation. All Rights Reserved.