sptk2 logo
SPTK Home Page
Public Member Functions | List of all members
sptk::WSInteger Class Reference

#include <WSBasicTypes.h>

Inheritance diagram for sptk::WSInteger:
sptk::WSBasicType sptk::WSType

Public Member Functions

 WSInteger ()
 
 WSInteger (const String &name, bool optional)
 
 WSInteger (int _value)
 
String className () const override
 
VariantDataType defaultDataType () const override
 Default data type. More...
 
void load (const xdoc::SNode &attr, bool nullLargeData) override
 
void load (const String &attr) override
 
void load (const Field &field) override
 
WSIntegeroperator= (int64_t _value)
 
WSIntegeroperator= (int _value)
 
 operator int32_t () const
 
 operator int64_t () const
 
 operator uint64_t () const
 
- Public Member Functions inherited from sptk::WSBasicType
 WSBasicType ()=default
 
 WSBasicType (const char *name, bool optional)
 
 WSBasicType (const WSBasicType &other)=default
 
 WSBasicType (WSBasicType &&other) noexcept=default
 
WSBasicTypeoperator= (const WSBasicType &other)
 
WSBasicTypeoperator= (WSBasicType &&other) noexcept
 
bool optional () const
 
void optional (bool opt)
 
void clear () override
 
void load (const xdoc::SNode &attr, bool nullLargeData) override
 
virtual void load (const String &attr)
 
virtual void load (const Field &field)
 
virtual operator String () const
 
String asString () const override
 
auto asInteger () const
 
auto asInt64 () const
 
auto asFloat () const
 
auto asBool () const
 
void setInteger (int32_t _value)
 
void setInt64 (int64_t _value)
 
void setFloat (bool _value)
 
void setBool (bool _value)
 
void setBuffer (const char *buffer, size_t size)
 
bool isNull () const override
 
void throwIfNull (const String &parentTypeName) const
 
size_t dataSize () const
 
VariantDataType dataType () const
 
void setNull ()
 
Variantvalue ()
 
const Variantvalue () const
 
void exportTo (const xdoc::SNode &parent, const char *name=nullptr) const override
 
- Public Member Functions inherited from sptk::WSType
 WSType ()=default
 
 WSType (const char *name)
 
 WSType (const WSType &)=default
 
 WSType (WSType &&) noexcept=default
 
WSTypeoperator= (const WSType &)
 
WSTypeoperator= (WSType &&) noexcept
 
virtual String className () const
 
virtual String name () const
 
virtual void owaspCheck (const String &value)
 
virtual void clear ()=0
 
virtual void load (const xdoc::SNode &attr, bool nullLargeData=false)=0
 
virtual String asString () const
 
virtual bool isNull () const =0
 
virtual void exportTo (const xdoc::SNode &parent, const char *name=nullptr) const =0
 

Additional Inherited Members

- Protected Member Functions inherited from sptk::WSBasicType
void setNull (VariantDataType dataType)
 
virtual VariantDataType defaultDataType () const
 Default data type. More...
 

Detailed Description

Wrapper for WSDL int type

Constructor & Destructor Documentation

◆ WSInteger() [1/3]

sptk::WSInteger::WSInteger ( )
inline

Constructor

References VAR_INT.

◆ WSInteger() [2/3]

sptk::WSInteger::WSInteger ( const String name,
bool  optional 
)
inline

Constructor

Parameters
nameWSDL element name
optionalElement optionality flag

References VAR_INT.

◆ WSInteger() [3/3]

sptk::WSInteger::WSInteger ( int  _value)
inline

Constructor

Parameters
valueValue

Member Function Documentation

◆ className()

String sptk::WSInteger::className ( ) const
inlineoverridevirtual

Return class name

Reimplemented from sptk::WSType.

◆ defaultDataType()

VariantDataType sptk::WSInteger::defaultDataType ( ) const
inlineoverridevirtual

Default data type.

Used in clear operations

Returns
Default data type for the class

Reimplemented from sptk::WSBasicType.

References VAR_INT.

◆ load() [1/3]

void sptk::WSInteger::load ( const Field field)
overridevirtual

Load data from database field

Parameters
fieldDatabase field

Reimplemented from sptk::WSBasicType.

◆ load() [2/3]

void sptk::WSInteger::load ( const String attr)
overridevirtual

Load data from string

Parameters
attrA string

Reimplemented from sptk::WSBasicType.

◆ load() [3/3]

void sptk::WSInteger::load ( const xdoc::SNode &  attr,
bool  nullLargeData 
)
overridevirtual

Load data from XML node

Parameters
attrXML node
nullLargeDataSet null for elements with data size > 256 bytes

Reimplemented from sptk::WSBasicType.

◆ operator int32_t()

sptk::WSInteger::operator int32_t ( ) const
inline

Conversion operator

◆ operator int64_t()

sptk::WSInteger::operator int64_t ( ) const
inline

Conversion operator

◆ operator uint64_t()

sptk::WSInteger::operator uint64_t ( ) const
inline

Conversion operator

◆ operator=() [1/2]

WSInteger & sptk::WSInteger::operator= ( int  _value)
inline

Assignment operation

◆ operator=() [2/2]

WSInteger & sptk::WSInteger::operator= ( int64_t  _value)
inline

Assignment operation


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

Fri Oct 14 2022 09:58:48: SPTK 5.4.1