from_stream method
Leave feedback
On this page
Detects file type by reading the file signature.
def from_stream(cls, stream):
...
| Parameter | Type | Description |
|---|---|---|
| stream | io.RawIOBase |
The file stream. |
Detects file type by reading the file signature.
def from_stream(cls, stream, password):
...
| Parameter | Type | Description |
|---|---|---|
| stream | io.RawIOBase |
The file stream. |
| password | str |
The password to open the file. |
Detects file type by reading the file signature.
def from_stream(cls, stream, logger):
...
| Parameter | Type | Description |
|---|---|---|
| stream | io.RawIOBase |
The file stream. |
| logger | ILogger |
The logger. |
Returns: FileType: The detected file type, or FileType.unknown if detection fails.
Detects the file type by reading the file signature.
def from_stream(cls, stream, password, logger):
...
| Parameter | Type | Description |
|---|---|---|
| stream | io.RawIOBase |
The file stream. |
| password | str |
The password to open the file. |
| logger | ILogger |
The logger. |
Returns: FileType: The detected file type, or FileType.unknown if detection fails.
- class
FileType
Was this page helpful?
Any additional feedback you'd like to share with us?
Please tell us how we can improve this page.
Thank you for your feedback!
We value your opinion. Your feedback will help us improve our documentation.