void Abs_CommandAdd( char * name, PFI funcFp, int changes )
int
CommandTest(hmgr, argc, argv)
Hrc_Manager_t **hmgr;
int argc;
char **argv;
{
return 0;
}
Note the double de-reference on the hmgr which is passed to the command; this allows the command to replace the current hmgr. argv[0] will generally be the command name, and argv[1] ... argv[argc-1] are the arguments for the command. util_getopt() can be used to parse the arguments, but util_getopt_reset() must be used before calling util_getopt(). The command function should return 0 for normal operation, 1 for any error. The changes flag is used to automatically save the hmgr before executing the command (in order to support undo).