當前位置: 首頁>>代碼示例>>Java>>正文


Java StreamOutput.writeGenericValue方法代碼示例

本文整理匯總了Java中org.elasticsearch.common.io.stream.StreamOutput.writeGenericValue方法的典型用法代碼示例。如果您正苦於以下問題:Java StreamOutput.writeGenericValue方法的具體用法?Java StreamOutput.writeGenericValue怎麽用?Java StreamOutput.writeGenericValue使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在org.elasticsearch.common.io.stream.StreamOutput的用法示例。


在下文中一共展示了StreamOutput.writeGenericValue方法的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。

示例1: writeTo

import org.elasticsearch.common.io.stream.StreamOutput; //導入方法依賴的package包/類
@Override
public void writeTo(StreamOutput out) throws IOException {
    // marshall doc count
    out.writeGenericValue(docCount);
    // marshall fieldSum
    out.writeGenericValue(fieldSum);
    // counts
    out.writeGenericValue(counts);
    // mean
    out.writeGenericValue(means);
    // variances
    out.writeGenericValue(variances);
    // skewness
    out.writeGenericValue(skewness);
    // kurtosis
    out.writeGenericValue(kurtosis);
    // covariances
    out.writeGenericValue(covariances);
}
 
開發者ID:justor,項目名稱:elasticsearch_my,代碼行數:20,代碼來源:RunningStats.java

示例2: doWriteTo

import org.elasticsearch.common.io.stream.StreamOutput; //導入方法依賴的package包/類
@Override
protected void doWriteTo(StreamOutput out) throws IOException {
    out.writeGenericValue(value);
    out.writeVInt(fieldsBoosts.size());
    for (Map.Entry<String, Float> fieldsEntry : fieldsBoosts.entrySet()) {
        out.writeString(fieldsEntry.getKey());
        out.writeFloat(fieldsEntry.getValue());
    }
    type.writeTo(out);
    operator.writeTo(out);
    out.writeOptionalString(analyzer);
    out.writeVInt(slop);
    out.writeOptionalWriteable(fuzziness);
    out.writeVInt(prefixLength);
    out.writeVInt(maxExpansions);
    out.writeOptionalString(minimumShouldMatch);
    out.writeOptionalString(fuzzyRewrite);
    out.writeOptionalBoolean(useDisMax);
    out.writeOptionalFloat(tieBreaker);
    out.writeBoolean(lenient);
    out.writeOptionalFloat(cutoffFrequency);
    zeroTermsQuery.writeTo(out);
}
 
開發者ID:justor,項目名稱:elasticsearch_my,代碼行數:24,代碼來源:MultiMatchQueryBuilder.java

示例3: doWriteTo

import org.elasticsearch.common.io.stream.StreamOutput; //導入方法依賴的package包/類
@Override
protected void doWriteTo(StreamOutput out) throws IOException {
    out.writeString(this.fieldName);
    out.writeGenericValue(this.from);
    out.writeGenericValue(this.to);
    out.writeBoolean(this.includeLower);
    out.writeBoolean(this.includeUpper);
    out.writeOptionalTimeZone(timeZone);
    String formatString = null;
    if (this.format != null) {
        formatString = this.format.format();
    }
    out.writeOptionalString(formatString);
    if (out.getVersion().onOrAfter(Version.V_5_2_0_UNRELEASED)) {
        String relationString = null;
        if (this.relation != null) {
            relationString = this.relation.getRelationName();
        }
        out.writeOptionalString(relationString);
    }
}
 
開發者ID:justor,項目名稱:elasticsearch_my,代碼行數:22,代碼來源:RangeQueryBuilder.java

示例4: writeTo

import org.elasticsearch.common.io.stream.StreamOutput; //導入方法依賴的package包/類
/** Marshalls MatrixStatsResults */
@Override
public void writeTo(StreamOutput out) throws IOException {
    // marshall results
    results.writeTo(out);
    // marshall correlation
    out.writeGenericValue(correlation);
}
 
開發者ID:justor,項目名稱:elasticsearch_my,代碼行數:9,代碼來源:MatrixStatsResults.java

示例5: doWriteTo

import org.elasticsearch.common.io.stream.StreamOutput; //導入方法依賴的package包/類
@Override
protected void doWriteTo(StreamOutput out) throws IOException {
    out.writeString(this.fieldName);
    out.writeGenericValue(this.value);
    this.fuzziness.writeTo(out);
    out.writeVInt(this.prefixLength);
    out.writeVInt(this.maxExpansions);
    out.writeBoolean(this.transpositions);
    out.writeOptionalString(this.rewrite);
}
 
開發者ID:justor,項目名稱:elasticsearch_my,代碼行數:11,代碼來源:FuzzyQueryBuilder.java

示例6: writeTo

import org.elasticsearch.common.io.stream.StreamOutput; //導入方法依賴的package包/類
@Override
public void writeTo(StreamOutput out) throws IOException {
    super.writeTo(out);
    out.writeString(type);
    out.writeString(id);

    out.writeBoolean(doc != null);
    if (doc != null) {
        out.writeBytesReference(doc);
    }
    out.writeOptionalString(routing);
    out.writeOptionalString(preference);
    long longFlags = 0;
    for (Flag flag : flagsEnum) {
        longFlags |= (1 << flag.ordinal());
    }
    out.writeVLong(longFlags);
    if (selectedFields != null) {
        out.writeVInt(selectedFields.size());
        for (String selectedField : selectedFields) {
            out.writeString(selectedField);
        }
    } else {
        out.writeVInt(0);
    }
    out.writeBoolean(perFieldAnalyzer != null);
    if (perFieldAnalyzer != null) {
        out.writeGenericValue(perFieldAnalyzer);
    }
    out.writeBoolean(filterSettings != null);
    if (filterSettings != null) {
        filterSettings.writeTo(out);
    }
    out.writeBoolean(realtime());
    out.writeByte(versionType.getValue());
    out.writeLong(version);
}
 
開發者ID:baidu,項目名稱:Elasticsearch,代碼行數:38,代碼來源:TermVectorsRequest.java

示例7: writeTo

import org.elasticsearch.common.io.stream.StreamOutput; //導入方法依賴的package包/類
@Override
public void writeTo(StreamOutput out) throws IOException {
    out.writeString(term);
    out.writeInt(startOffset);
    out.writeInt(endOffset);
    out.writeVInt(position);
    if (out.getVersion().onOrAfter(Version.V_5_2_0_UNRELEASED)) {
        out.writeOptionalVInt(positionLength > 1 ? positionLength : null);
    }
    out.writeOptionalString(type);
    if (out.getVersion().onOrAfter(Version.V_2_2_0)) {
        out.writeGenericValue(attributes);
    }
}
 
開發者ID:justor,項目名稱:elasticsearch_my,代碼行數:15,代碼來源:AnalyzeResponse.java

示例8: writeTo

import org.elasticsearch.common.io.stream.StreamOutput; //導入方法依賴的package包/類
@Override
public void writeTo(StreamOutput out) throws IOException {
    super.writeTo(out);

    out.writeBoolean(rowCount < 0);
    out.writeVLong(Math.abs(rowCount));
    out.writeInt(rows.length);
    for (Object[] row : rows) {
        for (int j = 0, len = cols().length; j < len; j++) {
            out.writeGenericValue(row[j]);
        }
    }
}
 
開發者ID:baidu,項目名稱:Elasticsearch,代碼行數:14,代碼來源:SQLResponse.java

示例9: writeTo

import org.elasticsearch.common.io.stream.StreamOutput; //導入方法依賴的package包/類
@Override
public void writeTo(StreamOutput out) throws IOException {
    out.writeVInt(sortValues.length);
    for (Object fieldValue : sortValues) {
        out.writeGenericValue(fieldValue);
    }
}
 
開發者ID:justor,項目名稱:elasticsearch_my,代碼行數:8,代碼來源:SearchAfterBuilder.java

示例10: writeTo

import org.elasticsearch.common.io.stream.StreamOutput; //導入方法依賴的package包/類
@Override
public void writeTo(StreamOutput out) throws IOException {
    out.writeBoolean(fetchFields);
    if (fetchFields) {
        out.writeGenericValue(fieldNames);
    }
}
 
開發者ID:justor,項目名稱:elasticsearch_my,代碼行數:8,代碼來源:StoredFieldsContext.java

示例11: doWriteTo

import org.elasticsearch.common.io.stream.StreamOutput; //導入方法依賴的package包/類
@Override
protected void doWriteTo(StreamOutput out) throws IOException {
    boolean hasScript = reduceScript != null;
    out.writeBoolean(hasScript);
    if (hasScript) {
        reduceScript.writeTo(out);
    }
    out.writeGenericValue(aggregation);
}
 
開發者ID:baidu,項目名稱:Elasticsearch,代碼行數:10,代碼來源:InternalScriptedMetric.java

示例12: writeTo

import org.elasticsearch.common.io.stream.StreamOutput; //導入方法依賴的package包/類
@Override
public void writeTo(StreamOutput out) throws IOException {
    out.writeString(fieldName);
    out.writeOptionalNamedWriteable(nestedFilter);
    out.writeOptionalString(nestedPath);
    out.writeGenericValue(missing);
    out.writeOptionalWriteable(order);
    out.writeOptionalWriteable(sortMode);
    out.writeOptionalString(unmappedType);
}
 
開發者ID:justor,項目名稱:elasticsearch_my,代碼行數:11,代碼來源:FieldSortBuilder.java

示例13: writeTo

import org.elasticsearch.common.io.stream.StreamOutput; //導入方法依賴的package包/類
@Override
public void writeTo(StreamOutput out) throws IOException {
    out.writeString(name);
    out.writeVInt(values.size());
    for (Object value : values) {
        out.writeGenericValue(value);
    }
}
 
開發者ID:justor,項目名稱:elasticsearch_my,代碼行數:9,代碼來源:SearchHitField.java

示例14: doWriteTo

import org.elasticsearch.common.io.stream.StreamOutput; //導入方法依賴的package包/類
@Override
protected void doWriteTo(StreamOutput out) throws IOException {
    out.writeString(fieldName);
    out.writeGenericValue(value);
    out.writeVInt(slop);
    out.writeVInt(maxExpansions);
    out.writeOptionalString(analyzer);
}
 
開發者ID:justor,項目名稱:elasticsearch_my,代碼行數:9,代碼來源:MatchPhrasePrefixQueryBuilder.java

示例15: writeValueTo

import org.elasticsearch.common.io.stream.StreamOutput; //導入方法依賴的package包/類
@Override
public void writeValueTo(StreamOutput out, Object v) throws IOException {
    out.writeGenericValue(v);
}
 
開發者ID:baidu,項目名稱:Elasticsearch,代碼行數:5,代碼來源:ObjectType.java


注:本文中的org.elasticsearch.common.io.stream.StreamOutput.writeGenericValue方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。