|
|
il y a 5 ans | |
|---|---|---|
| .. | ||
| interfaces | il y a 5 ans | |
| README.md | il y a 5 ans | |
▸ decompress(data: Uint8Array, out?: Uint8Array): Uint8Array
Defined in index.ts:774
Expands compressed GZIP, Zlib, or raw DEFLATE data, automatically detecting the format
| Name | Type | Description |
|---|---|---|
data |
Uint8Array | The data to decompress |
out? |
Uint8Array | Where to write the data. Saves memory if you know the decompressed size and provide an output buffer of that length. |
Returns: Uint8Array
▸ deflate(data: Uint8Array, opts: DeflateOptions): Uint8Array
Defined in index.ts:680
Compresses data with DEFLATE without any wrapper
| Name | Type | Default value | Description |
|---|---|---|---|
data |
Uint8Array | - | The data to compress |
opts |
DeflateOptions | {} | The compression options |
Returns: Uint8Array
▸ gunzip(data: Uint8Array, out?: Uint8Array): Uint8Array
Defined in index.ts:720
Expands GZIP data
| Name | Type | Description |
|---|---|---|
data |
Uint8Array | The data to decompress |
out? |
Uint8Array | Where to write the data. GZIP already encodes the output size, so providing this doesn't save memory. |
Returns: Uint8Array
▸ gzip(data: Uint8Array, opts: GZIPOptions): Uint8Array
Defined in index.ts:700
Compresses data with GZIP
| Name | Type | Default value | Description |
|---|---|---|---|
data |
Uint8Array | - | The data to compress |
opts |
GZIPOptions | {} | The compression options |
Returns: Uint8Array
▸ inflate(data: Uint8Array, out?: Uint8Array): Uint8Array
Defined in index.ts:690
Expands DEFLATE data with no wrapper
| Name | Type | Description |
|---|---|---|
data |
Uint8Array | The data to decompress |
out? |
Uint8Array | Where to write the data. Saves memory if you know the decompressed size and provide an output buffer of that length. |
Returns: Uint8Array
▸ unzlib(data: Uint8Array, out?: Uint8Array): Uint8Array
Defined in index.ts:758
Expands Zlib data
| Name | Type | Description |
|---|---|---|
data |
Uint8Array | The data to decompress |
out? |
Uint8Array | Where to write the data. Saves memory if you know the decompressed size and provide an output buffer of that length. |
Returns: Uint8Array
▸ zlib(data: Uint8Array, opts: ZlibOptions): Uint8Array
Defined in index.ts:737
Compress data with Zlib
| Name | Type | Description |
|---|---|---|
data |
Uint8Array | The data to compress |
opts |
ZlibOptions | The compression options |
Returns: Uint8Array