Public Member Functions | Static Public Attributes | Protected Member Functions | Protected Attributes | Package Functions

org.exolab.castor.builder.SGStateInfo Class Reference

Inheritance diagram for org.exolab.castor.builder.SGStateInfo:
org.exolab.castor.builder.util.ClassInfoResolverImpl org.exolab.castor.builder.ClassInfoResolver

List of all members.

Public Member Functions

void bindSourceCode (Annotated annotated, JClass[] classes)
JClass[] getSourceCode (Annotated annotated)
int getStatusCode ()

Static Public Attributes

static final int NORMAL_STATUS = 0
static final int STOP_STATUS = 1

Protected Member Functions

 SGStateInfo (Schema schema, SourceGenerator sgen)

Protected Attributes

String packageName = null

Package Functions

JClass getProcessed (String className)
void markAsProcessed (JClass jClass)
boolean processed (JClass jClass)
boolean processed (String className)
boolean promptForOverwrite ()
void setPromptForOverwrite (boolean promptForOverwrite)
Schema getSchema ()
SourceGenerator getSourceGenerator ()
boolean getSuppressNonFatalWarnings ()
void setSuppressNonFatalWarnings (boolean suppressNonFatalWarnings)
Dialog getDialog ()
void setDialog (Dialog dialog)
void setStatusCode (int status)
void setVerbose (boolean verbose)
boolean verbose ()
FactoryState getCurrentFactoryState ()
void setCurrentFactoryState (FactoryState state)

Detailed Description

A class for maintaining state for the SourceGenerator

Author:
Keith Visco
Version:
Revision:
1.4
Date:
2004/10/06 08:43:27

Constructor & Destructor Documentation

org.exolab.castor.builder.SGStateInfo.SGStateInfo ( Schema  schema,
SourceGenerator  sgen 
) [protected]

Creates a new SGStateInfo

Parameters:
schema the Schema to generate source for
sgen the SourceGenerator instance

References org.exolab.castor.builder.SGStateInfo.packageName.


Member Function Documentation

void org.exolab.castor.builder.SGStateInfo.bindSourceCode ( Annotated  annotated,
JClass[]  classes 
)

Binds the given Annotated structure with it's generated source classes

Parameters:
annotated the Annotated structure to add JClass bindings for
classes the JClass[] to bind

Referenced by org.exolab.castor.builder.SourceFactory.createSourceCode().

FactoryState org.exolab.castor.builder.SGStateInfo.getCurrentFactoryState (  )  [package]

Returns the current FactoryState that holds information about the classes being generated.

Returns:
the current FactoryState

Referenced by org.exolab.castor.builder.SourceFactory.createSourceCode().

Dialog org.exolab.castor.builder.SGStateInfo.getDialog (  )  [package]

Returns the Dialog used for interacting with the user

Returns:
the Dialog, or null if none has been set.

Referenced by org.exolab.castor.builder.SourceFactory.createSourceCode().

JClass org.exolab.castor.builder.SGStateInfo.getProcessed ( String  className  )  [package]

Returns the processed JClass with the given name. If no such JClass has been marked as processed, null is returned.

Parameters:
className the JClass name to check against
Returns:
the JClass with the given name

References org.exolab.javasource.JStructure.getName().

Schema org.exolab.castor.builder.SGStateInfo.getSchema (  )  [package]
JClass [] org.exolab.castor.builder.SGStateInfo.getSourceCode ( Annotated  annotated  ) 

Returns the array of JClass for the given Annotated structure or null if no bindings have been specified for the given Structure.

Returns:
the JClass array

Referenced by org.exolab.castor.builder.SourceFactory.createSourceCode().

SourceGenerator org.exolab.castor.builder.SGStateInfo.getSourceGenerator (  )  [package]

Returns the SourceGenerator instance being used

Referenced by org.exolab.castor.builder.FactoryState.FactoryState().

int org.exolab.castor.builder.SGStateInfo.getStatusCode (  ) 

Returns the current status

Returns:
the current status
boolean org.exolab.castor.builder.SGStateInfo.getSuppressNonFatalWarnings (  )  [package]
void org.exolab.castor.builder.SGStateInfo.markAsProcessed ( JClass  jClass  )  [package]

Marks the given JClass as having been processed.

Parameters:
jClass the JClass to mark as having been processed.
boolean org.exolab.castor.builder.SGStateInfo.processed ( JClass  jClass  )  [package]

Returns true if the given JClass has been marked as processed

Parameters:
jClass the JClass to check for being marked as processed
boolean org.exolab.castor.builder.SGStateInfo.processed ( String  className  )  [package]

Returns true if a JClass with the given name has been marked as processed

Parameters:
className the JClass name to check against

References org.exolab.javasource.JStructure.getName().

boolean org.exolab.castor.builder.SGStateInfo.promptForOverwrite (  )  [package]
void org.exolab.castor.builder.SGStateInfo.setCurrentFactoryState ( FactoryState  state  )  [package]

Sets the current FactoryState.

Parameters:
state the current FactoryState
See also:
getCurrentFactoryState

Referenced by org.exolab.castor.builder.SourceFactory.createSourceCode().

void org.exolab.castor.builder.SGStateInfo.setDialog ( Dialog  dialog  )  [package]

Sets the Dialog used for interacting with the user

Parameters:
dialog the Dialog to use

Referenced by org.exolab.castor.builder.SourceGenerator.generateSource().

void org.exolab.castor.builder.SGStateInfo.setPromptForOverwrite ( boolean  promptForOverwrite  )  [package]
void org.exolab.castor.builder.SGStateInfo.setStatusCode ( int  status  )  [package]

Sets the XMLBindingComponent that this SGStateInfo is working on. Returns the XMLBindingComponent this SGStateInfo is working on.

Returns:
the XMLBindingComponent this SGStateInfo is working on. Sets the current status code to the given one
Parameters:
status the new status code
void org.exolab.castor.builder.SGStateInfo.setSuppressNonFatalWarnings ( boolean  suppressNonFatalWarnings  )  [package]
void org.exolab.castor.builder.SGStateInfo.setVerbose ( boolean  verbose  )  [package]

Sets whether or not the source code generator prints additional messages during generating source code

Parameters:
verbose a boolean, when true indicates to print additional messages

Referenced by org.exolab.castor.builder.SourceGenerator.generateSource().

boolean org.exolab.castor.builder.SGStateInfo.verbose (  )  [package]

Returns the value of the verbose flag. A true value indicates that additional messages may be printed during processing

Returns:
the value of the verbose flag.

Referenced by org.exolab.castor.builder.SourceFactory.createSourceCode().


Member Data Documentation


The documentation for this class was generated from the following file:
 All Classes Namespaces Files Functions Variables Enumerations Properties