pathlib.Path.is_block_device()

Path.is_block_device()

Return True if the path points to a block device (or a symbolic link pointing to a block device), False if it points to another kind of file.

False is also returned if the path doesn’t exist or is a broken symlink; other errors (such as permission errors) are propagated.

doc_python
2016-10-07 17:40:27
Comments
Leave a Comment

Please login to continue.