1//===-- SBStatisticsOptions.cpp -------------------------------------------===//
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#include "lldb/API/SBStatisticsOptions.h"
10#include "lldb/Target/Statistics.h"
11#include "lldb/Utility/Instrumentation.h"
12
13#include "Utils.h"
14
15using namespace lldb;
16using namespace lldb_private;
17
18SBStatisticsOptions::SBStatisticsOptions()
19 : m_opaque_up(new StatisticsOptions()) {
20 LLDB_INSTRUMENT_VA(this);
21}
22
23SBStatisticsOptions::SBStatisticsOptions(const SBStatisticsOptions &rhs) {
24 LLDB_INSTRUMENT_VA(this, rhs);
25
26 m_opaque_up = clone(src: rhs.m_opaque_up);
27}
28
29SBStatisticsOptions::~SBStatisticsOptions() = default;
30
31const SBStatisticsOptions &
32SBStatisticsOptions::operator=(const SBStatisticsOptions &rhs) {
33 LLDB_INSTRUMENT_VA(this, rhs);
34
35 if (this != &rhs)
36 m_opaque_up = clone(src: rhs.m_opaque_up);
37 return *this;
38}
39
40void SBStatisticsOptions::SetSummaryOnly(bool b) {
41 m_opaque_up->SetSummaryOnly(b);
42}
43
44bool SBStatisticsOptions::GetSummaryOnly() {
45 return m_opaque_up->GetSummaryOnly();
46}
47
48void SBStatisticsOptions::SetIncludeTargets(bool b) {
49 m_opaque_up->SetIncludeTargets(b);
50}
51
52bool SBStatisticsOptions::GetIncludeTargets() const {
53 return m_opaque_up->GetIncludeTargets();
54}
55
56void SBStatisticsOptions::SetIncludeModules(bool b) {
57 m_opaque_up->SetIncludeModules(b);
58}
59
60bool SBStatisticsOptions::GetIncludeModules() const {
61 return m_opaque_up->GetIncludeModules();
62}
63
64void SBStatisticsOptions::SetIncludeTranscript(bool b) {
65 m_opaque_up->SetIncludeTranscript(b);
66}
67
68bool SBStatisticsOptions::GetIncludeTranscript() const {
69 return m_opaque_up->GetIncludeTranscript();
70}
71
72void SBStatisticsOptions::SetReportAllAvailableDebugInfo(bool b) {
73 m_opaque_up->SetLoadAllDebugInfo(b);
74}
75
76bool SBStatisticsOptions::GetReportAllAvailableDebugInfo() {
77 return m_opaque_up->GetLoadAllDebugInfo();
78}
79
80const lldb_private::StatisticsOptions &SBStatisticsOptions::ref() const {
81 return *m_opaque_up;
82}
83

Provided by KDAB

Privacy Policy
Learn to use CMake with our Intro Training
Find out more

source code of lldb/source/API/SBStatisticsOptions.cpp