Determine whether the current result is either a help request or a cancel request.
#include "asr/asrm.h"
int asrm_is_help_or_cancel(asr_result_t *result, cfg_item_t *opt_help_section, cfg_item_t *opt_cancel_section, asr_result_action_t *ret, int perform)
A pointer to the result structure.
A pointer to the help configuration section.
A pointer to the cancel configuration section.
The action to take.
A flag to indicate whether to take action on the result.
The asrm_is_help_or_cancel() function determines whether the specified result is either a help request or a cancel request. If it is one of these, the function sets ret to the appropriate action code. If the result is a help request and perform is nonzero, the asrp_active_help() function is invoked.
1 The result is either a help request or a cancel request. The res parameter is set to either ASR_RECOGNITION_CANCEL or ASR_RECOGNITION_RESTART.
0 The result is neither a help request nor a cancel request.