Small design issue here. I am trying to develop a calculation application in C #. I have a class, let it call InputRecord, which contains 100 fields (multidimensional arrays). This class InputRecordclass will be used in a number of CalculationEngines. Each CalculcationEngine can make changes to several fields in the InputRecord. These changes are the steps necessary to calculate it.
Now I do not want the local changes made to InputRecord to be used in other classes of CalculcationEngine.
The first solution that comes to mind is the use of structure: these are value types. However, I would like to use inheritance: each CalculationEngine needs several fields related only to this engine: it has its own InputRecord based on BaseInputRecord.
Can someone point me to a design that will help me accomplish this?
source
share