documint.session
Documint sessions. `ISessionFactory` implements the public API for creation `ISession`s, which in turn implement the public API for interacting with sessions.
ISession
protocol
Session.
members
allocate-thunk
(allocate-thunk this thunk)Allocate a `IStorageEntry` for a thunk.
destroy
(destroy this)Destroy this session and its storage.
get-content
(get-content this content-id)Retrieve the content of an entry from storage for this session. Responses are a map containing `:stream` and `:content-type` keys, or the response is `nil` if no such content identifier exists.
put-content
(put-content this content-type readable)Create a storage entry.
session-id
(session-id this)Retrieve the identifier for this session.
ISessionFactory
protocol
Session factory.
members
destroy-session
(destroy-session this id)Destroy a session.
get-session
(get-session this id)Retrieve an existing session by `id`.
new-session
(new-session this)Create a new session.
temp-file-session-factory
(temp-file-session-factory)(temp-file-session-factory next-id)(temp-file-session-factory next-id ttl)Create an `ISessionFactory` instance backed by temporary files. Sessions and content for those sessions are not persisted.