TAO_Sequence_Extracter_Base Class Reference

#include <Interpreter_Utils.h>

List of all members.

Static Public Member Functions

static CORBA::TCKind sequence_type (CORBA::TypeCode *code)


Detailed Description

Definition at line 83 of file Interpreter_Utils.h.


Member Function Documentation

TAO_BEGIN_VERSIONED_NAMESPACE_DECL CORBA::TCKind TAO_Sequence_Extracter_Base::sequence_type ( CORBA::TypeCode *  code  )  [static]

Definition at line 11 of file Interpreter_Utils.cpp.

References CORBA::tk_alias, CORBA::tk_sequence, and CORBA::tk_void.

Referenced by TAO_Constraint_Evaluator::sequence_does_contain(), and TAO_Constraint_Validator::visit_in().

00012 {
00013   // @@ Seth, why do you use a comma to separate the two statements?
00014   CORBA::TCKind return_value = CORBA::tk_void,
00015   type_kind = type_code->kind ();
00016 
00017   if (type_kind == CORBA::tk_alias
00018       || type_kind == CORBA::tk_sequence)
00019     {
00020       CORBA::TypeCode_var base = CORBA::TypeCode::_duplicate (type_code);
00021 
00022       for (;;)
00023         {
00024           CORBA::TCKind base_kind = base->kind ();
00025 
00026           if (base_kind == CORBA::tk_alias)
00027             {
00028               base = base->content_type ();
00029             }
00030           else
00031             break;
00032         }
00033 
00034       CORBA::TCKind base_kind = base->kind ();
00035 
00036       if (base_kind == CORBA::tk_sequence)
00037         {
00038           base = base->content_type ();
00039 
00040           base_kind = base->kind ();
00041           return_value = base_kind;
00042         }
00043     }
00044 
00045   return return_value;
00046 }


The documentation for this class was generated from the following files:
Generated on Tue Feb 2 17:49:34 2010 for TAO_CosTrader by  doxygen 1.4.7