ALib C++ Library
Library Version: 2412 R0
Documentation generated by doxygen
Loading...
Searching...
No Matches
Bool Struct Reference

Description:

Variable content type used with boolean type "B". When this type is imported, the value is tried to be parsed with the tokens in Configuration::BooleanTokens. If successful, the index of the pair of true/false-tokens is stored in field TokenIndex. When exported back to a configuration file or otherwise serialized or printed, then the right human-readable term, corresponding to the potentially now different Value is used.

Definition at line 219 of file vmeta.hpp.

#include <vmeta.hpp>

Public Field Index:

int8_t TokenIndex = -1
 
bool Value = false
 The boolean value. Defaults to false.
 

Public Method Index:

 operator bool () const
 
bool operator= (bool newValue)
 

Field Details:

◆ TokenIndex

int8_t TokenIndex = -1

The index in the list of tokens found when imported from a string. Can also be set programmatically to force a certain output "format". Defaults to -1 which indicates that the value was not parsed. On exporting, when -1, index 0 is used.

Definition at line 228 of file vmeta.hpp.

◆ Value

bool Value = false

The boolean value. Defaults to false.

Definition at line 222 of file vmeta.hpp.

Method Details:

◆ operator bool()

operator bool ( ) const
inline

Implicit cast operator to bool.

Returns
Returns the stored value.

Definition at line 237 of file vmeta.hpp.

◆ operator=()

bool operator= ( bool newValue)
inline

Assignment operator.

Parameters
newValueThe value to set.
Returns
The new value.

Definition at line 233 of file vmeta.hpp.


The documentation for this struct was generated from the following file: