bandcamp-fetch/docs/api/classes/CacheWrapper.md

93 lines
1.5 KiB
Markdown
Raw Normal View History

[bandcamp-fetch](../README.md) / CacheWrapper
# Class: CacheWrapper
## Table of contents
### Constructors
- [constructor](CacheWrapper.md#constructor)
### Methods
- [clear](CacheWrapper.md#clear)
- [setMaxPages](CacheWrapper.md#setmaxpages)
- [setTTL](CacheWrapper.md#setttl)
## Constructors
### constructor
**new CacheWrapper**(`cache`)
#### Parameters
| Name | Type |
| :------ | :------ |
| `cache` | [`Cache`](Cache.md) |
#### Defined in
2023-10-28 20:34:52 +02:00
[lib/BandcampFetch.ts:127](https://github.com/patrickkfkan/bandcamp-fetch/blob/7815c68/src/lib/BandcampFetch.ts#L127)
## Methods
### clear
**clear**(`type?`): `void`
#### Parameters
| Name | Type |
| :------ | :------ |
| `type?` | [`CacheDataType`](../enums/CacheDataType.md) |
#### Returns
`void`
#### Defined in
2023-10-28 20:34:52 +02:00
[lib/BandcampFetch.ts:131](https://github.com/patrickkfkan/bandcamp-fetch/blob/7815c68/src/lib/BandcampFetch.ts#L131)
___
### setMaxPages
**setMaxPages**(`maxPages`): `void`
#### Parameters
| Name | Type |
| :------ | :------ |
| `maxPages` | `number` |
#### Returns
`void`
#### Defined in
2023-10-28 20:34:52 +02:00
[lib/BandcampFetch.ts:139](https://github.com/patrickkfkan/bandcamp-fetch/blob/7815c68/src/lib/BandcampFetch.ts#L139)
___
### setTTL
**setTTL**(`type`, `ttl`): `void`
#### Parameters
| Name | Type |
| :------ | :------ |
| `type` | [`CacheDataType`](../enums/CacheDataType.md) |
| `ttl` | `number` |
#### Returns
`void`
#### Defined in
2023-10-28 20:34:52 +02:00
[lib/BandcampFetch.ts:135](https://github.com/patrickkfkan/bandcamp-fetch/blob/7815c68/src/lib/BandcampFetch.ts#L135)