[opengtl-commits] [261] make the default constructor private |
[ Thread Index |
Date Index
| More lists.tuxfamily.org/opengtl-commits Archives
]
Revision: 261
Author: cyrille
Date: 2008-06-29 10:48:30 +0200 (Sun, 29 Jun 2008)
Log Message:
-----------
make the default constructor private
Modified Paths:
--------------
trunk/OpenGTL/OpenGTL/GTLCore/Parameter.cpp
trunk/OpenGTL/OpenGTL/GTLCore/Parameter.h
Modified: trunk/OpenGTL/OpenGTL/GTLCore/Parameter.cpp
===================================================================
--- trunk/OpenGTL/OpenGTL/GTLCore/Parameter.cpp 2008-06-29 08:47:58 UTC (rev 260)
+++ trunk/OpenGTL/OpenGTL/GTLCore/Parameter.cpp 2008-06-29 08:48:30 UTC (rev 261)
@@ -19,6 +19,7 @@
#include "GTLCore/Parameter.h"
+#include "Debug.h"
#include "GTLCore/Type.h"
#include "GTLCore/Value.h"
@@ -32,8 +33,14 @@
Value defaultValue;
};
+Parameter::Parameter() : d(new Private )
+{
+}
+
Parameter::Parameter(const GTLCore::String& _name, const GTLCore::Type* _type, bool _output, bool _varying, const Value& _defaultValue) : d(new Private)
+
{
+ GTL_ASSERT(_type);
d->name = _name;
d->type = _type;
d->output = _output;
@@ -64,6 +71,7 @@
const GTLCore::Type* Parameter::type() const
{
+ GTL_ASSERT(d);
return d->type;
}
Modified: trunk/OpenGTL/OpenGTL/GTLCore/Parameter.h
===================================================================
--- trunk/OpenGTL/OpenGTL/GTLCore/Parameter.h 2008-06-29 08:47:58 UTC (rev 260)
+++ trunk/OpenGTL/OpenGTL/GTLCore/Parameter.h 2008-06-29 08:48:30 UTC (rev 261)
@@ -39,6 +39,7 @@
const Value& defaultValue() const;
bool output() const;
private:
+ Parameter();
struct Private;
Private* const d;
};