Base class for creating handlers that may send blobs to users.
def google.appengine.ext.webapp.blobstore_handlers.BlobstoreDownloadHandler.send_blob |
( |
|
self, |
|
|
|
blob_key_or_info, |
|
|
|
content_type = None , |
|
|
|
save_as = None , |
|
|
|
start = None , |
|
|
|
end = None , |
|
|
|
kwargs |
|
) |
| |
Send a blob-response based on a blob_key.
Sets the correct response header for serving a blob. If BlobInfo
is provided and no content_type specified, will set request content type
to BlobInfo's content type.
Args:
blob_key_or_info: BlobKey or BlobInfo record to serve.
content_type: Content-type to override when known.
save_as: If True, and BlobInfo record is provided, use BlobInfos
filename to save-as. If string is provided, use string as filename.
If None or False, do not send as attachment.
start: Start index of content-range to send.
end: End index of content-range to send. End index is inclusive.
use_range: Use provided content range from requests Range header.
Mutually exclusive to start and end.
Raises:
ValueError on invalid save_as parameter.