Applies parsers until one succeeds or all of them fail.
1 2 3 4 5
list of alternative parsers to be executed
Function to be executed if recognition succeeds. It takes as input parameters information derived from parsers involved as parameters
Function to be executed if recognition does not succeed. I takes two parameters:
In case of success,
action gets the
node from the first parse to succeed.
In case of failure, parameter
error gets a list, with information about failure from all the parsers processed.
Anonymous functions, returning a list.
From these input parameters, an anonymous function is constructed. This function admits just one parameter, stream, with
streamParser class, and returns a three-field list:
"ok" or "fail"
error function output, depending on the case
With information about the input, after success or failure in recognition
1 2 3 4 5 6 7 8
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.