The Typesafe Enum pattern as a PHP component.