1234567891011121314151617181920212223242526272829303132333435363738394041 |
- -ifndef(N2Z_HRL).
- -define(N2Z_HRL, true).
- -include_lib("kernel/include/logger.hrl").
- -define(LOG_EXCEPTION(E, R, S), ?LOG_ERROR(#{exception => E, reason => R, stack => S})).
- -record(pi, { name :: term(),
- table :: atom(),
- sup :: atom(),
- module :: atom(),
- state :: term() }).
- -record(cx, { handlers = [] :: list({atom(),atom()}),
- actions = [] :: list(tuple()),
- req = [] :: [] | term(),
- module = [] :: [] | atom() | list(),
- lang = [] :: [] | atom(),
- path = [] :: [] | binary(),
- session = [] :: [] | binary(),
- token = [] :: [] | binary(),
- formatter = bert :: bert | json | atom(),
- params = [] :: [] | list(tuple()) | binary() | list(),
- 'node' = [] :: [] | atom() | list(),
- client_pid= [] :: [] | term(),
- state = [] :: [] | term(),
- from = [] :: [] | binary(),
- vsn = [] :: [] | binary() }).
- %-define(CTX(ClientId), n2z:cache(ClientId)).
- %-define(REQ(ClientId), (n2z:cache(ClientId))#cx.req).
- % Nitrogen Protocol
- -include_lib("nitro/include/proto.hrl").
- -endif.
|