InboxEntryHandler
Class wrapping the process of creating and uploading an Inbox Entry.
Fields
RecommendedChunkSize
Int64
Recommended chunk size for file transfers, suggested by the endpoint library.
state
InboxEntryHandlerState
The current state
Static Methods
prepareInboxEntryHandler(using:in:containing:sending:derivingPublicKeyFrom:)
Creates a new InboxEntryHandler
for sending an entry to an Inbox.
If fileSources is an empty array, the created handler will be in .filesSent
, otherwise it will be in .prepared
.
Params
inboxApi
any PrivMXInbox
provider of PrivMXInbox
API
inboxId
String
Id of the Inbox in which the Entry is supposed to appear
data
Data
arbitrary data that will appear as a message in the Inbox
fileSources
[any FileDataSource]
list of sources of data for Files attached to the Entry
userPrivateKey
String?
Optional identity of the Sender.
Returns
InboxEntryHandler
·
an instance of InboxEntryHandler
Methods
sendFiles()
Uploads the files associated with the Entry.
Returns
InboxEntryHandlerState
·
the state of the Handler
cancel()
Aborts sending of the files, if they haven’t been sent already
sendEntry()
Sends the entry, completing the process and adding it to the Inbox.
We use cookies on our website. We use them to ensure the proper functioning of the site and, if you agree, for purposes we set, such as analytics or marketing.
PrivMX Endpoint Swift v2.3