Package org.eigenbase.resgen

# Class JavaFunctorBaseGenerator

java.lang.Object
org.eigenbase.resgen.AbstractGenerator
org.eigenbase.resgen.AbstractJavaGenerator
org.eigenbase.resgen.JavaBaseGenerator
org.eigenbase.resgen.JavaFunctorBaseGenerator

All Implemented Interfaces:
  `Generator`

public class JavaFunctorBaseGenerator extends JavaBaseGenerator
Generates a Java class for the base locale, using the 'functor' code-generation style.

For each resource, the generated Java class contains one public, final, non-static member. This member belongs to a class which has a number of methods for creating strings or exceptions based upon this resource. The methods are typesafe; that is, they have the same number and type of parameters as the resource itself.

Since:
  19 September, 2005
Version:
  $Id: //open/util/resgen/src/org/eigenbase/resgen/JavaFunctorBaseGenerator.java#4 $
Author:
  jhyde

## Nested Class Summary

## Nested classes/interfaces inherited from class org.eigenbase.resgen.JavaBaseGenerator

`JavaBaseGenerator.ExceptionDescription`

## Field Summary

### Fields inherited from class org.eigenbase.resgen.JavaBaseGenerator

`warnedClasses`

### Fields inherited from class org.eigenbase.resgen.AbstractJavaGenerator

`baseClassName, className, resourceBundle`

## Constructor Summary

Constructors
Constructor
Description
`JavaFunctorBaseGenerator(File srcFile, File file, String className, String baseClassName, ResourceDef.ResourceBundle resourceBundle)`

## Method Summary

Modifier and Type
Method
Description
`void`
`generateResource(ResourceDef.Resource resource, PrintWriter pw)`
Generates code for a particular resource.
`protected void`
`postModule(PrintWriter pw)`

### Methods inherited from class org.eigenbase.resgen.JavaBaseGenerator

`addLists, addLists, generateModule`

### Methods inherited from class org.eigenbase.resgen.AbstractJavaGenerator

`generateFooter, generateHeader, getArgTypes, getBaseClassName, getClassName, getErrorClass, getPackageName`

### Methods inherited from class org.eigenbase.resgen.AbstractGenerator

`generateDoNotModifyHeader, generateGeneratedByBlock, getArgumentList, getFile, getParameterList, getSrcFileForComment, setScmSafeComments, useScmSafeComments`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

## Constructor Details

### JavaFunctorBaseGenerator

JavaFunctorBaseGenerator(File srcFile, File file, String className, String baseClassName, ResourceDef.ResourceBundle resourceBundle)

## Method Details

### generateResource

public void generateResource(ResourceDef.Resource resource, PrintWriter pw)
Description copied from class: `AbstractGenerator`
Generates code for a particular resource.

Overrides:
  `generateResource` in class `JavaBaseGenerator`

### postModule

protected void postModule(PrintWriter pw)

Overrides:
  `postModule` in class `JavaBaseGenerator`