LLDB mainline
|
A class to manage flags. More...
#include "lldb/Utility/Flags.h"
Public Types | |
typedef uint32_t | ValueType |
The value type for flags is a 32 bit unsigned integer type. |
Public Member Functions | |
Flags (ValueType flags=0) | |
Construct with initial flag bit values. | |
ValueType | Get () const |
Get accessor for all flags. | |
size_t | GetBitSize () const |
Return the number of flags that can be represented in this object. | |
void | Reset (ValueType flags) |
Set accessor for all flags. | |
ValueType | Clear (ValueType mask=~static_cast< ValueType >(0)) |
Clear one or more flags. | |
ValueType | Set (ValueType mask) |
Set one or more flags by logical OR'ing mask with the current flags. | |
bool | AllSet (ValueType mask) const |
Test if all bits in mask are 1 in the current flags. | |
bool | AnySet (ValueType mask) const |
Test one or more flags. | |
bool | Test (ValueType bit) const |
Test a single flag bit. | |
bool | AllClear (ValueType mask) const |
Test if all bits in mask are clear. | |
bool | AnyClear (ValueType mask) const |
bool | IsClear (ValueType bit) const |
Test a single flag bit to see if it is clear (zero). |
Protected Attributes | |
ValueType | m_flags |
The flags. |
A class to manage flags.
The Flags class managed flag bits and allows testing and modification of individual or multiple flag bits.
typedef uint32_t lldb_private::Flags::ValueType |
|
inline |
Construct with initial flag bit values.
Constructs this object with mask as the initial value for all of the flags.
[in] | flags | The initial value for all flags. |
Definition at line 34 of file Flags.h.
References m_flags.
Referenced by lldb_private::Section::Section(), and lldb_private::Section::Section().
Test if all bits in mask are clear.
Definition at line 103 of file Flags.h.
References m_flags.
Referenced by DerefToNSErrorPointer(), ExtractFields(), lldb_private::ValueObject::GetValueForExpressionPath_Impl(), and IsPointerValue().
Test if all bits in mask are 1 in the current flags.
Definition at line 83 of file Flags.h.
References m_flags.
Referenced by DerefToNSErrorPointer(), lldb_private::AppleObjCRuntime::FixUpDynamicType(), lldb_private::GNUstepObjCRuntime::FixUpDynamicType(), and lldb_private::ItaniumABILanguageRuntime::FixUpDynamicType().
Test one or more flags.
Definition at line 90 of file Flags.h.
References m_flags.
Referenced by lldb_private::ValueObject::DumpPrintableRepresentation(), lldb_private::StructuredDataDarwinLog::FilterLaunchInfo(), lldb_private::ValueObject::HasSpecialPrintableRepresentation(), lldb_private::ValueObject::IsCStringContainer(), lldb_private::TypeSystemClang::IsCStringType(), IsPointerValue(), lldb_private::ValueObject::ReadPointedString(), and lldb_private::ValueObjectChild::UpdateValue().
Clear one or more flags.
[in] | mask | A bitfield containing one or more flags. |
Definition at line 61 of file Flags.h.
References m_flags.
Referenced by lldb_private::AppleThreadPlanStepThroughDirectDispatch::AppleThreadPlanStepThroughDirectDispatch(), lldb_private::PlatformQemuUser::DebugProcess(), lldb_private::TypePayloadClang::SetIsCompleteObjCClass(), lldb_private::ThreadPlanStepInRange::SetupAvoidNoDebug(), lldb_private::ThreadPlanStepOut::SetupAvoidNoDebug(), and lldb_private::ThreadPlanStepOverRange::SetupAvoidNoDebug().
|
inline |
Get accessor for all flags.
Definition at line 40 of file Flags.h.
References m_flags.
Referenced by lldb_private::CommandObject::CheckRequirements(), lldb_private::process_gdb_remote::ProcessGDBRemote::DoLaunch(), lldb_private::Section::Dump(), and ObjectFileELF::ReadSectionData().
|
inline |
Test a single flag bit to see if it is clear (zero).
Definition at line 111 of file Flags.h.
References lldb_private::bit(), and m_flags.
Referenced by lldb_private::formatters::NSArraySyntheticFrontEndCreator(), lldb_private::formatters::NSDictionarySyntheticFrontEndCreator(), and lldb_private::formatters::NSSetSyntheticFrontEndCreator().
|
inline |
Set accessor for all flags.
[in] | flags | The bits with which to replace all of the current flags. |
Definition at line 52 of file Flags.h.
References m_flags.
Referenced by lldb_private::ValueObject::GetValueForExpressionPath_Impl().
Set one or more flags by logical OR'ing mask with the current flags.
[in] | mask | A bitfield containing one or more flags. |
Definition at line 73 of file Flags.h.
References m_flags.
Referenced by CommandObjectScriptingObjectParsed::CommandObjectScriptingObjectParsed(), RegisterContextCorePOSIX_arm64::Create(), RegisterContextCorePOSIX_riscv64::Create(), lldb_private::BreakpointOptions::CreateFromStructuredData(), lldb_private::Platform::DebugProcess(), lldb_private::PlatformAppleSimulator::DebugProcess(), lldb_private::PlatformWindows::DebugProcess(), PlatformPOSIX::DebugProcess(), lldb_private::Target::Launch(), lldb_private::Platform::LaunchProcess(), lldb_private::AppleThreadPlanStepThroughDirectDispatch::SetFlagsToDefault(), lldb_private::ThreadPlanStepInRange::SetFlagsToDefault(), lldb_private::ThreadPlanStepOut::SetFlagsToDefault(), lldb_private::ThreadPlanStepOverRange::SetFlagsToDefault(), lldb_private::TypePayloadClang::SetIsCompleteObjCClass(), lldb_private::ThreadPlanStepInRange::SetupAvoidNoDebug(), lldb_private::ThreadPlanStepOut::SetupAvoidNoDebug(), and lldb_private::ThreadPlanStepOverRange::SetupAvoidNoDebug().
Test a single flag bit.
Definition at line 96 of file Flags.h.
References lldb_private::bit(), and m_flags.
Referenced by ABISysV_riscv::CallFrameAddressIsValid(), ABISysV_riscv::CodeAddressIsValid(), lldb_private::BreakpointOptions::CopyOverSetOptions(), lldb_private::ThreadPlanShouldStopHere::DefaultShouldStopHereCallback(), lldb_private::ThreadPlanShouldStopHere::DefaultStepFromHereCallback(), ProcessElfCore::DoGetMemoryRegionInfo(), ProcessMachCore::DoGetMemoryRegionInfo(), lldb_private::ValueObject::DumpPrintableRepresentation(), lldb_private::CommandInterpreter::EchoCommandNonInteractive(), lldb_private::Target::FinalizeFileActions(), lldb_private::TypeFormatImpl_Format::FormatObject(), GetPosixspawnFlags(), lldb_private::platform_linux::PlatformLinux::GetResumeCountForLaunchInfo(), lldb_private::platform_netbsd::PlatformNetBSD::GetResumeCountForLaunchInfo(), lldb_private::ValueObject::GetValueForExpressionPath_Impl(), lldb_private::ValueObject::HasSpecialPrintableRepresentation(), lldb_private::CommandInterpreter::IOHandlerInputComplete(), lldb_private::TypePayloadClang::IsCompleteObjCClass(), lldb_private::ValueObject::IsCStringContainer(), lldb_private::TypeSystemClang::IsCStringType(), lldb_private::Process::Launch(), lldb_private::Target::Launch(), lldb_private::MonitoringProcessLauncher::LaunchProcess(), lldb_private::Platform::LaunchProcess(), lldb_private::platform_gdb_server::PlatformRemoteGDBServer::LaunchProcess(), lldb_private::ProcessDebugger::LaunchProcess(), lldb_private::ProcessLauncherWindows::LaunchProcess(), LaunchProcessPosixSpawn(), ParseTrieEntries(), lldb_private::ValueObject::ReadPointedString(), ObjectFileELF::ReadSectionData(), lldb_private::TargetProperties::SetProcessLaunchInfo(), CoreSimulatorSupport::Device::Spawn(), and lldb_private::Log::WriteHeader().
|
protected |