Class ChangePasswordRequest

java.lang.Object
org.elasticsearch.client.security.ChangePasswordRequest
All Implemented Interfaces:
Validatable, org.elasticsearch.xcontent.ToXContent, org.elasticsearch.xcontent.ToXContentObject

public final class ChangePasswordRequest extends Object implements Validatable, org.elasticsearch.xcontent.ToXContentObject
Request object to change the password of a user of a native realm or a built-in user.
  • Nested Class Summary

    Nested classes/interfaces inherited from interface org.elasticsearch.xcontent.ToXContent

    org.elasticsearch.xcontent.ToXContent.DelegatingMapParams, org.elasticsearch.xcontent.ToXContent.MapParams, org.elasticsearch.xcontent.ToXContent.Params
  • Field Summary

    Fields inherited from interface org.elasticsearch.xcontent.ToXContent

    EMPTY_PARAMS

    Fields inherited from interface org.elasticsearch.client.Validatable

    EMPTY
  • Constructor Summary

    Constructors
    Constructor
    Description
    ChangePasswordRequest(String username, char[] password, RefreshPolicy refreshPolicy)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    char[]
     
     
     
    org.elasticsearch.xcontent.XContentBuilder
    toXContent(org.elasticsearch.xcontent.XContentBuilder builder, org.elasticsearch.xcontent.ToXContent.Params params)
     

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

    Methods inherited from interface org.elasticsearch.xcontent.ToXContentObject

    isFragment

    Methods inherited from interface org.elasticsearch.client.Validatable

    validate
  • Constructor Details

    • ChangePasswordRequest

      public ChangePasswordRequest(@Nullable String username, char[] password, RefreshPolicy refreshPolicy)
      Parameters:
      username - The username of the user whose password should be changed or null for the current user.
      password - The new password. The password array is not cleared by the ChangePasswordRequest object so the calling code must clear it after receiving the response.
      refreshPolicy - The refresh policy for the request.
  • Method Details

    • getUsername

      public String getUsername()
    • getPassword

      public char[] getPassword()
    • getRefreshPolicy

      public RefreshPolicy getRefreshPolicy()
    • toXContent

      public org.elasticsearch.xcontent.XContentBuilder toXContent(org.elasticsearch.xcontent.XContentBuilder builder, org.elasticsearch.xcontent.ToXContent.Params params) throws IOException
      Specified by:
      toXContent in interface org.elasticsearch.xcontent.ToXContent
      Throws:
      IOException