Daniel Santa Cruz wrote: > - ClassA with 10 field > - ClassB with same 10 fields > plus 2 'instance specific fields' > plus a reference to it's parent > plus a getters in every field that check if the local value is > nothing to either return the local value or the parent's value.
Use only class B for your storage. Delete the reference to parent as it is an artifact of the RDB approach. If necessary, add to it a flag that says whether the actual object is an "A" or a "B". (However, you may be able to tell this simply from whether the extra fields are not null.) Delete all the "getters" as they are artifacts of the RDB approach. In your old system there would have been a big storage penalty for carrying the extra fields. In Cache' there is not. I see no reason no reason to split up the storage.
