本文整理汇总了Java中org.apache.lucene.document.DoubleField.TYPE_NOT_STORED属性的典型用法代码示例。如果您正苦于以下问题:Java DoubleField.TYPE_NOT_STORED属性的具体用法?Java DoubleField.TYPE_NOT_STORED怎么用?Java DoubleField.TYPE_NOT_STORED使用的例子?那么恭喜您, 这里精选的属性代码示例或许可以为您提供帮助。您也可以进一步了解该属性所在类org.apache.lucene.document.DoubleField
的用法示例。
在下文中一共展示了DoubleField.TYPE_NOT_STORED属性的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: configure
@Override
public void configure(String fieldNameForThisInstance, Map<String, String> properties, Configuration configuration) {
String precisionStepStr = properties.get(NUMERIC_PRECISION_STEP);
if (precisionStepStr != null) {
_precisionStep = Integer.parseInt(precisionStepStr);
_typeStored = new FieldType(DoubleField.TYPE_STORED);
_typeStored.setNumericPrecisionStep(_precisionStep);
_typeStored.freeze();
_typeNotStored = new FieldType(DoubleField.TYPE_NOT_STORED);
_typeNotStored.setNumericPrecisionStep(_precisionStep);
_typeNotStored.freeze();
} else {
_typeStored = DoubleField.TYPE_STORED;
_typeNotStored = DoubleField.TYPE_NOT_STORED;
}
}
示例2: BBoxStrategy
public BBoxStrategy(SpatialContext ctx, String fieldNamePrefix) {
super(ctx, fieldNamePrefix);
field_bbox = fieldNamePrefix;
field_minX = fieldNamePrefix + SUFFIX_MINX;
field_maxX = fieldNamePrefix + SUFFIX_MAXX;
field_minY = fieldNamePrefix + SUFFIX_MINY;
field_maxY = fieldNamePrefix + SUFFIX_MAXY;
field_xdl = fieldNamePrefix + SUFFIX_XDL;
FieldType fieldType = new FieldType(DoubleField.TYPE_NOT_STORED);
fieldType.setNumericPrecisionStep(8);//Solr's default
fieldType.setDocValueType(FieldInfo.DocValuesType.NUMERIC);
setFieldType(fieldType);
}
示例3: createIndexableFields
/** @see #createIndexableFields(com.spatial4j.core.shape.Shape) */
public Field[] createIndexableFields(Point point) {
FieldType doubleFieldType = new FieldType(DoubleField.TYPE_NOT_STORED);
doubleFieldType.setNumericPrecisionStep(precisionStep);
Field[] f = new Field[2];
f[0] = new DoubleField(fieldNameX, point.getX(), doubleFieldType);
f[1] = new DoubleField(fieldNameY, point.getY(), doubleFieldType);
return f;
}
示例4: doubleField
@Override
public void doubleField(FieldInfo fieldInfo, double value) {
FieldType ft = new FieldType(DoubleField.TYPE_NOT_STORED);
ft.setStored(true);
ft.setIndexed(fieldInfo.isIndexed());
doc.add(new DoubleField(fieldInfo.name, value, ft));
}
示例5: doubleField
@Override
public void doubleField(FieldInfo fieldInfo, double value) {
FieldType ft = new FieldType(DoubleField.TYPE_NOT_STORED);
ft.setStored(true);
ft.setIndexed(fieldInfo.isIndexed());
doc.add(new DoubleField(fieldInfo.name, value, ft));
}