Skip to main content

Crate tuwunel_core

Crate tuwunel_core 

Source

Re-exports§

pub use config::Config;
pub use error::Error;
pub use info::version;
pub use info::version::version;
pub use matrix::Event;
pub use matrix::EventTypeExt;
pub use matrix::Pdu;
pub use matrix::PduCount;
pub use matrix::PduEvent;
pub use matrix::PduId;
pub use matrix::pdu;
pub use server::Server;
pub use utils::result;
pub use utils::result::Result;
pub use crate as tuwunel_core;
pub use ::arrayvec;
pub use ::either;
pub use ::http;
pub use ::itertools;
pub use ::jsonwebtoken as jwt;
pub use ::ruma;
pub use ::smallstr;
pub use ::smallvec;
pub use ::tokio_metrics;
pub use ::toml;
pub use ::tracing;

Modules§

alloc
Integration with allocators
config
debug
error
info
Information about the project. This module contains version, build, system, etc information which can be queried by admins or used by developers.
log
matrix
Core Matrix Library
metrics
mods
server
utils

Macros§

Err
apply
at
Functor for |x| x.$i
checked
Checked arithmetic expression. Returns a Result<R, Error::Arithmetic>
debug
debug_error
Log message at the ERROR level in debug-mode (when debug-assertions are enabled). In release-mode it becomes DEBUG level, and possibly subject to elision.
debug_event
Log event at given level in debug-mode (when debug-assertions are enabled). In release-mode it becomes DEBUG level, and possibly subject to elision.
debug_info
Log message at the INFO level in debug-mode (when debug-assertions are enabled). In release-mode it becomes DEBUG level, and possibly subject to elision.
debug_warn
Log message at the WARN level in debug-mode (when debug-assertions are enabled). In release-mode it becomes DEBUG level, and possibly subject to elision.
defer
deref_at
Functor for |x| *x.$i
err
err_lev
err_log
A trinity of integration between tracing, logging, and Error. This is a customization of tracing::event! with the primary purpose of sharing the error string, fieldset parsing and formatting. An added benefit is that we can share the same callsite metadata for the source of our Error and the associated logging and tracing event dispatches.
error
event
expected
Checked arithmetic expression which panics on failure. This is for expressions which do not meet the threshold for validated! but the caller has no realistic expectation for error and no interest in cluttering the callsite with result handling from checked!.
extract
extract_variant
format_maybe
Constant expression to bypass format! if the argument is a string literal but not a format string. If the literal is a format string then String is returned otherwise the input (i.e. &’static str) is returned. If multiple arguments are provided the first is assumed to be a format string.
info
is_equal
Functor for equality i.e. (a, b).map(is_equal!())
is_equal_to
Functor for equality i.e. .is_some_and(is_equal_to!(2))
is_false
Functor for falsy
is_format
Constant expression to decide if a literal is a format string. Note: could use some improvement.
is_less_than
Functor for less i.e. .is_some_and(is_less_than!(2))
is_matching
Functor for matches! i.e. .is_some_and(is_matching!(‘A’..=‘Z’))
is_nonzero
Functor for equality to non-zero
is_not_empty
Functor for !is_empty()
is_not_equal_to
Functor for inequality i.e. .is_some_and(is_not_equal_to!(2))
is_true
Functor for truthy
is_zero
Functor for equality to zero
maybe_unhandled
mod_ctor
mod_dtor
pair_of
redacted_debug
ref_at
Functor for |ref x| x.$i
rustc_flags_capture
scope_restore
trace
unhandled
val_at
Functor for |&x| x.$i
validated
Checked arithmetic expression in debug-mode. Use for performance when the expression is obviously safe. The check is elided in release-mode.
warn

Enums§

RoomVersion
A Matrix room version ID.

Statics§

RUSTC_FLAGS

Functions§

_set_rustc_flags 🔒
_unset_rustc_flags 🔒

Attribute Macros§

ctor
dtor
implement