public class GetIndexedScriptRequest extends ActionRequest<GetIndexedScriptRequest> implements IndicesRequest
scriptLang(String) and id(String) to be set.GetIndexedScriptResponseTransportRequest.EmptyIndicesRequest.Replaceable| Modifier and Type | Field and Description |
|---|---|
protected String |
id |
protected String |
scriptLang |
headers| Constructor and Description |
|---|
GetIndexedScriptRequest()
Constructs a new get request against the script index.
|
GetIndexedScriptRequest(String scriptLang,
String id)
Constructs a new get request against the script index with the type and id.
|
| Modifier and Type | Method and Description |
|---|---|
String |
id() |
GetIndexedScriptRequest |
id(String id)
Sets the id of the script to fetch.
|
String[] |
indices()
Returns the array of indices that the action relates to
|
IndicesOptions |
indicesOptions()
Returns the indices options used to resolve indices.
|
void |
readFrom(StreamInput in) |
String |
scriptLang() |
GetIndexedScriptRequest |
scriptLang(String type)
Sets the language of the script to fetch.
|
String |
toString() |
ActionRequestValidationException |
validate() |
long |
version()
Sets the version, which will cause the get operation to only be performed if a matching
version exists and no changes happened on the doc since then.
|
GetIndexedScriptRequest |
version(long version) |
VersionType |
versionType() |
GetIndexedScriptRequest |
versionType(VersionType versionType)
Sets the versioning type.
|
void |
writeTo(StreamOutput out) |
createTask, getDescriptionremoteAddress, remoteAddresscontextSize, copyContextAndHeadersFrom, copyContextFrom, copyHeadersFrom, getContext, getFromContext, getFromContext, getHeader, getHeaders, hasHeader, hasInContext, isContextEmpty, putAllInContext, putHeader, putInContextpublic GetIndexedScriptRequest()
scriptLang(String) and id(String)
must be set.public ActionRequestValidationException validate()
validate in class ActionRequest<GetIndexedScriptRequest>public String[] indices()
IndicesRequestindices in interface IndicesRequestpublic IndicesOptions indicesOptions()
IndicesRequestindicesOptions in interface IndicesRequestpublic GetIndexedScriptRequest scriptLang(@Nullable String type)
public GetIndexedScriptRequest id(String id)
public String scriptLang()
public String id()
public long version()
public GetIndexedScriptRequest version(long version)
public GetIndexedScriptRequest versionType(VersionType versionType)
VersionType.INTERNAL.public VersionType versionType()
public void readFrom(StreamInput in) throws IOException
readFrom in interface StreamablereadFrom in class ActionRequest<GetIndexedScriptRequest>IOExceptionpublic void writeTo(StreamOutput out) throws IOException
writeTo in interface StreamablewriteTo in class ActionRequest<GetIndexedScriptRequest>IOExceptionCopyright © 2009–2017. All rights reserved.