aboutsummaryrefslogtreecommitdiff
path: root/src/multistorage.cc
diff options
context:
space:
mode:
authorschnetter <schnetter@83718e91-0e4f-0410-abf4-91180603181f>2005-05-31 12:21:07 +0000
committerschnetter <schnetter@83718e91-0e4f-0410-abf4-91180603181f>2005-05-31 12:21:07 +0000
commitb291165dca900822bb22d9d08c3c2b51be925580 (patch)
tree86035fb56934ed5ee378b09fe95d97ad892c164a /src/multistorage.cc
parentf8fedd5ec017e3ad6d00e9845f0631e2cb64e2cf (diff)
Put everything into a namespace.
Include <fstream> once more, maybe it helps. Correct a few errors that gcc pointed out. git-svn-id: http://svn.cactuscode.org/arrangements/CactusUtils/Formaline/trunk@26 83718e91-0e4f-0410-abf4-91180603181f
Diffstat (limited to 'src/multistorage.cc')
-rw-r--r--src/multistorage.cc129
1 files changed, 69 insertions, 60 deletions
diff --git a/src/multistorage.cc b/src/multistorage.cc
index 374b667..6b16c75 100644
--- a/src/multistorage.cc
+++ b/src/multistorage.cc
@@ -2,97 +2,106 @@
#include "multistorage.hh"
-using namespace std;
-
-multistorage::
-multistorage ()
+namespace Formaline
{
-}
+ using namespace std;
-multistorage::
-~ multistorage ()
-{
- for (list<storage *>::const_iterator it = stores.begin();
- it != stores.end();
- ++ it)
+
+ multistorage::
+ multistorage ()
{
- delete * it;
}
-}
-void multistorage::
-add_storage (storage * const s)
-{
- stores.push_front (s);
-}
+ multistorage::
+ ~ multistorage ()
+ {
+ for (list<storage *>::const_iterator it = stores.begin();
+ it != stores.end();
+ ++ it)
+ {
+ delete * it;
+ }
+ }
-int multistorage::
-num_storages ()
- const
-{
- return stores.size();
-}
+ void multistorage::
+ add_storage (storage * const s)
+ {
+ stores.push_front (s);
+ }
-void multistorage::
-store (char const * const key, bool const value)
- const
-{
- for (list<storage *>::const_iterator it = stores.begin();
- it != stores.end();
- ++ it)
+ int multistorage::
+ num_storages ()
+ const
{
- (* it)->store (key, value);
+ return stores.size();
}
-}
-void multistorage::
-store (char const * const key, int const value)
- const
-{
- for (list<storage *>::const_iterator it = stores.begin();
- it != stores.end();
- ++ it)
+ void multistorage::
+ store (char const * const key, bool const value)
+ const
{
- (* it)->store (key, value);
+ for (list<storage *>::const_iterator it = stores.begin();
+ it != stores.end();
+ ++ it)
+ {
+ (* it)->store (key, value);
+ }
}
-}
-void multistorage::
-store (char const * const key, double const value)
- const
-{
- for (list<storage *>::const_iterator it = stores.begin();
- it != stores.end();
- ++ it)
+ void multistorage::
+ store (char const * const key, int const value)
+ const
{
- (* it)->store (key, value);
+ for (list<storage *>::const_iterator it = stores.begin();
+ it != stores.end();
+ ++ it)
+ {
+ (* it)->store (key, value);
+ }
}
-}
-void multistorage::
-store (char const * const key, char const * const value)
- const
-{
- for (list<storage *>::const_iterator it = stores.begin();
- it != stores.end();
- ++ it)
+ void multistorage::
+ store (char const * const key, double const value)
+ const
+ {
+ for (list<storage *>::const_iterator it = stores.begin();
+ it != stores.end();
+ ++ it)
+ {
+ (* it)->store (key, value);
+ }
+ }
+
+
+
+ void multistorage::
+ store (char const * const key, char const * const value)
+ const
{
- (* it)->store (key, value);
+ for (list<storage *>::const_iterator it = stores.begin();
+ it != stores.end();
+ ++ it)
+ {
+ (* it)->store (key, value);
+ }
}
-}
+
+
+
+} // namespace Formaline