Skip to content

Commit

Permalink
refactor: more documents on interfaces
Browse files Browse the repository at this point in the history
  • Loading branch information
wdhongtw committed Jan 16, 2025
1 parent 493f045 commit 0dc00bb
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions src/manager.ts
Original file line number Diff line number Diff line change
Expand Up @@ -303,9 +303,16 @@ export default class KeyStatusManager {
}
}

/** The abstract storage for our application, focusing on string type. */
export interface Storage {

/** Get the value for the key. */
get(key: string): Promise<string | undefined>

/** Update or insert value for the key. */
set(key: string, value: string): Promise<void>

/** Delete a value for some key, if any. */
delete(key: string): Promise<void>
}

Expand Down

0 comments on commit 0dc00bb

Please sign in to comment.