operations
@nishans/core / Exports / Operations
Class: Operations#
Hierarchy#
Cache
↳ Operations
Index#
Constructors#
Properties#
Methods#
- emptyStack
- executeOperation
- initializeCache
- initializeCacheForSpecificData
- printStack
- returnNonCachedData
- saveToCache
- updateCacheIfNotPresent
- updateCacheManually
Constructors#
constructor#
+ new Operations(args: NishanArg): Operations
Parameters:#
| Name | Type |
|---|---|
args | NishanArg |
Returns: Operations
Defined in: core/src/Operations.ts:9
Properties#
cache#
• cache: ICache
Defined in: endpoints/dist/src/Cache.d.ts:4
getConfigs#
• Protected getConfigs: () => Configs
Defined in: endpoints/dist/src/Cache.d.ts:15
headers#
• headers: { headers: { cookie: string ; x-notion-active-user-header: string } }
Type declaration:#
| Name | Type |
|---|---|
headers | { cookie: string ; x-notion-active-user-header: string } |
Defined in: endpoints/dist/src/Cache.d.ts:7
interval#
• interval: number
Defined in: endpoints/dist/src/Cache.d.ts:6
shard_id#
• shard_id: number
Defined in: core/src/Operations.ts:9
space_id#
• space_id: string
Defined in: core/src/Operations.ts:8
stack#
• stack: IOperation[]
Defined in: core/src/Operations.ts:7
token#
• token: string
Defined in: endpoints/dist/src/Cache.d.ts:5
user_id#
• user_id: string
Defined in: endpoints/dist/src/Cache.d.ts:13
Methods#
emptyStack#
â–¸ emptyStack(): void
Returns: void
Defined in: core/src/Operations.ts:18
executeOperation#
â–¸ executeOperation(): Promise<void>
Returns: Promise<void>
Defined in: core/src/Operations.ts:26
initializeCache#
â–¸ initializeCache(): Promise<void>
Returns: Promise<void>
Defined in: endpoints/dist/src/Cache.d.ts:22
initializeCacheForSpecificData#
â–¸ initializeCacheForSpecificData(id: string, type: block | collection | collection_view | space | notion_user | space_view | user_root | user_settings): Promise<void>
Parameters:#
| Name | Type |
|---|---|
id | string |
type | block | collection | collection_view | space | notion_user | space_view | user_root | user_settings |
Returns: Promise<void>
Defined in: endpoints/dist/src/Cache.d.ts:25
printStack#
â–¸ printStack(): void
Returns: void
Defined in: core/src/Operations.ts:22
returnNonCachedData#
â–¸ returnNonCachedData(ids: UpdateCacheManuallyParam): UpdateCacheManuallyParam
Parameters:#
| Name | Type |
|---|---|
ids | UpdateCacheManuallyParam |
Returns: UpdateCacheManuallyParam
Defined in: endpoints/dist/src/Cache.d.ts:21
saveToCache#
â–¸ saveToCache(recordMap: Partial<RecordMap>): void
Save the passed recordMap to cache
Parameters:#
| Name | Type | Description |
|---|---|---|
recordMap | Partial<RecordMap> | RecordMap map to save to cache |
Returns: void
Defined in: endpoints/dist/src/Cache.d.ts:20
updateCacheIfNotPresent#
â–¸ updateCacheIfNotPresent(arg: UpdateCacheManuallyParam): Promise<void>
Parameters:#
| Name | Type |
|---|---|
arg | UpdateCacheManuallyParam |
Returns: Promise<void>
Defined in: endpoints/dist/src/Cache.d.ts:24
updateCacheManually#
â–¸ updateCacheManually(arg: string | UpdateCacheManuallyParam): Promise<void>
Parameters:#
| Name | Type |
|---|---|
arg | string | UpdateCacheManuallyParam |
Returns: Promise<void>
Defined in: endpoints/dist/src/Cache.d.ts:23