simplexmq-6.5.0.16: SimpleXMQ message broker
Safe HaskellSafe-Inferred
LanguageHaskell2010

Simplex.Messaging.Encoding.String

Synopsis

Documentation

class StrEncoding a where Source #

Serializing human-readable and (where possible) URI-friendly strings for SMP and SMP agent protocols

Minimal complete definition

strEncode, (strDecode | strP)

Methods

strEncode :: a -> ByteString Source #

strDecode :: ByteString -> Either String a Source #

strP :: Parser a Source #

Instances

Instances details
StrEncoding Int64 Source # 
Instance details

Defined in Simplex.Messaging.Encoding.String

Methods

strEncode :: Int64 -> ByteString Source #

strDecode :: ByteString -> Either String Int64 Source #

strP :: Parser Int64 Source #

StrEncoding Word16 Source # 
Instance details

Defined in Simplex.Messaging.Encoding.String

Methods

strEncode :: Word16 -> ByteString Source #

strDecode :: ByteString -> Either String Word16 Source #

strP :: Parser Word16 Source #

StrEncoding Word32 Source # 
Instance details

Defined in Simplex.Messaging.Encoding.String

Methods

strEncode :: Word32 -> ByteString Source #

strDecode :: ByteString -> Either String Word32 Source #

strP :: Parser Word32 Source #

StrEncoding ByteString Source # 
Instance details

Defined in Simplex.Messaging.Encoding.String

Methods

strEncode :: ByteString -> ByteString Source #

strDecode :: ByteString -> Either String ByteString Source #

strP :: Parser ByteString Source #

StrEncoding IntSet Source # 
Instance details

Defined in Simplex.Messaging.Encoding.String

Methods

strEncode :: IntSet -> ByteString Source #

strDecode :: ByteString -> Either String IntSet Source #

strP :: Parser IntSet Source #

StrEncoding CertificateChain Source # 
Instance details

Defined in Simplex.Messaging.Encoding.String

Methods

strEncode :: CertificateChain -> ByteString Source #

strDecode :: ByteString -> Either String CertificateChain Source #

strP :: Parser CertificateChain Source #

StrEncoding Fingerprint Source # 
Instance details

Defined in Simplex.Messaging.Encoding.String

Methods

strEncode :: Fingerprint -> ByteString Source #

strDecode :: ByteString -> Either String Fingerprint Source #

strP :: Parser Fingerprint Source #

StrEncoding AFileDescription Source # 
Instance details

Defined in Simplex.FileTransfer.Description

Methods

strEncode :: AFileDescription -> ByteString Source #

strDecode :: ByteString -> Either String AFileDescription Source #

strP :: Parser AFileDescription Source #

StrEncoding AValidFileDescription Source # 
Instance details

Defined in Simplex.FileTransfer.Description

Methods

strEncode :: AValidFileDescription -> ByteString Source #

strDecode :: ByteString -> Either String AValidFileDescription Source #

strP :: Parser AValidFileDescription Source #

StrEncoding ChunkReplicaId Source # 
Instance details

Defined in Simplex.FileTransfer.Description

Methods

strEncode :: ChunkReplicaId -> ByteString Source #

strDecode :: ByteString -> Either String ChunkReplicaId Source #

strP :: Parser ChunkReplicaId Source #

StrEncoding FileDescriptionURI Source # 
Instance details

Defined in Simplex.FileTransfer.Description

Methods

strEncode :: FileDescriptionURI -> ByteString Source #

strDecode :: ByteString -> Either String FileDescriptionURI Source #

strP :: Parser FileDescriptionURI Source #

StrEncoding FileDigest Source # 
Instance details

Defined in Simplex.FileTransfer.Description

Methods

strEncode :: FileDigest -> ByteString Source #

strDecode :: ByteString -> Either String FileDigest Source #

strP :: Parser FileDigest Source #

StrEncoding FileInfo Source # 
Instance details

Defined in Simplex.FileTransfer.Protocol

Methods

strEncode :: FileInfo -> ByteString Source #

strDecode :: ByteString -> Either String FileInfo Source #

strP :: Parser FileInfo Source #

StrEncoding ControlProtocol Source # 
Instance details

Defined in Simplex.FileTransfer.Server.Control

Methods

strEncode :: ControlProtocol -> ByteString Source #

strDecode :: ByteString -> Either String ControlProtocol Source #

strP :: Parser ControlProtocol Source #

StrEncoding FileServerStatsData Source # 
Instance details

Defined in Simplex.FileTransfer.Server.Stats

Methods

strEncode :: FileServerStatsData -> ByteString Source #

strDecode :: ByteString -> Either String FileServerStatsData Source #

strP :: Parser FileServerStatsData Source #

StrEncoding FileRecipient Source # 
Instance details

Defined in Simplex.FileTransfer.Server.Store

Methods

strEncode :: FileRecipient -> ByteString Source #

strDecode :: ByteString -> Either String FileRecipient Source #

strP :: Parser FileRecipient Source #

StrEncoding FileStoreLogRecord Source # 
Instance details

Defined in Simplex.FileTransfer.Server.StoreLog

Methods

strEncode :: FileStoreLogRecord -> ByteString Source #

strDecode :: ByteString -> Either String FileStoreLogRecord Source #

strP :: Parser FileStoreLogRecord Source #

StrEncoding XFTPErrorType Source # 
Instance details

Defined in Simplex.FileTransfer.Transport

Methods

strEncode :: XFTPErrorType -> ByteString Source #

strDecode :: ByteString -> Either String XFTPErrorType Source #

strP :: Parser XFTPErrorType Source #

StrEncoding FileErrorType Source # 
Instance details

Defined in Simplex.FileTransfer.Types

Methods

strEncode :: FileErrorType -> ByteString Source #

strDecode :: ByteString -> Either String FileErrorType Source #

strP :: Parser FileErrorType Source #

StrEncoding ACommandTag Source # 
Instance details

Defined in Simplex.Messaging.Agent.Protocol

Methods

strEncode :: ACommandTag -> ByteString Source #

strDecode :: ByteString -> Either String ACommandTag Source #

strP :: Parser ACommandTag Source #

StrEncoding AConnShortLink Source # 
Instance details

Defined in Simplex.Messaging.Agent.Protocol

Methods

strEncode :: AConnShortLink -> ByteString Source #

strDecode :: ByteString -> Either String AConnShortLink Source #

strP :: Parser AConnShortLink Source #

StrEncoding AConnectionLink Source # 
Instance details

Defined in Simplex.Messaging.Agent.Protocol

Methods

strEncode :: AConnectionLink -> ByteString Source #

strDecode :: ByteString -> Either String AConnectionLink Source #

strP :: Parser AConnectionLink Source #

StrEncoding AConnectionMode Source # 
Instance details

Defined in Simplex.Messaging.Agent.Protocol

Methods

strEncode :: AConnectionMode -> ByteString Source #

strDecode :: ByteString -> Either String AConnectionMode Source #

strP :: Parser AConnectionMode Source #

StrEncoding AConnectionRequestUri Source # 
Instance details

Defined in Simplex.Messaging.Agent.Protocol

Methods

strEncode :: AConnectionRequestUri -> ByteString Source #

strDecode :: ByteString -> Either String AConnectionRequestUri Source #

strP :: Parser AConnectionRequestUri Source #

StrEncoding ConnectionMode Source # 
Instance details

Defined in Simplex.Messaging.Agent.Protocol

Methods

strEncode :: ConnectionMode -> ByteString Source #

strDecode :: ByteString -> Either String ConnectionMode Source #

strP :: Parser ConnectionMode Source #

StrEncoding LinkKey Source # 
Instance details

Defined in Simplex.Messaging.Agent.Protocol

Methods

strEncode :: LinkKey -> ByteString Source #

strDecode :: ByteString -> Either String LinkKey Source #

strP :: Parser LinkKey Source #

StrEncoding MsgErrorType Source # 
Instance details

Defined in Simplex.Messaging.Agent.Protocol

Methods

strEncode :: MsgErrorType -> ByteString Source #

strDecode :: ByteString -> Either String MsgErrorType Source #

strP :: Parser MsgErrorType Source #

StrEncoding MsgIntegrity Source # 
Instance details

Defined in Simplex.Messaging.Agent.Protocol

Methods

strEncode :: MsgIntegrity -> ByteString Source #

strDecode :: ByteString -> Either String MsgIntegrity Source #

strP :: Parser MsgIntegrity Source #

StrEncoding MsgReceiptStatus Source # 
Instance details

Defined in Simplex.Messaging.Agent.Protocol

Methods

strEncode :: MsgReceiptStatus -> ByteString Source #

strDecode :: ByteString -> Either String MsgReceiptStatus Source #

strP :: Parser MsgReceiptStatus Source #

StrEncoding NotificationsMode Source # 
Instance details

Defined in Simplex.Messaging.Agent.Protocol

Methods

strEncode :: NotificationsMode -> ByteString Source #

strDecode :: ByteString -> Either String NotificationsMode Source #

strP :: Parser NotificationsMode Source #

StrEncoding RatchetSyncState Source # 
Instance details

Defined in Simplex.Messaging.Agent.Protocol

Methods

strEncode :: RatchetSyncState -> ByteString Source #

strDecode :: ByteString -> Either String RatchetSyncState Source #

strP :: Parser RatchetSyncState Source #

StrEncoding RcvSwitchStatus Source # 
Instance details

Defined in Simplex.Messaging.Agent.Protocol

Methods

strEncode :: RcvSwitchStatus -> ByteString Source #

strDecode :: ByteString -> Either String RcvSwitchStatus Source #

strP :: Parser RcvSwitchStatus Source #

StrEncoding SMPQueueUri Source # 
Instance details

Defined in Simplex.Messaging.Agent.Protocol

Methods

strEncode :: SMPQueueUri -> ByteString Source #

strDecode :: ByteString -> Either String SMPQueueUri Source #

strP :: Parser SMPQueueUri Source #

StrEncoding SndSwitchStatus Source # 
Instance details

Defined in Simplex.Messaging.Agent.Protocol

Methods

strEncode :: SndSwitchStatus -> ByteString Source #

strDecode :: ByteString -> Either String SndSwitchStatus Source #

strP :: Parser SndSwitchStatus Source #

StrEncoding QueryStringParams Source # 
Instance details

Defined in Simplex.Messaging.Agent.QueryString

Methods

strEncode :: QueryStringParams -> ByteString Source #

strDecode :: ByteString -> Either String QueryStringParams Source #

strP :: Parser QueryStringParams Source #

StrEncoding AgentCmdType Source # 
Instance details

Defined in Simplex.Messaging.Agent.Store

Methods

strEncode :: AgentCmdType -> ByteString Source #

strDecode :: ByteString -> Either String AgentCmdType Source #

strP :: Parser AgentCmdType Source #

StrEncoding AgentCommand Source # 
Instance details

Defined in Simplex.Messaging.Agent.Store

Methods

strEncode :: AgentCommand -> ByteString Source #

strDecode :: ByteString -> Either String AgentCommand Source #

strP :: Parser AgentCommand Source #

StrEncoding AgentCommandTag Source # 
Instance details

Defined in Simplex.Messaging.Agent.Store

Methods

strEncode :: AgentCommandTag -> ByteString Source #

strDecode :: ByteString -> Either String AgentCommandTag Source #

strP :: Parser AgentCommandTag Source #

StrEncoding InternalCommand Source # 
Instance details

Defined in Simplex.Messaging.Agent.Store

Methods

strEncode :: InternalCommand -> ByteString Source #

strDecode :: ByteString -> Either String InternalCommand Source #

strP :: Parser InternalCommand Source #

StrEncoding InternalCommandTag Source # 
Instance details

Defined in Simplex.Messaging.Agent.Store

Methods

strEncode :: InternalCommandTag -> ByteString Source #

strDecode :: ByteString -> Either String InternalCommandTag Source #

strP :: Parser InternalCommandTag Source #

StrEncoding InternalId Source # 
Instance details

Defined in Simplex.Messaging.Agent.Store

Methods

strEncode :: InternalId -> ByteString Source #

strDecode :: ByteString -> Either String InternalId Source #

strP :: Parser InternalId Source #

StrEncoding MigrationConfirmation Source # 
Instance details

Defined in Simplex.Messaging.Agent.Store.Shared

Methods

strEncode :: MigrationConfirmation -> ByteString Source #

strDecode :: ByteString -> Either String MigrationConfirmation Source #

strP :: Parser MigrationConfirmation Source #

StrEncoding ProxyClientError Source # 
Instance details

Defined in Simplex.Messaging.Client

Methods

strEncode :: ProxyClientError -> ByteString Source #

strDecode :: ByteString -> Either String ProxyClientError Source #

strP :: Parser ProxyClientError Source #

StrEncoding SMPProxyFallback Source # 
Instance details

Defined in Simplex.Messaging.Client

Methods

strEncode :: SMPProxyFallback -> ByteString Source #

strDecode :: ByteString -> Either String SMPProxyFallback Source #

strP :: Parser SMPProxyFallback Source #

StrEncoding SMPProxyMode Source # 
Instance details

Defined in Simplex.Messaging.Client

Methods

strEncode :: SMPProxyMode -> ByteString Source #

strDecode :: ByteString -> Either String SMPProxyMode Source #

strP :: Parser SMPProxyMode Source #

StrEncoding SMPWebPortServers Source # 
Instance details

Defined in Simplex.Messaging.Client

Methods

strEncode :: SMPWebPortServers -> ByteString Source #

strDecode :: ByteString -> Either String SMPWebPortServers Source #

strP :: Parser SMPWebPortServers Source #

StrEncoding SocksMode Source # 
Instance details

Defined in Simplex.Messaging.Client

Methods

strEncode :: SocksMode -> ByteString Source #

strDecode :: ByteString -> Either String SocksMode Source #

strP :: Parser SocksMode Source #

StrEncoding ADhSecret Source # 
Instance details

Defined in Simplex.Messaging.Crypto

Methods

strEncode :: ADhSecret -> ByteString Source #

strDecode :: ByteString -> Either String ADhSecret Source #

strP :: Parser ADhSecret Source #

StrEncoding APrivateAuthKey Source # 
Instance details

Defined in Simplex.Messaging.Crypto

Methods

strEncode :: APrivateAuthKey -> ByteString Source #

strDecode :: ByteString -> Either String APrivateAuthKey Source #

strP :: Parser APrivateAuthKey Source #

StrEncoding APrivateSignKey Source # 
Instance details

Defined in Simplex.Messaging.Crypto

Methods

strEncode :: APrivateSignKey -> ByteString Source #

strDecode :: ByteString -> Either String APrivateSignKey Source #

strP :: Parser APrivateSignKey Source #

StrEncoding APublicAuthKey Source # 
Instance details

Defined in Simplex.Messaging.Crypto

Methods

strEncode :: APublicAuthKey -> ByteString Source #

strDecode :: ByteString -> Either String APublicAuthKey Source #

strP :: Parser APublicAuthKey Source #

StrEncoding APublicDhKey Source # 
Instance details

Defined in Simplex.Messaging.Crypto

Methods

strEncode :: APublicDhKey -> ByteString Source #

strDecode :: ByteString -> Either String APublicDhKey Source #

strP :: Parser APublicDhKey Source #

StrEncoding APublicVerifyKey Source # 
Instance details

Defined in Simplex.Messaging.Crypto

Methods

strEncode :: APublicVerifyKey -> ByteString Source #

strDecode :: ByteString -> Either String APublicVerifyKey Source #

strP :: Parser APublicVerifyKey Source #

StrEncoding CbNonce Source # 
Instance details

Defined in Simplex.Messaging.Crypto

Methods

strEncode :: CbNonce -> ByteString Source #

strDecode :: ByteString -> Either String CbNonce Source #

strP :: Parser CbNonce Source #

StrEncoding KeyHash Source # 
Instance details

Defined in Simplex.Messaging.Crypto

Methods

strEncode :: KeyHash -> ByteString Source #

strDecode :: ByteString -> Either String KeyHash Source #

strP :: Parser KeyHash Source #

StrEncoding SbKey Source # 
Instance details

Defined in Simplex.Messaging.Crypto

Methods

strEncode :: SbKey -> ByteString Source #

strDecode :: ByteString -> Either String SbKey Source #

strP :: Parser SbKey Source #

StrEncoding InitialKeys Source # 
Instance details

Defined in Simplex.Messaging.Crypto.Ratchet

Methods

strEncode :: InitialKeys -> ByteString Source #

strDecode :: ByteString -> Either String InitialKeys Source #

strP :: Parser InitialKeys Source #

StrEncoding PQEncryption Source # 
Instance details

Defined in Simplex.Messaging.Crypto.Ratchet

Methods

strEncode :: PQEncryption -> ByteString Source #

strDecode :: ByteString -> Either String PQEncryption Source #

strP :: Parser PQEncryption Source #

StrEncoding PQSupport Source # 
Instance details

Defined in Simplex.Messaging.Crypto.Ratchet

Methods

strEncode :: PQSupport -> ByteString Source #

strDecode :: ByteString -> Either String PQSupport Source #

strP :: Parser PQSupport Source #

StrEncoding KEMCiphertext Source # 
Instance details

Defined in Simplex.Messaging.Crypto.SNTRUP761.Bindings

Methods

strEncode :: KEMCiphertext -> ByteString Source #

strDecode :: ByteString -> Either String KEMCiphertext Source #

strP :: Parser KEMCiphertext Source #

StrEncoding KEMPublicKey Source # 
Instance details

Defined in Simplex.Messaging.Crypto.SNTRUP761.Bindings

Methods

strEncode :: KEMPublicKey -> ByteString Source #

strDecode :: ByteString -> Either String KEMPublicKey Source #

strP :: Parser KEMPublicKey Source #

StrEncoding KEMSecretKey Source # 
Instance details

Defined in Simplex.Messaging.Crypto.SNTRUP761.Bindings

Methods

strEncode :: KEMSecretKey -> ByteString Source #

strDecode :: ByteString -> Either String KEMSecretKey Source #

strP :: Parser KEMSecretKey Source #

StrEncoding KEMSharedKey Source # 
Instance details

Defined in Simplex.Messaging.Crypto.SNTRUP761.Bindings

Methods

strEncode :: KEMSharedKey -> ByteString Source #

strDecode :: ByteString -> Either String KEMSharedKey Source #

strP :: Parser KEMSharedKey Source #

StrEncoding Str Source # 
Instance details

Defined in Simplex.Messaging.Encoding.String

Methods

strEncode :: Str -> ByteString Source #

strDecode :: ByteString -> Either String Str Source #

strP :: Parser Str Source #

StrEncoding DeviceToken Source # 
Instance details

Defined in Simplex.Messaging.Notifications.Protocol

Methods

strEncode :: DeviceToken -> ByteString Source #

strDecode :: ByteString -> Either String DeviceToken Source #

strP :: Parser DeviceToken Source #

StrEncoding NTInvalidReason Source # 
Instance details

Defined in Simplex.Messaging.Notifications.Protocol

Methods

strEncode :: NTInvalidReason -> ByteString Source #

strDecode :: ByteString -> Either String NTInvalidReason Source #

strP :: Parser NTInvalidReason Source #

StrEncoding NtfRegCode Source # 
Instance details

Defined in Simplex.Messaging.Notifications.Protocol

Methods

strEncode :: NtfRegCode -> ByteString Source #

strDecode :: ByteString -> Either String NtfRegCode Source #

strP :: Parser NtfRegCode Source #

StrEncoding NtfSubStatus Source # 
Instance details

Defined in Simplex.Messaging.Notifications.Protocol

Methods

strEncode :: NtfSubStatus -> ByteString Source #

strDecode :: ByteString -> Either String NtfSubStatus Source #

strP :: Parser NtfSubStatus Source #

StrEncoding NtfTknStatus Source # 
Instance details

Defined in Simplex.Messaging.Notifications.Protocol

Methods

strEncode :: NtfTknStatus -> ByteString Source #

strDecode :: ByteString -> Either String NtfTknStatus Source #

strP :: Parser NtfTknStatus Source #

StrEncoding PNMessageData Source # 
Instance details

Defined in Simplex.Messaging.Notifications.Protocol

Methods

strEncode :: PNMessageData -> ByteString Source #

strDecode :: ByteString -> Either String PNMessageData Source #

strP :: Parser PNMessageData Source #

StrEncoding PushProvider Source # 
Instance details

Defined in Simplex.Messaging.Notifications.Protocol

Methods

strEncode :: PushProvider -> ByteString Source #

strDecode :: ByteString -> Either String PushProvider Source #

strP :: Parser PushProvider Source #

StrEncoding SMPQueueNtf Source # 
Instance details

Defined in Simplex.Messaging.Notifications.Protocol

Methods

strEncode :: SMPQueueNtf -> ByteString Source #

strDecode :: ByteString -> Either String SMPQueueNtf Source #

strP :: Parser SMPQueueNtf Source #

StrEncoding AProtoServerWithAuth Source # 
Instance details

Defined in Simplex.Messaging.Protocol

Methods

strEncode :: AProtoServerWithAuth -> ByteString Source #

strDecode :: ByteString -> Either String AProtoServerWithAuth Source #

strP :: Parser AProtoServerWithAuth Source #

StrEncoding AProtocolType Source # 
Instance details

Defined in Simplex.Messaging.Protocol

Methods

strEncode :: AProtocolType -> ByteString Source #

strDecode :: ByteString -> Either String AProtocolType Source #

strP :: Parser AProtocolType Source #

StrEncoding ASubscriberParty Source # 
Instance details

Defined in Simplex.Messaging.Protocol

Methods

strEncode :: ASubscriberParty -> ByteString Source #

strDecode :: ByteString -> Either String ASubscriberParty Source #

strP :: Parser ASubscriberParty Source #

StrEncoding BasicAuth Source # 
Instance details

Defined in Simplex.Messaging.Protocol

Methods

strEncode :: BasicAuth -> ByteString Source #

strDecode :: ByteString -> Either String BasicAuth Source #

strP :: Parser BasicAuth Source #

StrEncoding BlockingInfo Source # 
Instance details

Defined in Simplex.Messaging.Protocol

Methods

strEncode :: BlockingInfo -> ByteString Source #

strDecode :: ByteString -> Either String BlockingInfo Source #

strP :: Parser BlockingInfo Source #

StrEncoding BlockingReason Source # 
Instance details

Defined in Simplex.Messaging.Protocol

Methods

strEncode :: BlockingReason -> ByteString Source #

strDecode :: ByteString -> Either String BlockingReason Source #

strP :: Parser BlockingReason Source #

StrEncoding BrokerErrorType Source # 
Instance details

Defined in Simplex.Messaging.Protocol

Methods

strEncode :: BrokerErrorType -> ByteString Source #

strDecode :: ByteString -> Either String BrokerErrorType Source #

strP :: Parser BrokerErrorType Source #

StrEncoding CorrId Source # 
Instance details

Defined in Simplex.Messaging.Protocol

Methods

strEncode :: CorrId -> ByteString Source #

strDecode :: ByteString -> Either String CorrId Source #

strP :: Parser CorrId Source #

StrEncoding EncDataBytes Source # 
Instance details

Defined in Simplex.Messaging.Protocol

Methods

strEncode :: EncDataBytes -> ByteString Source #

strDecode :: ByteString -> Either String EncDataBytes Source #

strP :: Parser EncDataBytes Source #

StrEncoding ErrorType Source # 
Instance details

Defined in Simplex.Messaging.Protocol

Methods

strEncode :: ErrorType -> ByteString Source #

strDecode :: ByteString -> Either String ErrorType Source #

strP :: Parser ErrorType Source #

StrEncoding Message Source # 
Instance details

Defined in Simplex.Messaging.Protocol

Methods

strEncode :: Message -> ByteString Source #

strDecode :: ByteString -> Either String Message Source #

strP :: Parser Message Source #

StrEncoding MsgFlags Source # 
Instance details

Defined in Simplex.Messaging.Protocol

Methods

strEncode :: MsgFlags -> ByteString Source #

strDecode :: ByteString -> Either String MsgFlags Source #

strP :: Parser MsgFlags Source #

StrEncoding NetworkError Source # 
Instance details

Defined in Simplex.Messaging.Protocol

Methods

strEncode :: NetworkError -> ByteString Source #

strDecode :: ByteString -> Either String NetworkError Source #

strP :: Parser NetworkError Source #

StrEncoding ProtocolType Source # 
Instance details

Defined in Simplex.Messaging.Protocol

Methods

strEncode :: ProtocolType -> ByteString Source #

strDecode :: ByteString -> Either String ProtocolType Source #

strP :: Parser ProtocolType Source #

StrEncoding ProxyError Source # 
Instance details

Defined in Simplex.Messaging.Protocol

Methods

strEncode :: ProxyError -> ByteString Source #

strDecode :: ByteString -> Either String ProxyError Source #

strP :: Parser ProxyError Source #

StrEncoding SMPMsgMeta Source # 
Instance details

Defined in Simplex.Messaging.Protocol

Methods

strEncode :: SMPMsgMeta -> ByteString Source #

strDecode :: ByteString -> Either String SMPMsgMeta Source #

strP :: Parser SMPMsgMeta Source #

StrEncoding SubscriptionMode Source # 
Instance details

Defined in Simplex.Messaging.Protocol

Methods

strEncode :: SubscriptionMode -> ByteString Source #

strDecode :: ByteString -> Either String SubscriptionMode Source #

strP :: Parser SubscriptionMode Source #

StrEncoding ControlProtocol Source # 
Instance details

Defined in Simplex.Messaging.Server.Control

Methods

strEncode :: ControlProtocol -> ByteString Source #

strDecode :: ByteString -> Either String ControlProtocol Source #

strP :: Parser ControlProtocol Source #

StrEncoding HostingType Source # 
Instance details

Defined in Simplex.Messaging.Server.Information

Methods

strEncode :: HostingType -> ByteString Source #

strDecode :: ByteString -> Either String HostingType Source #

strP :: Parser HostingType Source #

StrEncoding DatabaseTable Source # 
Instance details

Defined in Simplex.Messaging.Server.Main

Methods

strEncode :: DatabaseTable -> ByteString Source #

strDecode :: ByteString -> Either String DatabaseTable Source #

strP :: Parser DatabaseTable Source #

StrEncoding MsgLogRecord Source # 
Instance details

Defined in Simplex.Messaging.Server.MsgStore

Methods

strEncode :: MsgLogRecord -> ByteString Source #

strDecode :: ByteString -> Either String MsgLogRecord Source #

strP :: Parser MsgLogRecord Source #

StrEncoding MsgQueueState Source # 
Instance details

Defined in Simplex.Messaging.Server.MsgStore.Journal

Methods

strEncode :: MsgQueueState -> ByteString Source #

strDecode :: ByteString -> Either String MsgQueueState Source #

strP :: Parser MsgQueueState Source #

StrEncoding MsgNtf Source # 
Instance details

Defined in Simplex.Messaging.Server.NtfStore

Methods

strEncode :: MsgNtf -> ByteString Source #

strDecode :: ByteString -> Either String MsgNtf Source #

strP :: Parser MsgNtf Source #

StrEncoding NtfLogRecord Source # 
Instance details

Defined in Simplex.Messaging.Server.NtfStore

Methods

strEncode :: NtfLogRecord -> ByteString Source #

strDecode :: ByteString -> Either String NtfLogRecord Source #

strP :: Parser NtfLogRecord Source #

StrEncoding NtfCreds Source # 
Instance details

Defined in Simplex.Messaging.Server.QueueStore

Methods

strEncode :: NtfCreds -> ByteString Source #

strDecode :: ByteString -> Either String NtfCreds Source #

strP :: Parser NtfCreds Source #

StrEncoding QueueRec Source # 
Instance details

Defined in Simplex.Messaging.Server.StoreLog

Methods

strEncode :: QueueRec -> ByteString Source #

strDecode :: ByteString -> Either String QueueRec Source #

strP :: Parser QueueRec Source #

StrEncoding ServerEntityStatus Source # 
Instance details

Defined in Simplex.Messaging.Server.QueueStore

Methods

strEncode :: ServerEntityStatus -> ByteString Source #

strDecode :: ByteString -> Either String ServerEntityStatus Source #

strP :: Parser ServerEntityStatus Source #

StrEncoding ServiceRec Source # 
Instance details

Defined in Simplex.Messaging.Server.QueueStore

Methods

strEncode :: ServiceRec -> ByteString Source #

strDecode :: ByteString -> Either String ServiceRec Source #

strP :: Parser ServiceRec Source #

StrEncoding PeriodStatsData Source # 
Instance details

Defined in Simplex.Messaging.Server.Stats

Methods

strEncode :: PeriodStatsData -> ByteString Source #

strDecode :: ByteString -> Either String PeriodStatsData Source #

strP :: Parser PeriodStatsData Source #

StrEncoding ProxyStatsData Source # 
Instance details

Defined in Simplex.Messaging.Server.Stats

Methods

strEncode :: ProxyStatsData -> ByteString Source #

strDecode :: ByteString -> Either String ProxyStatsData Source #

strP :: Parser ProxyStatsData Source #

StrEncoding ServerStatsData Source # 
Instance details

Defined in Simplex.Messaging.Server.Stats

Methods

strEncode :: ServerStatsData -> ByteString Source #

strDecode :: ByteString -> Either String ServerStatsData Source #

strP :: Parser ServerStatsData Source #

StrEncoding ServiceStatsData Source # 
Instance details

Defined in Simplex.Messaging.Server.Stats

Methods

strEncode :: ServiceStatsData -> ByteString Source #

strDecode :: ByteString -> Either String ServiceStatsData Source #

strP :: Parser ServiceStatsData Source #

StrEncoding StoreLogRecord Source # 
Instance details

Defined in Simplex.Messaging.Server.StoreLog

Methods

strEncode :: StoreLogRecord -> ByteString Source #

strDecode :: ByteString -> Either String StoreLogRecord Source #

strP :: Parser StoreLogRecord Source #

StrEncoding ServiceScheme Source # 
Instance details

Defined in Simplex.Messaging.ServiceScheme

Methods

strEncode :: ServiceScheme -> ByteString Source #

strDecode :: ByteString -> Either String ServiceScheme Source #

strP :: Parser ServiceScheme Source #

StrEncoding SrvLoc Source # 
Instance details

Defined in Simplex.Messaging.ServiceScheme

Methods

strEncode :: SrvLoc -> ByteString Source #

strDecode :: ByteString -> Either String SrvLoc Source #

strP :: Parser SrvLoc Source #

StrEncoding EntityId Source # 
Instance details

Defined in Simplex.Messaging.Transport

Methods

strEncode :: EntityId -> ByteString Source #

strDecode :: ByteString -> Either String EntityId Source #

strP :: Parser EntityId Source #

StrEncoding SocksAuth Source # 
Instance details

Defined in Simplex.Messaging.Transport.Client

Methods

strEncode :: SocksAuth -> ByteString Source #

strDecode :: ByteString -> Either String SocksAuth Source #

strP :: Parser SocksAuth Source #

StrEncoding SocksProxy Source # 
Instance details

Defined in Simplex.Messaging.Transport.Client

Methods

strEncode :: SocksProxy -> ByteString Source #

strDecode :: ByteString -> Either String SocksProxy Source #

strP :: Parser SocksProxy Source #

StrEncoding SocksProxyWithAuth Source # 
Instance details

Defined in Simplex.Messaging.Transport.Client

Methods

strEncode :: SocksProxyWithAuth -> ByteString Source #

strDecode :: ByteString -> Either String SocksProxyWithAuth Source #

strP :: Parser SocksProxyWithAuth Source #

StrEncoding TransportHost Source # 
Instance details

Defined in Simplex.Messaging.Transport.Client

Methods

strEncode :: TransportHost -> ByteString Source #

strDecode :: ByteString -> Either String TransportHost Source #

strP :: Parser TransportHost Source #

StrEncoding TransportHosts Source # 
Instance details

Defined in Simplex.Messaging.Transport.Client

Methods

strEncode :: TransportHosts -> ByteString Source #

strDecode :: ByteString -> Either String TransportHosts Source #

strP :: Parser TransportHosts Source #

StrEncoding TransportHosts_ Source # 
Instance details

Defined in Simplex.Messaging.Transport.Client

Methods

strEncode :: TransportHosts_ -> ByteString Source #

strDecode :: ByteString -> Either String TransportHosts_ Source #

strP :: Parser TransportHosts_ Source #

StrEncoding RCInvitation Source # 
Instance details

Defined in Simplex.RemoteControl.Invitation

Methods

strEncode :: RCInvitation -> ByteString Source #

strDecode :: ByteString -> Either String RCInvitation Source #

strP :: Parser RCInvitation Source #

StrEncoding RCSignedInvitation Source #

URL-encoded and signed for showing in QR code

Instance details

Defined in Simplex.RemoteControl.Invitation

Methods

strEncode :: RCSignedInvitation -> ByteString Source #

strDecode :: ByteString -> Either String RCSignedInvitation Source #

strP :: Parser RCSignedInvitation Source #

StrEncoding RCErrorType Source # 
Instance details

Defined in Simplex.RemoteControl.Types

Methods

strEncode :: RCErrorType -> ByteString Source #

strDecode :: ByteString -> Either String RCErrorType Source #

strP :: Parser RCErrorType Source #

StrEncoding Text Source # 
Instance details

Defined in Simplex.Messaging.Encoding.String

Methods

strEncode :: Text -> ByteString Source #

strDecode :: ByteString -> Either String Text Source #

strP :: Parser Text Source #

StrEncoding SystemTime Source # 
Instance details

Defined in Simplex.Messaging.Encoding.String

Methods

strEncode :: SystemTime -> ByteString Source #

strDecode :: ByteString -> Either String SystemTime Source #

strP :: Parser SystemTime Source #

StrEncoding UTCTime Source # 
Instance details

Defined in Simplex.Messaging.Encoding.String

Methods

strEncode :: UTCTime -> ByteString Source #

strDecode :: ByteString -> Either String UTCTime Source #

strP :: Parser UTCTime Source #

StrEncoding String Source # 
Instance details

Defined in Simplex.Messaging.Encoding.String

Methods

strEncode :: String -> ByteString Source #

strDecode :: ByteString -> Either String String Source #

strP :: Parser String Source #

StrEncoding Bool Source # 
Instance details

Defined in Simplex.Messaging.Encoding.String

Methods

strEncode :: Bool -> ByteString Source #

strDecode :: ByteString -> Either String Bool Source #

strP :: Parser Bool Source #

StrEncoding Char Source # 
Instance details

Defined in Simplex.Messaging.Encoding.String

Methods

strEncode :: Char -> ByteString Source #

strDecode :: ByteString -> Either String Char Source #

strP :: Parser Char Source #

StrEncoding Int Source # 
Instance details

Defined in Simplex.Messaging.Encoding.String

Methods

strEncode :: Int -> ByteString Source #

strDecode :: ByteString -> Either String Int Source #

strP :: Parser Int Source #

StrEncoding a => StrEncoding (NonEmpty a) Source # 
Instance details

Defined in Simplex.Messaging.Encoding.String

Methods

strEncode :: NonEmpty a -> ByteString Source #

strDecode :: ByteString -> Either String (NonEmpty a) Source #

strP :: Parser (NonEmpty a) Source #

(StrEncoding a, Ord a) => StrEncoding (Set a) Source # 
Instance details

Defined in Simplex.Messaging.Encoding.String

Methods

strEncode :: Set a -> ByteString Source #

strDecode :: ByteString -> Either String (Set a) Source #

strP :: Parser (Set a) Source #

FilePartyI p => StrEncoding (FileDescription p) Source # 
Instance details

Defined in Simplex.FileTransfer.Description

Methods

strEncode :: FileDescription p -> ByteString Source #

strDecode :: ByteString -> Either String (FileDescription p) Source #

strP :: Parser (FileDescription p) Source #

(Integral a, Show a) => StrEncoding (FileSize a) Source # 
Instance details

Defined in Simplex.FileTransfer.Description

Methods

strEncode :: FileSize a -> ByteString Source #

strDecode :: ByteString -> Either String (FileSize a) Source #

strP :: Parser (FileSize a) Source #

FilePartyI p => StrEncoding (ValidFileDescription p) Source # 
Instance details

Defined in Simplex.FileTransfer.Description

Methods

strEncode :: ValidFileDescription p -> ByteString Source #

strDecode :: ByteString -> Either String (ValidFileDescription p) Source #

strP :: Parser (ValidFileDescription p) Source #

ConnectionModeI m => StrEncoding (ConnShortLink m) Source # 
Instance details

Defined in Simplex.Messaging.Agent.Protocol

Methods

strEncode :: ConnShortLink m -> ByteString Source #

strDecode :: ByteString -> Either String (ConnShortLink m) Source #

strP :: Parser (ConnShortLink m) Source #

ConnectionModeI m => StrEncoding (ConnectionLink m) Source # 
Instance details

Defined in Simplex.Messaging.Agent.Protocol

Methods

strEncode :: ConnectionLink m -> ByteString Source #

strDecode :: ByteString -> Either String (ConnectionLink m) Source #

strP :: Parser (ConnectionLink m) Source #

ConnectionModeI m => StrEncoding (ConnectionRequestUri m) Source # 
Instance details

Defined in Simplex.Messaging.Agent.Protocol

Methods

strEncode :: ConnectionRequestUri m -> ByteString Source #

strDecode :: ByteString -> Either String (ConnectionRequestUri m) Source #

strP :: Parser (ConnectionRequestUri m) Source #

ConnectionModeI c => StrEncoding (UserConnLinkData c) Source # 
Instance details

Defined in Simplex.Messaging.Agent.Protocol

Methods

strEncode :: UserConnLinkData c -> ByteString Source #

strDecode :: ByteString -> Either String (UserConnLinkData c) Source #

strP :: Parser (UserConnLinkData c) Source #

AlgorithmI a => StrEncoding (DhSecret a) Source # 
Instance details

Defined in Simplex.Messaging.Crypto

Methods

strEncode :: DhSecret a -> ByteString Source #

strDecode :: ByteString -> Either String (DhSecret a) Source #

strP :: Parser (DhSecret a) Source #

KnownNat i => StrEncoding (MaxLenBS i) Source # 
Instance details

Defined in Simplex.Messaging.Crypto

Methods

strEncode :: MaxLenBS i -> ByteString Source #

strDecode :: ByteString -> Either String (MaxLenBS i) Source #

strP :: Parser (MaxLenBS i) Source #

StrEncoding (PrivateKey 'X25519) Source # 
Instance details

Defined in Simplex.Messaging.Crypto

Methods

strEncode :: PrivateKey 'X25519 -> ByteString Source #

strDecode :: ByteString -> Either String (PrivateKey 'X25519) Source #

strP :: Parser (PrivateKey 'X25519) Source #

AlgorithmI a => StrEncoding (PublicKey a) Source # 
Instance details

Defined in Simplex.Messaging.Crypto

Methods

strEncode :: PublicKey a -> ByteString Source #

strDecode :: ByteString -> Either String (PublicKey a) Source #

strP :: Parser (PublicKey a) Source #

CryptoSignature (Signature s) => StrEncoding (Signature s) Source # 
Instance details

Defined in Simplex.Messaging.Crypto

Methods

strEncode :: Signature s -> ByteString Source #

strDecode :: ByteString -> Either String (Signature s) Source #

strP :: Parser (Signature s) Source #

ProtocolTypeI p => StrEncoding (ProtoServerWithAuth p) Source # 
Instance details

Defined in Simplex.Messaging.Protocol

Methods

strEncode :: ProtoServerWithAuth p -> ByteString Source #

strDecode :: ByteString -> Either String (ProtoServerWithAuth p) Source #

strP :: Parser (ProtoServerWithAuth p) Source #

ProtocolTypeI p => StrEncoding (ProtocolServer p) Source # 
Instance details

Defined in Simplex.Messaging.Protocol

Methods

strEncode :: ProtocolServer p -> ByteString Source #

strDecode :: ByteString -> Either String (ProtocolServer p) Source #

strP :: Parser (ProtocolServer p) Source #

ProtocolTypeI p => StrEncoding (SProtocolType p) Source # 
Instance details

Defined in Simplex.Messaging.Protocol

Methods

strEncode :: SProtocolType p -> ByteString Source #

strDecode :: ByteString -> Either String (SProtocolType p) Source #

strP :: Parser (SProtocolType p) Source #

JournalTypeI t => StrEncoding (JournalState t) Source # 
Instance details

Defined in Simplex.Messaging.Server.MsgStore.Journal

Methods

strEncode :: JournalState t -> ByteString Source #

strDecode :: ByteString -> Either String (JournalState t) Source #

strP :: Parser (JournalState t) Source #

StrEncoding (RoundedSystemTime t) Source # 
Instance details

Defined in Simplex.Messaging.SystemTime

Methods

strEncode :: RoundedSystemTime t -> ByteString Source #

strDecode :: ByteString -> Either String (RoundedSystemTime t) Source #

strP :: Parser (RoundedSystemTime t) Source #

VersionScope v => StrEncoding (VersionRange v) Source # 
Instance details

Defined in Simplex.Messaging.Version

Methods

strEncode :: VersionRange v -> ByteString Source #

strDecode :: ByteString -> Either String (VersionRange v) Source #

strP :: Parser (VersionRange v) Source #

StrEncoding (Version v) Source # 
Instance details

Defined in Simplex.Messaging.Version.Internal

Methods

strEncode :: Version v -> ByteString Source #

strDecode :: ByteString -> Either String (Version v) Source #

strP :: Parser (Version v) Source #

StrEncoding a => StrEncoding (Maybe a) Source # 
Instance details

Defined in Simplex.Messaging.Encoding.String

Methods

strEncode :: Maybe a -> ByteString Source #

strDecode :: ByteString -> Either String (Maybe a) Source #

strP :: Parser (Maybe a) Source #

(RatchetKEMStateI s, AlgorithmI a) => StrEncoding (E2ERatchetParamsUri s a) Source # 
Instance details

Defined in Simplex.Messaging.Crypto.Ratchet

Methods

strEncode :: E2ERatchetParamsUri s a -> ByteString Source #

strDecode :: ByteString -> Either String (E2ERatchetParamsUri s a) Source #

strP :: Parser (E2ERatchetParamsUri s a) Source #

(StrEncoding a, StrEncoding b) => StrEncoding (a, b) Source # 
Instance details

Defined in Simplex.Messaging.Encoding.String

Methods

strEncode :: (a, b) -> ByteString Source #

strDecode :: ByteString -> Either String (a, b) Source #

strP :: Parser (a, b) Source #

(StrEncoding a, StrEncoding b, StrEncoding c) => StrEncoding (a, b, c) Source # 
Instance details

Defined in Simplex.Messaging.Encoding.String

Methods

strEncode :: (a, b, c) -> ByteString Source #

strDecode :: ByteString -> Either String (a, b, c) Source #

strP :: Parser (a, b, c) Source #

(StrEncoding a, StrEncoding b, StrEncoding c, StrEncoding d) => StrEncoding (a, b, c, d) Source # 
Instance details

Defined in Simplex.Messaging.Encoding.String

Methods

strEncode :: (a, b, c, d) -> ByteString Source #

strDecode :: ByteString -> Either String (a, b, c, d) Source #

strP :: Parser (a, b, c, d) Source #

(StrEncoding a, StrEncoding b, StrEncoding c, StrEncoding d, StrEncoding e) => StrEncoding (a, b, c, d, e) Source # 
Instance details

Defined in Simplex.Messaging.Encoding.String

Methods

strEncode :: (a, b, c, d, e) -> ByteString Source #

strDecode :: ByteString -> Either String (a, b, c, d, e) Source #

strP :: Parser (a, b, c, d, e) Source #

(StrEncoding a, StrEncoding b, StrEncoding c, StrEncoding d, StrEncoding e, StrEncoding f) => StrEncoding (a, b, c, d, e, f) Source # 
Instance details

Defined in Simplex.Messaging.Encoding.String

Methods

strEncode :: (a, b, c, d, e, f) -> ByteString Source #

strDecode :: ByteString -> Either String (a, b, c, d, e, f) Source #

strP :: Parser (a, b, c, d, e, f) Source #

newtype Str Source #

Constructors

Str 

Fields

Instances

Instances details
FromJSON Str Source # 
Instance details

Defined in Simplex.Messaging.Encoding.String

Methods

parseJSON :: Value -> Parser Str

parseJSONList :: Value -> Parser [Str]

omittedField :: Maybe Str

ToJSON Str Source # 
Instance details

Defined in Simplex.Messaging.Encoding.String

Methods

toJSON :: Str -> Value

toEncoding :: Str -> Encoding

toJSONList :: [Str] -> Value

toEncodingList :: [Str] -> Encoding

omitField :: Str -> Bool

Show Str Source # 
Instance details

Defined in Simplex.Messaging.Encoding.String

Methods

showsPrec :: Int -> Str -> ShowS

show :: Str -> String

showList :: [Str] -> ShowS

Eq Str Source # 
Instance details

Defined in Simplex.Messaging.Encoding.String

Methods

(==) :: Str -> Str -> Bool

(/=) :: Str -> Str -> Bool

StrEncoding Str Source # 
Instance details

Defined in Simplex.Messaging.Encoding.String

Methods

strEncode :: Str -> ByteString Source #

strDecode :: ByteString -> Either String Str Source #

strP :: Parser Str Source #

strP_ :: StrEncoding a => Parser a Source #

_strP :: StrEncoding a => Parser a Source #

strToJSON :: StrEncoding a => a -> Value Source #

strToJEncoding :: StrEncoding a => a -> Encoding Source #

strParseJSON :: StrEncoding a => String -> Value -> Parser a Source #

textToJSON :: TextEncoding a => a -> Value Source #

textToEncoding :: TextEncoding a => a -> Encoding Source #

textParseJSON :: TextEncoding a => String -> Value -> Parser a Source #

base64urlP :: Parser ByteString Source #

strEncodeList :: StrEncoding a => [a] -> ByteString Source #

strListP :: StrEncoding a => Parser [a] Source #