1 //===-- StreamGDBRemote.h ----------------------------------------*- C++-*-===//
3 // The LLVM Compiler Infrastructure
5 // This file is distributed under the University of Illinois Open Source
6 // License. See LICENSE.TXT for details.
8 //===----------------------------------------------------------------------===//
10 #ifndef liblldb_StreamGDBRemote_h_
11 #define liblldb_StreamGDBRemote_h_
13 #include "lldb/Utility/StreamString.h" // for StreamString
14 #include "lldb/lldb-enumerations.h" // for ByteOrder
16 #include <stddef.h> // for size_t
17 #include <stdint.h> // for uint32_t
19 namespace lldb_private {
21 class StreamGDBRemote : public StreamString {
25 StreamGDBRemote(uint32_t flags, uint32_t addr_size,
26 lldb::ByteOrder byte_order);
28 ~StreamGDBRemote() override;
30 //------------------------------------------------------------------
31 /// Output a block of data to the stream performing GDB-remote escaping.
36 /// @param[in] src_len
37 /// The amount of data to write.
40 /// Number of bytes written.
41 //------------------------------------------------------------------
42 // TODO: Convert this function to take ArrayRef<uint8_t>
43 int PutEscapedBytes(const void *s, size_t src_len);
46 } // namespace lldb_private
48 #endif // liblldb_StreamGDBRemote_h_