Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2026-05-10 08:42:43

0001 //===-- StoppointCallbackContext.h ------------------------------*- C++ -*-===//
0002 //
0003 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
0004 // See https://llvm.org/LICENSE.txt for license information.
0005 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
0006 //
0007 //===----------------------------------------------------------------------===//
0008 
0009 #ifndef LLDB_BREAKPOINT_STOPPOINTCALLBACKCONTEXT_H
0010 #define LLDB_BREAKPOINT_STOPPOINTCALLBACKCONTEXT_H
0011 
0012 #include "lldb/Target/ExecutionContext.h"
0013 #include "lldb/lldb-private.h"
0014 
0015 namespace lldb_private {
0016 
0017 /// \class StoppointCallbackContext StoppointCallbackContext.h
0018 /// "lldb/Breakpoint/StoppointCallbackContext.h" Class holds the information
0019 /// that a breakpoint callback needs to evaluate this stop.
0020 
0021 /// General Outline:
0022 /// When we hit a breakpoint we need to package up whatever information is
0023 /// needed to evaluate breakpoint commands and conditions.  This class is the
0024 /// container of that information.
0025 
0026 class StoppointCallbackContext {
0027 public:
0028   StoppointCallbackContext();
0029 
0030   StoppointCallbackContext(Event *event, const ExecutionContext &exe_ctx,
0031                            bool synchronously = false);
0032 
0033   /// Clear the object's state.
0034   ///
0035   /// Sets the event, process and thread to NULL, and the frame index to an
0036   /// invalid value.
0037   void Clear();
0038 
0039   // Member variables
0040   Event *event = nullptr; // This is the event, the callback can modify this to
0041                           // indicate the meaning of the breakpoint hit
0042   ExecutionContextRef
0043       exe_ctx_ref;     // This tells us where we have stopped, what thread.
0044   bool is_synchronous =
0045       false; // Is the callback being executed synchronously with the
0046              // breakpoint,
0047              // or asynchronously as the event is retrieved?
0048 };
0049 
0050 } // namespace lldb_private
0051 
0052 #endif // LLDB_BREAKPOINT_STOPPOINTCALLBACKCONTEXT_H