FLDadd_int


Synopsis

create/get/set an integer subobject to an object


int FLDadd_int (
OMobj_id field,
const char *name);

int FLDset_int (
OMobj_id field,
const char *name,
int val);

int FLDget_int (
OMobj_id field,
const char *name,
int *val);

Description

These routines add a single, new integer subobject to an existing field data schema object, and then set/get its value. They could also be used when you want to construct and reference an entirely new data object and add single integer subobjects to it, but you want to do this within the code of a function, rather than using V.

Note: If you are accessing an existing, defined subobject, use the specific routine for that subobject (for example, FLDget_coord_extent). Use FLDadd/set/get_int only when you have created your own, unique, named subobject, or when no FLD routine exists for a pre-defined subobject.

FLDadd_int adds a single integer subobject to the object specified by OMobj_id field. The object is named in the Object Manager by the string name. The new subobject is flagged as "not set."

FLDset_int sets the integer object within field, named name, to val.

FLDget_int returns the value of the integer subobject name within field in val.

Parameters

OMobj_id field

The OMobj_id of an object. This can be any object, not just a "Field".

const char *name

In FLDadd_int, an input argument specifying a character string that names the new integer subobject.

In FLDset_int and FLDget_int, an input character string argument that specifies which subobject of field to get/set.

int val
int *val

In FLDset_int, val is an input argument that sets the value of the integer subobject.

In FLDget_int, val is a pointer to an integer in which the value of the subobject is returned.

Example

modules/pln_crop.c
modules/iso.c
modules/slice.c

Related routines