summaryrefslogtreecommitdiffstats
path: root/cpp/sca/samples/store/currency-composite.hpp
diff options
context:
space:
mode:
authorjsdelfino <jsdelfino@13f79535-47bb-0310-9956-ffa450edef68>2009-09-26 21:31:26 +0000
committerjsdelfino <jsdelfino@13f79535-47bb-0310-9956-ffa450edef68>2009-09-26 21:31:26 +0000
commitc39d4c6d143697ee8982df0833499a8de934dd9a (patch)
treecbc758f3921459c0f11a96f24f5ef251db0bf367 /cpp/sca/samples/store/currency-composite.hpp
parent8eb242943144ad5ea57c7471e4a3e199bf5687d5 (diff)
Refactored the value class. Cleaned up usage of namespaces to remove side effects from includes. Added a few util functions to help work with threads. Added synchronizations to make pointers thread safe. Adjusted store sample to refactoring.
git-svn-id: http://svn.us.apache.org/repos/asf/tuscany@819220 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to '')
-rw-r--r--cpp/sca/samples/store/currency-composite.hpp9
1 files changed, 3 insertions, 6 deletions
diff --git a/cpp/sca/samples/store/currency-composite.hpp b/cpp/sca/samples/store/currency-composite.hpp
index a135ca660b..94b52b461e 100644
--- a/cpp/sca/samples/store/currency-composite.hpp
+++ b/cpp/sca/samples/store/currency-composite.hpp
@@ -22,12 +22,9 @@
#ifndef store_currencycomposite_hpp
#define store_currencycomposite_hpp
-#include <string.h>
-#include <math.h>
+#include <string>
#include "currency.hpp"
-using namespace tuscany;
-
namespace store
{
@@ -41,11 +38,11 @@ public:
CurrencyImpl() : currencyConverter(CurrencyConverterImpl()) {
}
- virtual const double convert(const string& fromCurrencyCode, const string& toCurrencyCode, const double amount) const {
+ virtual const double convert(const std::string& fromCurrencyCode, const std::string& toCurrencyCode, const double amount) const {
return currencyConverter.convert(fromCurrencyCode, toCurrencyCode, amount);
}
- virtual const string getSymbol(const string& currencyCode) const {
+ virtual const std::string getSymbol(const std::string& currencyCode) const {
return currencyConverter.getSymbol(currencyCode);
}
};