Browsable Java (J2SE 1.3 “Kestrel”) Grammar

CC-BY

Grammar extracted by Vadim Zaytsev, see the Grammar Zoo entry for details: java/java-3/bruneliere/extracted
Source used for this grammar: Hugo Brunelière, JAVA3 0.1, JAVA3.ecore, 2005/08/11 [Atlantic]

Summary

Syntax

Modifier ::=
	Class
Modifier ::=
	Interface
Modifier ::=
	Method
Modifier ::=
	Field
Class ::=
	[superClass]::Class [implement]::Interface+ [methods]::Method+ [fields]::Field+
Interface ::=
	[superInterface]::Interface+ [implementedBy]::Class+ [abstractMethods]::Method+ [constants]::Field+
Method ::=
	[share]::Boolean [class]::Class [interface]::Interface [resultOf]::Type [parameters]::Parameter+
Field ::=
	[share]::Boolean [class]::Class [interface]::Interface [value]::Value [typeOf]::Type
Value ::=
	ε
Parameter ::=
	[name]::String [typeOf]::Type [owner]::Method
Type ::=
	ReferenceType
Type ::=
	PrimitiveType
Type ::=
	ReferenceType
	PrimitiveType
ReferenceType ::=
	[reference]::Class
PrimitiveType ::=
	Int
Int ::=
	ε
String ::=
	string
Boolean ::=
	"true"
	"false"

GrammarLabMaintained by Dr. Vadim Zaytsev a.k.a. @grammarware. Last updated in September 2015. []