Class: BlobReader

Guacamole.BlobReader(streamnon-null, mimetypenon-null)

new BlobReader(streamnon-null, mimetypenon-null)

A reader which automatically handles the given input stream, assembling all received blobs into a single blob by appending them to each other in order. Note that this object will overwrite any installed event handlers on the given Guacamole.InputStream.
Parameters:
Name Type Description
stream Guacamole.InputStream The stream that data will be read from.
mimetype string The mimetype of the blob being built.
Source:

Methods

getBlob() → (non-null) {Blob}

Returns the contents of this Guacamole.BlobReader as a Blob.
Source:
Returns:
The contents of this Guacamole.BlobReader.
Type
Blob

getLength() → (non-null) {number}

Returns the current length of this Guacamole.InputStream, in bytes.
Source:
Returns:
The current length of this Guacamole.InputStream.
Type
number

Events

onend

Fired once this stream is finished and no further data will be written.
Source:

onprogress

Fired once for every blob of data received.
Parameters:
Name Type Description
length number The number of bytes received.
Source: