casasglobal-org / psymple

GNU General Public License v3.0
1 stars 2 forks source link

Container class development #38

Closed GJHSimmons closed 4 months ago

GJHSimmons commented 6 months ago

The Container class is designed to hold SymbolWrapper objects in a way which:

  1. Allows the getting of objects via their string, Symbol or index identifiers,
  2. Allows two Container objects to be added together by combining their items with + notation, as well as allows the combination of a Container and SymbolWrapper object with + notation.

As development has continued, the accessing of objects via index identifiers is rarely done, and the interface of psymple has become increasingly data-driven through string representations.

It therefore makes sense to re-implement the Container class as a subclass of dict, so that SymbolWrapper objects can be easily identified via their string representations, eg. "object.child.child.parameter". The second feature (2.) above can be reimplemented without issue, if required.

GJHSimmons commented 4 months ago

Solved by #42.