LLDB mainline
SystemLifetimeManager.h
Go to the documentation of this file.
1//===-- SystemLifetimeManager.h -------------------------------*- C++ -*-===//
2//
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
6//
7//===----------------------------------------------------------------------===//
8
9#ifndef LLDB_INITIALIZATION_SYSTEMLIFETIMEMANAGER_H
10#define LLDB_INITIALIZATION_SYSTEMLIFETIMEMANAGER_H
11
14#include "llvm/Support/Error.h"
15
16#include <memory>
17#include <mutex>
18
19namespace lldb_private {
20
22public:
25
26 llvm::Error Initialize(std::unique_ptr<SystemInitializer> initializer,
27 LoadPluginCallbackType plugin_callback);
28 void Terminate();
29
30private:
31 std::recursive_mutex m_mutex;
32 std::unique_ptr<SystemInitializer> m_initializer;
33 bool m_initialized = false;
34
35 // Noncopyable.
38};
39}
40
41#endif
SystemLifetimeManager(const SystemLifetimeManager &other)=delete
SystemLifetimeManager & operator=(const SystemLifetimeManager &other)=delete
llvm::Error Initialize(std::unique_ptr< SystemInitializer > initializer, LoadPluginCallbackType plugin_callback)
std::unique_ptr< SystemInitializer > m_initializer
A class that represents a running process on the host machine.
Definition: SBAttachInfo.h:14
llvm::sys::DynamicLibrary(* LoadPluginCallbackType)(const lldb::DebuggerSP &debugger_sp, const FileSpec &spec, Status &error)