@classmethod
def from_str(cls, value):
    """Convert string to enum element.

        :param str value:
            String with value to convert.
        :returns:
            Enum class object.
        :raises:
            NotImplementedError
        """
    int_value = int(value)
    for item in cls:
        if item.value == int_value:
            return item
    raise NotImplementedError("'{}' is no element of '{}'".format(value,
        cls.__name__))
