コード例 #1
0
  @Override
  protected void doXContentBody(XContentBuilder builder, boolean includeDefaults, Params params)
      throws IOException {
    super.doXContentBody(builder, includeDefaults, params);

    builder.field("analyzer", analyzer());
  }
コード例 #2
0
 @Override
 public IntegerFieldMapper build(BuilderContext context) {
   fieldType.setOmitNorms(fieldType.omitNorms() && boost == 1.0f);
   IntegerFieldMapper fieldMapper =
       new IntegerFieldMapper(
           buildNames(context),
           fieldType.numericPrecisionStep(),
           boost,
           fieldType,
           docValues,
           nullValue,
           ignoreMalformed(context),
           coerce(context),
           postingsProvider,
           docValuesProvider,
           similarity,
           normsLoading,
           fieldDataSettings,
           context.indexSettings(),
           multiFieldsBuilder.build(this, context),
           copyTo);
   fieldMapper.includeInAll(includeInAll);
   return fieldMapper;
 }
コード例 #3
0
 @Override
 protected void doMerge(Mapper mergeWith, boolean updateAllTypes) {
   super.doMerge(mergeWith, updateAllTypes);
   this.analyzer = ((TokenCountFieldMapper) mergeWith).analyzer;
 }
コード例 #4
0
 @Override
 public void postParse(ParseContext context) throws IOException {
   // we post parse it so we get the size stored, possibly compressed (source will be preParse)
   super.parse(context);
 }