1#ifndef _PRIVMXLIB_ENDPOINT_INBOX_INBOXAPI_HPP_
2#define _PRIVMXLIB_ENDPOINT_INBOX_INBOXAPI_HPP_
9#include "privmx/endpoint/core/Connection.hpp"
10#include "privmx/endpoint/core/Types.hpp"
12#include "privmx/endpoint/inbox/Types.hpp"
13#include "privmx/endpoint/store/StoreApi.hpp"
14#include "privmx/endpoint/thread/ThreadApi.hpp"
15#include <privmx/endpoint/core/ExtendedPointer.hpp>
62 const std::string& contextId,
63 const std::vector<core::UserWithPubKey>& users,
64 const std::vector<core::UserWithPubKey>& managers,
67 const std::optional<inbox::FilesConfig>& filesConfig,
68 const std::optional<core::ContainerPolicyWithoutItem>& policies = std::nullopt
87 const std::string& inboxId,
88 const std::vector<core::UserWithPubKey>& users,
89 const std::vector<core::UserWithPubKey>& managers,
92 const std::optional<inbox::FilesConfig>& filesConfig,
93 const int64_t version,
95 const bool forceGenerateNewKey,
96 const std::optional<core::ContainerPolicyWithoutItem>& policies = std::nullopt
143 const std::string& inboxId,
145 const std::vector<int64_t>& inboxFileHandles = std::vector<int64_t>(),
146 const std::optional<std::string>& userPrivKey = std::nullopt
193 const int64_t& fileSize
231 void seekInFile(
const int64_t fileHandle,
const int64_t position);
247 std::vector<std::string>
subscribeFor(
const std::vector<std::string>& subscriptionQueries);
263 EventSelectorType selectorType,
264 const std::string& selectorId
268 InboxApi(
const std::shared_ptr<InboxApiImpl>& impl);
Definition Connection.hpp:21
Definition ExtendedPointer.hpp:16
int64_t prepareEntry(const std::string &inboxId, const core::Buffer &data, const std::vector< int64_t > &inboxFileHandles=std::vector< int64_t >(), const std::optional< std::string > &userPrivKey=std::nullopt)
std::string buildSubscriptionQuery(EventType eventType, EventSelectorType selectorType, const std::string &selectorId)
void unsubscribeFrom(const std::vector< std::string > &subscriptionIds)
static InboxApi create(core::Connection &connection, thread::ThreadApi &threadApi, store::StoreApi &storeApi)
core::Buffer readFromFile(const int64_t fileHandle, const int64_t length)
inbox::InboxEntry readEntry(const std::string &inboxEntryId)
std::string closeFile(const int64_t fileHandle)
void deleteEntry(const std::string &inboxEntryId)
void deleteInbox(const std::string &inboxId)
std::string createInbox(const std::string &contextId, const std::vector< core::UserWithPubKey > &users, const std::vector< core::UserWithPubKey > &managers, const core::Buffer &publicMeta, const core::Buffer &privateMeta, const std::optional< inbox::FilesConfig > &filesConfig, const std::optional< core::ContainerPolicyWithoutItem > &policies=std::nullopt)
std::vector< std::string > subscribeFor(const std::vector< std::string > &subscriptionQueries)
core::PagingList< inbox::InboxEntry > listEntries(const std::string &inboxId, const core::PagingQuery &pagingQuery)
void sendEntry(const int64_t inboxHandle)
int64_t createFileHandle(const core::Buffer &publicMeta, const core::Buffer &privateMeta, const int64_t &fileSize)
Inbox getInbox(const std::string &inboxId)
void writeToFile(const int64_t inboxHandle, const int64_t inboxFileHandle, const core::Buffer &dataChunk)
void updateInbox(const std::string &inboxId, const std::vector< core::UserWithPubKey > &users, const std::vector< core::UserWithPubKey > &managers, const core::Buffer &publicMeta, const core::Buffer &privateMeta, const std::optional< inbox::FilesConfig > &filesConfig, const int64_t version, const bool force, const bool forceGenerateNewKey, const std::optional< core::ContainerPolicyWithoutItem > &policies=std::nullopt)
inbox::InboxPublicView getInboxPublicView(const std::string &inboxId)
int64_t openFile(const std::string &fileId)
void seekInFile(const int64_t fileHandle, const int64_t position)
core::PagingList< inbox::Inbox > listInboxes(const std::string &contextId, const core::PagingQuery &pagingQuery)
Definition StoreApi.hpp:22
Definition ThreadApi.hpp:23