![]() |
![]() |
![]() |
![]() |
OMchanged
Synopsis
int OMchanged(OMobj_id object_id, int seq_num);int OMXobj::changed(int seq_num);
Description
DescriptionOMchanged is normally called from a method's update function. It can be used to determine whether or not one of the parameters has changed since the last invocation of the method.Arguments
object_idseq_numThe sequence number of the method. This is passed as an argument to methods written with the omethod and cxxmethod method types.
Returned valueReturned value
A pointer to the array, or NULL if ARRalloc failed.Examples
Given this V code for a simple modulemodule my_module {
int my_param1;
omethod+notify+read update = "my_module_update";
};this C code can determine whether my_param1 has changed since the module last ran:int my_module_update(OMobj_id obj_id, OMevent_mask mask,
int seq_num){
OMobj_id param_id;
param_id = OMfind_subobj(obj_id,
OMstr_to_name("my_param1"),
OM_OBJ_RD);
if (OMchanged(param_id, seq_num)) { /* param1 changed */
...
}
...See Also
![]() |
![]() |
![]() |
![]() |