Classes | Public Member Functions | Static Public Member Functions

org.exolab.castor.tools.MappingTool Class Reference

List of all members.

Classes

class  InternalLoader

Public Member Functions

 MappingTool ()
void addClass (String name) throws MappingException
void addClass (String name, boolean deep) throws MappingException
void addClass (Class cls) throws MappingException
void addClass (Class cls, boolean deep) throws MappingException
void setForceIntrospection (boolean force)
void write (Writer writer) throws MappingException

Static Public Member Functions

static void main (String[] args)

Detailed Description

A tool which uses the introspector to automatically create mappings for a given set of classes.

Author:
Assaf Arkin
Keith Visco
Version:
Revision:
1.3
Date:
2004/10/01 13:25:11

Constructor & Destructor Documentation

org.exolab.castor.tools.MappingTool.MappingTool (  ) 

Member Function Documentation

void org.exolab.castor.tools.MappingTool.addClass ( String  name  )  throws MappingException

Adds the Class, specified by the given name, to the mapping file

Parameters:
name the name of the Class to add

Referenced by org.exolab.castor.tools.MappingTool.addClass(), and org.exolab.castor.tools.MappingTool.main().

void org.exolab.castor.tools.MappingTool.addClass ( Class  cls  )  throws MappingException

Adds the given Class to the mapping file

Parameters:
cls the Class to add

References org.exolab.castor.tools.MappingTool.addClass().

void org.exolab.castor.tools.MappingTool.addClass ( Class  cls,
boolean  deep 
) throws MappingException

Adds the given Class to the mapping file. If the deep flag is true, all mappings for Classes used by the given Class will also be added to the mapping file.

Parameters:
cls the Class to add
deep,a flag to indicate that recursive processing should take place and all classes used by the given class should also be added to the mapping file. This flag is true by default.

References org.exolab.castor.tools.MappingTool.addClass(), org.exolab.castor.mapping.xml.ClassMapping.addFieldMapping(), org.exolab.castor.tools.MappingTool.InternalLoader.canFindAccessors(), org.exolab.castor.xml.Introspector.generateClassDescriptor(), org.exolab.castor.mapping.xml.FieldMapping.getBindXml(), org.exolab.castor.mapping.FieldDescriptor.getClassDescriptor(), org.exolab.castor.mapping.FieldDescriptor.getFieldName(), org.exolab.castor.mapping.ClassDescriptor.getFields(), org.exolab.castor.mapping.FieldDescriptor.getFieldType(), org.exolab.castor.xml.Introspector.introspected(), org.exolab.castor.mapping.FieldDescriptor.isMultivalued(), org.exolab.castor.mapping.FieldDescriptor.isRequired(), org.exolab.castor.mapping.FieldDescriptor.isTransient(), org.exolab.castor.xml.util.ClassDescriptorResolverImpl.resolve(), org.exolab.castor.tools.MappingTool.InternalLoader.returnsArray(), org.exolab.castor.mapping.xml.ClassMapping.setAccess(), org.exolab.castor.mapping.xml.FieldMapping.setBindXml(), org.exolab.castor.mapping.xml.FieldMapping.setCollection(), org.exolab.castor.mapping.xml.FieldMapping.setContainer(), org.exolab.castor.mapping.xml.ClassMapping.setDescription(), org.exolab.castor.mapping.xml.ClassMapping.setMapTo(), org.exolab.castor.mapping.xml.BindXml.setName(), org.exolab.castor.mapping.xml.FieldMapping.setName(), org.exolab.castor.mapping.xml.ClassMapping.setName(), org.exolab.castor.mapping.xml.BindXml.setNode(), org.exolab.castor.mapping.xml.MapTo.setNsPrefix(), org.exolab.castor.mapping.xml.MapTo.setNsUri(), org.exolab.castor.mapping.xml.FieldMapping.setRequired(), org.exolab.castor.mapping.xml.FieldMapping.setTransient(), org.exolab.castor.mapping.xml.FieldMapping.setType(), and org.exolab.castor.mapping.xml.MapTo.setXml().

void org.exolab.castor.tools.MappingTool.addClass ( String  name,
boolean  deep 
) throws MappingException

Adds the Class, specified by the given name, to the mapping file

Parameters:
name the name of the Class to add
deep,a flag to indicate that recursive processing should take place and all classes used by the given class should also be added to the mapping file. This flag is true by default.

References org.exolab.castor.tools.MappingTool.addClass().

static void org.exolab.castor.tools.MappingTool.main ( String[]  args  )  [static]
void org.exolab.castor.tools.MappingTool.setForceIntrospection ( boolean  force  ) 

Enables or disables the forcing of introspection when a ClassDescriptor already exists. This is false by default.

Parameters:
force when true will cause the MappingTool to always use introspection regardless of whether or not a ClassDescriptor exists for a given Class.
void org.exolab.castor.tools.MappingTool.write ( Writer  writer  )  throws MappingException

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