Package org.apereo.cas.authentication
Class DefaultAuthentication
- java.lang.Object
-
- org.apereo.cas.authentication.DefaultAuthentication
-
- All Implemented Interfaces:
java.io.Serializable,org.apereo.cas.authentication.Authentication
public class DefaultAuthentication extends java.lang.Object implements org.apereo.cas.authentication.AuthenticationImmutable authentication event whose attributes may not change after creation. This class is designed for serialization and is suitable for long-term storage.- Since:
- 3.0.0
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description DefaultAuthentication(java.time.ZonedDateTime date, java.util.List<org.apereo.cas.authentication.CredentialMetaData> credentials, org.apereo.cas.authentication.principal.Principal principal, java.util.Map<java.lang.String,java.lang.Object> attributes, java.util.Map<java.lang.String,org.apereo.cas.authentication.AuthenticationHandlerExecutionResult> successes, java.util.Map<java.lang.String,java.lang.Throwable> failures)Creates a new instance with the given data.DefaultAuthentication(java.time.ZonedDateTime date, org.apereo.cas.authentication.principal.Principal principal, java.util.Map<java.lang.String,java.lang.Object> attributes, java.util.Map<java.lang.String,org.apereo.cas.authentication.AuthenticationHandlerExecutionResult> successes)Creates a new instance with the given data.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddAttribute(java.lang.String name, java.lang.Object value)voidupdate(org.apereo.cas.authentication.Authentication authn)voidupdateAll(org.apereo.cas.authentication.Authentication authn)
-
-
-
Constructor Detail
-
DefaultAuthentication
public DefaultAuthentication(@NonNull java.time.ZonedDateTime date, @NonNull org.apereo.cas.authentication.principal.Principal principal, @NonNull java.util.Map<java.lang.String,java.lang.Object> attributes, @NonNull java.util.Map<java.lang.String,org.apereo.cas.authentication.AuthenticationHandlerExecutionResult> successes)Creates a new instance with the given data.- Parameters:
date- Non-null authentication date.principal- Non-null authenticated principal.attributes- Nullable map of authentication metadata.successes- Non-null map of authentication successes containing at least one entry.
-
DefaultAuthentication
public DefaultAuthentication(@NonNull java.time.ZonedDateTime date, @NonNull java.util.List<org.apereo.cas.authentication.CredentialMetaData> credentials, @NonNull org.apereo.cas.authentication.principal.Principal principal, @NonNull java.util.Map<java.lang.String,java.lang.Object> attributes, @NonNull java.util.Map<java.lang.String,org.apereo.cas.authentication.AuthenticationHandlerExecutionResult> successes, @NonNull java.util.Map<java.lang.String,java.lang.Throwable> failures)Creates a new instance with the given data.- Parameters:
date- Non-null authentication date.credentials- Non-null list of credential metadata containing at least one entry.principal- Non-null authenticated principal.attributes- Nullable map of authentication metadata.successes- Non-null map of authentication successes containing at least one entry.failures- Nullable map of authentication failures.
-
-
Method Detail
-
update
public void update(org.apereo.cas.authentication.Authentication authn)
- Specified by:
updatein interfaceorg.apereo.cas.authentication.Authentication
-
updateAll
public void updateAll(org.apereo.cas.authentication.Authentication authn)
- Specified by:
updateAllin interfaceorg.apereo.cas.authentication.Authentication
-
addAttribute
public void addAttribute(java.lang.String name, java.lang.Object value)- Specified by:
addAttributein interfaceorg.apereo.cas.authentication.Authentication
-
-