LLDB  mainline
OptionValueFormatEntity.h
Go to the documentation of this file.
1 //===-- OptionValueFormatEntity.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_OPTIONVALUEFORMATENTITY_H
10 #define LLDB_INTERPRETER_OPTIONVALUEFORMATENTITY_H
11 
12 #include "lldb/Core/FormatEntity.h"
14 
15 namespace lldb_private {
16 
18  : public Cloneable<OptionValueFormatEntity, OptionValue> {
19 public:
20  OptionValueFormatEntity(const char *default_format);
21 
22  ~OptionValueFormatEntity() override = default;
23 
24  // Virtual subclass pure virtual overrides
25 
26  OptionValue::Type GetType() const override { return eTypeFormatEntity; }
27 
28  void DumpValue(const ExecutionContext *exe_ctx, Stream &strm,
29  uint32_t dump_mask) override;
30 
31  Status
32  SetValueFromString(llvm::StringRef value,
34 
35  void Clear() override;
36 
37  void AutoComplete(CommandInterpreter &interpreter,
38  CompletionRequest &request) override;
39 
40  // Subclass specific functions
41 
43 
45 
46  void SetCurrentValue(const FormatEntity::Entry &value) {
47  m_current_entry = value;
48  }
49 
51 
53 
54 protected:
59 };
60 
61 } // namespace lldb_private
62 
63 #endif // LLDB_INTERPRETER_OPTIONVALUEFORMATENTITY_H
lldb_private::OptionValueFormatEntity::AutoComplete
void AutoComplete(CommandInterpreter &interpreter, CompletionRequest &request) override
Definition: OptionValueFormatEntity.cpp:112
lldb_private::ExecutionContext
Definition: ExecutionContext.h:292
lldb_private::OptionValueFormatEntity::Clear
void Clear() override
Definition: OptionValueFormatEntity.cpp:30
lldb_private::OptionValueFormatEntity::GetCurrentValue
const FormatEntity::Entry & GetCurrentValue() const
Definition: OptionValueFormatEntity.h:44
lldb_private::Stream
Definition: Stream.h:28
lldb_private::OptionValueFormatEntity::m_default_format
std::string m_default_format
Definition: OptionValueFormatEntity.h:56
lldb_private::OptionValueFormatEntity::GetDefaultValue
const FormatEntity::Entry & GetDefaultValue() const
Definition: OptionValueFormatEntity.h:52
lldb_private::Cloneable
Definition: Cloneable.h:40
lldb_private::OptionValueFormatEntity::DumpValue
void DumpValue(const ExecutionContext *exe_ctx, Stream &strm, uint32_t dump_mask) override
Definition: OptionValueFormatEntity.cpp:50
OptionValue.h
lldb_private::VarSetOperationType
VarSetOperationType
Settable state variable types.
Definition: lldb-private-enumerations.h:83
lldb_private::OptionValueFormatEntity::GetType
OptionValue::Type GetType() const override
Definition: OptionValueFormatEntity.h:26
lldb_private::CommandInterpreter
Definition: CommandInterpreter.h:214
lldb_private::OptionValueFormatEntity::GetCurrentValue
FormatEntity::Entry & GetCurrentValue()
Definition: OptionValueFormatEntity.h:42
lldb_private::OptionValueFormatEntity::m_current_entry
FormatEntity::Entry m_current_entry
Definition: OptionValueFormatEntity.h:57
lldb_private::OptionValueFormatEntity::~OptionValueFormatEntity
~OptionValueFormatEntity() override=default
string
string(SUBSTRING ${p} 10 -1 pStripped) if($
Definition: Plugins/CMakeLists.txt:40
lldb_private::OptionValueFormatEntity::SetCurrentValue
void SetCurrentValue(const FormatEntity::Entry &value)
Definition: OptionValueFormatEntity.h:46
lldb_private::OptionValueFormatEntity::OptionValueFormatEntity
OptionValueFormatEntity(const char *default_format)
Definition: OptionValueFormatEntity.cpp:18
lldb_private::OptionValueFormatEntity::GetDefaultValue
FormatEntity::Entry & GetDefaultValue()
Definition: OptionValueFormatEntity.h:50
lldb_private::Status
Definition: Status.h:44
lldb_private::OptionValue::Type
Type
Definition: OptionValue.h:26
uint32_t
lldb_private::OptionValueFormatEntity::m_default_entry
FormatEntity::Entry m_default_entry
Definition: OptionValueFormatEntity.h:58
lldb_private::FormatEntity::Entry
Definition: FormatEntity.h:40
FormatEntity.h
lldb_private
A class that represents a running process on the host machine.
Definition: SBCommandInterpreterRunOptions.h:16
lldb_private::OptionValueFormatEntity
Definition: OptionValueFormatEntity.h:17
lldb_private::OptionValue::eTypeFormatEntity
@ eTypeFormatEntity
Definition: OptionValue.h:47
lldb_private::OptionValueFormatEntity::SetValueFromString
Status SetValueFromString(llvm::StringRef value, VarSetOperationType op=eVarSetOperationAssign) override
Definition: OptionValueFormatEntity.cpp:63
lldb_private::OptionValueFormatEntity::m_current_format
std::string m_current_format
Definition: OptionValueFormatEntity.h:55
lldb_private::CompletionRequest
Definition: CompletionRequest.h:100
lldb_private::eVarSetOperationAssign
@ eVarSetOperationAssign
Definition: lldb-private-enumerations.h:90