add getType method