Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[5.x] work on filters package #966

Merged
merged 5 commits into from
Aug 22, 2022

Conversation

haileyajohnson
Copy link
Contributor

Description of Changes

  • changes to the filters api
  • share filters between hdf5 and zarr
  • rewrite docs to use new api

PR Checklist

  • Indicate the version associated with this PR in the Title
    (e.g. "[5.x]: This is my PR title")
  • Link to any issues that the PR addresses
  • Add labels, especially if the PR should be ported to other versions
    (these labels start with "port: ")
  • Open as a draft PR
    until ready for review
  • Make sure GitHub tests pass
  • Mark PR as "Ready for Review"

@haileyajohnson haileyajohnson force-pushed the port-filters branch 2 times, most recently from b75477f to 6eb0866 Compare August 19, 2022 23:05
cdm/core/src/main/java/ucar/nc2/filter/Filters.java Outdated Show resolved Hide resolved
}

// try by id next
int id = ((Short) oid).intValue();
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

maybe we should check that oid instanceof Short before casting here?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we already checked that it's a Number, I think any Number type can cast to a Short without an exception

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yeah, maybe I am overthinking it here, but could it happen that a filter does have a name but no provider for that name? then you reach this code without having checked if the oid instanceof Number

haileyajohnson and others added 2 commits August 22, 2022 10:25
Co-authored-by: Tara Drwenski <tdrwenski@users.noreply.github.com>
…utBB.java

Co-authored-by: Tara Drwenski <tdrwenski@users.noreply.github.com>
@haileyajohnson haileyajohnson merged commit 8925a9e into Unidata:maint-5.x Aug 22, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants