Properties
index
index: Map<string, M>
Methods
add
- add(item: M): void
-
Returns void
addArr
- addArr(items: M[]): void
-
Returns void
addRange
- addRange(...items: M[]): void
-
Returns void
clear
- clear(): void
-
Returns void
create
- create(...args: any[]): M
-
Returns M
filter
- filter(pipe: ((m: M) => boolean)): M[]
-
Parameters
-
pipe: ((m: M) => boolean)
-
- (m: M): boolean
-
Returns boolean
Returns M[]
find
- find(key: string): M
-
Returns M
has
- has(key: string | M): boolean
-
Returns boolean
map
- map<R>(project: ((item: M) => R)): R[]
-
Parameters
-
project: ((item: M) => R)
Returns R[]
query
- query(predicate: ((item: M) => boolean)): M[]
-
Parameters
-
predicate: ((item: M) => boolean)
-
- (item: M): boolean
-
Returns boolean
Returns M[]
remove
- remove(item?: M): void
-
Returns void
removeArr
- removeArr(items: M[]): void
-
Returns void
removeById
- removeById(id: string): void
-
Returns void
removeRange
- removeRange(...items: M[]): void
-
Returns void
update
- update(item: M): void
-
Returns void
updateRange
- updateRange(...items: M[]): void
-
Returns void
将一个对象加入到数据集,标记为 Added,将在下次提交时远程添加