Examples of HibernateMappingExporter


Examples of org.hibernate.tool.hbm2x.HibernateMappingExporter

   
  }
 
  public void testGenerateMappings() {
        cfg.buildMappings();
        Exporter exporter = new HibernateMappingExporter(cfg, getOutputDir());
   
    exporter.start();
   
    Configuration derived = new Configuration();
   
    derived.addFile(new File(getOutputDir(), "Withversion.hbm.xml") );
    derived.addFile(new File(getOutputDir(), "Noversion.hbm.xml") );
View Full Code Here

Examples of org.hibernate.tool.hbm2x.HibernateMappingExporter

 
  public void testGenerateAndReadable() {
   
    cfg.buildMappings();
   
    HibernateMappingExporter hme = new HibernateMappingExporter(cfg, getOutputDir());
    hme.start();   
   
    assertFileAndExists( new File(getOutputDir(), "Employee.hbm.xml") );
    assertFileAndExists( new File(getOutputDir(), "Project.hbm.xml") );
    assertFileAndExists( new File(getOutputDir(), "WorksOnContext.hbm.xml") );
   
View Full Code Here

Examples of org.hibernate.tool.hbm2x.HibernateMappingExporter

  public void testGeneration() {
   
 
    cfg.buildMappings();
   
    HibernateMappingExporter hme = new HibernateMappingExporter(cfg, getOutputDir());
    hme.start();   
   
    assertFileAndExists( new File(getOutputDir(), "Role.hbm.xml") );
    assertFileAndExists( new File(getOutputDir(), "User.hbm.xml") );
    assertFileAndExists( new File(getOutputDir(), "Plainrole.hbm.xml") );
   
View Full Code Here

Examples of org.hibernate.tool.hbm2x.HibernateMappingExporter

        final File outputdir = new File("reverseoutput");
        outputdir.mkdirs();
       
        cfg.buildMappings();
        
        Exporter exporter = new HibernateMappingExporter(cfg, outputdir);
   
        Exporter javaExp = new POJOExporter(cfg, outputdir);
        exporter.start();
        javaExp.start();
       
        XMLPrettyPrinter.prettyPrintDirectory(outputdir,".hbm.xml", false);
        TestHelper.compile(outputdir, outputdir);
       
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.