SAGA C++ API 1.6
version.hpp
Go to the documentation of this file.
00001 //  Copyright (c) 2005-2007 Andre Merzky (andre@merzky.net)
00002 //  Copyright (c) 2005-2009 Hartmut Kaiser
00003 // 
00004 //  Distributed under the Boost Software License, Version 1.0. (See accompanying 
00005 //  file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
00006 
00007 #if !defined(SAGA_PACKAGE_DATA_NAMESPACE_VERSION_HPP)
00008 #define SAGA_PACKAGE_DATA_NAMESPACE_VERSION_HPP
00009 
00010 #include <saga/saga/util.hpp>
00011 #include <saga/saga/version.hpp>
00012 #include <saga/saga/packages/namespace/config.hpp>
00013 
00015 //  The version of the SAGA file package
00016 //
00017 //  SAGA_VERSION_PACKAGE_NAMESPACE_FULL & 0x0000FF is the sub-minor version
00018 //  SAGA_VERSION_PACKAGE_NAMESPACE_FULL & 0x00FF00 is the minor version
00019 //  SAGA_VERSION_PACKAGE_NAMESPACE_FULL & 0xFF0000 is the major version
00020 //
00021 #define SAGA_VERSION_PACKAGE_NAMESPACE_FULL         SAGA_VERSION_FULL
00022 
00023 #define SAGA_VERSION_PACKAGE_NAMESPACE_MAJOR        SAGA_VERSION_MAJOR
00024 #define SAGA_VERSION_PACKAGE_NAMESPACE_MINOR        SAGA_VERSION_MINOR
00025 #define SAGA_VERSION_PACKAGE_NAMESPACE_SUBMINOR     SAGA_VERSION_SUBMINOR
00026 
00027 #define SAGA_VERSION_PACKAGE_NAMESPACE_DATE         SAGA_VERSION_DATE
00028 
00029 #define SAGA_VERSION_PACKAGE_NAMESPACE_SUBMINORMASK SAGA_VERSION_SUBMINORMASK
00030 
00032 //  The SAGA namespace package API version: here V1.0.0
00033 #define SAGA_VERSION_PACKAGE_NAMESPACE_API          SAGA_VERSION_API
00034 
00036 //
00037 //  SAGA_VERSION_PACKAGE_NAMESPACE_ISCOMPATIBLE()
00038 // 
00039 //  The SAGA_VERSION_ISCOMPATIBLE macro tests, if the version of the loaded
00040 //  SAGA engine is compatible with the version the calling application was 
00041 //  compiled against.
00042 //
00043 #define SAGA_VERSION_PACKAGE_NAMESPACE_ISCOMPATIBLE_EX(version)               \
00044         ( ((version) & ~SAGA_VERSION_PACKAGE_NAMESPACE_SUBMINORMASK) >=       \
00045          ( SAGA_VERSION_PACKAGE_NAMESPACE_FULL &                              \
00046           ~SAGA_VERSION_PACKAGE_NAMESPACE_SUBMINORMASK) )                     \
00047   
00048 
00049 #define SAGA_VERSION_PACKAGE_NAMESPACE_ISCOMPATIBLE()                         \
00050         SAGA_VERSION_PACKAGE_NAMESPACE_ISCOMPATIBLE_EX(                       \
00051             saga::get_namespace_package_version())                            \
00052   
00053 
00055 namespace saga {
00056 
00057 // Returns the version of the SAGA engine
00058 SAGA_NAMESPACE_PACKAGE_EXPORT unsigned long get_namespace_package_version();
00059 
00060 // Returns the implemented SAGA API version
00061 SAGA_NAMESPACE_PACKAGE_EXPORT unsigned long get_namespace_package_api_version();
00062 
00064 }   // namespace saga
00065 
00066 #endif // !SAGA_VERSION_HPP
00067 
00068 
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines