generics: how to tell more about the parameter?
- From: Mikhail Teterin <usenet+mill@xxxxxxxxxxxxxxxxx>
- Date: Tue, 29 Apr 2008 17:37:12 -0400
Hi!
I'd like to promise certain things about the parameter of a generic:
public class Foo<Bar implements Something> {
...
}
but that's a syntax error immediately -- javac expects a closing `>' right
where the space after `Bar' is in the above example...
How can I do this -- so that I can rely on Bar's features inside Foo and
have the compiler enforce the possible Bar's compliance?
Thanks!
-mi
.
- Follow-Ups:
- Re: generics: how to tell more about the parameter?
- From: Joshua Cranmer
- Re: generics: how to tell more about the parameter?
- Prev by Date: Re: Calendar and OC4J
- Next by Date: Re: generics: how to tell more about the parameter?
- Previous by thread: Re: Calendar and OC4J
- Next by thread: Re: generics: how to tell more about the parameter?
- Index(es):
Relevant Pages
|
|