/usr/include/BALL/CONCEPT/concept.doc is in libball1.4-dev 1.4.3~beta1-3.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 | // -*- Mode: C++; tab-width: 2; -*-
// vi: set ts=2:
//
/** \defgroup Concepts Concepts
\ingroup Foundation
This chapter contains all relevant information on
the classes representing BALL concepts.
*/
/** \defgroup ConceptsIterators Iterators
* \ingroup Concepts
*/
/** \defgroup Persistence Object Persistence.
\ingroup Concepts
Ball provides support for the serialization and deserialization of
objects and their platform-independent storage.
<br>
All persistent objects have to be derived from PersistentObject. The
management, serialization, and deserialization is performed by the
PersistenceManager class. A persistence manager possess an input
stream and an output stream (<em> persistent streams </em>). It can write
objects to the output stream, thereby converting them to a portable
format and serializing all dependend objects, too. It can also read
objects from the input stream, create the corresponding objects
dynamically and demangle pointers and references.
<br>
There are two main problems related with this trivial persistence
concept:
- multiple inheritence from a single base class
- static members variables
These problems are inherent problems of C++ and cannot be solved.
However, they can be avoided in most cases. To circumvent problems
related to multiple instances of a common base class (which would
normally require virtual inheritence - but this does not solve the
problem), we introduced the model <b> storable </b>. Storable objects
are not derived from PersistentObject, but they provide two functions
(read/write) to write themselves to a persistent stream and to
retrieve their contents again.
<br>
Static member variables should usually be ignored when
reading/writing persistent objects. However, this has to be decided
on a case-by-case basis.
*/
/** \defgroup ClassTest Class Black Box Testing
To provide a maximum reliability for all BALL classes, each class
provides its own test program to ensure that each class compiles
and behaves (at least basically) as intended.
The testprograms reside in the directory source/TEST, they may
be built and executed by calling <b>make test</b>.
Each test program prints after execution either "PASSED" or "FAILED".
If any of the subtest contained in the test program fails, the whole
test failed. The result of the test program can also be checked via its
exit code. An exit code of zero means "PASSED", non-zero exit code means
"FAILED".
There are several macros defined to simplify the creation of a test program
and to provide a common interface.
Each test program consists of several subtests which usually test one
method or property of the class. Each of this subtests uses a series
of elementary tests to check the functionality of the method.
A number of elementary tests has been implemented that is sufficient
for most cases:
- \link #TEST_EQUAL TEST_EQUAL \endlink
- \link #TEST_NOT_EQUAL TEST_NOT_EQUAL \endlink
- \link #TEST_REAL_EQUAL TEST_REAL_EQUAL \endlink
A subtest is defined by calling the \link #CHECK CHECK \endlink macro with the subtest name
as an argument. Then a series of calls to <b>TEST</b> macros follows,
mixed with standard BALL code (remember to include all neccessary header files).
The subtest is terminated by calling \link #RESULT RESULT \endlink .
Use the two macros \link #START_TEST START_TEST \endlink and \link #END_TEST END_TEST \endlink to generate a complete
test program.
To create a new test program, use the file
<a href="../../source/BALL/TEST/Skeleton_test.C">source/TEST/Skeleton_test.C</a>
\par
\ingroup Concepts
*/
/** \defgroup Benchmark Benchmarking of classes.
<a href="../../source/BALL/BENCHMARKS/Skeleton_bench.C">source/BENCHMARKS/Skeleton_bench.C</a>
\par
\ingroup Concepts
*/
/** \defgroup ConceptsMiscellaneous Miscellaneous
\ingroup Concepts
*/
|