[MOAB-dev] r4816 - in MOAB/trunk: itaps itaps/igeom itaps/imesh tools/mbcoupler

jvporter at wisc.edu jvporter at wisc.edu
Wed May 11 18:06:43 CDT 2011


Author: jvporter
Date: 2011-05-11 18:06:43 -0500 (Wed, 11 May 2011)
New Revision: 4816

Modified:
   MOAB/trunk/itaps/iBase.h
   MOAB/trunk/itaps/igeom/iGeom_MOAB.cpp
   MOAB/trunk/itaps/igeom/iGeom_MOAB.hpp
   MOAB/trunk/itaps/imesh/MBiMesh.hpp
   MOAB/trunk/itaps/imesh/iMesh.h
   MOAB/trunk/itaps/imesh/iMesh_MOAB.cpp
   MOAB/trunk/itaps/imesh/iMesh_MOAB.hpp
   MOAB/trunk/tools/mbcoupler/ssn_test.cpp
Log:
* Update iBase.h and iMesh.h to newer version
* Change last error code/description to be per-instance, rather than per-interface


Modified: MOAB/trunk/itaps/iBase.h
===================================================================
--- MOAB/trunk/itaps/iBase.h	2011-05-11 21:27:05 UTC (rev 4815)
+++ MOAB/trunk/itaps/iBase.h	2011-05-11 23:06:43 UTC (rev 4816)
@@ -1,91 +1,167 @@
 #ifndef _ITAPS_iBase
 #define _ITAPS_iBase
 
-#ifdef __cplusplus
+/***************************************************************************//**
+ * \ingroup VersionNumbers
+ * \brief Compile time version number digits
+ *
+ * iBase maintains a major, minor and patch digit in its version number.
+ * Technically speaking, there is not much practical value in patch digit
+ * for an interface specification. A patch release is typically only used
+ * for bug fix releases. Although it is rare, sometimes a bug fix
+ * necessitates an API change. So, we define a patch digit for iMesh.
+ *
+ * Although each interface in ITAPS has been designed to support its own
+ * uniqe version numbers, apart from other ITAPS interfaces, as currently
+ * used, we require all ITAPS interfaces to use the same ITAPS-wide version
+ * number derived from the version number defined by these three digits.
+ ******************************************************************************/
+#define IBASE_VERSION_MAJOR 1
+#define IBASE_VERSION_MINOR 3
+#define IBASE_VERSION_PATCH 0
 
-extern "C"
-{
-#endif
+/***************************************************************************//**
+ * \ingroup VersionNumbers
+ * \brief Version Comparison
+ *
+ * Evaluates to true at CPP time if the version of iBase currently being
+ * compiled is greater than or equal to the version specified.
+ ******************************************************************************/
+#define IBASE_VERSION_GE(Maj,Min,Pat) \
+    (((IBASE_VERSION_MAJOR==(Maj)) && (IBASE_VERSION_MINOR==(Min)) && (IBASE_VERSION_PATCH>=(Pat))) || \
+     ((IBASE_VERSION_MAJOR==(Maj)) && (IBASE_VERSION_MINOR>(Min))) || \
+      (IBASE_VERSION_MAJOR>(Maj)))
 
+/***************************************************************************//**
+ * \ingroup VersionNumbers
+ * \brief Compose compile-time string represention of the version number
+ ******************************************************************************/
+#define IBASE_VERSION_STRING___(I,X,Y,Z) #I "_Version_" #X "." #Y "." #Z
+#define IBASE_VERSION_STRING__(I,X,Y,Z) IBASE_VERSION_STRING___(I,X,Y,Z)
+#define IBASE_VERSION_STRING_(I) IBASE_VERSION_STRING__(I,IBASE_VERSION_MAJOR,IBASE_VERSION_MINOR,IBASE_VERSION_PATCH)
+#define IBASE_VERSION_STRING IBASE_VERSION_STRING_(iBase)


More information about the moab-dev mailing list