Methods
GetCache
- GetCache<T>(name: string): undefined | T
GetValue
- GetValue<T>(name: string, defaultValueIfNotExist?: T): undefined | T
-
Parameters
-
name: string
-
Optional
defaultValueIfNotExist: T
Returns undefined | T
RemoveCache
- RemoveCache(...names: string[]): void
RemoveValue
- RemoveValue(name: string): void
SetCacheWithDate
- SetCacheWithDate(name: string, value: unknown, absoluteExpiration: Date): void
-
Parameters
-
name: string
-
value: unknown
-
absoluteExpiration: Date
Returns void
SetCacheWithHour
- SetCacheWithHour(name: string, value: unknown, hour: number): void
-
Parameters
-
name: string
-
value: unknown
-
hour: number
Returns void
SetCacheWithMilliseconds
- SetCacheWithMilliseconds(name: string, value: unknown, millisecond: number): void
-
Parameters
-
name: string
-
value: unknown
-
millisecond: number
Returns void
SetCacheWithMinute
- SetCacheWithMinute(name: string, value: unknown, minute: number): void
-
Parameters
-
name: string
-
value: unknown
-
minute: number
Returns void
SetValue
- SetValue(name: string, value: any): void
Since
4.0.0
Version
2021-12-14