]> Dogcows Code - chaz/yoink/blobdiff - src/moof/backend.hh
the massive refactoring effort
[chaz/yoink] / src / moof / backend.hh
similarity index 56%
rename from src/Moof/Backend.hh
rename to src/moof/backend.hh
index 8209b069b06ba34fb26b999b0ed5644580fe5c6b..b40a72a67a4d2f7ca0a1ed61817a6638ecccb106 100644 (file)
 #ifndef _MOOF_BACKEND_HH_
 #define _MOOF_BACKEND_HH_
 
-
-namespace Mf {
+/**
+ * \file backend.hh
+ * Initialize the backend libraries and subsystems.
+ */
 
 
-class Error;
+namespace moof {
 
 
-/*
+/**
  * Some classes and subsystems require certain backend libraries to be
  * initialized.  This is the mechanism to accomplish that.  Classes which
  * rely on any backend libraries just need to instantiate this class as a
  * member.  Backend cleanup will occur automagically when there are no more
  * instances.
  */
-
-class Backend
+class backend
 {
 public:
 
-       Backend();
-       Backend(const Backend& backend);
-       ~Backend();
+       /**
+        * Construct a backend reference, initializing the backend if it hasn't
+        * already been initialized.
+        */
+       backend();
+
+       /**
+        * Get whether or not the backend has been initialized.
+        * \return True if the backend is initialized, false otherwise.
+        */
+       static bool is_initialized();
+
+
+       // The rest of this stuff is to implement the reference counting.
 
-       static bool isInitialized();
-       static const Error& getError();
+       backend(const backend& backend);
+       backend& operator=(const backend& backend);
+       ~backend();
 };
 
 
-} // namespace Mf
+} // namespace moof
 
 #endif // _MOOF_BACKEND_HH_
 
This page took 0.028695 seconds and 4 git commands to generate.