c351e0c3e6dd4f13719150cefc9863be8e953182
[mdref/mdref-http] / http / Encoding / Stream / Enbrotli / encode.md
1 # static string http\Encoding\Stream\Enbrotli::encode(string $data[, int $flags = 0])
2
3 Encode data with brotli encoding.
4
5 ## Params:
6
7 * string $data
8 The data to compress.
9 * Optional int $flags = 0
10 Any compression tuning flags. See http\Encoding\Stream\Enbrotli and http\Encoding\Stream constants.
11
12 ## Returns:
13
14 * string, the compressed data.
15
16 ## Warnings:
17
18 * If $data cannot be encoded.