1 //===-- HostThread.h --------------------------------------------*- C++ -*-===//
3 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4 // See https://llvm.org/LICENSE.txt for license information.
5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
7 //===----------------------------------------------------------------------===//
9 #ifndef lldb_Host_HostThread_h_
10 #define lldb_Host_HostThread_h_
12 #include "lldb/Host/HostNativeThreadForward.h"
13 #include "lldb/Utility/Status.h"
14 #include "lldb/lldb-types.h"
18 namespace lldb_private {
20 class HostNativeThreadBase;
22 /// \class HostInfo HostInfo.h "lldb/Host/HostThread.h"
23 /// A class that represents a thread running inside of a process on the
26 /// HostThread allows querying and manipulation of threads running on the host
32 HostThread(lldb::thread_t thread);
34 Status Join(lldb::thread_result_t *result);
37 lldb::thread_t Release();
39 bool IsJoinable() const;
40 HostNativeThread &GetNativeThread();
41 const HostNativeThread &GetNativeThread() const;
42 lldb::thread_result_t GetResult() const;
44 bool EqualsThread(lldb::thread_t thread) const;
47 std::shared_ptr<HostNativeThreadBase> m_native_thread;