Various functions for accessing fields of the Db using the locator designation. They use the argument 'loctype' which refers to the Locator type (see ELoc enumeration). In most cases, they also refer to 'item' i.e. the rank (0 based) for the target locator.
- Parameters
-
loctype | Target locator |
iech | Target sample (0 based) |
item | Rank of the 'loctype' locator (0 based) |
oper | Type of operation
- 0 : New = New + Old
- 1 : New = New * Old
- 2 : New = New - Old
- 3 : New = Old / New
- 4 : New = New (only if old is defined)
- 5 : New = MAX(New, Old)
- 6 : New = MIN(New, Old)
|
value | Assigned value |
int Db::getLocNumber |
( |
const ELoc & |
loctype | ) |
const |
Returns the number of fields corresponding to the target locator present in the Db
- Returns
- Number of fields
double Db::getLocVariable |
( |
const ELoc & |
loctype, |
|
|
int |
iech, |
|
|
int |
item |
|
) |
| const |
Get the value of the field corresponding to the target locator (and its target item) at the target sample
- Returns
- Returned value
bool Db::hasLocVariable |
( |
const ELoc & |
loctype | ) |
const |
Check if there is at least one field corresponding to the target locator
- Returns
- TRUE if at least one field corresponds to 'loctype' locator; FALSE otherwise
void Db::setLocVariable |
( |
const ELoc & |
loctype, |
|
|
int |
iech, |
|
|
int |
item, |
|
|
double |
value |
|
) |
| |
Set the value of the field corresponding to the target locator (and its target item) at the target sample
void Db::updLocVariable |
( |
const ELoc & |
loctype, |
|
|
int |
iech, |
|
|
int |
item, |
|
|
const EOperator & |
oper, |
|
|
double |
value |
|
) |
| |
Update the value of the field corresponding to the target locator (and its target item) at the target sample