atagen

macltok

public
Star0
Watch0
7515819c2f3ed19dc742baec9701ccaa6bba83c5
3
ssh://brewery@pls.lobotomise.me:33/atagen/macltok.git
src/lib.rsRust73 lines3.2 KB
1
//! A compact application backend contract on top of the Matrix Rust SDK.
2
3
mod encryption;
4
mod engine;
5
mod error;
6
#[cfg(feature = "mirror")]
7
mod mirror;
8
mod model;
9
mod normalise;
10
mod transport;
11
mod uiaa;
12
mod upload;
13
#[cfg(target_family = "wasm")]
14
mod wasm;
15
16
#[cfg(all(feature = "sqlite", target_family = "wasm"))]
17
compile_error!("sqlite has no filesystem to live on in wasm, use indexeddb");
18
#[cfg(all(feature = "indexeddb", not(target_family = "wasm")))]
19
compile_error!("indexeddb only exists in a browser, use sqlite");
20
21
#[cfg(any(feature = "sqlite", feature = "indexeddb"))]
22
mod account;
23
#[cfg(any(feature = "sqlite", feature = "indexeddb"))]
24
mod accounts;
25
#[cfg(any(feature = "sqlite", feature = "indexeddb"))]
26
mod session_store;
27
#[cfg(any(feature = "sqlite", feature = "indexeddb"))]
28
mod store_lock;
29
30
#[cfg(any(feature = "sqlite", feature = "indexeddb"))]
31
pub use account::{
32
    AccountError, OAuthApplicationType, OAuthLogin, PasswordLogin, PendingOAuthLogin, Restore,
33
    Session, SessionRecord, SoftLogout, StoreConfig, UnsavedSession,
34
};
35
#[cfg(any(feature = "sqlite", feature = "indexeddb"))]
36
pub use accounts::{Account, Accounts};
37
#[cfg(any(feature = "sqlite", feature = "indexeddb"))]
38
pub use session_store::{EncryptedSessionStore, SessionStore};
39
40
pub use engine::{Engine, EngineConfig, EngineError};
41
pub use error::{Error, ErrorKind, ServerError};
42
pub use imbl;
43
#[cfg(feature = "mirror")]
44
pub use mirror::{
45
    Mirror, MirrorHandle, SessionStatus, State, StateChange, Subscription, TimelineChange,
46
    TimelineState, Update, UploadFailure, UploadState,
47
};
48
pub use model::{
49
    AccountCommand, AttachmentEncryption, AttachmentUpload, Change, Command, CommandOutput,
50
    ConnectionState, CreateRoomOptions, EncryptionCommand, EncryptionState, EngineErrorKind,
51
    EngineFailure, Event, EventRef, HistoryState, ImagePack, ImagePackSource, ImagePacks,
52
    KeyBackupState, LatestEvent, LifecycleCommand, LinkPreview, LinkPreviewImage, Media,
53
    MediaCommand, MediaDescriptor, MediaFile, MediaId, MediaKind, MediaLocation, MediaSize,
54
    MemberFilter, MemberMembership, MemberSummary, MembershipChange, Message, MessageContent,
55
    MessageEditContent, MessageKind, MessageMentions, NotificationCommand, OwnDevice, PackImage,
56
    PackUsage, PowerLevelChanges, Profile, PushNotification, PushNotificationEvent,
57
    PushNotificationRoom, PushNotificationSender, PushNotificationStatus, Reaction, RecoveryState,
58
    ReplyDetails, ReplyReference, Retain, RichText, RoomCategory, RoomCommand, RoomHero,
59
    RoomListFilter, RoomMatcher, RoomMembership, RoomNotificationMode, RoomNotificationSettings,
60
    RoomPowerLevels, RoomPreset, RoomSummary, RoomVisibility, SendState, Sender, SpaceChild,
61
    Termination, ThreadSummary, TimelineCommand, TimelineContent, TimelineDiff, TimelineDiffError,
62
    TimelineEvent, TimelineId, TimelineItem, TimelineItemId, TypingState, UploadDetails,
63
    UploadOutcome, UploadThumbnail, UtdCause, VerificationAction, VerificationFailure,
64
    VerificationState, VerificationTarget,
65
};
66
pub use ruma;
67
pub use transport::{ClientHandle, EventStream, Pending, SpaceHierarchy};
68
pub use uiaa::{
69
    InteractiveAuth, InteractiveAuthChallenge, InteractiveAuthFailure, InteractiveAuthFlow,
70
    InteractiveAuthOutcome,
71
};
72
#[cfg(target_family = "wasm")]
73
pub use wasm::on_panic;