[sword-cvs] sword/bindings/corba/orbitcpp swordorb-impl.cpp,1.9,1.10

sword@www.crosswire.org sword@www.crosswire.org
Sat, 25 Oct 2003 16:52:16 -0700


Update of /usr/local/cvsroot/sword/bindings/corba/orbitcpp
In directory www:/tmp/cvs-serv21521

Modified Files:
	swordorb-impl.cpp 
Log Message:
Added body of GlobalOption functions


Index: swordorb-impl.cpp
===================================================================
RCS file: /usr/local/cvsroot/sword/bindings/corba/orbitcpp/swordorb-impl.cpp,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -d -r1.9 -r1.10
--- swordorb-impl.cpp	31 Aug 2003 01:58:13 -0000	1.9
+++ swordorb-impl.cpp	25 Oct 2003 23:52:14 -0000	1.10
@@ -66,10 +66,34 @@
 
 
 StringList *SWMgr_impl::getGlobalOptions() throw(CORBA::SystemException) {
+	sword::StringList options = delegate->getGlobalOptions();
+	StringList *retVal = new StringList;
+	int count = 0;
+	for (sword::StringList::iterator it = options.begin(); it != options.end(); it++) {
+		count++;
+	}
+	retVal->length(count);
+	count = 0;
+	for (sword::StringList::iterator it = options.begin(); it != options.end(); it++) {
+		(*retVal)[count++] = CORBA::string_dup(it->c_str());
+	}
+	return retVal;
 }
 
 
 StringList *SWMgr_impl::getGlobalOptionValues(const char *option) throw(CORBA::SystemException) {
+	sword::StringList options = delegate->getGlobalOptionValues(option);
+	StringList *retVal = new StringList;
+	int count = 0;
+	for (sword::StringList::iterator it = options.begin(); it != options.end(); it++) {
+		count++;
+	}
+	retVal->length(count);
+	count = 0;
+	for (sword::StringList::iterator it = options.begin(); it != options.end(); it++) {
+		(*retVal)[count++] = CORBA::string_dup(it->c_str());
+	}
+	return retVal;
 }