org.ow2.easywsdl.schema
Class SchemaFactory

java.lang.Object
  extended by org.ow2.easywsdl.schema.SchemaFactory
Direct Known Subclasses:
SchemaFactoryImpl

public abstract class SchemaFactory
extends java.lang.Object

This abstract class defines a factory API that enables applications to obtain a SchemaFactory capable of producing new Definitions, new SchemaReaders, and new SchemaWriters. Some ideas used here have been shamelessly copied from the wonderful JAXP and Xerces work.

Author:
Nicolas Salatge - eBM WebSourcing

Constructor Summary
SchemaFactory()
           
 
Method Summary
static DefaultSchema getDefaultSchema()
          Get the default parent
static SchemaFactory newInstance()
          Get a new instance of a SchemaFactory.
abstract  Schema newSchema()
          Create a new instance of a Definition.
abstract  SchemaReader newSchemaReader()
          Create a new instance of a SchemaReaderImpl.
abstract  SchemaReader newSchemaReader(java.util.Map<SchemaReader.FeatureConstants,java.lang.Object> features)
          Create a new instance of a SchemaReaderImpl.
abstract  SchemaWriter newSchemaWriter()
          Create a new instance of a SchemaWriterImpl.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SchemaFactory

public SchemaFactory()
Method Detail

newInstance

public static SchemaFactory newInstance()
                                 throws SchemaException
Get a new instance of a SchemaFactory. This method follows (almost) the same basic sequence of steps that JAXP follows to determine the fully-qualified class name of the class which implements SchemaFactory.

The steps in order are:

  1. Check the property file META-INF/services/javax.wsdl.factory.SchemaFactory.
  2. Check the javax.wsdl.factory.SchemaFactory system property.
  3. Check the lib/wsdl.properties file in the JRE directory. The key will have the same name as the above system property.
  4. Use the default class name provided by the implementation.

Once an instance of a SchemaFactory is obtained, invoke newDefinition(), newSchemaReader(), or newSchemaWriter(), to create the desired instances.

Throws:
SchemaException

newSchema

public abstract Schema newSchema()
                          throws SchemaException
Create a new instance of a Definition.

Throws:
SchemaException

newSchemaReader

public abstract SchemaReader newSchemaReader()
                                      throws SchemaException
Create a new instance of a SchemaReaderImpl.

Throws:
SchemaException

newSchemaReader

public abstract SchemaReader newSchemaReader(java.util.Map<SchemaReader.FeatureConstants,java.lang.Object> features)
                                      throws SchemaException
Create a new instance of a SchemaReaderImpl.

Throws:
SchemaException

newSchemaWriter

public abstract SchemaWriter newSchemaWriter()
                                      throws SchemaException
Create a new instance of a SchemaWriterImpl.

Throws:
SchemaException

getDefaultSchema

public static DefaultSchema getDefaultSchema()
Get the default parent

Returns:
the default parent


Copyright © 2008-2009 Petals Link (previously EBM WebSourcing). All Rights Reserved.