gen_smtp_server (gen_smtp v1.3.1-1)
View SourceSetup ranch socket acceptor for gen_smtp_server_session
Summary
Functions
Return the list of active SMTP session pids.
Start the listener with callback module Module with default options linked to no process.
Start the listener with callback module Module with options Options linked to no process.
Start the listener as a registered process with callback module Module with options Options linked to no process.
Stop the listener pid() Pid with reason normal.
Types
-type options() :: [{domain, string()} | {address, inet:ip4_address()} | {family, inet | inet6} | {port, inet:port_number()} | {protocol, tcp | ssl} | {ranch_opts, ranch:opts()} | {sessionoptions, gen_smtp_server_session:options()}].
-type server_name() :: any().
Functions
-spec sessions(Name :: server_name()) -> [pid()].
Return the list of active SMTP session pids.
Start the listener with callback module Module with default options linked to no process.
-spec start(CallbackModule :: module(), Options :: options()) -> {ok, pid()} | ignore | {error, any()}.
Start the listener with callback module Module with options Options linked to no process.
-spec start(ServerName :: server_name(), CallbackModule :: module(), Options :: options()) -> {ok, pid()} | {error, any()}.
Start the listener as a registered process with callback module Module with options Options linked to no process.
-spec stop(Name :: server_name()) -> ok.
Stop the listener pid() Pid with reason normal.