View Source Ravix.Documents.Store behaviour (ravix v0.2.2)
Macro to define a RavenDB Repository Store
example
Example
`defmodule Ravix.TestRepo do
use Ravix.Documents.Store
end`
Link to this section Summary
Link to this section Callbacks
@callback close_session(session_id :: binary()) :: :ok | {:error, :not_found}
Closes a RavenDB local session
Returns :ok
if successful or {:error, :not_found}
if the session
is not found
examples
Examples
iex> Ravix.Test.Store.close_session("8945c215-dd67-44da-9a64-2916e0a328d9")
:ok
@callback open_session() :: {:ok, binary()}
Opens a RavenDB local session
Returns a tuple with {:ok, uuid}
if successful or {:error, :not_found}
if the store
is not initialized
examples
Examples
iex> Ravix.Test.Store.open_session
{:ok, "8945c215-dd67-44da-9a64-2916e0a328d9"}