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
|