NAME

Parse::RandGen::Grammar - Module for defining a language/protocol grammar

DESCRIPTION

    The purpose of this module is to build a grammar description that can then be used to build:

    (1) a parser using Parse::RecDescent

    (2) a stimulus generator that creates valid (and interesting invalid) tests of the grammer.

    Be aware of the greediness of the underlying parsing mechanism (RecDescent). See Parse::RandGen::Production for examples on how greediness can affect errors in grammars.

METHODS

new

Creates a new grammar. The grammar name is the only required argument.

name

Return the name of the grammar.

rule

Access an existing Rule object by name. Returns undef if the Rule is not found.

defineRule

Define a Rule if not already defined and return a reference to the Rule.

dump

Returns a dump of the Grammar object in Parse::RecDescent grammar format.

SEE ALSO

Parse::RandGen::Rule and Parse::RandGen::Production

AUTHORS

Jeff Dutton

2 POD Errors

The following errors were encountered while parsing the POD:

Around line 186:

You forgot a '=back' before '=head1'

Around line 208:

=back without =over