Class ChangePasswordRequest
- java.lang.Object
-
- org.elasticsearch.client.security.ChangePasswordRequest
-
- All Implemented Interfaces:
Validatable,ToXContent,ToXContentObject
public final class ChangePasswordRequest extends java.lang.Object implements Validatable, 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.common.xcontent.ToXContent
ToXContent.DelegatingMapParams, ToXContent.MapParams, ToXContent.Params
-
-
Field Summary
-
Fields inherited from interface org.elasticsearch.common.xcontent.ToXContent
EMPTY_PARAMS
-
-
Constructor Summary
Constructors Constructor Description ChangePasswordRequest(java.lang.String username, char[] password, RefreshPolicy refreshPolicy)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description char[]getPassword()RefreshPolicygetRefreshPolicy()java.lang.StringgetUsername()XContentBuildertoXContent(XContentBuilder builder, 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.common.xcontent.ToXContentObject
isFragment
-
Methods inherited from interface org.elasticsearch.client.Validatable
validate
-
-
-
-
Constructor Detail
-
ChangePasswordRequest
public ChangePasswordRequest(@Nullable java.lang.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 theChangePasswordRequestobject so the calling code must clear it after receiving the response.refreshPolicy- The refresh policy for the request.
-
-
Method Detail
-
getUsername
public java.lang.String getUsername()
-
getPassword
public char[] getPassword()
-
getRefreshPolicy
public RefreshPolicy getRefreshPolicy()
-
toXContent
public XContentBuilder toXContent(XContentBuilder builder, ToXContent.Params params) throws java.io.IOException
- Specified by:
toXContentin interfaceToXContent- Throws:
java.io.IOException
-
-