I made the RequestMethodsMap class during the big refactoring to support Dart, so that it could be declared at the top-level of the enums module. The class takes an enum (integer) and returns the corresponding enum's name. Like requestMethodsMap.get(0)// -> 'GET'But it should be able to be a constant and provide the same usefulness for converting RequestMethods enum values to strings and vice versa, with less overhead
I made the
RequestMethodsMapclass during the big refactoring to support Dart, so that it could be declared at the top-level of the enums module. The class takes an enum (integer) and returns the corresponding enum's name. LikerequestMethodsMap.get(0)// -> 'GET'But it should be able to be a constant and provide the same usefulness for convertingRequestMethodsenum values to strings and vice versa, with less overhead