Re: netCDF and other things

On Tue, 19 Aug 2003, Don Murray wrote:

> Actually, now that I'm looking at the code, I see:
>
>              if (overrideUnit != null && !overrideUnit.equals(rtunit) &&
>                  (!Unit.canConvert(rtunit, CommonUnit.secondsSinceTheEpoch) ||
>                   rtunit.getAbsoluteUnit().equals(rtunit))) {
>                dval[0] = (float)
>                  overrideUnit.toThis((double) dval[0], rtunit);
>                r = new Real(real, dval[0], overrideUnit);
>              }
>
> and in this case, overrideUnit.equals(rtunit), so this section of
> code never gets called and it uses the rtunit (1000.0 m).  If the
> check for equality is removed, it works.  Maybe this should be
> changed to allow for this?

Yes, even though the two Units are 'equals', they may print
as different Strings. Please make this change.

Thanks,
Bill


  • 2003 messages navigation, sorted by:
    1. Thread
    2. Subject
    3. Author
    4. Date
    5. ↑ Table Of Contents
  • Search the visad archives: