Re: language purist

2002-11-12 Thread Andrew C. Oliver
You could use class inheritance as well as interface inheritance, don't you? Or could interfaces have multiple parents while classes could not? [i'm not friend of multiple inheritance anyway] I tried to redesign it (mainly to test whether this interface usage does problems to gcj or not - seems

Re: language purist

2002-11-12 Thread Nicola Ken Barozzi
Andrew C. Oliver wrote: I do that too. Only in order to meet POI coding standards I do: /** * Really great javadoc comments * @author Andrew C. Oliver <[EMAIL PROTECTED]> */ interface ReallyNiceName { /** * More great comments! */ final static int REALLY_DESCRIPTIVE_NAME = 1; } Thes

Re: language purist

2002-11-12 Thread Andrew C. Oliver
Not to mention how disgusting it makes your code to have to do TheClassName.BLA_BLA in every method call when BLA_BLA is sufficient. Makes for long unnecessary line lengths. Using the interface is the best simulation of name spaces combined with defines. Rainer Klute wrote: I do not cast doub

Re: language purist

2002-11-12 Thread Andrew C. Oliver
I do that too. Only in order to meet POI coding standards I do: /** * Really great javadoc comments * @author Andrew C. Oliver <[EMAIL PROTECTED]> */ interface ReallyNiceName { /** * More great comments! */ final static int REALLY_DESCRIPTIVE_NAME = 1; } Rainer Klute wrote: Hi Marti

Re: language purist

2002-11-12 Thread Martin Aliger
> >I do not cast doubt upon use of constants in interfaces (esp. in case you outline) >but write intarface consting _only_ of constants? I think in this case is much better >use of public class - there is no need to derive from it or implement something. Just >public + class reference is enough.

Re: language purist

2002-11-12 Thread Rainer Klute
>I do not cast doubt upon use of constants in interfaces (esp. in case you outline) >but write intarface consting _only_ of constants? I think in this case is much better >use of public class - there is no need to derive from it or implement something. Just >public + class reference is enough. A

Re: language purist

2002-11-11 Thread Martin Aliger
> Hi Martin! Hi! > >Why are you using this contruct?: > > > >interface ABC { > > final static int C1 = 1; > >} > >... > > >Is this common use of interfaces in Java? ... > > This is indeed common usage. You'll need it if you want to specify an > interface that does not only define methods bu

Re: language purist

2002-11-11 Thread Rainer Klute
Hi Martin! >Why are you using this contruct?: > >interface ABC { > final static int C1 = 1; >} >... >Is this common use of interfaces in Java? ... This is indeed common usage. You'll need it if you want to specify an interface that does not only define methods but also some constants that ar

language purist

2002-11-11 Thread Martin Aliger
Hi all, I'm a language purist so take me with a pinch of salt [I found this in dictionary so hope it fits ;-)] Why are you using this contruct?: interface ABC { final static int C1 = 1; } class DEF implements ABC { ... using C1 constant... } Is this common use of interfaces in Ja