@NotThreadSafe public static final class AuthenticationResponse.Builder extends AbstractAuthenticationResponse.AbstractBuilder<AuthenticationResponse.Builder,AuthenticationResponse>
AuthenticationResponse
class.
Effective Java, 2nd Ed. : Item 2: Builder Pattern.
This Builder is not thread-safe but is thread-compliant, it is supposed to be used by only one thread.
Constructor and Description |
---|
Builder() |
Builder(AuthenticationResponse.Builder copy) |
Builder(IAuthenticationResponse copy) |
Modifier and Type | Method and Description |
---|---|
protected AuthenticationResponse |
newInstance()
Method to be implemented by subtypes to create the right type
T of instances. |
protected void |
validate()
Validates the state of this Builder before allowing to create new instances of the built type
T . |
attributes, audienceRestriction, build, consent, country, encrypted, encrypted, failure, failure, id, inResponseTo, ipAddress, issuer, levelOfAssurance, lightResponse, notBefore, notOnOrAfter, relayState, responseStatus, statusCode, statusMessage, subject, subjectNameIdFormat, subStatusCode
public Builder()
public Builder(@Nonnull AuthenticationResponse.Builder copy)
public Builder(@Nonnull IAuthenticationResponse copy)
protected void validate() throws IllegalArgumentException
AbstractAuthenticationResponse.AbstractBuilder
T
.validate
in class AbstractAuthenticationResponse.AbstractBuilder<AuthenticationResponse.Builder,AuthenticationResponse>
IllegalArgumentException
- if the builder is not in a legal state allowing to proceed with the creation
of a T
instance.@Nonnull protected AuthenticationResponse newInstance()
AbstractAuthenticationResponse.AbstractBuilder
T
of instances.
The typical implementation simply consists in writing return new MySubType(this);
newInstance
in class AbstractAuthenticationResponse.AbstractBuilder<AuthenticationResponse.Builder,AuthenticationResponse>
T
instance based on this Builder instance.Copyright © 2020. All Rights Reserved.