Documentation
¶
Index ¶
- type Cache
- func (c Cache) Count() int
- func (c Cache) Delete(key string)
- func (c Cache) Get(requestBody []byte, requestParams string) (CacheEntry, bool, string)
- func (c Cache) GetByKey(key string) (CacheEntry, bool)
- func (c Cache) HandlerPattern() string
- func (c Cache) Keys() []string
- func (c Cache) MaxAge() time.Duration
- func (c Cache) Set(requestBody []byte, requestParams string, requestHeader http.Header, ...)
- func (c Cache) Size() uint64
- type CacheEntry
- func (e *CacheEntry) Clone() CacheEntry
- func (e CacheEntry) EstimatedSize() uint64
- func (e *CacheEntry) ResponseBodyBrotli() []byte
- func (e *CacheEntry) ResponseBodyDeflate() []byte
- func (e *CacheEntry) ResponseBodyGzip() []byte
- func (e *CacheEntry) ResponseBodyPlain() []byte
- func (e *CacheEntry) ResponseHeader() http.Header
- func (e *CacheEntry) ResponseModel() interface{}
- func (e *CacheEntry) ResponseStatusCode() int
- func (e CacheEntry) Stats(c *Cache) (CacheEntryStats, error)
- func (e *CacheEntry) String() string
- func (e *CacheEntry) UpdatedOn() time.Time
- type CacheEntryStats
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Cache ¶
type Cache struct {
// contains filtered or unexported fields
}
func (Cache) HandlerPattern ¶ added in v1.1.7
type CacheEntry ¶ added in v1.0.85
type CacheEntry struct {
// contains filtered or unexported fields
}
func (*CacheEntry) Clone ¶ added in v1.0.85
func (e *CacheEntry) Clone() CacheEntry
func (CacheEntry) EstimatedSize ¶ added in v1.1.7
func (e CacheEntry) EstimatedSize() uint64
func (*CacheEntry) ResponseBodyBrotli ¶ added in v1.0.85
func (e *CacheEntry) ResponseBodyBrotli() []byte
func (*CacheEntry) ResponseBodyDeflate ¶ added in v1.0.85
func (e *CacheEntry) ResponseBodyDeflate() []byte
func (*CacheEntry) ResponseBodyGzip ¶ added in v1.0.85
func (e *CacheEntry) ResponseBodyGzip() []byte
func (*CacheEntry) ResponseBodyPlain ¶ added in v1.0.87
func (e *CacheEntry) ResponseBodyPlain() []byte
func (*CacheEntry) ResponseHeader ¶ added in v1.0.85
func (e *CacheEntry) ResponseHeader() http.Header
func (*CacheEntry) ResponseModel ¶ added in v1.0.85
func (e *CacheEntry) ResponseModel() interface{}
func (*CacheEntry) ResponseStatusCode ¶ added in v1.0.85
func (e *CacheEntry) ResponseStatusCode() int
func (CacheEntry) Stats ¶ added in v1.1.7
func (e CacheEntry) Stats(c *Cache) (CacheEntryStats, error)
func (*CacheEntry) String ¶ added in v1.0.85
func (e *CacheEntry) String() string
func (*CacheEntry) UpdatedOn ¶ added in v1.0.85
func (e *CacheEntry) UpdatedOn() time.Time
type CacheEntryStats ¶ added in v1.1.7
type CacheEntryStats struct { UpdatedOn string `json:"updatedOn"` TTL string `json:"TTL"` EstimatedSize string `json:"estimatedSize"` EstimatedSizeBytes uint64 `json:"estimatedSizeBytes"` StatusCode int `json:"statusCode"` CachedModel bool `json:"cachedModel"` CachedBodyPlain bool `json:"cachedBodyPlain"` CachedBodyBrotli bool `json:"cachedBodyBrotli"` CachedBodyGzip bool `json:"cachedBodyGzip"` CachedBodyDeflate bool `json:"cachedBodyDeflate"` RequestParams url.Values `json:"requestParams"` RequestBody string `json:"requestBody"` }
Click to show internal directories.
Click to hide internal directories.