diff options
author | Thorbjørn Lindeijer <thorbjorn@lindeijer.nl> | 2009-12-06 18:39:49 +0100 |
---|---|---|
committer | Thorbjørn Lindeijer <thorbjorn@lindeijer.nl> | 2009-12-06 18:46:49 +0100 |
commit | c0a5b22aa8f90c3d5de4a4b7495cf157d9a189d1 (patch) | |
tree | e3982ab486c539a88d0c3eaad37c0fdfaa1b1f8f /src/utils/singleton.h | |
parent | 49cd2c5d236294fa99a612dbf4833c72a7f89de8 (diff) | |
download | manaserv-c0a5b22aa8f90c3d5de4a4b7495cf157d9a189d1.tar.gz manaserv-c0a5b22aa8f90c3d5de4a4b7495cf157d9a189d1.tar.bz2 manaserv-c0a5b22aa8f90c3d5de4a4b7495cf157d9a189d1.tar.xz manaserv-c0a5b22aa8f90c3d5de4a4b7495cf157d9a189d1.zip |
A host of code style changes
Removed pointless void in method parameter lists, fixed methods and
variables that started with upper case, removed pointless 'const' for
stuff passed by value, made some getters const, etc.
Diffstat (limited to 'src/utils/singleton.h')
-rw-r--r-- | src/utils/singleton.h | 28 |
1 files changed, 7 insertions, 21 deletions
diff --git a/src/utils/singleton.h b/src/utils/singleton.h index 1a879235..86b9da7f 100644 --- a/src/utils/singleton.h +++ b/src/utils/singleton.h @@ -24,7 +24,6 @@ namespace utils { - /** * An abstract Meyer's singleton class. */ @@ -37,52 +36,39 @@ class Singleton * * @return the unique instance of Singleton. */ - static T& - instance(void) + static T &instance() { static T theInstance; - return theInstance; } - protected: /** * Default constructor. */ - Singleton(void) + Singleton() throw() - { - // NOOP - } - + {} /** * Destructor. */ - virtual - ~Singleton(void) + virtual ~Singleton() throw() - { - // NOOP - } - + {} private: /** * Copy constructor. */ - Singleton(const Singleton& rhs); - + Singleton(const Singleton &); /** * Assignment operator. */ - Singleton& - operator=(const Singleton& rhs); + Singleton &operator=(const Singleton &); }; - } // namespace utils #endif // _TMWSERV_SINGLETON_H_ |