![]() |
Parolin 0.7.9 6796
Console (soon DLLs) to do a tar like job
|
#include <Python.h>
#include <bytesobject.h>
#include <structmember.h>
#include <brotli/decode.h>
#include <brotli/encode.h>
Data Structures | |
struct | BlocksOutputBuffer |
struct | brotli_Compressor |
struct | brotli_Decompressor |
Macros | |
#define | PY_SSIZE_T_CLEAN 1 |
#define | Py_ARRAY_LENGTH(array) |
#define | KB (1024) |
#define | MB (1024*1024) |
#define | INIT_BROTLI |
#define | CREATE_BROTLI Py_InitModule3("_brotli", brotli_methods, brotli_doc) |
#define | RETURN_BROTLI return |
#define | RETURN_NULL return |
Functions | |
PyDoc_STRVAR (brotli_Compressor_doc, "An object to compress a byte string.\n" "\n" "Signature:\n" " Compressor(mode=MODE_GENERIC, quality=11, lgwin=22, lgblock=0)\n" "\n" "Args:\n" " mode (int, optional): The compression mode can be MODE_GENERIC (default),\n" " MODE_TEXT (for UTF-8 format text input) or MODE_FONT (for WOFF 2.0). \n" " quality (int, optional): Controls the compression-speed vs compression-\n" " density tradeoff. The higher the quality, the slower the compression.\n" " Range is 0 to 11. Defaults to 11.\n" " lgwin (int, optional): Base 2 logarithm of the sliding window size. Range\n" " is 10 to 24. Defaults to 22.\n" " lgblock (int, optional): Base 2 logarithm of the maximum input block size.\n" " Range is 16 to 24. If set to 0, the value will be set based on the\n" " quality. Defaults to 0.\n" "\n" "Raises:\n" " brotli.error: If arguments are invalid.\n") | |
PyDoc_STRVAR (brotli_Compressor_process_doc, "Process \"string\" for compression, returning a string that contains \n" "compressed output data. This data should be concatenated to the output \n" "produced by any preceding calls to the \"process()\" or flush()\" methods. \n" "Some or all of the input may be kept in internal buffers for later \n" "processing, and the compressed output data may be empty until enough input \n" "has been accumulated.\n" "\n" "Signature:\n" " compress(string)\n" "\n" "Args:\n" " string (bytes): The input data\n" "\n" "Returns:\n" " The compressed output data (bytes)\n" "\n" "Raises:\n" " brotli.error: If compression fails\n") | |
PyDoc_STRVAR (brotli_Compressor_flush_doc, "Process all pending input, returning a string containing the remaining\n" "compressed data. This data should be concatenated to the output produced by\n" "any preceding calls to the \"process()\" or \"flush()\" methods.\n" "\n" "Signature:\n" " flush()\n" "\n" "Returns:\n" " The compressed output data (bytes)\n" "\n" "Raises:\n" " brotli.error: If compression fails\n") | |
PyDoc_STRVAR (brotli_Compressor_finish_doc, "Process all pending input and complete all compression, returning a string\n" "containing the remaining compressed data. This data should be concatenated\n" "to the output produced by any preceding calls to the \"process()\" or\n" "\"flush()\" methods.\n" "After calling \"finish()\", the \"process()\" and \"flush()\" methods\n" "cannot be called again, and a new \"Compressor\" object should be created.\n" "\n" "Signature:\n" " finish(string)\n" "\n" "Returns:\n" " The compressed output data (bytes)\n" "\n" "Raises:\n" " brotli.error: If compression fails\n") | |
PyDoc_STRVAR (brotli_Decompressor_doc, "An object to decompress a byte string.\n" "\n" "Signature:\n" " Decompressor()\n" "\n" "Raises:\n" " brotli.error: If arguments are invalid.\n") | |
PyDoc_STRVAR (brotli_Decompressor_process_doc, "Process \"string\" for decompression, returning a string that contains \n" "decompressed output data. This data should be concatenated to the output \n" "produced by any preceding calls to the \"process()\" method. \n" "Some or all of the input may be kept in internal buffers for later \n" "processing, and the decompressed output data may be empty until enough input \n" "has been accumulated.\n" "\n" "Signature:\n" " decompress(string)\n" "\n" "Args:\n" " string (bytes): The input data\n" "\n" "Returns:\n" " The decompressed output data (bytes)\n" "\n" "Raises:\n" " brotli.error: If decompression fails\n") | |
PyDoc_STRVAR (brotli_Decompressor_is_finished_doc, "Checks if decoder instance reached the final state.\n" "\n" "Signature:\n" " is_finished()\n" "\n" "Returns:\n" " True if the decoder is in a state where it reached the end of the input\n" " and produced all of the output\n" " False otherwise\n" "\n" "Raises:\n" " brotli.error: If decompression fails\n") | |
PyDoc_STRVAR (brotli_decompress__doc__, "Decompress a compressed byte string.\n" "\n" "Signature:\n" " decompress(string)\n" "\n" "Args:\n" " string (bytes): The compressed input data.\n" "\n" "Returns:\n" " The decompressed byte string.\n" "\n" "Raises:\n" " brotli.error: If decompressor fails.\n") | |
PyDoc_STRVAR (brotli_doc, "Implementation module for the Brotli library.") | |
#define CREATE_BROTLI Py_InitModule3("_brotli", brotli_methods, brotli_doc) |
#define INIT_BROTLI | ( | void | ) |
#define KB (1024) |
#define MB (1024*1024) |
#define Py_ARRAY_LENGTH | ( | array | ) |
#define PY_SSIZE_T_CLEAN 1 |
#define RETURN_BROTLI return |
#define RETURN_NULL return |
PyDoc_STRVAR | ( | brotli_Compressor_doc | , |
"An object to compress a byte string.\n" "\n" "Signature:\n" " | Compressormode=MODE_GENERIC, quality=11, lgwin=22, lgblock=0)\n" "\n" "Args:\n" " mode (int, optional): The compression mode can be MODE_GENERIC (default, | ||
\n" " MODE_TEXT(for UTF-8 format text input) or MODE_FONT(for WOFF 2.0). \n" " quality(int, optional):Controls the compression-speed vs compression-\n" " density tradeoff. The higher the | quality, | ||
the slower the compression.\n" " Range is 0 to 11. Defaults to 11.\n" " lgwin(int, optional):Base 2 logarithm of the sliding window size. Range\n" " is 10 to 24. Defaults to 22.\n" " lgblock(int, optional):Base 2 logarithm of the maximum input block size.\n" " Range is 16 to 24. If set to | 0, | ||
the value will be set based on the\n" " quality. Defaults to 0.\n" "\n" "Raises:\n" " brotli.error:If arguments are invalid.\n" | ) |
PyDoc_STRVAR | ( | brotli_Compressor_finish_doc | , |
"Process all pending input and complete all | compression, | ||
returning a string\n" "containing the remaining compressed data. This data should be concatenated\n" "to the output produced by any preceding calls to the \"process()\" or\n" "\"flush()\" methods.\n" "After calling \"finish()\" | , | ||
the \"process()\" and \"flush()\" methods\n" "cannot be called | again, | ||
and a new \"Compressor\" object should be created.\n" "\n" "Signature:\n" " finish(string)\n" "\n" "Returns:\n" " The compressed output data (bytes)\n" "\n" "Raises:\n" " brotli.error: If compression fails\n" | ) |
PyDoc_STRVAR | ( | brotli_Compressor_flush_doc | , |
"Process all pending | input, | ||
returning a string containing the remaining\n" "compressed data. This data should be concatenated to the output produced by\n" "any preceding calls to the \"process()\" or \"flush()\" methods.\n" "\n" "Signature:\n" " flush()\n" "\n" "Returns:\n" " The compressed output data (bytes)\n" "\n" "Raises:\n" " brotli.error: If compression fails\n" | ) |
PyDoc_STRVAR | ( | brotli_Compressor_process_doc | , |
"Process \"string\" for | compression, | ||
returning a string that contains \n" "compressed output data. This data should be concatenated to the output \n" "produced by any preceding calls to the \"process()\" or flush()\" methods. \n" "Some or all of the input may be kept in internal buffers for later \n" " | processing, | ||
and the compressed output data may be empty until enough input \n" "has been accumulated.\n" "\n" "Signature:\n" " compress(string)\n" "\n" "Args:\n" " string(bytes):The input data\n" "\n" "Returns:\n" " The compressed output data(bytes)\n" "\n" "Raises:\n" " brotli.error:If compression fails\n" | ) |
PyDoc_STRVAR | ( | brotli_decompress__doc__ | , |
"Decompress a compressed byte string.\n" "\n" "Signature:\n" " decompress(string)\n" "\n" "Args:\n" " string (bytes): The compressed input data.\n" "\n" "Returns:\n" " The decompressed byte string.\n" "\n" "Raises:\n" " brotli.error: If decompressor fails.\n" | ) |
PyDoc_STRVAR | ( | brotli_Decompressor_doc | , |
"An object to decompress a byte string.\n" "\n" "Signature:\n" " Decompressor()\n" "\n" "Raises:\n" " brotli.error: If arguments are invalid.\n" | ) |
PyDoc_STRVAR | ( | brotli_Decompressor_is_finished_doc | , |
"Checks if decoder instance reached the final state.\n" "\n" "Signature:\n" " is_finished()\n" "\n" "Returns:\n" " True if the decoder is in a state where it reached the end of the input\n" " and produced all of the output\n" " False otherwise\n" "\n" "Raises:\n" " brotli.error: If decompression fails\n" | ) |
PyDoc_STRVAR | ( | brotli_Decompressor_process_doc | , |
"Process \"string\" for | decompression, | ||
returning a string that contains \n" "decompressed output data. This data should be concatenated to the output \n" "produced by any preceding calls to the \"process()\" method. \n" "Some or all of the input may be kept in internal buffers for later \n" " | processing, | ||
and the decompressed output data may be empty until enough input \n" "has been accumulated.\n" "\n" "Signature:\n" " decompress(string)\n" "\n" "Args:\n" " string(bytes):The input data\n" "\n" "Returns:\n" " The decompressed output data(bytes)\n" "\n" "Raises:\n" " brotli.error:If decompression fails\n" | ) |
PyDoc_STRVAR | ( | brotli_doc | , |
"Implementation module for the Brotli library." | ) |