--- coss/externalization/Makefile.orig Wed Jul 9 18:02:19 2003 +++ coss/externalization/Makefile Wed Jul 9 18:02:27 2003 @@ -85,6 +85,8 @@ $(CXX) $(CXXFLAGS) $(LDFLAGS) extreferenced.o $(LDLIBS) -o extreferenced $(POSTLD) $@ +idlcompile: CosExternalization.cc CosExternalizationContainment.cc CosExternalizationReference.cc + CosExternalization.h CosExternalization.cc: \ ../../include/coss/CosExternalization.idl $(IDL) $(IDL) $(IDLFLAGS) --name CosExternalization \ @@ -125,6 +127,8 @@ $(IBINCMD) extcontainmentd $(INSTDIR)/bin $(IDIRCMD) $(INSTDIR)/bin $(IBINCMD) extreferenced $(INSTDIR)/bin + $(IDIRCMD) $(INSTDIR)/bin + $(IBINCMD) extcriteriad $(INSTDIR)/bin ifeq (.depend, $(wildcard .depend)) --- include/coss/CosStream_impl.h.orig Fri Jul 4 15:24:06 2003 +++ include/coss/CosStream_impl.h Fri Jul 4 17:12:36 2003 @@ -58,8 +58,8 @@ class StreamIO_impl : virtual public POA_CosStream::StreamIO { - istream* istream_; - ostream* ostream_; + std::istream* istream_; + std::ostream* ostream_; enum in_out { in, @@ -67,12 +67,12 @@ } iotype; protected: - CORBA::Boolean was_extern(vector* vec_, + CORBA::Boolean was_extern(std::vector* vec_, CosObjectIdentity::ObjectIdentifier id); public: - StreamIO_impl(ostream* ostream_ptr = &cout) + StreamIO_impl(std::ostream* ostream_ptr = &std::cout) : ostream_(ostream_ptr), iotype(out) { }; - StreamIO_impl(istream* istream_ptr = &cin) + StreamIO_impl(std::istream* istream_ptr = &std::cin) : istream_(istream_ptr), iotype(in) { }; virtual void write_string(const char* aString); --- include/coss/Externalization_impl.h.orig Fri Jul 4 18:04:44 2003 +++ include/coss/Externalization_impl.h Fri Jul 4 18:08:33 2003 @@ -32,8 +32,8 @@ { CORBA::String_var filename_; CosLifeCycle::Key factory_id_; - istream* ifstream_; - ostream* ofstream_; + std::istream* ifstream_; + std::ostream* ofstream_; CORBA::Boolean context; public: --- coss/externalization/Stream_impl.cc.orig Fri Jul 4 15:30:45 2003 +++ coss/externalization/Stream_impl.cc Fri Jul 4 16:58:23 2003 @@ -37,8 +37,10 @@ #include #endif -typedef map > WorkedRoles; -typedef map > NewRoles; +using std::string; + +typedef std::map > WorkedRoles; +typedef std::map > NewRoles; typedef IfaceSequenceTmpl NewNodes; const char tag_object = 0xF0; @@ -135,10 +137,10 @@ (*aStreamable).externalize_to_stream(_sio); } -CORBA::Boolean StreamIO_impl::was_extern(vector* vec_, +CORBA::Boolean StreamIO_impl::was_extern(std::vector* vec_, CosObjectIdentity::ObjectIdentifier id) { - vector::iterator j; + std::vector::iterator j; for(j = vec_->begin();j != vec_->end();++j) if (*j == id) return TRUE; @@ -151,10 +153,10 @@ if (iotype != out) return; CosStream::StreamIO_ptr _sio = this->_this(); - vector* done_nodes = - new vector; - vector* done_rel = - new vector; + std::vector* done_nodes = + new std::vector; + std::vector* done_rel = + new std::vector; // Externalize Root Node CosObjectIdentity::ObjectIdentifier starting_node_id = starting_node->constant_random_id(); // End --- coss/externalization/Externalization_impl.cc.orig Fri Jul 4 15:28:31 2003 +++ coss/externalization/Externalization_impl.cc Fri Jul 4 15:28:51 2003 @@ -37,6 +37,8 @@ #include #include +using std::string; + #ifndef _WIN32 Stream_impl::Stream_impl(const char* filename = NULL) : POA_CosExternalization::Stream(), --- coss/externalization/extreferenced.cc.orig Fri Jul 4 17:57:42 2003 +++ coss/externalization/extreferenced.cc Fri Jul 4 17:58:50 2003 @@ -34,8 +34,8 @@ static void usage(const char* progName) { - cerr << "Usage:\n"; - cerr << progName << " [options]\n" + std::cerr << "Usage:\n"; + std::cerr << progName << " [options]\n" "\n" "Options:\n" "-h, --help Show this message.\n" @@ -65,7 +65,7 @@ else if(strcmp(argv[i], "--version") == 0 || strcmp(argv[i], "-v") == 0) { - cerr << "Version of CosExternalizationReference Service Factories is " << MICO_VERSION << endl; + std::cerr << "Version of CosExternalizationReference Service Factories is " << MICO_VERSION << std::endl; return 0; } else if(strcmp(argv[i], "--with-naming") == 0 || @@ -76,8 +76,8 @@ type = RegisterHelper::trading; else { - cerr << progName << ": unknown option `" - << argv[i] << "'\n" << endl; + std::cerr << progName << ": unknown option `" + << argv[i] << "'\n" << std::endl; usage(progName); return 1; } --- coss/externalization/streamd.cc.orig Fri Jul 4 17:57:59 2003 +++ coss/externalization/streamd.cc Fri Jul 4 17:59:41 2003 @@ -38,8 +38,8 @@ static void usage(const char* progName) { - cerr << "Usage:\n"; - cerr << progName << " [options]\n" + std::cerr << "Usage:\n"; + std::cerr << progName << " [options]\n" "\n" "Options:\n" "-h, --help Show this message.\n" @@ -67,7 +67,7 @@ else if(strcmp(argv[i], "--version") == 0 || strcmp(argv[i], "-v") == 0) { - cerr << "Version of CosExternalizationContainment Service Factories is " << MICO_VERSION << endl; + std::cerr << "Version of CosExternalizationContainment Service Factories is " << MICO_VERSION << std::endl; return 0; } else if(strcmp(argv[i], "--trading") == 0 || @@ -77,8 +77,8 @@ } else { - cerr << progName << ": unknown option `" - << argv[i] << "'\n" << endl; + std::cerr << progName << ": unknown option `" + << argv[i] << "'\n" << std::endl; usage(progName); return 1; } @@ -111,20 +111,20 @@ tr_obj = orb -> resolve_initial_references("TradingService"); #ifdef HAVE_EXCEPTIONS } catch(CORBA::ORB::InvalidName&) { - cerr << "Can`t resolve Trading Service. Abort" << endl; + std::cerr << "Can`t resolve Trading Service. Abort" << std::endl; exit(1); } #endif if (CORBA::is_nil(tr_obj)) { - cerr << "Can`t resolve Trading Service. Abort" << endl; + std::cerr << "Can`t resolve Trading Service. Abort" << std::endl; exit(1); } CosTrading::Lookup_var trader_ = CosTrading::Lookup::_narrow (tr_obj); CosTrading::Register_var reg = trader_->register_if(); if (CORBA::is_nil(reg)) { - cerr << "Invalid Trading Service. Abort" << endl; + std::cerr << "Invalid Trading Service. Abort" << std::endl; exit(1); } CORBA::Object_var obj = trader_->type_repos(); @@ -132,7 +132,7 @@ CosTradingRepos::ServiceTypeRepository::_narrow(obj); if (CORBA::is_nil(repo)) { - cerr << "Invalid Trading Service. Abort" << endl; + std::cerr << "Invalid Trading Service. Abort" << std::endl; exit(1); } --- coss/externalization/extcriteriad.cc.orig Fri Jul 4 17:58:08 2003 +++ coss/externalization/extcriteriad.cc Fri Jul 4 18:00:00 2003 @@ -37,8 +37,8 @@ static void usage(const char* progName) { - cerr << "Usage:\n"; - cerr << progName << " [options]\n" + std::cerr << "Usage:\n"; + std::cerr << progName << " [options]\n" "\n" "Options:\n" "-h, --help Show this message.\n" @@ -63,13 +63,13 @@ else if(strcmp(argv[i], "--version") == 0 || strcmp(argv[i], "-v") == 0) { - cerr << "Version of CosCompoundExternalization::PropagationCriteriaFactory Service is " << MICO_VERSION << endl; + std::cerr << "Version of CosCompoundExternalization::PropagationCriteriaFactory Service is " << MICO_VERSION << std::endl; return 0; } else { - cerr << progName << ": unknown option `" - << argv[i] << "'\n" << endl; + std::cerr << progName << ": unknown option `" + << argv[i] << "'\n" << std::endl; usage(progName); return 1; } --- coss/externalization/extcontainmentd.cc.orig Fri Jul 4 18:01:09 2003 +++ coss/externalization/extcontainmentd.cc Fri Jul 4 18:01:40 2003 @@ -34,8 +34,8 @@ static void usage(const char* progName) { - cerr << "Usage:\n"; - cerr << progName << " [options]\n" + std::cerr << "Usage:\n"; + std::cerr << progName << " [options]\n" "\n" "Options:\n" "-h, --help Show this message.\n" @@ -64,7 +64,7 @@ else if(strcmp(argv[i], "--version") == 0 || strcmp(argv[i], "-v") == 0) { - cerr << "Version of CosExternalizationContainment Service Factories is " << MICO_VERSION << endl; + std::cerr << "Version of CosExternalizationContainment Service Factories is " << MICO_VERSION << std::endl; return 0; } else if(strcmp(argv[i], "--with-naming") == 0 || @@ -75,8 +75,8 @@ type = RegisterHelper::trading; else { - cerr << progName << ": unknown option `" - << argv[i] << "'\n" << endl; + std::cerr << progName << ": unknown option `" + << argv[i] << "'\n" << std::endl; usage(progName); return 1; } --- coss/externalization/extnoded.cc.orig Fri Jul 4 17:35:15 2003 +++ coss/externalization/extnoded.cc Fri Jul 4 17:35:45 2003 @@ -34,8 +34,8 @@ static void usage(const char* progName) { - cerr << "Usage:\n"; - cerr << progName << " [options]\n" + std::cerr << "Usage:\n"; + std::cerr << progName << " [options]\n" "\n" "Options:\n" "-h, --help Show this message.\n" @@ -64,7 +64,7 @@ else if(strcmp(argv[i], "--version") == 0 || strcmp(argv[i], "-v") == 0) { - cerr << "Version of CosCompoundExternalization::Node Service Factories is " << MICO_VERSION << endl; + std::cerr << "Version of CosCompoundExternalization::Node Service Factories is " << MICO_VERSION << std::endl; return 0; } else if(strcmp(argv[i], "--with-naming") == 0 || @@ -75,8 +75,8 @@ type = RegisterHelper::trading; else { - cerr << progName << ": unknown option `" - << argv[i] << "'\n" << endl; + std::cerr << progName << ": unknown option `" + << argv[i] << "'\n" << std::endl; usage(progName); return 1; } --- include/coss/CompoundExternalization_impl.h.orig Sat Jul 5 23:41:43 2003 +++ include/coss/CompoundExternalization_impl.h Sat Jul 5 23:52:35 2003 @@ -52,7 +52,7 @@ virtual void internalize_node(CosStream::StreamIO_ptr sio, CosLifeCycle::FactoryFinder_ptr there, - CosGraphs::Node::Roles*& rolesOfNode); + CosGraphs::Node::Roles_out rolesOfNode); }; @@ -73,7 +73,7 @@ friend void CosCompoundExternalization_impl::Node_impl::internalize_node(CosStream::StreamIO_ptr sio, CosLifeCycle::FactoryFinder_ptr there, - CosGraphs::Node::Roles*& rolesOfNode); + CosGraphs::Node::Roles_out rolesOfNode); virtual void externalize_role(CosStream::StreamIO_ptr sio); virtual void internalize_role(CosStream::StreamIO_ptr sio); --- coss/externalization/CompoundExternalization_impl.cc.orig Sat Jul 5 23:14:13 2003 +++ coss/externalization/CompoundExternalization_impl.cc Sat Jul 5 23:51:29 2003 @@ -111,7 +111,7 @@ void CosCompoundExternalization_impl::Node_impl::internalize_node(CosStream::StreamIO_ptr sio, CosLifeCycle::FactoryFinder_ptr there, - CosGraphs::Node::Roles*& rolesOfNode) + CosGraphs::Node::Roles_out rolesOfNode) { // Node read its non-object data using the primitive StreamIO::read_...(data) function random_id = sio -> read_unsigned_long();