Closed ocehugo closed 3 years ago
@lbesnard - just did sync.
I think it would be good to stick to snake case for function naming.
Did you mean camelCase right? I'll be honest, the camelCase is not my cup of tea, but I'm trying to stick to it, particularly for functions that can be access from the prompt.
The camelStyle is quite a problem for me because I'm too used to disambiguate types when reading the code (a-la python). Implicit rules I adopted:
isstruct
, because this follows core matlab functions.+IMOS
and class methods.The scope of this PR is well above creating a simple parser.
Yes, it's plumbing first, parser next. The parser would be way more complicated without the plumbing, plus the plumbing allows me to write better code and do deep refactorings if needed.
@lbesnard - see new commits.
This is an aggregated of two dependent branches - IMOS Utilities and the Ocean Contour Parser. Although it's big, there quite a bit of dog fooding in there for the utilities and the parser, so better to review together.
The branch here implements further Utilities that I plan to use in any new parser. There is quite some tooling here that helps to reduce code size, hopefully create cleaner code, and even reduce the number of source files (e.g. test files) since now docstrings may work as simple tests. Most of the utilities are around creating variables/dimensions/etc, data access patterns, and assignment of data to toolbox structures. Some very small bugfixes are here too since they were detected some usage patterns.
The OceanContour parser is implemented as a class and uses some of these functions.
@lbesnard - Make sure you start the review after merging https://github.com/aodn/imos-toolbox/pull/687 and do a relink of this PR to master (on the edit button of the PR title). This should update this PR to the recently merged master changes and remove the already reviewed commits.