Class CreateAuthTokenRequest

  • All Implemented Interfaces:
    org.elasticsearch.common.io.stream.Writeable, org.elasticsearch.common.xcontent.ToXContent, org.elasticsearch.common.xcontent.ToXContentObject, org.elasticsearch.tasks.TaskAwareRequest

    public class CreateAuthTokenRequest
    extends org.elasticsearch.action.ActionRequest
    implements org.elasticsearch.common.xcontent.ToXContentObject
    • Nested Class Summary

      • Nested classes/interfaces inherited from class org.elasticsearch.transport.TransportRequest

        org.elasticsearch.transport.TransportRequest.Empty
      • Nested 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
      • Nested classes/interfaces inherited from interface org.elasticsearch.common.io.stream.Writeable

        org.elasticsearch.common.io.stream.Writeable.Reader<V extends Object>, org.elasticsearch.common.io.stream.Writeable.Writer<V extends Object>
    • Field Summary

      • Fields inherited from interface org.elasticsearch.common.xcontent.ToXContent

        EMPTY_PARAMS
    • Constructor Detail

      • CreateAuthTokenRequest

        public CreateAuthTokenRequest()
      • CreateAuthTokenRequest

        public CreateAuthTokenRequest​(RequestedPrivileges requestedPrivileges)
      • CreateAuthTokenRequest

        public CreateAuthTokenRequest​(org.elasticsearch.common.io.stream.StreamInput in)
                               throws IOException
        Throws:
        IOException
    • Method Detail

      • writeTo

        public void writeTo​(org.elasticsearch.common.io.stream.StreamOutput out)
                     throws IOException
        Specified by:
        writeTo in interface org.elasticsearch.common.io.stream.Writeable
        Overrides:
        writeTo in class org.elasticsearch.action.ActionRequest
        Throws:
        IOException
      • validate

        public org.elasticsearch.action.ActionRequestValidationException validate()
        Specified by:
        validate in class org.elasticsearch.action.ActionRequest
      • parse

        public static CreateAuthTokenRequest parse​(org.elasticsearch.common.bytes.BytesReference document,
                                                   org.elasticsearch.common.xcontent.XContentType contentType)
                                            throws com.floragunn.searchsupport.config.validation.ConfigValidationException
        Throws:
        com.floragunn.searchsupport.config.validation.ConfigValidationException
      • setRequestedPrivileges

        public void setRequestedPrivileges​(RequestedPrivileges requestedPrivileges)
      • getAudience

        public String getAudience()
      • setAudience

        public void setAudience​(String audience)
      • setExpiresAfter

        public void setExpiresAfter​(Duration expiresAfter)
      • getTokenName

        public String getTokenName()
      • setTokenName

        public void setTokenName​(String tokenName)
      • isFreezePrivileges

        public boolean isFreezePrivileges()
      • setFreezePrivileges

        public void setFreezePrivileges​(boolean snapshotPrivileges)
      • toJson

        public String toJson()
      • 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:
        toXContent in interface org.elasticsearch.common.xcontent.ToXContent
        Throws:
        IOException