InMemoryServerDocumentCatalog class

A ServerDocumentCatalog that keeps the ids in memory.

Pass it to PersistentServerRegistry for a server that should start empty on every launch. Documents written with it are still on disk after a restart, but the server no longer knows they exist, so it fills up again as clients name their documents.

Implemented types

Constructors

InMemoryServerDocumentCatalog({Set<String>? documentIds})
Creates a catalog holding documentIds, empty by default.

Properties

documentIds Future<Set<String>>
Every document id this server knows about.
no setteroverride
hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

add(String documentId) Future<void>
Remembers documentId.
override
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
remove(String documentId) Future<void>
Forgets documentId.
override
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited