Looking through different Python modules I have several times seen that classes are used to define a collection of valid arguments and I wonder what the purpose of this approach is.
E.g. consider the following class:
class ArgumentOption:
ARG1 = "ARG1"
ARG2 = "ARG2"
ARG3 = 3
What is the purpose of this approach as opposed to just defining a set, list, tuple, or something else containing the same options? Many times I see that functions might as well have take a string, int or whatever as argument instead of an instance of a class as defined above.
0