Skip to content

Commit 64b68d0

Browse files
committed
minor symfony#10927 Update filesystem.rst (atailouloute)
This PR was merged into the 3.4 branch. Discussion ---------- Update filesystem.rst Add missing doc for `tempnam` method Commits ------- de2f608 Update filesystem.rst
2 parents 057f279 + de2f608 commit 64b68d0

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

components/filesystem.rst

+8
Original file line numberDiff line numberDiff line change
@@ -283,6 +283,14 @@ isAbsolutePath
283283
// returns false
284284
$fileSystem->isAbsolutePath('../dir');
285285

286+
tempnam
287+
~~~~~~~
288+
289+
:method:`Symfony\\Component\\Filesystem\\Filesystem::tempnam` creates a temporary file with a unique filename, and returns its path, or throw an exception on failure::
290+
291+
// returns a path like : /tmp/prefix_wyjgtF
292+
$filesystem->tempnam('/tmp', 'prefix_');
293+
286294
dumpFile
287295
~~~~~~~~
288296

0 commit comments

Comments
 (0)