metrics: type phase attributes with Phase instead of private subclasses