The Fib multimedia system
Fib is a system for storing multimedia data (like images or films).
Main Page
Namespaces
Classes
Files
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
cIndividualIdentifier.h
Go to the documentation of this file.
1
/**
2
* @file cIndividualIdentifier
3
* file name: cIndividualIdentifier.h
4
* @author Betti Oesterholz
5
* @date 26.02.2010
6
* @mail webmaster@BioKom.info
7
*
8
* System: C++
9
*
10
* This header specifies a class for identifiers for individals.
11
* Copyright (C) @c GPL3 2010 Betti Oesterholz
12
*
13
* This program is free software: you can redistribute it and/or modify
14
* it under the terms of the GNU General Public License (GPL) as
15
* published by the Free Software Foundation, either version 3 of the
16
* License, or any later version.
17
*
18
* This program is distributed in the hope that it will be useful,
19
* but WITHOUT ANY WARRANTY; without even the implied warranty of
20
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21
* GNU Lesser General Public License for more details.
22
*
23
* You should have received a copy of the GNU General Public License
24
* along with this program. If not, see <http://www.gnu.org/licenses/>.
25
*
26
*
27
* This header specifies a class for identifiers for individals.
28
* The identifier is a unique object for all possible individuals.
29
* @see cIndividual
30
*
31
*/
32
/*
33
History:
34
26.02.2010 Oesterholz created
35
*/
36
37
#ifndef ___C_INDIVIDUAL_IDENTIFIER_H__
38
#define ___C_INDIVIDUAL_IDENTIFIER_H__
39
40
#include "version.h"
41
42
43
namespace
enviroment{
44
45
46
class
cIndividualIdentifier
{
47
48
protected
:
49
50
/**
51
* the identifier of a individual, wich is unique for all individuals
52
* in one enviroment instantiation
53
*/
54
unsigned
long
long
ulIndividualIdentifier
;
55
56
/**
57
* the identifier of the enviroment instantiation, so this identifier
58
* is unique, even for different enviroment instantiations
59
*/
60
unsigned
long
long
ulAlgorithmIdentifier
;
61
62
63
/**
64
* constructor
65
*
66
* @param ulInIndividualIdentifier the identifier of the individual
67
* @param ulInAlgorithmIdentifier the identifier of the enviroment
68
* instantiation
69
*/
70
cIndividualIdentifier
(
unsigned
long
long
ulInIndividualIdentifier,
71
unsigned
long
long
ulInAlgorithmIdentifier );
72
73
public
:
74
75
/**
76
* constructor
77
*
78
* @param ulInAlgorithmIdentifier the identifier of the enviroment
79
* instantiation
80
*/
81
cIndividualIdentifier
(
unsigned
long
long
ulInAlgorithmIdentifier );
82
83
/**
84
* @return a identifier for no individual; this will be lower ever
85
* other identifier
86
*/
87
static
cIndividualIdentifier
&
getNoIndividualIdentifier
();
88
89
/**
90
* Comparisson on equal method for two cIndividualIdentifier objects.
91
*
92
* @param idIndividual the idIndividualobject to compare this
93
* idIndividualobject to
94
* @return true if the cIndividualIdentifier this object represents is
95
* equal to the cIndividualIdentifier the given object idIndividual
96
* represents
97
*/
98
bool
equal
(
const
cIndividualIdentifier
&idIndividual )
const
;
99
100
/**
101
* Comparisson on equal operator for two cIndividualIdentifier objects.
102
*
103
* @param idIndividual the idIndividualobject to compare this
104
* idIndividualobject to
105
* @return true if the cIndividualIdentifier this object represents is
106
* equal to the cIndividualIdentifier the given object idIndividual
107
* represents
108
*/
109
bool
operator==
(
const
cIndividualIdentifier
&idIndividual )
const
;
110
111
/**
112
* Comparisson on not equal operator for two cIndividualIdentifier objects.
113
*
114
* @param idIndividual the idIndividualobject to compare this
115
* idIndividualobject to
116
* @return true if the cIndividualIdentifier this object represents is
117
* not equal to the cIndividualIdentifier the given object idIndividual
118
* represents
119
*/
120
bool
operator!=
(
const
cIndividualIdentifier
&idIndividual )
const
;
121
122
/**
123
* Comparisson on lower operator for two identifier objects.
124
* An identifier is lower, if it's algorithm identifier
125
* (@see ulAlgorithmIdentifier) is lower or the algorithm identifiers
126
* are equal and the individual identifier (@see ulIndividualIdentifier)
127
* is lower.
128
*
129
* This method is mainly for sorting individuals.
130
*
131
* @see ulAlgorithmIdentifier
132
* @see ulIndividualIdentifier
133
* @param identifier the identifier to compare this identifier to
134
* @return true identifier is lower than the given identifier, else false
135
*/
136
bool
operator<
(
const
cIndividualIdentifier
&identifier )
const
;
137
138
139
private
:
140
141
/**
142
* @return a individual identifier that wasn't used bevor
143
*/
144
static
unsigned
long
long
getNewIndividualIdentifier
();
145
146
147
148
};
//end class cIndividualIdentifier
149
150
151
152
};
//end namespace enviroment
153
154
#endif //___C_INDIVIDUAL_IDENTIFIER_H__
155
156
157
158
159
160
161
enviroment
incl
cIndividualIdentifier.h
Generated on Thu Feb 14 2013 14:06:55 for The Fib multimedia system by
1.8.1