OptionGroupValueObjectDisplay.h 2.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657
  1. //===-- OptionGroupValueObjectDisplay.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. #ifndef LLDB_INTERPRETER_OPTIONGROUPVALUEOBJECTDISPLAY_H
  9. #define LLDB_INTERPRETER_OPTIONGROUPVALUEOBJECTDISPLAY_H
  10. #include "lldb/Core/ValueObject.h"
  11. #include "lldb/Interpreter/Options.h"
  12. namespace lldb_private {
  13. // OptionGroupValueObjectDisplay
  14. class OptionGroupValueObjectDisplay : public OptionGroup {
  15. public:
  16. OptionGroupValueObjectDisplay() = default;
  17. ~OptionGroupValueObjectDisplay() override = default;
  18. llvm::ArrayRef<OptionDefinition> GetDefinitions() override;
  19. Status SetOptionValue(uint32_t option_idx, llvm::StringRef option_value,
  20. ExecutionContext *execution_context) override;
  21. void OptionParsingStarting(ExecutionContext *execution_context) override;
  22. bool AnyOptionWasSet() const {
  23. return show_types || no_summary_depth != 0 || show_location ||
  24. flat_output || use_objc || max_depth != UINT32_MAX ||
  25. ptr_depth != 0 || !use_synth || be_raw || ignore_cap ||
  26. run_validator;
  27. }
  28. DumpValueObjectOptions GetAsDumpOptions(
  29. LanguageRuntimeDescriptionDisplayVerbosity lang_descr_verbosity =
  30. eLanguageRuntimeDescriptionDisplayVerbosityFull,
  31. lldb::Format format = lldb::eFormatDefault,
  32. lldb::TypeSummaryImplSP summary_sp = lldb::TypeSummaryImplSP());
  33. bool show_types : 1, show_location : 1, flat_output : 1, use_objc : 1,
  34. use_synth : 1, be_raw : 1, ignore_cap : 1, run_validator : 1;
  35. uint32_t no_summary_depth;
  36. uint32_t max_depth;
  37. uint32_t ptr_depth;
  38. uint32_t elem_count;
  39. lldb::DynamicValueType use_dynamic;
  40. };
  41. } // namespace lldb_private
  42. #endif // LLDB_INTERPRETER_OPTIONGROUPVALUEOBJECTDISPLAY_H