Changeset View
Changeset View
Standalone View
Standalone View
src/base/kazvevents.hpp
| Show First 20 Lines • Show All 318 Lines • ▼ Show 20 Lines | namespace Kazv | ||||
| }; | }; | ||||
| struct ClaimKeysFailed | struct ClaimKeysFailed | ||||
| { | { | ||||
| std::string errorCode; | std::string errorCode; | ||||
| std::string error; | std::string error; | ||||
| }; | }; | ||||
| /** | |||||
| * Indicate that there are events to be saved. | |||||
| */ | |||||
| struct SaveEventsRequested | |||||
| { | |||||
| /** | |||||
| * The events to be saved in the timeline. | |||||
| * The events saved in the timeline part of the storage can be considered continuous, i.e. they can be | |||||
| * loaded to fully re-construct the timeline. There can be gaps, | |||||
| * but all gaps are properly recorded in the client state so that | |||||
| * it can be easily paginated. | |||||
| */ | |||||
| immer::map<std::string /* roomId */, EventList> timelineEvents; | |||||
| /** | |||||
| * The events that should be saved, but not in the timeline. | |||||
| */ | |||||
| immer::map<std::string /* roomId */, EventList> nonTimelineEvents; | |||||
| }; | |||||
| struct UnrecognizedResponse | struct UnrecognizedResponse | ||||
| { | { | ||||
| Response response; | Response response; | ||||
| }; | }; | ||||
| struct ShouldQueryKeys | struct ShouldQueryKeys | ||||
| { | { | ||||
| ▲ Show 20 Lines • Show All 42 Lines • ▼ Show 20 Lines | using KazvEvent = std::variant< | ||||
| // content | // content | ||||
| UploadContentSuccessful, UploadContentFailed, | UploadContentSuccessful, UploadContentFailed, | ||||
| DownloadContentSuccessful, DownloadContentFailed, | DownloadContentSuccessful, DownloadContentFailed, | ||||
| DownloadThumbnailSuccessful, DownloadThumbnailFailed, | DownloadThumbnailSuccessful, DownloadThumbnailFailed, | ||||
| // encryption | // encryption | ||||
| UploadIdentityKeysSuccessful, UploadIdentityKeysFailed, | UploadIdentityKeysSuccessful, UploadIdentityKeysFailed, | ||||
| UploadOneTimeKeysSuccessful, UploadOneTimeKeysFailed, | UploadOneTimeKeysSuccessful, UploadOneTimeKeysFailed, | ||||
| ClaimKeysSuccessful, ClaimKeysFailed, | ClaimKeysSuccessful, ClaimKeysFailed, | ||||
| // storage | |||||
| SaveEventsRequested, | |||||
| // general | // general | ||||
| UnrecognizedResponse, | UnrecognizedResponse, | ||||
| ShouldQueryKeys | ShouldQueryKeys | ||||
| >; | >; | ||||
| using KazvEventList = immer::flex_vector<KazvEvent>; | using KazvEventList = immer::flex_vector<KazvEvent>; | ||||
| } | } | ||||