LLDB mainline
ScriptedStopHookInterface.h
Go to the documentation of this file.
1//===-- ScriptedStopHookInterface.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_INTERPRETER_INTERFACES_SCRIPTEDSTOPHOOKINTERFACE_H
10#define LLDB_INTERPRETER_INTERFACES_SCRIPTEDSTOPHOOKINTERFACE_H
11
12#include "lldb/lldb-private.h"
13
14#include "ScriptedInterface.h"
15
16namespace lldb_private {
18public:
19 virtual llvm::Expected<StructuredData::GenericSP>
20 CreatePluginObject(llvm::StringRef class_name, lldb::TargetSP target_sp,
21 const StructuredDataImpl &args_sp) = 0;
22
23 /// "handle_stop" will return a bool with the meaning "should_stop"...
24 /// If nothing is returned, we'll assume we are going to stop.
25 /// Also any errors should return true, since we should stop on error.
26 virtual llvm::Expected<bool> HandleStop(ExecutionContext &exe_ctx,
27 lldb::StreamSP &output_sp) {
28 return true;
29 }
30};
31} // namespace lldb_private
32
33#endif // LLDB_INTERPRETER_INTERFACES_SCRIPTEDSTOPHOOKINTERFACE_H
"lldb/Target/ExecutionContext.h" A class that contains an execution context.
virtual llvm::Expected< bool > HandleStop(ExecutionContext &exe_ctx, lldb::StreamSP &output_sp)
"handle_stop" will return a bool with the meaning "should_stop"... If nothing is returned,...
virtual llvm::Expected< StructuredData::GenericSP > CreatePluginObject(llvm::StringRef class_name, lldb::TargetSP target_sp, const StructuredDataImpl &args_sp)=0
A class that represents a running process on the host machine.
std::shared_ptr< lldb_private::Stream > StreamSP
Definition: lldb-forward.h:432
std::shared_ptr< lldb_private::Target > TargetSP
Definition: lldb-forward.h:448