diff options
author | vzykov <vzykov@ae88bc3d-4319-0410-8dbf-d08b4c9d3795> | 2009-01-29 11:09:38 +0000 |
---|---|---|
committer | vzykov <vzykov@ae88bc3d-4319-0410-8dbf-d08b4c9d3795> | 2009-01-29 11:09:38 +0000 |
commit | 75c36ac3fc49e74b97e1051f91dae30318b88f31 (patch) | |
tree | a2acc6965d261a25f9f86a7d3757a98aa84767a6 /TAO | |
parent | ee2d2daa6485ca044eb6012228ad03a7c9e5a0af (diff) | |
download | ATCD-75c36ac3fc49e74b97e1051f91dae30318b88f31.tar.gz |
ChangeLogTag: Thu Jan 29 11:06:36 UTC 2009 Vladimir Zykov <vz@prismtech.com>
Diffstat (limited to 'TAO')
-rw-r--r-- | TAO/ChangeLog | 13 | ||||
-rw-r--r-- | TAO/TAO_IDL/be/be_visitor_array/cdr_op_cs.cpp | 8 | ||||
-rw-r--r-- | TAO/TAO_IDL/be/be_visitor_field/cdr_op_cs.cpp | 8 | ||||
-rw-r--r-- | TAO/TAO_IDL/be/be_visitor_union_branch/cdr_op_cs.cpp | 8 | ||||
-rw-r--r-- | TAO/TAO_IDL/be/be_visitor_valuebox/valuebox_cs.cpp | 8 | ||||
-rw-r--r-- | TAO/TAO_IDL/be/be_visitor_valuetype/field_cdr_cs.cpp | 8 | ||||
-rw-r--r-- | TAO/tao/CDR.h | 44 | ||||
-rw-r--r-- | TAO/tao/CDR.inl | 62 |
8 files changed, 43 insertions, 116 deletions
diff --git a/TAO/ChangeLog b/TAO/ChangeLog index 5d2d9d15cff..118e88279c9 100644 --- a/TAO/ChangeLog +++ b/TAO/ChangeLog @@ -1,3 +1,16 @@ +Thu Jan 29 11:06:36 UTC 2009 Vladimir Zykov <vz@prismtech.com> + + * tao/CDR.inl: + * tao/CDR.h: + * TAO_IDL/be/be_visitor_union_branch/cdr_op_cs.cpp: + * TAO_IDL/be/be_visitor_array/cdr_op_cs.cpp: + * TAO_IDL/be/be_visitor_valuebox/valuebox_cs.cpp: + * TAO_IDL/be/be_visitor_valuetype/field_cdr_cs.cpp: + * TAO_IDL/be/be_visitor_field/cdr_op_cs.cpp: + + Removed to_bounded_string and from_bounded_string structs. + It turned out they are unnecessary. + Thu Jan 29 10:32:52 UTC 2009 Johnny Willemsen <jwillemsen@remedy.nl> * tao/IIOP_Transport.cpp: diff --git a/TAO/TAO_IDL/be/be_visitor_array/cdr_op_cs.cpp b/TAO/TAO_IDL/be/be_visitor_array/cdr_op_cs.cpp index d49a15d3731..a56c43b1539 100644 --- a/TAO/TAO_IDL/be/be_visitor_array/cdr_op_cs.cpp +++ b/TAO/TAO_IDL/be/be_visitor_array/cdr_op_cs.cpp @@ -665,11 +665,11 @@ be_visitor_array_cdr_op_cs::visit_node (be_type *bt) { if (str->width () == (long) sizeof (char)) { - *os << "TAO_InputCDR::to_bounded_string (_tao_array "; + *os << "ACE_InputCDR::to_string (_tao_array "; } else { - *os << "TAO_InputCDR::to_bounded_wstring (_tao_array "; + *os << "ACE_InputCDR::to_wstring (_tao_array "; } } else @@ -792,11 +792,11 @@ be_visitor_array_cdr_op_cs::visit_node (be_type *bt) { if (str->width () == (long) sizeof (char)) { - *os << "TAO_OutputCDR::from_bounded_string (_tao_array "; + *os << "ACE_OutputCDR::from_string (_tao_array "; } else { - *os << "TAO_OutputCDR::from_bounded_wstring (_tao_array "; + *os << "ACE_OutputCDR::from_wstring (_tao_array "; } } else diff --git a/TAO/TAO_IDL/be/be_visitor_field/cdr_op_cs.cpp b/TAO/TAO_IDL/be/be_visitor_field/cdr_op_cs.cpp index 70a58d46cc2..bb6b9593c77 100644 --- a/TAO/TAO_IDL/be/be_visitor_field/cdr_op_cs.cpp +++ b/TAO/TAO_IDL/be/be_visitor_field/cdr_op_cs.cpp @@ -653,13 +653,13 @@ be_visitor_field_cdr_op_cs::visit_string (be_string *str) { if (str->width () == (long) sizeof (char)) { - *os << "(strm >> TAO_InputCDR::to_bounded_string (_tao_aggregate." + *os << "(strm >> ACE_InputCDR::to_string (_tao_aggregate." << f->local_name () << ".out (), " << str->max_size ()->ev ()->u.ulval << "))"; } else { - *os << "(strm >> TAO_InputCDR::to_bounded_wstring (_tao_aggregate." + *os << "(strm >> ACE_InputCDR::to_wstring (_tao_aggregate." << f->local_name () << ".out (), " << str->max_size ()->ev ()->u.ulval << "))"; } @@ -675,13 +675,13 @@ be_visitor_field_cdr_op_cs::visit_string (be_string *str) { if (str->width () == (long) sizeof (char)) { - *os << "(strm << TAO_OutputCDR::from_bounded_string (_tao_aggregate." + *os << "(strm << ACE_OutputCDR::from_string (_tao_aggregate." << f->local_name () << ".in (), " << str->max_size ()->ev ()->u.ulval << "))"; } else { - *os << "(strm << TAO_OutputCDR::from_bounded_wstring (_tao_aggregate." + *os << "(strm << ACE_OutputCDR::from_wstring (_tao_aggregate." << f->local_name () << ".in (), " << str->max_size ()->ev ()->u.ulval << "))"; } diff --git a/TAO/TAO_IDL/be/be_visitor_union_branch/cdr_op_cs.cpp b/TAO/TAO_IDL/be/be_visitor_union_branch/cdr_op_cs.cpp index 3c6d5c34f84..c81a9a22cfd 100644 --- a/TAO/TAO_IDL/be/be_visitor_union_branch/cdr_op_cs.cpp +++ b/TAO/TAO_IDL/be/be_visitor_union_branch/cdr_op_cs.cpp @@ -766,14 +766,14 @@ be_visitor_union_branch_cdr_op_cs::visit_string (be_string *node) { if (node->width () == (long) sizeof (char)) { - *os << "result = strm >> TAO_InputCDR::to_bounded_string (" + *os << "result = strm >> ACE_InputCDR::to_string (" << "_tao_union_tmp.out (), " << node->max_size ()->ev ()->u.ulval << ");" << be_nl << be_nl; } else { - *os << "result = strm >> TAO_InputCDR::to_bounded_wstring (" + *os << "result = strm >> ACE_InputCDR::to_wstring (" << "_tao_union_tmp.out (), " << node->max_size ()->ev ()->u.ulval << ");" << be_nl << be_nl; @@ -798,13 +798,13 @@ be_visitor_union_branch_cdr_op_cs::visit_string (be_string *node) { if (node->width () == (long) sizeof (char)) { - *os << "result = strm << TAO_OutputCDR::from_bounded_string (" + *os << "result = strm << ACE_OutputCDR::from_string (" << "_tao_union." << f->local_name () << " (), " << node->max_size ()->ev ()->u.ulval << ");"; } else { - *os << "result = strm << TAO_OutputCDR::from_bounded_wstring (" + *os << "result = strm << ACE_OutputCDR::from_wstring (" << "_tao_union." << f->local_name () << " (), " << node->max_size ()->ev ()->u.ulval << ");"; } diff --git a/TAO/TAO_IDL/be/be_visitor_valuebox/valuebox_cs.cpp b/TAO/TAO_IDL/be/be_visitor_valuebox/valuebox_cs.cpp index 06db74b436a..3e10e3f903a 100644 --- a/TAO/TAO_IDL/be/be_visitor_valuebox/valuebox_cs.cpp +++ b/TAO/TAO_IDL/be/be_visitor_valuebox/valuebox_cs.cpp @@ -278,13 +278,13 @@ be_visitor_valuebox_cs::visit_valuebox (be_valuebox *node) { if (str->width () == (long) sizeof (char)) { - *os << "::TAO_InputCDR::to_bounded_string " + *os << "::ACE_InputCDR::to_string " << "(vb_object->_pd_value, " << str->max_size ()->ev ()->u.ulval << ")"; } else { - *os << "::TAO_InputCDR::to_bounded_wstring " + *os << "::ACE_InputCDR::to_wstring " << "(vb_object->_pd_value, " << str->max_size ()->ev ()->u.ulval << ")"; } @@ -634,13 +634,13 @@ be_visitor_valuebox_cs::visit_string (be_string *str) { if (str->width () == (long) sizeof (char)) { - os << "::TAO_OutputCDR::from_bounded_string " + os << "::ACE_OutputCDR::from_string " << "(this->_pd_value, " << str->max_size ()->ev ()->u.ulval << ")"; } else { - os << "::TAO_OutputCDR::from_bounded_wstring " + os << "::ACE_OutputCDR::from_wstring " << "(this->_pd_value, " << str->max_size ()->ev ()->u.ulval << ")"; } diff --git a/TAO/TAO_IDL/be/be_visitor_valuetype/field_cdr_cs.cpp b/TAO/TAO_IDL/be/be_visitor_valuetype/field_cdr_cs.cpp index 4cb279676a8..9d1ec7fa3d7 100644 --- a/TAO/TAO_IDL/be/be_visitor_valuetype/field_cdr_cs.cpp +++ b/TAO/TAO_IDL/be/be_visitor_valuetype/field_cdr_cs.cpp @@ -651,13 +651,13 @@ be_visitor_valuetype_field_cdr_cs::visit_string (be_string *str) { if (str->width () == (long) sizeof (char)) { - *os << "(strm >> TAO_InputCDR::to_bounded_string (" + *os << "(strm >> ACE_InputCDR::to_string (" << this->pre_ << f->local_name () << this->post_ << ".out (), " << str->max_size ()->ev ()->u.ulval << "))"; } else { - *os << "(strm >> TAO_InputCDR::to_bounded_wstring (" + *os << "(strm >> ACE_InputCDR::to_wstring (" << this->pre_ << f->local_name () << this->post_ << ".out (), " << str->max_size ()->ev ()->u.ulval << "))"; } @@ -673,13 +673,13 @@ be_visitor_valuetype_field_cdr_cs::visit_string (be_string *str) { if (str->width () == (long) sizeof (char)) { - *os << "(strm << TAO_OutputCDR::from_bounded_string (" + *os << "(strm << ACE_OutputCDR::from_string (" << this->pre_ << f->local_name () << this->post_ << ".in (), " << str->max_size ()->ev ()->u.ulval << "))"; } else { - *os << "(strm << TAO_OutputCDR::from_bounded_wstring (" + *os << "(strm << ACE_OutputCDR::from_wstring (" << this->pre_ << f->local_name () << this->post_ << ".in (), " << str->max_size ()->ev ()->u.ulval << "))"; } diff --git a/TAO/tao/CDR.h b/TAO/tao/CDR.h index b983e4e7051..51c0ac4ca84 100644 --- a/TAO/tao/CDR.h +++ b/TAO/tao/CDR.h @@ -150,22 +150,6 @@ public: /// Destructor. ~TAO_OutputCDR (void); - struct TAO_Export from_bounded_string - { - from_bounded_string (const ACE_CDR::Char* s, - ACE_CDR::ULong b); - ACE_CDR::Char *val_; - ACE_CDR::ULong bound_; - }; - - struct TAO_Export from_bounded_wstring - { - from_bounded_wstring (const ACE_CDR::WChar* ws, - ACE_CDR::ULong b); - ACE_CDR::WChar *val_; - ACE_CDR::ULong bound_; - }; - // @todo do we want a special method to write an array of // strings and wstrings? @@ -384,26 +368,6 @@ public: /// Destructor ~TAO_InputCDR (void); - struct TAO_Export to_bounded_string - { - to_bounded_string (ACE_CDR::Char *&s, - ACE_CDR::ULong b); - to_bounded_string (const ACE_CDR::Char *&s, - ACE_CDR::ULong b); - ACE_CDR::Char *&val_; - ACE_CDR::ULong bound_; - }; - - struct TAO_Export to_bounded_wstring - { - to_bounded_wstring (ACE_CDR::WChar *&ws, - ACE_CDR::ULong b); - to_bounded_wstring (const ACE_CDR::WChar *&ws, - ACE_CDR::ULong b); - ACE_CDR::WChar *&val_; - ACE_CDR::ULong bound_; - }; - // = TAO specific methods. /// Accessor @@ -466,9 +430,9 @@ TAO_Export CORBA::Boolean operator<< (TAO_OutputCDR &os, TAO_Export CORBA::Boolean operator<< (TAO_OutputCDR &os, const CORBA::WChar* x); TAO_Export CORBA::Boolean operator<< (TAO_OutputCDR &os, - TAO_OutputCDR::from_bounded_string x); + ACE_OutputCDR::from_string x); TAO_Export CORBA::Boolean operator<< (TAO_OutputCDR &os, - TAO_OutputCDR::from_bounded_wstring x); + ACE_OutputCDR::from_wstring x); // CDR input operators for CORBA types @@ -495,9 +459,9 @@ TAO_Export CORBA::Boolean operator>> (TAO_InputCDR &is, TAO_Export CORBA::Boolean operator>> (TAO_InputCDR &is, CORBA::WChar* &x); TAO_Export CORBA::Boolean operator>> (TAO_InputCDR &os, - TAO_InputCDR::to_bounded_string x); + ACE_InputCDR::to_string x); TAO_Export CORBA::Boolean operator>> (TAO_InputCDR &os, - TAO_InputCDR::to_bounded_wstring x); + ACE_InputCDR::to_wstring x); TAO_END_VERSIONED_NAMESPACE_DECL diff --git a/TAO/tao/CDR.inl b/TAO/tao/CDR.inl index 44fcca4af39..64030e659cb 100644 --- a/TAO/tao/CDR.inl +++ b/TAO/tao/CDR.inl @@ -275,56 +275,6 @@ TAO_InputCDR::compressed (bool compressed) // **************************************************************** -ACE_INLINE -TAO_OutputCDR::from_bounded_string::from_bounded_string (const ACE_CDR::Char *s, - ACE_CDR::ULong b) - : val_ (const_cast<ACE_CDR::Char *> (s)), - bound_ (b) -{ -} - -ACE_INLINE -TAO_InputCDR::to_bounded_string::to_bounded_string (ACE_CDR::Char *&s, - ACE_CDR::ULong b) - : val_ (s), - bound_ (b) -{ -} - -ACE_INLINE -TAO_InputCDR::to_bounded_string::to_bounded_string (const ACE_CDR::Char *&s, - ACE_CDR::ULong b) - : val_ (const_cast<ACE_CDR::Char *&> (s)), - bound_ (b) -{ -} - -ACE_INLINE -TAO_OutputCDR::from_bounded_wstring::from_bounded_wstring (const ACE_CDR::WChar *ws, - ACE_CDR::ULong b) - : val_ (const_cast<ACE_CDR::WChar *> (ws)), - bound_ (b) -{ -} - -ACE_INLINE -TAO_InputCDR::to_bounded_wstring::to_bounded_wstring (ACE_CDR::WChar *&ws, - ACE_CDR::ULong b) - : val_ (ws), - bound_ (b) -{ -} - -ACE_INLINE -TAO_InputCDR::to_bounded_wstring::to_bounded_wstring (const ACE_CDR::WChar *&ws, - ACE_CDR::ULong b) - : val_ (const_cast<ACE_CDR::WChar *&> (ws)), - bound_ (b) -{ -} - -// **************************************************************** - ACE_INLINE CORBA::Boolean operator<< (TAO_OutputCDR &os, CORBA::Short x) { @@ -427,7 +377,7 @@ ACE_INLINE CORBA::Boolean operator<< (TAO_OutputCDR &os, } ACE_INLINE CORBA::Boolean operator<< (TAO_OutputCDR &os, - TAO_OutputCDR::from_bounded_string x) + ACE_OutputCDR::from_string x) { if (x.val_ != 0 && ACE_OS::strlen (x.val_) > x.bound_) @@ -438,7 +388,7 @@ ACE_INLINE CORBA::Boolean operator<< (TAO_OutputCDR &os, } ACE_INLINE CORBA::Boolean operator<< (TAO_OutputCDR &os, - TAO_OutputCDR::from_bounded_wstring x) + ACE_OutputCDR::from_wstring x) { if (x.val_ != 0 && ACE_OS::strlen (x.val_) > x.bound_) @@ -517,9 +467,9 @@ ACE_INLINE CORBA::Boolean operator>> (TAO_InputCDR &is, } ACE_INLINE CORBA::Boolean operator>> (TAO_InputCDR &is, - TAO_InputCDR::to_bounded_string x) + ACE_InputCDR::to_string x) { - CORBA::Boolean const marshal_flag = is >> x.val_; + CORBA::Boolean const marshal_flag = is >> const_cast<ACE_CDR::Char *&> (x.val_); if (marshal_flag && x.val_ != 0 && ACE_OS::strlen (x.val_) > x.bound_) { @@ -529,9 +479,9 @@ ACE_INLINE CORBA::Boolean operator>> (TAO_InputCDR &is, } ACE_INLINE CORBA::Boolean operator>> (TAO_InputCDR &is, - TAO_InputCDR::to_bounded_wstring x) + ACE_InputCDR::to_wstring x) { - CORBA::Boolean const marshal_flag = is >> x.val_; + CORBA::Boolean const marshal_flag = is >> const_cast<ACE_CDR::WChar *&> (x.val_); if (marshal_flag && x.val_ != 0 && ACE_OS::strlen (x.val_) > x.bound_) { |