add a isA method for subtype checking