Regina Calculation Engine
Classes | Defines | Functions
Engine Structure

Overall structure of the calculation engine. More...

Classes

class  regina::ShareableObject
 Facilitates mirroring objects in the underlying C++ calculation engine using the various wrapper classes provided in the various external interfaces (such as the Python interface). More...

Defines

#define REGINA_API
 All non-templated, non-static functions and classes that are part of Regina's public interface must be declared with REGINA_API.
#define REGINA_LOCAL
 Classes and functions that are local to the current compilation unit and should not be publicly exported may be declared with REGINA_LOCAL.

Functions

REGINA_API const char * regina::getVersionString ()
 Returns the full version number of this calculation engine.
REGINA_API int regina::getVersionMajor ()
 Returns the major version number of this calculation engine.
REGINA_API int regina::getVersionMinor ()
 Returns the minor version number of this calculation engine.
REGINA_API bool regina::versionUsesUTF8 (const char *version)
 Did the given version of Regina consistently use UTF-8 in its data files?
REGINA_API int regina::testEngine (int value)
 Tests to see if an interface can successfully communicate with the underlying C++ calculation engine.

Detailed Description

Overall structure of the calculation engine.


Define Documentation

#define REGINA_API

All non-templated, non-static functions and classes that are part of Regina's public interface must be declared with REGINA_API.

Otherwise things may (and in some environments will) break when external applications try to use Regina with optimisations such as gcc's -fvisibility=hidden.

Note: When building the Regina calculation engine shared library, REGINA_DLL_EXPORTS must be defined (this ensures that API symbols are marked for export). When importing (using) this library, REGINA_DLL_EXPORTS must not be defined (this ensures that API symbols are marked for import instead).

#define REGINA_LOCAL

Classes and functions that are local to the current compilation unit and should not be publicly exported may be declared with REGINA_LOCAL.

Use of this macro is optional.


Function Documentation

REGINA_API int regina::getVersionMajor ( )

Returns the major version number of this calculation engine.

For instance, version 2.3.1 would have major version 2.

Returns:
the major version number of this calculation engine.
REGINA_API int regina::getVersionMinor ( )

Returns the minor version number of this calculation engine.

For instance, version 2.3.1 would have minor version 3.

Returns:
the minor version number of this calculation engine.
REGINA_API const char* regina::getVersionString ( )

Returns the full version number of this calculation engine.

For instance, version 2.3.1 would have full version "2.3.1".

Returns:
the version of this calculation engine.
REGINA_API int regina::testEngine ( int  value)

Tests to see if an interface can successfully communicate with the underlying C++ calculation engine.

This routine simply uses the engine to return the same value that is passed to it; it can be used to test whether communications between the interface and the C++ engine are working properly.

Parameters:
valueany integer; this same integer will be returned.
Returns:
the same integer that was passed as value.
REGINA_API bool regina::versionUsesUTF8 ( const char *  version)

Did the given version of Regina consistently use UTF-8 in its data files?

In Regina versions 4.4 and below, no particular attention was paid to character encodings. As a result, the GUI typically stored data in LATIN1 (the default for the Qt libraries).

As of Regina 4.5, all strings are now stored in UTF-8 where possible.

This routine allows programs to determine which regime a particular version of Regina belongs to. This can be useful when working with Regina data files on a low-level basis.

Any whitespace in the version string will confuse the result, and the return value will be undefined.

As a special case, an empty string is treated as belonging to the UTF-8 regime.

Parameters:
versiona version string from some release of Regina, such as "4.2". This must not contain any whitespace padding.
Returns:
true if the given version uses UTF-8 consistently, or false if the given version is an older version that did not pay attention to character encodings.

Copyright © 1999-2011, The Regina development team
This software is released under the GNU General Public License.
For further information, or to submit a bug or other problem, please contact Ben Burton (bab@debian.org).