Treffer: A Small Extension to Java for Class Refinement
Weitere Informationen
This paper presents an extended Java language in which users can refine a class definition to a certain degree. They can statically or dynamically redefine methods and append a new method, field, and interfaces to the class like dynamic languages. A unique feature of this language, named GluonJ, is that users can use a standard Java IDE (Integrated Development Environment) to exploit coding support by the IDE. This is significant for the industrial acceptability of a new language. A GluonJ program is written in standard Java with additional Java annotations. GluonJ was carefully designed so that the IDE can recognize a GluonJ program and reflect it on the coding support such as the code assist of Eclipse. Moreover, a GluonJ program never throws a runtime exception reporting that an undefined method is called. Guaranteeing this property is not straightforward because GluonJ allows users to refine a class definition at runtime.