TAO_DynamicAny  2.3.1
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Public Member Functions | Static Public Member Functions | Private Types | Private Member Functions | Static Private Member Functions | Private Attributes | List of all members
TAO_DynValue_i Class Reference

Implementation of the DynValue class. More...

#include <DynValue_i.h>

Inheritance diagram for TAO_DynValue_i:
Inheritance graph
[legend]
Collaboration diagram for TAO_DynValue_i:
Collaboration graph
[legend]

Public Member Functions

 TAO_DynValue_i (CORBA::Boolean allow_truncation=true)
 Constructor. More...
 
 ~TAO_DynValue_i (void)
 Destructor. More...
 
void init (const CORBA::Any &any)
 Initialize using an Any. More...
 
void init (CORBA::TypeCode_ptr tc, TAO_InputCDR &in)
 Initialize using a TypeCode and an input stream. More...
 
void init (CORBA::TypeCode_ptr tc)
 Initialize using just a TypeCode. More...
 
virtual DynamicAny::FieldName current_member_name (void)
 
virtual CORBA::TCKind current_member_kind (void)
 
virtual
DynamicAny::NameValuePairSeq
get_members (void)
 
virtual void set_members (const DynamicAny::NameValuePairSeq &value)
 
virtual
DynamicAny::NameDynAnyPairSeq
get_members_as_dyn_any (void)
 
virtual void set_members_as_dyn_any (const DynamicAny::NameDynAnyPairSeq &value)
 
virtual void from_any (const CORBA::Any &value)
 
virtual CORBA::Any * to_any (void)
 
virtual CORBA::Boolean equal (DynamicAny::DynAny_ptr dyn_any)
 
virtual void destroy (void)
 
virtual DynamicAny::DynAny_ptr current_component (void)
 
virtual void insert_val (CORBA::ValueBase *value)
 
virtual CORBA::ValueBase * get_val (void)
 
virtual void set_to_value (void)
 
- Public Member Functions inherited from DynamicAny::DynValue
void set_members (in NameValuePairSeq value) raises (TypeMismatch, InvalidValue)
 
void set_members_as_dyn_any (in NameDynAnyPairSeq value) raises (TypeMismatch, InvalidValue)
 
- Public Member Functions inherited from DynamicAny::DynAny
void assign (in DynAny dyn_any) raises (TypeMismatch)
 
void from_any (in any value) raises (TypeMismatch, InvalidValue)
 
boolean equal (in DynAny dyn_any)
 
void insert_boolean (in boolean value) raises (TypeMismatch, InvalidValue)
 
void insert_octet (in octet value) raises (TypeMismatch, InvalidValue)
 
void insert_char (in char value) raises (TypeMismatch, InvalidValue)
 
void insert_short (in short value) raises (TypeMismatch, InvalidValue)
 
void insert_ushort (in unsigned short value) raises (TypeMismatch, InvalidValue)
 
void insert_long (in long value) raises (TypeMismatch, InvalidValue)
 
void insert_ulong (in unsigned long value) raises (TypeMismatch, InvalidValue)
 
void insert_float (in float value) raises (TypeMismatch, InvalidValue)
 
void insert_double (in double value) raises (TypeMismatch, InvalidValue)
 
void insert_string (in string value) raises (TypeMismatch, InvalidValue)
 
void insert_reference (in Object value) raises (TypeMismatch, InvalidValue)
 
void insert_typecode (in CORBA::TypeCode value) raises (TypeMismatch, InvalidValue)
 
void insert_longlong (in long long value) raises (TypeMismatch, InvalidValue)
 
void insert_ulonglong (in unsigned long long value) raises (TypeMismatch, InvalidValue)
 
void insert_longdouble (in long double value) raises (TypeMismatch, InvalidValue)
 
void insert_wchar (in wchar value) raises (TypeMismatch, InvalidValue)
 
void insert_wstring (in wstring value) raises (TypeMismatch, InvalidValue)
 
void insert_any (in any value) raises (TypeMismatch, InvalidValue)
 
void insert_dyn_any (in DynAny value) raises (TypeMismatch, InvalidValue)
 
void insert_val (in ValueBase value) raises (TypeMismatch, InvalidValue)
 
boolean seek (in long index)
 
void insert_abstract (in CORBA::AbstractBase value) raises (TypeMismatch, InvalidValue)
 
void insert_boolean_seq (in CORBA::BooleanSeq value) raises (TypeMismatch, InvalidValue)
 
void insert_octet_seq (in CORBA::OctetSeq value) raises (TypeMismatch, InvalidValue)
 
void insert_char_seq (in CORBA::CharSeq value) raises (TypeMismatch, InvalidValue)
 
void insert_short_seq (in CORBA::ShortSeq value) raises (TypeMismatch, InvalidValue)
 
void insert_ushort_seq (in CORBA::UShortSeq value) raises (TypeMismatch, InvalidValue)
 
void insert_long_seq (in CORBA::LongSeq value) raises (TypeMismatch, InvalidValue)
 
void insert_ulong_seq (in CORBA::ULongSeq value) raises (TypeMismatch, InvalidValue)
 
void insert_float_seq (in CORBA::FloatSeq value) raises (TypeMismatch, InvalidValue)
 
void insert_double_seq (in CORBA::DoubleSeq value) raises (TypeMismatch, InvalidValue)
 
void insert_longlong_seq (in CORBA::LongLongSeq value) raises (TypeMismatch, InvalidValue)
 
void insert_ulonglong_seq (in CORBA::ULongLongSeq value) raises (TypeMismatch, InvalidValue)
 
void insert_longdouble_seq (in CORBA::LongDoubleSeq value) raises (TypeMismatch, InvalidValue)
 
void insert_wchar_seq (in CORBA::WCharSeq value) raises (TypeMismatch, InvalidValue)
 
- Public Member Functions inherited from TAO_DynValueCommon_i
 TAO_DynValueCommon_i (CORBA::Boolean allow_truncation=true)
 Constructor. More...
 
 ~TAO_DynValueCommon_i (void)
 Destructor. More...
 
void init_common (void)
 Called by DynValue and DynValueBox init() functions. More...
 
virtual CORBA::Boolean is_null (void)
 
virtual void set_to_null (void)
 
- Public Member Functions inherited from TAO_DynAny_i
 TAO_DynAny_i (CORBA::Boolean allow_truncation=true)
 Constructor. More...
 
 ~TAO_DynAny_i (void)
 Destructor. More...
 
void init (CORBA::TypeCode_ptr tc)
 Initialize using just a TypeCode. More...
 
void init (const CORBA::Any &any)
 Initialize using an Any. More...
 
- Public Member Functions inherited from TAO_DynCommon
 TAO_DynCommon (CORBA::Boolean allow_truncation)
 Constructor. More...
 
virtual ~TAO_DynCommon (void)
 Destructor. More...
 
virtual CORBA::TypeCode_ptr type (void)
 
virtual void assign (DynamicAny::DynAny_ptr dyn_any)
 
virtual void insert_boolean (CORBA::Boolean value)
 
virtual void insert_octet (CORBA::Octet value)
 
virtual void insert_char (CORBA::Char value)
 
virtual void insert_short (CORBA::Short value)
 
virtual void insert_ushort (CORBA::UShort value)
 
virtual void insert_long (CORBA::Long value)
 
virtual void insert_ulong (CORBA::ULong value)
 
virtual void insert_float (CORBA::Float value)
 
virtual void insert_double (CORBA::Double value)
 
virtual void insert_string (const char *value)
 
virtual void insert_reference (CORBA::Object_ptr value)
 
virtual void insert_typecode (CORBA::TypeCode_ptr value)
 
virtual void insert_longlong (CORBA::LongLong value)
 
virtual void insert_ulonglong (CORBA::ULongLong value)
 
virtual void insert_longdouble (CORBA::LongDouble value)
 
virtual void insert_wchar (CORBA::WChar value)
 
virtual void insert_wstring (const CORBA::WChar *value)
 
virtual void insert_any (const CORBA::Any &value)
 
virtual void insert_dyn_any (DynamicAny::DynAny_ptr value)
 
virtual CORBA::Boolean get_boolean (void)
 
virtual CORBA::Octet get_octet (void)
 
virtual CORBA::Char get_char (void)
 
virtual CORBA::Short get_short (void)
 
virtual CORBA::UShort get_ushort (void)
 
virtual CORBA::Long get_long (void)
 
virtual CORBA::ULong get_ulong (void)
 
virtual CORBA::Float get_float (void)
 
virtual CORBA::Double get_double (void)
 
virtual char * get_string (void)
 
virtual CORBA::Object_ptr get_reference (void)
 
virtual CORBA::TypeCode_ptr get_typecode (void)
 
virtual CORBA::LongLong get_longlong (void)
 
virtual CORBA::ULongLong get_ulonglong (void)
 
virtual CORBA::LongDouble get_longdouble (void)
 
virtual CORBA::WChar get_wchar (void)
 
virtual CORBA::WCharget_wstring (void)
 
virtual CORBA::Any * get_any (void)
 
virtual DynamicAny::DynAny_ptr get_dyn_any (void)
 
virtual CORBA::Boolean seek (CORBA::Long index)
 
virtual void rewind (void)
 
virtual CORBA::Boolean next (void)
 
virtual DynamicAny::DynAny_ptr copy (void)
 
virtual CORBA::ULong component_count (void)
 
virtual void insert_abstract (CORBA::AbstractBase_ptr value)
 
virtual CORBA::AbstractBase_ptr get_abstract (void)
 
virtual void insert_boolean_seq (const CORBA::BooleanSeq &value)
 
virtual void insert_octet_seq (const CORBA::OctetSeq &value)
 
virtual void insert_char_seq (const CORBA::CharSeq &value)
 
virtual void insert_short_seq (const CORBA::ShortSeq &value)
 
virtual void insert_ushort_seq (const CORBA::UShortSeq &value)
 
virtual void insert_long_seq (const CORBA::LongSeq &value)
 
virtual void insert_ulong_seq (const CORBA::ULongSeq &value)
 
virtual void insert_float_seq (const CORBA::FloatSeq &value)
 
virtual void insert_double_seq (const CORBA::DoubleSeq &value)
 
virtual void insert_longlong_seq (const CORBA::LongLongSeq &value)
 
virtual void insert_ulonglong_seq (const CORBA::ULongLongSeq &value)
 
virtual void insert_longdouble_seq (const CORBA::LongDoubleSeq &value)
 
virtual void insert_wchar_seq (const CORBA::WCharSeq &value)
 
virtual CORBA::BooleanSeqget_boolean_seq (void)
 
virtual CORBA::OctetSeqget_octet_seq (void)
 
virtual CORBA::CharSeqget_char_seq (void)
 
virtual CORBA::ShortSeqget_short_seq (void)
 
virtual CORBA::UShortSeqget_ushort_seq (void)
 
virtual CORBA::LongSeqget_long_seq (void)
 
virtual CORBA::ULongSeqget_ulong_seq (void)
 
virtual CORBA::FloatSeqget_float_seq (void)
 
virtual CORBA::DoubleSeqget_double_seq (void)
 
virtual CORBA::LongLongSeqget_longlong_seq (void)
 
virtual CORBA::ULongLongSeqget_ulonglong_seq (void)
 
virtual CORBA::LongDoubleSeqget_longdouble_seq (void)
 
virtual CORBA::WCharSeqget_wchar_seq (void)
 
void set_flag (DynamicAny::DynAny_ptr component, CORBA::Boolean destroying)
 
DynamicAny::DynAny_ptr check_component (CORBA::Boolean isValueType=false)
 
void check_type (CORBA::TypeCode_ptr tc)
 
CORBA::Boolean has_components (void) const
 
CORBA::Boolean destroyed (void) const
 
CORBA::Any & the_any (void)
 
void container_is_destroying (CORBA::Boolean val)
 
void ref_to_component (CORBA::Boolean val)
 
- Public Member Functions inherited from CORBA::Object
virtual TAO::ObjectKey_key (void)
 
virtual CORBA::ULong _hash (CORBA::ULong maximum)
 
virtual CORBA::Boolean _is_equivalent (CORBA::Object_ptr other_obj)
 
virtual CORBA::Boolean _non_existent (void)
 
virtual InterfaceDef_ptr _get_interface (void)
 
virtual CORBA::Object_ptr _get_component (void)
 
virtual char * _repository_id (void)
 
virtual void _create_request (CORBA::Context_ptr ctx, const char *operation, CORBA::NVList_ptr arg_list, CORBA::NamedValue_ptr result, CORBA::Request_ptr &request, CORBA::Flags req_flags)
 
virtual void _create_request (CORBA::Context_ptr ctx, const char *operation, CORBA::NVList_ptr arg_list, CORBA::NamedValue_ptr result, CORBA::ExceptionList_ptr exclist, CORBA::ContextList_ptr ctxtlist, CORBA::Request_ptr &request, CORBA::Flags req_flags)
 
virtual CORBA::Request_ptr _request (const char *operation)
 
virtual CORBA::ORB_ptr _get_orb (void)
 

Static Public Member Functions

static TAO_DynValue_i_narrow (CORBA::Object_ptr obj)
 
- Static Public Member Functions inherited from TAO_DynValueCommon_i
static TAO_DynValueCommon_i_narrow (CORBA::Object_ptr obj)
 
- Static Public Member Functions inherited from TAO_DynAny_i
static TAO_DynAny_i_narrow (CORBA::Object_ptr obj)
 
- Static Public Member Functions inherited from TAO_DynCommon
static bool is_basic_type_seq (CORBA::TypeCode_ptr tc)
 

Private Types

typedef ACE_Array_Base
< CORBA::TypeCode_var
BaseTypesList_t
 List of base types. More...
 

Private Member Functions

void check_typecode (CORBA::TypeCode_ptr tc)
 Check if the typecode is acceptable. More...
 
void init_helper (CORBA::TypeCode_ptr tc)
 
void from_any_helper (const CORBA::Any &any)
 
void to_outputCDR (TAO_OutputCDR &)
 Write the value to the output stream. More...
 
void from_inputCDR (TAO_InputCDR &)
 Read the value from the input stream. More...
 
 TAO_DynValue_i (const TAO_DynValue_i &src)
 
TAO_DynValue_ioperator= (const TAO_DynValue_i &src)
 

Static Private Member Functions

static void get_base_types (CORBA::TypeCode_ptr, BaseTypesList_t &, CORBA::ULong *total_member_count=0)
 
static CORBA::TypeCode_ptr get_correct_base_type (const BaseTypesList_t &base_types, CORBA::ULong &index)
 
static CORBA::TypeCode_ptr get_member_type (const BaseTypesList_t &, CORBA::ULong index)
 
static const char * get_member_name (const BaseTypesList_t &, CORBA::ULong index)
 

Private Attributes

ACE_Array_Base
< DynamicAny::DynAny_var > 
da_members_
 Each component of DynValue and DynValueBox is also a DynAny. More...
 
BaseTypesList_t da_base_types_
 

Additional Inherited Members

- Protected Attributes inherited from TAO_DynValueCommon_i
CORBA::Boolean is_null_
 
- Protected Attributes inherited from TAO_DynCommon
CORBA::Boolean ref_to_component_
 Were we created by current_component()? More...
 
CORBA::Boolean container_is_destroying_
 Flag to let destroy() call by container override the flag above. More...
 
CORBA::Boolean has_components_
 Do we contain other Dynamic Anys? More...
 
CORBA::Boolean destroyed_
 Has destroy() been called on us yet? More...
 
CORBA::Long current_position_
 Slot of the current component (if any). More...
 
CORBA::ULong component_count_
 Number of components, as defined by CORBA 2.4.2. More...
 
CORBA::TypeCode_var type_
 Holder for our type code. More...
 
CORBA::Any any_
 
CORBA::Boolean allow_truncation_
 Are we allowed to truncate any valuetypes in our hyarchy? More...
 

Detailed Description

Implementation of the DynValue class.

Member Typedef Documentation

List of base types.

Constructor & Destructor Documentation

TAO_DynValue_i::TAO_DynValue_i ( CORBA::Boolean  allow_truncation = true)

Constructor.

TAO_DynValue_i::~TAO_DynValue_i ( void  )

Destructor.

TAO_DynValue_i::TAO_DynValue_i ( const TAO_DynValue_i src)
private

These are not implimented! Use copy() or assign() instead of these.

Member Function Documentation

TAO_DynValue_i * TAO_DynValue_i::_narrow ( CORBA::Object_ptr  obj)
static
void TAO_DynValue_i::check_typecode ( CORBA::TypeCode_ptr  tc)
privatevirtual

Check if the typecode is acceptable.

Implements TAO_DynValueCommon_i.

DynamicAny::DynAny_ptr TAO_DynValue_i::current_component ( void  )
virtual

Reimplemented from TAO_DynAny_i.

CORBA::TCKind TAO_DynValue_i::current_member_kind ( void  )
virtual

Implements DynamicAny::DynValue.

DynamicAny::FieldName TAO_DynValue_i::current_member_name ( void  )
virtual

Implements DynamicAny::DynValue.

void TAO_DynValue_i::destroy ( void  )
virtual

Reimplemented from TAO_DynAny_i.

CORBA::Boolean TAO_DynValue_i::equal ( DynamicAny::DynAny_ptr  dyn_any)
virtual

Reimplemented from TAO_DynAny_i.

void TAO_DynValue_i::from_any ( const CORBA::Any &  value)
virtual

Reimplemented from TAO_DynAny_i.

void TAO_DynValue_i::from_any_helper ( const CORBA::Any &  any)
private

Code common to the init(Any) and the member function from_any().

void TAO_DynValue_i::from_inputCDR ( TAO_InputCDR strm)
private

Read the value from the input stream.

void TAO_DynValue_i::get_base_types ( CORBA::TypeCode_ptr  tc,
BaseTypesList_t base_types,
CORBA::ULong total_member_count = 0 
)
staticprivate

Decompose the given TypeCode into its hiarchical list of basetypes. The first element of the list is our actual type, each basetype follows in order backwards down the hiarchy. All types stored in the list are de-aliased. Optionally return the total_member_count of the fully derived type.

CORBA::TypeCode_ptr TAO_DynValue_i::get_correct_base_type ( const BaseTypesList_t base_types,
CORBA::ULong index 
)
staticprivate

Return the unaliased valuetype typecode that corresponds to index (0..total_members-1) from the given hiarchical list of the derived type and it basetypes.

const char * TAO_DynValue_i::get_member_name ( const BaseTypesList_t base_types,
CORBA::ULong  index 
)
staticprivate

Return the member_name at index (0..total_members-1) from the given hiarchical list of the derived type and it basetypes.

CORBA::TypeCode_ptr TAO_DynValue_i::get_member_type ( const BaseTypesList_t base_types,
CORBA::ULong  index 
)
staticprivate

Return the member_type at index (0..total_members-1) from the given hiarchical list of the derived type and it basetypes.

DynamicAny::NameValuePairSeq * TAO_DynValue_i::get_members ( void  )
virtual

Implements DynamicAny::DynValue.

DynamicAny::NameDynAnyPairSeq * TAO_DynValue_i::get_members_as_dyn_any ( void  )
virtual

Implements DynamicAny::DynValue.

CORBA::ValueBase * TAO_DynValue_i::get_val ( void  )
virtual

Implements DynamicAny::DynAny.

void TAO_DynValue_i::init ( const CORBA::Any &  any)

Initialize using an Any.

void TAO_DynValue_i::init ( CORBA::TypeCode_ptr  tc,
TAO_InputCDR in 
)

Initialize using a TypeCode and an input stream.

void TAO_DynValue_i::init ( CORBA::TypeCode_ptr  tc)

Initialize using just a TypeCode.

void TAO_DynValue_i::init_helper ( CORBA::TypeCode_ptr  tc)
private

Common code from the init() functions, initializes the private bits from the given TypeCode

void TAO_DynValue_i::insert_val ( CORBA::ValueBase *  value)
virtual

Reimplemented from TAO_DynCommon.

TAO_DynValue_i& TAO_DynValue_i::operator= ( const TAO_DynValue_i src)
private
void TAO_DynValue_i::set_members ( const DynamicAny::NameValuePairSeq value)
virtual
void TAO_DynValue_i::set_members_as_dyn_any ( const DynamicAny::NameDynAnyPairSeq value)
virtual
void TAO_DynValue_i::set_to_value ( void  )
virtual

Implements TAO_DynValueCommon_i.

CORBA::Any_ptr TAO_DynValue_i::to_any ( void  )
virtual

Reimplemented from TAO_DynAny_i.

void TAO_DynValue_i::to_outputCDR ( TAO_OutputCDR out_cdr)
private

Write the value to the output stream.

Member Data Documentation

BaseTypesList_t TAO_DynValue_i::da_base_types_
private

First element of this is our type, each basetype follows in order backwards down the hiarchy. All types stored are de-aliased.

ACE_Array_Base<DynamicAny::DynAny_var> TAO_DynValue_i::da_members_
private

Each component of DynValue and DynValueBox is also a DynAny.


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