def _validateParamsFor__validateToDateTimeFormat(formats, blank=False, strip=None, allowlistRegexes=None, blocklistRegexes=None, excMsg=None):
_validateGenericParameters(blank=blank, strip=strip, allowlistRegexes=allowlistRegexes, blocklistRegexes=blocklistRegexes)<EOL>if formats is None:<EOL><INDENT>raise PySimpleValidateException('<STR_LIT>')<EOL><DEDENT>if isinstance(formats, str):<EOL><INDENT>raise PySimpleValidateException('<STR_LIT>')<EOL><DEDENT>try:<EOL><INDENT>len(formats)<EOL><DEDENT>except:<EOL><INDENT>raise PySimpleValidateException('<STR_LIT>')<EOL><DEDENT>for format in formats:<EOL><INDENT>try:<EOL><INDENT>time.strftime(format) <EOL><DEDENT>except:<EOL><INDENT>raise PySimpleValidateException('<STR_LIT>')<EOL><DEDENT><DEDENT>
Raises PySimpleValidateException if the arguments are invalid. This is called by
    the validateTime() function to check its arguments. This code was
    refactored out to a separate function so that the PyInputPlus module (or
    other modules) could check their parameters' arguments for inputTime().