generics all the way