Crate spacetimedb_lib

Crate spacetimedb_lib 

Source

Re-exports§

pub use connection_id::ConnectionId;
pub use identity::Identity;
pub use scheduler::ScheduleAt;
pub use spacetimedb_sats as sats;

Modules§

bsatn
buffer
Minimal utility for reading & writing the types we need to internal storage, without relying on types in third party libraries like bytes::Bytes, etc. Meant to be kept slim and trim for use across both native and WASM.
connection_id
db
Defines all the typed database objects & schemas.
de
error
hash
identity
metrics
operator
Operator support for the query macro.
query
scheduler
ser
st_var
type_def
type_value
version

Structs§

Hash
ModuleDefBuilder
A builder for a RawModuleDefV8. Deprecated.
ProductType
A structural product type of the factors given by elements.
ProductTypeElement
A factor / element of a product type.
ProductValue
A product value is made of a list of “elements” / “fields” / “factors” of other AlgebraicValues.
RawModuleDefV8
ReducerDef
SumType
A structural sum type.
TableDesc
TimeDuration
A span or delta in time, measured in microseconds.
Timestamp
A point in time, measured in microseconds since the Unix epoch.
TypeAlias
VersionTuple

Enums§

AlgebraicType
The SpacetimeDB Algebraic Type System (SATS) is a structural type system in which a nominal type system can be constructed.
AlgebraicValue
A value in SATS typed at some AlgebraicType.
MiscModuleExport
RawModuleDef
A versioned raw module definition.
TermBound

Constants§

MODULE_ABI_MAJOR_VERSION

Traits§

DirectIndexKey
FilterableValue
Types which can appear as an argument to an index filtering operation for a column of type Column.
IndexScanRangeBoundsTerminator
SpacetimeType
This trait makes types self-describing, allowing them to automatically register their structure with SpacetimeDB. This is used to tell SpacetimeDB about the structure of a module’s tables and reducers.

Functions§

assert_column_type_valid_for_direct_index
Assert that T is a valid column to use direct index on.
from_hex_pad
Converts a hexadecimal string reference to a byte array.
hash_bytes
resolved_type_via_v9
Returns a resolved AlgebraicType (containing no AlgebraicTypeRefs) for a given SpacetimeType, using the v9 moduledef infrastructure. Panics if the type is recursive.

Derive Macros§

SpacetimeType