anchor.diff:                  active_fun :: 'undefined' | logplex_msg_buffer:framing_fun()
                  }).
   
  -%-type pstates() :: 'passive' | 'active'.
  +-type mode() :: 'passive' | 'active'.
  +
   -type rx_msgs() :: {'post', Msg::term()}.
   -type tx_msgs() :: {'logplex_drain_data', pid(), Data::term()}.
   
  
positive.code:     {next_state, passive, S}.
  
  %% @private
  init(S = #state{channel_id = ChannelId}) ->
      logplex_channel:register({channel_id, ChannelId}),
      {ok, passive, S}.
  
  %% @private
  handle_event(_Event, StateName, State) ->
  
negative.code: 
  -export([start_link/2
           ,start_link/1
           ,start_link/4
           ,set_active/2
          ]).
  
  