[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: request: package-private to protected
- Subject: Re: request: package-private to protected
- Date: Thu, 18 Apr 2002 11:20:36 -0600
Well, the right thing to do is for me to carefully decide which methods can
be subclassed and which not. In lieu of that hard work, perhaps you could
send me the list of things which you found necessary to change to protected.
I can understand why you need to call Variable( ucar.netcdf.Variable ncvar,
ArrayList myDims) if you want to subclass variable.
PS: do you know about ucar.nc2.VariableStandardized class which may do the
scale and offset as you need?
PPS: Id be interested in hearing a summary of the features you have added;
perhaps i would add some into the main release if they are of general use.
----- Original Message -----
From: "Keith Davidson" <address@hidden>
To: "John Caron" <address@hidden>
Sent: Wednesday, April 17, 2002 9:45 PM
Subject: request: package-private to protected
> Hi John,
>
> I know this is a big ask, but I am wondering if it is possible to change
> everything that is package-private to protected for future releases of the
> Java NetCDF packages. This creates some difficulty for us to subclass the
> nc2 package. I can change the source myself, and recompile it, but I have
> to re-do it every time there is a new release.
>
> If you need an example of why this is required: we have implemented
> automation of things like scale and offset on reading and writing. ie,
all
> the read and write operations of WniomNetcdfFile and
> WniomNetcdfFileWriteable look for attributes called "scale_factor" or
> "add_offset", and if they exist, perform the scale and offset operations
> after/before reading/writing. This all works fine. However, there are
> also read methods in the Variable class, and although I can override these
> in WniomVariable, I can't get
WniomNetcdfFile.findVariable(java.lang.String
> name) to return a WniomVariable, only a Variable, because, for example the
> Variable( ucar.netcdf.Variable ncvar, ArrayList myDims) constructor is
> package-private, and so on...
>
> Thank you for your time.
>
> Keith Davidson
> Software Engineer
> WNI Oceanographers and Meteorologists
> 31 Bishop Street
> JOLIMONT WA 6014
> AUSTRALIA
> http://www.wnise.com
> Phone: +61 8 9387 7955 Fax: +61 8 9387 6686
>
>
>
>
> At 07:25 AM 4/18/02, you wrote:
> >For netcdf java (version 2) users:
> >
> >I have discovered an embarrrassing performance bug that makes writing new
> >files (blush) 40 time slower in some cases. You would probably only
notice
> >if you write medium or large files ( > 10 Mb? ). I found it on Windows
NT,
> >not sure if the 40x slowdown shows up on Unix OS.
> >
> >Fixed version is 2.06 at
> >
> > http://www.unidata.ucar.edu/packages/netcdf-java/
> >
> >This version has a 25% speed improvement when writing files on all
> >platforms. If you see a dramatic improvement, please let me know the
> >details.
> >
> >John Caron
>
>