View Source GenLSP.Communication.Adapter behaviour (gen_lsp v0.10.0)
Behaviour for implementing communication adapters for the GenLSP.Buffer
module to use.
Existing implementations:
Link to this section Summary
Callbacks
Initialize the adapter.
Tells the adapter to begin listening for data.
Read from the client.
Write data to the client.
Link to this section Types
@type state() :: any()
Link to this section Callbacks
Initialize the adapter.
Here you should return any state that should be passed into the other callbacks.
Tells the adapter to begin listening for data.
Read from the client.
This callback should read a packet of data from the client and return it as the second element in the tuple.
The third element can be used to return any data that as already been read from the client but still needs to be parsed into a packet.
Write data to the client.