agave-realtime/realtime-api/src/main/java/org/iplantc/service/realtime/resource/impl/AbstractServerResource.java
/**
     * Indicates if the given role is in the list of roles.
     * @param roles
     *            The list of roles.
     * @param roleName
     *            The name of the role to look for.
     * @return True if the list of roles contains the given role.
     */
Indicates if the given role is in the list of roles.
@param roles
The list of roles.
@param roleName
The name of the role to look for.
@return True if the list of roles contains the given role.
Indicates if the given role is in the list of roles . @param roles The list of roles . @param roleName The name of the role to look for . @return True if the list of roles contains the given role .
protected boolean hasRole(List<Role> roles, String roleName) {
        for (Role role : roles) {
            if (role.getName().equals(roleName)) {
                return true;
            }
        }
        return false;
    }
protected boolean hasRole ( List < Role > roles , String roleName ) { for ( Role role : roles ) { if ( role . getName ( ) . equals ( roleName ) ) { return true ; } } return false ; }
Indicates if the given role is in the list of roles.
Indicates if the given role is in the list of roles .