11 lines
263 B
Python
11 lines
263 B
Python
from enum import Enum
|
|
from typing import List
|
|
|
|
from image_prediction.formatter.formatters.key_formatter import KeyFormatter
|
|
|
|
|
|
class EnumFormatter(KeyFormatter):
|
|
@staticmethod
|
|
def format_key(key):
|
|
return key.value if isinstance(key, Enum) else key
|