@staticmethod
def _parse_optional_int(value: 'typing.Optional[typing.Union[str, int]]'
    ) ->'typing.Optional[int]':
    """Parse optional integer field in source data.

        :param value: value to process
        :type value: typing.Optional[typing.Union[str, int]]
        :return: integer value if applicable
        :rtype: typing.Optional[int]
        """
    if value is None or isinstance(value, int):
        return value
    return int(value)
