[This is preliminary documentation and is subject to change.]
Creates the Productions and Elements
necessary for a repeated section of a production.
Parameters
- repeatedElements (array<Object>[]()[][])
- The elements to be repeated in a production. These can be any of the types of object that you can supply to the Add method - Element, Production, string or an array containing any of these.
Return Value
A non terminal Element referencing the LHS of the productions
created. You add this to the RHS of a production where you want the
repeated elements.
Remarks
This method allows you to have the supplied elements to be
repeated zero or more times in a Production. It can be any Production in
the parser that this Production belongs to, but is usually used to create a
repeated section in this Production. If you have a grammar with a
production such as LHS = .. { E1 E2 .. En } .. then calling this
method with elements E1 to En will create the necessary productions to
achieve this.