Classes (does this make sense?)

Saaa empty at needmail.com
Tue Jun 3 14:16:36 PDT 2008


> Saaa wrote:
>
>> My idea was to put everything all the fruits share in the same (abstract)
>> super class.
>> I would also like the assert code to be in the super class as it is the
>> same for all fruits.
>> Same for the color setter/getter.
>>
>>
>
> Sure that's reasonable, then you can let the derived classes manipulate 
> the
> color via the getter / setter interface and still make the color field
> private.
>

I think I'll do that then ;) 




More information about the Digitalmars-d-learn mailing list