X-Git-Url: https://juplo.de/gitweb/?p=hibernate4-maven-plugin;a=blobdiff_plain;f=src%2Fmain%2Fjava%2Fde%2Fjuplo%2Fplugins%2Fhibernate4%2FHbm2DdlMojo.java;h=04c85179823e4959c1cbbb3b2f72b2bdac84eade;hp=7c5cc340d10a1d9304f928b697d3b30f82844257;hb=2f3807b9fbde5c1230e3a22010932ddec722871b;hpb=08c347e44a4eaeb0c5106f6c03c21f8c4282a14b diff --git a/src/main/java/de/juplo/plugins/hibernate4/Hbm2DdlMojo.java b/src/main/java/de/juplo/plugins/hibernate4/Hbm2DdlMojo.java index 7c5cc340..04c85179 100644 --- a/src/main/java/de/juplo/plugins/hibernate4/Hbm2DdlMojo.java +++ b/src/main/java/de/juplo/plugins/hibernate4/Hbm2DdlMojo.java @@ -29,11 +29,11 @@ import java.sql.DriverPropertyInfo; import java.sql.SQLException; import java.sql.SQLFeatureNotSupportedException; import java.util.Enumeration; -import java.util.HashSet; import java.util.List; import java.util.Map.Entry; import java.util.Properties; import java.util.Set; +import java.util.TreeSet; import java.util.logging.Logger; import javax.persistence.Embeddable; import javax.persistence.Entity; @@ -185,14 +185,17 @@ public class Hbm2DdlMojo extends AbstractMojo MojoExecutionException { if (skip) + { + getLog().info("Exectuion of hibernate4-maven-plugin:export was skipped!"); return; + } File dir = new File(outputDirectory); if (!dir.exists()) throw new MojoExecutionException("Cannot scan for annotated classes in " + outputDirectory + ": directory does not exist!"); - Set classes = new HashSet(); + Set classes = new TreeSet(); try { AnnotationDB db = new AnnotationDB(); @@ -214,6 +217,10 @@ public class Hbm2DdlMojo extends AbstractMojo if (classes.isEmpty()) throw new MojoFailureException("No annotated classes found in directory " + outputDirectory); + getLog().info("Detected classes with mapping-annotations:"); + for (String classname : classes) + getLog().info(" " + classname); + Properties properties = new Properties(); /** Try to read configuration from properties-file */