refactor: Dissolve2 CIF #2425
Conversation
9e73738 to
e7ce154
Compare
trisyoungs
left a comment
There was a problem hiding this comment.
Two significant comments to make:
- We could remove all of the old "secondary" CIF nodes which just adjust things in the main context since we need to reimplement them in node form anyway. That would break unit tests for the time being, but its probably easier to do that than try to maintain both while we work it up.
- My thought was that we could completely remove use of
ConfigurationandSpeciesand generate aStructuredirectly from the contents of the CIF.
…IFImportBaseVisitor.h)
c50f630 to
e14f873
Compare
| // Temporary atom types used for unique atom labels | ||
| std::vector<std::shared_ptr<AtomType>> atomLabelTypes_; |
There was a problem hiding this comment.
I wrote this - I don't like it any more! It's a strange use of AtomType. I'll flag this on the Dissolve2ToDo as something to refactor.
There was a problem hiding this comment.
We should be able to use the new capability for string name on StructureAtom that you added in #2427 to link the newly added structural atom to the relevant atom type bonding pairs information. That way, we shouldn't need the atomLabelTypes_ vector.
There was a problem hiding this comment.
How come the graphene species dialog got removed here? I don't recall there being any dependence on CIF in there! This is definitely destined for a node, too...
There was a problem hiding this comment.
Looks like I got a bit trigger-happy with anything that had an apparent CIFContext include... I've looked at the code in more depth, and the dialog doesn't appear to actually make use of the class (now removed), so we could in all likelihood reinstate it (without including nodes/cif/io/cifContext.h)!
This PR lays the ground work for refactoring the CIF node ecosystem into a more condensed form, where a (most likely) single node -
ImportCIFStructureNode- returns aStructure *created from the species atoms and any connectivity parsed from the import.ciffile. Virtually all of the Dissolve1 functionality for managing.cifimport and parsing has been migrated into thenode/cif/iofolder. This includes the cif-relevant ANTLR4 classes.