ReactOS 0.4.15-dev-8339-g4028de8
ATL::CStringData Struct Reference

#include <atlsimpstr.h>

Inheritance diagram for ATL::CStringData:
Collaboration diagram for ATL::CStringData:

Public Member Functions

voiddata () noexcept
 
void AddRef () noexcept
 
void Release () noexcept
 
bool IsLocked () const noexcept
 
bool IsShared () const noexcept
 

Public Attributes

IAtlStringMgrpStringMgr
 
int nAllocLength
 
int nDataLength
 
long nRefs
 

Detailed Description

Definition at line 48 of file atlsimpstr.h.

Member Function Documentation

◆ AddRef()

void ATL::CStringData::AddRef ( )
inlinenoexcept

Definition at line 60 of file atlsimpstr.h.

61 {
62 ATLASSERT(nRefs > 0);
64 }
#define ATLASSERT(x)
Definition: CComVariant.cpp:10
long __cdecl _InterlockedIncrement(_Interlocked_operand_ long volatile *_Addend)

Referenced by ATL::CSimpleStringT< BaseType, t_bMFCDLL >::CloneData(), and ATL::CAtlStringMgr::GetNilString().

◆ data()

void * ATL::CStringData::data ( )
inlinenoexcept

Definition at line 55 of file atlsimpstr.h.

56 {
57 return (this + 1);
58 }

Referenced by ATL::CSimpleStringT< BaseType, t_bMFCDLL >::__declspec(), and ATL::CSimpleStringT< BaseType, t_bMFCDLL >::CloneData().

◆ IsLocked()

bool ATL::CStringData::IsLocked ( ) const
inlinenoexcept

Definition at line 76 of file atlsimpstr.h.

77 {
78 return (nRefs < 0);
79 }

Referenced by ATL::CSimpleStringT< BaseType, t_bMFCDLL >::Empty().

◆ IsShared()

bool ATL::CStringData::IsShared ( ) const
inlinenoexcept

Definition at line 81 of file atlsimpstr.h.

82 {
83 return (nRefs > 1);
84 }

Referenced by ATL::CSimpleStringT< BaseType, t_bMFCDLL >::PrepareWrite2().

◆ Release()

void ATL::CStringData::Release ( )
inlinenoexcept

Definition at line 66 of file atlsimpstr.h.

67 {
68 ATLASSERT(nRefs != 0);
69
71 {
72 pStringMgr->Free(this);
73 }
74 }
virtual void Free(_Inout_ CStringData *pData)=0
long __cdecl _InterlockedDecrement(_Interlocked_operand_ long volatile *_Addend)
IAtlStringMgr * pStringMgr
Definition: atlsimpstr.h:50

Referenced by ATL::CSimpleStringT< BaseType, t_bMFCDLL >::__declspec(), and ATL::CSimpleStringT< BaseType, t_bMFCDLL >::Empty().

Member Data Documentation

◆ nAllocLength

◆ nDataLength

◆ nRefs

◆ pStringMgr


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