/** * Sets the doc source of the update request to be used when the document does not exists. */ public UpdateRequest upsert(Map source) { safeUpsertRequest().source(source); return this; }
/** * Sets the doc source of the update request to be used when the document does not exists. The doc * includes field and value pairs. */ public UpdateRequest upsert(Object... source) { safeUpsertRequest().source(source); return this; }
/** * Sets the doc source of the update request to be used when the document does not exists. */ public UpdateRequest upsert(byte[] source, int offset, int length, XContentType xContentType) { safeUpsertRequest().source(source, offset, length, xContentType); return this; }
/** * Sets the doc source of the update request to be used when the document does not exists. */ public UpdateRequest upsert(Map source, XContentType contentType) { safeUpsertRequest().source(source, contentType); return this; }
/** * Sets the doc source of the update request to be used when the document does not exists. */ public UpdateRequest upsert(XContentBuilder source) { safeUpsertRequest().source(source); return this; }
/** * Sets the doc source of the update request to be used when the document does not exists. */ public UpdateRequest upsert(String source, XContentType xContentType) { safeUpsertRequest().source(source, xContentType); return this; }
/** * Sets the doc source of the update request to be used when the document does not exists. */ public UpdateRequest upsert(byte[] source, XContentType xContentType) { safeUpsertRequest().source(source, xContentType); return this; }
/** * Sets the doc source of the update request to be used when the document does not exists. The doc * includes field and value pairs. */ public UpdateRequest upsert(XContentType xContentType, Object... source) { safeUpsertRequest().source(xContentType, source); return this; }
XContentBuilder builder = XContentFactory.contentBuilder(parser.contentType()); builder.copyCurrentStructure(parser); safeUpsertRequest().source(builder); } else if ("doc".equals(currentFieldName)) { XContentBuilder docBuilder = XContentFactory.contentBuilder(parser.contentType());
/** * Sets the doc source of the update request to be used when the document does not exists. * @deprecated use {@link #upsert(String, XContentType)} */ @Deprecated public UpdateRequest upsert(String source) { safeUpsertRequest().source(source); return this; }
/** * Sets the doc source of the update request to be used when the document does not exists. */ public UpdateRequest upsert(Map source) { safeUpsertRequest().source(source); return this; }
/** * Sets the doc source of the update request to be used when the document does not exists. */ public UpdateRequest upsert(XContentBuilder source) { safeUpsertRequest().source(source); return this; }
/** * Sets the doc source of the update request to be used when the document does not exists. */ public UpdateRequest upsert(byte[] source, XContentType xContentType) { safeUpsertRequest().source(source, xContentType); return this; }
/** * Sets the doc source of the update request to be used when the document does not exists. */ public UpdateRequest upsert(Map source, XContentType contentType) { safeUpsertRequest().source(source, contentType); return this; }
/** * Sets the doc source of the update request to be used when the document does not exists. */ public UpdateRequest upsert(String source, XContentType xContentType) { safeUpsertRequest().source(source, xContentType); return this; }
/** * Sets the doc source of the update request to be used when the document does not exists. The doc * includes field and value pairs. */ public UpdateRequest upsert(XContentType xContentType, Object... source) { safeUpsertRequest().source(xContentType, source); return this; }
/** * Sets the doc source of the update request to be used when the document does not exists. */ public UpdateRequest upsert(byte[] source) { safeUpsertRequest().source(source); return this; }
/** * Sets the doc source of the update request to be used when the document does not exists. */ public UpdateRequest upsert(XContentBuilder source) { safeUpsertRequest().source(source); return this; }
/** * Sets the doc source of the update request to be used when the document does not exists. */ public UpdateRequest upsert(byte[] source, int offset, int length, XContentType xContentType) { safeUpsertRequest().source(source, offset, length, xContentType); return this; }
/** * Sets the doc source of the update request to be used when the document does not exists. The doc * includes field and value pairs. */ public UpdateRequest upsert(XContentType xContentType, Object... source) { safeUpsertRequest().source(xContentType, source); return this; }