
########
FileTemp
########


****
NAME
****


Kernel::System::FileTemp - tmp files


***********
DESCRIPTION
***********


This module is managing temporary files and directories.


****************
PUBLIC INTERFACE
****************


new()
=====


Don't use the constructor directly, use the ObjectManager instead:


.. code-block:: perl

     my $FileTempObject = $Kernel::OM->Get('Kernel::System::FileTemp');



TempFile()
==========


returns an opened temporary file handle and its file name.
Please note that you need to close the file handle for other processes to write to it.


.. code-block:: perl

     my ($FileHandle, $Filename) = $TempObject->TempFile(
         Suffix => '.png',   # optional, defaults to '.tmp'
     );



TempDir()
=========


returns a temp directory. The directory and its contents will be removed
if the FileTemp object goes out of scope.




