MCPcopy Create free account
hub / github.com/astercloud/aster / NewCompressionCache

Function NewCompressionCache

pkg/compression/service.go:600–605  ·  view source on GitHub ↗

NewCompressionCache 创建压缩缓存

(maxSize int)

Source from the content-addressed store, hash-verified

598
599// NewCompressionCache 创建压缩缓存
600func NewCompressionCache(maxSize int) *CompressionCache {
601 return &CompressionCache{
602 cache: make(map[string]*CompressResult),
603 maxSize: maxSize,
604 }
605}
606
607// Get 获取缓存
608func (c *CompressionCache) Get(key string) *CompressResult {

Callers 2

TestCompressionCacheFunction · 0.85

Calls

no outgoing calls

Tested by 1

TestCompressionCacheFunction · 0.68