refactor enumerations