harmony-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Nathan Beyer <ndbe...@apache.org>
Subject Re: Blank constructor throwing NotImplementedException
Date Sun, 09 May 2010 16:36:26 GMT
The NotImplementedExceptions are to both indicate at runtime this
stuff won't work and were a marker for the JAPI tools [1] to point out
that even though the method signature matches, it's not complete.

If the code is being implemented, then it can be removed.

[1] http://sab39.netreach.com/Software/Japitools/42/

On Sat, May 8, 2010 at 7:08 PM, Lang Yang <yanglang@gmail.com> wrote:
> Hello guys,
>
> I have seen some constructors throws a NotImplementedExpcetion when JDOC
> says these constructors are supposed to just construct a blank class. I
> thought for this case we just leave that constructor blank is good enough.
> Is there any specific reason why we are throwing NotImplementedExceptions?
>
> e.g.:
> protected ImageInputStreamSpi() - Constructs a blank ImageInputStreamSpi. It
> is up to the subclass to initialize instance variables and/or override
> method implementations in order to provide working versions of all methods.
> [0]
>
>    protected ImageInputStreamSpi() throws NotImplementedException {
>        // TODO: implement
>        throw new NotImplementedException();
>    }
>
> Thanks,
>
> Lang
>
> [0] -
> http://java.sun.com/j2se/1.4.2/docs/api/javax/imageio/spi/ImageInputStreamSpi.html#ImageInputStreamSpi()
>

Mime
View raw message