com.puppycrawl.tools.checkstyle.gui

Class ParseTreeInfoPanel

public class ParseTreeInfoPanel extends JPanel

Displays information about a parse tree. The user can change the file that is parsed and displayed through a JFileChooser.

Author: Lars Kühne

Constructor Summary
ParseTreeInfoPanel()
Create a new ParseTreeInfoPanel instance.
Method Summary
voidopenFile(File aFile, Component aParent)
static DetailASTparseFile(String aFileName)
Parses a file and returns the parse tree.

Constructor Detail

ParseTreeInfoPanel

public ParseTreeInfoPanel()
Create a new ParseTreeInfoPanel instance.

Method Detail

openFile

public void openFile(File aFile, Component aParent)

parseFile

public static DetailAST parseFile(String aFileName)
Parses a file and returns the parse tree.

Parameters: aFileName the file to parse

Returns: the root node of the parse tree

Throws: IOException if the file cannot be opened ANTLRException if the file is not a Java source