LLDB mainline
lldb_protocol::mcp::Transport Class Referencefinal

#include <Transport.h>

Inheritance diagram for lldb_protocol::mcp::Transport:
[legend]

Public Member Functions

 Transport (lldb::IOObjectSP in, lldb::IOObjectSP out, LogCallback log_callback={})
virtual ~Transport ()=default
void Log (llvm::StringRef message) override
 Transport (const Transport &)=delete
 Transport is not copyable.
void operator= (const Transport &)=delete
Public Member Functions inherited from lldb_private::JSONTransport< Request, Response, Notification >
 JSONTransport (lldb::IOObjectSP in, lldb::IOObjectSP out)
llvm::Error Send (const Notification &evt) override
 Sends an event, a message that does not require a response.
llvm::Expected< MainLoop::ReadHandleUPRegisterMessageHandler (MainLoop &loop, MessageHandler &handler) override
 RegisterMessageHandler registers the Transport with the given MainLoop and handles any incoming messages using the given MessageHandler.
llvm::Error Write (const llvm::json::Value &message)
Public Member Functions inherited from lldb_private::Transport< Request, Response, Notification >
virtual llvm::Error Send (const Request &)=0
 Sends a request, a message that expects a response.
virtual llvm::Error Send (const Response &)=0
 Sends a response to a specific request.
virtual llvm::Expected< MainLoop::ReadHandleUPRegisterMessageHandler (MainLoop &loop, MessageHandler &handler)=0
 RegisterMessageHandler registers the Transport with the given MainLoop and handles any incoming messages using the given MessageHandler.
auto Logv (const char *Fmt, Ts &&...Vals)

Private Attributes

LogCallback m_log_callback

Additional Inherited Members

Public Types inherited from lldb_private::JSONTransport< Request, Response, Notification >
using MessageHandler
Public Types inherited from lldb_private::Transport< Request, Response, Notification >
using Message
using MessageHandlerSP
Static Public Attributes inherited from lldb_private::JSONTransport< Request, Response, Notification >
static constexpr size_t kReadBufferSize
 Public for testing purposes, otherwise this should be an implementation detail.
Protected Member Functions inherited from lldb_private::JSONRPCTransport< Request, Response, Notification >
std::string Encode (const llvm::json::Value &message) override
llvm::Expected< std::vector< std::string > > Parse () override
Protected Attributes inherited from lldb_private::JSONTransport< Request, Response, Notification >
llvm::SmallString< kReadBufferSizem_buffer
Static Protected Attributes inherited from lldb_private::JSONRPCTransport< Request, Response, Notification >
static constexpr llvm::StringLiteral kMessageSeparator

Detailed Description

Definition at line 27 of file Transport.h.

Constructor & Destructor Documentation

◆ Transport() [1/2]

Transport::Transport ( lldb::IOObjectSP in,
lldb::IOObjectSP out,
LogCallback log_callback = {} )

Definition at line 16 of file Transport.cpp.

References m_log_callback.

Referenced by operator=(), and Transport().

◆ ~Transport()

virtual lldb_protocol::mcp::Transport::~Transport ( )
virtualdefault

◆ Transport() [2/2]

lldb_protocol::mcp::Transport::Transport ( const Transport & )
delete

Transport is not copyable.

References Transport().

Member Function Documentation

◆ Log()

void lldb_protocol::mcp::Transport::Log ( llvm::StringRef message)
overridevirtual

◆ operator=()

void lldb_protocol::mcp::Transport::operator= ( const Transport & )
delete

References Transport().

Member Data Documentation

◆ m_log_callback

LogCallback lldb_protocol::mcp::Transport::m_log_callback
private

Definition at line 43 of file Transport.h.

Referenced by Transport().


The documentation for this class was generated from the following files: