Package org.ldaptive.auth
Class AuthenticationRequest
java.lang.Object
org.ldaptive.auth.AuthenticationRequest
Contains the data required to perform an ldap authentication.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classAuthentication request builder. -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate RequestControl[]Request controls.private CredentialUser credential.private String[]User attributes to return.private UserUser. -
Constructor Summary
ConstructorsConstructorDescriptionDefault constructor.Creates a new authentication request.AuthenticationRequest(String id, Credential c, String... attrs) Creates a new authentication request.Creates a new authentication request.AuthenticationRequest(User u, Credential c, String... attrs) Creates a new authentication request. -
Method Summary
Modifier and TypeMethodDescriptionbuilder()Creates a builder for this class.(package private) static AuthenticationRequestcopy(AuthenticationRequest request) Returns an authentication request initialized with the supplied request.Returns the controls.Returns the credential.String[]Returns the return attributes.getUser()Returns the user.voidsetControls(RequestControl... cntrls) Sets the controls.voidSets the credential.voidsetReturnAttributes(String... attrs) Sets the return attributes.voidSets the user.toString()
-
Field Details
-
user
User. -
credential
User credential. -
returnAttributes
User attributes to return. -
controls
Request controls.
-
-
Constructor Details
-
AuthenticationRequest
public AuthenticationRequest()Default constructor. -
AuthenticationRequest
Creates a new authentication request.- Parameters:
id- that identifies the userc- credential to authenticate the user
-
AuthenticationRequest
Creates a new authentication request.- Parameters:
id- that identifies the userc- credential to authenticate the userattrs- attributes to return
-
AuthenticationRequest
Creates a new authentication request.- Parameters:
u- that identifies the userc- credential to authenticate the user
-
AuthenticationRequest
Creates a new authentication request.- Parameters:
u- that identifies the userc- credential to authenticate the userattrs- attributes to return
-
-
Method Details
-
getUser
Returns the user.- Returns:
- user identifier
-
setUser
Sets the user.- Parameters:
u- user
-
getCredential
Returns the credential.- Returns:
- user credential
-
setCredential
Sets the credential.- Parameters:
c- user credential
-
getReturnAttributes
Returns the return attributes.- Returns:
- attributes to return
-
setReturnAttributes
Sets the return attributes.- Parameters:
attrs- return attributes
-
getControls
Returns the controls.- Returns:
- controls
-
setControls
Sets the controls.- Parameters:
cntrls- controls to set
-
copy
Returns an authentication request initialized with the supplied request. This method does not perform a deep copy of request properties.- Parameters:
request- authentication request to read properties from- Returns:
- authentication request
-
toString
-
builder
Creates a builder for this class.- Returns:
- new builder
-