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

Inheritance from the NXobject base class #1506

Open
rayosborn opened this issue Nov 4, 2024 · 3 comments
Open

Inheritance from the NXobject base class #1506

rayosborn opened this issue Nov 4, 2024 · 3 comments

Comments

@rayosborn
Copy link
Contributor

It was decided at the last NIAC meeting in September that the NXobject base class should be used to define objects that are valid in all other base classes. This needs to be implemented by adding the appropriate classes to the NXobject NXDL file.

According to the documentation, I believe that the following classes should be added: NXcollection, NXdata, NXgeometry, NXlog, NXnote, NXparameters, NXtransformations.

I believe it also makes sense to add the partial name patterns that have reserved suffixes, so that these can also be validated in any base class: GROUPNAME_log, FIELDNAME_set, FIELDNAME_errors, FIELDNAME_weights, FIELDNAME_mask.

I will submit a PR to implement this policy.

@phyy-nx
Copy link
Contributor

phyy-nx commented Nov 6, 2024

For reference, specific NIAC vote was here:
#1442 (comment)

@prjemian
Copy link
Contributor

prjemian commented Nov 6, 2024

The NXobject class was introduced to be the parent of all other classes. I agree that NXroot is exceptional since it never falls under NXentry. I amend as follows:

The NXobject class is the parent class of all classes except NXroot.

Further: It is intended that NXobject never be assigned to a NX_class="NXobject" attribute in a NeXus file.

@prjemian
Copy link
Contributor

prjemian commented Nov 6, 2024

As I recall, the NXroot class was introduced as a place where common file-level attributes could be provided with standardized names. Oldest to newest, these are relevant issues and PRs (which are closed at this time):

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants