-
-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #29 from medishen/dev/v2
The packages are synced according to the new version of @medishn/qiks.
- Loading branch information
Showing
5 changed files
with
41 additions
and
33 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,6 @@ | ||
import { Qiks } from '@medishn/qiks'; | ||
import { CacheConfigQiks } from '@medishn/qiks/dist/types/CacheTypes'; | ||
|
||
/** | ||
* A caching system built on top of @medishn/qiks. | ||
*/ | ||
export class MemoryCacheStore<K, V> extends Qiks<K, V> { | ||
constructor(options?: CacheConfigQiks<K>) { | ||
super(options); | ||
import { CacheConfig, Qiks } from '@medishn/qiks'; | ||
export class InMemoryCacheStore<K, V> extends Qiks<K, V> { | ||
constructor(option: CacheConfig<K, V>) { | ||
super(option); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -8,5 +8,8 @@ | |
}, | ||
"devDependencies": { | ||
"typescript": "^5.5.4" | ||
}, | ||
"dependencies": { | ||
"@medishn/qiks": "2.0.0" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,18 @@ | ||
import { MetadataKey, MetadataTarget, MetadataValue } from '../types/metadata.types'; | ||
|
||
export interface MetadataStorage { | ||
get<K extends MetadataKey, V>(target: MetadataTarget): Map<MetadataKey<K>, MetadataValue<V>>; | ||
set<K extends MetadataKey, V>(target: MetadataTarget, key: MetadataKey<K>, value: MetadataValue<V>): void; | ||
has(target: MetadataTarget, key: MetadataKey): boolean; | ||
delete(target: MetadataTarget, key: MetadataKey): boolean; | ||
// Define the MetadataStorage interface | ||
export interface MetadataStorage<K extends MetadataKey, V extends MetadataValue> { | ||
get(target: MetadataTarget): Map<K, V>; | ||
|
||
set(target: MetadataTarget, key: K, value: V): void; | ||
|
||
has(target: MetadataTarget, key: K): boolean; | ||
|
||
delete(target: MetadataTarget, key: K): boolean; | ||
|
||
clear(target: MetadataTarget): void; | ||
|
||
keys(): string[]; | ||
list<K extends MetadataKey, V>(target: MetadataTarget): Map<MetadataKey<K>, MetadataValue<V>> | null; | ||
|
||
list(target: MetadataTarget): Map<K, V> | null; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters