public class

SchemaTranscriber

extends Object
java.lang.Object
   ↳ org.apache.commons.betwixt.schema.SchemaTranscriber

Class Overview

Generates XML Schemas for Betwixt mappings.

The basic idea is that an object model for the schema will be created and Betwixt can be used to output this to xml. This should allow both SAX and text.

Summary

Constants
String W3C_SCHEMA_INSTANCE_URI
String W3C_SCHEMA_URI
Public Constructors
SchemaTranscriber()
Public Methods
BindingConfiguration createSchemaBindingConfiguration()

Gets a BindingConfiguration that is suitable for mapping Schema.

IntrospectionConfiguration createSchemaIntrospectionConfiguration()

Gets an IntrospectionConfiguration that is suitable for introspecting Schema.

Schema generate(XMLBeanInfo xmlBeanInfo)
Generates an XML Schema model from the given XMLBeanInfo
Schema generate(Class clazz)
Generates an XML Schema model for the given class.
TranscriptionConfiguration getConfiguration()
Gets the configuration for the XMLBeanInfo to XML schema transcription.
XMLIntrospector getXMLIntrospector()
Gets the XMLIntrospector used to create XMLInfoBean's.
void setConfiguration(TranscriptionConfiguration configuration)
Sets the configuration for the XMLBeanInfo to XML schema transcription.
void setXMLIntrospector(XMLIntrospector introspector)

Sets the XMLIntrospector used to create XMLInfoBeans.

[Expand]
Inherited Methods
From class java.lang.Object

Constants

public static final String W3C_SCHEMA_INSTANCE_URI

Constant Value: "http://www.w3.org/2001/XMLSchema-instance"

public static final String W3C_SCHEMA_URI

Constant Value: "http://www.w3.org/2001/XMLSchema"

Public Constructors

public SchemaTranscriber ()

Public Methods

public BindingConfiguration createSchemaBindingConfiguration ()

Gets a BindingConfiguration that is suitable for mapping Schema.

Note: A new instance is created each time this method is called. It can therefore be safely be modified.

Returns
  • BindingConfiguration, not null

public IntrospectionConfiguration createSchemaIntrospectionConfiguration ()

Gets an IntrospectionConfiguration that is suitable for introspecting Schema.

Note: A new instance is created each time this method is called. It can therefore be safely be modified.

Returns
  • IntrospectionConfiguration, not null

public Schema generate (XMLBeanInfo xmlBeanInfo)

Generates an XML Schema model from the given XMLBeanInfo

Parameters
xmlBeanInfo not null
Returns
  • Schema model, not null

public Schema generate (Class clazz)

Generates an XML Schema model for the given class.

Parameters
clazz not null
Returns
  • Schema model, not null

public TranscriptionConfiguration getConfiguration ()

Gets the configuration for the XMLBeanInfo to XML schema transcription.

Returns
  • TranscriptionConfiguration, not null

public XMLIntrospector getXMLIntrospector ()

Gets the XMLIntrospector used to create XMLInfoBean's.

Returns
  • XMLIntrospector used to create XMLInfoBean's used to generate schema, not null

public void setConfiguration (TranscriptionConfiguration configuration)

Sets the configuration for the XMLBeanInfo to XML schema transcription.

Parameters
configuration TranscriptionConfiguration, not null

public void setXMLIntrospector (XMLIntrospector introspector)

Sets the XMLIntrospector used to create XMLInfoBeans.

Note: certain properties will be reconfigured so that the introspection will produce correct results.

Parameters
introspector XMLIntrospector used to create XMLInfoBean's used to generate schema, not null