|
| Any () |
| Creates an empty any type. More...
|
|
template<typename ValueType > |
| Any (const ValueType &value) |
| Creates an Any which stores the init parameter inside. More...
|
|
| Any (const Any &other) |
| Copy constructor, works with empty Anys and initialized Any values. More...
|
|
| ~Any () |
|
Any & | Swap (Any &rhs) |
| Swaps the content of the two Anys. More...
|
|
template<typename ValueType > |
Any & | operator= (const ValueType &rhs) |
| Assignment operator for all types != Any. More...
|
|
Any & | operator= (const Any &rhs) |
| Assignment operator for Any. More...
|
|
bool | Empty () const |
| returns true if the Any is empty More...
|
|
std::string | ToString () const |
| Returns a string representation for the content. More...
|
|
const std::type_info & | Type () const |
| Returns the type information of the stored content. More...
|
|
An Any class represents a general type and is capable of storing any type, supporting type-safe extraction of the internally stored data.
Code taken from the Boost 1.46.1 library. Original copyright by Kevlin Henney. Modified for CppMicroServices.
template<typename ValueType >
ValueType* any_cast |
( |
Any * |
operand | ) |
|
|
friend |
any_cast operator used to extract the ValueType from an Any*.
Will return a pointer to the stored value.
Example Usage:
* MyType* pTmp =
any_cast<MyType*>(pAny)
*
Will return NULL if the cast fails, i.e. types don't match.