Function<Type, Iterable<Class<?>>> function = new Function<Type, Iterable<Class<?>>>()
{
@Override
public Iterable<Class<?>> map( Type type )
{
Mixins mixins = Annotations.annotationOn( type, Mixins.class );
if( mixins == null )
{
return empty();
}
else
{
return iterable( mixins.value() );
}
}
};
Iterable<Class<?>> flatten = flattenIterables( map( function, allTypes ) );
return toList( flatten );