Sure, if you have a few enums with each a few possible values, by all means do this. However, as soon as you get to have, let us say, some more enums that each have a hundred values or so, not only need to serialize them but also need to deserialize, them, also want to loop over all possible enum values and some such requirements one should start thinking about a smarter solution.