Documentation ¶
Overview ¶
Returns a script.
Index ¶
- Variables
- type GetScript
- func (r GetScript) Do(providedCtx context.Context) (*Response, error)
- func (r *GetScript) Header(key, value string) *GetScript
- func (r *GetScript) HttpRequest(ctx context.Context) (*http.Request, error)
- func (r GetScript) IsSuccess(providedCtx context.Context) (bool, error)
- func (r *GetScript) MasterTimeout(duration string) *GetScript
- func (r GetScript) Perform(providedCtx context.Context) (*http.Response, error)
- type NewGetScript
- type Response
Constants ¶
This section is empty.
Variables ¶
var ErrBuildPath = errors.New("cannot build path, check for missing path parameters")
ErrBuildPath is returned in case of missing parameters within the build of the request.
Functions ¶
This section is empty.
Types ¶
type GetScript ¶
type GetScript struct {
// contains filtered or unexported fields
}
func New ¶
func New(tp elastictransport.Interface) *GetScript
Returns a script.
https://www.elastic.co/guide/en/elasticsearch/reference/current/modules-scripting.html
func (GetScript) Do ¶
Do runs the request through the transport, handle the response and returns a getscript.Response
func (*GetScript) HttpRequest ¶
HttpRequest returns the http.Request object built from the given parameters.
func (GetScript) IsSuccess ¶
IsSuccess allows to run a query with a context and retrieve the result as a boolean. This only exists for endpoints without a request payload and allows for quick control flow.
func (*GetScript) MasterTimeout ¶
MasterTimeout Specify timeout for connection to master API name: master_timeout
type NewGetScript ¶
NewGetScript type alias for index.
func NewGetScriptFunc ¶
func NewGetScriptFunc(tp elastictransport.Interface) NewGetScript
NewGetScriptFunc returns a new instance of GetScript with the provided transport. Used in the index of the library this allows to retrieve every apis in once place.