Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [cross-project-issues-dev] JFace Generics

On Thu, 29 Aug 2013 22:21:53 +0200, <Mickael Istria> wrote:

I may have missed something, but wouldn't the following implementationbe a valid solution?
public E[] getElements(I inputElement) {
   return inputElement.toArray(new E[inputElement.size()]);

new E[] is not compilable, as E is a generic type.

Kind regards,
Mit freundlichen Grüßen
Andrey Loskutov


Back to the top