public interface

Generator

sun.rmi.rmic.Generator
Known Indirect Subclasses

Class Overview

Generator defines the protocol for back-end implementations to be added to rmic. See the rmic.properties file for a description of the format for adding new Generators to rmic.

Classes implementing this interface must have a public default constructor which should set any required arguments to their defaults. When Main encounters a command line argument which maps to a specific Generator subclass, it will instantiate one and call parseArgs(...). At some later point, Main will invoke the generate(...) method once for _each_ class passed on the command line. WARNING: The contents of this source file are not part of any supported API. Code that depends on them does so at its own risk: they are subject to change or removal without notice.

Summary

Public Methods
abstract void generate(BatchEnvironment env, ClassDefinition cdef, File destDir)
Generate output.
abstract boolean parseArgs(String[] argv, Main main)
Examine and consume command line arguments.

Public Methods

public abstract void generate (BatchEnvironment env, ClassDefinition cdef, File destDir)

Generate output. Any source files created which need compilation should be added to the compiler environment using the addGeneratedFile(File) method.

Parameters
env The compiler environment
cdef The definition for the implementation class or interface from which to generate output
destDir The directory for the root of the package hierarchy for generated files. May be null.

public abstract boolean parseArgs (String[] argv, Main main)

Examine and consume command line arguments.

Parameters
argv The command line arguments. Ignore null and unknown arguments. Set each consumed argument to null.
main Report any errors using the main.error() methods.
Returns
  • true if no errors, false otherwise.