summaryrefslogtreecommitdiff
path: root/TAO/tao/DynSequence_i.cpp
diff options
context:
space:
mode:
authorbala <balanatarajan@users.noreply.github.com>1999-09-04 01:52:29 +0000
committerbala <balanatarajan@users.noreply.github.com>1999-09-04 01:52:29 +0000
commit07cfd3e989664a20ccbca11b825ee64dda7a806d (patch)
tree6cb5dc3880ac01d49e4deced10402c939b61b594 /TAO/tao/DynSequence_i.cpp
parent9a0d2920d03e7788932be5b7cd39908a5dec766b (diff)
downloadATCD-07cfd3e989664a20ccbca11b825ee64dda7a806d.tar.gz
Changed the methods, member_type, discriminator_type & content_type to return a duplicate
Diffstat (limited to 'TAO/tao/DynSequence_i.cpp')
-rw-r--r--TAO/tao/DynSequence_i.cpp77
1 files changed, 38 insertions, 39 deletions
diff --git a/TAO/tao/DynSequence_i.cpp b/TAO/tao/DynSequence_i.cpp
index 4e67a26769f..fd36be4b4d8 100644
--- a/TAO/tao/DynSequence_i.cpp
+++ b/TAO/tao/DynSequence_i.cpp
@@ -57,7 +57,7 @@ TAO_DynSequence_i::TAO_DynSequence_i (const CORBA_Any& any)
this->da_members_.size (length);
// Get the type of the sequence elments.
- CORBA::TypeCode_ptr field_tc =
+ CORBA::TypeCode_var field_tc =
this->get_element_type (ACE_TRY_ENV);
ACE_TRY_CHECK;
@@ -182,7 +182,7 @@ TAO_DynSequence_i::set_elements (const CORBA_AnySeq& value,
ACE_THROW (CORBA_DynAny::InvalidSeq ());
}
- CORBA::TypeCode_ptr element_type =
+ CORBA::TypeCode_var element_type =
this->get_element_type (ACE_TRY_ENV);
ACE_CHECK;
@@ -305,7 +305,7 @@ TAO_DynSequence_i::from_any (const CORBA_Any& any,
ACE_THROW (CORBA_DynAny::Invalid ());
}
- CORBA::TypeCode_ptr field_tc =
+ CORBA::TypeCode_var field_tc =
this->get_element_type (ACE_TRY_ENV);
ACE_CHECK;
@@ -346,7 +346,7 @@ TAO_DynSequence_i::to_any (CORBA::Environment& ACE_TRY_ENV)
out_cdr.write_ulong (this->da_members_.size ());
- CORBA_TypeCode_ptr field_tc = this->get_element_type (ACE_TRY_ENV);
+ CORBA_TypeCode_var field_tc = this->get_element_type (ACE_TRY_ENV);
ACE_CHECK_RETURN (0);
for (CORBA::ULong i = 0; i < this->da_members_.size (); i++)
@@ -411,7 +411,7 @@ TAO_DynSequence_i::current_component (CORBA::Environment &ACE_TRY_ENV)
if (!this->da_members_[this->current_index_].in ())
{
- CORBA_TypeCode_ptr tc = this->get_element_type (ACE_TRY_ENV);
+ CORBA_TypeCode_var tc = this->get_element_type (ACE_TRY_ENV);
ACE_CHECK_RETURN (CORBA_DynAny::_nil ());
this->da_members_[this->current_index_] =
@@ -467,7 +467,7 @@ void
TAO_DynSequence_i::insert_boolean (CORBA::Boolean value,
CORBA::Environment &ACE_TRY_ENV)
{
- CORBA_TypeCode_ptr tc = this->get_element_type (ACE_TRY_ENV);
+ CORBA_TypeCode_var tc = this->get_element_type (ACE_TRY_ENV);
ACE_CHECK;
CORBA::TCKind kind = tc->kind (ACE_TRY_ENV);
@@ -495,7 +495,7 @@ void
TAO_DynSequence_i::insert_octet (CORBA::Octet value,
CORBA::Environment &ACE_TRY_ENV)
{
- CORBA_TypeCode_ptr tc = this->get_element_type (ACE_TRY_ENV);
+ CORBA_TypeCode_var tc = this->get_element_type (ACE_TRY_ENV);
ACE_CHECK;
CORBA::TCKind kind = tc->kind (ACE_TRY_ENV);
@@ -523,7 +523,7 @@ void
TAO_DynSequence_i::insert_char (CORBA::Char value,
CORBA::Environment &ACE_TRY_ENV)
{
- CORBA_TypeCode_ptr tc = this->get_element_type (ACE_TRY_ENV);
+ CORBA_TypeCode_var tc = this->get_element_type (ACE_TRY_ENV);
ACE_CHECK;
CORBA::TCKind kind = tc->kind (ACE_TRY_ENV);
@@ -551,7 +551,7 @@ void
TAO_DynSequence_i::insert_short (CORBA::Short value,
CORBA::Environment &ACE_TRY_ENV)
{
- CORBA_TypeCode_ptr tc = this->get_element_type (ACE_TRY_ENV);
+ CORBA_TypeCode_var tc = this->get_element_type (ACE_TRY_ENV);
ACE_CHECK;
CORBA::TCKind kind = tc->kind (ACE_TRY_ENV);
@@ -579,7 +579,7 @@ void
TAO_DynSequence_i::insert_ushort (CORBA::UShort value,
CORBA::Environment &ACE_TRY_ENV)
{
- CORBA_TypeCode_ptr tc = this->get_element_type (ACE_TRY_ENV);
+ CORBA_TypeCode_var tc = this->get_element_type (ACE_TRY_ENV);
ACE_CHECK;
CORBA::TCKind kind = tc->kind (ACE_TRY_ENV);
@@ -607,7 +607,7 @@ void
TAO_DynSequence_i::insert_long (CORBA::Long value,
CORBA::Environment &ACE_TRY_ENV)
{
- CORBA_TypeCode_ptr tc = this->get_element_type (ACE_TRY_ENV);
+ CORBA_TypeCode_var tc = this->get_element_type (ACE_TRY_ENV);
ACE_CHECK;
CORBA::TCKind kind = tc->kind (ACE_TRY_ENV);
@@ -635,7 +635,7 @@ void
TAO_DynSequence_i::insert_ulong (CORBA::ULong value,
CORBA::Environment &ACE_TRY_ENV)
{
- CORBA_TypeCode_ptr tc = this->get_element_type (ACE_TRY_ENV);
+ CORBA_TypeCode_var tc = this->get_element_type (ACE_TRY_ENV);
ACE_CHECK;
CORBA::TCKind kind = tc->kind (ACE_TRY_ENV);
@@ -663,7 +663,7 @@ void
TAO_DynSequence_i::insert_float (CORBA::Float value,
CORBA::Environment &ACE_TRY_ENV)
{
- CORBA_TypeCode_ptr tc = this->get_element_type (ACE_TRY_ENV);
+ CORBA_TypeCode_var tc = this->get_element_type (ACE_TRY_ENV);
ACE_CHECK;
CORBA::TCKind kind = tc->kind (ACE_TRY_ENV);
@@ -691,7 +691,7 @@ void
TAO_DynSequence_i::insert_double (CORBA::Double value,
CORBA::Environment &ACE_TRY_ENV)
{
- CORBA_TypeCode_ptr tc = this->get_element_type (ACE_TRY_ENV);
+ CORBA_TypeCode_var tc = this->get_element_type (ACE_TRY_ENV);
ACE_CHECK;
CORBA::TCKind kind = tc->kind (ACE_TRY_ENV);
@@ -719,7 +719,7 @@ void
TAO_DynSequence_i::insert_string (const char * value,
CORBA::Environment &ACE_TRY_ENV)
{
- CORBA_TypeCode_ptr tc = this->get_element_type (ACE_TRY_ENV);
+ CORBA_TypeCode_var tc = this->get_element_type (ACE_TRY_ENV);
ACE_CHECK;
CORBA::TCKind kind = tc->kind (ACE_TRY_ENV);
@@ -747,7 +747,7 @@ void
TAO_DynSequence_i::insert_reference (CORBA::Object_ptr value,
CORBA::Environment &ACE_TRY_ENV)
{
- CORBA_TypeCode_ptr tc = this->get_element_type (ACE_TRY_ENV);
+ CORBA_TypeCode_var tc = this->get_element_type (ACE_TRY_ENV);
ACE_CHECK;
CORBA::TCKind kind = tc->kind (ACE_TRY_ENV);
@@ -775,7 +775,7 @@ void
TAO_DynSequence_i::insert_typecode (CORBA::TypeCode_ptr value,
CORBA::Environment &ACE_TRY_ENV)
{
- CORBA_TypeCode_ptr tc = this->get_element_type (ACE_TRY_ENV);
+ CORBA_TypeCode_var tc = this->get_element_type (ACE_TRY_ENV);
ACE_CHECK;
CORBA::TCKind kind = tc->kind (ACE_TRY_ENV);
@@ -803,7 +803,7 @@ void
TAO_DynSequence_i::insert_longlong (CORBA::LongLong value,
CORBA::Environment &ACE_TRY_ENV)
{
- CORBA_TypeCode_ptr tc = this->get_element_type (ACE_TRY_ENV);
+ CORBA_TypeCode_var tc = this->get_element_type (ACE_TRY_ENV);
ACE_CHECK;
CORBA::TCKind kind = tc->kind (ACE_TRY_ENV);
@@ -831,7 +831,7 @@ void
TAO_DynSequence_i::insert_ulonglong (CORBA::ULongLong value,
CORBA::Environment &ACE_TRY_ENV)
{
- CORBA_TypeCode_ptr tc = this->get_element_type (ACE_TRY_ENV);
+ CORBA_TypeCode_var tc = this->get_element_type (ACE_TRY_ENV);
ACE_CHECK;
CORBA::TCKind kind = tc->kind (ACE_TRY_ENV);
@@ -859,7 +859,7 @@ void
TAO_DynSequence_i::insert_wchar (CORBA::WChar value,
CORBA::Environment &ACE_TRY_ENV)
{
- CORBA_TypeCode_ptr tc = this->get_element_type (ACE_TRY_ENV);
+ CORBA_TypeCode_var tc = this->get_element_type (ACE_TRY_ENV);
ACE_CHECK;
CORBA::TCKind kind = tc->kind (ACE_TRY_ENV);
@@ -887,7 +887,7 @@ void
TAO_DynSequence_i::insert_any (const CORBA::Any& value,
CORBA::Environment &ACE_TRY_ENV)
{
- CORBA_TypeCode_ptr tc = this->get_element_type (ACE_TRY_ENV);
+ CORBA_TypeCode_var tc = this->get_element_type (ACE_TRY_ENV);
ACE_CHECK;
CORBA::TCKind kind = tc->kind (ACE_TRY_ENV);
@@ -925,7 +925,7 @@ TAO_DynSequence_i::get_boolean (CORBA::Environment &ACE_TRY_ENV)
if (dp)
{
- CORBA_TypeCode_ptr tc = this->get_element_type (ACE_TRY_ENV);
+ CORBA_TypeCode_var tc = this->get_element_type (ACE_TRY_ENV);
ACE_CHECK_RETURN (val);
CORBA::TCKind kind = tc->kind (ACE_TRY_ENV);
@@ -963,7 +963,7 @@ TAO_DynSequence_i::get_octet (CORBA::Environment &ACE_TRY_ENV)
if (dp)
{
- CORBA_TypeCode_ptr tc = this->get_element_type (ACE_TRY_ENV);
+ CORBA_TypeCode_var tc = this->get_element_type (ACE_TRY_ENV);
ACE_CHECK_RETURN (val);
CORBA::TCKind kind = tc->kind (ACE_TRY_ENV);
@@ -1001,7 +1001,7 @@ TAO_DynSequence_i::get_char (CORBA::Environment &ACE_TRY_ENV)
if (dp)
{
- CORBA_TypeCode_ptr tc = this->get_element_type (ACE_TRY_ENV);
+ CORBA_TypeCode_var tc = this->get_element_type (ACE_TRY_ENV);
ACE_CHECK_RETURN (val);
CORBA::TCKind kind = tc->kind (ACE_TRY_ENV);
@@ -1039,7 +1039,7 @@ TAO_DynSequence_i::get_short (CORBA::Environment &ACE_TRY_ENV)
if (dp)
{
- CORBA_TypeCode_ptr tc = this->get_element_type (ACE_TRY_ENV);
+ CORBA_TypeCode_var tc = this->get_element_type (ACE_TRY_ENV);
ACE_CHECK_RETURN (val);
CORBA::TCKind kind = tc->kind (ACE_TRY_ENV);
@@ -1077,7 +1077,7 @@ TAO_DynSequence_i::get_ushort (CORBA::Environment &ACE_TRY_ENV)
if (dp)
{
- CORBA_TypeCode_ptr tc = this->get_element_type (ACE_TRY_ENV);
+ CORBA_TypeCode_var tc = this->get_element_type (ACE_TRY_ENV);
ACE_CHECK_RETURN (val);
CORBA::TCKind kind = tc->kind (ACE_TRY_ENV);
@@ -1115,7 +1115,7 @@ TAO_DynSequence_i::get_long (CORBA::Environment &ACE_TRY_ENV)
if (dp)
{
- CORBA_TypeCode_ptr tc = this->get_element_type (ACE_TRY_ENV);
+ CORBA_TypeCode_var tc = this->get_element_type (ACE_TRY_ENV);
ACE_CHECK_RETURN (val);
CORBA::TCKind kind = tc->kind (ACE_TRY_ENV);
@@ -1153,7 +1153,7 @@ TAO_DynSequence_i::get_ulong (CORBA::Environment &ACE_TRY_ENV)
if (dp)
{
- CORBA_TypeCode_ptr tc = this->get_element_type (ACE_TRY_ENV);
+ CORBA_TypeCode_var tc = this->get_element_type (ACE_TRY_ENV);
ACE_CHECK_RETURN (val);
CORBA::TCKind kind = tc->kind (ACE_TRY_ENV);
@@ -1191,7 +1191,7 @@ TAO_DynSequence_i::get_float (CORBA::Environment &ACE_TRY_ENV)
if (dp)
{
- CORBA_TypeCode_ptr tc = this->get_element_type (ACE_TRY_ENV);
+ CORBA_TypeCode_var tc = this->get_element_type (ACE_TRY_ENV);
ACE_CHECK_RETURN (val);
CORBA::TCKind kind = tc->kind (ACE_TRY_ENV);
@@ -1229,7 +1229,7 @@ TAO_DynSequence_i::get_double (CORBA::Environment &ACE_TRY_ENV)
if (dp)
{
- CORBA_TypeCode_ptr tc = this->get_element_type (ACE_TRY_ENV);
+ CORBA_TypeCode_var tc = this->get_element_type (ACE_TRY_ENV);
ACE_CHECK_RETURN (val);
CORBA::TCKind kind = tc->kind (ACE_TRY_ENV);
@@ -1267,7 +1267,7 @@ TAO_DynSequence_i::get_string (CORBA::Environment &ACE_TRY_ENV)
if (dp)
{
- CORBA_TypeCode_ptr tc = this->get_element_type (ACE_TRY_ENV);
+ CORBA_TypeCode_var tc = this->get_element_type (ACE_TRY_ENV);
ACE_CHECK_RETURN (val);
CORBA::TCKind kind = tc->kind (ACE_TRY_ENV);
@@ -1305,7 +1305,7 @@ TAO_DynSequence_i::get_reference (CORBA::Environment &ACE_TRY_ENV)
if (dp)
{
- CORBA_TypeCode_ptr tc = this->get_element_type (ACE_TRY_ENV);
+ CORBA_TypeCode_var tc = this->get_element_type (ACE_TRY_ENV);
ACE_CHECK_RETURN (val);
CORBA::TCKind kind = tc->kind (ACE_TRY_ENV);
@@ -1343,7 +1343,7 @@ TAO_DynSequence_i::get_typecode (CORBA::Environment &ACE_TRY_ENV)
if (dp)
{
- CORBA_TypeCode_ptr tc = this->get_element_type (ACE_TRY_ENV);
+ CORBA_TypeCode_var tc = this->get_element_type (ACE_TRY_ENV);
ACE_CHECK_RETURN (val);
CORBA::TCKind kind = tc->kind (ACE_TRY_ENV);
@@ -1386,7 +1386,7 @@ TAO_DynSequence_i::get_longlong (CORBA::Environment &ACE_TRY_ENV)
if (dp)
{
- CORBA_TypeCode_ptr tc = this->get_element_type (ACE_TRY_ENV);
+ CORBA_TypeCode_var tc = this->get_element_type (ACE_TRY_ENV);
ACE_CHECK_RETURN (val);
CORBA::TCKind kind = tc->kind (ACE_TRY_ENV);
@@ -1424,7 +1424,7 @@ TAO_DynSequence_i::get_ulonglong (CORBA::Environment &ACE_TRY_ENV)
if (dp)
{
- CORBA_TypeCode_ptr tc = this->get_element_type (ACE_TRY_ENV);
+ CORBA_TypeCode_var tc = this->get_element_type (ACE_TRY_ENV);
ACE_CHECK_RETURN (val);
CORBA::TCKind kind = tc->kind (ACE_TRY_ENV);
@@ -1462,7 +1462,7 @@ TAO_DynSequence_i::get_wchar (CORBA::Environment &ACE_TRY_ENV)
if (dp)
{
- CORBA_TypeCode_ptr tc = this->get_element_type (ACE_TRY_ENV);
+ CORBA_TypeCode_var tc = this->get_element_type (ACE_TRY_ENV);
ACE_CHECK_RETURN (val);
CORBA::TCKind kind = tc->kind (ACE_TRY_ENV);
@@ -1500,7 +1500,7 @@ TAO_DynSequence_i::get_any (CORBA::Environment &ACE_TRY_ENV)
if (dp)
{
- CORBA_TypeCode_ptr tc = this->get_element_type (ACE_TRY_ENV);
+ CORBA_TypeCode_var tc = this->get_element_type (ACE_TRY_ENV);
ACE_CHECK_RETURN (val);
CORBA::TCKind kind = tc->kind (ACE_TRY_ENV);
@@ -1534,8 +1534,7 @@ TAO_DynSequence_i::get_any (CORBA::Environment &ACE_TRY_ENV)
CORBA::TypeCode_ptr
TAO_DynSequence_i::get_element_type (CORBA::Environment& ACE_TRY_ENV)
{
- CORBA::TypeCode_ptr element_type =
- this->type_.in ();
+ CORBA::TypeCode_var element_type = CORBA::TypeCode::_duplicate (this->type_.in ());
// Strip away aliases (if any) on top of the outer type
CORBA::TCKind kind = element_type->kind (ACE_TRY_ENV);