net.sourceforge.pmd.parsers

Interface Parser

public interface Parser

Common interface for calling tree-building parsers or source files.

Author: Pieter_Van_Raemdonck - Application Engineers NV/SA - www.ae.be

Method Summary
Objectparse(Reader source)
Parse source code and return the root node of the AST.

Method Detail

parse

public Object parse(Reader source)
Parse source code and return the root node of the AST.

Parameters: source Reader that provides the source code of a compilation unit

Returns: the root node of the AST that is built from the source code

Throws: ParseException In case the source code could not be parsed, probably due to syntactical errors.