ZSTD_CCtx_setParameter method

int ZSTD_CCtx_setParameter(
  1. Pointer<ZSTD_CCtx> cctx,
  2. int param,
  3. int value
)

! ZSTD_CCtx_setParameter() : Set one compression parameter, selected by enum ZSTD_cParameter. All parameters have valid bounds. Bounds can be queried using ZSTD_cParam_getBounds(). Providing a value beyond bound will either clamp it, or trigger an error (depending on parameter). Setting a parameter is generally only possible during frame initialization (before starting compression). Exception : when using multi-threading mode (nbWorkers >= 1), the following parameters can be updated during compression (within same frame): => compressionLevel, hashLog, chainLog, searchLog, minMatch, targetLength and strategy. new parameters will be active for next job only (after a flush()). @return : an error code (which can be tested using ZSTD_isError()).

Implementation

int ZSTD_CCtx_setParameter(
    ffi.Pointer<ZSTD_CCtx> cctx,
    int param,
    int value,
    ) {
  return _ZSTD_CCtx_setParameter(
    cctx,
    param,
    value,
  );
}