first off you question sounds like "how do I do first class functions in java" historically that answer was "make a class with one method, it's shit suck it" things are better now though. But really ...
Generics make your code more flexible and easier to read, and they help you avoid ClassCastExceptions at runtime. Get started with this introduction to using generics with the Java Collections ...
Some results have been hidden because they may be inaccessible to you
Show inaccessible results