public boolean hasRole ( String roleName ) { if ( roles != null ) { for ( String r : roles ) { if ( r . equals ( roleName ) ) return true ; } } return false ; }
Check whether the group has the specified role .