BrotliDecoderAttachDictionary

Function BrotliDecoderAttachDictionary 

Source
pub unsafe extern "C" fn BrotliDecoderAttachDictionary(
    state: *mut BrotliDecoderState,
    type_: BrotliSharedDictionaryType,
    data_size: usize,
    data: *const u8,
) -> BROTLI_BOOL
Expand description

Adds LZ77 prefix dictionary, adds or replaces built-in static dictionary and transforms.

Attached dictionary ownership is not transferred. Data provided to this method should be kept accessible until decoding is finished and decoder instance is destroyed.

@note Dictionaries can NOT be attached after actual decoding is started.

@param state decoder instance @param type dictionary data format @param data_size length of memory region pointed by @p data @param data dictionary data in format corresponding to @p type @returns ::BROTLI_FALSE if dictionary is corrupted, or dictionary count limit is reached @returns ::BROTLI_TRUE if dictionary is accepted / attached