A FileLike holding its content.
Attributes#
| Attribute | Type | Description |
|---|---|---|
content | bytes | |
name | str | |
content_type | str = '' | |
last_modified | datetime = datetime(1970, 1, 1, tzinfo=UTC) | |
size | int |
Functions#
__init__#
__init__(content, name, content_type='', last_modified=datetime(1970, 1, 1, tzinfo=UTC)) -> None| Parameter | Type | Description |
|---|---|---|
content | bytes | |
name | str | |
content_type | str = '' | |
last_modified | datetime = datetime(1970, 1, 1, tzinfo=UTC) |
stream#
stream() -> Stream[bytes, object]Returns Stream[bytes, object]
def stream(self) -> Stream[bytes, object]:
return succeed_stream(self.content)