Skip to content

rpau/javalang

Repository files navigation

javalang: Java 8 parser customized for walkmod

Build Status Build Status

Java 8 parser and Abstract Syntax Tree (AST). Therefore, lambda expressions, reference expressions, type annotations and default methods are supported.

The AST contains the source code structure, javadoc and comments. It also allows to parse Javadoc tags and the Java code links.

This parser is based on Sreenivasa Viswanadha’s Java 1.5 parser.

The project was originally hosted at javaparser but seemed dead. This repository adds powerful parsing functionalities for walkmod such as AST merge support, AST dumping as the original format or Javadoc parsing.

	This program is free software: you can redistribute it and/or modify
	it under the terms of the GNU Lesser General Public License as published by
	the Free Software Foundation, either version 3 of the License, or
	(at your option) any later version.

	This program is distributed in the hope that it will be useful,
	but WITHOUT ANY WARRANTY; without even the implied warranty of
	MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
	GNU Lesser General Public License for more details.

	You should have received a copy of the GNU Lesser General Public License
	along with this program.  If not, see <http://www.gnu.org/licenses/>.

Usage

If you are interested in creating a new walkmod plugin for Java code, you must add the following dependency in your project.

<dependency>
    <groupId>org.walkmod</groupId>
    <artifactId>javalang</artifactId>
    <version>4.3.0</version>
</dependency>

Contributing

If you want to hack on this, fork it, improve it and send me a pull request.

To get started using it, just clone it and call mvn install.