View Source PhxJsonRpc.Router.Context behaviour (Phoenix JSON RPC v0.3.3)

Context that provides access to the stored route list, jsonrpc version and schema.

Link to this section Summary

Types

Type represents the list of available routes.

Callbacks

Returns the pre-resolved json-schema.

Returns maximum size of the batch.

Returns the otp application name.

Returns the pre-defined list of routes.

Returns the json rpc version number.

Link to this section Types

@type route_list() :: [{atom(), PhxJsonRpc.Router.MetaData.t()}]

Type represents the list of available routes.

Link to this section Callbacks

@callback get_json_schema() :: map()

Returns the pre-resolved json-schema.

@callback get_max_batch_size() :: pos_integer()

Returns maximum size of the batch.

@callback get_otp_app() :: atom()

Returns the otp application name.

@callback get_routes() :: route_list()

Returns the pre-defined list of routes.

@callback get_version() :: binary()

Returns the json rpc version number.