class AllowedTypesValidator implements Predicate<TypeMirror> {

    @Override
    public boolean test( TypeMirror typeMirror )
    {
        TypeMirror erasedActualType = typeUtils.erasure( typeMirror );

        return isValidErasedType( erasedActualType ) &&
                (!isSameErasedType( List.class, typeMirror ) || isValidListType( typeMirror )) &&
                (!isSameErasedType( Map.class, typeMirror ) || isValidMapType( typeMirror ));
    }

    public  AllowedTypesValidator( TypeMirrorUtils typeMirrors, Types typeUtils );

}