atagen

macltok

public
Star0
Watch0
9eabb6b7587ddbf872d0ee2dfb752650c3f823f9
3
ssh://brewery@pls.lobotomise.me:33/atagen/macltok.git
src/lib.rsRust89 lines3.9 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
mod mentions;
7
mod mentions_model;
8
#[cfg(feature = "mirror")]
9
mod mirror;
10
mod model;
11
mod normalise;
12
mod repair_model;
13
mod space_order;
14
mod transport;
15
mod uiaa;
16
mod upload;
17
#[cfg(target_family = "wasm")]
18
mod wasm;
19
20
#[cfg(all(feature = "sqlite", target_family = "wasm"))]
21
compile_error!("sqlite has no filesystem to live on in wasm, use indexeddb");
22
#[cfg(all(feature = "indexeddb", not(target_family = "wasm")))]
23
compile_error!("indexeddb only exists in a browser, use sqlite");
24
25
#[cfg(any(feature = "sqlite", feature = "indexeddb"))]
26
mod account;
27
#[cfg(any(feature = "sqlite", feature = "indexeddb"))]
28
mod accounts;
29
#[cfg(any(feature = "sqlite", feature = "indexeddb"))]
30
mod session_store;
31
#[cfg(any(feature = "sqlite", feature = "indexeddb"))]
32
mod store_lock;
33
34
#[cfg(any(feature = "sqlite", feature = "indexeddb"))]
35
pub use account::{
36
    AccountError, OAuthApplicationType, OAuthLogin, PasswordLogin, PendingOAuthLogin, Restore,
37
    Session, SessionRecord, SoftLogout, StoreConfig, UnsavedSession,
38
};
39
#[cfg(any(feature = "sqlite", feature = "indexeddb"))]
40
pub use accounts::{Account, Accounts};
41
#[cfg(any(feature = "sqlite", feature = "indexeddb"))]
42
pub use session_store::{EncryptedSessionStore, SessionStore};
43
44
pub use engine::{Engine, EngineConfig, EngineError};
45
pub use error::{Error, ErrorKind, ServerError};
46
pub use imbl;
47
pub use mentions_model::{
48
    MentionCaptureState, MentionCoverage, MentionEntry, MentionGap, MentionKey, MentionReason,
49
    MentionsBoundary, MentionsCommand, MentionsPage, MentionsUpdate, SavedMentionContext,
50
};
51
#[cfg(feature = "mirror")]
52
pub use mirror::{
53
    Mirror, MirrorHandle, SessionStatus, State, StateChange, Subscription, TimelineChange,
54
    TimelineState, Update, UploadFailure, UploadState,
55
};
56
pub use model::{
57
    AccountCommand, AttachmentEncryption, AttachmentUpload, Change, Command, CommandOutput,
58
    ConnectionState, CreateRoomOptions, EncryptionCommand, EncryptionState, EngineErrorKind,
59
    EngineFailure, Event, EventContext, EventContextCommand, EventContextDirection,
60
    EventContextPage, EventRef, HistoryState, ImagePack, ImagePackSource, ImagePacks,
61
    KeyBackupState, LatestEvent, LifecycleCommand, LinkPreview, LinkPreviewImage, Media,
62
    MediaCommand, MediaDescriptor, MediaFile, MediaId, MediaKind, MediaLocation, MediaSize,
63
    MemberFilter, MemberMembership, MemberSummary, MembershipChange, Message, MessageContent,
64
    MessageEditContent, MessageKind, MessageMentions, NotificationCommand, OwnDevice, PackCommand,
65
    PackImage, PackImageInfo, PackUsage, Patch, PowerLevelChanges, Profile, PushNotification,
66
    PushNotificationEvent, PushNotificationRoom, PushNotificationSender, PushNotificationStatus,
67
    Reaction, RecentHistoryState, RecoveryState, ReplyDetails, ReplyReference, Retain, RichText,
68
    RoomCategory, RoomCommand, RoomHero, RoomListFilter, RoomMatcher, RoomMembership,
69
    RoomNotificationMode, RoomNotificationSettings, RoomPowerLevels, RoomPreset, RoomSummary,
70
    RoomVisibility, SendState, Sender, SpaceChild, Termination, ThreadSummary, TimelineCommand,
71
    TimelineContent, TimelineDiff, TimelineDiffError, TimelineEvent, TimelineId, TimelineItem,
72
    TimelineItemId, TypingState, UploadDetails, UploadOutcome, UploadThumbnail, UtdCause,
73
    VerificationAction, VerificationFailure, VerificationState, VerificationTarget,
74
};
75
pub use repair_model::{
76
    HistoryContinuity, HistoryGap, HistoryGapLifecycle, HistoryRepairBudget, HistoryRepairCommand,
77
    HistoryRepairPhase, HistoryRepairPolicy, HistoryRepairReport, HistoryRepairStop,
78
    HistoryRepairStrategy,
79
};
80
pub use ruma;
81
#[doc(hidden)]
82
pub use transport::PublicationAck;
83
pub use transport::{ClientHandle, EventStream, Pending, SpaceHierarchy};
84
pub use uiaa::{
85
    InteractiveAuth, InteractiveAuthChallenge, InteractiveAuthFailure, InteractiveAuthFlow,
86
    InteractiveAuthOutcome,
87
};
88
#[cfg(target_family = "wasm")]
89
pub use wasm::on_panic;