IO::File::WithFilename does everything that IO::File does, but implements
filename method, that File::Temp objects have. It lets you write the code
that is ignorant of what classes of objects it works with.
.
If you want to check if it is safe to call filename method, you are
recommended to call can method rather than to check an object's inheritance:
.
print $obj->filename, "\n" if eval { $obj->can('filename') };
Installed Size: 19.5 kB
Architectures: all