simplexmq-0.5.0: SimpleXMQ message broker
Safe HaskellNone
LanguageHaskell2010

Simplex.Messaging.Agent.Store.SQLite

Documentation

data SQLiteStore Source #

Instances

Instances details
(MonadUnliftIO m, MonadError StoreError m) => MonadAgentStore SQLiteStore m Source # 
Instance details

Defined in Simplex.Messaging.Agent.Store.SQLite

Methods

createRcvConn :: forall (c :: ConnectionMode). SQLiteStore -> TVar ChaChaDRG -> ConnData -> RcvQueue -> SConnectionMode c -> m ConnId Source #

createSndConn :: SQLiteStore -> TVar ChaChaDRG -> ConnData -> SndQueue -> m ConnId Source #

getConn :: SQLiteStore -> ConnId -> m SomeConn Source #

getAllConnIds :: SQLiteStore -> m [ConnId] Source #

getRcvConn :: SQLiteStore -> SMPServer -> RecipientId -> m SomeConn Source #

deleteConn :: SQLiteStore -> ConnId -> m () Source #

upgradeRcvConnToDuplex :: SQLiteStore -> ConnId -> SndQueue -> m () Source #

upgradeSndConnToDuplex :: SQLiteStore -> ConnId -> RcvQueue -> m () Source #

setRcvQueueStatus :: SQLiteStore -> RcvQueue -> QueueStatus -> m () Source #

setRcvQueueActive :: SQLiteStore -> RcvQueue -> VerificationKey -> m () Source #

setSndQueueStatus :: SQLiteStore -> SndQueue -> QueueStatus -> m () Source #

updateSignKey :: SQLiteStore -> SndQueue -> SignatureKey -> m () Source #

createConfirmation :: SQLiteStore -> TVar ChaChaDRG -> NewConfirmation -> m ConfirmationId Source #

acceptConfirmation :: SQLiteStore -> ConfirmationId -> ConnInfo -> m AcceptedConfirmation Source #

getAcceptedConfirmation :: SQLiteStore -> ConnId -> m AcceptedConfirmation Source #

removeConfirmations :: SQLiteStore -> ConnId -> m () Source #

createInvitation :: SQLiteStore -> TVar ChaChaDRG -> NewInvitation -> m InvitationId Source #

getInvitation :: SQLiteStore -> InvitationId -> m Invitation Source #

acceptInvitation :: SQLiteStore -> InvitationId -> ConnInfo -> m () Source #

deleteInvitation :: SQLiteStore -> ConnId -> InvitationId -> m () Source #

updateRcvIds :: SQLiteStore -> ConnId -> m (InternalId, InternalRcvId, PrevExternalSndId, PrevRcvMsgHash) Source #

createRcvMsg :: SQLiteStore -> ConnId -> RcvMsgData -> m () Source #

updateSndIds :: SQLiteStore -> ConnId -> m (InternalId, InternalSndId, PrevSndMsgHash) Source #

createSndMsg :: SQLiteStore -> ConnId -> SndMsgData -> m () Source #

updateSndMsgStatus :: SQLiteStore -> ConnId -> InternalId -> SndMsgStatus -> m () Source #

getPendingMsgData :: SQLiteStore -> ConnId -> InternalId -> m (SndQueue, MsgBody) Source #

getPendingMsgs :: SQLiteStore -> ConnId -> m [PendingMsg] Source #

getMsg :: SQLiteStore -> ConnId -> InternalId -> m Msg Source #

checkRcvMsg :: SQLiteStore -> ConnId -> InternalId -> m () Source #

updateRcvMsgAck :: SQLiteStore -> ConnId -> InternalId -> m () Source #

withTransaction :: forall a. SQLiteStore -> (Connection -> IO a) -> IO a Source #

fromTextField_ :: Typeable a => (Text -> Maybe a) -> Field -> Ok a Source #

Orphan instances

FromField MsgIntegrity Source # 
Instance details

FromField QueueStatus Source # 
Instance details

FromField AConnectionRequest Source # 
Instance details

FromField SMPQueueUri Source # 
Instance details

FromField AConnectionMode Source # 
Instance details

FromField ConnectionMode Source # 
Instance details

FromField InternalId Source # 
Instance details

FromField InternalSndId Source # 
Instance details

FromField InternalRcvId Source # 
Instance details

ToField MsgIntegrity Source # 
Instance details

ToField QueueStatus Source # 
Instance details

ToField AConnectionRequest Source # 
Instance details

ToField SMPQueueUri Source # 
Instance details

ToField ConnectionMode Source # 
Instance details

ToField InternalId Source # 
Instance details

ToField SndMsgStatus Source # 
Instance details

ToField InternalSndId Source # 
Instance details

ToField RcvMsgStatus Source # 
Instance details

ToField InternalRcvId Source # 
Instance details

(Typeable c, ConnectionModeI c) => FromField (ConnectionRequest c) Source # 
Instance details

ToField (ConnectionRequest c) Source # 
Instance details

ToField (SConnectionMode c) Source # 
Instance details

(FromField a, FromField b, FromField c, FromField d, FromField e, FromField f, FromField g, FromField h, FromField i, FromField j, FromField k) => FromRow (a, b, c, d, e, f, g, h, i, j, k) Source # 
Instance details

Methods

fromRow :: RowParser (a, b, c, d, e, f, g, h, i, j, k) #

(FromField a, FromField b, FromField c, FromField d, FromField e, FromField f, FromField g, FromField h, FromField i, FromField j, FromField k, FromField l) => FromRow (a, b, c, d, e, f, g, h, i, j, k, l) Source # 
Instance details

Methods

fromRow :: RowParser (a, b, c, d, e, f, g, h, i, j, k, l) #

(ToField a, ToField b, ToField c, ToField d, ToField e, ToField f, ToField g, ToField h, ToField i, ToField j, ToField k, ToField l) => ToRow (a, b, c, d, e, f, g, h, i, j, k, l) Source # 
Instance details

Methods

toRow :: (a, b, c, d, e, f, g, h, i, j, k, l) -> [SQLData] #