def create_temp_file_name(suffix, prefix=None, dir=None, directory=None):
    """
    Small convenience function that creates temporary files.

    This function is a wrapper around the Python built-in
    function tempfile.mkstemp.

    """
    if dir is not None:
        warnings.warn(
            "The dir argument is deprecated.\n" +
            "Please use the directory argument instead.", DeprecationWarning)
        # Deprecated since 1.9.0, will be removed in 2.0.0
        directory = dir

    if not prefix:
        prefix = tempfile.gettempprefix()
    fd, name = tempfile.mkstemp(suffix=suffix, prefix=prefix, dir=directory)
    file_obj = os.fdopen(fd)
    file_obj.close()
    return name
def create_temp_file_name ( suffix , prefix = None , dir = None , directory = None ) : if dir is not None : warnings . warn ( "The dir argument is deprecated.\n" + "Please use the directory argument instead." , DeprecationWarning ) directory = dir if not prefix : prefix = tempfile . gettempprefix ( ) fd , name = tempfile . mkstemp ( suffix = suffix , prefix = prefix , dir = directory ) file_obj = os . fdopen ( fd ) file_obj . close ( ) return name
Small convenience function that creates temporary files.

    This function is a wrapper around the Python built-in
    function tempfile.mkstemp.