1 //===-- CommandObjectScript.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_SOURCE_INTERPRETER_COMMANDOBJECTSCRIPT_H
10 #define LLDB_SOURCE_INTERPRETER_COMMANDOBJECTSCRIPT_H
12 #include "lldb/Interpreter/CommandObject.h"
14 namespace lldb_private
{
16 class CommandObjectScript
: public CommandObjectRaw
{
18 CommandObjectScript(CommandInterpreter
&interpreter
);
19 ~CommandObjectScript() override
;
20 Options
*GetOptions() override
{ return &m_options
; }
22 class CommandOptions
: public Options
{
24 CommandOptions() = default;
25 ~CommandOptions() override
= default;
26 Status
SetOptionValue(uint32_t option_idx
, llvm::StringRef option_arg
,
27 ExecutionContext
*execution_context
) override
;
28 void OptionParsingStarting(ExecutionContext
*execution_context
) override
;
29 llvm::ArrayRef
<OptionDefinition
> GetDefinitions() override
;
30 lldb::ScriptLanguage language
= lldb::eScriptLanguageNone
;
34 void DoExecute(llvm::StringRef command
, CommandReturnObject
&result
) override
;
37 CommandOptions m_options
;
40 } // namespace lldb_private
42 #endif // LLDB_SOURCE_INTERPRETER_COMMANDOBJECTSCRIPT_H