Are there any standard generic "callback" or "function/method" types in Java, like System.Action<T>
or System.Func<T,U>
in .NET?
In my concrete case, I need a class that wraps a method that takes one (generic) parameter of type T
and returns nothing (i.e. void
).
Yes, it's easy enough to create such a class/interface for myself, but I'd prefer a standard library class if there is one.