mirror of https://github.com/google/brotli
parent
71fe6cac06
commit
36533a866e
|
@ -453,7 +453,7 @@ BROTLI_ENC_API BROTLI_BOOL BrotliEncoderHasMoreOutput(
|
||||||
*
|
*
|
||||||
* This method is used to make language bindings easier and more efficient:
|
* This method is used to make language bindings easier and more efficient:
|
||||||
* -# push data to ::BrotliEncoderCompressStream,
|
* -# push data to ::BrotliEncoderCompressStream,
|
||||||
* until ::BrotliEncoderHasMoreOutput returns BROTL_TRUE
|
* until ::BrotliEncoderHasMoreOutput returns BROTLI_TRUE
|
||||||
* -# use ::BrotliEncoderTakeOutput to peek bytes and copy to language-specific
|
* -# use ::BrotliEncoderTakeOutput to peek bytes and copy to language-specific
|
||||||
* entity
|
* entity
|
||||||
*
|
*
|
||||||
|
|
|
@ -587,7 +587,7 @@ invalid values might be accepted in case they would not break encoding process\&
|
||||||
.PP
|
.PP
|
||||||
Acquires pointer to internal output buffer\&. This method is used to make language bindings easier and more efficient:
|
Acquires pointer to internal output buffer\&. This method is used to make language bindings easier and more efficient:
|
||||||
.IP "1." 4
|
.IP "1." 4
|
||||||
push data to \fBBrotliEncoderCompressStream\fP, until \fBBrotliEncoderHasMoreOutput\fP returns BROTL_TRUE
|
push data to \fBBrotliEncoderCompressStream\fP, until \fBBrotliEncoderHasMoreOutput\fP returns BROTLI_TRUE
|
||||||
.IP "2." 4
|
.IP "2." 4
|
||||||
use \fBBrotliEncoderTakeOutput\fP to peek bytes and copy to language-specific entity
|
use \fBBrotliEncoderTakeOutput\fP to peek bytes and copy to language-specific entity
|
||||||
.PP
|
.PP
|
||||||
|
|
|
@ -51,7 +51,7 @@ def main(args=None):
|
||||||
parser = argparse.ArgumentParser(
|
parser = argparse.ArgumentParser(
|
||||||
prog=os.path.basename(__file__), description=__doc__)
|
prog=os.path.basename(__file__), description=__doc__)
|
||||||
parser.add_argument(
|
parser.add_argument(
|
||||||
'--version', action='version', version=brotli.__version__)
|
'--version', action='version', version=brotli.version)
|
||||||
parser.add_argument(
|
parser.add_argument(
|
||||||
'-i',
|
'-i',
|
||||||
'--input',
|
'--input',
|
||||||
|
|
|
@ -8,7 +8,7 @@
|
||||||
import _brotli
|
import _brotli
|
||||||
|
|
||||||
# The library version.
|
# The library version.
|
||||||
__version__ = _brotli.__version__
|
version = __version__ = _brotli.__version__
|
||||||
|
|
||||||
# The compression mode.
|
# The compression mode.
|
||||||
MODE_GENERIC = _brotli.MODE_GENERIC
|
MODE_GENERIC = _brotli.MODE_GENERIC
|
||||||
|
|
|
@ -44,9 +44,17 @@ TESTDATA_FILES = [
|
||||||
'alice29.txt', # Large text
|
'alice29.txt', # Large text
|
||||||
'random_org_10k.bin', # Small data
|
'random_org_10k.bin', # Small data
|
||||||
'mapsdatazrh', # Large data
|
'mapsdatazrh', # Large data
|
||||||
|
'ukkonooa', # Poem
|
||||||
]
|
]
|
||||||
|
|
||||||
TESTDATA_PATHS = [os.path.join(TESTDATA_DIR, f) for f in TESTDATA_FILES]
|
# Some files might be missing in a lightweight sources pack.
|
||||||
|
TESTDATA_PATH_CANDIDATES = [
|
||||||
|
os.path.join(TESTDATA_DIR, f) for f in TESTDATA_FILES
|
||||||
|
]
|
||||||
|
|
||||||
|
TESTDATA_PATHS = [
|
||||||
|
path for path in TESTDATA_PATH_CANDIDATES if os.path.isfile(path)
|
||||||
|
]
|
||||||
|
|
||||||
TESTDATA_PATHS_FOR_DECOMPRESSION = glob.glob(
|
TESTDATA_PATHS_FOR_DECOMPRESSION = glob.glob(
|
||||||
os.path.join(TESTDATA_DIR, '*.compressed'))
|
os.path.join(TESTDATA_DIR, '*.compressed'))
|
||||||
|
|
|
@ -7,7 +7,6 @@ import subprocess
|
||||||
import unittest
|
import unittest
|
||||||
|
|
||||||
from . import _test_utils
|
from . import _test_utils
|
||||||
import brotli
|
|
||||||
|
|
||||||
BRO_ARGS = _test_utils.BRO_ARGS
|
BRO_ARGS = _test_utils.BRO_ARGS
|
||||||
TEST_ENV = _test_utils.TEST_ENV
|
TEST_ENV = _test_utils.TEST_ENV
|
||||||
|
|
Loading…
Reference in New Issue