| Safe Haskell | Safe-Inferred |
|---|---|
| Language | Haskell2010 |
Simplex.FileTransfer.Server.Store
Documentation
Constructors
| FSMemory | |
| FSPostgres |
data SFSType :: FSType -> Type where Source #
Constructors
| SFSMemory :: SFSType 'FSMemory | |
| SFSPostgres :: SFSType 'FSPostgres |
class FileStoreClass s where Source #
Minimal complete definition
newFileStore, closeFileStore, addFile, setFilePath, addRecipient, deleteFile, blockFile, deleteRecipient, getFile, ackFile, expiredFiles, getUsedStorage, getFileCount
Associated Types
type FileStoreConfig s Source #
Methods
newFileStore :: FileStoreConfig s -> IO s Source #
closeFileStore :: s -> IO () Source #
addFile :: s -> SenderId -> FileInfo -> RoundedFileTime -> ServerEntityStatus -> IO (Either XFTPErrorType ()) Source #
setFilePath :: s -> SenderId -> FilePath -> IO (Either XFTPErrorType ()) Source #
addRecipient :: s -> SenderId -> FileRecipient -> IO (Either XFTPErrorType ()) Source #
deleteFile :: s -> SenderId -> IO (Either XFTPErrorType ()) Source #
deleteFiles :: s -> [SenderId] -> IO () Source #
blockFile :: s -> SenderId -> BlockingInfo -> Bool -> IO (Either XFTPErrorType ()) Source #
deleteRecipient :: s -> RecipientId -> FileRec -> IO () Source #
getFile :: s -> SFileParty p -> XFTPFileId -> IO (Either XFTPErrorType (FileRec, APublicAuthKey)) Source #
ackFile :: s -> RecipientId -> IO (Either XFTPErrorType ()) Source #
expiredFiles :: s -> Int64 -> Int -> IO [(SenderId, Maybe FilePath, Word32)] Source #
getUsedStorage :: s -> IO Int64 Source #
getFileCount :: s -> IO Int Source #
Instances
Constructors
| FileRec | |
Fields
| |
data FileRecipient Source #
Constructors
| FileRecipient RecipientId APublicAuthKey |
Instances
| Show FileRecipient Source # | |
Defined in Simplex.FileTransfer.Server.Store Methods showsPrec :: Int -> FileRecipient -> ShowS show :: FileRecipient -> String showList :: [FileRecipient] -> ShowS | |
| StrEncoding FileRecipient Source # | |
Defined in Simplex.FileTransfer.Server.Store Methods strEncode :: FileRecipient -> ByteString Source # strDecode :: ByteString -> Either String FileRecipient Source # strP :: Parser FileRecipient Source # | |
data STMFileStore Source #
Constructors
| STMFileStore | |
Fields
| |
Instances
type RoundedFileTime = RoundedSystemTime 3600 Source #
fileTimePrecision :: Int64 Source #