1 //===-- ConnectionMachPort.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 //===----------------------------------------------------------------------===//
11 #ifndef liblldb_ConnectionMachPort_h_
12 #define liblldb_ConnectionMachPort_h_
15 #include <mach/port.h>
16 #include <mach/kern_return.h>
21 // Other libraries and framework includes
23 #include "lldb/Core/Connection.h"
25 class ConnectionMachPort :
26 public lldb_private::Connection
29 ConnectionMachPort ();
32 ~ConnectionMachPort ();
37 virtual lldb::ConnectionStatus
38 BytesAvailable (uint32_t timeout_usec, lldb_private::Error *error_ptr);
40 virtual lldb::ConnectionStatus
41 Connect (const char *s, lldb_private::Error *error_ptr);
43 virtual lldb::ConnectionStatus
44 Disconnect (lldb_private::Error *error_ptr);
49 uint32_t timeout_usec,
50 lldb::ConnectionStatus &status,
51 lldb_private::Error *error_ptr);
54 Write (const void *src,
56 lldb::ConnectionStatus &status,
57 lldb_private::Error *error_ptr);
59 lldb::ConnectionStatus
60 BootstrapCheckIn (const char *port_name,
61 lldb_private::Error *error_ptr);
63 lldb::ConnectionStatus
64 BootstrapLookup (const char *port_name,
65 lldb_private::Error *error_ptr);
75 Send (const PayloadType &payload);
78 Receive (PayloadType &payload);
88 DISALLOW_COPY_AND_ASSIGN (ConnectionMachPort);
91 #endif // liblldb_ConnectionMachPort_h_
93 #endif // #if defined(__APPLE__)