public static Collection < SimplePrincipalProvider > getSimplePrincipals ( Collection < PrincipalProvider < ? > > principalProviders ) { Collection < SimplePrincipalProvider > principals = new ArrayList <> ( ) ; for ( PrincipalProvider < ? > principal : principalProviders ) { if ( principal instanceof SimplePrincipalProvider ) { principals . add ( ( SimplePrincipalProvider ) principal ) ; } } return principals ; }
Extracts the simple principals of the collection of principals