@@ -246,7 +246,7 @@ def set_filename(self, filename):
246
246
247
247
Parameters
248
248
----------
249
- filename : str
249
+ filename : str or os.PathLike
250
250
If the image format only has one file associated with it,
251
251
this will be the only filename set into the image
252
252
``.file_map`` attribute. Otherwise, the image instance will
@@ -279,7 +279,7 @@ def filespec_to_file_map(klass, filespec):
279
279
280
280
Parameters
281
281
----------
282
- filespec : str
282
+ filespec : str or os.PathLike
283
283
Filename that might be for this image file type.
284
284
285
285
Returns
@@ -321,7 +321,7 @@ def to_filename(self, filename):
321
321
322
322
Parameters
323
323
----------
324
- filename : str
324
+ filename : str or os.PathLike
325
325
filename to which to save image. We will parse `filename`
326
326
with ``filespec_to_file_map`` to work out names for image,
327
327
header etc.
@@ -419,7 +419,7 @@ def _sniff_meta_for(klass, filename, sniff_nbytes, sniff=None):
419
419
420
420
Parameters
421
421
----------
422
- filename : str
422
+ filename : str or os.PathLike
423
423
Filename for an image, or an image header (metadata) file.
424
424
If `filename` points to an image data file, and the image type has
425
425
a separate "header" file, we work out the name of the header file,
@@ -466,7 +466,7 @@ def path_maybe_image(klass, filename, sniff=None, sniff_max=1024):
466
466
467
467
Parameters
468
468
----------
469
- filename : str
469
+ filename : str or os.PathLike
470
470
Filename for an image, or an image header (metadata) file.
471
471
If `filename` points to an image data file, and the image type has
472
472
a separate "header" file, we work out the name of the header file,
0 commit comments