Siena Fast Forwarding Documentation (v. 1.13.0)
Public Member Functions | List of all members
siena::value Class Referenceabstract

interface of a generic value in the Siena data model. More...

#include <types.h>

Inheritance diagram for siena::value:
Inheritance graph
[legend]

Public Member Functions

virtual ~value ()
 virtual destructor
 
virtual type_id type () const =0
 returns the actual type identifier of this value. More...
 
virtual int_t int_value () const =0
 returns this value as an integer. More...
 
virtual string_t string_value () const =0
 returns this value as a string. More...
 
virtual bool_t bool_value () const =0
 returns this value as a boolean. More...
 
virtual double_t double_value () const =0
 returns this value as a double. More...
 

Detailed Description

interface of a generic value in the Siena data model.

A value is a typed value.

Examples:
simple_types.cc.

Member Function Documentation

virtual bool_t siena::value::bool_value ( ) const
pure virtual

returns this value as a boolean.

This method returns this value as a boolean if the actual type (returned by type()) is bool_id. The result is undefined if the actual type is not bool_id.

Examples:
message_iteration.cc.
virtual double_t siena::value::double_value ( ) const
pure virtual

returns this value as a double.

This method returns this value as a boolean if the actual type (returned by type()) is double_id. The result is undefined if the actual type is not double_id.

Examples:
message_iteration.cc.
virtual int_t siena::value::int_value ( ) const
pure virtual

returns this value as an integer.

This method returns this value as an integer if the actual type (returned by type()) is int_id. The result is undefined if the actual type is not int_id.

Examples:
message_iteration.cc.
virtual string_t siena::value::string_value ( ) const
pure virtual

returns this value as a string.

This method returns this value as a string if the actual type (returned by type()) is type_id::string_t. The result is undefined if the actual type is not string_t.

Examples:
message_iteration.cc.
virtual type_id siena::value::type ( ) const
pure virtual

returns the actual type identifier of this value.

See Also
see type_id.
Examples:
message_iteration.cc.