View Source edb_dap_transport (edb v0.4.0)
Transport layer of the DAP server This module deals with serialization/deserialization, sequencing and other low-level details of the DAP frontend for the edb Erlang debugger.
For the actual handling of requests, etc. see the edb_dap_server module.
Summary
Types
-type action() :: {event, edb_dap:event_type(), edb_dap:arguments()} | {reverse_request, edb_dap:command(), edb_dap:body()} | terminate.
-type state() :: #{io := port(), buffer := binary(), seq := pos_integer()}.
Functions
-spec init(noargs) -> {ok, state()}.
-spec send_event(Event) -> ok when Event :: edb_dap_event:event().
-spec send_response(RequestContext, Response) -> ok when RequestContext :: #{command := edb_dap:command(), seq := edb_dap:seq()}, Response :: edb_dap_request:response(edb_dap:body()).
-spec send_reverse_request(Request) -> ok when Request :: edb_dap_reverse_request:request().
-spec start_link() -> {ok, pid()}.