implement toString and equals for all base object