org.enhydra.zeus.generator
Class SimpleGenerator

java.lang.Object
  |
  +--org.enhydra.zeus.generator.SimpleGenerator
All Implemented Interfaces:
Generator

public class SimpleGenerator
extends java.lang.Object
implements Generator

Generator is the portion of Zeus that will convert a set of constraints, visible through a Binding, and output them as generated Java classes (to a File [directory]).

SimpleGenerator is the simplest form of a Generator and takes in either a single Binding or a List of them, and directly generates Java classes.

Version:
1.0
Author:
Brett McLaughlin

Constructor Summary
SimpleGenerator()
           This will construct a new instance of SimpleGenerator.
 
Method Summary
 void generate(Binding binding, java.io.File directory)
           This will convert from a set of constraints to Java classes.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SimpleGenerator

public SimpleGenerator()

This will construct a new instance of SimpleGenerator.

Method Detail

generate

public void generate(Binding binding,
                     java.io.File directory)
              throws java.io.IOException

This will convert from a set of constraints to Java classes. It accesses those constraints through the Binding interface, which provides them in a representation-independent format, and then converts them into Java code, which is output to the supplied File.

Specified by:
generate in interface Generator
Parameters:
binder - Binder with ability to convert from constraints to Zeus Bindings.
directory - File to output generated classes to.
Throws:
IOException - - when errors in writing to the supplied Result occur.


Copyright © 2001 Enhydra. All Rights Reserved.