ReactOS  0.4.15-dev-5608-gafb953a
XMLStorage::XMLDoubleRef Struct Reference

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

#include <xmlstorage.h>

Collaboration diagram for XMLStorage::XMLDoubleRef:

Public Member Functions

 XMLDoubleRef (XMLNode *node, const XS_String &attr_name, double def=0.)
XMLDoubleRefoperator= (double value)
 operator double () const
void assign (double value)

Protected Attributes


Detailed Description

type converter for numeric data with write access

Definition at line 2137 of file xmlstorage.h.

Constructor & Destructor Documentation

◆ XMLDoubleRef()

XMLStorage::XMLDoubleRef::XMLDoubleRef ( XMLNode node,
const XS_String attr_name,
double  def = 0. 

Definition at line 2139 of file xmlstorage.h.

2140  : _ref((*node)[attr_name])
2141  {
2142  if (_ref.empty())
2143  assign(def);
2144  }
void assign(double value)
Definition: xmlstorage.h:2159
Definition: dlist.c:348

Member Function Documentation

◆ assign()

void XMLStorage::XMLDoubleRef::assign ( double  value)

Definition at line 2159 of file xmlstorage.h.

2160  {
2161  XS_CHAR buffer[32];
2163  _ref.assign(buffer);
2164  }
Definition: pdh_main.c:93
GLuint buffer
Definition: glext.h:5915
void assign(const XS_String &s)
Definition: xmlstorage.h:338
#define XS_snprintf
Definition: xmlstorage.h:247
#define XS_CHAR
Definition: xmlstorage.h:236
#define COUNTOF(b)
Definition: xmlstorage.h:271
Definition: xmlstorage.h:428

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

◆ operator double()

Definition at line 2153 of file xmlstorage.h.

2154  {
2155  LPTSTR end;
2156  return XS_tod(_ref.c_str(), &end);
2157  }
#define XS_tod
Definition: xmlstorage.h:245
Definition: xmlstorage.h:192
GLuint GLuint end
Definition: gl.h:1545

◆ operator=()

Definition at line 2146 of file xmlstorage.h.

2147  {
2148  assign(value);
2150  return *this;
2151  }
Definition: pdh_main.c:93
void assign(double value)
Definition: xmlstorage.h:2159

Member Data Documentation

◆ _ref

XS_String& XMLStorage::XMLDoubleRef::_ref

Definition at line 2167 of file xmlstorage.h.

Referenced by assign(), operator double(), and XMLDoubleRef().

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