Oracle8i XML Reference Guide
Release 3 (8.1.7)

Part Number A83730-01

Library

Product

Contents

Index

Go to previous page Go to next page

2
XML Class Generator for Java

Description

Class Summary 

 

Classes 

 

CGDocument 

Serves as the base document class for the Class Generated generated classes 

CGNode 

Serves as the base class for nodes generated by the Class Generated 

ClassGenerator 

This class is used by the Class Generated to generate classes 

Exceptions 

 

InvalidContentException 

Definition of InvalidContentException thrown by dtdcompiler classes 

oracle.xml.classgen

CGDocument

Syntax

public abstract class CGDocument extends CGNode
 
java.lang.Object
  |
  +--CGNode
        |
        +--oracle.xml.classgen.CGDocument

Description

Serves as the base document class for the Class Generated generated classes

Inherited Member Summary 

Methods inherited from class CGNode 

setDocument(CGDocument) 

Methods inherited from class java.lang.Object 

equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait 

oracle.xml.classgen

CGNode

Syntax

public abstract class CGNode extends java.lang.Object
 
java.lang.Object
  |
  +--oracle.xml.classgen.CGNode

Direct Known Subclasses:

CGDocument

Description

Serves as the base class for nodes generated by the Class Generated

Member Summary 

 

Methods 

 

setDocument(CGDocument) 

Sets the base document (root Element) 

Inherited Member Summary 

Methods inherited from class java.lang.Object 

equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait 

Methods

setDocument(CGDocument)

public void setDocument(CGDocument d)

Sets the base document (root Element)

Parameters:

d - Base CGDocument

oracle.xml.classgen

ClassGenerator

Syntax

public class ClassGenerator extends java.lang.Object
 
java.lang.Object
  |
  +--oracle.xml.classgen.ClassGenerator

Description

This class is used by the Class Generated to generate classes

Member Summary 

 

Constructors 

 

ClassGenerator() 

Default constructor for ClassGenerator. 

Methods 

 

generate(DTD, String) 

Traverses the DTD with element doctype as root and generates Java classes 

setGenerateComments(boolean) 

Switch to determine whether to generate java doc comments Default - TRUE 

setJavaPackage(String) 

Sets the package for the classes generated Default - No package 

setOutputDirectory(String) 

Sets the output directory Default - current directory 

setSerializationMode(boolean) 

Switch to determine if the DTD should be saved as a serialized object or as text file. 

setValidationMode(boolean) 

Switch to determine whether the classes generated should validate the XML Document being constructed Default - TRUE 

Inherited Member Summary 

Methods inherited from class java.lang.Object 

equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait 

Constructors

ClassGenerator()

public  ClassGenerator()

Default constructor for ClassGenerator.

Methods

generate(DTD, String)

public void generate(oracle.xml.classgen.DTD dtd, java.lang.String doctype)

Traverses the DTD with element doctype as root and generates Java classes

Parameters:

DTD - The DTD used to generate the classes

doctype - Name of the root Element

setGenerateComments(boolean)

public void setGenerateComments(boolean comments)

Switch to determine whether to generate java doc comments Default - TRUE

Parameters:

comments - boolean flag

setJavaPackage(String)

public void setJavaPackage(java.lang.String packageName)

Sets the package for the classes generated Default - No package

Parameters:

packageName - Name of the package

setOutputDirectory(String)

public void setOutputDirectory(java.lang.String dir)

Sets the output directory Default - current directory

Parameters:

dir - Output directory

setSerializationMode(boolean)

public void setSerializationMode(boolean flag)

Switch to determine if the DTD should be saved as a serialized object or as text file. Serializing the DTD improves the performance when the generated classes are used to author XML files. Default - FALSE (DTD is saved a text file)

Parameters:

flag - boolean flag

setValidationMode(boolean)

public void setValidationMode(boolean flag)

Switch to determine whether the classes generated should validate the XML Document being constructed Default - TRUE

Parameters:

flag - boolean flag

oracle.xml.classgen

InvalidContentException

Syntax

public class InvalidContentException extends java.lang.Exception
 
java.lang.Object
  |
  +--java.lang.Throwable
        |
        +--java.lang.Exception
              |
              +--oracle.xml.classgen.InvalidContentException

All Implemented Interfaces:

java.io.Serializable

Description

Definition of InvalidContentException thrown by dtdcompiler classes

Member Summary 

 

Constructors 

 

InvalidContentException() 

 

InvalidContentException(String) 

 

Inherited Member Summary 

Methods inherited from class java.lang.Throwable 

fillInStackTrace, getLocalizedMessage, getMessage, printStackTrace, printStackTrace, printStackTrace, toString 

Methods inherited from class java.lang.Object 

equals, getClass, hashCode, notify, notifyAll, wait, wait, wait 

Constructors

InvalidContentException()

public  InvalidContentException()

InvalidContentException(String)

public  InvalidContentException(java.lang.String s)

Go to previous page Go to next page
Oracle
Copyright © 1996-2000, Oracle Corporation.

All Rights Reserved.

Library

Product

Contents

Index