CompressionOptions class - dart:io library (original) (raw)

Options controlling compression in a WebSocket.

A CompressionOptions instance can be passed to WebSocket.connect, or used in other similar places where WebSocket compression is configured.

In most cases the default compressionDefault is sufficient, but in some situations, it might be desirable to use different compression parameters, for example to preserve memory on small devices.

Constructors

CompressionOptions({bool clientNoContextTakeover = false, bool serverNoContextTakeover = false, int? clientMaxWindowBits, int? serverMaxWindowBits, bool enabled = true})

const

Properties

clientMaxWindowBitsint?

The maximal window size bit count requested by the client.

final

clientNoContextTakeoverbool

Whether the client will reuse its compression instances.

final

enabledbool

Whether WebSocket compression is enabled.

final

hashCodeint

The hash code for this object.

no setterinherited

runtimeTypeType

A representation of the runtime type of the object.

no setterinherited

serverMaxWindowBitsint?

The maximal window size bit count requested by the server.

final

serverNoContextTakeoverbool

Whether the server will reuse its compression instances.

final

Methods

noSuchMethod(Invocation invocation)→ dynamic

Invoked when a nonexistent method or property is accessed.

inherited

toString()→ String

A string representation of this object.

inherited

Operators

operator ==(Object other)→ bool

The equality operator.

inherited

Constants

compressionDefault → const CompressionOptions

Default WebSocket compression configuration.

compressionOff → const CompressionOptions

No-compression configuration.