blob: 3ad778c581dd6ae944fd8daccc489810c66c0516 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
|
-module(p11p_app).
-behaviour(application).
-export([start/2, prep_stop/1, stop/1]).
-include("p11p_defs.hrl").
start(_Type, _Args) -> % Args from 'mod' in application spec.
lager:notice("p11p version ~s starting", [p11p:version()]),
{ok, Sup} = p11p_sup:start_link(),
{ok, Sup}.
-spec prep_stop(term()) -> term().
prep_stop(State) ->
lager:debug("p11p: cleaning up"),
p11p_server_sup:cleanup(),
State.
-spec stop([]) -> ok.
stop(_State) ->
lager:info("p11p stopped"),
ok.
%% Private.
|