Class AuthToken

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

    public class AuthToken
    extends Object
    implements org.elasticsearch.common.xcontent.ToXContentObject, org.elasticsearch.common.io.stream.Writeable, Serializable
    See Also:
    Serialized Form
    • Field Detail

    • Constructor Detail

      • AuthToken

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

      • 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
      • toXContentFragment

        public org.elasticsearch.common.xcontent.XContentBuilder toXContentFragment​(org.elasticsearch.common.xcontent.XContentBuilder builder,
                                                                                    org.elasticsearch.common.xcontent.ToXContent.Params params)
                                                                             throws IOException
        Throws:
        IOException
      • getId

        public String getId()
      • getUserName

        public String getUserName()
      • getTokenName

        public String getTokenName()
      • isRevoked

        public boolean isRevoked()
      • parse

        public static AuthToken parse​(String id,
                                      com.fasterxml.jackson.databind.JsonNode jsonNode)
                               throws com.floragunn.searchsupport.config.validation.ConfigValidationException
        Throws:
        com.floragunn.searchsupport.config.validation.ConfigValidationException
      • getCreationTime

        public Instant getCreationTime()
      • getExpiryTime

        public Instant getExpiryTime()
      • writeTo

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

        public Instant getRevokedAt()
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class Object