Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## net.sf.hibernate.tool.ddl2hbm
Class MapGenerator

    java.lang.Object
      |
      +--net.sf.hibernate.tool.ddl2hbm.MapGenerator

public class MapGenerator
extends Object

Author:
  Administrator

Constructor Summary
`MapGenerator()` Creates a new instance of SchemaExport

Method Summary
`protected void` | `addCompositeId(org.w3c.dom.Element classElement, Collection primaryKeys, Collection foreignKeys)`
`protected void` | `addGenerator(org.w3c.dom.Element idElement)`
`protected void` | `addHibernateClass(Connection c, String tableName, org.w3c.dom.Element mappingElement)`
`protected void` | `addId(org.w3c.dom.Element classElement, JDBCUtil.Column pkColumn)`
`protected void` | `addProperties(org.w3c.dom.Element classElement, Collection pkColumns, Collection fkColumns, Collection columns)`
`protected org.w3c.dom.Document` | `createMappingDoc()`
`void` | `generate(Connection c)`
`void` | `generateCode(org.w3c.dom.Document doc)`
`String` | `getBaseClass()` Getter for property baseClass.
`String` | `getCatalog()` Getter for property catalog.
`String` | `getGenerator()` Getter for property generator.
`String[]` | `getGeneratorParameters()` Getter for property generatorParameters.
`String` | `getIdName()` Getter for property idName.
`String` | `getIdType()` Getter for property idType.
`org.w3c.dom.Document` | `getMap(Connection c)`
`String` | `getMappingFile()` Getter for property mappingFile.
`File` | `getOutputDirectory()` Getter for property outputDirectory.
`String` | `getPackageName()` Getter for property packageName.
`String` | `getSchemaPattern()` Getter for property schemaPattern.
`String[]` | `getTableNames()` Getter for property tablePattern.
`String[]` | `getTableTypes()` Getter for property tableTypes.
`protected String` | `getXml(org.w3c.dom.Node node)`
`boolean` | `isGenerateSource()` Getter for property generateSource.
`boolean` | `isHibernateTypes()` Getter for property hibernateTypes.
`boolean` | `isSingleMapFile()` Getter for property singleMapFile.
`protected String` | `makeEntityName(String name)`
`protected String` | `makeMemberName(String name)`
`void` | `setBaseClass(String baseClass)` Setter for property baseClass.
`void` | `setCatalog(String catalog)` Setter for property catalog.
`void` | `setGenerateSource(boolean generateSource)` Setter for property generateSource.
`void` | `setGenerator(String generator)` Setter for property generator.
`void` | `setGeneratorParameters(String[] generatorParameters)` Setter for property generatorParameters.
`void` | `setHibernateTypes(boolean hibernateTypes)` Setter for property hibernateTypes.
`void` | `setIdName(String idName)` Setter for property idName.
`void` | `setIdType(String idType)` Setter for property idType.
`void` | `setMappingFile(String mappingFile)` Setter for property mappingFile.
`void` | `setOutputDirectory(File outputDirectory)` Setter for property outputDirectory.
`void` | `setPackageName(String packageName)` Setter for property packageName.
`void` | `setSchemaPattern(String schemaPattern)` Setter for property schemaPattern.
`void` | `setSingleMapFile(boolean singleMapFile)` Setter for property singleMapFile.
`void` | `setTableNames(String[] tableNames)` Setter for property tablePattern.
`void` | `setTableTypes(String[] tableTypes)` Setter for property tableTypes.
`protected void` | `writeHbm(org.w3c.dom.Node node, OutputStream os)`
`protected void` | `writeMapping(org.w3c.dom.Document mapping)`
`protected void` | `writeNode(org.w3c.dom.Node node, OutputStream os)`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### MapGenerator

    public MapGenerator()

  Creates a new instance of SchemaExport

Method Detail

### generate

    public void generate(Connection c)
                  throws IOException,
                         SQLException,
                         Exception

    `IOException`
    `SQLException`
    `Exception`

### getMap

    public org.w3c.dom.Document getMap(Connection c)
                                throws IOException,
                                       SQLException

    `IOException`
    `SQLException`

### generateCode

    public void generateCode(org.w3c.dom.Document doc)
                      throws Exception

    `Exception`

### writeMapping

    protected void writeMapping(org.w3c.dom.Document mapping)
                         throws IOException

    `IOException`

### writeHbm

    protected void writeHbm(org.w3c.dom.Node node,
                            OutputStream os)

### getXml

    protected String getXml(org.w3c.dom.Node node)

### writeNode

    protected void writeNode(org.w3c.dom.Node node,
                             OutputStream os)

### createMappingDoc

    protected org.w3c.dom.Document createMappingDoc()

### addHibernateClass

    protected void addHibernateClass(Connection c,
                                     String tableName,
                                     org.w3c.dom.Element mappingElement)
                              throws SQLException

    `SQLException`

### addId

    protected void addId(org.w3c.dom.Element classElement,
                         JDBCUtil.Column pkColumn)

### addCompositeId

    protected void addCompositeId(org.w3c.dom.Element classElement,
                                  Collection primaryKeys,
                                  Collection foreignKeys)

### addProperties

    protected void addProperties(org.w3c.dom.Element classElement,
                                 Collection pkColumns,
                                 Collection fkColumns,
                                 Collection columns)

### addGenerator

    protected void addGenerator(org.w3c.dom.Element idElement)

### makeEntityName

    protected String makeEntityName(String name)

### makeMemberName

    protected String makeMemberName(String name)

### getSchemaPattern

    public String getSchemaPattern()

  Getter for property schemaPattern.

  Returns:
    Value of property schemaPattern.

### setSchemaPattern

    public void setSchemaPattern(String schemaPattern)

  Setter for property schemaPattern.

  Parameters:
    `schemaPattern` - New value of property schemaPattern.

### getTableNames

    public String[] getTableNames()

  Getter for property tablePattern.

  Returns:
    Value of property tablePattern.

### setTableNames

    public void setTableNames(String[] tableNames)

  Setter for property tablePattern.

### getCatalog

    public String getCatalog()

  Getter for property catalog.

  Returns:
    Value of property catalog.

### setCatalog

    public void setCatalog(String catalog)

  Setter for property catalog.

  Parameters:
    `catalog` - New value of property catalog.

### getTableTypes

    public String[] getTableTypes()

  Getter for property tableTypes.

  Returns:
    Value of property tableTypes.

### setTableTypes

    public void setTableTypes(String[] tableTypes)

  Setter for property tableTypes.

  Parameters:
    `tableTypes` - New value of property tableTypes.

### getPackageName

    public String getPackageName()

  Getter for property packageName.

  Returns:
    Value of property packageName.

### setPackageName

    public void setPackageName(String packageName)

  Setter for property packageName.

  Parameters:
    `packageName` - New value of property packageName.

### getOutputDirectory

    public File getOutputDirectory()

  Getter for property outputDirectory.

  Returns:
    Value of property outputDirectory.

### setOutputDirectory

    public void setOutputDirectory(File outputDirectory)

  Setter for property outputDirectory.

  Parameters:
    `outputDirectory` - New value of property outputDirectory.

### getIdName

    public String getIdName()

  Getter for property idName.

  Returns:
    Value of property idName.

### setIdName

    public void setIdName(String idName)

  Setter for property idName.

  Parameters:
    `idName` - New value of property idName.

### getGenerator

    public String getGenerator()

  Getter for property generator.

  Returns:
    Value of property generator.

### setGenerator

    public void setGenerator(String generator)

  Setter for property generator.

  Parameters:
    `generator` - New value of property generator.

### getGeneratorParameters

    public String[] getGeneratorParameters()

  Getter for property generatorParameters.

  Returns:
    Value of property generatorParameters.

### setGeneratorParameters

    public void setGeneratorParameters(String[] generatorParameters)

  Setter for property generatorParameters.

  Parameters:
    `generatorParameters` - New value of property generatorParameters.

### getMappingFile

    public String getMappingFile()

  Getter for property mappingFile.

  Returns:
    Value of property mappingFile.

### setMappingFile

    public void setMappingFile(String mappingFile)

  Setter for property mappingFile.

  Parameters:
    `mappingFile` - New value of property mappingFile.

### getIdType

    public String getIdType()

  Getter for property idType.

  Returns:
    Value of property idType.

### setIdType

    public void setIdType(String idType)

  Setter for property idType.

  Parameters:
    `idType` - New value of property idType.

### getBaseClass

    public String getBaseClass()

  Getter for property baseClass.

  Returns:
    Value of property baseClass.

### setBaseClass

    public void setBaseClass(String baseClass)

  Setter for property baseClass.

  Parameters:
    `baseClass` - New value of property baseClass.

### isGenerateSource

    public boolean isGenerateSource()

  Getter for property generateSource.

  Returns:
    Value of property generateSource.

### setGenerateSource

    public void setGenerateSource(boolean generateSource)

  Setter for property generateSource.

  Parameters:
    `generateSource` - New value of property generateSource.

### isSingleMapFile

    public boolean isSingleMapFile()

  Getter for property singleMapFile.

  Returns:
    Value of property singleMapFile.

### setSingleMapFile

    public void setSingleMapFile(boolean singleMapFile)

  Setter for property singleMapFile.

  Parameters:
    `singleMapFile` - New value of property singleMapFile.

### isHibernateTypes

    public boolean isHibernateTypes()

  Getter for property hibernateTypes.

  Returns:
    Value of property hibernateTypes.

### setHibernateTypes

    public void setHibernateTypes(boolean hibernateTypes)

  Setter for property hibernateTypes.

  Parameters:
    `hibernateTypes` - New value of property hibernateTypes.

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD