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 class
Authentication request builder. -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate RequestControl[]
Request controls.private Credential
User credential.private String[]
User attributes to return.private User
User. -
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.static AuthenticationRequest
copy
(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.void
setControls
(RequestControl... cntrls) Sets the controls.void
Sets the credential.void
setReturnAttributes
(String... attrs) Sets the return attributes.void
Sets 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.- Parameters:
request
- authentication request to read properties from- Returns:
- authentication request
-
toString
-
builder
Creates a builder for this class.- Returns:
- new builder
-