Package org.elasticsearch.client.ml
Class PostDataRequest
java.lang.Object
org.elasticsearch.client.ml.PostDataRequest
- All Implemented Interfaces:
Validatable,org.elasticsearch.common.xcontent.ToXContent,org.elasticsearch.common.xcontent.ToXContentObject
public class PostDataRequest
extends Object
implements Validatable, org.elasticsearch.common.xcontent.ToXContentObject
Request to post data to a Machine Learning job
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classClass for incrementally building a bulk document request inXContentType.JSONformatNested classes/interfaces inherited from interface org.elasticsearch.common.xcontent.ToXContent
org.elasticsearch.common.xcontent.ToXContent.DelegatingMapParams, org.elasticsearch.common.xcontent.ToXContent.MapParams, org.elasticsearch.common.xcontent.ToXContent.Params -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic org.elasticsearch.common.xcontent.ParseFieldstatic org.elasticsearch.common.xcontent.ConstructingObjectParser<PostDataRequest,Void>static org.elasticsearch.common.xcontent.ParseFieldstatic org.elasticsearch.common.xcontent.ParseFieldFields inherited from interface org.elasticsearch.common.xcontent.ToXContent
EMPTY_PARAMSFields inherited from interface org.elasticsearch.client.Validatable
EMPTY -
Constructor Summary
ConstructorsConstructorDescriptionPostDataRequest(String jobId, PostDataRequest.JsonBuilder builder)Create a new PostDataRequest object referencing the passedPostDataRequest.JsonBuilderobjectPostDataRequest(String jobId, org.elasticsearch.common.xcontent.XContentType xContentType, byte[] content)Create a new PostDataRequest object referencing the passedbyte[]contentPostDataRequest(String jobId, org.elasticsearch.common.xcontent.XContentType xContentType, org.elasticsearch.common.bytes.BytesReference content)Create a new PostDataRequest object -
Method Summary
Modifier and TypeMethodDescriptionbooleanorg.elasticsearch.common.bytes.BytesReferencegetJobId()org.elasticsearch.common.xcontent.XContentTypeinthashCode()voidsetResetEnd(String resetEnd)Specifies the end of the bucket resetting rangevoidsetResetStart(String resetStart)Specifies the start of the bucket resetting rangeorg.elasticsearch.common.xcontent.XContentBuildertoXContent(org.elasticsearch.common.xcontent.XContentBuilder builder, org.elasticsearch.common.xcontent.ToXContent.Params params)Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.elasticsearch.common.xcontent.ToXContentObject
isFragmentMethods inherited from interface org.elasticsearch.client.Validatable
validate
-
Field Details
-
RESET_START
public static final org.elasticsearch.common.xcontent.ParseField RESET_START -
RESET_END
public static final org.elasticsearch.common.xcontent.ParseField RESET_END -
CONTENT_TYPE
public static final org.elasticsearch.common.xcontent.ParseField CONTENT_TYPE -
PARSER
public static final org.elasticsearch.common.xcontent.ConstructingObjectParser<PostDataRequest,Void> PARSER
-
-
Constructor Details
-
PostDataRequest
public PostDataRequest(String jobId, org.elasticsearch.common.xcontent.XContentType xContentType, org.elasticsearch.common.bytes.BytesReference content)Create a new PostDataRequest object- Parameters:
jobId- non-null jobId of the job to post data toxContentType- content type of the data to post. OnlyXContentType.JSONorXContentType.SMILEare supportedcontent- bulk serialized content in the format of the passedXContentType
-
PostDataRequest
public PostDataRequest(String jobId, org.elasticsearch.common.xcontent.XContentType xContentType, byte[] content)Create a new PostDataRequest object referencing the passedbyte[]content- Parameters:
jobId- non-null jobId of the job to post data toxContentType- content type of the data to post. OnlyXContentType.JSONorXContentType.SMILEare supportedcontent- bulk serialized content in the format of the passedXContentType
-
PostDataRequest
Create a new PostDataRequest object referencing the passedPostDataRequest.JsonBuilderobject- Parameters:
jobId- non-null jobId of the job to post data tobuilder-PostDataRequest.JsonBuilderobject containing documents to be serialized and sent inXContentType.JSONformat
-
-
Method Details
-
getJobId
-
getResetStart
-
setResetStart
Specifies the start of the bucket resetting range- Parameters:
resetStart- String representation of a timestamp; may be an epoch seconds, epoch millis or an ISO 8601 string
-
getResetEnd
-
setResetEnd
Specifies the end of the bucket resetting range- Parameters:
resetEnd- String representation of a timestamp; may be an epoch seconds, epoch millis or an ISO 8601 string
-
getContent
public org.elasticsearch.common.bytes.BytesReference getContent() -
getXContentType
public org.elasticsearch.common.xcontent.XContentType getXContentType() -
hashCode
public int hashCode() -
equals
-
toXContent
public org.elasticsearch.common.xcontent.XContentBuilder toXContent(org.elasticsearch.common.xcontent.XContentBuilder builder, org.elasticsearch.common.xcontent.ToXContent.Params params) throws IOException- Specified by:
toXContentin interfaceorg.elasticsearch.common.xcontent.ToXContent- Throws:
IOException
-