public AuthenticationStatement newAuthenticationStatement ( final ZonedDateTime authenticationDate , final Collection < Object > authenticationMethod , final String subjectId ) { val authnStatement = newSamlObject ( AuthenticationStatement . class ) ; authnStatement . setAuthenticationInstant ( DateTimeUtils . dateTimeOf ( authenticationDate ) ) ; authnStatement . setAuthenticationMethod ( authenticationMethod != null && ! authenticationMethod . isEmpty ( ) ? authenticationMethod . iterator ( ) . next ( ) . toString ( ) : SamlAuthenticationMetaDataPopulator . AUTHN_METHOD_UNSPECIFIED ) ; authnStatement . setSubject ( newSubject ( subjectId ) ) ; return authnStatement ; }
New authentication statement .