ReactOS 0.4.15-dev-5667-ged97270
XMLStorage::XMLIntRef Struct Reference

type converter for integer data with write access More...

#include <xmlstorage.h>

Collaboration diagram for XMLStorage::XMLIntRef:

Public Member Functions

 XMLIntRef (XMLNode *node, const XS_String &attr_name, int def=0)
 
XMLIntRefoperator= (int value)
 
 operator int () const
 
void assign (int value)
 

Protected Attributes

XS_String_ref
 

Detailed Description

type converter for integer data with write access

Definition at line 2055 of file xmlstorage.h.

Constructor & Destructor Documentation

◆ XMLIntRef()

XMLStorage::XMLIntRef::XMLIntRef ( XMLNode node,
const XS_String attr_name,
int  def = 0 
)
inline

Definition at line 2057 of file xmlstorage.h.

2058 : _ref((*node)[attr_name])
2059 {
2060 if (_ref.empty())
2061 assign(def);
2062 }
void assign(int value)
Definition: xmlstorage.h:2076
Definition: dlist.c:348

Member Function Documentation

◆ assign()

void XMLStorage::XMLIntRef::assign ( int  value)
inline

Definition at line 2076 of file xmlstorage.h.

2077 {
2078 XS_CHAR buffer[32];
2081 }
GLuint buffer
Definition: glext.h:5915
#define COUNTOF(x)
Definition: utility.h:93
void assign(const XS_String &s)
Definition: xmlstorage.h:338
Definition: pdh_main.c:94
#define XS_CHAR
Definition: xmlstorage.h:236
#define XS_INTFMT
Definition: xmlstorage.h:427
#define XS_snprintf
Definition: xmlstorage.h:247

Referenced by operator=(), and XMLIntRef().

◆ operator int()

XMLStorage::XMLIntRef::operator int ( ) const
inline

Definition at line 2071 of file xmlstorage.h.

2072 {
2073 return XS_toi(_ref.c_str());
2074 }
#define XS_toi
Definition: xmlstorage.h:244

◆ operator=()

XMLIntRef & XMLStorage::XMLIntRef::operator= ( int  value)
inline

Definition at line 2064 of file xmlstorage.h.

2065 {
2066 assign(value);
2067
2068 return *this;
2069 }

Member Data Documentation

◆ _ref

XS_String& XMLStorage::XMLIntRef::_ref
protected

Definition at line 2084 of file xmlstorage.h.

Referenced by assign(), operator int(), and XMLIntRef().


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