Am I right that a temporary file is created in memory?
If no, could we have a method like tempMemFile? That makes working with them a lot faster for certain operations (like creating a file for attachments )…
If yes, can I overwrite it with the same name over and over without any issue?
No temp files are really created on disk in temp dir
I do not understand why you need a temp mem file, all global variables are in mem, which you can write to disk, assign to media fields etc.