dlex v0.2.2 Dlex.Adapter behaviour

Link to this section Summary

Link to this section Types

Link to this type

conn()
conn() :: term()

Link to this type

host()
host() :: String.t() | atom()

Link to this type

json_lib()
json_lib() :: module()

Link to this type

opts()
opts() :: keyword()

Link to this type

port_number()
port_number() :: integer()

Link to this type

request()
request() :: %{}

Link to this type

result()
result() :: %{}

Link to this type

transaction()
transaction() :: %{}

Link to this section Functions

Link to this macro

__using__(_) (macro)

Use Dlex.Adapter to set the behaviour.

Link to this function

alter(adapter, conn, request, json_lib, opts)

Link to this function

commit_or_abort(adapter, conn, request, json_lib, opts)

Link to this function

connect(adapter, host, port, opts)

Link to this function

disconnect(adapter, conn)

Link to this function

mutate(adapter, conn, request, json_lib, opts)

Link to this function

ping(adapter, conn)

Link to this function

query(adapter, conn, request, json_lib, opts)

Link to this section Callbacks

Link to this callback

alter(conn, request, json_lib, opts)
alter(conn(), request(), json_lib(), opts()) ::
  {:ok, result()} | {:error, term()}

Link to this callback

commit_or_abort(conn, transaction, json_lib, opts)
commit_or_abort(conn(), transaction(), json_lib(), opts()) ::
  {:ok, transaction()} | {:error, term()}

Link to this callback

connect(host, port_number, opts)
connect(host(), port_number(), opts()) :: {:ok, conn()} | {:error, term()}

Link to this callback

disconnect(conn)
disconnect(conn()) :: :ok | {:error, term()}

Link to this callback

mutate(conn, request, json_lib, opts)
mutate(conn(), request(), json_lib(), opts()) ::
  {:ok, result()} | {:error, term()}

Link to this callback

ping(conn)
ping(conn()) :: :ok | {:error, term()}

Link to this callback

query(conn, request, json_lib, opts)
query(conn(), request(), json_lib(), opts()) ::
  {:ok, result()} | {:error, term()}