RDKit: RDKit::RDValue Struct Reference

| RDKit Open-source cheminformatics and machine learning.

- Main Page
- Namespaces
- Classes
- Files

- Class List
- Class Hierarchy
- Class Members

Public Member Functions | Static Public Member Functions | Public Attributes | Static Public Attributes | List of all members
RDKit::RDValue Struct Reference

`#include <RDValue-doublemagic.h>`

## Public Member Functions
| RDValue ()
| RDValue (double number)
| RDValue (float number)
| RDValue (int32_t number)
| RDValue (unsigned int number)
| RDValue (bool number)
| RDValue (boost::any *pointer)
| RDValue (const boost::any &any)
template<class T >
| RDValue (const T &v)
| RDValue (const std::string &v)
| RDValue (const std::vector< double > &v)
| RDValue (const std::vector< float > &v)
| RDValue (const std::vector< int > &v)
| RDValue (const std::vector< unsigned int > &v)
| RDValue (const std::vector< std::string > &v)
boost::uint64_t | getTag () const
template<class T >
T * | ptrCast () const
void | destroy ()
| RDValue ()
| RDValue (double v)
| RDValue (float v)
| RDValue (int v)
| RDValue (unsigned v)
| RDValue (bool v)
| RDValue (boost::any *v)
| RDValue (const boost::any &v)
| RDValue (const std::string &v)
template<class T >
| RDValue (const T &v)
| RDValue (const std::vector< double > &v)
| RDValue (const std::vector< float > &v)
| RDValue (const std::vector< int > &v)
| RDValue (const std::vector< unsigned int > &v)
| RDValue (const std::vector< std::string > &v)
short | getTag () const
template<class T >
T * | ptrCast () const
void | destroy ()

## Static Public Member Functions
static void | cleanup_rdvalue (RDValue v)
static void | cleanup_rdvalue (RDValue &rdvalue)

## Public Attributes
union {
double doubleBits
boost::uint64_t otherBits
}; |
RDTypeTag::detail::Value | value
short | type
short | reserved_tag

## Static Public Attributes
static const boost::uint64_t | TagMask = 0xFFFF000000000000
static const boost::uint64_t | PointerTagMask = 0xFFFF000000000007
static const boost::uint64_t | ApplyMask = 0x0000FFFFFFFFFFFF
static const boost::uint64_t | ApplyPtrMask = 0x0000FFFFFFFFFFF8

## Detailed Description

Definition at line 130 of file RDValue-doublemagic.h.

## Constructor & Destructor Documentation

RDKit::RDValue::RDValue | ( |  | ) |
| inline

Definition at line 142 of file RDValue-doublemagic.h.

RDKit::RDValue::RDValue | ( | double | number | ) |
| inline

Definition at line 144 of file RDValue-doublemagic.h.

References RDKit::RDTypeTag::NaN.

RDKit::RDValue::RDValue | ( | float | number | ) |
| inline

Definition at line 155 of file RDValue-doublemagic.h.

References RDKit::RDTypeTag::FloatTag.

RDKit::RDValue::RDValue | ( | int32_t | number | ) |
| inline

Definition at line 160 of file RDValue-doublemagic.h.

References RDKit::RDTypeTag::IntTag.

RDKit::RDValue::RDValue | ( | unsigned int | number | ) |
| inline

Definition at line 164 of file RDValue-doublemagic.h.

References RDKit::RDTypeTag::UnsignedIntTag.

RDKit::RDValue::RDValue | ( | bool | number | ) |
| inline

Definition at line 168 of file RDValue-doublemagic.h.

References RDKit::RDTypeTag::BoolTag.

RDKit::RDValue::RDValue | ( | boost::any * | pointer | ) |
| inline

Definition at line 172 of file RDValue-doublemagic.h.

References RDKit::RDTypeTag::AnyTag.

RDKit::RDValue::RDValue | ( | const boost::any & | any | ) |
| inline

Definition at line 178 of file RDValue-doublemagic.h.

References RDKit::RDTypeTag::AnyTag.

template<class T >

RDKit::RDValue::RDValue | ( | const T & | v | ) |
| inline

Definition at line 187 of file RDValue-doublemagic.h.

References RDKit::RDTypeTag::AnyTag.

RDKit::RDValue::RDValue | ( | const std::string & | v | ) |
| inline

Definition at line 193 of file RDValue-doublemagic.h.

References RDKit::RDTypeTag::StringTag.

RDKit::RDValue::RDValue | ( | const std::vector< double > & | v | ) |
| inline

Definition at line 199 of file RDValue-doublemagic.h.

References RDKit::RDTypeTag::VecDoubleTag.

RDKit::RDValue::RDValue | ( | const std::vector< float > & | v | ) |
| inline

Definition at line 205 of file RDValue-doublemagic.h.

References RDKit::RDTypeTag::VecFloatTag.

RDKit::RDValue::RDValue | ( | const std::vector< int > & | v | ) |
| inline

Definition at line 211 of file RDValue-doublemagic.h.

References RDKit::RDTypeTag::VecIntTag.

RDKit::RDValue::RDValue | ( | const std::vector< unsigned int > & | v | ) |
| inline

Definition at line 217 of file RDValue-doublemagic.h.

References RDKit::RDTypeTag::VecIntTag, and RDKit::RDTypeTag::VecUnsignedIntTag.

RDKit::RDValue::RDValue | ( | const std::vector< std::string > & | v | ) |
| inline

Definition at line 223 of file RDValue-doublemagic.h.

References RDKit::RDTypeTag::VecStringTag.

RDKit::RDValue::RDValue | ( |  | ) |
| inline

Definition at line 221 of file RDValue-taggedunion.h.

RDKit::RDValue::RDValue | ( | double | v | ) |
| inline

Definition at line 223 of file RDValue-taggedunion.h.

RDKit::RDValue::RDValue | ( | float | v | ) |
| inline

Definition at line 224 of file RDValue-taggedunion.h.

RDKit::RDValue::RDValue | ( | int | v | ) |
| inline

Definition at line 225 of file RDValue-taggedunion.h.

RDKit::RDValue::RDValue | ( | unsigned | v | ) |
| inline

Definition at line 226 of file RDValue-taggedunion.h.

RDKit::RDValue::RDValue | ( | bool | v | ) |
| inline

Definition at line 227 of file RDValue-taggedunion.h.

RDKit::RDValue::RDValue | ( | boost::any * | v | ) |
| inline

Definition at line 229 of file RDValue-taggedunion.h.

RDKit::RDValue::RDValue | ( | const boost::any & | v | ) |
| inline

Definition at line 232 of file RDValue-taggedunion.h.

RDKit::RDValue::RDValue | ( | const std::string & | v | ) |
| inline

Definition at line 234 of file RDValue-taggedunion.h.

template<class T >

RDKit::RDValue::RDValue | ( | const T & | v | ) |
| inline

Definition at line 237 of file RDValue-taggedunion.h.

RDKit::RDValue::RDValue | ( | const std::vector< double > & | v | ) |
| inline

Definition at line 240 of file RDValue-taggedunion.h.

RDKit::RDValue::RDValue | ( | const std::vector< float > & | v | ) |
| inline

Definition at line 242 of file RDValue-taggedunion.h.

RDKit::RDValue::RDValue | ( | const std::vector< int > & | v | ) |
| inline

Definition at line 244 of file RDValue-taggedunion.h.

RDKit::RDValue::RDValue | ( | const std::vector< unsigned int > & | v | ) |
| inline

Definition at line 246 of file RDValue-taggedunion.h.

RDKit::RDValue::RDValue | ( | const std::vector< std::string > & | v | ) |
| inline

Definition at line 249 of file RDValue-taggedunion.h.

## Member Function Documentation

static void RDKit::RDValue::cleanup_rdvalue | ( | RDValue | v | ) |
| inlinestatic

Definition at line 280 of file RDValue-doublemagic.h.

References destroy().

Referenced by RDKit::Dict::clearVal(), RDKit::RDAny::operator=(), RDKit::Dict::reset(), RDKit::Dict::setPODVal(), RDKit::Dict::setVal(), and RDKit::RDAny::~RDAny().

static void RDKit::RDValue::cleanup_rdvalue | ( | RDValue & | rdvalue | ) |
| inlinestatic

Definition at line 295 of file RDValue-taggedunion.h.

References RDKit::RDTypeTag::detail::Value::a, RDKit::RDTypeTag::AnyTag, RDKit::RDTypeTag::detail::Value::b, RDKit::copy_rdvalue(), RDKit::RDTypeTag::detail::Value::d, destroy(), RDKit::RDTypeTag::detail::Value::f, getTag(), RDKit::RDTypeTag::detail::Value::i, ptrCast(), RDKit::rdvalue_cast(), RDKit::rdvalue_is(), RDKit::rdvalue_is< double >(), RDKit::RDTypeTag::detail::Value::s, RDKit::RDTypeTag::StringTag, type, RDKit::RDTypeTag::detail::Value::u, value, RDKit::RDTypeTag::detail::Value::vd, RDKit::RDTypeTag::VecDoubleTag, RDKit::RDTypeTag::VecFloatTag, RDKit::RDTypeTag::VecIntTag, RDKit::RDTypeTag::VecStringTag, RDKit::RDTypeTag::VecUnsignedIntTag, RDKit::RDTypeTag::detail::Value::vf, RDKit::RDTypeTag::detail::Value::vi, RDKit::RDTypeTag::detail::Value::vs, and RDKit::RDTypeTag::detail::Value::vu.

void RDKit::RDValue::destroy | ( |  | ) |
| inline

Definition at line 251 of file RDValue-doublemagic.h.

References RDKit::RDTypeTag::AnyTag, RDKit::RDTypeTag::StringTag, RDKit::RDTypeTag::VecDoubleTag, RDKit::RDTypeTag::VecFloatTag, RDKit::RDTypeTag::VecIntTag, RDKit::RDTypeTag::VecStringTag, and RDKit::RDTypeTag::VecUnsignedIntTag.

Referenced by cleanup_rdvalue(), and RDKit::copy_rdvalue().

void RDKit::RDValue::destroy | ( |  | ) |
| inline

Definition at line 264 of file RDValue-taggedunion.h.

References RDKit::RDTypeTag::detail::Value::a, RDKit::RDTypeTag::AnyTag, RDKit::RDTypeTag::EmptyTag, RDKit::RDTypeTag::detail::Value::s, RDKit::RDTypeTag::StringTag, RDKit::RDTypeTag::detail::Value::vd, RDKit::RDTypeTag::VecDoubleTag, RDKit::RDTypeTag::VecFloatTag, RDKit::RDTypeTag::VecIntTag, RDKit::RDTypeTag::VecStringTag, RDKit::RDTypeTag::VecUnsignedIntTag, RDKit::RDTypeTag::detail::Value::vf, RDKit::RDTypeTag::detail::Value::vi, RDKit::RDTypeTag::detail::Value::vs, and RDKit::RDTypeTag::detail::Value::vu.

boost::uint64_t RDKit::RDValue::getTag | ( |  | ) | const
| inline

Definition at line 229 of file RDValue-doublemagic.h.

References RDKit::RDTypeTag::DoubleTag, RDKit::RDTypeTag::MaxDouble, RDKit::RDTypeTag::NaN, and RDKit::RDTypeTag::PtrTag.

Referenced by cleanup_rdvalue(), RDKit::copy_rdvalue(), RDKit::from_rdany(), RDKit::from_rdvalue(), RDKit::isSerializable(), RDKit::rdvalue_is(), RDKit::rdvalue_tostring(), and RDKit::streamWriteProp().

short RDKit::RDValue::getTag | ( |  | ) | const
| inline

Definition at line 252 of file RDValue-taggedunion.h.

template<class T >

T* RDKit::RDValue::ptrCast | ( |  | ) | const
| inline

Definition at line 243 of file RDValue-doublemagic.h.

Referenced by cleanup_rdvalue(), RDKit::copy_rdvalue(), and RDKit::rdvalue_cast().

template<class T >

T* RDKit::RDValue::ptrCast | ( |  | ) | const
| inline

Definition at line 256 of file RDValue-taggedunion.h.

## Member Data Documentation

union { ... }

const boost::uint64_t RDKit::RDValue::ApplyMask = 0x0000FFFFFFFFFFFF
| static

Definition at line 134 of file RDValue-doublemagic.h.

const boost::uint64_t RDKit::RDValue::ApplyPtrMask = 0x0000FFFFFFFFFFF8
| static

Definition at line 135 of file RDValue-doublemagic.h.

double RDKit::RDValue::doubleBits

Definition at line 138 of file RDValue-doublemagic.h.

boost::uint64_t RDKit::RDValue::otherBits

Definition at line 139 of file RDValue-doublemagic.h.

const boost::uint64_t RDKit::RDValue::PointerTagMask = 0xFFFF000000000007
| static

Definition at line 133 of file RDValue-doublemagic.h.

short RDKit::RDValue::reserved_tag

Definition at line 219 of file RDValue-taggedunion.h.

const boost::uint64_t RDKit::RDValue::TagMask = 0xFFFF000000000000
| static

Definition at line 132 of file RDValue-doublemagic.h.

short RDKit::RDValue::type

Definition at line 218 of file RDValue-taggedunion.h.

Referenced by cleanup_rdvalue().

RDTypeTag::detail::Value RDKit::RDValue::value

Definition at line 217 of file RDValue-taggedunion.h.

Referenced by cleanup_rdvalue().

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

- RDValue-doublemagic.h
- RDValue-taggedunion.h