Safe Haskell | None |
---|---|
Language | Haskell98 |
Synopsis
- createTempDirectory :: MonadResource m => Maybe FilePath -> String -> m (ReleaseKey, FilePath)
- openBinaryTempFile :: MonadResource m => Maybe FilePath -> String -> m (ReleaseKey, FilePath, Handle)
- openTempFile :: MonadResource m => Maybe FilePath -> String -> m (ReleaseKey, FilePath, Handle)
Documentation
:: MonadResource m | |
=> Maybe FilePath | optional parent directory |
-> String | filename template; for security, a random number will be inserted between the filename and any extension. |
-> m (ReleaseKey, FilePath) |
Create a temporary directory. The directory will be deleted if empty
when the resource is released. If a parent directory is supplied, the
temporary directory will be created there; otherwise, it will be created
in the system temporary directory returned by getTemporaryDirectory
.
:: MonadResource m | |
=> Maybe FilePath | optional parent directory |
-> String | filename template; for security, a random number will be inserted between the filename and any extension. |
-> m (ReleaseKey, FilePath, Handle) |
Open a temporary file in binary mode. The file will be readable and
writeable, but only by the current user. The file will be deleted when
the resource is released, if it still exists. If a parent directory is
supplied, the file will be created there; otherwise, it will be created
in the system temporary directory returned by getTemporaryDirectory
.
:: MonadResource m | |
=> Maybe FilePath | optional parent directory |
-> String | filename template; for security, a random number will be inserted between the filename and any extension. |
-> m (ReleaseKey, FilePath, Handle) |
Open a temporary file. The file will be readable and writeable, but
only by the current user. The file will be deleted when the resource is
released, if it still exists. If a parent directory is supplied, the
file will be created there; otherwise, it will be created in the system
temporary directory returned by getTemporaryDirectory
.