github.com/andybalholm/brotli@v1.0.6/encoder_dict.go (about) 1 package brotli 2 3 /* Dictionary data (words and transforms) for 1 possible context */ 4 type encoderDictionary struct { 5 words *dictionary 6 cutoffTransformsCount uint32 7 cutoffTransforms uint64 8 hash_table []uint16 9 buckets []uint16 10 dict_words []dictWord 11 } 12 13 func initEncoderDictionary(dict *encoderDictionary) { 14 dict.words = getDictionary() 15 16 dict.hash_table = kStaticDictionaryHash[:] 17 dict.buckets = kStaticDictionaryBuckets[:] 18 dict.dict_words = kStaticDictionaryWords[:] 19 20 dict.cutoffTransformsCount = kCutoffTransformsCount 21 dict.cutoffTransforms = kCutoffTransforms 22 }