createTempFilename function

String createTempFilename({
  1. String? suffix,
  2. String? pathToTempDir,
})

Generates a temporary filename in pathToTempDir or if inTempDir os not passed then in the system temp directory. The generated filename is is guaranteed to be globally unique.

This method does NOT create the file.

The temp file name will be uuid.tmp unless you provide a suffix in which case the file name will be uuid.suffix

Implementation

String createTempFilename({String? suffix, String? pathToTempDir}) =>
    core.createTempFilename(suffix: suffix, pathToTempDir: pathToTempDir);