objecthandler-cvs Mailing List for ObjectHandler
Brought to you by:
ericehlers,
nando
You can subscribe to this list here.
2006 |
Jan
|
Feb
|
Mar
|
Apr
|
May
(115) |
Jun
(109) |
Jul
(85) |
Aug
(49) |
Sep
(19) |
Oct
(105) |
Nov
(16) |
Dec
(43) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2007 |
Jan
(63) |
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
From: Eric E. <eri...@us...> - 2007-01-12 10:12:52
|
Update of /cvsroot/objecthandler/ObjectHandler/oh In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv21583/oh Added Files: demo.hpp Log Message: rename demo.*pp to ohthing.*pp to avoid name conflict with autogenerated demo.cpp --- NEW FILE: demo.hpp --- /* Copyright (C) 2007 Eric Ehlers This file is part of QuantLib, a free-software/open-source library for financial quantitative analysts and developers - http://quantlib.org/ QuantLib is free software: you can redistribute it and/or modify it under the terms of the QuantLib license. You should have received a copy of the license along with this program; if not, please email qua...@li... The license is also available online at http://quantlib.org/html/license.html This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the license for more details. */ #ifndef oh_demo_hpp #define oh_demo_hpp #include <oh/exception.hpp> // temporary dummy file to keep vo_demo.cpp happy // pending fix to gensrc #endif |
From: Eric E. <eri...@us...> - 2007-01-12 10:00:59
|
Update of /cvsroot/objecthandler/ObjectHandler/oh In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv15790/oh Modified Files: Makefile.am Added Files: ohthing.cpp ohthing.hpp Removed Files: demo.cpp demo.hpp Log Message: rename demo.*pp to ohthing.*pp to avoid name conflict with autogenerated demo.cpp --- demo.cpp DELETED --- --- NEW FILE: ohthing.cpp --- /* Copyright (C) 2007 Eric Ehlers This file is part of QuantLib, a free-software/open-source library for financial quantitative analysts and developers - http://quantlib.org/ QuantLib is free software: you can redistribute it and/or modify it under the terms of the QuantLib license. You should have received a copy of the license along with this program; if not, please email qua...@li... The license is also available online at http://quantlib.org/html/license.html This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the license for more details. */ #include <oh/ohthing.hpp> namespace ObjHandler { std::string Thing::ohThingFunc0(const std::string &p0) { return p0; } double Thing::ohThingFunc1(const double &p0) { return p0; } std::string Thing::ohThingFunc2(const std::string &p0, const std::string &p1, const std::string &p2) { return p0 + " | " + p1 + " | " + p2; } std::string Thing::ohThingFunc3(const std::string &p0, const std::vector<std::string> &p1) { std::string ret = p0; for (std::vector<std::string>::const_iterator i = p1.begin(); i != p1.end(); i++) { ret += " | " + *i; } return ret; } std::vector<std::string> Thing::ohThingFunc4(const std::string &p0, const std::vector<std::string> &p1) { std::vector<std::string> ret; for (std::vector<std::string>::const_iterator i = p1.begin(); i != p1.end(); i++) { ret.push_back(*i + " | " + p0); } return ret; } std::string Thing::ohThingFunc5(const std::string &p0, const std::string &p1) { return p0 + " | " + p1; } std::vector<std::string> Thing::ohThingFunc6(const std::string &p0) { std::vector<std::string> ret; ret.push_back(p0); return ret; } } --- NEW FILE: ohthing.hpp --- /* Copyright (C) 2007 Ferdinando Ametrano Copyright (C) 2006, 2007 Eric Ehlers This file is part of QuantLib, a free-software/open-source library for financial quantitative analysts and developers - http://quantlib.org/ QuantLib is free software: you can redistribute it and/or modify it under the terms of the QuantLib license. You should have received a copy of the license along with this program; if not, please email qua...@li... The license is also available online at http://quantlib.org/html/license.html This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the license for more details. */ #ifndef oh_ohthing_hpp #define oh_ohthing_hpp #include <oh/object.hpp> namespace ObjHandler { class Thing : public Object { public: Thing(const std::string& stringParam, double doubleParam) : stringParameter_(stringParam), doubleParameter_(doubleParam) {}; const std::string& stringParameter() { return stringParameter_; } const std::string& setStringParameter(const std::string& stringPar) { stringParameter_ = stringPar; return stringParameter_; } double doubleParameter() { return doubleParameter_; } double setDoubleParameter(double doubleParam) { doubleParameter_ = doubleParam; return doubleParameter_; } std::string ohThingFunc0(const std::string &); double ohThingFunc1(const double &); std::string ohThingFunc2(const std::string &, const std::string &, const std::string &); std::string ohThingFunc3(const std::string &, const std::vector<std::string> &); std::vector<std::string> ohThingFunc4(const std::string &, const std::vector<std::string> &); std::string ohThingFunc5(const std::string &, const std::string &); std::vector<std::string> ohThingFunc6(const std::string &); private: std::string stringParameter_; double doubleParameter_; }; } #endif --- demo.hpp DELETED --- Index: Makefile.am =================================================================== RCS file: /cvsroot/objecthandler/ObjectHandler/oh/Makefile.am,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** Makefile.am 28 Aug 2006 10:02:16 -0000 1.3 --- Makefile.am 12 Jan 2007 10:00:52 -0000 1.4 *************** *** 10,13 **** --- 10,14 ---- objhandlerdefines.hpp \ objhandler.hpp \ + ohthing.hpp \ singleton.hpp \ utilities.hpp \ *************** *** 25,28 **** --- 26,30 ---- object.cpp \ objecthandler.cpp \ + ohthing.cpp \ utilities.cpp |
From: Eric E. <eri...@us...> - 2007-01-12 10:00:58
|
Update of /cvsroot/objecthandler/ObjectHandler/gensrc/metadata In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv15790/gensrc/metadata Modified Files: demo.xml Log Message: rename demo.*pp to ohthing.*pp to avoid name conflict with autogenerated demo.cpp Index: demo.xml =================================================================== RCS file: /cvsroot/objecthandler/ObjectHandler/gensrc/metadata/demo.xml,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** demo.xml 12 Jan 2007 08:33:43 -0000 1.7 --- demo.xml 12 Jan 2007 10:00:52 -0000 1.8 *************** *** 3,10 **** <displayName>Demo</displayName> <xlFunctionWizardCategory>ObjectHandler</xlFunctionWizardCategory> ! <copyright> Copyright (C) 2007 Ferdinando Ametrano ! Copyright (C) 2006 Eric Ehlers </copyright> --- 3,12 ---- <displayName>Demo</displayName> <xlFunctionWizardCategory>ObjectHandler</xlFunctionWizardCategory> ! <includes> ! <include>oh/ohthing.hpp</include> ! </includes> <copyright> Copyright (C) 2007 Ferdinando Ametrano ! Copyright (C) 2006, 2007 Eric Ehlers </copyright> |
From: Eric E. <eri...@us...> - 2007-01-12 10:00:55
|
Update of /cvsroot/objecthandler/ObjectHandler/ohxl/ohxllib In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv15790/ohxl/ohxllib Modified Files: ohxllib.vcproj ohxllib_vc8.vcproj Log Message: rename demo.*pp to ohthing.*pp to avoid name conflict with autogenerated demo.cpp Index: ohxllib_vc8.vcproj =================================================================== RCS file: /cvsroot/objecthandler/ObjectHandler/ohxl/ohxllib/ohxllib_vc8.vcproj,v retrieving revision 1.22 retrieving revision 1.23 diff -C2 -d -r1.22 -r1.23 *** ohxllib_vc8.vcproj 12 Jan 2007 08:33:44 -0000 1.22 --- ohxllib_vc8.vcproj 12 Jan 2007 10:00:52 -0000 1.23 *************** *** 329,337 **** > <File ! RelativePath="..\..\oh\demo.cpp" > </File> <File ! RelativePath="..\..\oh\demo.hpp" > </File> --- 329,337 ---- > <File ! RelativePath="..\..\oh\ohthing.cpp" > </File> <File ! RelativePath="..\..\oh\ohthing.hpp" > </File> Index: ohxllib.vcproj =================================================================== RCS file: /cvsroot/objecthandler/ObjectHandler/ohxl/ohxllib/ohxllib.vcproj,v retrieving revision 1.18 retrieving revision 1.19 diff -C2 -d -r1.18 -r1.19 *** ohxllib.vcproj 12 Jan 2007 08:33:44 -0000 1.18 --- ohxllib.vcproj 12 Jan 2007 10:00:52 -0000 1.19 *************** *** 338,342 **** Filter=""> <File ! RelativePath="..\..\oh\demo.hpp"> </File> <File --- 338,345 ---- Filter=""> <File ! RelativePath="..\..\oh\ohthing.cpp"> ! </File> ! <File ! RelativePath="..\..\oh\ohthing.hpp"> </File> <File |
From: Eric E. <eri...@us...> - 2007-01-12 10:00:55
|
Update of /cvsroot/objecthandler/ObjectHandler In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv15790 Modified Files: ohlib.vcproj ohlib_vc8.vcproj Log Message: rename demo.*pp to ohthing.*pp to avoid name conflict with autogenerated demo.cpp Index: ohlib.vcproj =================================================================== RCS file: /cvsroot/objecthandler/ObjectHandler/ohlib.vcproj,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -d -r1.8 -r1.9 *** ohlib.vcproj 12 Jan 2007 08:33:43 -0000 1.8 --- ohlib.vcproj 12 Jan 2007 10:00:52 -0000 1.9 *************** *** 335,342 **** </File> <File ! RelativePath="oh\demo.cpp"> </File> <File ! RelativePath="oh\demo.hpp"> </File> <File --- 335,342 ---- </File> <File ! RelativePath="oh\ohthing.cpp"> </File> <File ! RelativePath="oh\ohthing.hpp"> </File> <File Index: ohlib_vc8.vcproj =================================================================== RCS file: /cvsroot/objecthandler/ObjectHandler/ohlib_vc8.vcproj,v retrieving revision 1.10 retrieving revision 1.11 diff -C2 -d -r1.10 -r1.11 *** ohlib_vc8.vcproj 12 Jan 2007 08:33:43 -0000 1.10 --- ohlib_vc8.vcproj 12 Jan 2007 10:00:52 -0000 1.11 *************** *** 327,335 **** </File> <File ! RelativePath="oh\demo.cpp" > </File> <File ! RelativePath="oh\demo.hpp" > </File> --- 327,335 ---- </File> <File ! RelativePath="oh\ohthing.cpp" > </File> <File ! RelativePath="oh\ohthing.hpp" > </File> |
From: Eric E. <eri...@us...> - 2007-01-12 08:33:46
|
Update of /cvsroot/objecthandler/ObjectHandler/ohxl In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv10361/ohxl Modified Files: Makefile.am Added Files: loop.hpp Log Message: - transfer from QLXL to OHXL the infrastructure for looping behavior - supplement ohThing() with additional member functions for testing loops --- NEW FILE: loop.hpp --- /* Copyright (C) 2006, 2007 Eric Ehlers This file is part of QuantLib, a free-software/open-source library for financial quantitative analysts and developers - http://quantlib.org/ QuantLib is free software: you can redistribute it and/or modify it under the terms of the QuantLib license. You should have received a copy of the license along with this program; if not, please email qua...@li... The license is also available online at http://quantlib.org/html/license.html This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the license for more details. */ #ifndef ohxl_loop_hpp #define ohxl_loop_hpp #include <ohxl/objhandlerxl.hpp> namespace ObjHandler { template<class LoopFunction, class InputType, class OutputType> void loopIteration( LoopFunction &loopFunction, XLOPER &xIn, XLOPER &xOut) { InputType inputItem; operToScalar(xIn, inputItem); OutputType returnItem = loopFunction(inputItem); scalarToOper(returnItem, xOut); } template<class LoopFunction, class InputType, class OutputType> void loop(FunctionCall &functionCall, LoopFunction &loopFunction, OPER *xIn, XLOPER &xOut) { OPER xTemp, *xMulti; bool needToFree = false; bool errorInitialized = false; // if the input is an array then take its address & carry on if (xIn->xltype == xltypeMulti) { xMulti = xIn; // if the input is a scalar then just call the function once & return } else if (xIn->xltype == xltypeNum || xIn->xltype == xltypeStr || xIn->xltype == xltypeBool) { loopIteration<LoopFunction, InputType, OutputType>( loopFunction, *xIn, xOut); return; // some other input (e.g. a reference) - try to convert to an array } else { Excel(xlCoerce, &xTemp, 2, xIn, TempInt(xltypeMulti)); xMulti = &xTemp; needToFree = true; } xOut.val.array.rows = xMulti->val.array.rows; xOut.val.array.columns = xMulti->val.array.columns; int numCells = xMulti->val.array.rows * xMulti->val.array.columns; xOut.val.array.lparray = new XLOPER[numCells]; if (!xOut.val.array.lparray) { if (needToFree) Excel(xlFree, 0, 1, &xTemp); throw Exception("error on call to new"); } xOut.xltype = xltypeMulti | xlbitDLLFree; for (int i=0; i<numCells; i++) { try { loopIteration<LoopFunction, InputType, OutputType>( loopFunction, xMulti->val.array.lparray[i], xOut.val.array.lparray[i]); } catch(const std::exception &e) { std::ostringstream err; if (!errorInitialized) { ObjectHandlerXL::instance().clearError(); err << functionCall.getFunctionName() << " - " << functionCall.getAddressString() << std::endl << std::endl; errorInitialized = true; } err << "iteration #" << i << " - " << e.what(); ObjectHandlerXL::instance().logError(err.str(), true); xOut.val.array.lparray[i].xltype = xltypeErr; xOut.val.array.lparray[i].val.err = xlerrNum; } } // free memory if (needToFree) Excel(xlFree, 0, 1, &xTemp); } } #endif Index: Makefile.am =================================================================== RCS file: /cvsroot/objecthandler/ObjectHandler/ohxl/Makefile.am,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** Makefile.am 3 Oct 2006 18:29:33 -0000 1.4 --- Makefile.am 12 Jan 2007 08:33:43 -0000 1.5 *************** *** 9,12 **** --- 9,13 ---- functioncall.hpp \ functioncount.hpp \ + loop.hpp \ objecthandlerxl.cpp \ objecthandlerxl.hpp \ |
From: Eric E. <eri...@us...> - 2007-01-12 08:33:45
|
Update of /cvsroot/objecthandler/ObjectHandler/oh In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv10361/oh Modified Files: demo.hpp Added Files: demo.cpp Log Message: - transfer from QLXL to OHXL the infrastructure for looping behavior - supplement ohThing() with additional member functions for testing loops --- NEW FILE: demo.cpp --- /* Copyright (C) 2007 Eric Ehlers This file is part of QuantLib, a free-software/open-source library for financial quantitative analysts and developers - http://quantlib.org/ QuantLib is free software: you can redistribute it and/or modify it under the terms of the QuantLib license. You should have received a copy of the license along with this program; if not, please email qua...@li... The license is also available online at http://quantlib.org/html/license.html This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the license for more details. */ #include <oh/demo.hpp> namespace ObjHandler { std::string Thing::ohThingFunc0(const std::string &p0) { return p0; } double Thing::ohThingFunc1(const double &p0) { return p0; } std::string Thing::ohThingFunc2(const std::string &p0, const std::string &p1, const std::string &p2) { return p0 + " | " + p1 + " | " + p2; } std::string Thing::ohThingFunc3(const std::string &p0, const std::vector<std::string> &p1) { std::string ret = p0; for (std::vector<std::string>::const_iterator i = p1.begin(); i != p1.end(); i++) { ret += " | " + *i; } return ret; } std::vector<std::string> Thing::ohThingFunc4(const std::string &p0, const std::vector<std::string> &p1) { std::vector<std::string> ret; for (std::vector<std::string>::const_iterator i = p1.begin(); i != p1.end(); i++) { ret.push_back(*i + " | " + p0); } return ret; } std::string Thing::ohThingFunc5(const std::string &p0, const std::string &p1) { return p0 + " | " + p1; } std::vector<std::string> Thing::ohThingFunc6(const std::string &p0) { std::vector<std::string> ret; ret.push_back(p0); return ret; } } Index: demo.hpp =================================================================== RCS file: /cvsroot/objecthandler/ObjectHandler/oh/demo.hpp,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** demo.hpp 2 Jan 2007 10:59:39 -0000 1.2 --- demo.hpp 12 Jan 2007 08:33:43 -0000 1.3 *************** *** 39,42 **** --- 39,50 ---- return doubleParameter_; } + + std::string ohThingFunc0(const std::string &); + double ohThingFunc1(const double &); + std::string ohThingFunc2(const std::string &, const std::string &, const std::string &); + std::string ohThingFunc3(const std::string &, const std::vector<std::string> &); + std::vector<std::string> ohThingFunc4(const std::string &, const std::vector<std::string> &); + std::string ohThingFunc5(const std::string &, const std::string &); + std::vector<std::string> ohThingFunc6(const std::string &); private: std::string stringParameter_; |
From: Eric E. <eri...@us...> - 2007-01-12 08:33:45
|
Update of /cvsroot/objecthandler/ObjectHandler/gensrc/config In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv10361/gensrc/config Modified Files: config.xml Log Message: - transfer from QLXL to OHXL the infrastructure for looping behavior - supplement ohThing() with additional member functions for testing loops Index: config.xml =================================================================== RCS file: /cvsroot/objecthandler/ObjectHandler/gensrc/config/config.xml,v retrieving revision 1.9 retrieving revision 1.10 diff -C2 -d -r1.9 -r1.10 *** config.xml 3 Dec 2006 21:08:45 -0000 1.9 --- config.xml 12 Jan 2007 08:33:43 -0000 1.10 *************** *** 4,8 **** --- 4,10 ---- <excelRootDirectory>ohxl</excelRootDirectory> <namespaceObjects>ObjHandler</namespaceObjects> + <namespaceLibrary>ObjHandler</namespaceLibrary> <voRootDirectory>oh/ValueObjects</voRootDirectory> + <loopRootDirectory>oh/Loop</loopRootDirectory> <libRootDirectory>oh</libRootDirectory> |
From: Eric E. <eri...@us...> - 2007-01-12 08:33:45
|
Update of /cvsroot/objecthandler/ObjectHandler/oh/Loop In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv10361/oh/Loop Added Files: .cvsignore Log Message: - transfer from QLXL to OHXL the infrastructure for looping behavior - supplement ohThing() with additional member functions for testing loops --- NEW FILE: .cvsignore --- loop_demo.hpp |
From: Eric E. <eri...@us...> - 2007-01-12 08:33:45
|
Update of /cvsroot/objecthandler/ObjectHandler/gensrc/scripts In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv10361/gensrc/scripts Modified Files: gensrc.py Log Message: - transfer from QLXL to OHXL the infrastructure for looping behavior - supplement ohThing() with additional member functions for testing loops Index: gensrc.py =================================================================== RCS file: /cvsroot/objecthandler/ObjectHandler/gensrc/scripts/gensrc.py,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** gensrc.py 3 Dec 2006 14:35:02 -0000 1.4 --- gensrc.py 12 Jan 2007 08:33:43 -0000 1.5 *************** *** 21,24 **** --- 21,25 ---- import utilities import valueobjects + import loop config.Config.getInstance().initialize() *************** *** 28,31 **** --- 29,33 ---- addins.append(utilities.serializeObject(addindoxygen.AddinDoxygen)) addins.append(utilities.serializeObject(valueobjects.ValueObjects)) + addins.append(utilities.serializeObject(loop.Loop)) utilities.generate(addins) |
From: Eric E. <eri...@us...> - 2007-01-12 08:33:45
|
Update of /cvsroot/objecthandler/ObjectHandler/ohxl/ohxllib In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv10361/ohxl/ohxllib Modified Files: ohxllib.vcproj ohxllib_vc8.vcproj Log Message: - transfer from QLXL to OHXL the infrastructure for looping behavior - supplement ohThing() with additional member functions for testing loops Index: ohxllib_vc8.vcproj =================================================================== RCS file: /cvsroot/objecthandler/ObjectHandler/ohxl/ohxllib/ohxllib_vc8.vcproj,v retrieving revision 1.21 retrieving revision 1.22 diff -C2 -d -r1.21 -r1.22 *** ohxllib_vc8.vcproj 4 Jan 2007 11:18:36 -0000 1.21 --- ohxllib_vc8.vcproj 12 Jan 2007 08:33:44 -0000 1.22 *************** *** 329,332 **** --- 329,336 ---- > <File + RelativePath="..\..\oh\demo.cpp" + > + </File> + <File RelativePath="..\..\oh\demo.hpp" > *************** *** 421,424 **** --- 425,436 ---- </File> </Filter> + <Filter + Name="Loop" + > + <File + RelativePath="..\..\oh\Loop\loop_demo.hpp" + > + </File> + </Filter> </Filter> <Filter *************** *** 589,592 **** --- 601,612 ---- </File> </Filter> + <Filter + Name="Loop" + > + <File + RelativePath="..\loop.hpp" + > + </File> + </Filter> </Filter> </Files> Index: ohxllib.vcproj =================================================================== RCS file: /cvsroot/objecthandler/ObjectHandler/ohxl/ohxllib/ohxllib.vcproj,v retrieving revision 1.17 retrieving revision 1.18 diff -C2 -d -r1.17 -r1.18 *** ohxllib.vcproj 14 Dec 2006 12:27:36 -0000 1.17 --- ohxllib.vcproj 12 Jan 2007 08:33:44 -0000 1.18 *************** *** 532,535 **** --- 532,542 ---- </File> </Filter> + <Filter + Name="Loop" + Filter=""> + <File + RelativePath="..\loop.hpp"> + </File> + </Filter> </Filter> </Files> |
From: Eric E. <eri...@us...> - 2007-01-12 08:33:44
|
Update of /cvsroot/objecthandler/ObjectHandler In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv10361 Modified Files: ohlib.vcproj ohlib_vc8.vcproj Log Message: - transfer from QLXL to OHXL the infrastructure for looping behavior - supplement ohThing() with additional member functions for testing loops Index: ohlib.vcproj =================================================================== RCS file: /cvsroot/objecthandler/ObjectHandler/ohlib.vcproj,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** ohlib.vcproj 14 Dec 2006 12:27:35 -0000 1.7 --- ohlib.vcproj 12 Jan 2007 08:33:43 -0000 1.8 *************** *** 335,338 **** --- 335,344 ---- </File> <File + RelativePath="oh\demo.cpp"> + </File> + <File + RelativePath="oh\demo.hpp"> + </File> + <File RelativePath="oh\exception.cpp"> </File> Index: ohlib_vc8.vcproj =================================================================== RCS file: /cvsroot/objecthandler/ObjectHandler/ohlib_vc8.vcproj,v retrieving revision 1.9 retrieving revision 1.10 diff -C2 -d -r1.9 -r1.10 *** ohlib_vc8.vcproj 2 Jan 2007 11:01:04 -0000 1.9 --- ohlib_vc8.vcproj 12 Jan 2007 08:33:43 -0000 1.10 *************** *** 323,327 **** <Files> <File ! RelativePath=".\oh\auto_link.hpp" > </File> --- 323,335 ---- <Files> <File ! RelativePath="oh\auto_link.hpp" ! > ! </File> ! <File ! RelativePath="oh\demo.cpp" ! > ! </File> ! <File ! RelativePath="oh\demo.hpp" > </File> *************** *** 335,339 **** </File> <File ! RelativePath=".\oh\iless.hpp" > </File> --- 343,347 ---- </File> <File ! RelativePath="oh\iless.hpp" > </File> *************** *** 383,387 **** </File> <File ! RelativePath=".\oh\valueobject.hpp" > </File> --- 391,395 ---- </File> <File ! RelativePath="oh\valueobject.hpp" > </File> |
From: Eric E. <eri...@us...> - 2007-01-12 08:33:44
|
Update of /cvsroot/objecthandler/ObjectHandler/gensrc/metadata In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv10361/gensrc/metadata Modified Files: demo.xml Log Message: - transfer from QLXL to OHXL the infrastructure for looping behavior - supplement ohThing() with additional member functions for testing loops Index: demo.xml =================================================================== RCS file: /cvsroot/objecthandler/ObjectHandler/gensrc/metadata/demo.xml,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** demo.xml 11 Jan 2007 11:25:14 -0000 1.6 --- demo.xml 12 Jan 2007 08:33:43 -0000 1.7 *************** *** 104,108 **** --- 104,281 ---- </Member> + <Member name='ohThingFunc0' objectClass='Thing'> + <description></description> + <libraryFunction>ohThingFunc0</libraryFunction> + <SupportedPlatforms> + <Excel calcInWizard='false' /> + </SupportedPlatforms> + <ParameterList> + <Parameters> + <Parameter name='p0'> + <type>string</type> + <tensorRank>scalar</tensorRank> + <description></description> + </Parameter> + </Parameters> + </ParameterList> + <ReturnValue> + <type>string</type> + <tensorRank>scalar</tensorRank> + </ReturnValue> + </Member> + + <Member name='ohThingFunc1' objectClass='Thing'> + <description></description> + <libraryFunction>ohThingFunc1</libraryFunction> + <SupportedPlatforms> + <Excel calcInWizard='false' /> + </SupportedPlatforms> + <ParameterList> + <Parameters> + <Parameter name='p0'> + <type>double</type> + <tensorRank>scalar</tensorRank> + <description></description> + </Parameter> + </Parameters> + </ParameterList> + <ReturnValue> + <type>double</type> + <tensorRank>scalar</tensorRank> + </ReturnValue> + </Member> + + <Member name='ohThingFunc2' objectClass='Thing'> + <description></description> + <libraryFunction>ohThingFunc2</libraryFunction> + <SupportedPlatforms> + <Excel calcInWizard='false' /> + </SupportedPlatforms> + <ParameterList> + <Parameters> + <Parameter name='p0'> + <type>string</type> + <tensorRank>scalar</tensorRank> + <description></description> + </Parameter> + <Parameter name='p1'> + <type>string</type> + <tensorRank>scalar</tensorRank> + <description></description> + </Parameter> + <Parameter name='p2'> + <type>string</type> + <tensorRank>scalar</tensorRank> + <description></description> + </Parameter> + </Parameters> + </ParameterList> + <ReturnValue> + <type>string</type> + <tensorRank>scalar</tensorRank> + </ReturnValue> + </Member> + + <Member name='ohThingFunc3' objectClass='Thing'> + <description></description> + <libraryFunction>ohThingFunc3</libraryFunction> + <SupportedPlatforms> + <Excel calcInWizard='false' /> + </SupportedPlatforms> + <ParameterList> + <Parameters> + <Parameter name='p0'> + <type>string</type> + <tensorRank>scalar</tensorRank> + <description></description> + </Parameter> + <Parameter name='p1'> + <type>string</type> + <tensorRank>vector</tensorRank> + <description></description> + </Parameter> + </Parameters> + </ParameterList> + <ReturnValue> + <type>string</type> + <tensorRank>scalar</tensorRank> + </ReturnValue> + </Member> + + <Member name='ohThingFunc4' objectClass='Thing'> + <description></description> + <libraryFunction>ohThingFunc4</libraryFunction> + <SupportedPlatforms> + <Excel calcInWizard='false' /> + </SupportedPlatforms> + <ParameterList> + <Parameters> + <Parameter name='p0'> + <type>string</type> + <tensorRank>scalar</tensorRank> + <description></description> + </Parameter> + <Parameter name='p1'> + <type>string</type> + <tensorRank>vector</tensorRank> + <description></description> + </Parameter> + </Parameters> + </ParameterList> + <ReturnValue> + <type>string</type> + <tensorRank>vector</tensorRank> + </ReturnValue> + </Member> + + <Member name='ohThingFunc5' objectClass='Thing' loopParameter='p1'> + <description></description> + <libraryFunction>ohThingFunc5</libraryFunction> + <SupportedPlatforms> + <Excel calcInWizard='false' /> + </SupportedPlatforms> + <ParameterList> + <Parameters> + <Parameter name='p0'> + <type>string</type> + <tensorRank>scalar</tensorRank> + <description></description> + </Parameter> + <Parameter name='p1'> + <type>string</type> + <tensorRank>vector</tensorRank> + <description></description> + </Parameter> + </Parameters> + </ParameterList> + <ReturnValue> + <type>string</type> + <tensorRank>vector</tensorRank> + </ReturnValue> + </Member> + + <Member name='ohThingFunc6' objectClass='Thing'> + <description></description> + <libraryFunction>ohThingFunc6</libraryFunction> + <SupportedPlatforms> + <Excel calcInWizard='false' /> + </SupportedPlatforms> + <ParameterList> + <Parameters> + <Parameter name='p0'> + <type>string</type> + <tensorRank>scalar</tensorRank> + <description></description> + </Parameter> + </Parameters> + </ParameterList> + <ReturnValue> + <type>string</type> + <tensorRank>vector</tensorRank> + </ReturnValue> + </Member> + </Functions> </Category> + |
From: Eric E. <eri...@us...> - 2007-01-11 16:25:29
|
Update of /cvsroot/objecthandler/ObjectHandler/oh/Loop In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv14261/Loop Log Message: Directory /cvsroot/objecthandler/ObjectHandler/oh/Loop added to the repository |
From: Ferdinando A. <na...@us...> - 2007-01-11 11:25:16
|
Update of /cvsroot/objecthandler/ObjectHandler/gensrc/metadata In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv17023/gensrc/metadata Modified Files: demo.xml ohutils.xml valueobjects.xml Log Message: setting calcInWizard='true' where possible Index: valueobjects.xml =================================================================== RCS file: /cvsroot/objecthandler/ObjectHandler/gensrc/metadata/valueobjects.xml,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** valueobjects.xml 10 Jan 2007 17:39:29 -0000 1.3 --- valueobjects.xml 11 Jan 2007 11:25:15 -0000 1.4 *************** *** 18,22 **** <libraryFunction>propertyNames</libraryFunction> <SupportedPlatforms> ! <Excel calcInWizard='false' /> </SupportedPlatforms> <ParameterList> --- 18,22 ---- <libraryFunction>propertyNames</libraryFunction> <SupportedPlatforms> ! <Excel calcInWizard='true' /> </SupportedPlatforms> <ParameterList> Index: demo.xml =================================================================== RCS file: /cvsroot/objecthandler/ObjectHandler/gensrc/metadata/demo.xml,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** demo.xml 10 Jan 2007 17:39:28 -0000 1.5 --- demo.xml 11 Jan 2007 11:25:14 -0000 1.6 *************** *** 36,40 **** <libraryFunction>stringParameter</libraryFunction> <SupportedPlatforms> ! <Excel calcInWizard='false' /> </SupportedPlatforms> <ParameterList> --- 36,40 ---- <libraryFunction>stringParameter</libraryFunction> <SupportedPlatforms> ! <Excel calcInWizard='true' /> </SupportedPlatforms> <ParameterList> *************** *** 72,76 **** <libraryFunction>doubleParameter</libraryFunction> <SupportedPlatforms> ! <Excel calcInWizard='false' /> </SupportedPlatforms> <ParameterList> --- 72,76 ---- <libraryFunction>doubleParameter</libraryFunction> <SupportedPlatforms> ! <Excel calcInWizard='true' /> </SupportedPlatforms> <ParameterList> Index: ohutils.xml =================================================================== RCS file: /cvsroot/objecthandler/ObjectHandler/gensrc/metadata/ohutils.xml,v retrieving revision 1.10 retrieving revision 1.11 diff -C2 -d -r1.10 -r1.11 *** ohutils.xml 10 Jan 2007 17:39:29 -0000 1.10 --- ohutils.xml 11 Jan 2007 11:25:14 -0000 1.11 *************** *** 120,124 **** <alias>ObjHandler::ObjectHandlerXL::instance().objectCount</alias> <SupportedPlatforms> ! <Excel calcInWizard='false' /> </SupportedPlatforms> <ParameterList> --- 120,124 ---- <alias>ObjHandler::ObjectHandlerXL::instance().objectCount</alias> <SupportedPlatforms> ! <Excel calcInWizard='true' /> </SupportedPlatforms> <ParameterList> *************** *** 235,239 **** <alias>ObjHandler::version</alias> <SupportedPlatforms> ! <Excel calcInWizard='false' /> </SupportedPlatforms> <ParameterList> --- 235,239 ---- <alias>ObjHandler::version</alias> <SupportedPlatforms> ! <Excel calcInWizard='true' /> </SupportedPlatforms> <ParameterList> |
From: Ferdinando A. <na...@us...> - 2007-01-11 11:24:27
|
Update of /cvsroot/objecthandler/ObjectHandler/ohxl/Functions In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv16510/ohxl/Functions Modified Files: manual.cpp Log Message: in synch with latest FunctionCall policy Index: manual.cpp =================================================================== RCS file: /cvsroot/objecthandler/ObjectHandler/ohxl/Functions/manual.cpp,v retrieving revision 1.16 retrieving revision 1.17 diff -C2 -d -r1.16 -r1.17 *** manual.cpp 3 Jan 2007 16:25:02 -0000 1.16 --- manual.cpp 11 Jan 2007 11:24:26 -0000 1.17 *************** *** 78,82 **** OPER *dummy9) { ! boost::shared_ptr<ObjHandler::FunctionCall> functionCall; try { --- 78,83 ---- OPER *dummy9) { ! //boost::shared_ptr<ObjHandler::FunctionCall> functionCall; ! ObjHandler::FunctionCall functionCall("ohTrigger"); try { *************** *** 84,91 **** // initialize Function Call object ! functionCall = boost::shared_ptr<ObjHandler::FunctionCall> ! ( new ObjHandler::FunctionCall("ohTrigger") ); ! if (functionCall->IsCalledByFuncWiz()) ! return 0; // reset the calling cell --- 85,92 ---- // initialize Function Call object ! //functionCall = boost::shared_ptr<ObjHandler::FunctionCall> ! // ( new ObjHandler::FunctionCall("ohTrigger") ); ! //if (functionCall->IsCalledByFuncWiz()) ! // return 0; // reset the calling cell *************** *** 144,148 **** XLL_DEC OPER *ohPack(OPER *xInputRange) { ! boost::shared_ptr < ObjHandler::FunctionCall > functionCall; OPER xMulti; static OPER xRet; --- 145,150 ---- XLL_DEC OPER *ohPack(OPER *xInputRange) { ! ObjHandler::FunctionCall functionCall("ohPack"); ! //boost::shared_ptr < ObjHandler::FunctionCall > functionCall; OPER xMulti; static OPER xRet; *************** *** 150,155 **** try { ! functionCall = boost::shared_ptr < ObjHandler::FunctionCall > ! ( new ObjHandler::FunctionCall("ohPack") ); Excel(xlCoerce, &xMulti, 2, xInputRange, TempInt(xltypeMulti)); --- 152,157 ---- try { ! //functionCall = boost::shared_ptr < ObjHandler::FunctionCall > ! // ( new ObjHandler::FunctionCall("ohPack") ); Excel(xlCoerce, &xMulti, 2, xInputRange, TempInt(xltypeMulti)); |
From: Eric E. <eri...@us...> - 2007-01-10 17:39:32
|
Update of /cvsroot/objecthandler/ObjectHandler/gensrc/metadata In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv32643/gensrc/metadata Modified Files: demo.xml garbagecollection.xml logging.xml ohutils.xml valueobjects.xml Log Message: change checkForFunctionWizard='true' to calcInWizard='false' so Nando doesn't get confused Index: valueobjects.xml =================================================================== RCS file: /cvsroot/objecthandler/ObjectHandler/gensrc/metadata/valueobjects.xml,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** valueobjects.xml 10 Jan 2007 16:40:31 -0000 1.2 --- valueobjects.xml 10 Jan 2007 17:39:29 -0000 1.3 *************** *** 18,22 **** <libraryFunction>propertyNames</libraryFunction> <SupportedPlatforms> ! <Excel checkForFunctionWizard='true' /> </SupportedPlatforms> <ParameterList> --- 18,22 ---- <libraryFunction>propertyNames</libraryFunction> <SupportedPlatforms> ! <Excel calcInWizard='false' /> </SupportedPlatforms> <ParameterList> *************** *** 33,37 **** <libraryFunction>propertyValue</libraryFunction> <SupportedPlatforms> ! <Excel checkForFunctionWizard='true' /> </SupportedPlatforms> <ParameterList> --- 33,37 ---- <libraryFunction>propertyValue</libraryFunction> <SupportedPlatforms> ! <Excel calcInWizard='false' /> </SupportedPlatforms> <ParameterList> Index: logging.xml =================================================================== RCS file: /cvsroot/objecthandler/ObjectHandler/gensrc/metadata/logging.xml,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** logging.xml 10 Jan 2007 16:40:31 -0000 1.2 --- logging.xml 10 Jan 2007 17:39:29 -0000 1.3 *************** *** 18,22 **** <alias>ObjHandler::logAllObjects</alias> <SupportedPlatforms> ! <Excel checkForFunctionWizard='true' /> </SupportedPlatforms> <ParameterList> --- 18,22 ---- <alias>ObjHandler::logAllObjects</alias> <SupportedPlatforms> ! <Excel calcInWizard='false' /> </SupportedPlatforms> <ParameterList> *************** *** 33,37 **** <alias>ObjHandler::logMessage</alias> <SupportedPlatforms> ! <Excel checkForFunctionWizard='true' /> </SupportedPlatforms> <ParameterList> --- 33,37 ---- <alias>ObjHandler::logMessage</alias> <SupportedPlatforms> ! <Excel calcInWizard='false' /> </SupportedPlatforms> <ParameterList> *************** *** 59,63 **** <alias>ObjHandler::logObject</alias> <SupportedPlatforms> ! <Excel checkForFunctionWizard='true' /> </SupportedPlatforms> <ParameterList> --- 59,63 ---- <alias>ObjHandler::logObject</alias> <SupportedPlatforms> ! <Excel calcInWizard='false' /> </SupportedPlatforms> <ParameterList> *************** *** 80,84 **** <alias>ObjHandler::setLogFile</alias> <SupportedPlatforms> ! <Excel checkForFunctionWizard='true' /> </SupportedPlatforms> <ParameterList> --- 80,84 ---- <alias>ObjHandler::setLogFile</alias> <SupportedPlatforms> ! <Excel calcInWizard='false' /> </SupportedPlatforms> <ParameterList> *************** *** 106,110 **** <alias>ObjHandler::setLogLevel</alias> <SupportedPlatforms> ! <Excel checkForFunctionWizard='true' /> </SupportedPlatforms> <ParameterList> --- 106,110 ---- <alias>ObjHandler::setLogLevel</alias> <SupportedPlatforms> ! <Excel calcInWizard='false' /> </SupportedPlatforms> <ParameterList> Index: demo.xml =================================================================== RCS file: /cvsroot/objecthandler/ObjectHandler/gensrc/metadata/demo.xml,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** demo.xml 10 Jan 2007 16:40:31 -0000 1.4 --- demo.xml 10 Jan 2007 17:39:28 -0000 1.5 *************** *** 14,18 **** <libraryFunction>Thing</libraryFunction> <SupportedPlatforms> ! <Excel checkForFunctionWizard='true' /> </SupportedPlatforms> <ParameterList> --- 14,18 ---- <libraryFunction>Thing</libraryFunction> <SupportedPlatforms> ! <Excel calcInWizard='false' /> </SupportedPlatforms> <ParameterList> *************** *** 36,40 **** <libraryFunction>stringParameter</libraryFunction> <SupportedPlatforms> ! <Excel checkForFunctionWizard='true' /> </SupportedPlatforms> <ParameterList> --- 36,40 ---- <libraryFunction>stringParameter</libraryFunction> <SupportedPlatforms> ! <Excel calcInWizard='false' /> </SupportedPlatforms> <ParameterList> *************** *** 51,55 **** <libraryFunction>setStringParameter</libraryFunction> <SupportedPlatforms> ! <Excel checkForFunctionWizard='true' /> </SupportedPlatforms> <ParameterList> --- 51,55 ---- <libraryFunction>setStringParameter</libraryFunction> <SupportedPlatforms> ! <Excel calcInWizard='false' /> </SupportedPlatforms> <ParameterList> *************** *** 72,76 **** <libraryFunction>doubleParameter</libraryFunction> <SupportedPlatforms> ! <Excel checkForFunctionWizard='true' /> </SupportedPlatforms> <ParameterList> --- 72,76 ---- <libraryFunction>doubleParameter</libraryFunction> <SupportedPlatforms> ! <Excel calcInWizard='false' /> </SupportedPlatforms> <ParameterList> *************** *** 87,91 **** <libraryFunction>setDoubleParameter</libraryFunction> <SupportedPlatforms> ! <Excel checkForFunctionWizard='true' /> </SupportedPlatforms> <ParameterList> --- 87,91 ---- <libraryFunction>setDoubleParameter</libraryFunction> <SupportedPlatforms> ! <Excel calcInWizard='false' /> </SupportedPlatforms> <ParameterList> Index: ohutils.xml =================================================================== RCS file: /cvsroot/objecthandler/ObjectHandler/gensrc/metadata/ohutils.xml,v retrieving revision 1.9 retrieving revision 1.10 diff -C2 -d -r1.9 -r1.10 *** ohutils.xml 10 Jan 2007 16:40:31 -0000 1.9 --- ohutils.xml 10 Jan 2007 17:39:29 -0000 1.10 *************** *** 99,103 **** <alias>ObjHandler::ObjectHandlerXL::instance().listObjectIDs</alias> <SupportedPlatforms> ! <Excel checkForFunctionWizard='true' /> </SupportedPlatforms> <ParameterList> --- 99,103 ---- <alias>ObjHandler::ObjectHandlerXL::instance().listObjectIDs</alias> <SupportedPlatforms> ! <Excel calcInWizard='false' /> </SupportedPlatforms> <ParameterList> *************** *** 120,124 **** <alias>ObjHandler::ObjectHandlerXL::instance().objectCount</alias> <SupportedPlatforms> ! <Excel checkForFunctionWizard='true' /> </SupportedPlatforms> <ParameterList> --- 120,124 ---- <alias>ObjHandler::ObjectHandlerXL::instance().objectCount</alias> <SupportedPlatforms> ! <Excel calcInWizard='false' /> </SupportedPlatforms> <ParameterList> *************** *** 156,160 **** <alias>ObjHandler::split</alias> <SupportedPlatforms> ! <Excel checkForFunctionWizard='true' /> </SupportedPlatforms> <ParameterList> --- 156,160 ---- <alias>ObjHandler::split</alias> <SupportedPlatforms> ! <Excel calcInWizard='false' /> </SupportedPlatforms> <ParameterList> *************** *** 188,192 **** <xlWizardRecalc>true</xlWizardRecalc> <SupportedPlatforms> ! <Excel checkForFunctionWizard='true' /> </SupportedPlatforms> <ParameterList> --- 188,192 ---- <xlWizardRecalc>true</xlWizardRecalc> <SupportedPlatforms> ! <Excel calcInWizard='false' /> </SupportedPlatforms> <ParameterList> *************** *** 214,218 **** <alias>ObjHandler::ObjectHandlerXL::instance().retrieveError</alias> <SupportedPlatforms> ! <Excel checkForFunctionWizard='true' /> </SupportedPlatforms> <ParameterList> --- 214,218 ---- <alias>ObjHandler::ObjectHandlerXL::instance().retrieveError</alias> <SupportedPlatforms> ! <Excel calcInWizard='false' /> </SupportedPlatforms> <ParameterList> *************** *** 235,239 **** <alias>ObjHandler::version</alias> <SupportedPlatforms> ! <Excel checkForFunctionWizard='true' /> </SupportedPlatforms> <ParameterList> --- 235,239 ---- <alias>ObjHandler::version</alias> <SupportedPlatforms> ! <Excel calcInWizard='false' /> </SupportedPlatforms> <ParameterList> Index: garbagecollection.xml =================================================================== RCS file: /cvsroot/objecthandler/ObjectHandler/gensrc/metadata/garbagecollection.xml,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** garbagecollection.xml 10 Jan 2007 16:40:31 -0000 1.3 --- garbagecollection.xml 10 Jan 2007 17:39:29 -0000 1.4 *************** *** 18,22 **** <alias>ObjHandler::ObjectHandlerXL::instance().collectGarbage</alias> <SupportedPlatforms> ! <Excel checkForFunctionWizard='true' /> </SupportedPlatforms> <ParameterList> --- 18,22 ---- <alias>ObjHandler::ObjectHandlerXL::instance().collectGarbage</alias> <SupportedPlatforms> ! <Excel calcInWizard='false' /> </SupportedPlatforms> <ParameterList> *************** *** 39,43 **** <alias>ObjHandler::ObjectHandlerXL::instance().deleteAllObjects</alias> <SupportedPlatforms> ! <Excel checkForFunctionWizard='true' /> </SupportedPlatforms> <ParameterList> --- 39,43 ---- <alias>ObjHandler::ObjectHandlerXL::instance().deleteAllObjects</alias> <SupportedPlatforms> ! <Excel calcInWizard='false' /> </SupportedPlatforms> <ParameterList> *************** *** 60,64 **** <alias>ObjHandler::ObjectHandlerXL::instance().deleteObject</alias> <SupportedPlatforms> ! <Excel checkForFunctionWizard='true' /> </SupportedPlatforms> <ParameterList> --- 60,64 ---- <alias>ObjHandler::ObjectHandlerXL::instance().deleteObject</alias> <SupportedPlatforms> ! <Excel calcInWizard='false' /> </SupportedPlatforms> <ParameterList> |
From: Eric E. <eri...@us...> - 2007-01-10 16:40:48
|
Update of /cvsroot/objecthandler/ObjectHandler/gensrc/metadata In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv9746/gensrc/metadata Modified Files: demo.xml garbagecollection.xml logging.xml ohutils.xml valueobjects.xml Log Message: in function metadata, explicitly specify the XML tag controlling the test for the Function Wizard Index: valueobjects.xml =================================================================== RCS file: /cvsroot/objecthandler/ObjectHandler/gensrc/metadata/valueobjects.xml,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** valueobjects.xml 3 Dec 2006 14:35:04 -0000 1.1 --- valueobjects.xml 10 Jan 2007 16:40:31 -0000 1.2 *************** *** 18,22 **** <libraryFunction>propertyNames</libraryFunction> <SupportedPlatforms> ! <Excel/> </SupportedPlatforms> <ParameterList> --- 18,22 ---- <libraryFunction>propertyNames</libraryFunction> <SupportedPlatforms> ! <Excel checkForFunctionWizard='true' /> </SupportedPlatforms> <ParameterList> *************** *** 33,37 **** <libraryFunction>propertyValue</libraryFunction> <SupportedPlatforms> ! <Excel/> </SupportedPlatforms> <ParameterList> --- 33,37 ---- <libraryFunction>propertyValue</libraryFunction> <SupportedPlatforms> ! <Excel checkForFunctionWizard='true' /> </SupportedPlatforms> <ParameterList> Index: logging.xml =================================================================== RCS file: /cvsroot/objecthandler/ObjectHandler/gensrc/metadata/logging.xml,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** logging.xml 3 Dec 2006 14:35:03 -0000 1.1 --- logging.xml 10 Jan 2007 16:40:31 -0000 1.2 *************** *** 18,22 **** <alias>ObjHandler::logAllObjects</alias> <SupportedPlatforms> ! <Excel/> </SupportedPlatforms> <ParameterList> --- 18,22 ---- <alias>ObjHandler::logAllObjects</alias> <SupportedPlatforms> ! <Excel checkForFunctionWizard='true' /> </SupportedPlatforms> <ParameterList> *************** *** 33,37 **** <alias>ObjHandler::logMessage</alias> <SupportedPlatforms> ! <Excel/> </SupportedPlatforms> <ParameterList> --- 33,37 ---- <alias>ObjHandler::logMessage</alias> <SupportedPlatforms> ! <Excel checkForFunctionWizard='true' /> </SupportedPlatforms> <ParameterList> *************** *** 59,63 **** <alias>ObjHandler::logObject</alias> <SupportedPlatforms> ! <Excel/> </SupportedPlatforms> <ParameterList> --- 59,63 ---- <alias>ObjHandler::logObject</alias> <SupportedPlatforms> ! <Excel checkForFunctionWizard='true' /> </SupportedPlatforms> <ParameterList> *************** *** 80,84 **** <alias>ObjHandler::setLogFile</alias> <SupportedPlatforms> ! <Excel/> </SupportedPlatforms> <ParameterList> --- 80,84 ---- <alias>ObjHandler::setLogFile</alias> <SupportedPlatforms> ! <Excel checkForFunctionWizard='true' /> </SupportedPlatforms> <ParameterList> *************** *** 106,110 **** <alias>ObjHandler::setLogLevel</alias> <SupportedPlatforms> ! <Excel/> </SupportedPlatforms> <ParameterList> --- 106,110 ---- <alias>ObjHandler::setLogLevel</alias> <SupportedPlatforms> ! <Excel checkForFunctionWizard='true' /> </SupportedPlatforms> <ParameterList> Index: demo.xml =================================================================== RCS file: /cvsroot/objecthandler/ObjectHandler/gensrc/metadata/demo.xml,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** demo.xml 2 Jan 2007 10:59:39 -0000 1.3 --- demo.xml 10 Jan 2007 16:40:31 -0000 1.4 *************** *** 14,18 **** <libraryFunction>Thing</libraryFunction> <SupportedPlatforms> ! <Excel/> </SupportedPlatforms> <ParameterList> --- 14,18 ---- <libraryFunction>Thing</libraryFunction> <SupportedPlatforms> ! <Excel checkForFunctionWizard='true' /> </SupportedPlatforms> <ParameterList> *************** *** 36,40 **** <libraryFunction>stringParameter</libraryFunction> <SupportedPlatforms> ! <Excel/> </SupportedPlatforms> <ParameterList> --- 36,40 ---- <libraryFunction>stringParameter</libraryFunction> <SupportedPlatforms> ! <Excel checkForFunctionWizard='true' /> </SupportedPlatforms> <ParameterList> *************** *** 51,55 **** <libraryFunction>setStringParameter</libraryFunction> <SupportedPlatforms> ! <Excel/> </SupportedPlatforms> <ParameterList> --- 51,55 ---- <libraryFunction>setStringParameter</libraryFunction> <SupportedPlatforms> ! <Excel checkForFunctionWizard='true' /> </SupportedPlatforms> <ParameterList> *************** *** 72,76 **** <libraryFunction>doubleParameter</libraryFunction> <SupportedPlatforms> ! <Excel/> </SupportedPlatforms> <ParameterList> --- 72,76 ---- <libraryFunction>doubleParameter</libraryFunction> <SupportedPlatforms> ! <Excel checkForFunctionWizard='true' /> </SupportedPlatforms> <ParameterList> *************** *** 87,91 **** <libraryFunction>setDoubleParameter</libraryFunction> <SupportedPlatforms> ! <Excel/> </SupportedPlatforms> <ParameterList> --- 87,91 ---- <libraryFunction>setDoubleParameter</libraryFunction> <SupportedPlatforms> ! <Excel checkForFunctionWizard='true' /> </SupportedPlatforms> <ParameterList> Index: ohutils.xml =================================================================== RCS file: /cvsroot/objecthandler/ObjectHandler/gensrc/metadata/ohutils.xml,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -d -r1.8 -r1.9 *** ohutils.xml 8 Jan 2007 19:55:31 -0000 1.8 --- ohutils.xml 10 Jan 2007 16:40:31 -0000 1.9 *************** *** 99,103 **** <alias>ObjHandler::ObjectHandlerXL::instance().listObjectIDs</alias> <SupportedPlatforms> ! <Excel/> </SupportedPlatforms> <ParameterList> --- 99,103 ---- <alias>ObjHandler::ObjectHandlerXL::instance().listObjectIDs</alias> <SupportedPlatforms> ! <Excel checkForFunctionWizard='true' /> </SupportedPlatforms> <ParameterList> *************** *** 120,124 **** <alias>ObjHandler::ObjectHandlerXL::instance().objectCount</alias> <SupportedPlatforms> ! <Excel/> </SupportedPlatforms> <ParameterList> --- 120,124 ---- <alias>ObjHandler::ObjectHandlerXL::instance().objectCount</alias> <SupportedPlatforms> ! <Excel checkForFunctionWizard='true' /> </SupportedPlatforms> <ParameterList> *************** *** 156,160 **** <alias>ObjHandler::split</alias> <SupportedPlatforms> ! <Excel/> </SupportedPlatforms> <ParameterList> --- 156,160 ---- <alias>ObjHandler::split</alias> <SupportedPlatforms> ! <Excel checkForFunctionWizard='true' /> </SupportedPlatforms> <ParameterList> *************** *** 188,192 **** <xlWizardRecalc>true</xlWizardRecalc> <SupportedPlatforms> ! <Excel/> </SupportedPlatforms> <ParameterList> --- 188,192 ---- <xlWizardRecalc>true</xlWizardRecalc> <SupportedPlatforms> ! <Excel checkForFunctionWizard='true' /> </SupportedPlatforms> <ParameterList> *************** *** 214,218 **** <alias>ObjHandler::ObjectHandlerXL::instance().retrieveError</alias> <SupportedPlatforms> ! <Excel/> </SupportedPlatforms> <ParameterList> --- 214,218 ---- <alias>ObjHandler::ObjectHandlerXL::instance().retrieveError</alias> <SupportedPlatforms> ! <Excel checkForFunctionWizard='true' /> </SupportedPlatforms> <ParameterList> *************** *** 235,239 **** <alias>ObjHandler::version</alias> <SupportedPlatforms> ! <Excel/> </SupportedPlatforms> <ParameterList> --- 235,239 ---- <alias>ObjHandler::version</alias> <SupportedPlatforms> ! <Excel checkForFunctionWizard='true' /> </SupportedPlatforms> <ParameterList> Index: garbagecollection.xml =================================================================== RCS file: /cvsroot/objecthandler/ObjectHandler/gensrc/metadata/garbagecollection.xml,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** garbagecollection.xml 2 Jan 2007 11:09:06 -0000 1.2 --- garbagecollection.xml 10 Jan 2007 16:40:31 -0000 1.3 *************** *** 18,22 **** <alias>ObjHandler::ObjectHandlerXL::instance().collectGarbage</alias> <SupportedPlatforms> ! <Excel/> </SupportedPlatforms> <ParameterList> --- 18,22 ---- <alias>ObjHandler::ObjectHandlerXL::instance().collectGarbage</alias> <SupportedPlatforms> ! <Excel checkForFunctionWizard='true' /> </SupportedPlatforms> <ParameterList> *************** *** 39,43 **** <alias>ObjHandler::ObjectHandlerXL::instance().deleteAllObjects</alias> <SupportedPlatforms> ! <Excel/> </SupportedPlatforms> <ParameterList> --- 39,43 ---- <alias>ObjHandler::ObjectHandlerXL::instance().deleteAllObjects</alias> <SupportedPlatforms> ! <Excel checkForFunctionWizard='true' /> </SupportedPlatforms> <ParameterList> *************** *** 60,64 **** <alias>ObjHandler::ObjectHandlerXL::instance().deleteObject</alias> <SupportedPlatforms> ! <Excel/> </SupportedPlatforms> <ParameterList> --- 60,64 ---- <alias>ObjHandler::ObjectHandlerXL::instance().deleteObject</alias> <SupportedPlatforms> ! <Excel checkForFunctionWizard='true' /> </SupportedPlatforms> <ParameterList> |
From: Eric E. <eri...@us...> - 2007-01-10 09:55:09
|
Update of /cvsroot/objecthandler/ObjectHandler/ohxl In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv30934/ohxl Modified Files: functioncall.cpp functioncall.hpp Log Message: - optimize the test for the Excel Function Wizard - remove copyright of Jérôme Lecomte since the code originates from MSDN Index: functioncall.cpp =================================================================== RCS file: /cvsroot/objecthandler/ObjectHandler/ohxl/functioncall.cpp,v retrieving revision 1.13 retrieving revision 1.14 diff -C2 -d -r1.13 -r1.14 *** functioncall.cpp 4 Jan 2007 11:18:36 -0000 1.13 --- functioncall.cpp 10 Jan 2007 09:55:07 -0000 1.14 *************** *** 1,6 **** /* ! Copyright (C) 2006 Eric Ehlers ! Copyright (C) 1998, 1999, 2001, 2002 Jérôme Lecomte This file is part of QuantLib, a free-software/open-source library --- 1,5 ---- /* ! Copyright (C) 2006, 2007 Eric Ehlers This file is part of QuantLib, a free-software/open-source library *************** *** 125,167 **** } - - // code to determine whether we've been called from the Excel function wizard - // taken from xlw by Jérôme Lecomte - - typedef struct _EnumStruct { - bool bFuncWiz; - short hwndXLMain; - } - EnumStruct, FAR * LPEnumStruct; - - bool CALLBACK EnumProc(HWND hwnd, LPEnumStruct pEnum) { - const size_t CLASS_NAME_BUFFER = 50; - // first check the class of the window. Will be szXLDialogClass - // if function wizard dialog is up in Excel - char rgsz[CLASS_NAME_BUFFER]; - GetClassName(hwnd, (LPSTR)rgsz, CLASS_NAME_BUFFER); - if (2 == CompareString(MAKELCID(MAKELANGID(LANG_ENGLISH, - SUBLANG_ENGLISH_US),SORT_DEFAULT), NORM_IGNORECASE, - (LPSTR)rgsz, (lstrlen((LPSTR)rgsz)>lstrlen("bosa_sdm_XL")) - ? lstrlen("bosa_sdm_XL"):-1, "bosa_sdm_XL", -1)) { - if(LOWORD((DWORD) GetParent(hwnd)) == pEnum->hwndXLMain) { - pEnum->bFuncWiz = TRUE; - return false; - } - } - // no luck - continue the enumeration - return true; - } - - bool FunctionCall::IsCalledByFuncWiz() { - XLOPER xHwndMain; - EnumStruct enm; - Excel(xlGetHwnd, &xHwndMain, 0); - enm.bFuncWiz = false; - enm.hwndXLMain = xHwndMain.val.w; - EnumWindows((WNDENUMPROC) EnumProc, (LPARAM) ((LPEnumStruct) &enm)); - return enm.bFuncWiz; - } - CallerType FunctionCall::getCallerType() { if (callerType_ == Uninitialized2) { --- 124,127 ---- *************** *** 178,180 **** --- 138,223 ---- return callerType_; } + + // Code to determine whether we've been called from the Excel function wizard. + // + // This code is called by every function in the Addin and some attempt has been + // made to optimize performance e.g. caching variables whose values don't change. + // + // This code is based on code from MSDN and has inherited some bugs from the + // MSDN version: + // 1) The Function Wizard dialog is assumed to be any window of class + // "bosa_sdm_XL" but that class can also indicate the "Edit->Replace" dialog + // 2) The main excel parent window is identified only by the LOWORD half of its + // DWORD handle + // + // Consequently there is the risk that this function will return false positives + // i.e. we'll conclude that we've been called from the Function Wizard when in + // fact we've been called while + // 1) the "Edit->Replace" dialog is active + // 2) some other Excel session is displaying the Function Wizard or + // "Edit->Replace" dialog + + typedef struct { + bool bFuncWiz; + short hwndXLMain; + } EnumStruct; + + // The class name of the window for the Function Wizard dialog. Various + // versions of Excel may suffix this string with additional characters. + #define WIZ_ID_BUF "bosa_sdm_XL" + #define WIZ_ID_BUF_LEN 12 + + // Called by EnumWindows (below) for each open window + bool CALLBACK EnumProc(HWND hwnd, EnumStruct *pEnum) { + + // Retrieve the class name of the current window. We only want to + // compare the resulting string with the "bosa_sdm_XL" value so we set + // the buffer size such that any trailing characters are truncated. + + char class_name[WIZ_ID_BUF_LEN]; + GetClassName(hwnd, class_name, WIZ_ID_BUF_LEN); + + if (stricmp(class_name, WIZ_ID_BUF) == 0) { + + // Apparently this window is the Excel Function Wizard dialog. + // Now check whether the ID of this window's parent matches that of + // our main Excel window as returned by xlGetHwnd (below). + + if (LOWORD((DWORD) GetParent(hwnd)) == pEnum->hwndXLMain) { + pEnum->bFuncWiz = TRUE; // We've (probably) been called from the wizard + return false; // Tell EnumWindows to stop + } + + } + + return true; // Tell EnumWindows to continue + } + + short int getWinID() { + + // Retrieve the LOWORD half of the DWORD handle + // of the main Excel window. + + XLOPER xHwndMain; + Excel(xlGetHwnd, &xHwndMain, 0); + + return xHwndMain.val.w; + } + + bool FunctionCall::IsCalledByFuncWiz() { + + // ID of the main Excel window. This value is retrieved once + // for this running instance of the Addin. + + static short int winID = getWinID(); + + // Call EnumWindows which iteratively calls EnumProc which sets + // enm.bFuncWiz if the Excel Function Wizard dialog is detected. + + EnumStruct enm = { false, winID }; + EnumWindows((WNDENUMPROC)EnumProc, (LPARAM)&enm); + + return enm.bFuncWiz; + } + } Index: functioncall.hpp =================================================================== RCS file: /cvsroot/objecthandler/ObjectHandler/ohxl/functioncall.hpp,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -d -r1.8 -r1.9 *** functioncall.hpp 30 Oct 2006 15:46:51 -0000 1.8 --- functioncall.hpp 10 Jan 2007 09:55:07 -0000 1.9 *************** *** 2,6 **** /* Copyright (C) 2006 Eric Ehlers - Copyright (C) 1998, 1999, 2001, 2002 Jérôme Lecomte This file is part of QuantLib, a free-software/open-source library --- 2,5 ---- *************** *** 74,76 **** #endif - --- 73,74 ---- |
From: Eric E. <eri...@us...> - 2007-01-09 14:38:00
|
Update of /cvsroot/objecthandler/ObjectHandler/oh In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv21874/oh Modified Files: objecthandler.cpp Log Message: ohListObjectIDs() - use case insensitive regex Index: objecthandler.cpp =================================================================== RCS file: /cvsroot/objecthandler/ObjectHandler/oh/objecthandler.cpp,v retrieving revision 1.9 retrieving revision 1.10 diff -C2 -d -r1.9 -r1.10 *** objecthandler.cpp 3 Jan 2007 09:03:47 -0000 1.9 --- objecthandler.cpp 9 Jan 2007 14:37:58 -0000 1.10 *************** *** 127,136 **** objectIDs.push_back(i->first); } else { ! boost::regex r(regex); for (OhRepository::const_iterator i=repository_.begin(); i!=repository_.end(); ++i) { string objectID = i->first; - // FIXME: it should be case insensitive if (regex_match(objectID, r)) objectIDs.push_back(objectID); } --- 127,135 ---- objectIDs.push_back(i->first); } else { ! boost::regex r(regex, boost::regex::perl | boost::regex::icase); for (OhRepository::const_iterator i=repository_.begin(); i!=repository_.end(); ++i) { string objectID = i->first; if (regex_match(objectID, r)) objectIDs.push_back(objectID); } |
From: Eric E. <eri...@us...> - 2007-01-08 19:55:34
|
Update of /cvsroot/objecthandler/ObjectHandler/ohxl/Conversions In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv14288/ohxl/Conversions Modified Files: opertoscalar.cpp opertoscalar.hpp Log Message: - reinstate from OH 0.1.3 some previously deprecated code for converting boost::any <-> OPER - consolidate ohFilter1/ohFilter2 into ohFilter and enable Function Wizard Index: opertoscalar.hpp =================================================================== RCS file: /cvsroot/objecthandler/ObjectHandler/ohxl/Conversions/opertoscalar.hpp,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** opertoscalar.hpp 4 Jan 2007 11:18:36 -0000 1.6 --- opertoscalar.hpp 8 Jan 2007 19:55:31 -0000 1.7 *************** *** 22,25 **** --- 22,26 ---- #include <xlsdk/xlsdkdefines.hpp> #include <string> + #include <boost/any.hpp> namespace ObjHandler { *************** *** 29,32 **** --- 30,34 ---- DLL_API void operToScalar(const OPER &xScalar, bool &ret); DLL_API void operToScalar(const OPER &xScalar, std::string &ret); + DLL_API void operToScalar(const OPER &xScalar, boost::any &ret); template <class T> Index: opertoscalar.cpp =================================================================== RCS file: /cvsroot/objecthandler/ObjectHandler/ohxl/Conversions/opertoscalar.cpp,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** opertoscalar.cpp 4 Jan 2007 11:18:36 -0000 1.4 --- opertoscalar.cpp 8 Jan 2007 19:55:31 -0000 1.5 *************** *** 18,21 **** --- 18,22 ---- #include <ohxl/Conversions/opertoscalar.hpp> + #include <oh/exception.hpp> namespace ObjHandler { *************** *** 85,87 **** --- 86,105 ---- } + DLL_API void operToScalar(const OPER &xScalar, boost::any &ret) { + if (xScalar.xltype & xltypeErr) + throw std::exception("input value is #NULL (xltypeErr)"); + if (xScalar.xltype & (xltypeMissing | xltypeNil)) + ret = boost::any(); + else if (xScalar.xltype == xltypeNum) + ret = xScalar.val.num; + else if (xScalar.xltype == xltypeBool) + ret = xScalar.val.boolean != 0; + else if (xScalar.xltype == xltypeStr) { + std::string value; + operToScalar(xScalar, value); + ret = value; + } else { + OH_FAIL("operToScalar: unexpected datatype: " << xScalar.xltype); + } + } } |
From: Eric E. <eri...@us...> - 2007-01-08 19:55:32
|
Update of /cvsroot/objecthandler/ObjectHandler/oh In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv14288/oh Modified Files: exception.hpp Log Message: - reinstate from OH 0.1.3 some previously deprecated code for converting boost::any <-> OPER - consolidate ohFilter1/ohFilter2 into ohFilter and enable Function Wizard Index: exception.hpp =================================================================== RCS file: /cvsroot/objecthandler/ObjectHandler/oh/exception.hpp,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** exception.hpp 19 Nov 2006 13:08:26 -0000 1.2 --- exception.hpp 8 Jan 2007 19:55:31 -0000 1.3 *************** *** 26,29 **** --- 26,30 ---- #include <exception> #include <string> + #include <sstream> #define OH_FAIL(message) \ |
From: Eric E. <eri...@us...> - 2007-01-08 19:55:32
|
Update of /cvsroot/objecthandler/ObjectHandler/gensrc/metadata In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv14288/gensrc/metadata Modified Files: ohutils.xml Log Message: - reinstate from OH 0.1.3 some previously deprecated code for converting boost::any <-> OPER - consolidate ohFilter1/ohFilter2 into ohFilter and enable Function Wizard Index: ohutils.xml =================================================================== RCS file: /cvsroot/objecthandler/ObjectHandler/gensrc/metadata/ohutils.xml,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** ohutils.xml 4 Jan 2007 17:11:27 -0000 1.7 --- ohutils.xml 8 Jan 2007 19:55:31 -0000 1.8 *************** *** 183,189 **** </Procedure> ! <!--<Procedure name='ohFilter' dependencyTrigger='False'> <description>Filters the first vector using the second one as boolean inclusion flags</description> <alias>ObjHandler::filter</alias> <SupportedPlatforms> <Excel/> --- 183,190 ---- </Procedure> ! <Procedure name='ohFilter' dependencyTrigger='False'> <description>Filters the first vector using the second one as boolean inclusion flags</description> <alias>ObjHandler::filter</alias> + <xlWizardRecalc>true</xlWizardRecalc> <SupportedPlatforms> <Excel/> *************** *** 207,262 **** <tensorRank>vector</tensorRank> </ReturnValue> - </Procedure>--> - - <Procedure name='ohFilter1' dependencyTrigger='False'> - <description>Filters the first vector using the second one as boolean inclusion flags</description> - <alias>ObjHandler::filter</alias> - <SupportedPlatforms> - <Excel/> - </SupportedPlatforms> - <ParameterList> - <Parameters> - <Parameter name='input'> - <type>string</type> - <tensorRank>vector</tensorRank> - <description>vector to be filtered</description> - </Parameter> - <Parameter name='flags'> - <type>bool</type> - <tensorRank>vector</tensorRank> - <description>vector to inclusion flags</description> - </Parameter> - </Parameters> - </ParameterList> - <ReturnValue> - <type>string</type> - <tensorRank>vector</tensorRank> - </ReturnValue> - </Procedure> - - <Procedure name='ohFilter2' dependencyTrigger='False'> - <description>Filters the first vector using the second one as boolean inclusion flags</description> - <alias>ObjHandler::filter</alias> - <SupportedPlatforms> - <Excel/> - </SupportedPlatforms> - <ParameterList> - <Parameters> - <Parameter name='input'> - <type>double</type> - <tensorRank>vector</tensorRank> - <description>vector to be filtered</description> - </Parameter> - <Parameter name='flags'> - <type>bool</type> - <tensorRank>vector</tensorRank> - <description>vector to inclusion flags</description> - </Parameter> - </Parameters> - </ParameterList> - <ReturnValue> - <type>double</type> - <tensorRank>vector</tensorRank> - </ReturnValue> </Procedure> --- 208,211 ---- |
From: Ferdinando A. <na...@us...> - 2007-01-04 17:11:32
|
Update of /cvsroot/objecthandler/ObjectHandler/gensrc/metadata In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv17773/gensrc/metadata Modified Files: ohutils.xml Log Message: new ohFilter function Index: ohutils.xml =================================================================== RCS file: /cvsroot/objecthandler/ObjectHandler/gensrc/metadata/ohutils.xml,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** ohutils.xml 2 Jan 2007 11:07:43 -0000 1.6 --- ohutils.xml 4 Jan 2007 17:11:27 -0000 1.7 *************** *** 153,157 **** <Procedure name='ohSplit' dependencyTrigger='False'> ! <description>Extract the ith number from a whitespace-delimited list of fields</description> <alias>ObjHandler::split</alias> <SupportedPlatforms> --- 153,157 ---- <Procedure name='ohSplit' dependencyTrigger='False'> ! <description>Splits a string using delimiters</description> <alias>ObjHandler::split</alias> <SupportedPlatforms> *************** *** 165,182 **** <description>string to be parsed</description> </Parameter> ! <Parameter name='delimiter' default='",;"'> <type>string</type> <tensorRank>scalar</tensorRank> ! <description>characters (default = \";,\")</description> </Parameter> - <!--<Parameter name='index' default='-1'> - <type>long</type> - <tensorRank>scalar</tensorRank> - <description>index (1-based) of desired field - if omitted, all fields returned as arrray</description> - </Parameter>--> <Parameter name='concatenateDelim' default='false'> <type>bool</type> <tensorRank>scalar</tensorRank> ! <description>specifies if adjacent delimiters are concatenated (TRUE) or not (FALSE). Default value is FALSE.</description> </Parameter> </Parameters> --- 165,177 ---- <description>string to be parsed</description> </Parameter> ! <Parameter name='delimiters' default='",;"'> <type>string</type> <tensorRank>scalar</tensorRank> ! <description>characters used as delimiters: each single character is used as delimiter (default = \";,\")</description> </Parameter> <Parameter name='concatenateDelim' default='false'> <type>bool</type> <tensorRank>scalar</tensorRank> ! <description>specifies if multiple adjacent delimiters are to be considered as one (TRUE) or not (FALSE). Default value is FALSE.</description> </Parameter> </Parameters> *************** *** 188,191 **** --- 183,264 ---- </Procedure> + <!--<Procedure name='ohFilter' dependencyTrigger='False'> + <description>Filters the first vector using the second one as boolean inclusion flags</description> + <alias>ObjHandler::filter</alias> + <SupportedPlatforms> + <Excel/> + </SupportedPlatforms> + <ParameterList> + <Parameters> + <Parameter name='input'> + <type>any</type> + <tensorRank>vector</tensorRank> + <description>vector to be filtered</description> + </Parameter> + <Parameter name='flags'> + <type>bool</type> + <tensorRank>vector</tensorRank> + <description>vector to inclusion flags</description> + </Parameter> + </Parameters> + </ParameterList> + <ReturnValue> + <type>any</type> + <tensorRank>vector</tensorRank> + </ReturnValue> + </Procedure>--> + + <Procedure name='ohFilter1' dependencyTrigger='False'> + <description>Filters the first vector using the second one as boolean inclusion flags</description> + <alias>ObjHandler::filter</alias> + <SupportedPlatforms> + <Excel/> + </SupportedPlatforms> + <ParameterList> + <Parameters> + <Parameter name='input'> + <type>string</type> + <tensorRank>vector</tensorRank> + <description>vector to be filtered</description> + </Parameter> + <Parameter name='flags'> + <type>bool</type> + <tensorRank>vector</tensorRank> + <description>vector to inclusion flags</description> + </Parameter> + </Parameters> + </ParameterList> + <ReturnValue> + <type>string</type> + <tensorRank>vector</tensorRank> + </ReturnValue> + </Procedure> + + <Procedure name='ohFilter2' dependencyTrigger='False'> + <description>Filters the first vector using the second one as boolean inclusion flags</description> + <alias>ObjHandler::filter</alias> + <SupportedPlatforms> + <Excel/> + </SupportedPlatforms> + <ParameterList> + <Parameters> + <Parameter name='input'> + <type>double</type> + <tensorRank>vector</tensorRank> + <description>vector to be filtered</description> + </Parameter> + <Parameter name='flags'> + <type>bool</type> + <tensorRank>vector</tensorRank> + <description>vector to inclusion flags</description> + </Parameter> + </Parameters> + </ParameterList> + <ReturnValue> + <type>double</type> + <tensorRank>vector</tensorRank> + </ReturnValue> + </Procedure> + <Procedure name='ohRetrieveError'> <description>retrieve error message associated with a given range</description> |
From: Ferdinando A. <na...@us...> - 2007-01-04 17:11:32
|
Update of /cvsroot/objecthandler/ObjectHandler/oh In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv17773/oh Modified Files: utilities.hpp Log Message: new ohFilter function Index: utilities.hpp =================================================================== RCS file: /cvsroot/objecthandler/ObjectHandler/oh/utilities.hpp,v retrieving revision 1.15 retrieving revision 1.16 diff -C2 -d -r1.15 -r1.16 *** utilities.hpp 2 Jan 2007 11:07:43 -0000 1.15 --- utilities.hpp 4 Jan 2007 17:11:27 -0000 1.16 *************** *** 25,28 **** --- 25,30 ---- #include <oh/objhandlerdefines.hpp> + #include <oh/exception.hpp> + #include <boost/any.hpp> #include <string> #include <vector> *************** *** 84,87 **** --- 86,106 ---- bool token_compress); + template< typename T> + std::vector<T> filter(const std::vector<T> &in, + const std::vector<bool> &flags) { + std::size_t size = in.size(); + OH_REQUIRE(size==flags.size(), + "size mismatch between value vector (" << size << + ") and flag vector (" << flags.size() << ")"); + + std::vector<T> out; + out.reserve(size); //excess capacity + + for (std::size_t i=0; i<size; ++i) + if (flags[i]) out.push_back(in[i]); + + return out; + } + //@} } |