1) Why this enum should be a part of public API?
2) It is better to add enum name, and use name instead of `int` below.