Skip Navigation Links
Skip Navigation LinksHome > ZipArchive > How to Use > API Documentation
The ZipArchive Library
ZipArchiveLib::CBitFlag Struct Reference

#include <BitFlag.h>

Public Member Functions

 CBitFlag ()
 CBitFlag (const CBitFlag &flag)
 CBitFlag (int value)
void Change (int flags, bool set)
bool ChangeWithCheck (int flags, bool set)
void Clear (int flags)
bool ClearWithCheck (int flags)
bool IsSetAll (int flags) const
bool IsSetAny (int flags) const
 operator int () const
CBitFlagoperator= (const CBitFlag &flag)
bool operator== (const CBitFlag &flag)
bool operator== (int value)
void Set (int flags)
bool SetWithCheck (int flags)

Public Attributes

int m_value

Detailed Description

Provides functionality for bit operations on an integer value.

Constructor & Destructor Documentation

◆ CBitFlag() [1/3]

ZipArchiveLib::CBitFlag::CBitFlag ( )
inline

Initializes a new instance of the CBitFlag class.

◆ CBitFlag() [2/3]

ZipArchiveLib::CBitFlag::CBitFlag ( int value)
inline

Initializes a new instance of the CBitFlag class.

Parameters
valueThe initial value.

◆ CBitFlag() [3/3]

ZipArchiveLib::CBitFlag::CBitFlag ( const CBitFlag & flag)
inline

Initializes a new instance of the CBitFlag class.

Parameters
flagThe object to copy the value from.

Member Function Documentation

◆ Change()

void ZipArchiveLib::CBitFlag::Change ( int flags,
bool set )
inline

Changes the given flags.

Parameters
flagsThe flags to change.
setIf true, the flags will be set; otherwise the flags will be cleared.

◆ ChangeWithCheck()

bool ZipArchiveLib::CBitFlag::ChangeWithCheck ( int flags,
bool set )
inline

Changes the given flags and examines if this caused a modification to the current object.

Parameters
flagsThe flags to change.
setIf true, the flags will be set; otherwise the flags will be cleared.
Returns
true, if the operation caused a modification; false otherwise.

◆ Clear()

void ZipArchiveLib::CBitFlag::Clear ( int flags)
inline

Clears the given flags.

Parameters
flagsThe flags to clear.

◆ ClearWithCheck()

bool ZipArchiveLib::CBitFlag::ClearWithCheck ( int flags)
inline

Clears the given flags and examines if this caused a modification to the current object.

Parameters
flagsThe flags to clear.
Returns
true, if the operation caused modification; false otherwise.

◆ IsSetAll()

bool ZipArchiveLib::CBitFlag::IsSetAll ( int flags) const
inline

Returns the value indicating whether all of the given flags are set.

Parameters
flagsThe flags to examine.
Returns
true, if all of the given flags are set; false otherwise.

◆ IsSetAny()

bool ZipArchiveLib::CBitFlag::IsSetAny ( int flags) const
inline

Returns the value indicating whether any of the given flags is set.

Parameters
flagsThe flags to examine.
Returns
true, if any of the given flags is set; false otherwise.

◆ operator int()

ZipArchiveLib::CBitFlag::operator int ( ) const
inline

Returns the current value.

◆ operator=()

CBitFlag & ZipArchiveLib::CBitFlag::operator= ( const CBitFlag & flag)
inline

Assignment operator.

Parameters
flagThe object to copy the value from.
Returns
Reference to this object.

◆ operator==() [1/2]

bool ZipArchiveLib::CBitFlag::operator== ( const CBitFlag & flag)
inline

Equality comparison operator.

Parameters
flagThe object to compare with.
Returns
true if the values are equal; false otherwise.

◆ operator==() [2/2]

bool ZipArchiveLib::CBitFlag::operator== ( int value)
inline

Equality comparison operator.

Parameters
valueThe value to compare with.
Returns
true if the values are equal; false otherwise.

◆ Set()

void ZipArchiveLib::CBitFlag::Set ( int flags)
inline

Sets the given flags.

Parameters
flagsThe flags to set.

◆ SetWithCheck()

bool ZipArchiveLib::CBitFlag::SetWithCheck ( int flags)
inline

Sets the given flags and examines if this caused a modification to the current object.

Parameters
flagsThe flags to set.
Returns
true, if the operation caused modification; false otherwise.

Member Data Documentation

◆ m_value

int ZipArchiveLib::CBitFlag::m_value

The current value.


The documentation for this struct was generated from the following file:
Back To Top Up