Radix Relay
Hybrid mesh communications with Signal Protocol encryption
Loading...
Searching...
No Matches
radix_relay::tui::processor< Bridge > Struct Template Reference

Text-based user interface processor with REPL. More...

#include <processor.hpp>

Public Member Functions

 processor (std::string node_id, std::string mode, const std::shared_ptr< Bridge > &bridge, const std::shared_ptr< async::async_queue< core::events::raw_command > > &command_queue, const std::shared_ptr< async::async_queue< core::events::display_message > > &display_queue)
 Constructs a TUI processor.
 
 ~processor ()
 
 processor (const processor &)=delete
 
auto operator= (const processor &) -> processor &=delete
 
 processor (processor &&)=delete
 
auto operator= (processor &&) -> processor &=delete
 
auto run () -> void
 Runs the interactive REPL loop.
 
auto stop () -> void
 Stops the TUI processor and message polling thread.
 
auto get_mode () const -> const std::string &
 Returns the current network mode.
 

Detailed Description

template<concepts::signal_bridge Bridge>
struct radix_relay::tui::processor< Bridge >

Text-based user interface processor with REPL.

Template Parameters
BridgeType satisfying the signal_bridge concept

Provides an interactive command-line interface using Replxx for command input, history management, and display message output.

Definition at line 23 of file processor.hpp.

Constructor & Destructor Documentation

◆ processor() [1/3]

template<concepts::signal_bridge Bridge>
radix_relay::tui::processor< Bridge >::processor ( std::string  node_id,
std::string  mode,
const std::shared_ptr< Bridge > &  bridge,
const std::shared_ptr< async::async_queue< core::events::raw_command > > &  command_queue,
const std::shared_ptr< async::async_queue< core::events::display_message > > &  display_queue 
)
inline

Constructs a TUI processor.

Parameters
node_idNode identifier for display
modeNetwork mode (internet/mesh/hybrid)
bridgeSignal Protocol bridge
command_queueQueue for outgoing user commands
display_queueQueue for incoming display messages

Definition at line 34 of file processor.hpp.

◆ ~processor()

template<concepts::signal_bridge Bridge>
radix_relay::tui::processor< Bridge >::~processor ( )
inline

Definition at line 43 of file processor.hpp.

References radix_relay::tui::processor< Bridge >::stop().

◆ processor() [2/3]

template<concepts::signal_bridge Bridge>
radix_relay::tui::processor< Bridge >::processor ( const processor< Bridge > &  )
delete

◆ processor() [3/3]

template<concepts::signal_bridge Bridge>
radix_relay::tui::processor< Bridge >::processor ( processor< Bridge > &&  )
delete

Member Function Documentation

◆ get_mode()

template<concepts::signal_bridge Bridge>
auto radix_relay::tui::processor< Bridge >::get_mode ( ) const -> const std::string &
inline

Returns the current network mode.

Returns
Network mode string (internet/mesh/hybrid)

Definition at line 119 of file processor.hpp.

◆ operator=() [1/2]

template<concepts::signal_bridge Bridge>
auto radix_relay::tui::processor< Bridge >::operator= ( const processor< Bridge > &  ) -> processor &=delete
delete

◆ operator=() [2/2]

template<concepts::signal_bridge Bridge>
auto radix_relay::tui::processor< Bridge >::operator= ( processor< Bridge > &&  ) -> processor &=delete
delete

◆ run()

template<concepts::signal_bridge Bridge>
auto radix_relay::tui::processor< Bridge >::run ( ) -> void
inline

Runs the interactive REPL loop.

Starts message polling thread and processes user input until quit command.

Definition at line 55 of file processor.hpp.

◆ stop()

template<concepts::signal_bridge Bridge>
auto radix_relay::tui::processor< Bridge >::stop ( ) -> void
inline

Stops the TUI processor and message polling thread.

Definition at line 107 of file processor.hpp.

Referenced by radix_relay::tui::processor< Bridge >::~processor().


The documentation for this struct was generated from the following file: