MjpegStreamReader class

MjpegStreamReader retrieves a motion jpeg(mjpeg) stream from the specified uri and publishes the jpeg frame.

Constructors

MjpegStreamReader.new({required String uri, Client? client, Duration timeout = const Duration(seconds: 5)})
Constructor uri specifies the motion jpeg(mjpeg) stream url. client specifies the HTTP client. If not specified, it is generated internally. timeout specifies the HTTP connection timeout.

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
stream Stream<Uint8List>
no setter
timeout Duration
final
uri String
final

Methods

dispose() → void
Cancel the subscription to stream, and reset the internal state, then close the internal stream controller.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
start() Future<void>
Connect to the specified uri, parses the chunks, and add jpeg frame to stream to view.
stop({bool closeController = false}) → void
Cancel the subscription to stream, and reset the internal state. closeController if true, close the internal streamcontroller.
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited