TOC PREV NEXT INDEX

GDget_str_val

Synopsis

get or set a string value

int _ GDget_str_val ( parent_id , _ elem_name , _char ** string );
int _ GDget_newstr_val ( parent_id , _ elem_name , _ seq , _char ** string );
int _ GDget_updstr_val ( parent_id , _ elem_name , _ seq , _char ** string );
void _ GDset_newstr_val ( parent_id , _ elem_name , _ seq , _char * string );

OMobj_id _ parent_id ;
char _* elem_name ;
int _* seq ;

Description

GDget_str_val gets a string value and places the value into string . The return value is 1 if successful, 0 if a failure.

GDget_newstr_val gets a string value and places the value into string . The routine also returns the string's updated sequence number. The return value is 1 if the data has changed, 0 if it has not.

GDget_updstr_val gets a string value and places the value into string . The return value is 1 if the data has changed, 0 if it has not.

GDset_newstr_val sets a string value. The routine also returns the string's updated sequence number.

Parameters

parent_id

The id of the target subobject's parent.

elem_name

The name of the target subobject.

seq

(GDget_newstr_val only) _An input/output argument. It is used to compare against the string's current sequence number to determine if the string has changed. It is then updated with the current sequence number.

(GDget_updstr_val only) _An input argument. It is used to compare against the string's current sequence number to determine if the string has changed.

(GDset_newstr_val only) _An output argument that is updated with the current sequence number.

string

In the GDget_xxxx routines, the address where the routine places the string.
In the GDset_xxxx routines, the string that the routine copies.

Example

/* Get the name of the current object, stored in GDobj_sel. */
OMobj_id _obj_sel_id; /* Assume this has been set. */
char curobj_name[40];
int seq;
...
GDget_newstr_val(GDobj_sel, "curobj_name", &seq,
&curobj_name);


TOC PREV NEXT INDEX