BinaryNinja::Settings Class Reference

Public Member Functions

 Settings (BNSettings *settings)
 
virtual ~Settings ()
 
void SetResourceId (const std::string &resourceId="")
 
bool RegisterGroup (const std::string &group, const std::string &title)
 
bool RegisterSetting (const std::string &key, const std::string &properties)
 
bool Contains (const std::string &key)
 
bool IsEmpty ()
 
std::vector< std::string > Keys ()
 
template<typename T >
QueryProperty (const std::string &key, const std::string &property)
 
bool UpdateProperty (const std::string &key, const std::string &property)
 
bool UpdateProperty (const std::string &key, const std::string &property, bool value)
 
bool UpdateProperty (const std::string &key, const std::string &property, double value)
 
bool UpdateProperty (const std::string &key, const std::string &property, int value)
 
bool UpdateProperty (const std::string &key, const std::string &property, int64_t value)
 
bool UpdateProperty (const std::string &key, const std::string &property, uint64_t value)
 
bool UpdateProperty (const std::string &key, const std::string &property, const char *value)
 
bool UpdateProperty (const std::string &key, const std::string &property, const std::string &value)
 
bool UpdateProperty (const std::string &key, const std::string &property, const std::vector< std::string > &value)
 
bool DeserializeSchema (const std::string &schema, BNSettingsScope scope=SettingsAutoScope, bool merge=true)
 
std::string SerializeSchema ()
 
bool DeserializeSettings (const std::string &contents, Ref< BinaryView > view=nullptr, BNSettingsScope scope=SettingsAutoScope)
 
std::string SerializeSettings (Ref< BinaryView > view=nullptr, BNSettingsScope scope=SettingsAutoScope)
 
bool Reset (const std::string &key, Ref< BinaryView > view=nullptr, BNSettingsScope scope=SettingsAutoScope)
 
bool ResetAll (Ref< BinaryView > view=nullptr, BNSettingsScope scope=SettingsAutoScope, bool schemaOnly=true)
 
template<typename T >
Get (const std::string &key, Ref< BinaryView > view=nullptr, BNSettingsScope *scope=nullptr)
 
std::string GetJson (const std::string &key, Ref< BinaryView > view=nullptr, BNSettingsScope *scope=nullptr)
 
bool Set (const std::string &key, bool value, Ref< BinaryView > view=nullptr, BNSettingsScope scope=SettingsAutoScope)
 
bool Set (const std::string &key, double value, Ref< BinaryView > view=nullptr, BNSettingsScope scope=SettingsAutoScope)
 
bool Set (const std::string &key, int value, Ref< BinaryView > view=nullptr, BNSettingsScope scope=SettingsAutoScope)
 
bool Set (const std::string &key, int64_t value, Ref< BinaryView > view=nullptr, BNSettingsScope scope=SettingsAutoScope)
 
bool Set (const std::string &key, uint64_t value, Ref< BinaryView > view=nullptr, BNSettingsScope scope=SettingsAutoScope)
 
bool Set (const std::string &key, const char *value, Ref< BinaryView > view=nullptr, BNSettingsScope scope=SettingsAutoScope)
 
bool Set (const std::string &key, const std::string &value, Ref< BinaryView > view=nullptr, BNSettingsScope scope=SettingsAutoScope)
 
bool Set (const std::string &key, const std::vector< std::string > &value, Ref< BinaryView > view=nullptr, BNSettingsScope scope=SettingsAutoScope)
 
bool SetJson (const std::string &key, const std::string &value, Ref< BinaryView > view=nullptr, BNSettingsScope scope=SettingsAutoScope)
 
template<>
bool Get (const std::string &key, Ref< BinaryView > view, BNSettingsScope *scope)
 
template<>
double Get (const std::string &key, Ref< BinaryView > view, BNSettingsScope *scope)
 
template<>
int64_t Get (const std::string &key, Ref< BinaryView > view, BNSettingsScope *scope)
 
template<>
uint64_t Get (const std::string &key, Ref< BinaryView > view, BNSettingsScope *scope)
 
template<>
vector< string > QueryProperty (const string &key, const string &property)
 
template<>
bool Get (const string &key, Ref< BinaryView > view, BNSettingsScope *scope)
 
template<>
double Get (const string &key, Ref< BinaryView > view, BNSettingsScope *scope)
 
template<>
int64_t Get (const string &key, Ref< BinaryView > view, BNSettingsScope *scope)
 
template<>
uint64_t Get (const string &key, Ref< BinaryView > view, BNSettingsScope *scope)
 
template<>
string Get (const string &key, Ref< BinaryView > view, BNSettingsScope *scope)
 
template<>
vector< string > Get (const string &key, Ref< BinaryView > view, BNSettingsScope *scope)
 
- Public Member Functions inherited from BinaryNinja::CoreRefCountObject< BNSettings, BNNewSettingsReference, BNFreeSettings >
 CoreRefCountObject ()
 
virtual ~CoreRefCountObject ()
 
BNSettings * GetObject () const
 
void AddRef ()
 
void Release ()
 
void AddRefForRegistration ()
 
void ReleaseForRegistration ()
 

Static Public Member Functions

static Ref< SettingsInstance (const std::string &schemaId="")
 
- Static Public Member Functions inherited from BinaryNinja::CoreRefCountObject< BNSettings, BNNewSettingsReference, BNFreeSettings >
static BNSettings * GetObject (CoreRefCountObject *obj)
 

Additional Inherited Members

- Public Attributes inherited from BinaryNinja::CoreRefCountObject< BNSettings, BNNewSettingsReference, BNFreeSettings >
std::atomic< int > m_refs
 
bool m_registeredRef
 
BNSettings * m_object
 

Constructor & Destructor Documentation

◆ Settings()

Settings::Settings ( BNSettings *  settings)

◆ ~Settings()

virtual BinaryNinja::Settings::~Settings ( )
inlinevirtual

Member Function Documentation

◆ Contains()

bool Settings::Contains ( const std::string &  key)

◆ DeserializeSchema()

bool Settings::DeserializeSchema ( const std::string &  schema,
BNSettingsScope  scope = SettingsAutoScope,
bool  merge = true 
)

◆ DeserializeSettings()

bool Settings::DeserializeSettings ( const std::string &  contents,
Ref< BinaryView view = nullptr,
BNSettingsScope  scope = SettingsAutoScope 
)

◆ Get() [1/11]

template<>
bool BinaryNinja::Settings::Get ( const std::string &  key,
Ref< BinaryView view,
BNSettingsScope scope 
)

◆ Get() [2/11]

template<>
double BinaryNinja::Settings::Get ( const std::string &  key,
Ref< BinaryView view,
BNSettingsScope scope 
)

◆ Get() [3/11]

template<>
int64_t BinaryNinja::Settings::Get ( const std::string &  key,
Ref< BinaryView view,
BNSettingsScope scope 
)

◆ Get() [4/11]

template<>
uint64_t BinaryNinja::Settings::Get ( const std::string &  key,
Ref< BinaryView view,
BNSettingsScope scope 
)

◆ Get() [5/11]

template<typename T >
T BinaryNinja::Settings::Get ( const std::string &  key,
Ref< BinaryView view = nullptr,
BNSettingsScope scope = nullptr 
)

◆ Get() [6/11]

template<>
bool BinaryNinja::Settings::Get ( const string &  key,
Ref< BinaryView view,
BNSettingsScope scope 
)

◆ Get() [7/11]

template<>
double BinaryNinja::Settings::Get ( const string &  key,
Ref< BinaryView view,
BNSettingsScope scope 
)

◆ Get() [8/11]

template<>
int64_t BinaryNinja::Settings::Get ( const string &  key,
Ref< BinaryView view,
BNSettingsScope scope 
)

◆ Get() [9/11]

template<>
uint64_t BinaryNinja::Settings::Get ( const string &  key,
Ref< BinaryView view,
BNSettingsScope scope 
)

◆ Get() [10/11]

template<>
vector< string > BinaryNinja::Settings::Get ( const string &  key,
Ref< BinaryView view,
BNSettingsScope scope 
)

◆ Get() [11/11]

template<>
string BinaryNinja::Settings::Get ( const string &  key,
Ref< BinaryView view,
BNSettingsScope scope 
)

◆ GetJson()

string Settings::GetJson ( const std::string &  key,
Ref< BinaryView view = nullptr,
BNSettingsScope scope = nullptr 
)

◆ Instance()

Ref< Settings > Settings::Instance ( const std::string &  schemaId = "")
static

◆ IsEmpty()

bool Settings::IsEmpty ( )

◆ Keys()

vector< string > Settings::Keys ( )

◆ QueryProperty() [1/2]

template<typename T >
T BinaryNinja::Settings::QueryProperty ( const std::string &  key,
const std::string &  property 
)

◆ QueryProperty() [2/2]

template<>
vector< string > BinaryNinja::Settings::QueryProperty ( const string &  key,
const string &  property 
)

◆ RegisterGroup()

bool Settings::RegisterGroup ( const std::string &  group,
const std::string &  title 
)

◆ RegisterSetting()

bool Settings::RegisterSetting ( const std::string &  key,
const std::string &  properties 
)

◆ Reset()

bool Settings::Reset ( const std::string &  key,
Ref< BinaryView view = nullptr,
BNSettingsScope  scope = SettingsAutoScope 
)

◆ ResetAll()

bool Settings::ResetAll ( Ref< BinaryView view = nullptr,
BNSettingsScope  scope = SettingsAutoScope,
bool  schemaOnly = true 
)

◆ SerializeSchema()

string Settings::SerializeSchema ( )

◆ SerializeSettings()

string Settings::SerializeSettings ( Ref< BinaryView view = nullptr,
BNSettingsScope  scope = SettingsAutoScope 
)

◆ Set() [1/8]

bool BinaryNinja::Settings::Set ( const std::string &  key,
bool  value,
Ref< BinaryView view = nullptr,
BNSettingsScope  scope = SettingsAutoScope 
)

◆ Set() [2/8]

bool BinaryNinja::Settings::Set ( const std::string &  key,
const char *  value,
Ref< BinaryView view = nullptr,
BNSettingsScope  scope = SettingsAutoScope 
)

◆ Set() [3/8]

bool BinaryNinja::Settings::Set ( const std::string &  key,
const std::string &  value,
Ref< BinaryView view = nullptr,
BNSettingsScope  scope = SettingsAutoScope 
)

◆ Set() [4/8]

bool BinaryNinja::Settings::Set ( const std::string &  key,
const std::vector< std::string > &  value,
Ref< BinaryView view = nullptr,
BNSettingsScope  scope = SettingsAutoScope 
)

◆ Set() [5/8]

bool BinaryNinja::Settings::Set ( const std::string &  key,
double  value,
Ref< BinaryView view = nullptr,
BNSettingsScope  scope = SettingsAutoScope 
)

◆ Set() [6/8]

bool BinaryNinja::Settings::Set ( const std::string &  key,
int  value,
Ref< BinaryView view = nullptr,
BNSettingsScope  scope = SettingsAutoScope 
)

◆ Set() [7/8]

bool BinaryNinja::Settings::Set ( const std::string &  key,
int64_t  value,
Ref< BinaryView view = nullptr,
BNSettingsScope  scope = SettingsAutoScope 
)

◆ Set() [8/8]

bool BinaryNinja::Settings::Set ( const std::string &  key,
uint64_t  value,
Ref< BinaryView view = nullptr,
BNSettingsScope  scope = SettingsAutoScope 
)

◆ SetJson()

bool Settings::SetJson ( const std::string &  key,
const std::string &  value,
Ref< BinaryView view = nullptr,
BNSettingsScope  scope = SettingsAutoScope 
)

◆ SetResourceId()

void Settings::SetResourceId ( const std::string &  resourceId = "")

◆ UpdateProperty() [1/9]

bool Settings::UpdateProperty ( const std::string &  key,
const std::string &  property 
)

◆ UpdateProperty() [2/9]

bool Settings::UpdateProperty ( const std::string &  key,
const std::string &  property,
bool  value 
)

◆ UpdateProperty() [3/9]

bool Settings::UpdateProperty ( const std::string &  key,
const std::string &  property,
const char *  value 
)

◆ UpdateProperty() [4/9]

bool Settings::UpdateProperty ( const std::string &  key,
const std::string &  property,
const std::string &  value 
)

◆ UpdateProperty() [5/9]

bool Settings::UpdateProperty ( const std::string &  key,
const std::string &  property,
const std::vector< std::string > &  value 
)

◆ UpdateProperty() [6/9]

bool Settings::UpdateProperty ( const std::string &  key,
const std::string &  property,
double  value 
)

◆ UpdateProperty() [7/9]

bool Settings::UpdateProperty ( const std::string &  key,
const std::string &  property,
int  value 
)

◆ UpdateProperty() [8/9]

bool Settings::UpdateProperty ( const std::string &  key,
const std::string &  property,
int64_t  value 
)

◆ UpdateProperty() [9/9]

bool Settings::UpdateProperty ( const std::string &  key,
const std::string &  property,
uint64_t  value 
)

The documentation for this class was generated from the following files: