generics and models that take X as model object but return Y

2009-12-30 Thread Sam Zilverberg
What's the best practice when using generics with models that take some object but return another type of object? examples: When you have a collection and need to convert it to a list for listview purposes. When you have some object and you need a wrapping model that creates some string

Re: generics and models that take X as model object but return Y

2009-12-30 Thread Igor Vaynberg
/** * Simplifies implementing wrapper models that adapt from model object of one type to another * * @author igor.vaynberg * * @param N *new type * @param O *old type */ public abstract class AdapterModelN, O implements IModelN { private static final long