404: Page Not Found!
We do not know, where you are.
+And we do not know, why you are here.
+But we can tell you: WE ARE SORRY!
+Really.
+From: Kai Moritz We do not know, where you are. And we do not know, why you are here. But we can tell you: WE ARE SORRY! Really. We do not know, what happend. But we can tell you: WE ARE SORRY! Really. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved.
- This error-handler handels responses withe the HTTP-status code
-
- If the HTTP-status-code of the response is not Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. The Overview page is the front page of this API document and provides a list of all packages with a summary for each. This page can also contain an overall description of the set of packages. Each package has a page that contains a list of its classes and interfaces, with a summary for each. This page can contain six categories: Each class, interface, nested class and nested interface has its own separate page. Each of these pages has three sections consisting of a class/interface description, summary tables, and detailed member descriptions: Each summary entry contains the first sentence from the detailed description for that item. The summary entries are alphabetical, while the detailed descriptions are in the order they appear in the source code. This preserves the logical groupings established by the programmer. Each annotation type has its own separate page with the following sections: Each enum has its own separate page with the following sections: Each documented package, class and interface has its own Use page. This page describes what packages, classes, methods, constructors and fields use any part of the given class or package. Given a class or interface A, its Use page includes subclasses of A, fields declared as A, methods that return A, and methods and constructors with parameters of type A. You can access this page by first going to the package, class or interface, then clicking on the "Use" link in the navigation bar. There is a Class Hierarchy page for all packages, plus a hierarchy for each package. Each hierarchy page contains a list of classes and a list of interfaces. The classes are organized by inheritance structure starting with The Deprecated API page lists all of the API that have been deprecated. A deprecated API is not recommended for use, generally due to improvements, and a replacement API is usually given. Deprecated APIs may be removed in future implementations. The Index contains an alphabetic list of all classes, interfaces, constructors, methods, and fields. These links take you to the next or previous class, interface, package, or related page. These links show and hide the HTML frames. All pages are available with or without frames. The All Classes link shows all classes and interfaces except non-static nested types. Each serializable or externalizable class has a description of its serialization fields and methods. This information is of interest to re-implementors, not to developers using the API. While there is no link in the navigation bar, you can get to this information by going to any serialized class and clicking "Serialized Form" in the "See also" section of the class description. The Constant Field Values page lists the static final fields and their values. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved.
- The most simple way to configure the plugin is, to put all the
- hibernate-configuration in a hibernate.properties-file on your
- classpath. Put the file in the resources-folder. Maven will put
- it in the class-folder of your webapp, where it will be picked up
- by this plugin as well as by Hibernate 4.
-
- Doing so, the only additionally configuration needed, to activat the plugin
- is the following entry in the plugins-section of your pom.xml:
-
- But be aware, that in this case the database-url, that is
- build in the application is the same that is used while testing, where
- the database is droped and recreated by the plugin.
- Because of that,
-
- you should never fire up this configuration on your production
- system, or your database might be erased!
-
-
- A better approach is, to specify a different url for testing like in the
- following snippet:
-
- Configuration properties, that are set in the configuration-section
- of the plugin-configuration cannnot be overwritten elsewere (for details
- see Configuration-Method-Precedence).
- You never can overwrite them by accident when specifying a property on
- the commandline or in your settings.xml.
-
- Alternatively, it is possible, to configure the plugin via maven-properties.
- Each relevant configuration-option has a corresponding maven-property
- (for a full list see the Documentation of the export-Mojo).
- These are named after the
- Hibernate JDBC Properties:
-
- So, instead of writing the hibernate-configuration in the properties-file,
- like above, you could put it in the properties-section of your
- pom.xml.
-
- Thogether with the plugin-definition from above, the following would
- be a complete configuration (again, the database-url was overwritten in
- the plugin-configuration, to be sure to have a separate database for
- testing):
-
- A third way for configuring the plugin is the plugin-configuration.
- The relevant configuration-parameters are:
-
- The equivalent of the configuration from the last section would look
- like this:
-
- The parameter hibernateProperties (name of the hibernate-properties-file
- to use, defaults to hibernate.properties) can only be configured through
- this approach.
-
- For more explanations, see the
- Documentation of the export-Mojo.
-
- The configuration is gathered in a fix order:
-
- If you are in doubt about where a configuration-value comes from, run
- maven with the debug-output enabled: mvn -X hibernate:export
- and be aware, that maven-properties can be overwitten on the command-line,
- in your ~/.m2/settings.xml and in a profile.
-
- The plugin-configuration comes last and overwrites everything else.
- That way, you can be sure, that a configuration-value, that is
- specified in the plugin-configuration will never be overwritten by any
- other configuration-method.
-
- If you need to overwrite plugin-configuration-values with
- maven-properties, you can use maven-properties in the plugin-configuration:
-
- If you are new to hibernate-maven-plugin, in many cases, the
- {Configuration-Method-Precedence} may be the source of configuration
- errors.
- To solve this problem, you should run maven with the debugging output
- enabled.
- For example, by executing:
-
- (The compile might be necessary, because hibernate-maven-plugin
- has to scan the compiled classes for annotations!)
-
- Unlike the majority of the maven-plugins, hibernate-maven-plugin was
- designed to give a good many hints, when debugging is enabled.
- Because, if you do not know, what went wrong, you can't fix it!
-
- But be warned: hibernate-maven-plugin tends to be very chatty ;)
- The following is a list of compile dependencies for this project. These dependencies are required to compile and run the application: The following is a list of test dependencies for this project. These dependencies are only required to compile and run unit tests for the application: The following is a list of provided dependencies for this project. These dependencies are required to compile the application, but should be provided by default when using the library: The following is a list of transitive dependencies for this project. Transitive dependencies are the dependencies of the project dependencies. The following is a list of compile dependencies for this project. These dependencies are required to compile and run the application: The following is a list of test dependencies for this project. These dependencies are only required to compile and run unit tests for the application: The following is a list of provided dependencies for this project. These dependencies are required to compile the application, but should be provided by default when using the library: Apache 2.0: OAuth2 for Spring Security Eclipse Public License 1.0: JUnit MIT License: JCL 1.1.1 implemented over SLF4J, SLF4J API Module CDDL + GPLv2 with classpath exception: Java Servlet API Public Domain: AOP alliance GNU Lesser General Public License: Logback Classic Module, Logback Core Module New BSD License: Hamcrest Core The Apache Software License, Version 2.0: Commons Codec, Data Mapper for Jackson, Jackson, Jackson-annotations, Jackson-core, Juplo - Facebook Utils, Spring AOP, Spring Beans, Spring Context, Spring Core, Spring Expression Language (SpEL), Spring TestContext Framework, Spring Web, Spring Web MVC, jackson-databind, spring-security-core Eclipse Public License - v 1.0: AspectJ runtime, Logback Classic Module, Logback Core Module Repository locations for each of the Dependencies. The following is the distribution management information used by this project.
- The hibernate-maven-plugin computes MD5-sums for all found annotated
- classes and stores them together with the generated schema.
- If no classes were changed or added and the dialect wasn't changed too, it
- automatically skips the configured schema-export, to speed up the development
- cycle.
-
- The plugin signals, that the execution was skipped by setting the maven
- property $\{hibernate.export.skipped\} to true.
- This may be helpful, because other plugins like
- dbunit-plugin
- may fail, when the execution is skipped.
-
- If you need the hibernate-maven-plugin to <never skip execution automatically>,
- you can force it to do so, if you set the parameter force to
- true:
-
- Or you may specify -Dhibernate.export.force=true at the command line,
- if you want to force hibernate-maven-plugin only once.
-
- The hibernate-maven-plugin is a plugin for generating a database-schema
- from your Hibernate-4-Mappings and create or update your database
- accordingly.
- Its main usage is to automatically create and populate a test-database
- for unit-tests in cooperation with the
- dbunit-maven-plugin.
-
- The plugin was designed with three main goals in mind:
-
- To achieve the first goal, the convention-over-configuration paradigma
- was applied and the plugin was stuffed with usefull logging-messages.
- So, if in doubt, just turn on the debugging output with the mvn -X ....
-
- To achieve the second goal, the precedence in which the configuration
- locations are consulted was layouted in a way that makes it possible, to
- prevent overwrites of the wrong database by accident.
-
- Last but not least, in order to not slow down the development cycle, the
- hibernate-maven-plugin only executes the schema-export, if the mapping
- or the dialect changes (or if you force it to do so).
-
- For more information about the inspiration to write this tiny plugin,
- read our blog-article about the hibernate-maven-plugin.
-
- Please send your bug-reports, questions or feature-requests directly
- to the developer.
- Typically the licenses listed for the project are that of the project itself, and not of dependencies. A business-friendly OSS license
- Please send your bug-reports, questions or feature-requests directly
- to the developer.
-
- hibernate-maven-plugin by default scans dependencies in the scope
- compile. You can configure it to scan dependencies in other
- scopes as well. But it scans only direct dependencies. Transitive
- dependencies are not scanned for annotated classes. If some of your
- annotated classes are hidden in a transitive dependency, you can simply
- add that dependency explicitly.
-
- The default-configuration uses the EXPORT-target of the SchemaExport-Tool.
- If you do not need to create a database with the evaluated schema, you can
- use the NONE- or the SCRIPT-target.
- This can be achieved with the command-line parameter
- -Dhibernate.export.target=SCRIPT or with the following configuration:
-
- But even when no database is to be created, hibernate always needs to know
- the dialect. Hence, the plugin will fail if this parameter is missing!
-
- One regular problem is the scope of the jdbc-driver-dependency.
- It is very unlikely, that this dependency is needed at compile-time.
- So a tidy maven-developer would usually scope it for runtime.
-
- But this will break the execution of the hibernate-maven-plugin.
- Since it will not be able to see the needed dependency, it will fail with
- an error-message like:
-
- A quick workaround for this error would be, to delete the runtime-constraint
- for the jdbc-driver-dependency.
-
- A much cleaner way is, to (additionally) ad the dependency, to the
- plugin-definition:
-
- This is also the best way, if you use a different jdbc-driver for
- testing, than in production.
- Because otherwise, this dependency will unnecessarily bloat the
- runtime-dependencies of your project.
-
- If hibernate-maven-plugin skips its excecution, this may lead to errors in
- other plugins.
- For example, when importing sample-data in the automatically created database
- with the help of the dbunit-plugin,
- the CLEAN_INSERT-operation may fail because of foreign-key-constraints,
- if the database was not recreated, because the hibernate-maven-plugin has
- skipped its excecution.
-
- A quick fix to this problem is, to force
- hibernate-maven-plugin to export the schema every time it is running.
- But to recreate the database on every testrun may noticeable slow down your
- development cycle, if you have to wait for slow IO.
-
- To circumvent this problem, hibernate-maven-plugin signals a skipped
- excecution by setting the maven property $\{hibernate.export.skipped\} to
- true.
- You can configure other plugins to react on this signal.
- For example, the dbunit-plugin can be configured to skip its excecution, if
- hibernate-maven-plugin was skipped like this:
-
- If one manually drops the database or removes the hsqldb-files, it will not
- be recreated by the hibernate-maven-plugin, because it cannot detect, that
- the database needs to be recreated.
- This happens, because the plugin will not recreate the database if neither
- the configuration nor the annotated classes have changed, because an
- unnecessary drop-create-cycle might take a long time. The plugin will
- report that like this:
-
- If one always uses mvn clean for cleanup, this will not happen.
- Otherwise the recreation must be forced:
-
- The hibernate-maven-plugin automatically skips its execution, when
- maven.test.skip is set to true. If you need it to be always
- executed, you can configure that explicitly like this:
-
- Background-information for this design-decission can be found on the extra
- page To skip or not to skip: that is the question...
-
- If you do not want your dependencies to be scanned for hibernate annotations,
- you can pass -Dhibernate.export.scan_dependencies=none to maven
- or set scanDependencies to none in the configuration
- of the plugin like this:
-
- If you are working under Windows and get the error-message
- No annotated classes found in directory C:\projects\X Y Z\path-to-project\target\classes,
- but you are really sure, that there are annotated classes in that
- directory, you are expiriencing a bug, in the scannotation-library, that
- was closed in version 1.1.0 of the hibernate-maven-plugin.
-
-
- You should consider to upgrade to that version of the plugin.
-
- The following document contains the results of PMD 5.3.2. This document provides an overview of the various documents and links that are part of this project's general information. All of this content is automatically generated by Maven on behalf of the project. This document provides an overview of the various reports that are automatically generated by Maven . Each report is briefly described below.
- In most use-cases, the hibernate-maven-plugin is used to create a
- test-database automatically. In this use-cases, it is very likely, that it
- will result in mistakes/errors, if the goal is executed, when the tests
- are skipped.
- For example, one might manually overwrite the database-url with the url of
- the production-database, in order to run other tests, like starting a
- local webserver with the
- jetty-maven-plugin.
- If the export-goal would be executed in such a scenario, it might erase the
- hole production-database, which is not very desireable.
-
- Because of this, the configuration-parameter skip defaults to the value
- of the proptery maven.test.skip. This way, the execution of the
- hibernate-maven-plugin is skipped automatically, when the tests are
- skipped. Think of it as a build-in security-belt.
-
- If you do not like that, because you need the plugin to always execute the
- export-goal, even if the tests are skipped you can configure that explicitly,
- by setting the configuration-parameter skip to false:
-
- Or, if you want the export-goal to be executed by default and to be skipped
- if you say so, you can bind the value of the configuration-parameter
- skip to a custom property. For example:
-
- This way, the export-goal would be skipped, if you set the property
- foo.bar to true. For example, if you specify -Dfoo.bar=true
- on the command-line.
- This project uses GIT to manage its source code. Instructions on GIT use can be found at http://git-scm.com/documentation. The source can be checked out anonymously from GIT with this command (See http://git-scm.com/docs/git-clone): Only project developers can access the GIT tree via this method (See http://git-scm.com/docs/git-clone). [Summary] [Package List] [Test Cases] Note: failures are anticipated and checked for with assertions while errors are unanticipated. [Summary] [Package List] [Test Cases] Note: package statistics are not computed recursively, they only sum up all of its testsuites numbers. [Summary] [Package List] [Test Cases] A successful project requires many people to play many roles. Some members write code or documentation, while others are valuable as testers, submitting patches and suggestions. The team is comprised of Members and Contributors. Members have direct access to the source of a project and actively evolve the code-base. Contributors improve the project through submission of patches and suggestions to the Members. The number of Contributors to the project is unbounded. Get involved today. All contributions to the project are greatly appreciated. The following is a list of developers with commit privileges that have directly contributed to the project in one way or another. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. The Overview page is the front page of this API document and provides a list of all packages with a summary for each. This page can also contain an overall description of the set of packages. Each package has a page that contains a list of its classes and interfaces, with a summary for each. This page can contain six categories: Each class, interface, nested class and nested interface has its own separate page. Each of these pages has three sections consisting of a class/interface description, summary tables, and detailed member descriptions: Each summary entry contains the first sentence from the detailed description for that item. The summary entries are alphabetical, while the detailed descriptions are in the order they appear in the source code. This preserves the logical groupings established by the programmer. Each annotation type has its own separate page with the following sections: Each enum has its own separate page with the following sections: Each documented package, class and interface has its own Use page. This page describes what packages, classes, methods, constructors and fields use any part of the given class or package. Given a class or interface A, its Use page includes subclasses of A, fields declared as A, methods that return A, and methods and constructors with parameters of type A. You can access this page by first going to the package, class or interface, then clicking on the "Use" link in the navigation bar. There is a Class Hierarchy page for all packages, plus a hierarchy for each package. Each hierarchy page contains a list of classes and a list of interfaces. The classes are organized by inheritance structure starting with The Deprecated API page lists all of the API that have been deprecated. A deprecated API is not recommended for use, generally due to improvements, and a replacement API is usually given. Deprecated APIs may be removed in future implementations. The Index contains an alphabetic list of all classes, interfaces, constructors, methods, and fields. These links take you to the next or previous class, interface, package, or related page. These links show and hide the HTML frames. All pages are available with or without frames. The All Classes link shows all classes and interfaces except non-static nested types. Each serializable or externalizable class has a description of its serialization fields and methods. This information is of interest to re-implementors, not to developers using the API. While there is no link in the navigation bar, you can get to this information by going to any serialized class and clicking "Serialized Form" in the "See also" section of the class description. The Constant Field Values page lists the static final fields and their values. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved. This document is designed to be viewed using the frames feature. If you see this message, you are using a non-frame-capable web client. Link to Non-frame version. Copyright © 2015. All rights reserved. Copyright © 2015. All rights reserved.
- You don't have frames. Go here
-
- You don't have frames. Go here
- Copyright © 2016. All Rights Reserved. Copyright © 2016. All Rights Reserved. Copyright © 2016. All Rights Reserved. Copyright © 2016. All Rights Reserved. Copyright © 2016. All Rights Reserved. Copyright © 2016. All Rights Reserved. Copyright © 2016. All Rights Reserved. Copyright © 2016. All Rights Reserved. Copyright © 2016. All Rights Reserved. Copyright © 2016. All Rights Reserved. Copyright © 2016. All Rights Reserved. Copyright © 2016. All Rights Reserved. Copyright © 2016. All Rights Reserved. Copyright © 2016. All Rights Reserved. Copyright © 2016. All Rights Reserved. Copyright © 2016. All Rights Reserved. Copyright © 2016. All Rights Reserved. Each package has a page that contains a list of its classes and interfaces, with a summary for each. This page can contain six categories: Each class, interface, nested class and nested interface has its own separate page. Each of these pages has three sections consisting of a class/interface description, summary tables, and detailed member descriptions: Each summary entry contains the first sentence from the detailed description for that item. The summary entries are alphabetical, while the detailed descriptions are in the order they appear in the source code. This preserves the logical groupings established by the programmer. Each annotation type has its own separate page with the following sections: Each enum has its own separate page with the following sections: Each documented package, class and interface has its own Use page. This page describes what packages, classes, methods, constructors and fields use any part of the given class or package. Given a class or interface A, its Use page includes subclasses of A, fields declared as A, methods that return A, and methods and constructors with parameters of type A. You can access this page by first going to the package, class or interface, then clicking on the "Use" link in the navigation bar. There is a Class Hierarchy page for all packages, plus a hierarchy for each package. Each hierarchy page contains a list of classes and a list of interfaces. The classes are organized by inheritance structure starting with The Deprecated API page lists all of the API that have been deprecated. A deprecated API is not recommended for use, generally due to improvements, and a replacement API is usually given. Deprecated APIs may be removed in future implementations. The Index contains an alphabetic list of all classes, interfaces, constructors, methods, and fields. These links take you to the next or previous class, interface, package, or related page. These links show and hide the HTML frames. All pages are available with or without frames. The All Classes link shows all classes and interfaces except non-static nested types. Each serializable or externalizable class has a description of its serialization fields and methods. This information is of interest to re-implementors, not to developers using the API. While there is no link in the navigation bar, you can get to this information by going to any serialized class and clicking "Serialized Form" in the "See also" section of the class description. The Constant Field Values page lists the static final fields and their values. Copyright © 2016. All Rights Reserved. Copyright © 2016. All Rights Reserved. This document is designed to be viewed using the frames feature. If you see this message, you are using a non-frame-capable web client. Link to Non-frame version. Copyright © 2016. All Rights Reserved.
- The most simple way to configure the plugin is, to put all the
- hibernate-configuration in a hibernate.properties- or
- a hibernate.cfg.xml-file on your classpath or in the
- persistence.xml-file of your JPA-configuration, just
- like you would do, if you are not using the
- hibernate-maven-plugin.
-
- Doing so, the only additionally configuration needed, to activat the plugin
- is the following entry in the plugins-section of your pom.xml:
-
- This would create the configured database.
- If you want it to be droped beforehand, you have to add the goal
- drop:
-
- A correspondin goal for the command update is missing in this
- version, but we are planning to implement it in near feature.
-
- In order to let this configuration work, your configuration file must
- contain a complete valid configuration for the database, that you want
- to use.
- A simple example hibernate.properties-file may look like this:
-
- But be aware, that using this configuration-approach the database-url,
- that is build in the application is the same that is used while testing,
- where the database is droped and recreated by the plugin.
- Because of that,
-
- you should never fire up this configuration on your production
- system, or your database might be erased!
-
-
- A better approach is, to specify a different url for testing like in the
- following snippet:
-
- Configuration properties, that are set in the configuration-section
- of the plugin-configuration cannnot be overwritten elsewere (for details
- see Configuration-Method-Precedence).
- You never can overwrite them by accident when specifying a property on
- the commandline or in your settings.xml.
-
- Alternatively, it is possible, to configure the plugin via maven-properties.
- Each relevant configuration-option has a corresponding maven-property
- (for a full list see the Documentation of the goal create).
- These are named after the
- Hibernate JDBC Properties:
-
- So, instead of writing the hibernate-configuration in the properties-file,
- like above, you could put it in the properties-section of your
- pom.xml.
-
- Thogether with the plugin-definition from above, the following would
- be a complete configuration (again, the database-url was overwritten in
- the plugin-configuration, to be sure to have a separate database for
- testing):
-
- This way, you can reuse the same properties to provide a
- default-configurationthe, that is build into your application, and
- overwrite the database-url, that is used during testing to prevent
- accidential drops of your production database.
-
- A third way for configuring the plugin is the plugin-configuration.
- The relevant configuration-parameters are:
-
- The equivalent of the configuration from the last section would look
- like this:
-
- The parameter hibernateProperties (name of the hibernate-properties-file
- to use, defaults to hibernate.properties) can only be configured through
- this approach.
-
- For more explanations, see the
- Documentation of the goal create.
-
- The configuration is gathered in a fix order:
-
- If you are in doubt about where a configuration-value comes from, run
- maven with the debug-output enabled: mvn -X hibernate:create
- and be aware, that maven-properties can be overwitten on the command-line,
- in your ~/.m2/settings.xml and in a profile.
-
- The plugin-configuration comes last and overwrites everything else.
- That way, you can be sure, that a configuration-value, that is
- specified in the plugin-configuration will never be overwritten by any
- other configuration-method.
-
- If you need to overwrite plugin-configuration-values with
- maven-properties, you can use maven-properties in the plugin-configuration:
- The following document contains the results of PMD's CPD 5.2.3. Full name: de.juplo:hibernate-maven-plugin:2.0.0:create Description: Attributes: Important: This configuration value can only be
-configured through the pom.xml, or by the definition
-of a system-property, because it is not known by Hibernate nor JPA
-and, hence, not picked up from their configuration! Important: This configuration value can only be
-configured through the pom.xml, or by the definition
-of a system-property, because it is not known by Hibernate nor JPA
-and, hence, not picked up from their configuration! Force execution, even if no modified or newly added annotated
-classes where found and the dialect was not changed. skip takes precedence over force. Important: This configuration value can only be
-configured through the pom.xml, or by the definition
-of a system-property, because it is not known by Hibernate nor JPA
-and, hence, not picked up from their configuration! If this parameter is not set the plugin will load configuration
-values from a ressource named hibernate.cfg.xml on the
-classpath, if it is present, but will not fail if there is no such
-ressource. During ressource-lookup, the test-classpath takes
-precedence. Settings in this file will overwrite settings in the properties
-file. If this parameter is not set the plugin will load configuration
-values from a ressource named hibernate.properties on
-the classpath, if it is present, but will not fail if there is no
-such ressource. During ressource-lookup, the test-classpath takes
-precedence. This parameter defaults to the maven build-output-directory for
-classes. Additionally, all dependencies are scanned for annotated
-classes. Important: This configuration value can only be
-configured through the pom.xml, or by the definition
-of a system-property, because it is not known by Hibernate nor JPA
-and, hence, not picked up from their configuration! If the specified filename is not absolut, the file will be
-created relative to the project build directory
-(project.build.directory). If this parameter is not set and there is only one
-persistence-unit available, that unit will be used automatically.
-But if this parameter is not set and there are multiple
-persistence-units available on, the class-path, the execution of
-the plugin will fail. Settings in this file will overwrite settings in the properties
-or the configuration file. This parameter is intended to allow overwriting of the parameter
-exclude-unlisted-classes of a
-persistence-unit. If not specified, it defaults to
-true By default, only dependencies in the scope compile
-are scanned for annotated classes. Multiple scopes can be seperated
-by white space or commas. If you do not want any dependencies to be scanned for annotated
-classes, set this parameter to none. The plugin does not scan for annotated classes in transitive
-dependencies. If some of your annotated classes are hidden in a
-transitive dependency, you can simply add that dependency
-explicitly. If this parameter is set to true the test-classes
-of the artifact will be scanned for hibernate-annotated classes
-additionally. Important: This configuration value can only be
-configured through the pom.xml, or by the definition
-of a system-property, because it is not known by Hibernate nor JPA
-and, hence, not picked up from their configuration! If set to true, the execution is skipped. A skipped execution is signaled via the maven-property
-${hibernate.schema.skipped}. The execution is skipped automatically, if no modified or newly
-added annotated classes are found and the dialect was not
-changed. Important: This configuration value can only be
-configured through the pom.xml, or by the definition
-of a system-property, because it is not known by Hibernate nor JPA
-and, hence, not picked up from their configuration! This parameter defaults to the maven build-output-directory for
-test-classes. This parameter is only used, when scanTestClasses
-is set to true! Important: This configuration value can only be
-configured through the pom.xml, or by the definition
-of a system-property, because it is not known by Hibernate nor JPA
-and, hence, not picked up from their configuration! Important: This configuration value can only be
-configured through the pom.xml, or by the definition
-of a system-property, because it is not known by Hibernate nor JPA
-and, hence, not picked up from their configuration! Important: This configuration value can only be
-configured through the pom.xml, or by the definition
-of a system-property, because it is not known by Hibernate nor JPA
-and, hence, not picked up from their configuration! Force execution, even if no modified or newly added annotated
-classes where found and the dialect was not changed. skip takes precedence over force. Important: This configuration value can only be
-configured through the pom.xml, or by the definition
-of a system-property, because it is not known by Hibernate nor JPA
-and, hence, not picked up from their configuration! If this parameter is not set the plugin will load configuration
-values from a ressource named hibernate.cfg.xml on the
-classpath, if it is present, but will not fail if there is no such
-ressource. During ressource-lookup, the test-classpath takes
-precedence. Settings in this file will overwrite settings in the properties
-file. If this parameter is not set the plugin will load configuration
-values from a ressource named hibernate.properties on
-the classpath, if it is present, but will not fail if there is no
-such ressource. During ressource-lookup, the test-classpath takes
-precedence. This parameter defaults to the maven build-output-directory for
-classes. Additionally, all dependencies are scanned for annotated
-classes. Important: This configuration value can only be
-configured through the pom.xml, or by the definition
-of a system-property, because it is not known by Hibernate nor JPA
-and, hence, not picked up from their configuration! If the specified filename is not absolut, the file will be
-created relative to the project build directory
-(project.build.directory). If this parameter is not set and there is only one
-persistence-unit available, that unit will be used automatically.
-But if this parameter is not set and there are multiple
-persistence-units available on, the class-path, the execution of
-the plugin will fail. Settings in this file will overwrite settings in the properties
-or the configuration file. This parameter is intended to allow overwriting of the parameter
-exclude-unlisted-classes of a
-persistence-unit. If not specified, it defaults to
-true By default, only dependencies in the scope compile
-are scanned for annotated classes. Multiple scopes can be seperated
-by white space or commas. If you do not want any dependencies to be scanned for annotated
-classes, set this parameter to none. The plugin does not scan for annotated classes in transitive
-dependencies. If some of your annotated classes are hidden in a
-transitive dependency, you can simply add that dependency
-explicitly. If this parameter is set to true the test-classes
-of the artifact will be scanned for hibernate-annotated classes
-additionally. Important: This configuration value can only be
-configured through the pom.xml, or by the definition
-of a system-property, because it is not known by Hibernate nor JPA
-and, hence, not picked up from their configuration! show: skip: If set to true, the execution is skipped. A skipped execution is signaled via the maven-property
-${hibernate.schema.skipped}. The execution is skipped automatically, if no modified or newly
-added annotated classes are found and the dialect was not
-changed. Important: This configuration value can only be
-configured through the pom.xml, or by the definition
-of a system-property, because it is not known by Hibernate nor JPA
-and, hence, not picked up from their configuration! This parameter defaults to the maven build-output-directory for
-test-classes. This parameter is only used, when scanTestClasses
-is set to true! Important: This configuration value can only be
-configured through the pom.xml, or by the definition
-of a system-property, because it is not known by Hibernate nor JPA
-and, hence, not picked up from their configuration! url:
- If you are new to hibernate-maven-plugin, in many cases, the
- Configuration-Method-Precedence
- may be the source of configuration errors.
- To solve this problem, you should run maven with the debugging output
- enabled.
- For example, by executing:
-
- (The compile might be necessary, because hibernate-maven-plugin
- has to scan the compiled classes for annotations!)
-
- Unlike the majority of the maven-plugins, hibernate-maven-plugin was
- designed to give a good many hints, when debugging is enabled.
- Because, if you do not know, what went wrong, you can't fix it!
-
- But be warned: hibernate-maven-plugin tends to be very chatty ;)
- The following is a list of compile dependencies for this project. These dependencies are required to compile and run the application: The following is a list of transitive dependencies for this project. Transitive dependencies are the dependencies of the project dependencies. The following is a list of compile dependencies for this project. These dependencies are required to compile and run the application: Apache License, version 2.0: JBoss Logging 3 Eclipse Public License (EPL), Version 1.0: Java Persistence API, Version 2.1 Apache Public License 2.0: Plexus Cipher: encryption/decryption Component, Plexus Security Dispatcher Component Public Domain: AOP alliance GNU Lesser General Public License: Core Hibernate O/RM functionality, ENtity VERSioning support, Hibernate Commons Annotations, Hibernate JPA Support Eclipse Distribution License (EDL), Version 1.0: Java Persistence API, Version 2.1 Eclipse Public License, Version 1.0: Aether API, Aether Implementation, Aether SPI, Aether Utilities, org.eclipse.sisu.inject, org.eclipse.sisu.plexus Unknown: dom4j, scannotation Apache License 2.0: Javassist BSD License: AntLR Parser Generator AL 2.0: Java Annotation Indexer Apache License, Version 2.0: CDI APIs, Hibernate Validator Engine, Maven Aether Provider, Maven Artifact, Maven Builder Support, Maven Core, Maven Model, Maven Model Builder, Maven Plugin API, Maven Repository Metadata Model, Maven Settings, Maven Settings Builder COMMON DEVELOPMENT AND DISTRIBUTION LICENSE (CDDL) Version 1.0: JSR-250 Common Annotations for the JavaTM Platform LGPL 2.1: Javassist CDDL + GPLv2 with classpath exception: Expression Language 3.0 API MPL 1.1: Javassist The Apache Software License, Version 2.0: Bean Validation API, ClassMate, Guava: Google Core Libraries for Java, Hibernate Maven Plugin, JTA 1.1, Log4j, Plexus :: Component Annotations, Plexus Classworlds, Plexus Interpolation API, Sisu Guice - Core Library, XML Commons External Components XML APIs, javax.inject, maven-plugin-log4j Repository locations for each of the Dependencies. The following is the distribution management information used by this project. Full name: de.juplo:hibernate-maven-plugin:2.0.0:drop Description: Attributes: Important: This configuration value can only be
-configured through the pom.xml, or by the definition
-of a system-property, because it is not known by Hibernate nor JPA
-and, hence, not picked up from their configuration! Important: This configuration value can only be
-configured through the pom.xml, or by the definition
-of a system-property, because it is not known by Hibernate nor JPA
-and, hence, not picked up from their configuration! Force execution, even if no modified or newly added annotated
-classes where found and the dialect was not changed. skip takes precedence over force. Important: This configuration value can only be
-configured through the pom.xml, or by the definition
-of a system-property, because it is not known by Hibernate nor JPA
-and, hence, not picked up from their configuration! If this parameter is not set the plugin will load configuration
-values from a ressource named hibernate.cfg.xml on the
-classpath, if it is present, but will not fail if there is no such
-ressource. During ressource-lookup, the test-classpath takes
-precedence. Settings in this file will overwrite settings in the properties
-file. If this parameter is not set the plugin will load configuration
-values from a ressource named hibernate.properties on
-the classpath, if it is present, but will not fail if there is no
-such ressource. During ressource-lookup, the test-classpath takes
-precedence. This parameter defaults to the maven build-output-directory for
-classes. Additionally, all dependencies are scanned for annotated
-classes. Important: This configuration value can only be
-configured through the pom.xml, or by the definition
-of a system-property, because it is not known by Hibernate nor JPA
-and, hence, not picked up from their configuration! If the specified filename is not absolut, the file will be
-created relative to the project build directory
-(project.build.directory). If this parameter is not set and there is only one
-persistence-unit available, that unit will be used automatically.
-But if this parameter is not set and there are multiple
-persistence-units available on, the class-path, the execution of
-the plugin will fail. Settings in this file will overwrite settings in the properties
-or the configuration file. This parameter is intended to allow overwriting of the parameter
-exclude-unlisted-classes of a
-persistence-unit. If not specified, it defaults to
-true By default, only dependencies in the scope compile
-are scanned for annotated classes. Multiple scopes can be seperated
-by white space or commas. If you do not want any dependencies to be scanned for annotated
-classes, set this parameter to none. The plugin does not scan for annotated classes in transitive
-dependencies. If some of your annotated classes are hidden in a
-transitive dependency, you can simply add that dependency
-explicitly. If this parameter is set to true the test-classes
-of the artifact will be scanned for hibernate-annotated classes
-additionally. Important: This configuration value can only be
-configured through the pom.xml, or by the definition
-of a system-property, because it is not known by Hibernate nor JPA
-and, hence, not picked up from their configuration! If set to true, the execution is skipped. A skipped execution is signaled via the maven-property
-${hibernate.schema.skipped}. The execution is skipped automatically, if no modified or newly
-added annotated classes are found and the dialect was not
-changed. Important: This configuration value can only be
-configured through the pom.xml, or by the definition
-of a system-property, because it is not known by Hibernate nor JPA
-and, hence, not picked up from their configuration! This parameter defaults to the maven build-output-directory for
-test-classes. This parameter is only used, when scanTestClasses
-is set to true! Important: This configuration value can only be
-configured through the pom.xml, or by the definition
-of a system-property, because it is not known by Hibernate nor JPA
-and, hence, not picked up from their configuration! Important: This configuration value can only be
-configured through the pom.xml, or by the definition
-of a system-property, because it is not known by Hibernate nor JPA
-and, hence, not picked up from their configuration! Important: This configuration value can only be
-configured through the pom.xml, or by the definition
-of a system-property, because it is not known by Hibernate nor JPA
-and, hence, not picked up from their configuration! Force execution, even if no modified or newly added annotated
-classes where found and the dialect was not changed. skip takes precedence over force. Important: This configuration value can only be
-configured through the pom.xml, or by the definition
-of a system-property, because it is not known by Hibernate nor JPA
-and, hence, not picked up from their configuration! If this parameter is not set the plugin will load configuration
-values from a ressource named hibernate.cfg.xml on the
-classpath, if it is present, but will not fail if there is no such
-ressource. During ressource-lookup, the test-classpath takes
-precedence. Settings in this file will overwrite settings in the properties
-file. If this parameter is not set the plugin will load configuration
-values from a ressource named hibernate.properties on
-the classpath, if it is present, but will not fail if there is no
-such ressource. During ressource-lookup, the test-classpath takes
-precedence. This parameter defaults to the maven build-output-directory for
-classes. Additionally, all dependencies are scanned for annotated
-classes. Important: This configuration value can only be
-configured through the pom.xml, or by the definition
-of a system-property, because it is not known by Hibernate nor JPA
-and, hence, not picked up from their configuration! If the specified filename is not absolut, the file will be
-created relative to the project build directory
-(project.build.directory). If this parameter is not set and there is only one
-persistence-unit available, that unit will be used automatically.
-But if this parameter is not set and there are multiple
-persistence-units available on, the class-path, the execution of
-the plugin will fail. Settings in this file will overwrite settings in the properties
-or the configuration file. This parameter is intended to allow overwriting of the parameter
-exclude-unlisted-classes of a
-persistence-unit. If not specified, it defaults to
-true By default, only dependencies in the scope compile
-are scanned for annotated classes. Multiple scopes can be seperated
-by white space or commas. If you do not want any dependencies to be scanned for annotated
-classes, set this parameter to none. The plugin does not scan for annotated classes in transitive
-dependencies. If some of your annotated classes are hidden in a
-transitive dependency, you can simply add that dependency
-explicitly. If this parameter is set to true the test-classes
-of the artifact will be scanned for hibernate-annotated classes
-additionally. Important: This configuration value can only be
-configured through the pom.xml, or by the definition
-of a system-property, because it is not known by Hibernate nor JPA
-and, hence, not picked up from their configuration! show: skip: If set to true, the execution is skipped. A skipped execution is signaled via the maven-property
-${hibernate.schema.skipped}. The execution is skipped automatically, if no modified or newly
-added annotated classes are found and the dialect was not
-changed. Important: This configuration value can only be
-configured through the pom.xml, or by the definition
-of a system-property, because it is not known by Hibernate nor JPA
-and, hence, not picked up from their configuration! This parameter defaults to the maven build-output-directory for
-test-classes. This parameter is only used, when scanTestClasses
-is set to true! Important: This configuration value can only be
-configured through the pom.xml, or by the definition
-of a system-property, because it is not known by Hibernate nor JPA
-and, hence, not picked up from their configuration! url:
- The hibernate-maven-plugin computes MD5-sums for all found annotated
- classes and stores them together with the generated schema.
- If no classes were changed or added and the dialect wasn't changed too, it
- automatically skips the configured schema-export, to speed up the development
- cycle.
-
- The plugin signals, that the execution was skipped by setting the maven
- property ${hibernate.schema.skipped} to true.
- This may be helpful, because other plugins like
- dbunit-plugin
- may fail, when the execution is skipped.
-
- If you need the hibernate-maven-plugin to never skip execution automatically,
- you can force it to do so, if you set the parameter force to
- true:
-
- Or you may specify -Dhibernate.schema.force=true at the command line,
- if you want to force hibernate-maven-plugin only once.
- Full name: de.juplo:hibernate-maven-plugin:2.0.0:help Description: Attributes: goal:
- The hibernate-maven-plugin is a plugin for generating a database-schema
- from your Hibernate-Mappings and create or update your database
- accordingly.
- Its main usage is to automatically create and populate a test-database
- for unit-tests in cooperation with the
- dbunit-maven-plugin.
-
- The plugin was designed with three main goals in mind:
-
- To achieve the first goal, the convention-over-configuration paradigma
- was applied and the plugin was stuffed with usefull logging-messages.
- So, if in doubt, just turn on the debugging output with the mvn -X ....
-
- To achieve the second goal, the precedence in which the configuration
- locations are consulted was layouted in a way that makes it possible, to
- prevent overwrites of the wrong database by accident.
-
- Last but not least, in order to not slow down the development cycle, the
- hibernate-maven-plugin only executes the schema-export, if the mapping
- or the dialect changes (or if you force it to do so).
-
- For more information about the inspiration to write this tiny plugin,
- read our blog-article about the hibernate-maven-plugin.
- Configuration for notifying developers/users when a build is unsuccessful, including user information and notification mode.
- Please send your bug-reports, questions or feature-requests directly
- to the developer.
- Typically the licenses listed for the project are that of the project itself, and not of dependencies. A business-friendly OSS license
- Please send your bug-reports, questions or feature-requests directly
- to the developer.
-
- hibernate-maven-plugin by default scans dependencies in the scope
- compile. You can configure it to scan dependencies in other
- scopes as well. But it scans only direct dependencies. Transitive
- dependencies are not scanned for annotated classes. If some of your
- annotated classes are hidden in a transitive dependency, you can simply
- add that dependency explicitly.
-
- The default-configuration exports the created schema to the configured
- database.
- Therefore, it needs a valid database-connection and fails, if none is
- available.
- If you do not need to export the created schema to a database,
- you can set the property hibernate.schema.export to
- false.
- This can be achieved with the command-line parameter
- -Dhibernate.schema.export=false or with the following
- configuration:
-
- But even when no database is to be created, hibernate always needs to know
- the dialect. Hence, the plugin will still fail, if this parameter is also
- missing!
-
- One regular problem is the scope of the jdbc-driver-dependency.
- It is very unlikely, that this dependency is needed at compile-time.
- So a tidy maven-developer would usually scope it for runtime.
-
- But this will break the execution of the hibernate-maven-plugin.
- Since it will not be able to see the needed dependency, it will fail with
- an error-message like:
-
- A quick workaround for this error would be, to delete the runtime-constraint
- for the jdbc-driver-dependency.
-
- A much cleaner way is, to (additionally) ad the dependency, to the
- plugin-definition:
-
- This is also the best way, if you use a different jdbc-driver for
- testing, than in production.
- Because otherwise, this dependency will unnecessarily bloat the
- runtime-dependencies of your project.
-
- If hibernate-maven-plugin skips its excecution, this may lead to errors in
- other plugins.
- For example, when importing sample-data in the automatically created database
- with the help of the dbunit-plugin,
- the CLEAN_INSERT-operation may fail because of foreign-key-constraints,
- if the database was not recreated, because the hibernate-maven-plugin has
- skipped its excecution.
-
- A quick fix to this problem is, to force
- hibernate-maven-plugin to export the schema every time it is running.
- But to recreate the database on every testrun may noticeable slow down your
- development cycle, if you have to wait for slow IO.
-
- To circumvent this problem, hibernate-maven-plugin signals a skipped
- excecution by setting the maven property ${hibernate.schema.skipped} to
- true.
- You can configure other plugins to react on this signal.
- For example, the dbunit-plugin can be configured to skip its excecution, if
- hibernate-maven-plugin was skipped like this:
-
- If one manually drops the database or removes the hsqldb-files, it will not
- be recreated by the hibernate-maven-plugin, because it cannot detect, that
- the database needs to be recreated.
- This happens, because the plugin will not recreate the database if neither
- the configuration nor the annotated classes have changed, because an
- unnecessary drop-create-cycle might take a long time. The plugin will
- report that like this:
-
- If one always uses mvn clean for cleanup, this will not happen.
- Otherwise the recreation must be forced:
-
- The hibernate-maven-plugin automatically skips its execution, when
- maven.test.skip is set to true. If you need it to be always
- executed, you can configure that explicitly like this:
-
- Background-information for this design-decission can be found on the extra
- page To skip or not to skip: that is the question...
-
- If you do not want your dependencies to be scanned for hibernate annotations,
- you can pass -Dhibernate.schema.scan.dependencies=none to maven
- or set scanDependencies to none in the configuration
- of the plugin like this:
-
- If you are working under Windows and get the error-message
- No annotated classes found in directory C:\projects\X Y Z\path-to-project\target\classes,
- but you are really sure, that there are annotated classes in that
- directory, you are expiriencing a bug, in the scannotation-library, that
- was closed in version 1.1.0 of the hibernate-maven-plugin.
-
-
- You should consider to upgrade to the latest version of the plugin.
-
- Goals available for this plugin: The following specifies the minimum requirements to run this Maven plugin: You should specify the version in your project's plugin configuration: For more information, see "Guide to Configuring Plug-ins" The following document contains the results of PMD 5.2.3. This document provides an overview of the various documents and links that are part of this project's general information. All of this content is automatically generated by Maven on behalf of the project. This document provides an overview of the various reports that are automatically generated by Maven . Each report is briefly described below.
- In most use-cases, the hibernate-maven-plugin is used to create a
- test-database automatically. In this use-cases, it is very likely, that it
- will result in mistakes/errors, if the goal is executed, when the tests
- are skipped.
- For example, one might manually overwrite the database-url with the url of
- the production-database, in order to run other tests, like starting a
- local webserver with the
- jetty-maven-plugin.
- If the drop-goal would be executed in such a scenario, it might erase the
- hole production-database, which is not very desireable.
-
- Because of this, the configuration-parameter skip defaults to the value
- of the proptery maven.test.skip. This way, the execution of the
- hibernate-maven-plugin is skipped automatically, when the tests are
- skipped. Think of it as a build-in security-belt.
-
- If you do not like that, because you need the plugin to always,
- even if the tests are skipped you can configure that explicitly,
- by setting the configuration-parameter skip to false:
-
- Or, if you want the plugin to be executed by default and to be skipped
- if you say so, you can bind the value of the configuration-parameter
- skip to a custom property. For example:
-
- This way, the plugin would be skipped, if you set the property
- foo.bar to true. For example, if you specify -Dfoo.bar=true
- on the command-line.
- This project uses GIT to manage its source code. Instructions on GIT use can be found at http://git-scm.com/documentation. The source can be checked out anonymously from GIT with this command (See http://git-scm.com/docs/git-clone): Only project developers can access the GIT tree via this method (See http://git-scm.com/docs/git-clone). A successful project requires many people to play many roles. Some members write code or documentation, while others are valuable as testers, submitting patches and suggestions. The team is comprised of Members and Contributors. Members have direct access to the source of a project and actively evolve the code-base. Contributors improve the project through submission of patches and suggestions to the Members. The number of Contributors to the project is unbounded. Get involved today. All contributions to the project are greatly appreciated. The following is a list of developers with commit privileges that have directly contributed to the project in one way or another. The following additional people have contributed to this project through the way of suggestions, patches or documentation. Copyright © 2016. All Rights Reserved. Copyright © 2016. All Rights Reserved. Copyright © 2016. All Rights Reserved. Copyright © 2016. All Rights Reserved. Copyright © 2016. All Rights Reserved. Copyright © 2016. All Rights Reserved. Copyright © 2016. All Rights Reserved. Each package has a page that contains a list of its classes and interfaces, with a summary for each. This page can contain six categories: Each class, interface, nested class and nested interface has its own separate page. Each of these pages has three sections consisting of a class/interface description, summary tables, and detailed member descriptions: Each summary entry contains the first sentence from the detailed description for that item. The summary entries are alphabetical, while the detailed descriptions are in the order they appear in the source code. This preserves the logical groupings established by the programmer. Each annotation type has its own separate page with the following sections: Each enum has its own separate page with the following sections: Each documented package, class and interface has its own Use page. This page describes what packages, classes, methods, constructors and fields use any part of the given class or package. Given a class or interface A, its Use page includes subclasses of A, fields declared as A, methods that return A, and methods and constructors with parameters of type A. You can access this page by first going to the package, class or interface, then clicking on the "Use" link in the navigation bar. There is a Class Hierarchy page for all packages, plus a hierarchy for each package. Each hierarchy page contains a list of classes and a list of interfaces. The classes are organized by inheritance structure starting with The Deprecated API page lists all of the API that have been deprecated. A deprecated API is not recommended for use, generally due to improvements, and a replacement API is usually given. Deprecated APIs may be removed in future implementations. The Index contains an alphabetic list of all classes, interfaces, constructors, methods, and fields. These links take you to the next or previous class, interface, package, or related page. These links show and hide the HTML frames. All pages are available with or without frames. The All Classes link shows all classes and interfaces except non-static nested types. Each serializable or externalizable class has a description of its serialization fields and methods. This information is of interest to re-implementors, not to developers using the API. While there is no link in the navigation bar, you can get to this information by going to any serialized class and clicking "Serialized Form" in the "See also" section of the class description. The Constant Field Values page lists the static final fields and their values. Copyright © 2016. All Rights Reserved. Copyright © 2016. All Rights Reserved. This document is designed to be viewed using the frames feature. If you see this message, you are using a non-frame-capable web client. Link to Non-frame version. Copyright © 2016. All Rights Reserved.
- You don't have frames. Go here
-
- You don't have frames. Go here
- Copyright © 2017. All Rights Reserved. Copyright © 2017. All Rights Reserved. Copyright © 2017. All Rights Reserved. Copyright © 2017. All Rights Reserved. Copyright © 2017. All Rights Reserved. Copyright © 2017. All Rights Reserved. Copyright © 2017. All Rights Reserved. Copyright © 2017. All Rights Reserved. Copyright © 2017. All Rights Reserved. Copyright © 2017. All Rights Reserved. Copyright © 2017. All Rights Reserved. Copyright © 2017. All Rights Reserved. Copyright © 2017. All Rights Reserved. Copyright © 2017. All Rights Reserved. Copyright © 2017. All Rights Reserved. Copyright © 2017. All Rights Reserved. Copyright © 2017. All Rights Reserved. Copyright © 2017. All Rights Reserved. Copyright © 2017. All Rights Reserved. Each package has a page that contains a list of its classes and interfaces, with a summary for each. This page can contain six categories: Each class, interface, nested class and nested interface has its own separate page. Each of these pages has three sections consisting of a class/interface description, summary tables, and detailed member descriptions: Each summary entry contains the first sentence from the detailed description for that item. The summary entries are alphabetical, while the detailed descriptions are in the order they appear in the source code. This preserves the logical groupings established by the programmer. Each annotation type has its own separate page with the following sections: Each enum has its own separate page with the following sections: Each documented package, class and interface has its own Use page. This page describes what packages, classes, methods, constructors and fields use any part of the given class or package. Given a class or interface A, its Use page includes subclasses of A, fields declared as A, methods that return A, and methods and constructors with parameters of type A. You can access this page by first going to the package, class or interface, then clicking on the "Use" link in the navigation bar. There is a Class Hierarchy page for all packages, plus a hierarchy for each package. Each hierarchy page contains a list of classes and a list of interfaces. The classes are organized by inheritance structure starting with The Deprecated API page lists all of the API that have been deprecated. A deprecated API is not recommended for use, generally due to improvements, and a replacement API is usually given. Deprecated APIs may be removed in future implementations. The Index contains an alphabetic list of all classes, interfaces, constructors, methods, and fields. These links take you to the next or previous class, interface, package, or related page. These links show and hide the HTML frames. All pages are available with or without frames. The All Classes link shows all classes and interfaces except non-static nested types. Each serializable or externalizable class has a description of its serialization fields and methods. This information is of interest to re-implementors, not to developers using the API. While there is no link in the navigation bar, you can get to this information by going to any serialized class and clicking "Serialized Form" in the "See also" section of the class description. The Constant Field Values page lists the static final fields and their values. Copyright © 2017. All Rights Reserved. Copyright © 2017. All Rights Reserved. This document is designed to be viewed using the frames feature. If you see this message, you are using a non-frame-capable web client. Link to Non-frame version. Copyright © 2017. All Rights Reserved.
-
+
+
+ 404: Page Not Found!
+
+
+ An Unexpected Error Occured!
All Classes
-
-
-All Classes
-
-
-de.juplo.*
-
-
-
-
-
-
-
-Modifier and Type
-Constant Field
-Value
-
-
-
-
-
-
-public static final String
-PARAM_SIGNED_REQUEST
-"signed_request"
Class FacebookUtils
-
-
-
-
-
-
-
-
-@Configuration
-public class FacebookUtils
-extends Object
-
-
-
-
-
-
-
-Constructor Summary
-
-
-
-
-Constructor and Description
-
-
-
-FacebookUtils()
-
-Method Summary
-
-
-
-
-
-Modifier and Type
-Method and Description
-
-
-
-org.springframework.beans.factory.config.BeanPostProcessor
-getBeanPostProcessor(String clientSecret)
-
-
-void
-init()
-
-
-
-Method Detail
-
-
-
-
-
-
-
-
-init
-@PostConstruct
-public void init()
-
-
-getBeanPostProcessor
-@Bean
-public org.springframework.beans.factory.config.BeanPostProcessor getBeanPostProcessor(String clientSecret)
-Annotation Type Sanitize
-Class SanitizeAspect
-
-
-
-
-
-
-
-
-public class SanitizeAspect
-extends Object
-
-
-
-
-
-
-
-Constructor Summary
-
-
-
-
-Constructor and Description
-
-
-
-SanitizeAspect()
-
-Method Summary
-
-
-
-
-
-Modifier and Type
-Method and Description
-
-
-
-void
-sanitize(org.aspectj.lang.ProceedingJoinPoint jp,
- String in,
- Sanitize sanitize)
-
-
-
-
-Method Detail
-
-
-
-
-
-sanitize
-public void sanitize(org.aspectj.lang.ProceedingJoinPoint jp,
- String in,
- Sanitize sanitize)
- throws Throwable
-
-
-
- This method ensures that the output String has only
- valid XML unicode characters as specified by the
- XML 1.0 standard. For reference, please see
- the
- standard. This method will return an empty
- String if the input is null or empty.
-
-jp
- The join-point captured by AspectJ.in
- The String whose non-valid characters we want to remove.sanitize
- The annotation, the field was marked with.Throwable
Uses of Class
-
de.juplo.facebook.aspects.Sanitize
-
-
-
-
-
-
-Package
-Description
-
-
-
-de.juplo.facebook.aspects
-
-
-
-Uses of Sanitize in de.juplo.facebook.aspects
-
-
-
-
-
-Modifier and Type
-Method and Description
-
-
-
-
-void
SanitizeAspect.
-sanitize(org.aspectj.lang.ProceedingJoinPoint jp,
- String in,
- Sanitize sanitize)
-Uses of Class
-
de.juplo.facebook.aspects.SanitizeAspectde.juplo.facebook.aspects
-
-
-
diff --git a/dist/facebook-utils-2.5.0/apidocs/de/juplo/facebook/aspects/package-summary.html b/dist/facebook-utils-2.5.0/apidocs/de/juplo/facebook/aspects/package-summary.html
deleted file mode 100644
index 59754041..00000000
--- a/dist/facebook-utils-2.5.0/apidocs/de/juplo/facebook/aspects/package-summary.html
+++ /dev/null
@@ -1,159 +0,0 @@
-
-
-
-
-
-
-Package de.juplo.facebook.aspects
-
-
-
-
-
-
-
-Class
-Description
-
-
-
-SanitizeAspect
-
-
-
-
-
-
-Annotation Type
-Description
-
-
-
-Sanitize
-
-Class Hierarchy
-
-
-
-
-Annotation Type Hierarchy
-
-
-Uses of Package
-
de.juplo.facebook.aspects
-
-
-
-
-
-
-Package
-Description
-
-
-
-de.juplo.facebook.aspects
-
-
-
-
-
-
-Class and Description
-
-
-
-Sanitize
-Uses of Class
-
de.juplo.facebook.FacebookUtilsClass GraphApiErrorHandler
-
-
-
-
-
-
-
-
-
-
-public class GraphApiErrorHandler
-extends Object
-implements org.springframework.web.client.ResponseErrorHandler
-400 BAD REQUEST
. It tries to extract and parse the error-message
- from the HTTP-body. Successfully extracted and parsed messages are mapped
- to a hierarchy of exceptions, that reflects the hierarchy of the error-
- codes and -types.
- 400 BAD REQUEST
or
- the HTTP-body could not be extracted or parsed, this error-handler
- delegates the handling to its parent.
-
-
-
-
-
-
-Constructor Summary
-
-
-
-
-Constructor and Description
-
-
-
-GraphApiErrorHandler(org.springframework.web.client.ResponseErrorHandler errorHandler)
-
-Method Summary
-
-
-
-
-
-Modifier and Type
-Method and Description
-
-
-
-void
-handleError(org.springframework.http.client.ClientHttpResponse response)
-
-
-boolean
-hasError(org.springframework.http.client.ClientHttpResponse response)
-
-
-
-
-Constructor Detail
-
-
-
-
-
-GraphApiErrorHandler
-public GraphApiErrorHandler(org.springframework.web.client.ResponseErrorHandler errorHandler)
-
-
-Method Detail
-
-
-
-
-
-
-
-
-hasError
-public boolean hasError(org.springframework.http.client.ClientHttpResponse response)
- throws IOException
-
-
-hasError
in interface org.springframework.web.client.ResponseErrorHandler
IOException
-
-handleError
-public void handleError(org.springframework.http.client.ClientHttpResponse response)
- throws IOException
-
-
-handleError
in interface org.springframework.web.client.ResponseErrorHandler
IOException
Uses of Class
-
de.juplo.facebook.client.GraphApiErrorHandlerde.juplo.facebook.client
-Classes
-
-Package de.juplo.facebook.client
-
-
-
-
-
-
-
-Class
-Description
-
-
-
-GraphApiErrorHandler
-
-
-Class Hierarchy
-
-
-
-
-Uses of Package
-
de.juplo.facebook.clientClass AccessTokenRequiredException
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-public class AccessTokenRequiredException
-extends OAuthException
-
-
-
-
-
-
-
-Nested Class Summary
-
-
-Nested classes/interfaces inherited from class de.juplo.facebook.exceptions.GraphApiException
-GraphApiException.FacebookErrorMessage, GraphApiException.Type
-
-
-Field Summary
-
-
-Fields inherited from class org.springframework.security.oauth2.common.exceptions.OAuth2Exception
-ACCESS_DENIED, DESCRIPTION, ERROR, INSUFFICIENT_SCOPE, INVALID_CLIENT, INVALID_GRANT, INVALID_REQUEST, INVALID_SCOPE, INVALID_TOKEN, REDIRECT_URI_MISMATCH, UNAUTHORIZED_CLIENT, UNSUPPORTED_GRANT_TYPE, UNSUPPORTED_RESPONSE_TYPE, URI
-
-
-Constructor Summary
-
-
-
-
-Modifier
-Constructor and Description
-
-
-
-protected
-AccessTokenRequiredException(GraphApiException.FacebookErrorMessage error)
-
-Method Summary
-
-
-Methods inherited from class de.juplo.facebook.exceptions.GraphApiException
-create, create, create, getCode, getSubCode, getTraceId, getType, getUserMessage, getUserTitle, toString
-
-Methods inherited from class org.springframework.security.oauth2.common.exceptions.OAuth2Exception
-addAdditionalInformation, create, getAdditionalInformation, getHttpErrorCode, getOAuth2ErrorCode, getSummary, valueOf
-
-
-Methods inherited from class java.lang.Throwable
-addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace
-
-
-
-Constructor Detail
-
-
-
-
-
-AccessTokenRequiredException
-protected AccessTokenRequiredException(GraphApiException.FacebookErrorMessage error)
-Class CallbackVerificationFailedException
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-public class CallbackVerificationFailedException
-extends OAuthException
-
-
-
-
-
-
-
-Nested Class Summary
-
-
-Nested classes/interfaces inherited from class de.juplo.facebook.exceptions.GraphApiException
-GraphApiException.FacebookErrorMessage, GraphApiException.Type
-
-
-Field Summary
-
-
-Fields inherited from class org.springframework.security.oauth2.common.exceptions.OAuth2Exception
-ACCESS_DENIED, DESCRIPTION, ERROR, INSUFFICIENT_SCOPE, INVALID_CLIENT, INVALID_GRANT, INVALID_REQUEST, INVALID_SCOPE, INVALID_TOKEN, REDIRECT_URI_MISMATCH, UNAUTHORIZED_CLIENT, UNSUPPORTED_GRANT_TYPE, UNSUPPORTED_RESPONSE_TYPE, URI
-
-
-Constructor Summary
-
-
-
-
-Modifier
-Constructor and Description
-
-
-
-protected
-CallbackVerificationFailedException(GraphApiException.FacebookErrorMessage error)
-
-Method Summary
-
-
-Methods inherited from class de.juplo.facebook.exceptions.GraphApiException
-create, create, create, getCode, getSubCode, getTraceId, getType, getUserMessage, getUserTitle, toString
-
-Methods inherited from class org.springframework.security.oauth2.common.exceptions.OAuth2Exception
-addAdditionalInformation, create, getAdditionalInformation, getHttpErrorCode, getOAuth2ErrorCode, getSummary, valueOf
-
-
-Methods inherited from class java.lang.Throwable
-addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace
-
-
-
-Constructor Detail
-
-
-
-
-
-CallbackVerificationFailedException
-protected CallbackVerificationFailedException(GraphApiException.FacebookErrorMessage error)
-Class GraphApiException.FacebookErrorMessage
-
-
-
-
-
-
-
-
-
-
-public static class GraphApiException.FacebookErrorMessage
-extends Object
-
-
-
-
-
-
-Enum GraphApiException.Type
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-public static enum GraphApiException.Type
-extends Enum<GraphApiException.Type>
-
-
-
-
-
-Enum Constant Summary
-
-
-
-
-Enum Constant and Description
-
-
-
-GraphMethodException
-
-
-OAuthException
-
-Method Summary
-
-
-
-
-
-
-Modifier and Type
-Method and Description
-
-
-
-static GraphApiException.Type
-valueOf(String name)
-
-
-
-static GraphApiException.Type[]
-values()
-
-
-
-
-
-Enum Constant Detail
-
-
-
-
-
-
-
-
-OAuthException
-public static final GraphApiException.Type OAuthException
-
-
-GraphMethodException
-public static final GraphApiException.Type GraphMethodException
-
-
-Method Detail
-
-
-
-
-
-
-
-
-values
-public static GraphApiException.Type[] values()
-
-for (GraphApiException.Type c : GraphApiException.Type.values())
- System.out.println(c);
-
-
-
-
-valueOf
-public static GraphApiException.Type valueOf(String name)
-
-
-name
- the name of the enum constant to be returned.IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is null
-
-
-
-Class GraphApiException
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-public class GraphApiException
-extends org.springframework.security.oauth2.common.exceptions.OAuth2Exception
-
-
-
-
-
-
-
-Nested Class Summary
-
-
-
-
-Modifier and Type
-Class and Description
-
-
-
-static class
-GraphApiException.FacebookErrorMessage
-
-
-
-static class
-GraphApiException.Type
-
-
-Field Summary
-
-
-Fields inherited from class org.springframework.security.oauth2.common.exceptions.OAuth2Exception
-ACCESS_DENIED, DESCRIPTION, ERROR, INSUFFICIENT_SCOPE, INVALID_CLIENT, INVALID_GRANT, INVALID_REQUEST, INVALID_SCOPE, INVALID_TOKEN, REDIRECT_URI_MISMATCH, UNAUTHORIZED_CLIENT, UNSUPPORTED_GRANT_TYPE, UNSUPPORTED_RESPONSE_TYPE, URI
-
-
-Constructor Summary
-
-
-
-
-Modifier
-Constructor and Description
-
-
-
-protected
-GraphApiException(GraphApiException.FacebookErrorMessage error)
-
-Method Summary
-
-
-
-
-Modifier and Type
-Method and Description
-
-
-
-static GraphApiException
-create(byte[] message)
-
-
-static GraphApiException
-create(GraphApiException.FacebookErrorMessage error)
-
-
-static GraphApiException
-create(InputStream in)
-
-
-Integer
-getCode()
-
-
-Integer
-getSubCode()
-
-
-String
-getTraceId()
-
-
-GraphApiException.Type
-getType()
-
-
-String
-getUserMessage()
-
-
-String
-getUserTitle()
-
-
-String
-toString()
-
-Methods inherited from class org.springframework.security.oauth2.common.exceptions.OAuth2Exception
-addAdditionalInformation, create, getAdditionalInformation, getHttpErrorCode, getOAuth2ErrorCode, getSummary, valueOf
-
-
-Methods inherited from class java.lang.Throwable
-addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace
-
-
-
-
-Constructor Detail
-
-
-
-
-
-GraphApiException
-protected GraphApiException(GraphApiException.FacebookErrorMessage error)
-
-
-Method Detail
-
-
-
-
-
-
-
-
-create
-public static GraphApiException create(InputStream in)
- throws IOException,
- com.fasterxml.jackson.core.JsonParseException,
- com.fasterxml.jackson.databind.JsonMappingException
-
-
-IOException
com.fasterxml.jackson.core.JsonParseException
com.fasterxml.jackson.databind.JsonMappingException
-
-
-
-
-create
-public static GraphApiException create(byte[] message)
- throws IOException,
- com.fasterxml.jackson.core.JsonParseException,
- com.fasterxml.jackson.databind.JsonMappingException
-
-
-IOException
com.fasterxml.jackson.core.JsonParseException
com.fasterxml.jackson.databind.JsonMappingException
-
-
-
-
-create
-public static GraphApiException create(GraphApiException.FacebookErrorMessage error)
-
-
-
-
-
-getType
-public GraphApiException.Type getType()
-
-
-
-
-
-getCode
-public Integer getCode()
-
-
-
-
-
-getSubCode
-public Integer getSubCode()
-
-
-
-
-
-getUserTitle
-public String getUserTitle()
-
-
-
-
-
-getUserMessage
-public String getUserMessage()
-
-
-
-
-
-getTraceId
-public String getTraceId()
-
-
-toString
-public String toString()
-
-
-toString
in class org.springframework.security.oauth2.common.exceptions.OAuth2Exception
Class GraphMethodException
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-public abstract class GraphMethodException
-extends GraphApiException
-GraphMethodException
.
-
-
-
-
-
-
-Nested Class Summary
-
-
-Nested classes/interfaces inherited from class de.juplo.facebook.exceptions.GraphApiException
-GraphApiException.FacebookErrorMessage, GraphApiException.Type
-
-
-Field Summary
-
-
-Fields inherited from class org.springframework.security.oauth2.common.exceptions.OAuth2Exception
-ACCESS_DENIED, DESCRIPTION, ERROR, INSUFFICIENT_SCOPE, INVALID_CLIENT, INVALID_GRANT, INVALID_REQUEST, INVALID_SCOPE, INVALID_TOKEN, REDIRECT_URI_MISMATCH, UNAUTHORIZED_CLIENT, UNSUPPORTED_GRANT_TYPE, UNSUPPORTED_RESPONSE_TYPE, URI
-
-Method Summary
-
-
-Methods inherited from class de.juplo.facebook.exceptions.GraphApiException
-create, create, create, getCode, getSubCode, getTraceId, getType, getUserMessage, getUserTitle, toString
-
-Methods inherited from class org.springframework.security.oauth2.common.exceptions.OAuth2Exception
-addAdditionalInformation, create, getAdditionalInformation, getHttpErrorCode, getOAuth2ErrorCode, getSummary, valueOf
-
-
-Methods inherited from class java.lang.Throwable
-addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace
Class OAuthException
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-public class OAuthException
-extends GraphApiException
-OAuthException
.
-
-
-
-
-
-
-Nested Class Summary
-
-
-Nested classes/interfaces inherited from class de.juplo.facebook.exceptions.GraphApiException
-GraphApiException.FacebookErrorMessage, GraphApiException.Type
-
-
-Field Summary
-
-
-Fields inherited from class org.springframework.security.oauth2.common.exceptions.OAuth2Exception
-ACCESS_DENIED, DESCRIPTION, ERROR, INSUFFICIENT_SCOPE, INVALID_CLIENT, INVALID_GRANT, INVALID_REQUEST, INVALID_SCOPE, INVALID_TOKEN, REDIRECT_URI_MISMATCH, UNAUTHORIZED_CLIENT, UNSUPPORTED_GRANT_TYPE, UNSUPPORTED_RESPONSE_TYPE, URI
-
-
-Constructor Summary
-
-
-
-
-Modifier
-Constructor and Description
-
-
-
-protected
-OAuthException(GraphApiException.FacebookErrorMessage error)
-
-Method Summary
-
-
-Methods inherited from class de.juplo.facebook.exceptions.GraphApiException
-create, create, create, getCode, getSubCode, getTraceId, getType, getUserMessage, getUserTitle, toString
-
-Methods inherited from class org.springframework.security.oauth2.common.exceptions.OAuth2Exception
-addAdditionalInformation, create, getAdditionalInformation, getHttpErrorCode, getOAuth2ErrorCode, getSummary, valueOf
-
-
-Methods inherited from class java.lang.Throwable
-addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace
-
-
-
-Constructor Detail
-
-
-
-
-
-OAuthException
-protected OAuthException(GraphApiException.FacebookErrorMessage error)
-Class PageMigratedException
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-public class PageMigratedException
-extends OAuthException
-
-
-
-
-
-
-
-Nested Class Summary
-
-
-Nested classes/interfaces inherited from class de.juplo.facebook.exceptions.GraphApiException
-GraphApiException.FacebookErrorMessage, GraphApiException.Type
-
-
-Field Summary
-
-
-Fields inherited from class org.springframework.security.oauth2.common.exceptions.OAuth2Exception
-ACCESS_DENIED, DESCRIPTION, ERROR, INSUFFICIENT_SCOPE, INVALID_CLIENT, INVALID_GRANT, INVALID_REQUEST, INVALID_SCOPE, INVALID_TOKEN, REDIRECT_URI_MISMATCH, UNAUTHORIZED_CLIENT, UNSUPPORTED_GRANT_TYPE, UNSUPPORTED_RESPONSE_TYPE, URI
-
-
-Constructor Summary
-
-
-
-
-Modifier
-Constructor and Description
-
-
-
-protected
-PageMigratedException(GraphApiException.FacebookErrorMessage error)
-
-Method Summary
-
-
-
-
-Modifier and Type
-Method and Description
-
-
-
-Long
-getNewId()
-
-
-Long
-getOldId()
-
-Methods inherited from class de.juplo.facebook.exceptions.GraphApiException
-create, create, create, getCode, getSubCode, getTraceId, getType, getUserMessage, getUserTitle, toString
-
-Methods inherited from class org.springframework.security.oauth2.common.exceptions.OAuth2Exception
-addAdditionalInformation, create, getAdditionalInformation, getHttpErrorCode, getOAuth2ErrorCode, getSummary, valueOf
-
-
-Methods inherited from class java.lang.Throwable
-addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace
Class RateExceededException
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-public class RateExceededException
-extends OAuthException
-
-
-
-
-
-
-
-Nested Class Summary
-
-
-Nested classes/interfaces inherited from class de.juplo.facebook.exceptions.GraphApiException
-GraphApiException.FacebookErrorMessage, GraphApiException.Type
-
-
-Field Summary
-
-
-Fields inherited from class org.springframework.security.oauth2.common.exceptions.OAuth2Exception
-ACCESS_DENIED, DESCRIPTION, ERROR, INSUFFICIENT_SCOPE, INVALID_CLIENT, INVALID_GRANT, INVALID_REQUEST, INVALID_SCOPE, INVALID_TOKEN, REDIRECT_URI_MISMATCH, UNAUTHORIZED_CLIENT, UNSUPPORTED_GRANT_TYPE, UNSUPPORTED_RESPONSE_TYPE, URI
-
-
-Constructor Summary
-
-
-
-
-Modifier
-Constructor and Description
-
-
-
-protected
-RateExceededException(GraphApiException.FacebookErrorMessage error)
-
-Method Summary
-
-
-Methods inherited from class de.juplo.facebook.exceptions.GraphApiException
-create, create, create, getCode, getSubCode, getTraceId, getType, getUserMessage, getUserTitle, toString
-
-Methods inherited from class org.springframework.security.oauth2.common.exceptions.OAuth2Exception
-addAdditionalInformation, create, getAdditionalInformation, getHttpErrorCode, getOAuth2ErrorCode, getSummary, valueOf
-
-
-Methods inherited from class java.lang.Throwable
-addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace
-
-
-
-Constructor Detail
-
-
-
-
-
-RateExceededException
-protected RateExceededException(GraphApiException.FacebookErrorMessage error)
-Class UnexpectedErrorException
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-public class UnexpectedErrorException
-extends OAuthException
-
-
-
-
-
-
-
-Nested Class Summary
-
-
-Nested classes/interfaces inherited from class de.juplo.facebook.exceptions.GraphApiException
-GraphApiException.FacebookErrorMessage, GraphApiException.Type
-
-
-Field Summary
-
-
-Fields inherited from class org.springframework.security.oauth2.common.exceptions.OAuth2Exception
-ACCESS_DENIED, DESCRIPTION, ERROR, INSUFFICIENT_SCOPE, INVALID_CLIENT, INVALID_GRANT, INVALID_REQUEST, INVALID_SCOPE, INVALID_TOKEN, REDIRECT_URI_MISMATCH, UNAUTHORIZED_CLIENT, UNSUPPORTED_GRANT_TYPE, UNSUPPORTED_RESPONSE_TYPE, URI
-
-
-Constructor Summary
-
-
-
-
-Modifier
-Constructor and Description
-
-
-
-protected
-UnexpectedErrorException(GraphApiException.FacebookErrorMessage error)
-
-Method Summary
-
-
-Methods inherited from class de.juplo.facebook.exceptions.GraphApiException
-create, create, create, getCode, getSubCode, getTraceId, getType, getUserMessage, getUserTitle, toString
-
-Methods inherited from class org.springframework.security.oauth2.common.exceptions.OAuth2Exception
-addAdditionalInformation, create, getAdditionalInformation, getHttpErrorCode, getOAuth2ErrorCode, getSummary, valueOf
-
-
-Methods inherited from class java.lang.Throwable
-addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace
-
-
-
-Constructor Detail
-
-
-
-
-
-UnexpectedErrorException
-protected UnexpectedErrorException(GraphApiException.FacebookErrorMessage error)
-Class UnknownErrorException
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-public class UnknownErrorException
-extends OAuthException
-
-
-
-
-
-
-
-Nested Class Summary
-
-
-Nested classes/interfaces inherited from class de.juplo.facebook.exceptions.GraphApiException
-GraphApiException.FacebookErrorMessage, GraphApiException.Type
-
-
-Field Summary
-
-
-Fields inherited from class org.springframework.security.oauth2.common.exceptions.OAuth2Exception
-ACCESS_DENIED, DESCRIPTION, ERROR, INSUFFICIENT_SCOPE, INVALID_CLIENT, INVALID_GRANT, INVALID_REQUEST, INVALID_SCOPE, INVALID_TOKEN, REDIRECT_URI_MISMATCH, UNAUTHORIZED_CLIENT, UNSUPPORTED_GRANT_TYPE, UNSUPPORTED_RESPONSE_TYPE, URI
-
-
-Constructor Summary
-
-
-
-
-Modifier
-Constructor and Description
-
-
-
-protected
-UnknownErrorException(GraphApiException.FacebookErrorMessage error)
-
-Method Summary
-
-
-Methods inherited from class de.juplo.facebook.exceptions.GraphApiException
-create, create, create, getCode, getSubCode, getTraceId, getType, getUserMessage, getUserTitle, toString
-
-Methods inherited from class org.springframework.security.oauth2.common.exceptions.OAuth2Exception
-addAdditionalInformation, create, getAdditionalInformation, getHttpErrorCode, getOAuth2ErrorCode, getSummary, valueOf
-
-
-Methods inherited from class java.lang.Throwable
-addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace
-
-
-
-Constructor Detail
-
-
-
-
-
-UnknownErrorException
-protected UnknownErrorException(GraphApiException.FacebookErrorMessage error)
-Class UnmappedErrorException
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-public class UnmappedErrorException
-extends GraphApiException
-
-
-
-
-
-
-
-Nested Class Summary
-
-
-Nested classes/interfaces inherited from class de.juplo.facebook.exceptions.GraphApiException
-GraphApiException.FacebookErrorMessage, GraphApiException.Type
-
-
-Field Summary
-
-
-Fields inherited from class org.springframework.security.oauth2.common.exceptions.OAuth2Exception
-ACCESS_DENIED, DESCRIPTION, ERROR, INSUFFICIENT_SCOPE, INVALID_CLIENT, INVALID_GRANT, INVALID_REQUEST, INVALID_SCOPE, INVALID_TOKEN, REDIRECT_URI_MISMATCH, UNAUTHORIZED_CLIENT, UNSUPPORTED_GRANT_TYPE, UNSUPPORTED_RESPONSE_TYPE, URI
-
-
-Constructor Summary
-
-
-
-
-Modifier
-Constructor and Description
-
-
-
-protected
-UnmappedErrorException(GraphApiException.FacebookErrorMessage error)
-
-Method Summary
-
-
-Methods inherited from class de.juplo.facebook.exceptions.GraphApiException
-create, create, create, getCode, getSubCode, getTraceId, getType, getUserMessage, getUserTitle, toString
-
-Methods inherited from class org.springframework.security.oauth2.common.exceptions.OAuth2Exception
-addAdditionalInformation, create, getAdditionalInformation, getHttpErrorCode, getOAuth2ErrorCode, getSummary, valueOf
-
-
-Methods inherited from class java.lang.Throwable
-addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace
-
-
-
-Constructor Detail
-
-
-
-
-
-UnmappedErrorException
-protected UnmappedErrorException(GraphApiException.FacebookErrorMessage error)
-Class UnsupportedGetRequestException
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-public class UnsupportedGetRequestException
-extends GraphMethodException
-
-
-
-
-
-
-
-Nested Class Summary
-
-
-Nested classes/interfaces inherited from class de.juplo.facebook.exceptions.GraphApiException
-GraphApiException.FacebookErrorMessage, GraphApiException.Type
-
-
-Field Summary
-
-
-Fields inherited from class org.springframework.security.oauth2.common.exceptions.OAuth2Exception
-ACCESS_DENIED, DESCRIPTION, ERROR, INSUFFICIENT_SCOPE, INVALID_CLIENT, INVALID_GRANT, INVALID_REQUEST, INVALID_SCOPE, INVALID_TOKEN, REDIRECT_URI_MISMATCH, UNAUTHORIZED_CLIENT, UNSUPPORTED_GRANT_TYPE, UNSUPPORTED_RESPONSE_TYPE, URI
-
-
-Constructor Summary
-
-
-
-
-Modifier
-Constructor and Description
-
-
-
-protected
-UnsupportedGetRequestException(GraphApiException.FacebookErrorMessage error)
-
-Method Summary
-
-
-Methods inherited from class de.juplo.facebook.exceptions.GraphApiException
-create, create, create, getCode, getSubCode, getTraceId, getType, getUserMessage, getUserTitle, toString
-
-Methods inherited from class org.springframework.security.oauth2.common.exceptions.OAuth2Exception
-addAdditionalInformation, create, getAdditionalInformation, getHttpErrorCode, getOAuth2ErrorCode, getSummary, valueOf
-
-
-Methods inherited from class java.lang.Throwable
-addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace
-
-
-
-Constructor Detail
-
-
-
-
-
-UnsupportedGetRequestException
-protected UnsupportedGetRequestException(GraphApiException.FacebookErrorMessage error)
-Uses of Class
-
de.juplo.facebook.exceptions.AccessTokenRequiredExceptionUses of Class
-
de.juplo.facebook.exceptions.CallbackVerificationFailedExceptionUses of Class
-
de.juplo.facebook.exceptions.GraphApiException.FacebookErrorMessage
-
-
-
-
-
-
-Package
-Description
-
-
-
-de.juplo.facebook.exceptions
-
-
-
-Uses of GraphApiException.FacebookErrorMessage in de.juplo.facebook.exceptions
-
-
-
-
-
-Modifier and Type
-Method and Description
-
-
-
-
-static GraphApiException
GraphApiException.
-create(GraphApiException.FacebookErrorMessage error)
-
-
-
-
-Constructor and Description
-
-
-
-AccessTokenRequiredException(GraphApiException.FacebookErrorMessage error)
-
-
-CallbackVerificationFailedException(GraphApiException.FacebookErrorMessage error)
-
-
-GraphApiException(GraphApiException.FacebookErrorMessage error)
-
-
-OAuthException(GraphApiException.FacebookErrorMessage error)
-
-
-PageMigratedException(GraphApiException.FacebookErrorMessage error)
-
-
-RateExceededException(GraphApiException.FacebookErrorMessage error)
-
-
-UnexpectedErrorException(GraphApiException.FacebookErrorMessage error)
-
-
-UnknownErrorException(GraphApiException.FacebookErrorMessage error)
-
-
-UnmappedErrorException(GraphApiException.FacebookErrorMessage error)
-
-
-
-UnsupportedGetRequestException(GraphApiException.FacebookErrorMessage error)
Uses of Class
-
de.juplo.facebook.exceptions.GraphApiException.Type
-
-
-
-
-
-
-Package
-Description
-
-
-
-de.juplo.facebook.exceptions
-
-
-
-Uses of GraphApiException.Type in de.juplo.facebook.exceptions
-
-
-
-
-
-Modifier and Type
-Method and Description
-
-
-
-GraphApiException.Type
GraphApiException.
-getType()
-
-
-static GraphApiException.Type
GraphApiException.Type.
-valueOf(String name)
-
-
-
-
-static GraphApiException.Type[]
GraphApiException.Type.
-values()
-Uses of Class
-
de.juplo.facebook.exceptions.GraphApiException
-
-
-
-
-
-
-Package
-Description
-
-
-
-de.juplo.facebook.exceptions
-
-
-
-Uses of GraphApiException in de.juplo.facebook.exceptions
-
-
-
-
-
-Modifier and Type
-Class and Description
-
-
-
-class
-AccessTokenRequiredException
-
-
-
-class
-CallbackVerificationFailedException
-
-
-
-class
-GraphMethodException
-GraphMethodException
.
-
-
-class
-OAuthException
-OAuthException
.
-
-
-class
-PageMigratedException
-
-
-
-class
-RateExceededException
-
-
-
-class
-UnexpectedErrorException
-
-
-
-class
-UnknownErrorException
-
-
-
-class
-UnmappedErrorException
-
-
-
-
-class
-UnsupportedGetRequestException
-
-
-
-
-
-Modifier and Type
-Method and Description
-
-
-
-static GraphApiException
GraphApiException.
-create(byte[] message)
-
-
-static GraphApiException
GraphApiException.
-create(GraphApiException.FacebookErrorMessage error)
-
-
-
-static GraphApiException
GraphApiException.
-create(InputStream in)
Uses of Class
-
de.juplo.facebook.exceptions.GraphMethodException
-
-
-
-
-
-
-Package
-Description
-
-
-
-de.juplo.facebook.exceptions
-
-
-
-Uses of GraphMethodException in de.juplo.facebook.exceptions
-
-
-
-
-
-Modifier and Type
-Class and Description
-
-
-
-
-class
-UnsupportedGetRequestException
-Uses of Class
-
de.juplo.facebook.exceptions.OAuthException
-
-
-
-
-
-
-Package
-Description
-
-
-
-de.juplo.facebook.exceptions
-
-
-
-Uses of OAuthException in de.juplo.facebook.exceptions
-
-
-
-
-
-Modifier and Type
-Class and Description
-
-
-
-class
-AccessTokenRequiredException
-
-
-
-class
-CallbackVerificationFailedException
-
-
-
-class
-PageMigratedException
-
-
-
-class
-RateExceededException
-
-
-
-class
-UnexpectedErrorException
-
-
-
-
-class
-UnknownErrorException
-Uses of Class
-
de.juplo.facebook.exceptions.PageMigratedExceptionUses of Class
-
de.juplo.facebook.exceptions.RateExceededExceptionUses of Class
-
de.juplo.facebook.exceptions.UnexpectedErrorExceptionUses of Class
-
de.juplo.facebook.exceptions.UnknownErrorExceptionUses of Class
-
de.juplo.facebook.exceptions.UnmappedErrorExceptionUses of Class
-
de.juplo.facebook.exceptions.UnsupportedGetRequestExceptionde.juplo.facebook.exceptions
-Classes
-
-Enums
-
-Exceptions
-
-Package de.juplo.facebook.exceptions
-
-
-
-
-
-
-
-Class
-Description
-
-
-
-GraphApiException.FacebookErrorMessage
-
-
-
-
-
-
-
-Enum
-Description
-
-
-
-GraphApiException.Type
-
-
-
-
-
-
-Exception
-Description
-
-
-AccessTokenRequiredException
-
-
-
-
-CallbackVerificationFailedException
-
-
-
-
-GraphApiException
-
-
-
-
-GraphMethodException
-
-
-GraphMethodException
.
-
-OAuthException
-
-
-OAuthException
.
-
-PageMigratedException
-
-
-
-
-RateExceededException
-
-
-
-
-UnexpectedErrorException
-
-
-
-
-UnknownErrorException
-
-
-
-
-UnmappedErrorException
-
-
-
-
-
-UnsupportedGetRequestException
-
-
-Class Hierarchy
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-Enum Hierarchy
-
-
-
-
-
-
-Uses of Package
-
de.juplo.facebook.exceptions
-
-
-
-
-
-
-Package
-Description
-
-
-
-de.juplo.facebook.exceptions
-
-
-
-
-
-
-Class and Description
-
-
-GraphApiException
-
-
-
-GraphApiException.FacebookErrorMessage
-
-
-
-GraphApiException.Type
-
-
-GraphMethodException
-
-GraphMethodException
.
-
-
-OAuthException
-
-OAuthException
.de.juplo.facebook
-Classes
-
-Package de.juplo.facebook
-
-
-
-
-
-
-
-Class
-Description
-
-
-
-FacebookUtils
-
-
-Class Hierarchy
-
-
-
-
-Uses of Package
-
de.juplo.facebookClass SignedRequestAwareAuthorizationCodeAccessTokenProvider
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-public class SignedRequestAwareAuthorizationCodeAccessTokenProvider
-extends org.springframework.security.oauth2.client.token.grant.code.AuthorizationCodeAccessTokenProvider
-AuthorizationCodeAccessTokenProvider
and adds
- support for signed requests, which are issued by Facebook, if the Canvas-
- or Tab-Page of a Facebook-App is accessed for the first time.
-
-
-
-
-
-
-Field Summary
-
-
-
-
-Modifier and Type
-Field and Description
-
-
-
-static String
-PARAM_SIGNED_REQUEST
-
-Fields inherited from class org.springframework.security.oauth2.client.token.OAuth2AccessTokenSupport
-logger
-
-
-Constructor Summary
-
-
-
-
-Constructor and Description
-
-
-
-SignedRequestAwareAuthorizationCodeAccessTokenProvider()
-
-Method Summary
-
-
-
-
-Modifier and Type
-Method and Description
-
-
-
-org.codehaus.jackson.map.ObjectMapper
-getObjectMapper()
-
-
-String
-getSecret()
-
-
-org.springframework.security.oauth2.common.OAuth2AccessToken
-obtainAccessToken(org.springframework.security.oauth2.client.resource.OAuth2ProtectedResourceDetails details,
- org.springframework.security.oauth2.client.token.AccessTokenRequest parameters)
-
-
-void
-setObjectMapper(org.codehaus.jackson.map.ObjectMapper objectMapper)
-
-
-void
-setSecret(String secret)
-
-Methods inherited from class org.springframework.security.oauth2.client.token.grant.code.AuthorizationCodeAccessTokenProvider
-getAuthorizationResponseExtractor, getUserApprovalSignal, obtainAuthorizationCode, refreshAccessToken, setAuthorizationRequestEnhancer, setScopePrefix, setStateKeyGenerator, setStateMandatory, supportsRefresh, supportsResource
-
-
-Methods inherited from class org.springframework.security.oauth2.client.token.OAuth2AccessTokenSupport
-getAccessTokenUri, getHttpMethod, getRequestCallback, getResponseErrorHandler, getResponseExtractor, getRestTemplate, retrieveToken, setAuthenticationHandler, setInterceptors, setMessageConverters, setRequestFactory, setTokenRequestEnhancer
-
-
-
-
-Field Detail
-
-
-
-
-
-PARAM_SIGNED_REQUEST
-public static final String PARAM_SIGNED_REQUEST
-
-
-
-
-
-Constructor Detail
-
-
-
-
-
-SignedRequestAwareAuthorizationCodeAccessTokenProvider
-public SignedRequestAwareAuthorizationCodeAccessTokenProvider()
-
-
-Method Detail
-
-
-
-
-
-
-
-
-obtainAccessToken
-public org.springframework.security.oauth2.common.OAuth2AccessToken obtainAccessToken(org.springframework.security.oauth2.client.resource.OAuth2ProtectedResourceDetails details,
- org.springframework.security.oauth2.client.token.AccessTokenRequest parameters)
-
-
-obtainAccessToken
in interface org.springframework.security.oauth2.client.token.AccessTokenProvider
obtainAccessToken
in class org.springframework.security.oauth2.client.token.grant.code.AuthorizationCodeAccessTokenProvider
-
-
-
-
-getSecret
-public String getSecret()
-
-
-
-
-
-setSecret
-public void setSecret(String secret)
-
-
-
-
-
-getObjectMapper
-public org.codehaus.jackson.map.ObjectMapper getObjectMapper()
-
-
-setObjectMapper
-public void setObjectMapper(org.codehaus.jackson.map.ObjectMapper objectMapper)
-Uses of Class
-
de.juplo.facebook.token.SignedRequestAwareAuthorizationCodeAccessTokenProviderde.juplo.facebook.token
-Classes
-
-Package de.juplo.facebook.token
-
-
-
-
-
-
-
-Class
-Description
-
-
-
-SignedRequestAwareAuthorizationCodeAccessTokenProvider
-
-
-AuthorizationCodeAccessTokenProvider
and adds
- support for signed requests, which are issued by Facebook, if the Canvas-
- or Tab-Page of a Facebook-App is accessed for the first time.Class Hierarchy
-
-
-
-
-
-
-
-
-Uses of Package
-
de.juplo.facebook.tokenDeprecated API
-Contents
-How This API Document Is Organized
-
-
-This help file applies to API documentation generated using the standard doclet.Overview
-Package
-
-
-Class/Interface
-
-
-
-
-
-
-Annotation Type
-
-
-Enum
-
-
-Use
-Tree (Class Hierarchy)
-java.lang.Object
. The interfaces do not inherit from java.lang.Object
.
-
-Deprecated API
-Index
-Prev/Next
-Frames/No Frames
-All Classes
-Serialized Form
-Constant Field Values
-A
-
-
-
-
-
-C
-
-
-
-
-
-D
-
-
-
-
-
-F
-
-
-
-
-
-G
-
-
-
-
-
-GraphMethodException
.H
-
-
-
-
-
-I
-
-
-
-
-
-O
-
-
-
-
-
-OAuthException
.P
-
-
-
-
-
-R
-
-
-
-
-
-S
-
-
-
-
-
-AuthorizationCodeAccessTokenProvider
and adds
- support for signed requests, which are issued by Facebook, if the Canvas-
- or Tab-Page of a Facebook-App is accessed for the first time.T
-
-
-
-
-
-U
-
-
-
-
-
-V
-
-
-A C D F G H I O P R S T U V Packages
-
-Juplo - Facebook Utils 2.5.0 API
-
-
-
-
-
-Package
-Description
-
-
-de.juplo.facebook
-
-
-
-de.juplo.facebook.aspects
-
-
-
-de.juplo.facebook.client
-
-
-
-de.juplo.facebook.exceptions
-
-
-
-
-de.juplo.facebook.token
-
-Hierarchy For All Packages
-Package Hierarchies:
-
-Class Hierarchy
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-Annotation Type Hierarchy
-
-
-Enum Hierarchy
-
-
-
-
-
-
-Serialized Form
-
-
-Package de.juplo.facebook.exceptions
-
-
-Class de.juplo.facebook.exceptions.AccessTokenRequiredException extends OAuthException implements Serializable
-Class de.juplo.facebook.exceptions.CallbackVerificationFailedException extends OAuthException implements Serializable
-Class de.juplo.facebook.exceptions.GraphApiException extends org.springframework.security.oauth2.common.exceptions.OAuth2Exception implements Serializable
-
-
-Serialized Fields
-
-
-error
-GraphApiException.FacebookErrorMessage error
-Class de.juplo.facebook.exceptions.GraphMethodException extends GraphApiException implements Serializable
-Class de.juplo.facebook.exceptions.OAuthException extends GraphApiException implements Serializable
-Class de.juplo.facebook.exceptions.PageMigratedException extends OAuthException implements Serializable
-
-Class de.juplo.facebook.exceptions.RateExceededException extends OAuthException implements Serializable
-Class de.juplo.facebook.exceptions.UnexpectedErrorException extends OAuthException implements Serializable
-Class de.juplo.facebook.exceptions.UnknownErrorException extends OAuthException implements Serializable
-Class de.juplo.facebook.exceptions.UnmappedErrorException extends GraphApiException implements Serializable
-Class de.juplo.facebook.exceptions.UnsupportedGetRequestException extends GraphMethodException implements Serializable
-juplo
- Java bits from nerds for nerds
-
- $shortTitle
Configuration through a hibernate.properties-File
-
-<plugin>
- <groupId>de.juplo</groupId>
- <artifactId>hibernate-maven-plugin</artifactId>
- <version>${project.version}</version>
- <executions>
- <execution>
- <goals>
- <goal>export</goal>
- </goals>
- </execution>
- </executions>
-</plugin>
-<plugin>
- <groupId>de.juplo</groupId>
- <artifactId>hibernate-maven-plugin</artifactId>
- <version>${project.version}</version>
- <executions>
- <execution>
- <goals>
- <goal>export</goal>
- </goals>
- </execution>
- </executions>
- <configuration>
- <url><![CDATA[jdbc:mysql://localhost/test-db]]></url>
- </configuration>
-</plugin>
Configuration through maven-properties
-
-
-
-<properties>
- <hibernate.connection.driver_class>org.hsqldb.jdbcDriver</hibernate.connection.driver_class>
- <hibernate.dialect>org.hibernate.dialect.HSQLDialect</hibernate.dialect>
- <hibernate.connection.url><![CDATA[jdbc:hsqldb:res:org.my.path.production_db]]></hibernate.connection.url>
- <hibernate.connection.username>sa</hibernate.connection.username>
- <hibernate.connection.password></hibernate.connection.password>
-</properties>
-
-...
-
-<plugins>
-
- ...
-
- <plugin>
- <groupId>de.juplo</groupId>
- <artifactId>hibernate-maven-plugin</artifactId>
- <version>${project.version}</version>
- <executions>
- <execution>
- <goals>
- <goal>export</goal>
- </goals>
- </execution>
- </executions>
- <configuration>
- <url><![CDATA[jdbc:hsqldb:target/db/testdb;shutdown=true]]></url>
- </configuration>
- </plugin>
-
-<plugins>
Configuration through the plugin-configuration
-
-
-
-<plugin>
- <groupId>de.juplo</groupId>
- <artifactId>hibernate-maven-plugin</artifactId>
- <version>${project.version}</version>
- <executions>
- <execution>
- <goals>
- <goal>export</goal>
- </goals>
- </execution>
- </executions>
- <configuration>
- <driver>org.hsqldb.jdbcDriver</driver>
- <dialect>org.hibernate.dialect.HSQLDialect</dialect>
- <url><![CDATA[jdbc:hsqldb:target/db/fotos;shutdown=true]]></url>
- <username>sa</username>
- <password></password>
- </configuration>
-</plugin>
Configuration-Method-Precedence
-
-
-
-<plugin>
- <groupId>de.juplo</groupId>
- <artifactId>hibernate-maven-plugin</artifactId>
- <version>${project.version}</version>
- <executions>
- <execution>
- <goals>
- <goal>export</goal>
- </goals>
- </execution>
- </executions>
- <configuration>
- <password>${my-password-property}</password>
- </configuration>
-</plugin>
juplo
- Java bits from nerds for nerds
-
- $shortTitle
-mvn -X compile hibernate:export
juplo
- Java bits from nerds for nerds
-
- Dependencies
Project Dependencies
compile
GroupId ArtifactId Version Type License com.fasterxml.jackson.core jackson-core 2.6.2 jar The Apache Software License, Version 2.0 com.fasterxml.jackson.core jackson-databind 2.6.2 jar The Apache Software License, Version 2.0 commons-codec commons-codec 1.7 jar The Apache Software License, Version 2.0 org.slf4j slf4j-api 1.7.12 jar MIT License org.springframework.security spring-security-core 4.0.2.RELEASE jar The Apache Software License, Version 2.0 org.springframework.security.oauth spring-security-oauth2 2.0.8.RELEASE jar Apache 2.0 test
GroupId ArtifactId Version Type License ch.qos.logback logback-classic 1.1.3 jar Eclipse Public License - v 1.0-GNU Lesser General Public License junit junit 4.12 jar Eclipse Public License 1.0 org.slf4j jcl-over-slf4j 1.7.12 jar MIT License org.springframework spring-test 4.2.1.RELEASE jar The Apache Software License, Version 2.0 provided
GroupId ArtifactId Version Type License javax.servlet javax.servlet-api 3.0.1 jar CDDL + GPLv2 with classpath exception org.aspectj aspectjrt 1.8.5 jar Eclipse Public License - v 1.0 org.springframework spring-webmvc 4.2.1.RELEASE jar The Apache Software License, Version 2.0 Project Transitive Dependencies
compile
GroupId ArtifactId Version Type License aopalliance aopalliance 1.0 jar Public Domain com.fasterxml.jackson.core jackson-annotations 2.6.0 jar The Apache Software License, Version 2.0 org.codehaus.jackson jackson-core-asl 1.9.13 jar The Apache Software License, Version 2.0 org.codehaus.jackson jackson-mapper-asl 1.9.13 jar The Apache Software License, Version 2.0 test
GroupId ArtifactId Version Type License ch.qos.logback logback-core 1.1.3 jar Eclipse Public License - v 1.0-GNU Lesser General Public License org.hamcrest hamcrest-core 1.3 jar New BSD License provided
GroupId ArtifactId Version Type License org.springframework spring-aop 4.2.1.RELEASE jar The Apache Software License, Version 2.0 org.springframework spring-beans 4.2.1.RELEASE jar The Apache Software License, Version 2.0 org.springframework spring-context 4.2.1.RELEASE jar The Apache Software License, Version 2.0 org.springframework spring-core 4.2.1.RELEASE jar The Apache Software License, Version 2.0 org.springframework spring-expression 4.2.1.RELEASE jar The Apache Software License, Version 2.0 org.springframework spring-web 4.2.1.RELEASE jar The Apache Software License, Version 2.0 Project Dependency Graph
-Dependency Tree
Licenses
Dependency File Details
Filename Size Entries Classes Packages JDK Rev Debug aopalliance-1.0.jar 4.36 kB 15 9 2 1.3 debug logback-classic-1.1.3.jar 274.34 kB 221 173 25 1.6 debug logback-core-1.1.3.jar 444.38 kB 410 365 35 1.6 debug jackson-annotations-2.6.0.jar 45.87 kB 70 58 1 1.6 debug jackson-core-2.6.2.jar 252.76 kB 116 93 9 1.6 debug jackson-databind-2.6.2.jar 1.11 MB 597 563 20 1.6 debug commons-codec-1.7.jar 253.52 kB 227 85 6 1.6 debug javax.servlet-api-3.0.1.jar 83.35 kB 94 74 4 1.5 debug junit-4.12.jar 307.55 kB 323 286 30 1.5 debug aspectjrt-1.8.5.jar 114.77 kB 148 130 11 1.5 debug jackson-core-asl-1.9.13.jar 226.80 kB 137 121 8 1.5 debug jackson-mapper-asl-1.9.13.jar 762.37 kB 529 502 18 1.5 debug hamcrest-core-1.3.jar 43.97 kB 52 45 3 1.5 debug jcl-over-slf4j-1.7.12.jar 16.23 kB 23 9 2 1.5 debug slf4j-api-1.7.12.jar 31.37 kB 39 28 3 1.5 debug spring-aop-4.2.1.RELEASE.jar 357.91 kB 291 258 15 1.6 debug spring-beans-4.2.1.RELEASE.jar 712.53 kB 448 396 15 1.6 debug spring-context-4.2.1.RELEASE.jar 1.03 MB 863 746 66 1.6 debug spring-core-4.2.1.RELEASE.jar 1.02 MB 797 751 40 1.6 debug spring-expression-4.2.1.RELEASE.jar 256.23 kB 155 141 6 1.6 debug spring-test-4.2.1.RELEASE.jar 548.17 kB 451 412 30 1.6 debug spring-web-4.2.1.RELEASE.jar 750.50 kB 577 529 36 1.6 debug spring-webmvc-4.2.1.RELEASE.jar 846.65 kB 528 476 30 1.6 debug spring-security-core-4.0.2.RELEASE.jar 349.60 kB 362 297 44 1.5 debug spring-security-oauth2-2.0.8.RELEASE.jar 440.03 kB 363 303 40 1.6 debug Total Size Entries Classes Packages JDK Rev Debug 25 10.12 MB 7,836 6,850 499 1.6 25 compile: 10 compile: 3.42 MB compile: 2,455 compile: 2,059 compile: 151 - compile: 10 test: 6 test: 1.60 MB test: 1,480 test: 1,290 test: 125 - test: 6 provided: 9 provided: 5.10 MB provided: 3,901 provided: 3,501 provided: 223 - provided: 9 Dependency Repository Locations
Repo ID URL Release Snapshot Blacklisted central http://repo.maven.apache.org/maven2 Yes - - sonatype-nexus-snapshots https://oss.sonatype.org/content/repositories/snapshots - Yes - glassfish-repository http://download.java.net/maven/glassfish Yes Yes Yes jvnet-nexus-snapshots https://maven.java.net/content/repositories/snapshots - Yes - apache.snapshots http://repository.apache.org/snapshots - Yes - juplo
- Java bits from nerds for nerds
-
- Dependency Information
juplo
- Java bits from nerds for nerds
-
- Distribution Management
Overview
Snapshot Repository - sonatype-nexus-snapshots
https://oss.sonatype.org/content/repositories/snapshots/juplo
- Java bits from nerds for nerds
-
- $shortTitle
-<plugin>
- <groupId>de.juplo</groupId>
- <artifactId>hibernate-maven-plugin</artifactId>
- <version>${project.version}</version>
- <configuration>
- <force>true</force>
- </configuration>
-</plugin>
juplo
- Java bits from nerds for nerds
-
- $shortTitle
Hibernate 4 Maven Plugin
- A simple Plugin for generating a Database-Schema from Hibernate 4 Mapping-Annotations
-
-
- Documentation
-
-
- juplo
- Java bits from nerds for nerds
-
- Continuous Integration
juplo
- Java bits from nerds for nerds
-
- Issue Tracking
juplo
- Java bits from nerds for nerds
-
- Project License
Overview
Project License
The Apache Software License, Version 2.0
- Apache License
- Version 2.0, January 2004
- http://www.apache.org/licenses/
-
- TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
-
- 1. Definitions.
-
- "License" shall mean the terms and conditions for use, reproduction,
- and distribution as defined by Sections 1 through 9 of this document.
-
- "Licensor" shall mean the copyright owner or entity authorized by
- the copyright owner that is granting the License.
-
- "Legal Entity" shall mean the union of the acting entity and all
- other entities that control, are controlled by, or are under common
- control with that entity. For the purposes of this definition,
- "control" means (i) the power, direct or indirect, to cause the
- direction or management of such entity, whether by contract or
- otherwise, or (ii) ownership of fifty percent (50%) or more of the
- outstanding shares, or (iii) beneficial ownership of such entity.
-
- "You" (or "Your") shall mean an individual or Legal Entity
- exercising permissions granted by this License.
-
- "Source" form shall mean the preferred form for making modifications,
- including but not limited to software source code, documentation
- source, and configuration files.
-
- "Object" form shall mean any form resulting from mechanical
- transformation or translation of a Source form, including but
- not limited to compiled object code, generated documentation,
- and conversions to other media types.
-
- "Work" shall mean the work of authorship, whether in Source or
- Object form, made available under the License, as indicated by a
- copyright notice that is included in or attached to the work
- (an example is provided in the Appendix below).
-
- "Derivative Works" shall mean any work, whether in Source or Object
- form, that is based on (or derived from) the Work and for which the
- editorial revisions, annotations, elaborations, or other modifications
- represent, as a whole, an original work of authorship. For the purposes
- of this License, Derivative Works shall not include works that remain
- separable from, or merely link (or bind by name) to the interfaces of,
- the Work and Derivative Works thereof.
-
- "Contribution" shall mean any work of authorship, including
- the original version of the Work and any modifications or additions
- to that Work or Derivative Works thereof, that is intentionally
- submitted to Licensor for inclusion in the Work by the copyright owner
- or by an individual or Legal Entity authorized to submit on behalf of
- the copyright owner. For the purposes of this definition, "submitted"
- means any form of electronic, verbal, or written communication sent
- to the Licensor or its representatives, including but not limited to
- communication on electronic mailing lists, source code control systems,
- and issue tracking systems that are managed by, or on behalf of, the
- Licensor for the purpose of discussing and improving the Work, but
- excluding communication that is conspicuously marked or otherwise
- designated in writing by the copyright owner as "Not a Contribution."
-
- "Contributor" shall mean Licensor and any individual or Legal Entity
- on behalf of whom a Contribution has been received by Licensor and
- subsequently incorporated within the Work.
-
- 2. Grant of Copyright License. Subject to the terms and conditions of
- this License, each Contributor hereby grants to You a perpetual,
- worldwide, non-exclusive, no-charge, royalty-free, irrevocable
- copyright license to reproduce, prepare Derivative Works of,
- publicly display, publicly perform, sublicense, and distribute the
- Work and such Derivative Works in Source or Object form.
-
- 3. Grant of Patent License. Subject to the terms and conditions of
- this License, each Contributor hereby grants to You a perpetual,
- worldwide, non-exclusive, no-charge, royalty-free, irrevocable
- (except as stated in this section) patent license to make, have made,
- use, offer to sell, sell, import, and otherwise transfer the Work,
- where such license applies only to those patent claims licensable
- by such Contributor that are necessarily infringed by their
- Contribution(s) alone or by combination of their Contribution(s)
- with the Work to which such Contribution(s) was submitted. If You
- institute patent litigation against any entity (including a
- cross-claim or counterclaim in a lawsuit) alleging that the Work
- or a Contribution incorporated within the Work constitutes direct
- or contributory patent infringement, then any patent licenses
- granted to You under this License for that Work shall terminate
- as of the date such litigation is filed.
-
- 4. Redistribution. You may reproduce and distribute copies of the
- Work or Derivative Works thereof in any medium, with or without
- modifications, and in Source or Object form, provided that You
- meet the following conditions:
-
- (a) You must give any other recipients of the Work or
- Derivative Works a copy of this License; and
-
- (b) You must cause any modified files to carry prominent notices
- stating that You changed the files; and
-
- (c) You must retain, in the Source form of any Derivative Works
- that You distribute, all copyright, patent, trademark, and
- attribution notices from the Source form of the Work,
- excluding those notices that do not pertain to any part of
- the Derivative Works; and
-
- (d) If the Work includes a "NOTICE" text file as part of its
- distribution, then any Derivative Works that You distribute must
- include a readable copy of the attribution notices contained
- within such NOTICE file, excluding those notices that do not
- pertain to any part of the Derivative Works, in at least one
- of the following places: within a NOTICE text file distributed
- as part of the Derivative Works; within the Source form or
- documentation, if provided along with the Derivative Works; or,
- within a display generated by the Derivative Works, if and
- wherever such third-party notices normally appear. The contents
- of the NOTICE file are for informational purposes only and
- do not modify the License. You may add Your own attribution
- notices within Derivative Works that You distribute, alongside
- or as an addendum to the NOTICE text from the Work, provided
- that such additional attribution notices cannot be construed
- as modifying the License.
-
- You may add Your own copyright statement to Your modifications and
- may provide additional or different license terms and conditions
- for use, reproduction, or distribution of Your modifications, or
- for any such Derivative Works as a whole, provided Your use,
- reproduction, and distribution of the Work otherwise complies with
- the conditions stated in this License.
-
- 5. Submission of Contributions. Unless You explicitly state otherwise,
- any Contribution intentionally submitted for inclusion in the Work
- by You to the Licensor shall be under the terms and conditions of
- this License, without any additional terms or conditions.
- Notwithstanding the above, nothing herein shall supersede or modify
- the terms of any separate license agreement you may have executed
- with Licensor regarding such Contributions.
-
- 6. Trademarks. This License does not grant permission to use the trade
- names, trademarks, service marks, or product names of the Licensor,
- except as required for reasonable and customary use in describing the
- origin of the Work and reproducing the content of the NOTICE file.
-
- 7. Disclaimer of Warranty. Unless required by applicable law or
- agreed to in writing, Licensor provides the Work (and each
- Contributor provides its Contributions) on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
- implied, including, without limitation, any warranties or conditions
- of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
- PARTICULAR PURPOSE. You are solely responsible for determining the
- appropriateness of using or redistributing the Work and assume any
- risks associated with Your exercise of permissions under this License.
-
- 8. Limitation of Liability. In no event and under no legal theory,
- whether in tort (including negligence), contract, or otherwise,
- unless required by applicable law (such as deliberate and grossly
- negligent acts) or agreed to in writing, shall any Contributor be
- liable to You for damages, including any direct, indirect, special,
- incidental, or consequential damages of any character arising as a
- result of this License or out of the use or inability to use the
- Work (including but not limited to damages for loss of goodwill,
- work stoppage, computer failure or malfunction, or any and all
- other commercial damages or losses), even if such Contributor
- has been advised of the possibility of such damages.
-
- 9. Accepting Warranty or Additional Liability. While redistributing
- the Work or Derivative Works thereof, You may choose to offer,
- and charge a fee for, acceptance of support, warranty, indemnity,
- or other liability obligations and/or rights consistent with this
- License. However, in accepting such obligations, You may act only
- on Your own behalf and on Your sole responsibility, not on behalf
- of any other Contributor, and only if You agree to indemnify,
- defend, and hold each Contributor harmless for any liability
- incurred by, or claims asserted against, such Contributor by reason
- of your accepting any such warranty or additional liability.
-
- END OF TERMS AND CONDITIONS
-
- APPENDIX: How to apply the Apache License to your work.
-
- To apply the Apache License to your work, attach the following
- boilerplate notice, with the fields enclosed by brackets "[]"
- replaced with your own identifying information. (Don't include
- the brackets!) The text should be enclosed in the appropriate
- comment syntax for the file format. We also recommend that a
- file or class name and description of purpose be included on the
- same "printed page" as the copyright notice for easier
- identification within third-party archives.
-
- Copyright [yyyy] [name of copyright owner]
-
- Licensed under the Apache License, Version 2.0 (the "License");
- you may not use this file except in compliance with the License.
- You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
-
juplo
- Java bits from nerds for nerds
-
- Mailing Lists
juplo
- Java bits from nerds for nerds
-
- $shortTitle
Annotated classes in dependencies are not found.
- hibernate-maven-plugin always needs a database-connection
-
-<configuration>
- <target>SCRIPT</target>
-</configuration>
Dependency for driver-class XYZ is missing
-
-[INFO] Gathered hibernate-configuration (turn on debugging for details):
-[INFO] hibernate.connection.username = sa
-[INFO] hibernate.connection.password =
-[INFO] hibernate.dialect = org.hibernate.dialect.HSQLDialect
-[INFO] hibernate.connection.url = jdbc:hsqldb:/home/kai/mmf/target/mmf;shutdown=true
-[INFO] hibernate.connection.driver_class = org.hsqldb.jdbcDriver
-[ERROR] Dependency for driver-class org.hsqldb.jdbcDriver is missing!
-[INFO] ------------------------------------------------------------------------
-[ERROR] BUILD ERROR
-[INFO] ------------------------------------------------------------------------
-[INFO] org.hsqldb.jdbcDriver
-[INFO] ------------------------------------------------------------------------
-[INFO] For more information, run Maven with the -e switch
-[INFO] ------------------------------------------------------------------------
-[INFO] Total time: 2 seconds
-[INFO] Finished at: Thu Nov 29 11:31:14 CET 2012
-[INFO] Final Memory: 32M/342M
-[INFO] ------------------------------------------------------------------------
-<plugin>
- <groupId>de.juplo</groupId>
- <artifactId>hibernate-maven-plugin</artifactId>
- <version>${project.version}</version>
- <executions>
- <execution>
- <goals>
- <goal>export</goal>
- </goals>
- </execution>
- </executions>
- <dependencies>
- <dependency>
- <groupId>org.hsqldb</groupId>
- <artifactId>hsqldb</artifactId>
- <version>2.2.8</version>
- </dependency>
- </dependencies>
-</plugin>
DBUnit fails after execution of hibernate was skipped because nothing has changed
-
-<plugin>
- <groupId>org.codehaus.mojo</groupId>
- <artifactId>dbunit-maven-plugin</artifactId>
- <configuration>
- <skip>${hibernate.export.skipped}</skip>
- </configuration>
-</plugin>
The database will not be recreated after a manual drop/clean
-
-[INFO] No modified annotated classes found and dialect unchanged.
-[INFO] Skipping schema generation!
-mvn hibernate:export -Dhibernate.export.force=true
The hibernate:export goal is not executed, when tests are skipped
-
-<plugin>
- <groupId>de.juplo</groupId>
- <artifactId>hibernate-maven-plugin</artifactId>
- ...
- <configuration>
- <skip>false</skip>
- </configuration>
-</plugin>
I do not want my dependencies to be scanned for hibernate annotations
-
-<plugin>
- <groupId>de.juplo</groupId>
- <artifactId>hibernate-maven-plugin</artifactId>
- ...
- <configuration>
- <scanDependencies>none</scanDependencies>
- </configuration>
-</plugin>
No annotated classes found
- juplo
- Java bits from nerds for nerds
-
- Plugin Management
Project Plugin Management
GroupId ArtifactId Version org.apache.maven.plugins maven-antrun-plugin 1.3 org.apache.maven.plugins maven-assembly-plugin 2.2-beta-5 org.apache.maven.plugins maven-dependency-plugin 2.1 org.apache.maven.plugins maven-release-plugin 2.1 juplo
- Java bits from nerds for nerds
-
- Project Plugins
Project Build Plugins
GroupId ArtifactId Version org.apache.maven.plugins maven-clean-plugin 2.5 org.apache.maven.plugins maven-compiler-plugin 3.3 org.apache.maven.plugins maven-deploy-plugin 2.7 org.apache.maven.plugins maven-enforcer-plugin 1.2 org.apache.maven.plugins maven-install-plugin 2.3 org.apache.maven.plugins maven-jar-plugin 2.2 org.apache.maven.plugins maven-resources-plugin 2.3 org.apache.maven.plugins maven-site-plugin 3.0 org.apache.maven.plugins maven-source-plugin 2.1.2 org.apache.maven.plugins maven-surefire-plugin 2.10 org.codehaus.mojo aspectj-maven-plugin 1.8 Project Report Plugins
GroupId ArtifactId Version org.apache.maven.plugins maven-changes-plugin 2.11 org.apache.maven.plugins maven-javadoc-plugin 2.10.3 org.apache.maven.plugins maven-jxr-plugin 2.5 org.apache.maven.plugins maven-pmd-plugin 3.5 org.apache.maven.plugins maven-scm-plugin 1.9.4 org.apache.maven.plugins maven-surefire-report-plugin 2.18.1 juplo
- Java bits from nerds for nerds
-
- PMD
PMD Results
Files
de/juplo/facebook/aspects/SanitizeAspect.java
Violation Line Useless parentheses. 70 Useless parentheses. 71 Useless parentheses. 72 Useless parentheses. 73 Useless parentheses. 73 Useless parentheses. 73 Useless parentheses. 74 Useless parentheses. 74 Useless parentheses. 74 Useless parentheses. 75 Useless parentheses. 75 Useless parentheses. 75 juplo
- Java bits from nerds for nerds
-
- Project Information
Project Information
Overview
Document Description About Collection of usefull classes for communicating with the Facebook-Graph-API Plugin Management This document lists the plugins that are defined through pluginManagement. Distribution Management This document provides informations on the distribution management of this project. Dependency Information This document describes how to to include this project as a dependency using various dependency management tools. Source Repository This is a link to the online source repository that can be viewed via a web browser. Mailing Lists This document provides subscription and archive information for this project's mailing lists. Issue Tracking This is a link to the issue management system for this project. Issues (bugs, features, change requests) can be created and queried using this link. Continuous Integration This is a link to the definitions of all continuous integration processes that builds and tests code on a frequent, regular basis. Project Plugins This document lists the build plugins and the report plugins used by this project. Project License This is a link to the definitions of project licenses. Project Team This document provides information on the members of this project. These are the individuals who have contributed to the project in one form or another. Project Summary This document lists other related information of this project Dependencies This document lists the project's dependencies and provides information on each dependency. juplo
- Java bits from nerds for nerds
-
- Project Reports
Generated Reports
Overview
Document Description JavaDocs JavaDoc API documentation. Test JavaDocs Test JavaDoc API documentation. Source Xref HTML based, cross-reference version of Java source code. Test Source Xref HTML based, cross-reference version of Java test source code. Surefire Report Report on the test results of the project. PMD Verification of coding rules. juplo
- Java bits from nerds for nerds
-
- Project Summary
Project Summary
Project Information
Field Value Name Juplo - Facebook Utils Description Collection of usefull classes for communicating with the Facebook-Graph-API Homepage http://www.juplo.de/facebook-utils juplo
- Java bits from nerds for nerds
-
- $shortTitle
-<plugin>
- <groupId>de.juplo</groupId>
- <artifactId>hibernate-maven-plugin</artifactId>
- ...
- <configuration>
- <skip>false</skip>
- </configuration>
-</plugin>
-<plugin>
- <groupId>de.juplo</groupId>
- <artifactId>hibernate-maven-plugin</artifactId>
- ...
- <configuration>
- <skip>${foo.bar}</skip>
- </configuration>
-</plugin>
juplo
- Java bits from nerds for nerds
-
- Source Repository
Overview
Anonymous access
$ git clone http://juplo.de/git/facebook-utils
Developer access
$ git clone ssh://juplo.de/var/lib/git/juplo/facebook-utils
juplo
- Java bits from nerds for nerds
-
- Surefire Report
Summary
Tests Errors Failures Skipped Success Rate Time 12 0 0 0 100% 1.181 Package List
Package Tests Errors Failures Skipped Success Rate Time de.juplo.facebook.exceptions 2 0 0 0 100% 0 de.juplo.facebook.client 10 0 0 0 100% 1.181 de.juplo.facebook.exceptions
Class Tests Errors Failures Skipped Success Rate Time FacebookErrorMessageMappingTest 2 0 0 0 100% 0 de.juplo.facebook.client
Class Tests Errors Failures Skipped Success Rate Time GraphApiErrorHandlerTest 10 0 0 0 100% 1.181 Test Cases
GraphApiErrorHandlerTest
testError21 0.121 testUnmappedError 0.005 testUnmappedErrors 0.012 testInvlalidErrors 0.062 testError2200 0.007 testError1 0.006 testError2 0.006 testError100 0.006 testError104 0.006 testError613 0.005 juplo
- Java bits from nerds for nerds
-
- Project Team
The Team
Members
Image Id Name Email kai Kai Moritz kai@juplo.de All Classes
-
-
-
diff --git a/dist/facebook-utils-2.5.0/testapidocs/allclasses-noframe.html b/dist/facebook-utils-2.5.0/testapidocs/allclasses-noframe.html
deleted file mode 100644
index cba714f4..00000000
--- a/dist/facebook-utils-2.5.0/testapidocs/allclasses-noframe.html
+++ /dev/null
@@ -1,22 +0,0 @@
-
-
-
-
-
-
-All Classes
-
-
-
diff --git a/dist/facebook-utils-2.5.0/testapidocs/constant-values.html b/dist/facebook-utils-2.5.0/testapidocs/constant-values.html
deleted file mode 100644
index f90dd138..00000000
--- a/dist/facebook-utils-2.5.0/testapidocs/constant-values.html
+++ /dev/null
@@ -1,126 +0,0 @@
-
-
-
-
-
-
-Constant Field Values
-Contents
-Class GraphApiErrorHandlerTest
-
-
-
-
-
-
-
-
-@ContextConfiguration(locations="classpath:/spring/test-facebook-error-handler.xml")
-public class GraphApiErrorHandlerTest
-extends Object
-
-
-
-
-
-
-
-Constructor Summary
-
-
-
-
-Constructor and Description
-
-
-
-GraphApiErrorHandlerTest()
-
-Method Summary
-
-
-
-
-
-Modifier and Type
-Method and Description
-
-
-
-void
-setUp()
-
-
-void
-testError1()
-
-
-void
-testError100()
-
-
-void
-testError104()
-
-
-void
-testError2()
-
-
-void
-testError21()
-
-
-void
-testError2200()
-
-
-void
-testError613()
-
-
-void
-testInvlalidErrors()
-
-
-void
-testUnmappedError()
-
-
-void
-testUnmappedErrors()
-
-
-
-
-Constructor Detail
-
-
-
-
-
-GraphApiErrorHandlerTest
-public GraphApiErrorHandlerTest()
-
-
-Method Detail
-
-
-
-
-
-
-
-
-testError1
-public void testError1()
-
-
-
-
-
-testError2
-public void testError2()
-
-
-
-
-
-testError21
-public void testError21()
-
-
-
-
-
-testError100
-public void testError100()
-
-
-
-
-
-testError104
-public void testError104()
-
-
-
-
-
-testError613
-public void testError613()
-
-
-
-
-
-testError2200
-public void testError2200()
-
-
-
-
-
-testUnmappedError
-public void testUnmappedError()
-
-
-
-
-
-testUnmappedErrors
-public void testUnmappedErrors()
-
-
-
-
-
-testInvlalidErrors
-public void testInvlalidErrors()
-
-
-setUp
-public void setUp()
-Class MockClientHttpRequestFactory
-
-
-
-
-
-
-
-
-
-
-public class MockClientHttpRequestFactory
-extends Object
-implements org.springframework.http.client.ClientHttpRequestFactory
-
-
-
-
-
-
-
-Constructor Summary
-
-
-
-
-Constructor and Description
-
-
-
-MockClientHttpRequestFactory()
-
-Method Summary
-
-
-
-
-
-Modifier and Type
-Method and Description
-
-
-
-void
-addHeader(String name,
- String value)
-
-
-org.springframework.http.client.ClientHttpRequest
-createRequest(URI uri,
- org.springframework.http.HttpMethod method)
-
-
-void
-setBody(String body)
-
-
-void
-setHeaders(org.springframework.http.HttpHeaders headers)
-
-
-void
-setStatus(org.springframework.http.HttpStatus status)
-
-
-
-
-Constructor Detail
-
-
-
-
-
-MockClientHttpRequestFactory
-public MockClientHttpRequestFactory()
-
-
-Method Detail
-
-
-
-
-
-
-
-
-createRequest
-public org.springframework.http.client.ClientHttpRequest createRequest(URI uri,
- org.springframework.http.HttpMethod method)
- throws IOException
-
-
-createRequest
in interface org.springframework.http.client.ClientHttpRequestFactory
IOException
-
-
-
-
-setStatus
-public void setStatus(org.springframework.http.HttpStatus status)
-
-
-
-
-
-
-
-
-
-setHeaders
-public void setHeaders(org.springframework.http.HttpHeaders headers)
-
-
-setBody
-public void setBody(String body)
-Uses of Class
-
de.juplo.facebook.client.GraphApiErrorHandlerTestUses of Class
-
de.juplo.facebook.client.MockClientHttpRequestFactoryde.juplo.facebook.client
-Classes
-
-Package de.juplo.facebook.client
-
-
-
-
-
-
-
-Class
-Description
-
-
-GraphApiErrorHandlerTest
-
-
-
-
-MockClientHttpRequestFactory
-
-Class Hierarchy
-
-
-
-
-Uses of Package
-
de.juplo.facebook.clientClass FacebookErrorMessageMappingTest
-
-
-
-
-
-
-
-
-public class FacebookErrorMessageMappingTest
-extends Object
-
-
-
-
-
-
-
-Constructor Summary
-
-
-
-
-Constructor and Description
-
-
-
-FacebookErrorMessageMappingTest()
-
-Method Summary
-
-
-
-
-
-Modifier and Type
-Method and Description
-
-
-
-void
-testDeserialize()
-
-
-void
-testSerialize()
-
-
-
-
-Constructor Detail
-
-
-
-
-
-FacebookErrorMessageMappingTest
-public FacebookErrorMessageMappingTest()
-
-
-Method Detail
-
-
-
-
-
-
-
-
-testSerialize
-public void testSerialize()
- throws com.fasterxml.jackson.core.JsonProcessingException
-
-
-com.fasterxml.jackson.core.JsonProcessingException
-
-testDeserialize
-public void testDeserialize()
- throws IOException
-
-
-IOException
Uses of Class
-
de.juplo.facebook.exceptions.FacebookErrorMessageMappingTestde.juplo.facebook.exceptions
-Classes
-
-Package de.juplo.facebook.exceptions
-
-
-
-
-
-
-
-Class
-Description
-
-
-
-FacebookErrorMessageMappingTest
-
-Class Hierarchy
-
-
-
-
-Uses of Package
-
de.juplo.facebook.exceptionsDeprecated API
-Contents
-How This API Document Is Organized
-
-
-This help file applies to API documentation generated using the standard doclet.Overview
-Package
-
-
-Class/Interface
-
-
-
-
-
-
-Annotation Type
-
-
-Enum
-
-
-Use
-Tree (Class Hierarchy)
-java.lang.Object
. The interfaces do not inherit from java.lang.Object
.
-
-Deprecated API
-Index
-Prev/Next
-Frames/No Frames
-All Classes
-Serialized Form
-Constant Field Values
-A
-
-
-
-
-
-C
-
-
-
-
-
-D
-
-
-
-
-
-F
-
-
-
-
-
-G
-
-
-
-
-
-M
-
-
-
-
-
-S
-
-
-
-
-
-T
-
-
-A C D F G M S T Frame Alert
-Packages
-
-Juplo - Facebook Utils 2.5.0 Test API
-
-
-
-
-
-Package
-Description
-
-
-de.juplo.facebook.client
-
-
-
-
-de.juplo.facebook.exceptions
-
-Hierarchy For All Packages
-Package Hierarchies:
-
-Class Hierarchy
-
-
-
-
-All Classes
-
-
-
-
-
-
diff --git a/dist/facebook-utils-2.5.0/xref-test/de/juplo/facebook/client/GraphApiErrorHandlerTest.html b/dist/facebook-utils-2.5.0/xref-test/de/juplo/facebook/client/GraphApiErrorHandlerTest.html
deleted file mode 100644
index c3dde74a..00000000
--- a/dist/facebook-utils-2.5.0/xref-test/de/juplo/facebook/client/GraphApiErrorHandlerTest.html
+++ /dev/null
@@ -1,821 +0,0 @@
-
-
-
-
-1 package de.juplo.facebook.client;
-2
-3 import de.juplo.facebook.exceptions.AccessTokenRequiredException;
-4 import de.juplo.facebook.exceptions.CallbackVerificationFailedException;
-5 import de.juplo.facebook.exceptions.UnsupportedGetRequestException;
-6 import de.juplo.facebook.exceptions.UnexpectedErrorException;
-7 import de.juplo.facebook.exceptions.RateExceededException;
-8 import de.juplo.facebook.exceptions.GraphApiException;
-9 import de.juplo.facebook.exceptions.GraphApiException.Type;
-10 import de.juplo.facebook.exceptions.UnknownErrorException;
-11 import de.juplo.facebook.exceptions.PageMigratedException;
-12 import de.juplo.facebook.exceptions.UnmappedErrorException;
-13 import java.util.Date;
-14 import java.util.Map;
-15 import java.util.Set;
-16 import javax.annotation.Resource;
-17 import static org.junit.Assert.*;
-18 import org.junit.Before;
-19 import org.junit.Test;
-20 import org.junit.runner.RunWith;
-21 import org.slf4j.Logger;
-22 import org.slf4j.LoggerFactory;
-23 import org.springframework.http.HttpStatus;
-24 import org.springframework.security.access.AccessDeniedException;
-25 import org.springframework.security.oauth2.client.OAuth2RestTemplate;
-26 import org.springframework.security.oauth2.client.http.OAuth2ErrorHandler;
-27 import org.springframework.security.oauth2.client.resource.OAuth2ProtectedResourceDetails;
-28 import org.springframework.security.oauth2.client.resource.UserApprovalRequiredException;
-29 import org.springframework.security.oauth2.client.resource.UserRedirectRequiredException;
-30 import org.springframework.security.oauth2.client.token.AccessTokenProvider;
-31 import org.springframework.security.oauth2.client.token.AccessTokenRequest;
-32 import org.springframework.security.oauth2.common.OAuth2AccessToken;
-33 import static org.springframework.security.oauth2.common.OAuth2AccessToken.OAUTH2_TYPE;
-34 import org.springframework.security.oauth2.common.OAuth2RefreshToken;
-35 import org.springframework.test.context.ContextConfiguration;
-36 import org.springframework.test.context.junit4.SpringJUnit4ClassRunner;
-37 import org.springframework.web.client.HttpClientErrorException;
-38
-39
-40
-41 /**
-42 *
-43 * @author kai
-44 */
-45 @RunWith(SpringJUnit4ClassRunner.class)
-46 @ContextConfiguration(
-47 locations = {
-48 "classpath:/spring/test-facebook-error-handler.xml"
-49 })
-50 public class GraphApiErrorHandlerTest
-51 {
-52 private static final Logger log =
-53 LoggerFactory.getLogger(GraphApiErrorHandlerTest.class);
-54
-55 @Resource
-56 private OAuth2RestTemplate clientTemplate;
-57
-58 private MockClientHttpRequestFactory requestFactory;
-59
-60
-61 @Test
-62 public void testError1()
-63 {
-64 log.info("testError1");
-65
-66
-67 requestFactory.setBody(
-68 "{\n" +
-69 " \"error\":\n" +
-70 " {\n" +
-71 " \"message\": \"An unknown error has occurred.\",\n" +
-72 " \"type\": \"OAuthException\",\n" +
-73 " \"code\": 1\n" +
-74 " }\n" +
-75 "}");
-76
-77 try
-78 {
-79 clientTemplate.getForObject("ANY", SOME.class);
-80 fail("The expected exception was not thrown");
-81 }
-82 catch(UnknownErrorException e)
-83 {
-84 log.debug("{}", e.toString());
-85 assertEquals("invalid_request", e.getOAuth2ErrorCode());
-86 assertEquals(new Integer(1), e.getCode());
-87 assertEquals("An unknown error has occurred.", e.getMessage());
-88 assertEquals(Type.OAuthException, e.getType());
-89 }
-90 }
-91
-92 @Test
-93 public void testError2()
-94 {
-95 log.info("testError2");
-96
-97
-98 requestFactory.setBody(
-99 "{\n" +
-100 " \"error\":\n" +
-101 " {\n" +
-102 " \"message\": \"An unexpected error has occurred. Please retry your request later.\",\n" +
-103 " \"type\": \"OAuthException\",\n" +
-104 " \"code\": 2\n" +
-105 " }\n" +
-106 "}");
-107
-108 try
-109 {
-110 clientTemplate.getForObject("ANY", SOME.class);
-111 fail("The expected exception was not thrown");
-112 }
-113 catch(UnexpectedErrorException e)
-114 {
-115 log.debug("{}", e.toString());
-116 assertEquals("invalid_request", e.getOAuth2ErrorCode());
-117 assertEquals(new Integer(2), e.getCode());
-118 assertEquals("An unexpected error has occurred. Please retry your request later.", e.getMessage());
-119 assertEquals(Type.OAuthException, e.getType());
-120 }
-121 }
-122
-123 @Test
-124 public void testError21()
-125 {
-126 log.info("testError21");
-127
-128
-129 requestFactory.setBody(
-130 "{\n" +
-131 " \"error\":\n" +
-132 " {\n" +
-133 " \"message\": \"(#21) Page ID 590408587650316 was migrated to page ID 1421620791415603. Please update your API calls to the new ID\",\n" +
-134 " \"type\": \"OAuthException\",\n" +
-135 " \"code\": 21\n" +
-136 " }\n" +
-137 "}");
-138
-139 try
-140 {
-141 clientTemplate.getForObject("ANY", SOME.class);
-142 fail("The expected exception was not thrown");
-143 }
-144 catch(PageMigratedException e)
-145 {
-146 log.debug("{}", e.toString());
-147 assertEquals("invalid_request", e.getOAuth2ErrorCode());
-148 assertEquals(new Integer(21), e.getCode());
-149 assertEquals("(#21) Page ID 590408587650316 was migrated to page ID 1421620791415603. Please update your API calls to the new ID", e.getMessage());
-150 assertEquals(Type.OAuthException, e.getType());
-151 }
-152 }
-153
-154 @Test
-155 public void testError100()
-156 {
-157 log.info("testError100");
-158
-159
-160 requestFactory.setBody(
-161 "{\n" +
-162 " \"error\":\n" +
-163 " {\n" +
-164 " \"message\": \"Unsupported get request.\",\n" +
-165 " \"type\": \"GraphMethodException\",\n" +
-166 " \"code\": 100\n" +
-167 " }\n" +
-168 "}");
-169
-170 try
-171 {
-172 clientTemplate.getForObject("ANY", SOME.class);
-173 fail("The expected exception was not thrown");
-174 }
-175 catch(UnsupportedGetRequestException e)
-176 {
-177 log.debug("{}", e.toString());
-178 assertEquals("invalid_request", e.getOAuth2ErrorCode());
-179 assertEquals(new Integer(100), e.getCode());
-180 assertEquals("Unsupported get request.", e.getMessage());
-181 assertEquals(Type.GraphMethodException, e.getType());
-182 }
-183 }
-184
-185 @Test
-186 public void testError104()
-187 {
-188 log.info("testError104");
-189
-190 requestFactory.setBody("{\"error\":{\"message\":\"An access token is required to request this resource.\",\"type\":\"OAuthException\",\"code\":104,\"fbtrace_id\":\"E2Jjkj5++LL\"}}");
-191
-192 try
-193 {
-194 clientTemplate.getForObject("ANY", SOME.class);
-195 fail("The expected exception was not thrown");
-196 }
-197 catch(AccessTokenRequiredException e)
-198 {
-199 log.debug("{}", e.toString());
-200 assertEquals("invalid_request", e.getOAuth2ErrorCode());
-201 assertEquals(new Integer(104), e.getCode());
-202 assertEquals("An access token is required to request this resource.", e.getMessage());
-203 assertEquals(Type.OAuthException, e.getType());
-204 assertEquals("E2Jjkj5++LL", e.getTraceId());
-205 }
-206 }
-207
-208 @Test
-209 public void testError613()
-210 {
-211 log.info("testError613");
-212
-213
-214 requestFactory.setBody(
-215 "{\n" +
-216 " \"error\":\n" +
-217 " {\n" +
-218 " \"message\": \"(#613) Calls to stream have exceeded the rate of 600 calls per 600 seconds.\",\n" +
-219 " \"type\": \"OAuthException\",\n" +
-220 " \"code\": 613\n" +
-221 " }\n" +
-222 "}");
-223
-224 try
-225 {
-226 clientTemplate.getForObject("ANY", SOME.class);
-227 fail("The expected exception was not thrown");
-228 }
-229 catch(RateExceededException e)
-230 {
-231 log.debug("{}", e.toString());
-232 assertEquals("invalid_request", e.getOAuth2ErrorCode());
-233 assertEquals(new Integer(613), e.getCode());
-234 assertEquals("(#613) Calls to stream have exceeded the rate of 600 calls per 600 seconds.", e.getMessage());
-235 assertEquals(Type.OAuthException, e.getType());
-236 }
-237 }
-238
-239 @Test
-240 public void testError2200()
-241 {
-242 requestFactory.setBody("{\"error\":{\"message\":\"(#2200) callback verification failed: \",\"type\":\"OAuthException\",\"code\":2200,\"fbtrace_id\":\"ESLjoZKvPXg\"}}");
-243
-244 try
-245 {
-246 clientTemplate.getForObject("ANY", SOME.class);
-247 fail("The expected exception was not thrown");
-248 }
-249 catch(CallbackVerificationFailedException e)
-250 {
-251 log.debug("{}", e.toString());
-252 assertEquals("invalid_request", e.getOAuth2ErrorCode());
-253 assertEquals(new Integer(2200), e.getCode());
-254 assertEquals("(#2200) callback verification failed: ", e.getMessage());
-255 assertEquals(Type.OAuthException, e.getType());
-256 assertEquals("ESLjoZKvPXg", e.getTraceId());
-257 }
-258 }
-259
-260 @Test
-261 public void testUnmappedError()
-262 {
-263 log.info("testUnmappedError");
-264
-265
-266 requestFactory.setBody(
-267 "{\n" +
-268 " \"error\":\n" +
-269 " {\n" +
-270 " \"message\": \"This error does not exist.\",\n" +
-271 " \"type\": \"NonexistentTypeException\",\n" +
-272 " \"code\": 999999999\n" +
-273 " }\n" +
-274 "}");
-275
-276 try
-277 {
-278 clientTemplate.getForObject("ANY", SOME.class);
-279 fail("The expected exception was not thrown");
-280 }
-281 catch(GraphApiException e)
-282 {
-283 log.debug("{}", e.toString());
-284 assertEquals("invalid_request", e.getOAuth2ErrorCode());
-285 assertEquals(new Integer(999999999), e.getCode());
-286 assertEquals("This error does not exist.", e.getMessage());
-287 try
-288 {
-289 Type type = e.getType();
-290 log.error("unknown type: {}", type);
-291 fail("unmapped type was resolved by enum: " + type);
-292 }
-293 catch (IllegalArgumentException ee) {}
-294 }
-295 }
-296
-297 @Test
-298 public void testUnmappedErrors()
-299 {
-300 log.info("testUnmappedErrors");
-301
-302
-303 requestFactory.setBody(
-304 "{\n" +
-305 " \"error\":\n" +
-306 " {\n" +
-307 " \"message\": null,\n" +
-308 " \"type\": \"WhateverTypeException\",\n" +
-309 " \"code\": 999999999\n" +
-310 " }\n" +
-311 "}");
-312
-313 try
-314 {
-315 clientTemplate.getForObject("ANY", SOME.class);
-316 fail("The expected exception was not thrown");
-317 }
-318 catch(UnmappedErrorException e)
-319 {
-320 log.debug("{}", e.toString());
-321 assertNull(e.getMessage());
-322 try
-323 {
-324 Type type = e.getType();
-325 log.error("unknown type: {}", type);
-326 fail("unmapped type was resolved by enum: " + type);
-327 }
-328 catch (IllegalArgumentException ee) {}
-329 assertEquals(new Integer(999999999), e.getCode());
-330 assertNull(e.getSubCode());
-331 assertNull(e.getUserTitle());
-332 assertNull(e.getUserMessage());
-333 assertNull(e.getTraceId());
-334 }
-335 catch(Exception e)
-336 {
-337 fail("A wrong exception was thrown: " + e.toString());
-338 }
-339
-340
-341 requestFactory.setBody(
-342 "{\n" +
-343 " \"error\":\n" +
-344 " {\n" +
-345 " \"type\": \"WhateverTypeException\",\n" +
-346 " \"code\": 999999999\n" +
-347 " }\n" +
-348 "}");
-349
-350 try
-351 {
-352 clientTemplate.getForObject("ANY", SOME.class);
-353 fail("The expected exception was not thrown");
-354 }
-355 catch(UnmappedErrorException e)
-356 {
-357 log.debug("{}", e.toString());
-358 assertNull(e.getMessage());
-359 try
-360 {
-361 Type type = e.getType();
-362 log.error("unknown type: {}", type);
-363 fail("unmapped type was resolved by enum: " + type);
-364 }
-365 catch (IllegalArgumentException ee) {}
-366 assertEquals(new Integer(999999999), e.getCode());
-367 assertNull(e.getSubCode());
-368 assertNull(e.getUserTitle());
-369 assertNull(e.getUserMessage());
-370 assertNull(e.getTraceId());
-371 }
-372 catch(Exception e)
-373 {
-374 fail("A wrong exception was thrown: " + e.toString());
-375 }
-376
-377
-378 requestFactory.setBody(
-379 "{\n" +
-380 " \"error\":\n" +
-381 " {\n" +
-382 " \"message\": \"An unmapped Graph-API-Exception.\",\n" +
-383 " \"type\": null,\n" +
-384 " \"code\": 999999999\n" +
-385 " }\n" +
-386 "}");
-387
-388 try
-389 {
-390 clientTemplate.getForObject("ANY", SOME.class);
-391 fail("The expected exception was not thrown");
-392 }
-393 catch(UnmappedErrorException e)
-394 {
-395 log.debug("{}", e.toString());
-396 assertEquals("An unmapped Graph-API-Exception.", e.getMessage());
-397 assertNull(e.getType());
-398 assertEquals(new Integer(999999999), e.getCode());
-399 assertNull(e.getSubCode());
-400 assertNull(e.getUserTitle());
-401 assertNull(e.getUserMessage());
-402 assertNull(e.getTraceId());
-403 }
-404 catch(Exception e)
-405 {
-406 fail("A wrong exception was thrown: " + e.toString());
-407 }
-408
-409
-410 requestFactory.setBody(
-411 "{\n" +
-412 " \"error\":\n" +
-413 " {\n" +
-414 " \"message\": \"An unmapped Graph-API-Exception.\",\n" +
-415 " \"code\": 999999999\n" +
-416 " }\n" +
-417 "}");
-418
-419 try
-420 {
-421 clientTemplate.getForObject("ANY", SOME.class);
-422 fail("The expected exception was not thrown");
-423 }
-424 catch(UnmappedErrorException e)
-425 {
-426 log.debug("{}", e.toString());
-427 assertEquals("An unmapped Graph-API-Exception.", e.getMessage());
-428 assertNull(e.getType());
-429 assertEquals(new Integer(999999999), e.getCode());
-430 assertNull(e.getSubCode());
-431 assertNull(e.getUserTitle());
-432 assertNull(e.getUserMessage());
-433 assertNull(e.getTraceId());
-434 }
-435 catch(Exception e)
-436 {
-437 fail("A wrong exception was thrown: " + e.toString());
-438 }
-439 }
-440
-441 @Test
-442 public void testInvlalidErrors()
-443 {
-444 log.info("testInvalidErrors");
-445
-446
-447 requestFactory.setBody(
-448 "{\n" +
-449 " \"error\":\n" +
-450 " {\n" +
-451 " \"message\": \"Not a Graph-Api-Exception.\",\n" +
-452 " \"type\": \"Whatever\",\n" +
-453 " \"code\": \"some string\"\n" +
-454 " }\n" +
-455 "}");
-456
-457 try
-458 {
-459 clientTemplate.getForObject("ANY", SOME.class);
-460 fail("The expected exception was not thrown");
-461 }
-462 catch(HttpClientErrorException e)
-463 {
-464 log.debug("{}", e.toString());
-465 }
-466 catch(Exception e)
-467 {
-468 fail("A wrong exception was thrown: " + e.toString());
-469 }
-470
-471
-472 requestFactory.setBody(
-473 "{\n" +
-474 " \"error\":\n" +
-475 " {\n" +
-476 " \"message\": \"Not a Graph-Api-Exception.\",\n" +
-477 " \"type\": \"Whatever\",\n" +
-478 " \"code\": 9.9\n" +
-479 " }\n" +
-480 "}");
-481
-482 try
-483 {
-484 clientTemplate.getForObject("ANY", SOME.class);
-485 fail("The expected exception was not thrown");
-486 }
-487 catch(HttpClientErrorException e)
-488 {
-489 log.debug("{}", e.toString());
-490 }
-491 catch(Exception e)
-492 {
-493 fail("A wrong exception was thrown: " + e.toString());
-494 }
-495
-496
-497 requestFactory.setBody(
-498 "{\n" +
-499 " \"error\":\n" +
-500 " {\n" +
-501 " \"message\": \"Not a Graph-Api-Exception.\",\n" +
-502 " \"type\": \"Whatever\",\n" +
-503 " \"code\": null\n" +
-504 " }\n" +
-505 "}");
-506
-507 try
-508 {
-509 clientTemplate.getForObject("ANY", SOME.class);
-510 fail("The expected exception was not thrown");
-511 }
-512 catch(HttpClientErrorException e)
-513 {
-514 log.debug("{}", e.toString());
-515 }
-516 catch(Exception e)
-517 {
-518 fail("A wrong exception was thrown: " + e.toString());
-519 }
-520
-521
-522 requestFactory.setBody(
-523 "{\n" +
-524 " \"error\":\n" +
-525 " {\n" +
-526 " \"message\": \"Not a Graph-Api-Exception.\",\n" +
-527 " \"type\": \"Whatever\"\n" +
-528 " }\n" +
-529 "}");
-530
-531 try
-532 {
-533 clientTemplate.getForObject("ANY", SOME.class);
-534 fail("The expected exception was not thrown");
-535 }
-536 catch(HttpClientErrorException e)
-537 {
-538 log.debug("{}", e.toString());
-539 }
-540 catch(Exception e)
-541 {
-542 fail("A wrong exception was thrown: " + e.toString());
-543 }
-544
-545
-546 requestFactory.setBody("{\"error\":{\"message\":null}}");
-547
-548 try
-549 {
-550 clientTemplate.getForObject("ANY", SOME.class);
-551 fail("The expected exception was not thrown");
-552 }
-553 catch(HttpClientErrorException e)
-554 {
-555 log.debug("{}", e.toString());
-556 }
-557 catch(Exception e)
-558 {
-559 fail("A wrong exception was thrown: " + e.toString());
-560 }
-561
-562
-563 requestFactory.setBody("{\"error\":{\"type\":null}}");
-564
-565 try
-566 {
-567 clientTemplate.getForObject("ANY", SOME.class);
-568 fail("The expected exception was not thrown");
-569 }
-570 catch(HttpClientErrorException e)
-571 {
-572 log.debug("{}", e.toString());
-573 }
-574 catch(Exception e)
-575 {
-576 fail("A wrong exception was thrown: " + e.toString());
-577 }
-578
-579
-580 requestFactory.setBody("{\"error\":{\"code\":null}}");
-581
-582 try
-583 {
-584 clientTemplate.getForObject("ANY", SOME.class);
-585 fail("The expected exception was not thrown");
-586 }
-587 catch(HttpClientErrorException e)
-588 {
-589 log.debug("{}", e.toString());
-590 }
-591 catch(Exception e)
-592 {
-593 fail("A wrong exception was thrown: " + e.toString());
-594 }
-595
-596
-597 requestFactory.setBody("{\"error\":{}}");
-598
-599 try
-600 {
-601 clientTemplate.getForObject("ANY", SOME.class);
-602 fail("The expected exception was not thrown");
-603 }
-604 catch(HttpClientErrorException e)
-605 {
-606 log.debug("{}", e.toString());
-607 }
-608 catch(Exception e)
-609 {
-610 fail("A wrong exception was thrown: " + e.toString());
-611 }
-612
-613
-614 requestFactory.setBody("{\"error\":\"some message\"}");
-615
-616 try
-617 {
-618 clientTemplate.getForObject("ANY", SOME.class);
-619 fail("The expected exception was not thrown");
-620 }
-621 catch(HttpClientErrorException e)
-622 {
-623 log.debug("{}", e.toString());
-624 }
-625 catch(Exception e)
-626 {
-627 fail("A wrong exception was thrown: " + e.toString());
-628 }
-629
-630
-631 requestFactory.setBody("{\"error\":null}");
-632
-633 try
-634 {
-635 clientTemplate.getForObject("ANY", SOME.class);
-636 fail("The expected exception was not thrown");
-637 }
-638 catch(HttpClientErrorException e)
-639 {
-640 log.debug("{}", e.toString());
-641 }
-642 catch(Exception e)
-643 {
-644 fail("A wrong exception was thrown: " + e.toString());
-645 }
-646
-647
-648 requestFactory.setBody("{\"some filed\":\"some message\"}");
-649
-650 try
-651 {
-652 clientTemplate.getForObject("ANY", SOME.class);
-653 fail("The expected exception was not thrown");
-654 }
-655 catch(HttpClientErrorException e)
-656 {
-657 log.debug("{}", e.toString());
-658 }
-659 catch(Exception e)
-660 {
-661 fail("A wrong exception was thrown: " + e.toString());
-662 }
-663
-664
-665 requestFactory.setBody("{}");
-666
-667 try
-668 {
-669 clientTemplate.getForObject("ANY", SOME.class);
-670 fail("The expected exception was not thrown");
-671 }
-672 catch(HttpClientErrorException e)
-673 {
-674 log.debug("{}", e.toString());
-675 }
-676 catch(Exception e)
-677 {
-678 fail("A wrong exception was thrown: " + e.toString());
-679 }
-680
-681
-682 requestFactory.setBody("");
-683
-684 try
-685 {
-686 clientTemplate.getForObject("ANY", SOME.class);
-687 fail("The expected exception was not thrown");
-688 }
-689 catch(HttpClientErrorException e)
-690 {
-691 log.debug("{}", e.toString());
-692 }
-693 catch(Exception e)
-694 {
-695 fail("A wrong exception was thrown: " + e.toString());
-696 }
-697 }
-698
-699
-700 @Before
-701 public void setUp()
-702 {
-703 requestFactory = new MockClientHttpRequestFactory();
-704 requestFactory.setStatus(HttpStatus.BAD_REQUEST);
-705 requestFactory.addHeader("Content-Type", "application/json");
-706 clientTemplate.setRequestFactory(requestFactory);
-707
-708 clientTemplate.setErrorHandler(
-709 new GraphApiErrorHandler(
-710 (OAuth2ErrorHandler)clientTemplate.getErrorHandler()
-711 )
-712 );
-713
-714 clientTemplate.setAccessTokenProvider(new AccessTokenProvider()
-715 {
-716 @Override
-717 public OAuth2AccessToken obtainAccessToken(
-718 OAuth2ProtectedResourceDetails details,
-719 AccessTokenRequest parameters
-720 )
-721 throws
-722 UserRedirectRequiredException,
-723 UserApprovalRequiredException,
-724 AccessDeniedException
-725 {
-726 return new OAuth2AccessToken() {
-727
-728 @Override
-729 public Map<String, Object> getAdditionalInformation()
-730 {
-731 throw new UnsupportedOperationException("Not supported yet.");
-732 }
-733
-734 @Override
-735 public Set<String> getScope()
-736 {
-737 throw new UnsupportedOperationException("Not supported yet.");
-738 }
-739
-740 @Override
-741 public OAuth2RefreshToken getRefreshToken()
-742 {
-743 throw new UnsupportedOperationException("Not supported yet.");
-744 }
-745
-746 @Override
-747 public String getTokenType()
-748 {
-749 return OAUTH2_TYPE;
-750 }
-751
-752 @Override
-753 public boolean isExpired()
-754 {
-755 return false;
-756 }
-757
-758 @Override
-759 public Date getExpiration()
-760 {
-761 throw new UnsupportedOperationException("Not supported yet.");
-762 }
-763
-764 @Override
-765 public int getExpiresIn()
-766 {
-767 throw new UnsupportedOperationException("Not supported yet.");
-768 }
-769
-770 @Override
-771 public String getValue()
-772 {
-773 return "ANY";
-774 }
-775 };
-776 }
-777
-778 @Override
-779 public boolean supportsResource(OAuth2ProtectedResourceDetails resource)
-780 {
-781 return true;
-782 }
-783
-784 @Override
-785 public OAuth2AccessToken refreshAccessToken(
-786 OAuth2ProtectedResourceDetails resource,
-787 OAuth2RefreshToken refreshToken,
-788 AccessTokenRequest request
-789 )
-790 throws
-791 UserRedirectRequiredException
-792 {
-793 throw new UnsupportedOperationException("Not supported yet.");
-794 }
-795
-796 @Override
-797 public boolean supportsRefresh(OAuth2ProtectedResourceDetails resource)
-798 {
-799 return false;
-800 }
-801 });
-802 }
-803
-804
-805 static class SOME
-806 {
-807 }
-808 }
-
-
-
-
-
diff --git a/dist/facebook-utils-2.5.0/xref-test/de/juplo/facebook/client/MockClientHttpRequestFactory.html b/dist/facebook-utils-2.5.0/xref-test/de/juplo/facebook/client/MockClientHttpRequestFactory.html
deleted file mode 100644
index 269ecadd..00000000
--- a/dist/facebook-utils-2.5.0/xref-test/de/juplo/facebook/client/MockClientHttpRequestFactory.html
+++ /dev/null
@@ -1,157 +0,0 @@
-
-
-
-
-1 package de.juplo.facebook.client;
-2
-3 import java.io.ByteArrayInputStream;
-4 import java.io.IOException;
-5 import java.io.InputStream;
-6 import java.io.OutputStream;
-7 import java.net.URI;
-8 import java.nio.charset.StandardCharsets;
-9 import org.slf4j.Logger;
-10 import org.slf4j.LoggerFactory;
-11 import org.springframework.http.HttpHeaders;
-12 import org.springframework.http.HttpMethod;
-13 import org.springframework.http.HttpStatus;
-14 import org.springframework.http.client.ClientHttpRequest;
-15 import org.springframework.http.client.ClientHttpRequestFactory;
-16 import org.springframework.http.client.ClientHttpResponse;
-17
-18
-19
-20 /**
-21 *
-22 * @author kai
-23 */
-24 public class MockClientHttpRequestFactory implements ClientHttpRequestFactory
-25 {
-26 private static final Logger log =
-27 LoggerFactory.getLogger(MockClientHttpRequestFactory.class);
-28
-29 private HttpStatus status = HttpStatus.OK;
-30 private HttpHeaders headers = new HttpHeaders();
-31 private String body = "";
-32
-33
-34 @Override
-35 public ClientHttpRequest createRequest(URI uri, HttpMethod method) throws IOException
-36 {
-37 return new MockClientHttpRequest(uri, method);
-38 }
-39
-40 public void setStatus(HttpStatus status)
-41 {
-42 this.status = status;
-43 }
-44
-45 public void setHeaders(HttpHeaders headers)
-46 {
-47 this.headers = headers;
-48 }
-49
-50 public void addHeader(String name, String value)
-51 {
-52 headers.add(name, value);
-53 }
-54
-55 public void setBody(String body)
-56 {
-57 log.trace(body);
-58 this.body = body;
-59 }
-60
-61
-62 class MockClientHttpRequest implements ClientHttpRequest
-63 {
-64 private final URI uri;
-65 private final HttpMethod method;
-66
-67
-68 public MockClientHttpRequest(URI uri, HttpMethod method)
-69 {
-70 this.uri = uri;
-71 this.method = method;
-72 }
-73
-74
-75 @Override
-76 public ClientHttpResponse execute() throws IOException
-77 {
-78 return new MockClientHttpResponse();
-79 }
-80
-81 @Override
-82 public HttpMethod getMethod()
-83 {
-84 return method;
-85 }
-86
-87 @Override
-88 public URI getURI()
-89 {
-90 return uri;
-91 }
-92
-93 @Override
-94 public HttpHeaders getHeaders()
-95 {
-96 return headers;
-97 }
-98
-99 @Override
-100 public OutputStream getBody() throws IOException
-101 {
-102 throw new UnsupportedOperationException("Not supported yet.");
-103 }
-104 }
-105
-106
-107 class MockClientHttpResponse implements ClientHttpResponse
-108 {
-109 @Override
-110 public HttpStatus getStatusCode() throws IOException
-111 {
-112 return status;
-113 }
-114
-115 @Override
-116 public int getRawStatusCode() throws IOException
-117 {
-118 return status.value();
-119 }
-120
-121 @Override
-122 public String getStatusText() throws IOException
-123 {
-124 return status.getReasonPhrase();
-125 }
-126
-127 @Override
-128 public void close()
-129 {
-130 }
-131
-132 @Override
-133 public InputStream getBody() throws IOException
-134 {
-135 return new ByteArrayInputStream(body.getBytes(StandardCharsets.UTF_8));
-136 }
-137
-138 @Override
-139 public HttpHeaders getHeaders()
-140 {
-141 return headers;
-142 }
-143 }
-144 }
-
-
-
-
-
diff --git a/dist/facebook-utils-2.5.0/xref-test/de/juplo/facebook/client/package-frame.html b/dist/facebook-utils-2.5.0/xref-test/de/juplo/facebook/client/package-frame.html
deleted file mode 100644
index e64b90a6..00000000
--- a/dist/facebook-utils-2.5.0/xref-test/de/juplo/facebook/client/package-frame.html
+++ /dev/null
@@ -1,36 +0,0 @@
-
-
-
-
-
-
- de.juplo.facebook.client
-
-
- Classes
-
-
-
-
-
-
\ No newline at end of file
diff --git a/dist/facebook-utils-2.5.0/xref-test/de/juplo/facebook/client/package-summary.html b/dist/facebook-utils-2.5.0/xref-test/de/juplo/facebook/client/package-summary.html
deleted file mode 100644
index e79e2df3..00000000
--- a/dist/facebook-utils-2.5.0/xref-test/de/juplo/facebook/client/package-summary.html
+++ /dev/null
@@ -1,89 +0,0 @@
-
-
-
-
-
-
-
- Package de.juplo.facebook.client
-
-
-
-
-
-
-
-
-
- Class Summary
-
-
-
- GraphApiErrorHandlerTest
-
-
-
-
- MockClientHttpRequest
-
-
-
-
- MockClientHttpRequestFactory
-
-
-
-
- MockClientHttpResponse
-
-
-
-
-
- SOME
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/dist/facebook-utils-2.5.0/xref-test/de/juplo/facebook/exceptions/FacebookErrorMessageMappingTest.html b/dist/facebook-utils-2.5.0/xref-test/de/juplo/facebook/exceptions/FacebookErrorMessageMappingTest.html
deleted file mode 100644
index c1045c49..00000000
--- a/dist/facebook-utils-2.5.0/xref-test/de/juplo/facebook/exceptions/FacebookErrorMessageMappingTest.html
+++ /dev/null
@@ -1,72 +0,0 @@
-
-
-
-
-1 package de.juplo.facebook.exceptions;
-2
-3 import com.fasterxml.jackson.core.JsonProcessingException;
-4 import de.juplo.facebook.exceptions.GraphApiException.FacebookErrorMessage;
-5 import static de.juplo.facebook.exceptions.GraphApiException.OBJECT_MAPPER;
-6 import de.juplo.facebook.exceptions.GraphApiException.Type;
-7 import java.io.IOException;
-8 import org.junit.Test;
-9 import static org.junit.Assert.assertEquals;
-10
-11 /**
-12 * @author Kai Moritz
-13 */
-14 public class FacebookErrorMessageMappingTest
-15 {
-16 final String example =
-17 "{" +
-18 "\"error\":{" +
-19 "\"message\":\"Message describing the error\"," +
-20 "\"type\":\"OAuthException\"," +
-21 "\"code\":190," +
-22 "\"error_subcode\":460," +
-23 "\"error_user_title\":\"A title\"," +
-24 "\"error_user_msg\":\"A message\"," +
-25 "\"fbtrace_id\":\"EJplcsCHuLu\"" +
-26 "}" +
-27 "}";
-28
-29
-30 @Test
-31 public void testSerialize() throws JsonProcessingException
-32 {
-33 FacebookErrorMessage error = new FacebookErrorMessage();
-34 error.message = "Message describing the error";
-35 error.type = Type.OAuthException.name();
-36 error.code = 190;
-37 error.subCode = 460;
-38 error.userTitle = "A title";
-39 error.userMessage = "A message";
-40 error.traceId = "EJplcsCHuLu";
-41
-42 assertEquals(example, OBJECT_MAPPER.writeValueAsString(error));
-43 }
-44
-45 @Test
-46 public void testDeserialize() throws IOException
-47 {
-48 FacebookErrorMessage error =
-49 OBJECT_MAPPER.readValue(example, FacebookErrorMessage.class);
-50
-51 assertEquals("Message describing the error", error.message);
-52 assertEquals(Type.OAuthException.name(), error.type);
-53 assertEquals(new Integer(190), error.code);
-54 assertEquals(new Integer(460), error.subCode);
-55 assertEquals("A title", error.userTitle);
-56 assertEquals("A message", error.userMessage);
-57 assertEquals("EJplcsCHuLu", error.traceId);
-58 }
-59 }
-
-
-
-
-
diff --git a/dist/facebook-utils-2.5.0/xref-test/de/juplo/facebook/exceptions/package-frame.html b/dist/facebook-utils-2.5.0/xref-test/de/juplo/facebook/exceptions/package-frame.html
deleted file mode 100644
index dc1cac60..00000000
--- a/dist/facebook-utils-2.5.0/xref-test/de/juplo/facebook/exceptions/package-frame.html
+++ /dev/null
@@ -1,24 +0,0 @@
-
-
-
-
-
-
- de.juplo.facebook.exceptions
-
-
- Classes
-
-
-
-
-
-
\ No newline at end of file
diff --git a/dist/facebook-utils-2.5.0/xref-test/de/juplo/facebook/exceptions/package-summary.html b/dist/facebook-utils-2.5.0/xref-test/de/juplo/facebook/exceptions/package-summary.html
deleted file mode 100644
index 6a6c3db3..00000000
--- a/dist/facebook-utils-2.5.0/xref-test/de/juplo/facebook/exceptions/package-summary.html
+++ /dev/null
@@ -1,69 +0,0 @@
-
-
-
-
-
-
-
- Package de.juplo.facebook.exceptions
-
-
-
-
-
-
-
-
-
- Class Summary
-
-
-
-
- FacebookErrorMessageMappingTest
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/dist/facebook-utils-2.5.0/xref-test/index.html b/dist/facebook-utils-2.5.0/xref-test/index.html
deleted file mode 100644
index 36b3a730..00000000
--- a/dist/facebook-utils-2.5.0/xref-test/index.html
+++ /dev/null
@@ -1,25 +0,0 @@
-
-
-
-
-
-
- Frame Alert
-
- All Classes
-
-
- Packages
-
-
-
-
-
-
-
diff --git a/dist/facebook-utils-2.5.0/xref-test/overview-summary.html b/dist/facebook-utils-2.5.0/xref-test/overview-summary.html
deleted file mode 100644
index 3786f849..00000000
--- a/dist/facebook-utils-2.5.0/xref-test/overview-summary.html
+++ /dev/null
@@ -1,71 +0,0 @@
-
-
-
-
-
-
-
- Juplo - Facebook Utils 2.5.0 Reference
-
-
-
-
-
-
-
-
-
- Packages
-
-
-
- de.juplo.facebook.client
-
-
-
-
-
- de.juplo.facebook.exceptions
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/dist/facebook-utils-2.5.0/xref-test/stylesheet.css b/dist/facebook-utils-2.5.0/xref-test/stylesheet.css
deleted file mode 100644
index 89732f81..00000000
--- a/dist/facebook-utils-2.5.0/xref-test/stylesheet.css
+++ /dev/null
@@ -1,114 +0,0 @@
-/* Javadoc style sheet */
-/* Define colors, fonts and other style attributes here to override the defaults */
-body {
- background-color: #fff;
- font-family: Arial, Helvetica, sans-serif;
-}
-
-a:link {
- color: #00f;
-}
-a:visited {
- color: #00a;
-}
-
-a:active, a:hover {
- color: #f30 !important;
-}
-
-ul, li {
- list-style-type:none;
- margin:0;
- padding:0;
-}
-
-table td {
- padding: 3px;
- border: 1px solid #000;
-}
-table {
- width:100%;
- border: 1px solid #000;
- border-collapse: collapse;
-}
-
-div.overview {
- background-color:#ddd;
- padding: 4px 4px 4px 0;
-}
-div.overview li, div.framenoframe li {
- display: inline;
-}
-div.framenoframe {
- text-align: center;
- font-size: x-small;
-}
-div.framenoframe li {
- margin: 0 3px 0 3px;
-}
-div.overview li {
- margin:3px 3px 0 3px;
- padding: 4px;
-}
-li.selected {
- background-color:#888;
- color: #fff;
- font-weight: bold;
-}
-
-table.summary {
- margin-bottom: 20px;
-}
-table.summary td, table.summary th {
- font-weight: bold;
- text-align: left;
- padding: 3px;
-}
-table.summary th {
- background-color:#036;
- color: #fff;
-}
-table.summary td {
- background-color:#eee;
- border: 1px solid black;
-}
-
-em {
- color: #A00;
-}
-em.comment {
- color: #390;
-}
-.string {
- color: #009;
-}
-
-#overview {
- padding:2px;
-}
-
-hr {
- height: 1px;
- color: #000;
-}
-
-/* JXR style sheet */
-.jxr_comment
-{
- color: #390;
-}
-
-.jxr_javadoccomment
-{
- color: #A00;
-}
-
-.jxr_string
-{
- color: #009;
-}
-
-.jxr_keyword
-{
- color: #000;
-}
diff --git a/dist/facebook-utils-2.5.0/xref/allclasses-frame.html b/dist/facebook-utils-2.5.0/xref/allclasses-frame.html
deleted file mode 100644
index ffacff13..00000000
--- a/dist/facebook-utils-2.5.0/xref/allclasses-frame.html
+++ /dev/null
@@ -1,71 +0,0 @@
-
-
-
-
-
- All Classes
-
-
-
-
-
-
diff --git a/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/FacebookUtils.html b/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/FacebookUtils.html
deleted file mode 100644
index d74a8692..00000000
--- a/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/FacebookUtils.html
+++ /dev/null
@@ -1,119 +0,0 @@
-
-
-
-
-1 package de.juplo.facebook;
-2
-3
-4 import de.juplo.facebook.token.SignedRequestAwareAuthorizationCodeAccessTokenProvider;
-5 import de.juplo.facebook.client.GraphApiErrorHandler;
-6 import java.util.Arrays;
-7 import java.util.LinkedList;
-8 import java.util.List;
-9 import javax.annotation.PostConstruct;
-10 import org.slf4j.Logger;
-11 import org.slf4j.LoggerFactory;
-12 import org.springframework.beans.BeansException;
-13 import org.springframework.beans.factory.annotation.Autowired;
-14 import org.springframework.beans.factory.config.BeanPostProcessor;
-15 import org.springframework.context.annotation.Bean;
-16 import org.springframework.context.annotation.Configuration;
-17 import org.springframework.security.oauth2.client.OAuth2RestTemplate;
-18 import org.springframework.security.oauth2.client.http.OAuth2ErrorHandler;
-19 import org.springframework.security.oauth2.client.token.AccessTokenProvider;
-20 import org.springframework.security.oauth2.client.token.AccessTokenProviderChain;
-21 import org.springframework.security.oauth2.client.token.grant.client.ClientCredentialsAccessTokenProvider;
-22 import org.springframework.security.oauth2.client.token.grant.implicit.ImplicitAccessTokenProvider;
-23 import org.springframework.security.oauth2.client.token.grant.password.ResourceOwnerPasswordAccessTokenProvider;
-24
-25
-26
-27 /**
-28 * This class injects the facebook-utils into the spring-oauth2-configuration
-29 *
-30 * @author kai
-31 */
-32 @Configuration
-33 public class FacebookUtils
-34 {
-35 private final Logger log = LoggerFactory.getLogger(FacebookUtils.class);
-36
-37
-38 @Autowired(required=false)
-39 private List<AccessTokenProvider> accessTokenProviderChain;
-40
-41
-42 @PostConstruct
-43 public void init()
-44 {
-45 if (accessTokenProviderChain == null)
-46 {
-47 log.info("no AccessTokenProviderChain configured, creating default-chain");
-48 accessTokenProviderChain =
-49 Arrays.<AccessTokenProvider> asList(
-50 new ImplicitAccessTokenProvider(),
-51 new ResourceOwnerPasswordAccessTokenProvider(),
-52 new ClientCredentialsAccessTokenProvider()
-53 );
-54 }
-55 }
-56
-57
-58 @Bean
-59 public BeanPostProcessor getBeanPostProcessor(final String clientSecret)
-60 {
-61 log.debug("createing new instance of BeanPostProcessor");
-62 return new BeanPostProcessor() {
-63
-64 @Override
-65 public Object postProcessBeforeInitialization(
-66 Object bean,
-67 String beanName
-68 )
-69 throws
-70 BeansException
-71 {
-72 if (bean instanceof OAuth2RestTemplate)
-73 {
-74 log.info("injecting signed_request-aware AccessTokenProviderChain");
-75 OAuth2RestTemplate template = (OAuth2RestTemplate)bean;
-76 List<AccessTokenProvider> chain =
-77 new LinkedList<>(accessTokenProviderChain);
-78 SignedRequestAwareAuthorizationCodeAccessTokenProvider provider =
-79 new SignedRequestAwareAuthorizationCodeAccessTokenProvider();
-80 provider.setSecret(clientSecret);
-81 chain.add(provider);
-82 template.setAccessTokenProvider(new AccessTokenProviderChain(chain));
-83 log.info("injecting GraphApiErrorHandler");
-84 template.setErrorHandler(
-85 new GraphApiErrorHandler(
-86 (OAuth2ErrorHandler)template.getErrorHandler()
-87 )
-88 );
-89 }
-90
-91 return bean;
-92 }
-93
-94 @Override
-95 public Object postProcessAfterInitialization(
-96 Object bean,
-97 String beanName
-98 )
-99 throws
-100 BeansException
-101 {
-102 return bean;
-103 }
-104 };
-105 }
-106 }
-
-
-
-
-
diff --git a/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/aspects/Sanitize.html b/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/aspects/Sanitize.html
deleted file mode 100644
index fa6cead3..00000000
--- a/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/aspects/Sanitize.html
+++ /dev/null
@@ -1,31 +0,0 @@
-
-
-
-
-1 package de.juplo.facebook.aspects;
-2
-3
-4 import java.lang.annotation.ElementType;
-5 import java.lang.annotation.Retention;
-6 import java.lang.annotation.RetentionPolicy;
-7 import java.lang.annotation.Target;
-8
-9 /**
-10 * @author Kai Moritz
-11 */
-12 @Target({ ElementType.FIELD })
-13 @Retention(RetentionPolicy.RUNTIME)
-14 public @interface Sanitize
-15 {
-16 int length() default 255; // in accordance to @Column(length)
-17 boolean fail() default false;
-18 }
-
-
-
-
-
diff --git a/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/aspects/SanitizeAspect.html b/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/aspects/SanitizeAspect.html
deleted file mode 100644
index dcb6204c..00000000
--- a/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/aspects/SanitizeAspect.html
+++ /dev/null
@@ -1,106 +0,0 @@
-
-
-
-
-1 package de.juplo.facebook.aspects;
-2
-3
-4 import org.aspectj.lang.ProceedingJoinPoint;
-5 import org.aspectj.lang.annotation.Around;
-6 import org.aspectj.lang.annotation.Aspect;
-7 import org.slf4j.Logger;
-8 import org.slf4j.LoggerFactory;
-9
-10
-11
-12 /**
-13 * @author Kai Moritz
-14 */
-15 @Aspect
-16 public class SanitizeAspect
-17 {
-18 private static final Logger log =
-19 LoggerFactory.getLogger(SanitizeAspect.class);
-20
-21
-22 /**
-23 * This method sanitizes the given string in all means:
-24 * <ul>
-25 * <li>It removes leading and trailing whitspace.</li>
-26 * <li>It removes characters, that are not allowed in the XML-output</li>
-27 * <li>It checks the allowed length of the string</li>
-28 * </ul>
-29 *
-30 * This method ensures that the output String has only
-31 * valid XML unicode characters as specified by the
-32 * XML 1.0 standard. For reference, please see
-33 * <a href="http://www.w3.org/TR/2000/REC-xml-20001006#NT-Char">the
-34 * standard</a>. This method will return an empty
-35 * String if the input is null or empty.
-36 *
-37 * @param jp The join-point captured by AspectJ.
-38 * @param in The String whose non-valid characters we want to remove.
-39 * @param sanitize The annotation, the field was marked with.
-40 * @see <a href="http://blog.mark-mclaren.info/2007/02/invalid-xml-characters-when-valid-utf8_5873.html">Invalid XML Characters: when valid UTF8 does not mean valid XML</a>
-41 * @see <a href="http://up-download.de/up/docs/werkstatt/de/intrexx-werkstatt-ungueltige-zeichen-in-eingabefeldern-abfangen.pdf">Ungültige Zeichen in Eingabefeldern abfangen</a>
-42 */
-43 @Around("set(String *) && args(in) && @annotation(sanitize)")
-44 public void sanitize(
-45 ProceedingJoinPoint jp,
-46 String in,
-47 Sanitize sanitize
-48 )
-49 throws Throwable
-50 {
-51 if (in == null)
-52 {
-53 jp.proceed(new Object[] { null });
-54 return;
-55 }
-56
-57 in = in.trim();
-58 if ("".equals(in))
-59 {
-60 jp.proceed(new Object[] { null });
-61 return;
-62 }
-63
-64 StringBuilder out = new StringBuilder(); // Used to hold the output.
-65 char current; // Used to reference the current character.
-66
-67 for (int i = 0; i < in.length(); i++)
-68 {
-69 current = in.charAt(i); // NOTE: No IndexOutOfBoundsException caught here; it should not happen.
-70 if ((current == 0x9) ||
-71 (current == 0xA) ||
-72 (current == 0xD) ||
-73 ((current >= 0x20) && (current <= 0xD7FF)) ||
-74 ((current >= 0xE000) && (current <= 0xFFFD)) ||
-75 ((current >= 0x10000) && (current <= 0x10FFFF)))
-76 out.append(current);
-77 }
-78 if (out.length() > sanitize.length())
-79 {
-80 log.error(
-81 "Maximum length for attribute {} exceeded: should={}, was={}",
-82 jp.getSignature().getName(),
-83 sanitize.length(),
-84 out.length()
-85 );
-86 if (sanitize.fail())
-87 throw new RuntimeException("String is longer than " + sanitize.length());
-88 else
-89 out.setLength(sanitize.length());
-90 }
-91 jp.proceed(new Object[] { out.toString() });
-92 }
-93 }
-
-
-
-
-
diff --git a/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/aspects/package-frame.html b/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/aspects/package-frame.html
deleted file mode 100644
index f45995a5..00000000
--- a/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/aspects/package-frame.html
+++ /dev/null
@@ -1,27 +0,0 @@
-
-
-
-
-
-
- de.juplo.facebook.aspects
-
-
- Classes
-
-
-
-
-
-
\ No newline at end of file
diff --git a/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/aspects/package-summary.html b/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/aspects/package-summary.html
deleted file mode 100644
index 05572828..00000000
--- a/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/aspects/package-summary.html
+++ /dev/null
@@ -1,74 +0,0 @@
-
-
-
-
-
-
-
- Package de.juplo.facebook.aspects
-
-
-
-
-
-
-
-
-
- Class Summary
-
-
-
- Sanitize
-
-
-
-
-
- SanitizeAspect
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/client/GraphApiErrorHandler.html b/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/client/GraphApiErrorHandler.html
deleted file mode 100644
index 4fd52fca..00000000
--- a/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/client/GraphApiErrorHandler.html
+++ /dev/null
@@ -1,153 +0,0 @@
-
-
-
-
-1 package de.juplo.facebook.client;
-2
-3 import de.juplo.facebook.exceptions.GraphApiException;
-4 import java.io.ByteArrayInputStream;
-5 import java.io.IOException;
-6 import java.io.InputStream;
-7 import java.nio.charset.Charset;
-8 import org.slf4j.Logger;
-9 import org.slf4j.LoggerFactory;
-10 import org.springframework.http.HttpHeaders;
-11 import org.springframework.http.HttpStatus;
-12 import org.springframework.http.client.ClientHttpResponse;
-13 import org.springframework.util.FileCopyUtils;
-14 import org.springframework.web.client.ResponseErrorHandler;
-15
-16
-17
-18 /**
-19 * Error-Handler for error-messages from the Facebook Graph-API.
-20 * <p>
-21 * This error-handler handels responses withe the HTTP-status code
-22 * {@code 400 BAD REQUEST}. It tries to extract and parse the error-message
-23 * from the HTTP-body. Successfully extracted and parsed messages are mapped
-24 * to a hierarchy of exceptions, that reflects the hierarchy of the error-
-25 * codes and -types.
-26 * <p>
-27 * If the HTTP-status-code of the response is not {@code 400 BAD REQUEST} or
-28 * the HTTP-body could not be extracted or parsed, this error-handler
-29 * delegates the handling to its parent.
-30 *
-31 * @see <a href="https://developers.facebook.com/docs/graph-api/using-graph-api/v2.5#errors">Graph-API Documentation</a>
-32 * @see <a href="http://fbdevwiki.com/wiki/Error_codes">Inofficial Wiki For Facebook-Developers</a>
-33 * @author Kai Moritz
-34 */
-35 public class GraphApiErrorHandler implements ResponseErrorHandler
-36 {
-37 private final static Logger LOG =
-38 LoggerFactory.getLogger(GraphApiErrorHandler.class);
-39
-40 private final ResponseErrorHandler parent;
-41
-42
-43 public GraphApiErrorHandler(ResponseErrorHandler errorHandler)
-44 {
-45 this.parent = errorHandler;
-46 }
-47
-48
-49 @Override
-50 public boolean hasError(ClientHttpResponse response) throws IOException
-51 {
-52 return
-53 HttpStatus.Series.CLIENT_ERROR.equals(response.getStatusCode().series())
-54 || this.parent.hasError(response);
-55 }
-56
-57 @Override
-58 public void handleError(final ClientHttpResponse response) throws IOException
-59 {
-60 if (!HttpStatus.BAD_REQUEST.equals(response.getStatusCode()))
-61 {
-62 // We will only handle 400 BAD REQUEST
-63 LOG.debug("ignoring response with status-code {}.", response.getStatusCode());
-64 parent.handleError(response);
-65 return;
-66 }
-67
-68
-69 if (response.getBody() == null)
-70 {
-71 // There is no body to interpret in the HTTP-message
-72 LOG.warn("Could not convert the response into an exception, because there is no message-body.");
-73 parent.handleError(response);
-74 return;
-75 }
-76
-77 final byte[] body = FileCopyUtils.copyToByteArray(response.getBody());
-78 GraphApiException error;
-79
-80 try
-81 {
-82 error = GraphApiException.create(body);
-83 if (LOG.isInfoEnabled())
-84 LOG.info("error-response: {}", new String(body, Charset.forName("UTF-8")));
-85 }
-86 catch (Exception e)
-87 {
-88 // The body of the HTTP-message could not be parsed.
-89 // Let the parent error-handler try to handle the response.
-90
-91 LOG.warn("Could not convert the response into an exception, because the body is unparsable: {}", body);
-92
-93 // To do so, we have to wrap the original response to fill in
-94 // the buffered body, if needed
-95 ClientHttpResponse buffered = new ClientHttpResponse()
-96 {
-97 @Override
-98 public HttpStatus getStatusCode() throws IOException
-99 {
-100 return response.getStatusCode();
-101 }
-102
-103 @Override
-104 public synchronized InputStream getBody() throws IOException
-105 {
-106 return new ByteArrayInputStream(body);
-107 }
-108
-109 @Override
-110 public HttpHeaders getHeaders()
-111 {
-112 return response.getHeaders();
-113 }
-114
-115 @Override
-116 public String getStatusText() throws IOException
-117 {
-118 return response.getStatusText();
-119 }
-120
-121 @Override
-122 public void close()
-123 {
-124 response.close();
-125 }
-126
-127 @Override
-128 public int getRawStatusCode() throws IOException
-129 {
-130 return response.getRawStatusCode();
-131 }
-132 };
-133
-134 parent.handleError(buffered);
-135 return;
-136 }
-137
-138 throw error;
-139 }
-140 }
-
-
-
-
-
diff --git a/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/client/package-frame.html b/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/client/package-frame.html
deleted file mode 100644
index 60af1449..00000000
--- a/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/client/package-frame.html
+++ /dev/null
@@ -1,24 +0,0 @@
-
-
-
-
-
-
- de.juplo.facebook.client
-
-
- Classes
-
-
-
-
-
-
\ No newline at end of file
diff --git a/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/client/package-summary.html b/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/client/package-summary.html
deleted file mode 100644
index f9a25b26..00000000
--- a/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/client/package-summary.html
+++ /dev/null
@@ -1,69 +0,0 @@
-
-
-
-
-
-
-
- Package de.juplo.facebook.client
-
-
-
-
-
-
-
-
-
- Class Summary
-
-
-
-
- GraphApiErrorHandler
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/exceptions/AccessTokenRequiredException.html b/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/exceptions/AccessTokenRequiredException.html
deleted file mode 100644
index ad216fd7..00000000
--- a/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/exceptions/AccessTokenRequiredException.html
+++ /dev/null
@@ -1,31 +0,0 @@
-
-
-
-
-1 package de.juplo.facebook.exceptions;
-2
-3
-4 import de.juplo.facebook.exceptions.GraphApiException.FacebookErrorMessage;
-5
-6
-7
-8 /**
-9 * 104: An access token is required to request this resource.
-10 * @author Kai Moritz
-11 */
-12 public class AccessTokenRequiredException extends OAuthException
-13 {
-14 protected AccessTokenRequiredException(FacebookErrorMessage error)
-15 {
-16 super(error);
-17 }
-18 }
-
-
-
-
-
diff --git a/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/exceptions/CallbackVerificationFailedException.html b/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/exceptions/CallbackVerificationFailedException.html
deleted file mode 100644
index 973f1401..00000000
--- a/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/exceptions/CallbackVerificationFailedException.html
+++ /dev/null
@@ -1,27 +0,0 @@
-
-
-
-
-1 package de.juplo.facebook.exceptions;
-2
-3
-4 /**
-5 * 2200: Callback verification failed.
-6 * @author Kai Moritz
-7 */
-8 public class CallbackVerificationFailedException extends OAuthException
-9 {
-10 protected CallbackVerificationFailedException(FacebookErrorMessage error)
-11 {
-12 super(error);
-13 }
-14 }
-
-
-
-
-
diff --git a/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/exceptions/GraphApiException.html b/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/exceptions/GraphApiException.html
deleted file mode 100644
index bfdb4630..00000000
--- a/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/exceptions/GraphApiException.html
+++ /dev/null
@@ -1,186 +0,0 @@
-
-
-
-
-1 package de.juplo.facebook.exceptions;
-2
-3 import com.fasterxml.jackson.annotation.JsonProperty;
-4 import com.fasterxml.jackson.annotation.JsonPropertyOrder;
-5 import com.fasterxml.jackson.annotation.JsonRootName;
-6 import com.fasterxml.jackson.core.JsonParseException;
-7 import com.fasterxml.jackson.core.JsonProcessingException;
-8 import com.fasterxml.jackson.databind.DeserializationFeature;
-9 import com.fasterxml.jackson.databind.JsonMappingException;
-10 import com.fasterxml.jackson.databind.ObjectMapper;
-11 import com.fasterxml.jackson.databind.SerializationFeature;
-12 import java.io.IOException;
-13 import java.io.InputStream;
-14 import org.slf4j.Logger;
-15 import org.slf4j.LoggerFactory;
-16 import org.springframework.security.oauth2.common.exceptions.OAuth2Exception;
-17
-18 /**
-19 * Base exception for Facebook Graph-Api exceptions.
-20 *
-21 * @author Kai Moritz
-22 */
-23 public class GraphApiException extends OAuth2Exception
-24 {
-25 public enum Type { OAuthException, GraphMethodException }
-26
-27
-28 final static Logger LOG = LoggerFactory.getLogger(GraphApiException.class);
-29 final static ObjectMapper OBJECT_MAPPER;
-30
-31 private final FacebookErrorMessage error;
-32
-33
-34 static
-35 {
-36 OBJECT_MAPPER = new ObjectMapper();
-37 OBJECT_MAPPER.configure(DeserializationFeature.UNWRAP_ROOT_VALUE, true);
-38 OBJECT_MAPPER.configure(DeserializationFeature.ACCEPT_FLOAT_AS_INT, false);
-39 OBJECT_MAPPER.configure(SerializationFeature.WRAP_ROOT_VALUE, true);
-40 }
-41
-42
-43 public static GraphApiException create(InputStream in)
-44 throws
-45 IOException,
-46 JsonParseException,
-47 JsonMappingException
-48 {
-49 return create(OBJECT_MAPPER.readValue(in, FacebookErrorMessage.class));
-50 }
-51
-52 public static GraphApiException create(byte[] message)
-53 throws
-54 IOException,
-55 JsonParseException,
-56 JsonMappingException
-57 {
-58 return create(OBJECT_MAPPER.readValue(message, FacebookErrorMessage.class));
-59 }
-60
-61 public static GraphApiException create(FacebookErrorMessage error)
-62 {
-63 // see: http://fbdevwiki.com/wiki/Error_codes
-64 switch(error.code)
-65 {
-66 // 1..99: general errors
-67 case 1: return new UnknownErrorException(error);
-68 case 2: return new UnexpectedErrorException(error);
-69 case 21: return new PageMigratedException(error);
-70 // 100..199: graph method errors
-71 case 100: return new UnsupportedGetRequestException(error);
-72 case 104: return new AccessTokenRequiredException(error);
-73 // 200..299: permission errors
-74 // 300..399: data editing errors
-75 // 400..449: authentication error
-76 // 450..499: session errors
-77 // 500..599: application messaging errors
-78 // 600..699: FQL errors
-79 case 613: return new RateExceededException(error);
-80 // 700..749: ref errors
-81 // 750..799: application integration errors
-82 // 900..949: application information errors
-83 // 950..999: batch api errors
-84 // 1000..1099: event api errors
-85 // 1100..1199: live-message errors
-86 case 2200: return new CallbackVerificationFailedException(error);
-87
-88 default:
-89 LOG.info("unmapped error: {}", error);
-90 return new UnmappedErrorException(error);
-91 }
-92 }
-93
-94
-95 protected GraphApiException(FacebookErrorMessage error)
-96 {
-97 super(error.message);
-98 this.error = error;
-99 }
-100
-101
-102 public Type getType()
-103 {
-104 return error.type == null ? null : Type.valueOf(error.type);
-105 }
-106
-107 public Integer getCode()
-108 {
-109 return error.code;
-110 }
-111
-112 public Integer getSubCode()
-113 {
-114 return error.subCode;
-115 }
-116
-117 public String getUserTitle()
-118 {
-119 return error.userTitle;
-120 }
-121
-122 public String getUserMessage()
-123 {
-124 return error.userMessage;
-125 }
-126
-127 public String getTraceId()
-128 {
-129 return error.traceId;
-130 }
-131
-132
-133 @Override
-134 public String toString()
-135 {
-136 try
-137 {
-138 return OBJECT_MAPPER.writeValueAsString(error);
-139 }
-140 catch(JsonProcessingException e)
-141 {
-142 // This should never happen. But in case of a mistake: be verbose!
-143 LOG.error("could not convert message into JSON: {}", e);
-144 return e.getMessage();
-145 }
-146 }
-147
-148
-149 /**
-150 * This class represents an error message from the Graph-API
-151 *
-152 * @see <a href="https://developers.facebook.com/docs/graph-api/using-graph-api/v2.5#errors">Graph-API Documentation</a>
-153 */
-154 @JsonRootName("error")
-155 @JsonPropertyOrder({ "message", "type", "code", "error_subcode", "error_user_title", "error_user_msg", "fbtrace_id" })
-156 public static class FacebookErrorMessage
-157 {
-158 @JsonProperty("message")
-159 String message;
-160 @JsonProperty("type")
-161 String type;
-162 @JsonProperty("code")
-163 Integer code;
-164 @JsonProperty("error_subcode")
-165 Integer subCode;
-166 @JsonProperty("error_user_title")
-167 String userTitle;
-168 @JsonProperty("error_user_msg")
-169 String userMessage;
-170 @JsonProperty("fbtrace_id")
-171 String traceId;
-172 }
-173 }
-
-
-
-
-
diff --git a/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/exceptions/GraphMethodException.html b/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/exceptions/GraphMethodException.html
deleted file mode 100644
index bed2930e..00000000
--- a/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/exceptions/GraphMethodException.html
+++ /dev/null
@@ -1,27 +0,0 @@
-
-
-
-
-1 package de.juplo.facebook.exceptions;
-2
-3
-4 /**
-5 * Baseclass for exceptions of type {@code GraphMethodException}.
-6 * @author Kai Moritz
-7 */
-8 public abstract class GraphMethodException extends GraphApiException
-9 {
-10 GraphMethodException(FacebookErrorMessage error)
-11 {
-12 super(error);
-13 }
-14 }
-
-
-
-
-
diff --git a/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/exceptions/OAuthException.html b/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/exceptions/OAuthException.html
deleted file mode 100644
index bbb6ea2c..00000000
--- a/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/exceptions/OAuthException.html
+++ /dev/null
@@ -1,31 +0,0 @@
-
-
-
-
-1 package de.juplo.facebook.exceptions;
-2
-3
-4 import de.juplo.facebook.exceptions.GraphApiException.FacebookErrorMessage;
-5
-6
-7
-8 /**
-9 * Baseclass for exceptions of type {@code OAuthException}.
-10 * @author Kai Moritz
-11 */
-12 public class OAuthException extends GraphApiException
-13 {
-14 protected OAuthException(FacebookErrorMessage error)
-15 {
-16 super(error);
-17 }
-18 }
-
-
-
-
-
diff --git a/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/exceptions/PageMigratedException.html b/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/exceptions/PageMigratedException.html
deleted file mode 100644
index ee492adb..00000000
--- a/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/exceptions/PageMigratedException.html
+++ /dev/null
@@ -1,58 +0,0 @@
-
-
-
-
-1 package de.juplo.facebook.exceptions;
-2
-3
-4 import java.util.regex.Matcher;
-5 import java.util.regex.Pattern;
-6
-7
-8
-9 /**
-10 * 21: Page ID (XXX) was migrated to page ID (YYY).
-11 * @author Kai Moritz
-12 */
-13 public class PageMigratedException extends OAuthException
-14 {
-15 private final static Pattern pattern =
-16 Pattern.compile("Page ID ([0-9]+) was migrated to page ID ([0-9]+)");
-17
-18 private final Long oldId, newId;
-19
-20
-21 protected PageMigratedException(FacebookErrorMessage error)
-22 {
-23 super(error);
-24 Matcher matcher = pattern.matcher(error.message);
-25 if (!matcher.find())
-26 {
-27 String warning = "Could not parse migration-error: " + error.message;
-28 LOG.error(warning);
-29 throw new RuntimeException(warning);
-30 }
-31 oldId = Long.parseLong(matcher.group(1));
-32 newId = Long.parseLong(matcher.group(2));
-33 }
-34
-35
-36 public Long getOldId()
-37 {
-38 return oldId;
-39 }
-40
-41 public Long getNewId()
-42 {
-43 return newId;
-44 }
-45 }
-
-
-
-
-
diff --git a/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/exceptions/RateExceededException.html b/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/exceptions/RateExceededException.html
deleted file mode 100644
index 7e59b91d..00000000
--- a/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/exceptions/RateExceededException.html
+++ /dev/null
@@ -1,27 +0,0 @@
-
-
-
-
-1 package de.juplo.facebook.exceptions;
-2
-3
-4 /**
-5 * 613: Calls to stream have exceeded the rate of 600 calls per 600 seconds.
-6 * @author Kai Moritz
-7 */
-8 public class RateExceededException extends OAuthException
-9 {
-10 protected RateExceededException(FacebookErrorMessage error)
-11 {
-12 super(error);
-13 }
-14 }
-
-
-
-
-
diff --git a/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/exceptions/UnexpectedErrorException.html b/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/exceptions/UnexpectedErrorException.html
deleted file mode 100644
index 7e6efeb6..00000000
--- a/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/exceptions/UnexpectedErrorException.html
+++ /dev/null
@@ -1,31 +0,0 @@
-
-
-
-
-1 package de.juplo.facebook.exceptions;
-2
-3
-4 import de.juplo.facebook.exceptions.GraphApiException.FacebookErrorMessage;
-5
-6
-7
-8 /**
-9 * 2: An unexpected error has occurred.
-10 * @author Kai Moritz
-11 */
-12 public class UnexpectedErrorException extends OAuthException
-13 {
-14 protected UnexpectedErrorException(FacebookErrorMessage error)
-15 {
-16 super(error);
-17 }
-18 }
-
-
-
-
-
diff --git a/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/exceptions/UnknownErrorException.html b/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/exceptions/UnknownErrorException.html
deleted file mode 100644
index d3a5306e..00000000
--- a/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/exceptions/UnknownErrorException.html
+++ /dev/null
@@ -1,31 +0,0 @@
-
-
-
-
-1 package de.juplo.facebook.exceptions;
-2
-3
-4 import de.juplo.facebook.exceptions.GraphApiException.FacebookErrorMessage;
-5
-6
-7
-8 /**
-9 * 1: An unknown error has occurred.
-10 * @author Kai Moritz
-11 */
-12 public class UnknownErrorException extends OAuthException
-13 {
-14 protected UnknownErrorException(FacebookErrorMessage error)
-15 {
-16 super(error);
-17 }
-18 }
-
-
-
-
-
diff --git a/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/exceptions/UnmappedErrorException.html b/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/exceptions/UnmappedErrorException.html
deleted file mode 100644
index 9335db81..00000000
--- a/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/exceptions/UnmappedErrorException.html
+++ /dev/null
@@ -1,30 +0,0 @@
-
-
-
-
-1 package de.juplo.facebook.exceptions;
-2
-3
-4 /**
-5 * Marker class for error-messages, that are not mapped yet.
-6 * Pleas help us to complete the list of possible errors and report errors,
-7 * that are mapped to this class to info@juplo.de. Thanxs!
-8 *
-9 * @author Kai Moritz
-10 */
-11 public class UnmappedErrorException extends GraphApiException
-12 {
-13 protected UnmappedErrorException(FacebookErrorMessage error)
-14 {
-15 super(error);
-16 }
-17 }
-
-
-
-
-
diff --git a/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/exceptions/UnsupportedGetRequestException.html b/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/exceptions/UnsupportedGetRequestException.html
deleted file mode 100644
index 60d23bdf..00000000
--- a/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/exceptions/UnsupportedGetRequestException.html
+++ /dev/null
@@ -1,27 +0,0 @@
-
-
-
-
-1 package de.juplo.facebook.exceptions;
-2
-3
-4 /**
-5 * 100: Unsupported get request.
-6 * @author Kai Moritz
-7 */
-8 public class UnsupportedGetRequestException extends GraphMethodException
-9 {
-10 protected UnsupportedGetRequestException(FacebookErrorMessage error)
-11 {
-12 super(error);
-13 }
-14 }
-
-
-
-
-
diff --git a/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/exceptions/package-frame.html b/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/exceptions/package-frame.html
deleted file mode 100644
index 730d21ae..00000000
--- a/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/exceptions/package-frame.html
+++ /dev/null
@@ -1,60 +0,0 @@
-
-
-
-
-
-
- de.juplo.facebook.exceptions
-
-
- Classes
-
-
-
-
-
-
\ No newline at end of file
diff --git a/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/exceptions/package-summary.html b/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/exceptions/package-summary.html
deleted file mode 100644
index f3063be1..00000000
--- a/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/exceptions/package-summary.html
+++ /dev/null
@@ -1,129 +0,0 @@
-
-
-
-
-
-
-
- Package de.juplo.facebook.exceptions
-
-
-
-
-
-
-
-
-
- Class Summary
-
-
-
- AccessTokenRequiredException
-
-
-
-
- CallbackVerificationFailedException
-
-
-
-
- FacebookErrorMessage
-
-
-
-
- GraphApiException
-
-
-
-
- GraphMethodException
-
-
-
-
- OAuthException
-
-
-
-
- PageMigratedException
-
-
-
-
- RateExceededException
-
-
-
-
- Type
-
-
-
-
- UnexpectedErrorException
-
-
-
-
- UnknownErrorException
-
-
-
-
- UnmappedErrorException
-
-
-
-
-
- UnsupportedGetRequestException
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/package-frame.html b/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/package-frame.html
deleted file mode 100644
index 296b581b..00000000
--- a/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/package-frame.html
+++ /dev/null
@@ -1,24 +0,0 @@
-
-
-
-
-
-
- de.juplo.facebook
-
-
- Classes
-
-
-
-
-
-
\ No newline at end of file
diff --git a/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/package-summary.html b/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/package-summary.html
deleted file mode 100644
index 2a872e9f..00000000
--- a/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/package-summary.html
+++ /dev/null
@@ -1,69 +0,0 @@
-
-
-
-
-
-
-
- Package de.juplo.facebook
-
-
-
-
-
-
-
-
-
- Class Summary
-
-
-
-
- FacebookUtils
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/token/SignedRequestAwareAuthorizationCodeAccessTokenProvider.html b/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/token/SignedRequestAwareAuthorizationCodeAccessTokenProvider.html
deleted file mode 100644
index 5b65226f..00000000
--- a/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/token/SignedRequestAwareAuthorizationCodeAccessTokenProvider.html
+++ /dev/null
@@ -1,261 +0,0 @@
-
-
-
-
-1 package de.juplo.facebook.token;
-2
-3
-4 import java.io.IOException;
-5 import java.io.UnsupportedEncodingException;
-6 import java.security.InvalidKeyException;
-7 import java.security.NoSuchAlgorithmException;
-8 import java.util.Date;
-9 import java.util.HashMap;
-10 import java.util.Map;
-11 import java.util.regex.Matcher;
-12 import java.util.regex.Pattern;
-13 import javax.crypto.Mac;
-14 import javax.crypto.spec.SecretKeySpec;
-15 import org.apache.commons.codec.binary.Base64;
-16 import org.codehaus.jackson.JsonNode;
-17 import org.codehaus.jackson.map.ObjectMapper;
-18 import org.slf4j.Logger;
-19 import org.slf4j.LoggerFactory;
-20 import org.springframework.security.oauth2.client.resource.OAuth2ProtectedResourceDetails;
-21 import org.springframework.security.oauth2.client.resource.UserRedirectRequiredException;
-22 import org.springframework.security.oauth2.client.token.AccessTokenRequest;
-23 import org.springframework.security.oauth2.client.token.grant.code.AuthorizationCodeAccessTokenProvider;
-24 import org.springframework.security.oauth2.common.DefaultOAuth2AccessToken;
-25 import org.springframework.security.oauth2.common.OAuth2AccessToken;
-26
-27
-28 /**
-29 * This class extends {@link AuthorizationCodeAccessTokenProvider} and adds
-30 * support for signed requests, which are issued by Facebook, if the Canvas-
-31 * or Tab-Page of a Facebook-App is accessed for the first time.
-32 *
-33 * @author Kai Moritz
-34 */
-35 public class SignedRequestAwareAuthorizationCodeAccessTokenProvider
-36 extends AuthorizationCodeAccessTokenProvider
-37 {
-38 private final Logger log =
-39 LoggerFactory.getLogger(SignedRequestAwareAuthorizationCodeAccessTokenProvider.class);
-40 private final static Pattern pattern =
-41 Pattern.compile("([a-zA-Z0-9_-]+)\\.([a-zA-Z0-9_-]+)");
-42
-43 public final static String PARAM_SIGNED_REQUEST = "signed_request";
-44
-45
-46 private String secret;
-47 private ObjectMapper objectMapper;
-48
-49
-50 @Override
-51 public OAuth2AccessToken obtainAccessToken(
-52 OAuth2ProtectedResourceDetails details,
-53 AccessTokenRequest parameters
-54 )
-55 {
-56 try
-57 {
-58 return super.obtainAccessToken(details, parameters);
-59 }
-60 catch (UserRedirectRequiredException redirect)
-61 {
-62 log.debug("no valid access-token available: checking for signed request");
-63
-64 if (!parameters.containsKey(PARAM_SIGNED_REQUEST))
-65 {
-66 log.info(
-67 "parameter " + PARAM_SIGNED_REQUEST + " is not present"
-68 );
-69 throw redirect;
-70 }
-71
-72 String signed_request = parameters.get(PARAM_SIGNED_REQUEST).get(0);
-73
-74 Matcher matcher = pattern.matcher(signed_request);
-75 if (!matcher.matches())
-76 {
-77 log.error("invalid signed_request: {}", signed_request);
-78 throw redirect;
-79 }
-80
-81 String signature = matcher.group(1);
-82 String rawdata = matcher.group(2);
-83
-84 String data;
-85 try
-86 {
-87 data = new String(Base64.decodeBase64(rawdata), "UTF-8");
-88 log.debug("JSON-data: {}", data);
-89 }
-90 catch (UnsupportedEncodingException e)
-91 {
-92 log.error("error while decoding data: {}", e.getMessage());
-93 throw redirect;
-94 }
-95
-96 JsonNode json;
-97 try
-98 {
-99 json = objectMapper.readTree(data);
-100 }
-101 catch (IOException e)
-102 {
-103 log.error("error \"{}\" while parsing JSON-data: {}", e, data);
-104 throw redirect;
-105 }
-106
-107 String algorithm = "";
-108 try
-109 {
-110 algorithm = json.get("algorithm").asText();
-111 }
-112 catch (NullPointerException e) {}
-113 if (algorithm.isEmpty())
-114 {
-115 log.error("field \"algorithm\" is missing: {}", data);
-116 throw redirect;
-117 }
-118 algorithm = algorithm.replaceAll("-", "");
-119
-120 String check;
-121 try
-122 {
-123 SecretKeySpec key = new SecretKeySpec(secret.getBytes("UTF-8"), algorithm);
-124 Mac mac = Mac.getInstance(algorithm);
-125 mac.init(key);
-126 byte[] hmacData = mac.doFinal(rawdata.getBytes("UTF-8"));
-127 check = new String(Base64.encodeBase64URLSafe(hmacData), "UTF-8");
-128 }
-129 catch (
-130 UnsupportedEncodingException |
-131 NoSuchAlgorithmException |
-132 InvalidKeyException |
-133 IllegalStateException e
-134 )
-135 {
-136 log.error("signature check failed!", e);
-137 throw redirect;
-138 }
-139 if (!check.equals(signature))
-140 {
-141 log.error("signature does not match!");
-142 throw redirect;
-143 }
-144
-145 /**
-146 * Extract additional information and store it in the token
-147 * See:
-148 * https://developers.facebook.com/docs/reference/login/signed-request/
-149 * TODO:
-150 * - Attribute "code"
-151 */
-152 Map<String,Object> additionalInformation = new HashMap<>();
-153 try
-154 {
-155 additionalInformation.put(
-156 "issued_at",
-157 new Date(json.get("issued_at").getLongValue()*1000L)
-158 );
-159 Map<String,Object> user = new HashMap<>();
-160 user.put(
-161 "country",
-162 json.get("user").get("country").asText()
-163 );
-164 user.put(
-165 "locale",
-166 json.get("user").get("locale").asText()
-167 );
-168 user.put(
-169 "age_min",
-170 json.get("user").get("age").get("min").getNumberValue()
-171 );
-172 if (json.get("user") != null && json.get("user").get("max") != null)
-173 user.put(
-174 "age_max",
-175 json.get("user").get("age").get("max").getNumberValue()
-176 );
-177 additionalInformation.put("user", user);
-178 if (json.get("app_data") != null)
-179 additionalInformation.put("app_data", json.get("app_data").asText());
-180 if (json.get("page") != null)
-181 {
-182 Map<String,Object> page = new HashMap<>();
-183 page.put("id", json.get("page").get("id").asText());
-184 page.put("liked", json.get("page").get("liked").asBoolean());
-185 page.put("admin", json.get("page").get("admin").asBoolean());
-186 additionalInformation.put("page", page);
-187 }
-188 }
-189 catch (NullPointerException e)
-190 {
-191 log.warn("expected additional data is missing: {}", data);
-192 }
-193
-194 DefaultOAuth2AccessToken token = null;
-195 try
-196 {
-197 String value = json.get("oauth_token").asText();
-198 if (value.isEmpty())
-199 {
-200 log.error("field \"oauth_token\" is missing: {}", data);
-201 throw redirect;
-202 }
-203 token = new DefaultOAuth2AccessToken(value);
-204 token.setExpiration(new Date(json.get("expires").getLongValue()*1000L));
-205
-206 additionalInformation.put(
-207 "user_id",
-208 json.get("user_id").asText()
-209 );
-210
-211 token.setAdditionalInformation(additionalInformation);
-212 }
-213 catch (NullPointerException e)
-214 {
-215 if (token == null)
-216 {
-217 log.error("field \"oauth_token\" is missing: {}", data);
-218 throw redirect;
-219 }
-220 else
-221 log.warn("expected additional data is missing: {}", data);
-222 }
-223
-224 return token;
-225 }
-226 }
-227
-228
-229 public String getSecret()
-230 {
-231 return secret;
-232 }
-233
-234 public void setSecret(String secret)
-235 {
-236 this.secret = secret;
-237 }
-238
-239 public ObjectMapper getObjectMapper()
-240 {
-241 return objectMapper;
-242 }
-243
-244 public void setObjectMapper(ObjectMapper objectMapper)
-245 {
-246 this.objectMapper = objectMapper;
-247 }
-248 }
-
-
-
-
-
diff --git a/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/token/package-frame.html b/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/token/package-frame.html
deleted file mode 100644
index e3e290c2..00000000
--- a/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/token/package-frame.html
+++ /dev/null
@@ -1,24 +0,0 @@
-
-
-
-
-
-
- de.juplo.facebook.token
-
-
- Classes
-
-
-
-
-
\ No newline at end of file
diff --git a/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/token/package-summary.html b/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/token/package-summary.html
deleted file mode 100644
index 856bdab8..00000000
--- a/dist/facebook-utils-2.5.0/xref/de/juplo/facebook/token/package-summary.html
+++ /dev/null
@@ -1,69 +0,0 @@
-
-
-
-
-
-
-
- Package de.juplo.facebook.token
-
-
-
-
-
-
-
-
-
- Class Summary
-
-
-
-
- SignedRequestAwareAuthorizationCodeAccessTokenProvider
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/dist/facebook-utils-2.5.0/xref/index.html b/dist/facebook-utils-2.5.0/xref/index.html
deleted file mode 100644
index 36b3a730..00000000
--- a/dist/facebook-utils-2.5.0/xref/index.html
+++ /dev/null
@@ -1,25 +0,0 @@
-
-
-
-
-
-
- Frame Alert
-
- All Classes
-
-
- Packages
-
-
-
-
-
-
-
diff --git a/dist/facebook-utils-2.5.0/xref/overview-summary.html b/dist/facebook-utils-2.5.0/xref/overview-summary.html
deleted file mode 100644
index b204c36c..00000000
--- a/dist/facebook-utils-2.5.0/xref/overview-summary.html
+++ /dev/null
@@ -1,86 +0,0 @@
-
-
-
-
-
-
-
- Juplo - Facebook Utils 2.5.0 Reference
-
-
-
-
-
-
-
-
-
- Packages
-
-
-
- de.juplo.facebook
-
-
-
-
- de.juplo.facebook.aspects
-
-
-
-
- de.juplo.facebook.client
-
-
-
-
- de.juplo.facebook.exceptions
-
-
-
-
-
- de.juplo.facebook.token
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/dist/facebook-utils-2.5.0/xref/stylesheet.css b/dist/facebook-utils-2.5.0/xref/stylesheet.css
deleted file mode 100644
index 89732f81..00000000
--- a/dist/facebook-utils-2.5.0/xref/stylesheet.css
+++ /dev/null
@@ -1,114 +0,0 @@
-/* Javadoc style sheet */
-/* Define colors, fonts and other style attributes here to override the defaults */
-body {
- background-color: #fff;
- font-family: Arial, Helvetica, sans-serif;
-}
-
-a:link {
- color: #00f;
-}
-a:visited {
- color: #00a;
-}
-
-a:active, a:hover {
- color: #f30 !important;
-}
-
-ul, li {
- list-style-type:none;
- margin:0;
- padding:0;
-}
-
-table td {
- padding: 3px;
- border: 1px solid #000;
-}
-table {
- width:100%;
- border: 1px solid #000;
- border-collapse: collapse;
-}
-
-div.overview {
- background-color:#ddd;
- padding: 4px 4px 4px 0;
-}
-div.overview li, div.framenoframe li {
- display: inline;
-}
-div.framenoframe {
- text-align: center;
- font-size: x-small;
-}
-div.framenoframe li {
- margin: 0 3px 0 3px;
-}
-div.overview li {
- margin:3px 3px 0 3px;
- padding: 4px;
-}
-li.selected {
- background-color:#888;
- color: #fff;
- font-weight: bold;
-}
-
-table.summary {
- margin-bottom: 20px;
-}
-table.summary td, table.summary th {
- font-weight: bold;
- text-align: left;
- padding: 3px;
-}
-table.summary th {
- background-color:#036;
- color: #fff;
-}
-table.summary td {
- background-color:#eee;
- border: 1px solid black;
-}
-
-em {
- color: #A00;
-}
-em.comment {
- color: #390;
-}
-.string {
- color: #009;
-}
-
-#overview {
- padding:2px;
-}
-
-hr {
- height: 1px;
- color: #000;
-}
-
-/* JXR style sheet */
-.jxr_comment
-{
- color: #390;
-}
-
-.jxr_javadoccomment
-{
- color: #A00;
-}
-
-.jxr_string
-{
- color: #009;
-}
-
-.jxr_keyword
-{
- color: #000;
-}
diff --git a/dist/hibernate-maven-plugin b/dist/hibernate-maven-plugin
deleted file mode 120000
index 99982517..00000000
--- a/dist/hibernate-maven-plugin
+++ /dev/null
@@ -1 +0,0 @@
-hibernate-maven-plugin-2.1.0
\ No newline at end of file
diff --git a/dist/hibernate-maven-plugin-2.0.0/apidocs/allclasses-frame.html b/dist/hibernate-maven-plugin-2.0.0/apidocs/allclasses-frame.html
deleted file mode 100644
index 7e65251e..00000000
--- a/dist/hibernate-maven-plugin-2.0.0/apidocs/allclasses-frame.html
+++ /dev/null
@@ -1,25 +0,0 @@
-
-
-
-
-
-
-All Classes
-
-
-
diff --git a/dist/hibernate-maven-plugin-2.0.0/apidocs/allclasses-noframe.html b/dist/hibernate-maven-plugin-2.0.0/apidocs/allclasses-noframe.html
deleted file mode 100644
index f3e4ee80..00000000
--- a/dist/hibernate-maven-plugin-2.0.0/apidocs/allclasses-noframe.html
+++ /dev/null
@@ -1,25 +0,0 @@
-
-
-
-
-
-
-All Classes
-
-
-
diff --git a/dist/hibernate-maven-plugin-2.0.0/apidocs/constant-values.html b/dist/hibernate-maven-plugin-2.0.0/apidocs/constant-values.html
deleted file mode 100644
index 5f66e5b3..00000000
--- a/dist/hibernate-maven-plugin-2.0.0/apidocs/constant-values.html
+++ /dev/null
@@ -1,202 +0,0 @@
-
-
-
-
-
-
-de.juplo.*
-
-
-
-
-
-
-
-Modifier and Type
-Constant Field
-Value
-
-
-
-
-
-public static final String
-DELIMITER
-"hibernate.schema.delimiter"
-
-
-
-
-public static final String
-EXPORT
-"hibernate.schema.export"
-
-
-
-
-public static final String
-OUTPUTDIRECTORY
-"project.build.outputDirectory"
-
-
-
-
-public static final String
-SCAN_CLASSES
-"hibernate.schema.scan.classes"
-
-
-
-
-public static final String
-SCAN_DEPENDENCIES
-"hibernate.schema.scan.dependencies"
-
-
-
-
-public static final String
-SCAN_TESTCLASSES
-"hibernate.schema.scan.test_classes"
-
-
-
-
-public static final String
-SKIPPED
-"hibernate.schema.skipped"
-
-
-
-
-
-public static final String
-TEST_OUTPUTDIRECTORY
-"project.build.testOutputDirectory"
Class AbstractSchemaMojo
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-public abstract class AbstractSchemaMojo
-extends org.apache.maven.plugin.AbstractMojo
-
-
-
-
-
-
-
-Field Summary
-
-
-
-
-Modifier and Type
-Field and Description
-
-
-
-static String
-DELIMITER
-
-
-static String
-EXPORT
-
-
-static String
-OUTPUTDIRECTORY
-
-
-static String
-SCAN_CLASSES
-
-
-static String
-SCAN_DEPENDENCIES
-
-
-static String
-SCAN_TESTCLASSES
-
-
-static String
-SKIPPED
-
-
-static String
-TEST_OUTPUTDIRECTORY
-
-Fields inherited from interface org.apache.maven.plugin.Mojo
-ROLE
-
-
-Constructor Summary
-
-
-
-
-Constructor and Description
-
-
-
-AbstractSchemaMojo()
-
-Method Summary
-
-
-
-
-Modifier and Type
-Method and Description
-
-
-
-void
-execute(String filename)
-
-Methods inherited from class org.apache.maven.plugin.AbstractMojo
-getLog, getPluginContext, setLog, setPluginContext
-
-Methods inherited from class java.lang.Object
-clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
-Methods inherited from interface org.apache.maven.plugin.Mojo
-execute
-
-
-
-
-
-
-Field Detail
-
-
-
-
-
-
-
-
-EXPORT
-public static final String EXPORT
-
-
-
-
-
-
-
-DELIMITER
-public static final String DELIMITER
-
-
-
-
-
-
-
-OUTPUTDIRECTORY
-public static final String OUTPUTDIRECTORY
-
-
-
-
-
-
-
-SCAN_CLASSES
-public static final String SCAN_CLASSES
-
-
-
-
-
-
-
-SCAN_DEPENDENCIES
-public static final String SCAN_DEPENDENCIES
-
-
-
-
-
-
-
-SCAN_TESTCLASSES
-public static final String SCAN_TESTCLASSES
-
-
-
-
-
-
-
-TEST_OUTPUTDIRECTORY
-public static final String TEST_OUTPUTDIRECTORY
-
-
-
-
-SKIPPED
-public static final String SKIPPED
-
-
-
-
-Method Detail
-
-
-
-
-
-execute
-public final void execute(String filename)
- throws org.apache.maven.plugin.MojoFailureException,
- org.apache.maven.plugin.MojoExecutionException
-
-
-org.apache.maven.plugin.MojoFailureException
org.apache.maven.plugin.MojoExecutionException
Class CreateMojo
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-public class CreateMojo
-extends AbstractSchemaMojo
-
-
-
-
-
-
-
-Field Summary
-
-
-Fields inherited from class de.juplo.plugins.hibernate.AbstractSchemaMojo
-DELIMITER, EXPORT, OUTPUTDIRECTORY, SCAN_CLASSES, SCAN_DEPENDENCIES, SCAN_TESTCLASSES, SKIPPED, TEST_OUTPUTDIRECTORY
-
-Fields inherited from interface org.apache.maven.plugin.Mojo
-ROLE
-
-
-Constructor Summary
-
-
-
-
-Constructor and Description
-
-
-
-CreateMojo()
-
-Method Summary
-
-
-
-
-Modifier and Type
-Method and Description
-
-
-
-void
-execute()
-
-Methods inherited from class de.juplo.plugins.hibernate.AbstractSchemaMojo
-execute
-
-
-Methods inherited from class org.apache.maven.plugin.AbstractMojo
-getLog, getPluginContext, setLog, setPluginContext
-
-Class DropMojo
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-public class DropMojo
-extends AbstractSchemaMojo
-
-
-
-
-
-
-
-
-
-Field Summary
-
-
-Fields inherited from class de.juplo.plugins.hibernate.AbstractSchemaMojo
-DELIMITER, EXPORT, OUTPUTDIRECTORY, SCAN_CLASSES, SCAN_DEPENDENCIES, SCAN_TESTCLASSES, SKIPPED, TEST_OUTPUTDIRECTORY
-
-Fields inherited from interface org.apache.maven.plugin.Mojo
-ROLE
-
-Method Summary
-
-
-
-
-Modifier and Type
-Method and Description
-
-
-
-void
-execute()
-
-Methods inherited from class de.juplo.plugins.hibernate.AbstractSchemaMojo
-execute
-
-
-Methods inherited from class org.apache.maven.plugin.AbstractMojo
-getLog, getPluginContext, setLog, setPluginContext
-
-Class HelpMojo
-
-
-
-
-
-
-
-
-
-
-
-
-public class HelpMojo
-extends org.apache.maven.plugin.AbstractMojo
-
- Call mvn hibernate:help -Ddetail=true -Dgoal=<goal-name>
to display parameter details.
-
-
-
-
-
-
-
-
-Field Summary
-
-
-Fields inherited from interface org.apache.maven.plugin.Mojo
-ROLE
-
-Method Summary
-
-
-
-
-Modifier and Type
-Method and Description
-
-
-
-void
-execute()
-
-
-Methods inherited from class org.apache.maven.plugin.AbstractMojo
-getLog, getPluginContext, setLog, setPluginContext
-
-
-
-Class ModificationTracker
-
-
-
-
-
-
-
-
-public class ModificationTracker
-extends Object
-
-
-
-
-
-
-Class MutableClassLoader
-
-
-
-
-
-
-
-
-
-
-public class MutableClassLoader
-extends ClassLoader
-
-
-
-
-
-
-
-Constructor Summary
-
-
-
-
-Constructor and Description
-
-
-
-MutableClassLoader(LinkedHashSet<URL> urls,
- org.apache.maven.plugin.logging.Log log)
-
-Method Summary
-
-
-
-
-Modifier and Type
-Method and Description
-
-
-
-MutableClassLoader
-add(LinkedHashSet<URL> urls)
-
-
-void
-clearAssertionStatus()
-
-
-URL
-getResource(String name)
-
-
-InputStream
-getResourceAsStream(String name)
-
-
-Enumeration<URL>
-getResources(String name)
-
-
-Class<?>
-loadClass(String name)
-
-
-void
-setClassAssertionStatus(String className,
- boolean enabled)
-
-
-void
-setDefaultAssertionStatus(boolean enabled)
-
-
-void
-setPackageAssertionStatus(String packageName,
- boolean enabled)
-
-
-Methods inherited from class java.lang.ClassLoader
-defineClass, defineClass, defineClass, defineClass, definePackage, findClass, findLibrary, findLoadedClass, findResource, findResources, findSystemClass, getClassLoadingLock, getPackage, getPackages, getParent, getSystemClassLoader, getSystemResource, getSystemResourceAsStream, getSystemResources, loadClass, registerAsParallelCapable, resolveClass, setSigners
-
-
-
-
-Constructor Detail
-
-
-
-
-
-MutableClassLoader
-public MutableClassLoader(LinkedHashSet<URL> urls,
- org.apache.maven.plugin.logging.Log log)
-
-
-Method Detail
-
-
-
-
-
-
-
-
-add
-public MutableClassLoader add(LinkedHashSet<URL> urls)
-
-
-
-
-
-clearAssertionStatus
-public void clearAssertionStatus()
-
-
-clearAssertionStatus
in class ClassLoader
-
-
-
-
-setClassAssertionStatus
-public void setClassAssertionStatus(String className,
- boolean enabled)
-
-
-setClassAssertionStatus
in class ClassLoader
-
-
-
-
-setPackageAssertionStatus
-public void setPackageAssertionStatus(String packageName,
- boolean enabled)
-
-
-setPackageAssertionStatus
in class ClassLoader
-
-
-
-
-setDefaultAssertionStatus
-public void setDefaultAssertionStatus(boolean enabled)
-
-
-setDefaultAssertionStatus
in class ClassLoader
-
-
-
-
-getResourceAsStream
-public InputStream getResourceAsStream(String name)
-
-
-getResourceAsStream
in class ClassLoader
-
-
-
-
-getResources
-public Enumeration<URL> getResources(String name)
- throws IOException
-
-
-getResources
in class ClassLoader
IOException
-
-
-
-
-getResource
-public URL getResource(String name)
-
-
-getResource
in class ClassLoader
-
-loadClass
-public Class<?> loadClass(String name)
- throws ClassNotFoundException
-
-
-loadClass
in class ClassLoader
ClassNotFoundException
Uses of Class
-
de.juplo.plugins.hibernate.AbstractSchemaMojo
-
-
-
-Uses of AbstractSchemaMojo in de.juplo.plugins.hibernate
-
-
-
-
-
-Modifier and Type
-Class and Description
-
-
-
-class
-CreateMojo
-
-
-
-
-class
-DropMojo
-Uses of Class
-
de.juplo.plugins.hibernate.CreateMojoUses of Class
-
de.juplo.plugins.hibernate.DropMojoUses of Class
-
de.juplo.plugins.hibernate.HelpMojoUses of Class
-
de.juplo.plugins.hibernate.ModificationTrackerUses of Class
-
de.juplo.plugins.hibernate.MutableClassLoader
-
-
-
-Uses of MutableClassLoader in de.juplo.plugins.hibernate
-
-
-
-
-
-Modifier and Type
-Method and Description
-
-
-
-
-MutableClassLoader
MutableClassLoader.
-add(LinkedHashSet<URL> urls)
de.juplo.plugins.hibernate
-Classes
-
-Package de.juplo.plugins.hibernate
-
-
-
-
-
-
-
-Class
-Description
-
-
-AbstractSchemaMojo
-
-
-
-
-CreateMojo
-
-
-
-
-DropMojo
-
-
-
-
-HelpMojo
-
-
-
-
-ModificationTracker
-
-
-
-
-MutableClassLoader
-
-Hierarchy For Package de.juplo.plugins.hibernate
-Class Hierarchy
-
-
-
-
-
-
-
-
-
-
-Uses of Package
-
de.juplo.plugins.hibernate
-
-
-
-
-
-
-Class and Description
-
-
-AbstractSchemaMojo
-
-
-
-
-MutableClassLoader
-Deprecated API
-Contents
-How This API Document Is Organized
-
-
-This help file applies to API documentation generated using the standard doclet.Package
-
-
-Class/Interface
-
-
-
-
-
-
-Annotation Type
-
-
-Enum
-
-
-Use
-Tree (Class Hierarchy)
-java.lang.Object
. The interfaces do not inherit from java.lang.Object
.
-
-Deprecated API
-Index
-Prev/Next
-Frames/No Frames
-All Classes
-Serialized Form
-Constant Field Values
-A
-
-
-
-
-
-C
-
-
-
-
-
-D
-
-
-
-
-
-E
-
-
-
-
-
-G
-
-
-
-
-
-H
-
-
-
-
-
-L
-
-
-
-
-
-M
-
-
-
-
-
-O
-
-
-
-
-
-S
-
-
-
-
-
-T
-
-
-A C D E G H L M O S T Frame Alert
-Class Hierarchy
-
-
-
-
-
-
-
-
-
-
-juplo
- Java bits from nerds for nerds
-
- Configuration Examples
Configuration Through A Configuration-File
-
-
-<plugin>
- <groupId>de.juplo</groupId>
- <artifactId>hibernate-maven-plugin</artifactId>
- <version>2.0.0</version>
- <executions>
- <execution>
- <goals>
- <goal>create</goal>
- </goals>
- </execution>
- </executions>
-</plugin>
-<plugin>
- <groupId>de.juplo</groupId>
- <artifactId>hibernate-maven-plugin</artifactId>
- <version>2.0.0</version>
- <executions>
- <execution>
- <goals>
- <goal>drop</goal>
- <goal>create</goal>
- </goals>
- </execution>
- </executions>
-</plugin>
-hibernate.dialect=org.hibernate.dialect.H2Dialect
-hibernate.connection.url=jdbc:h2:file:./target/db
-hibernate.connection.driver_class=org.h2.Driver
-hibernate.connection.username=sa
-hibernate.connection.password=
-<plugin>
- <groupId>de.juplo</groupId>
- <artifactId>hibernate-maven-plugin</artifactId>
- <version>2.0.0</version>
- <executions>
- <execution>
- <goals>
- <goal>drop</goal>
- <goal>create</goal>
- </goals>
- </execution>
- </executions>
- <configuration>
- <url><![CDATA[jdbc:mysql://localhost/test-db]]></url>
- </configuration>
-</plugin>
Configuration through maven-properties
-
-
-
-
-
-
-<properties>
- <hibernate.connection.driver_class>org.hsqldb.jdbcDriver</hibernate.connection.driver_class>
- <hibernate.dialect>org.hibernate.dialect.HSQLDialect</hibernate.dialect>
- <hibernate.connection.url><![CDATA[jdbc:hsqldb:res:org.my.path.production_db]]></hibernate.connection.url>
- <hibernate.connection.username>sa</hibernate.connection.username>
- <hibernate.connection.password></hibernate.connection.password>
-</properties>
-
-...
-
-<plugins>
-
- ...
-
- <plugin>
- <groupId>de.juplo</groupId>
- <artifactId>hibernate-maven-plugin</artifactId>
- <version>2.0.0</version>
- <executions>
- <execution>
- <goals>
- <goal>drop</goal>
- <goal>create</goal>
- </goals>
- </execution>
- </executions>
- <configuration>
- <url><![CDATA[jdbc:hsqldb:target/db/testdb;shutdown=true]]></url>
- </configuration>
- </plugin>
-
-<plugins>
Configuration through the plugin-configuration
-
-
-
-
-
-
-<plugin>
- <groupId>de.juplo</groupId>
- <artifactId>hibernate-maven-plugin</artifactId>
- <version>2.0.0</version>
- <executions>
- <execution>
- <goals>
- <goal>drop</goal>
- <goal>create</goal>
- </goals>
- </execution>
- </executions>
- <configuration>
- <driver>org.hsqldb.jdbcDriver</driver>
- <dialect>org.hibernate.dialect.HSQLDialect</dialect>
- <url><![CDATA[jdbc:hsqldb:target/db/fotos;shutdown=true]]></url>
- <username>sa</username>
- <password></password>
- </configuration>
-</plugin>
Configuration-Method-Precedence
-
-
-
-
-
-
-<plugin>
- <groupId>de.juplo</groupId>
- <artifactId>hibernate-maven-plugin</artifactId>
- <version>2.0.0</version>
- <executions>
- <execution>
- <goals>
- <goal>drop</goal>
- <goal>create</goal>
- </goals>
- </execution>
- </executions>
- <configuration>
- <password>${my-password-property}</password>
- </configuration>
-</plugin>
juplo
- Java bits from nerds for nerds
-
- CPD
CPD Results
-Duplications
-
-
-
-File
-Line
-
-de/juplo/plugins/hibernate/CreateMojo.java
-35
-
-de/juplo/plugins/hibernate/DropMojo.java
-35
- public class CreateMojo extends AbstractSchemaMojo
-{
- /**
- * Output file.
- * <p>
- * If the specified filename is not absolut, the file will be created
- * relative to the project build directory
- * (<code>project.build.directory</code>).
- *
- * @parameter property="hibernate.schema.export.create" default-value="create.sql"
- * @since 1.0
- */
- private String outputFile;
-
-
- @Override
- public final void execute()
- throws
- MojoFailureException,
- MojoExecutionException
- {
- super.execute(outputFile);
- }
-
-
- @Override
- void build(MetadataImplementor metadata)
- throws
- MojoExecutionException,
- MojoFailureException
- {
- SchemaExport schemaExport = new SchemaExport(metadata, createNamespaces);
- schemaExport.setDelimiter(delimiter);
- schemaExport.setFormat(format);
-
- File output = new File(outputFile);
-
- if (!output.isAbsolute())
- {
- // Interpret relative file path relative to build directory
- output = new File(buildDirectory, outputFile);
- getLog().debug("Adjusted relative path, resulting path is " + output.getPath());
- }
-
- // Ensure that directory path for specified file exists
- File outFileParentDir = output.getParentFile();
- if (null != outFileParentDir && !outFileParentDir.exists())
- {
- try
- {
- getLog().info("Creating directory path for output file:" + outFileParentDir.getPath());
- outFileParentDir.mkdirs();
- }
- catch (Exception e)
- {
- getLog().error("Error creating directory path for output file: " + e.getLocalizedMessage());
- }
- }
-
- schemaExport.setOutputFile(output.getPath());
- schemaExport.execute(false, this.export, false, true);
juplo
- Java bits from nerds for nerds
-
- Goal: CREATE
hibernate:create
-
-
-
-
-
-Optional Parameters
-
-
-
-
-
-
-
-
-Name
-
-Type
-
-Since
-
-Description
-
-
-
-
-createNamespaces
-
-Boolean
-
-2.0
-
-Specifies whether to automatically create also the database
-schema/catalog.
-
Default value is: false.
User property is: hibernate.hbm2dll.create_namespaces.
-
-
-
-delimiter
-
-String
-
-1.0
-
-Delimiter in output-file.
-
-
-
Default value is: ;.
User property is: hibernate.schema.delimiter.
-
-
-
-dialect
-
-String
-
-1.0
-
-Hibernate dialect.
-
User property is: hibernate.dialect.
-
-
-
-driver
-
-String
-
-1.0
-
-SQL-Driver name.
-
User property is: hibernate.connection.driver_class.
-
-
-
-export
-
-Boolean
-
-2.0
-
-Export the database-schma to the database. If set to
-false, only the SQL-script is created and the database
-is not touched.
-
-
-
Default value is: true.
User property is: hibernate.schema.export.
-
-
-
-force
-
-boolean
-
-1.0
-
-Force execution
-
-
-
Default value is: false.
User property is: hibernate.schema.force.
-
-
-
-format
-
-Boolean
-
-1.0
-
-Format output-file.
-
User property is: hibernate.format_sql.
-
-
-
-hibernateConfig
-
-String
-
-1.1.0
-
-Path to Hibernate configuration file (.cfg.xml). If this parameter
-is specified, the plugin will try to load configuration values from
-a file with the given path or a ressource on the classpath with the
-given name. If both fails, the execution of the plugin will fail.
-
-
-
-
-
-
-hibernateProperties
-
-String
-
-1.0
-
-Path to a file or name of a ressource with hibernate properties. If
-this parameter is specified, the plugin will try to load
-configuration values from a file with the given path or a ressource
-on the classpath with the given name. If both fails, the execution
-of the plugin will fail.
-
-
-
-
-
-
-implicitNamingStrategy
-
-String
-
-2.0
-
-Implicit naming strategy
-
User property is: hibernate.implicit_naming_strategy.
-
-
-
-mappings
-
-String
-
-1.0.2
-
-List of Hibernate-Mapping-Files (XML). Multiple files can be
-separated with white-spaces and/or commas.
-
User property is: hibernate.mapping.
-
-
-
-outputDirectory
-
-String
-
-1.0
-
-Classes-Directory to scan.
-
-
-
User property is: project.build.outputDirectory.
-
-
-
-outputFile
-
-String
-
-1.0
-
-Output file.
-
-
-
Default value is: create.sql.
User property is: hibernate.schema.export.create.
-
-
-
-password
-
-String
-
-1.0
-
-Database password
-
User property is: hibernate.connection.password.
-
-
-
-persistenceUnit
-
-String
-
-1.1.0
-
-Name of the persistence-unit. If this parameter is specified, the
-plugin will try to load configuration values from a
-persistence-unit with the specified name. If no such
-persistence-unit can be found, the plugin will throw an exception.
-
-
-
-
-
-
-physicalNamingStrategy
-
-String
-
-2.0
-
-Physical naming strategy
-
User property is: hibernate.physical_naming_strategy.
-
-
-
-scanClasses
-
-Boolean
-
-2.0
-
-Wether the project should be scanned for annotated-classes, or not
-
-
-
User property is: hibernate.schema.scan.classes.
-
-
-
-scanDependencies
-
-String
-
-1.0.3
-
-Dependency-Scopes, that should be scanned for annotated classes.
-
-
-
Default value is: compile.
User property is: hibernate.schema.scan.dependencies.
-
-
-
-scanTestClasses
-
-Boolean
-
-1.0.1
-
-Whether to scan the test-branch of the project for annotated
-classes, or not.
-
-
-
Default value is: false.
User property is: hibernate.schema.scan.test_classes.
-
-
-
-show
-
-Boolean
-
-1.0
-
-Show the generated SQL in the command-line output.
-
User property is: hibernate.show_sql.
-
-
-
-skip
-
-boolean
-
-1.0
-
-Skip execution
-
-
-
Default value is: ${maven.test.skip}.
User property is: hibernate.schema.skip.
-
-
-
-testOutputDirectory
-
-String
-
-1.0.2
-
-Test-Classes-Directory to scan.
-
-
-
User property is: project.build.testOutputDirectory.
-
-
-
-url
-
-String
-
-1.0
-
-Database URL.
-
User property is: hibernate.connection.url.
-
-
- username
-
-String
-
-1.0
-
-Database username
-
User property is: hibernate.connection.username.Parameter Details
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- juplo
- Java bits from nerds for nerds
-
- Enable Debug-Output
-mvn -X compile hibernate:create
juplo
- Java bits from nerds for nerds
-
- Dependencies
Project Dependencies
-compile
-
-
-
-GroupId
-ArtifactId
-Version
-Type
-License
-
-com.pyx4j
-maven-plugin-log4j
-1.0.1
-jar
-The Apache Software License, Version 2.0
-
-de.juplo
-scannotation
-1.0.4
-jar
--
-
-javax.el
-javax.el-api
-3.0.0
-jar
-CDDL + GPLv2 with classpath exception
-
-org.apache.maven
-maven-core
-3.3.3
-jar
-Apache License, Version 2.0
-
-org.apache.maven
-maven-plugin-api
-3.3.3
-jar
-Apache License, Version 2.0
-
-org.hibernate
-hibernate-core
-5.0.2.Final
-jar
-GNU Lesser General Public License
-
-org.hibernate
-hibernate-envers
-5.0.2.Final
-jar
-GNU Lesser General Public License
- org.hibernate
-hibernate-validator
-5.2.2.Final
-jar
-Apache License, Version 2.0 Project Transitive Dependencies
-compile
-Project Dependency Graph
-
-Dependency Tree
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
Licenses
-Dependency File Details
-
-
-
-Filename
-Size
-Entries
-Classes
-Packages
-JDK Rev
-Debug
-
-antlr-2.7.7.jar
-434.85 kB
-239
-224
-12
-1.2
-debug
-
-aopalliance-1.0.jar
-4.36 kB
-15
-9
-2
-1.3
-debug
-
-classmate-1.1.0.jar
-61.40 kB
-52
-37
-4
-1.6
-debug
-
-guava-18.0.jar
-2.15 MB
-1,719
-1,690
-17
-1.6
-debug
-
-maven-plugin-log4j-1.0.1.jar
-3.64 kB
-12
-1
-1
-1.4
-debug
-
-scannotation-1.0.4.jar
-19.79 kB
-23
-13
-2
-1.6
-debug
-
-dom4j-1.6.1.jar
-306.54 kB
-208
-190
-14
-1.3
-debug
-
-jsr250-api-1.0.jar
-5.71 kB
-16
-11
-2
-1.5
-debug
-
-javax.el-api-3.0.0.jar
-71.35 kB
-57
-46
-1
-1.6
-debug
-
-cdi-api-1.0.jar
-43.86 kB
-92
-75
-7
-1.5
-debug
-
-javax.inject-1.jar
-2.44 kB
-8
-6
-1
-1.5
-release
-
-validation-api-1.1.0.Final.jar
-62.28 kB
-122
-106
-8
-1.6
-debug
-
-log4j-1.2.14.jar
-358.83 kB
-288
-256
-19
-1.1
-debug
-
-geronimo-jta_1.1_spec-1.1.1.jar
-15.65 kB
-30
-18
-2
-1.5
-debug
-
-maven-aether-provider-3.3.3.jar
-64.79 kB
-43
-26
-1
-1.6
-debug
-
-maven-artifact-3.3.3.jar
-53.80 kB
-57
-32
-11
-1.6
-debug
-
-maven-builder-support-3.3.3.jar
-14.61 kB
-24
-10
-1
-1.6
-debug
-
-maven-core-3.3.3.jar
-617.07 kB
-489
-390
-56
-1.6
-debug
-
-maven-model-3.3.3.jar
-157.05 kB
-67
-50
-3
-1.6
-debug
-
-maven-model-builder-3.3.3.jar
-172.28 kB
-154
-121
-16
-1.6
-debug
-
-maven-plugin-api-3.3.3.jar
-45.02 kB
-46
-25
-6
-1.6
-debug
-
-maven-repository-metadata-3.3.3.jar
-25.35 kB
-25
-7
-2
-1.6
-debug
-
-maven-settings-3.3.3.jar
-42.02 kB
-33
-17
-2
-1.6
-debug
-
-maven-settings-builder-3.3.3.jar
-42.14 kB
-53
-32
-5
-1.6
-debug
-
-plexus-classworlds-2.5.2.jar
-51.45 kB
-52
-37
-5
-1.6
-debug
-
-plexus-component-annotations-1.5.5.jar
-4.11 kB
-15
-3
-1
-1.5
-release
-
-plexus-interpolation-1.21.jar
-60.99 kB
-60
-44
-6
-1.5
-debug
-
-aether-api-1.0.2.v20150114.jar
-133.13 kB
-149
-128
-11
-1.5
-debug
-
-aether-impl-1.0.2.v20150114.jar
-168.94 kB
-114
-96
-4
-1.5
-debug
-
-aether-spi-1.0.2.v20150114.jar
-29.99 kB
-54
-34
-8
-1.5
-debug
-
-aether-util-1.0.2.v20150114.jar
-143.43 kB
-126
-101
-13
-1.5
-debug
-
-org.eclipse.sisu.inject-0.3.0.jar
-366.47 kB
-287
-269
-9
-1.6
-debug
-
-org.eclipse.sisu.plexus-0.3.0.jar
-200.59 kB
-196
-164
-20
-1.6
-debug
-
-hibernate-core-5.0.2.Final.jar
-5.29 MB
-4,069
-3,776
-224
-1.6
-debug
-
-hibernate-entitymanager-5.0.2.Final.jar
-576.65 kB
-429
-390
-24
-1.6
-debug
-
-hibernate-envers-5.0.2.Final.jar
-397.65 kB
-319
-264
-37
-1.6
-debug
-
-hibernate-validator-5.2.2.Final.jar
-680.98 kB
-539
-452
-54
-1.6
-debug
-
-hibernate-commons-annotations-5.0.0.Final.jar
-73.35 kB
-80
-67
-7
-1.6
-debug
-
-hibernate-jpa-2.1-api-1.0.0.Final.jar
-110.71 kB
-207
-200
-4
-1.6
-debug
-
-javassist-3.18.1-GA.jar
-697.46 kB
-414
-390
-17
-1.6
-debug
-
-jandex-1.2.2.Final.jar
-76.97 kB
-54
-44
-1
-1.6
-debug
-
-jboss-logging-3.3.0.Final.jar
-65.24 kB
-60
-48
-1
-1.6
-debug
-
-plexus-cipher-1.4.jar
-13.18 kB
-20
-6
-1
-1.4
-debug
-
-plexus-sec-dispatcher-1.3.jar
-27.89 kB
-31
-13
-3
-1.4
-debug
-
-sisu-guice-3.2.5-no_aop.jar
-390.30 kB
-331
-316
-8
-1.6
-debug
-
-xml-apis-1.0.b2.jar
-106.76 kB
-217
-184
-17
-1.2
-release
-
-Total
-Size
-Entries
-Classes
-Packages
-JDK Rev
-Debug
-
-46
-14.28 MB
-11,695
-10,418
-670
-1.6
-43
- compile: 46
-compile: 14.28 MB
-compile: 11,695
-compile: 10,418
-compile: 670
--
-compile: 43 Dependency Repository Locations
-
-
-
-
-Repo ID
-URL
-Release
-Snapshot
-Blacklisted
-
-plexus.snapshots
-https://oss.sonatype.org/content/repositories/plexus-snapshots
--
-Yes
--
-
-central
-http://repo.maven.apache.org/maven2
-Yes
--
--
-
-codehaus-snapshots
-http://snapshots.repository.codehaus.org
--
-Yes
-Yes
-
-apache-snapshots
-http://people.apache.org/repo/m2-snapshot-repository
--
-Yes
-Yes
-
-snapshots.jboss.org
-http://snapshots.jboss.org/maven2
--
-Yes
--
-
-sonatype-nexus-snapshots
-https://oss.sonatype.org/content/repositories/snapshots
--
-Yes
--
-
-oss.sonatype.org/jboss-snapshots
-http://oss.sonatype.org/content/repositories/jboss-snapshots
--
-Yes
--
-
-jvnet-nexus-snapshots
-https://maven.java.net/content/repositories/snapshots
--
-Yes
--
-
-repository.jboss.org
-http://repository.jboss.org/maven2
-Yes
--
--
-
-apache-incubator
-http://people.apache.org/repo/m2-incubating-repository/
-Yes
--
-Yes
- apache.snapshots
-http://repository.apache.org/snapshots
--
-Yes
-- juplo
- Java bits from nerds for nerds
-
- Dependency Information
Dependency Information
-Apache Maven
-<dependency>
- <groupId>de.juplo</groupId>
- <artifactId>hibernate-maven-plugin</artifactId>
- <version>2.0.0</version>
- <type>maven-plugin</type>
-</dependency>
Apache Ant
-<dependency org="de.juplo" name="hibernate-maven-plugin" rev="2.0.0">
- <artifact name="hibernate-maven-plugin" type="maven-plugin" />
-</dependency>
juplo
- Java bits from nerds for nerds
-
- Distribution Management
Overview
-Snapshot Repository - sonatype-nexus-snapshots
https://oss.sonatype.org/content/repositories/snapshots/juplo
- Java bits from nerds for nerds
-
- Goal: DROP
hibernate:drop
-
-
-
-
-
-Optional Parameters
-
-
-
-
-
-
-
-
-Name
-
-Type
-
-Since
-
-Description
-
-
-
-
-createNamespaces
-
-Boolean
-
-2.0
-
-Specifies whether to automatically create also the database
-schema/catalog.
-
Default value is: false.
User property is: hibernate.hbm2dll.create_namespaces.
-
-
-
-delimiter
-
-String
-
-1.0
-
-Delimiter in output-file.
-
-
-
Default value is: ;.
User property is: hibernate.schema.delimiter.
-
-
-
-dialect
-
-String
-
-1.0
-
-Hibernate dialect.
-
User property is: hibernate.dialect.
-
-
-
-driver
-
-String
-
-1.0
-
-SQL-Driver name.
-
User property is: hibernate.connection.driver_class.
-
-
-
-export
-
-Boolean
-
-2.0
-
-Export the database-schma to the database. If set to
-false, only the SQL-script is created and the database
-is not touched.
-
-
-
Default value is: true.
User property is: hibernate.schema.export.
-
-
-
-force
-
-boolean
-
-1.0
-
-Force execution
-
-
-
Default value is: false.
User property is: hibernate.schema.force.
-
-
-
-format
-
-Boolean
-
-1.0
-
-Format output-file.
-
User property is: hibernate.format_sql.
-
-
-
-hibernateConfig
-
-String
-
-1.1.0
-
-Path to Hibernate configuration file (.cfg.xml). If this parameter
-is specified, the plugin will try to load configuration values from
-a file with the given path or a ressource on the classpath with the
-given name. If both fails, the execution of the plugin will fail.
-
-
-
-
-
-
-hibernateProperties
-
-String
-
-1.0
-
-Path to a file or name of a ressource with hibernate properties. If
-this parameter is specified, the plugin will try to load
-configuration values from a file with the given path or a ressource
-on the classpath with the given name. If both fails, the execution
-of the plugin will fail.
-
-
-
-
-
-
-implicitNamingStrategy
-
-String
-
-2.0
-
-Implicit naming strategy
-
User property is: hibernate.implicit_naming_strategy.
-
-
-
-mappings
-
-String
-
-1.0.2
-
-List of Hibernate-Mapping-Files (XML). Multiple files can be
-separated with white-spaces and/or commas.
-
User property is: hibernate.mapping.
-
-
-
-outputDirectory
-
-String
-
-1.0
-
-Classes-Directory to scan.
-
-
-
User property is: project.build.outputDirectory.
-
-
-
-outputFile
-
-String
-
-1.0
-
-Output file.
-
-
-
Default value is: drop.sql.
User property is: hibernate.schema.export.drop.
-
-
-
-password
-
-String
-
-1.0
-
-Database password
-
User property is: hibernate.connection.password.
-
-
-
-persistenceUnit
-
-String
-
-1.1.0
-
-Name of the persistence-unit. If this parameter is specified, the
-plugin will try to load configuration values from a
-persistence-unit with the specified name. If no such
-persistence-unit can be found, the plugin will throw an exception.
-
-
-
-
-
-
-physicalNamingStrategy
-
-String
-
-2.0
-
-Physical naming strategy
-
User property is: hibernate.physical_naming_strategy.
-
-
-
-scanClasses
-
-Boolean
-
-2.0
-
-Wether the project should be scanned for annotated-classes, or not
-
-
-
User property is: hibernate.schema.scan.classes.
-
-
-
-scanDependencies
-
-String
-
-1.0.3
-
-Dependency-Scopes, that should be scanned for annotated classes.
-
-
-
Default value is: compile.
User property is: hibernate.schema.scan.dependencies.
-
-
-
-scanTestClasses
-
-Boolean
-
-1.0.1
-
-Whether to scan the test-branch of the project for annotated
-classes, or not.
-
-
-
Default value is: false.
User property is: hibernate.schema.scan.test_classes.
-
-
-
-show
-
-Boolean
-
-1.0
-
-Show the generated SQL in the command-line output.
-
User property is: hibernate.show_sql.
-
-
-
-skip
-
-boolean
-
-1.0
-
-Skip execution
-
-
-
Default value is: ${maven.test.skip}.
User property is: hibernate.schema.skip.
-
-
-
-testOutputDirectory
-
-String
-
-1.0.2
-
-Test-Classes-Directory to scan.
-
-
-
User property is: project.build.testOutputDirectory.
-
-
-
-url
-
-String
-
-1.0
-
-Database URL.
-
User property is: hibernate.connection.url.
-
-
- username
-
-String
-
-1.0
-
-Database username
-
User property is: hibernate.connection.username.Parameter Details
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- juplo
- Java bits from nerds for nerds
-
- Force Exceution
-<plugin>
- <groupId>de.juplo</groupId>
- <artifactId>hibernate-maven-plugin</artifactId>
- <version>2.0.0</version>
- <configuration>
- <force>true</force>
- </configuration>
-</plugin>
juplo
- Java bits from nerds for nerds
-
- hibernate:help
hibernate:help
-
-
-Call mvn hibernate:help -Ddetail=true
--Dgoal=<goal-name> to display parameter details.
-
-
-
-Optional Parameters
-
-
-
-
-
-
-
-
-Name
-
-Type
-
-Since
-
-Description
-
-
-
-
-detail
-
-boolean
-
--
-
-If true, display all settable properties for each
-goal.
-
Default value is: false.
User property is: detail.
-
-
-
-goal
-
-String
-
--
-
-The name of the goal for which to show help. If unspecified, all
-goals will be displayed.
-
User property is: goal.
-
-
-
-indentSize
-
-int
-
--
-
-The number of spaces per indentation level, should be positive.
-
Default value is: 2.
User property is: indentSize.
-
-
- lineLength
-
-int
-
--
-
-The maximum length of a display line, should be positive.
-
Default value is: 80.
User property is: lineLength.Parameter Details
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- juplo
- Java bits from nerds for nerds
-
- Hibernate Maven Plugin
-
-A simple Plugin for generating a Database-Schema from Hibernate Mapping-Annotations
-
-
-
-
-
-Documentation
-
-
-
-
- juplo
- Java bits from nerds for nerds
-
- Continuous Integration
Notifiers
-
-
-
-Type
-Address
-Configuration
- mail
-kai@juplo.de
-- juplo
- Java bits from nerds for nerds
-
- Issue Tracking
juplo
- Java bits from nerds for nerds
-
- Project License
Overview
-Project License
-The Apache Software License, Version 2.0
-
- Apache License
- Version 2.0, January 2004
- http://www.apache.org/licenses/
-
- TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
-
- 1. Definitions.
-
- "License" shall mean the terms and conditions for use, reproduction,
- and distribution as defined by Sections 1 through 9 of this document.
-
- "Licensor" shall mean the copyright owner or entity authorized by
- the copyright owner that is granting the License.
-
- "Legal Entity" shall mean the union of the acting entity and all
- other entities that control, are controlled by, or are under common
- control with that entity. For the purposes of this definition,
- "control" means (i) the power, direct or indirect, to cause the
- direction or management of such entity, whether by contract or
- otherwise, or (ii) ownership of fifty percent (50%) or more of the
- outstanding shares, or (iii) beneficial ownership of such entity.
-
- "You" (or "Your") shall mean an individual or Legal Entity
- exercising permissions granted by this License.
-
- "Source" form shall mean the preferred form for making modifications,
- including but not limited to software source code, documentation
- source, and configuration files.
-
- "Object" form shall mean any form resulting from mechanical
- transformation or translation of a Source form, including but
- not limited to compiled object code, generated documentation,
- and conversions to other media types.
-
- "Work" shall mean the work of authorship, whether in Source or
- Object form, made available under the License, as indicated by a
- copyright notice that is included in or attached to the work
- (an example is provided in the Appendix below).
-
- "Derivative Works" shall mean any work, whether in Source or Object
- form, that is based on (or derived from) the Work and for which the
- editorial revisions, annotations, elaborations, or other modifications
- represent, as a whole, an original work of authorship. For the purposes
- of this License, Derivative Works shall not include works that remain
- separable from, or merely link (or bind by name) to the interfaces of,
- the Work and Derivative Works thereof.
-
- "Contribution" shall mean any work of authorship, including
- the original version of the Work and any modifications or additions
- to that Work or Derivative Works thereof, that is intentionally
- submitted to Licensor for inclusion in the Work by the copyright owner
- or by an individual or Legal Entity authorized to submit on behalf of
- the copyright owner. For the purposes of this definition, "submitted"
- means any form of electronic, verbal, or written communication sent
- to the Licensor or its representatives, including but not limited to
- communication on electronic mailing lists, source code control systems,
- and issue tracking systems that are managed by, or on behalf of, the
- Licensor for the purpose of discussing and improving the Work, but
- excluding communication that is conspicuously marked or otherwise
- designated in writing by the copyright owner as "Not a Contribution."
-
- "Contributor" shall mean Licensor and any individual or Legal Entity
- on behalf of whom a Contribution has been received by Licensor and
- subsequently incorporated within the Work.
-
- 2. Grant of Copyright License. Subject to the terms and conditions of
- this License, each Contributor hereby grants to You a perpetual,
- worldwide, non-exclusive, no-charge, royalty-free, irrevocable
- copyright license to reproduce, prepare Derivative Works of,
- publicly display, publicly perform, sublicense, and distribute the
- Work and such Derivative Works in Source or Object form.
-
- 3. Grant of Patent License. Subject to the terms and conditions of
- this License, each Contributor hereby grants to You a perpetual,
- worldwide, non-exclusive, no-charge, royalty-free, irrevocable
- (except as stated in this section) patent license to make, have made,
- use, offer to sell, sell, import, and otherwise transfer the Work,
- where such license applies only to those patent claims licensable
- by such Contributor that are necessarily infringed by their
- Contribution(s) alone or by combination of their Contribution(s)
- with the Work to which such Contribution(s) was submitted. If You
- institute patent litigation against any entity (including a
- cross-claim or counterclaim in a lawsuit) alleging that the Work
- or a Contribution incorporated within the Work constitutes direct
- or contributory patent infringement, then any patent licenses
- granted to You under this License for that Work shall terminate
- as of the date such litigation is filed.
-
- 4. Redistribution. You may reproduce and distribute copies of the
- Work or Derivative Works thereof in any medium, with or without
- modifications, and in Source or Object form, provided that You
- meet the following conditions:
-
- (a) You must give any other recipients of the Work or
- Derivative Works a copy of this License; and
-
- (b) You must cause any modified files to carry prominent notices
- stating that You changed the files; and
-
- (c) You must retain, in the Source form of any Derivative Works
- that You distribute, all copyright, patent, trademark, and
- attribution notices from the Source form of the Work,
- excluding those notices that do not pertain to any part of
- the Derivative Works; and
-
- (d) If the Work includes a "NOTICE" text file as part of its
- distribution, then any Derivative Works that You distribute must
- include a readable copy of the attribution notices contained
- within such NOTICE file, excluding those notices that do not
- pertain to any part of the Derivative Works, in at least one
- of the following places: within a NOTICE text file distributed
- as part of the Derivative Works; within the Source form or
- documentation, if provided along with the Derivative Works; or,
- within a display generated by the Derivative Works, if and
- wherever such third-party notices normally appear. The contents
- of the NOTICE file are for informational purposes only and
- do not modify the License. You may add Your own attribution
- notices within Derivative Works that You distribute, alongside
- or as an addendum to the NOTICE text from the Work, provided
- that such additional attribution notices cannot be construed
- as modifying the License.
-
- You may add Your own copyright statement to Your modifications and
- may provide additional or different license terms and conditions
- for use, reproduction, or distribution of Your modifications, or
- for any such Derivative Works as a whole, provided Your use,
- reproduction, and distribution of the Work otherwise complies with
- the conditions stated in this License.
-
- 5. Submission of Contributions. Unless You explicitly state otherwise,
- any Contribution intentionally submitted for inclusion in the Work
- by You to the Licensor shall be under the terms and conditions of
- this License, without any additional terms or conditions.
- Notwithstanding the above, nothing herein shall supersede or modify
- the terms of any separate license agreement you may have executed
- with Licensor regarding such Contributions.
-
- 6. Trademarks. This License does not grant permission to use the trade
- names, trademarks, service marks, or product names of the Licensor,
- except as required for reasonable and customary use in describing the
- origin of the Work and reproducing the content of the NOTICE file.
-
- 7. Disclaimer of Warranty. Unless required by applicable law or
- agreed to in writing, Licensor provides the Work (and each
- Contributor provides its Contributions) on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
- implied, including, without limitation, any warranties or conditions
- of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
- PARTICULAR PURPOSE. You are solely responsible for determining the
- appropriateness of using or redistributing the Work and assume any
- risks associated with Your exercise of permissions under this License.
-
- 8. Limitation of Liability. In no event and under no legal theory,
- whether in tort (including negligence), contract, or otherwise,
- unless required by applicable law (such as deliberate and grossly
- negligent acts) or agreed to in writing, shall any Contributor be
- liable to You for damages, including any direct, indirect, special,
- incidental, or consequential damages of any character arising as a
- result of this License or out of the use or inability to use the
- Work (including but not limited to damages for loss of goodwill,
- work stoppage, computer failure or malfunction, or any and all
- other commercial damages or losses), even if such Contributor
- has been advised of the possibility of such damages.
-
- 9. Accepting Warranty or Additional Liability. While redistributing
- the Work or Derivative Works thereof, You may choose to offer,
- and charge a fee for, acceptance of support, warranty, indemnity,
- or other liability obligations and/or rights consistent with this
- License. However, in accepting such obligations, You may act only
- on Your own behalf and on Your sole responsibility, not on behalf
- of any other Contributor, and only if You agree to indemnify,
- defend, and hold each Contributor harmless for any liability
- incurred by, or claims asserted against, such Contributor by reason
- of your accepting any such warranty or additional liability.
-
- END OF TERMS AND CONDITIONS
-
- APPENDIX: How to apply the Apache License to your work.
-
- To apply the Apache License to your work, attach the following
- boilerplate notice, with the fields enclosed by brackets "[]"
- replaced with your own identifying information. (Don't include
- the brackets!) The text should be enclosed in the appropriate
- comment syntax for the file format. We also recommend that a
- file or class name and description of purpose be included on the
- same "printed page" as the copyright notice for easier
- identification within third-party archives.
-
- Copyright [yyyy] [name of copyright owner]
-
- Licensed under the Apache License, Version 2.0 (the "License");
- you may not use this file except in compliance with the License.
- You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
-
juplo
- Java bits from nerds for nerds
-
- Mailing Lists
juplo
- Java bits from nerds for nerds
-
- Known Pitfalls (FAQ)
Annotated classes in dependencies are not found.
-
-hibernate-maven-plugin always needs a database-connection
-
-
-<configuration>
- <export>false</export>
-</configuration>
Dependency for driver-class XYZ is missing
-
-
-[INFO] Gathered hibernate-configuration (turn on debugging for details):
-[INFO] hibernate.connection.username = sa
-[INFO] hibernate.connection.password =
-[INFO] hibernate.dialect = org.hibernate.dialect.H2Dialect
-[INFO] hibernate.connection.url = jdbc:h2:file:./db
-[INFO] hibernate.hbm2dll.create_namespaces = false
-[INFO] hibernate.connection.driver_class = org.h2.Driver
-[INFO] hibernate.format_sql = true
-[INFO] HHH000412: Hibernate Core {5.0.2.Final}
-[INFO] HHH000206: hibernate.properties not found
-[INFO] HHH000021: Bytecode provider name : javassist
-[INFO] Adding /home/kai/project/target/classes to the list of roots to scan...
-[INFO] Adding dependencies from scope compile to the list of roots to scan
-[INFO] Adding dependencies from scope org.hibernate:hibernate-core:jar:4.3.0.Final to the list of roots to scan
-[INFO] Adding annotated resource: de.juplo.tests.SimplestMavenHib4Test
-[INFO] ------------------------------------------------------------------------
-[INFO] BUILD FAILURE
-[INFO] ------------------------------------------------------------------------
-[INFO] Total time: 1.760s
-[INFO] Finished at: Mon Mar 07 19:06:54 CET 2016
-[INFO] Final Memory: 11M/215M
-[INFO] ------------------------------------------------------------------------
-[ERROR] Failed to execute goal de.juplo:hibernate-maven-plugin:2.0.0:drop (default) on project hibernate4-properties-test: Could not open the JDBC-connection: Unable to load class [org.h2.Driver]: Could not load requested class : org.h2.Driver -> [Help 1]
-[ERROR]
-[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
-[ERROR] Re-run Maven using the -X switch to enable full debug logging.
-[ERROR]
-[ERROR] For more information about the errors and possible solutions, please read the following articles:
-[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException
-<plugin>
- <groupId>de.juplo</groupId>
- <artifactId>hibernate-maven-plugin</artifactId>
- <version>2.0.0</version>
- <executions>
- <execution>
- <goals>
- <goal>drop</goal>
- <goal>create</goal>
- </goals>
- </execution>
- </executions>
- <dependencies>
- <dependency>
- <groupId>org.hsqldb</groupId>
- <artifactId>hsqldb</artifactId>
- <version>2.2.8</version>
- </dependency>
- </dependencies>
-</plugin>
DBUnit fails after execution of hibernate was skipped because nothing has changed
-
-
-<plugin>
- <groupId>org.codehaus.mojo</groupId>
- <artifactId>dbunit-maven-plugin</artifactId>
- <configuration>
- <skip>${hibernate.schema.skipped}</skip>
- </configuration>
-</plugin>
The database will not be recreated after a manual drop/clean
-
-
-[INFO] No modified annotated classes found and dialect unchanged.
-[INFO] Skipping schema generation!
-mvn hibernate:create -Dhibernate.schema.force=true
The hibernate:create goal is not executed, when tests are skipped
-
-
-<plugin>
- <groupId>de.juplo</groupId>
- <artifactId>hibernate-maven-plugin</artifactId>
- ...
- <configuration>
- <skip>false</skip>
- </configuration>
-</plugin>
I do not want my dependencies to be scanned for hibernate annotations
-
-
-<plugin>
- <groupId>de.juplo</groupId>
- <artifactId>hibernate-maven-plugin</artifactId>
- ...
- <configuration>
- <scanDependencies>none</scanDependencies>
- </configuration>
-</plugin>
No annotated classes found
-
-juplo
- Java bits from nerds for nerds
-
- Plugin Documentation
Plugin Documentation
-
-
-
-
-Goal
-Description
-
-hibernate:create
-Goal which extracts the hibernate-mapping-configuration and exports
-an according SQL-database-schema.
-
-hibernate:drop
-Goal which extracts the hibernate-mapping-configuration and exports
-an according SQL-database-schema.
- hibernate:help
-Display help information on hibernate-maven-plugin.
-Call mvn hibernate:help -Ddetail=true
--Dgoal=<goal-name>
to display parameter details.System Requirements
-
-
-
-Maven
-2.0.6
-
-JDK
-1.6
-
-Memory
-No minimum requirement.
- Disk Space
-No minimum requirement. Usage
-<project>
- ...
- <build>
- <!-- To define the plugin version in your parent POM -->
- <pluginManagement>
- <plugins>
- <plugin>
- <groupId>de.juplo</groupId>
- <artifactId>hibernate-maven-plugin</artifactId>
- <version>2.0.0</version>
- </plugin>
- ...
- </plugins>
- </pluginManagement>
- <!-- To use the plugin goals in your POM or parent POM -->
- <plugins>
- <plugin>
- <groupId>de.juplo</groupId>
- <artifactId>hibernate-maven-plugin</artifactId>
- <version>2.0.0</version>
- </plugin>
- ...
- </plugins>
- </build>
- ...
-</project>
-
juplo
- Java bits from nerds for nerds
-
- Plugin Management
Project Plugin Management
-
-
-
-GroupId
-ArtifactId
-Version
-
-org.apache.maven.plugins
-maven-antrun-plugin
-1.3
-
-org.apache.maven.plugins
-maven-assembly-plugin
-2.2-beta-5
-
-org.apache.maven.plugins
-maven-dependency-plugin
-2.1
-
-org.apache.maven.plugins
-maven-release-plugin
-2.1
- org.apache.maven.plugins
-maven-site-plugin
-3.4 juplo
- Java bits from nerds for nerds
-
- Project Plugins
Project Build Plugins
-
-
-
-GroupId
-ArtifactId
-Version
-
-org.apache.maven.plugins
-maven-clean-plugin
-2.5
-
-org.apache.maven.plugins
-maven-compiler-plugin
-3.3
-
-org.apache.maven.plugins
-maven-dependency-plugin
-2.10
-
-org.apache.maven.plugins
-maven-deploy-plugin
-2.7
-
-org.apache.maven.plugins
-maven-enforcer-plugin
-1.2
-
-org.apache.maven.plugins
-maven-gpg-plugin
-1.1
-
-org.apache.maven.plugins
-maven-install-plugin
-2.3
-
-org.apache.maven.plugins
-maven-invoker-plugin
-1.10
-
-org.apache.maven.plugins
-maven-jar-plugin
-2.2
-
-org.apache.maven.plugins
-maven-javadoc-plugin
-2.7
-
-org.apache.maven.plugins
-maven-plugin-plugin
-3.4
-
-org.apache.maven.plugins
-maven-resources-plugin
-2.7
-
-org.apache.maven.plugins
-maven-scm-plugin
-1.9.4
-
-org.apache.maven.plugins
-maven-site-plugin
-3.4
-
-org.apache.maven.plugins
-maven-source-plugin
-2.1.2
- org.apache.maven.plugins
-maven-surefire-plugin
-2.10 Project Report Plugins
-
-
-
-GroupId
-ArtifactId
-Version
-
-org.apache.maven.plugins
-maven-changes-plugin
-2.11
-
-org.apache.maven.plugins
-maven-javadoc-plugin
-2.7
-
-org.apache.maven.plugins
-maven-jxr-plugin
-2.5
-
-org.apache.maven.plugins
-maven-plugin-plugin
-3.4
- org.apache.maven.plugins
-maven-pmd-plugin
-3.4 juplo
- Java bits from nerds for nerds
-
- PMD
PMD Results
-Files
-de/juplo/plugins/hibernate/AbstractSchemaMojo.java
-
-
-
-Violation
-Line
-
-Too many static imports may lead to messy code
-1–1178
-
-Avoid unused method parameters such as 'path'.
-970
- Avoid using a branching statement as the last in a loop.
-1173 de/juplo/plugins/hibernate/ModificationTracker.java
-
-
-
-Violation
-Line
- Unnecessary use of fully qualified name 'java.security.MessageDigest.getInstance' due to existing import 'java.security.MessageDigest'
-60 de/juplo/plugins/hibernate/SimpleConnectionProvider.java
-
-
-
-Violation
-Line
-
-Too many static imports may lead to messy code
-1–249
-
-Unnecessary use of fully qualified name 'java.sql.Driver' due to existing import 'java.sql.Driver'
-168
-
-Unnecessary use of fully qualified name 'java.sql.Connection' due to existing import 'java.sql.Connection'
-180
- Unnecessary use of fully qualified name 'java.util.Properties' due to existing import 'java.util.Properties'
-182 juplo
- Java bits from nerds for nerds
-
- Project Information
Project Information
-Overview
-
-
-
-Document
-Description
-
-About
-Plugin for generating a database-schema from Hibernate-Mapping-Annotations
-
-Plugin Management
-This document lists the plugins that are defined through pluginManagement.
-
-Distribution Management
-This document provides informations on the distribution management of this project.
-
-Dependency Information
-This document describes how to to include this project as a dependency using various dependency management tools.
-
-Source Repository
-This is a link to the online source repository that can be viewed via a web browser.
-
-Mailing Lists
-This document provides subscription and archive information for this project's mailing lists.
-
-Issue Tracking
-This is a link to the issue management system for this project. Issues (bugs, features, change requests) can be created and queried using this link.
-
-Continuous Integration
-This is a link to the definitions of all continuous integration processes that builds and tests code on a frequent, regular basis.
-
-Project Plugins
-This document lists the build plugins and the report plugins used by this project.
-
-Project License
-This is a link to the definitions of project licenses.
-
-Project Team
-This document provides information on the members of this project. These are the individuals who have contributed to the project in one form or another.
-
-Project Summary
-This document lists other related information of this project
- Dependencies
-This document lists the project's dependencies and provides information on each dependency. juplo
- Java bits from nerds for nerds
-
- Project Reports
Generated Reports
-Overview
-
-
-
-Document
-Description
-
-Test JavaDocs
-Test JavaDoc API documentation.
-
-JavaDocs
-JavaDoc API documentation.
-
-Source Xref
-HTML based, cross-reference version of Java source code.
-
-Test Source Xref
-HTML based, cross-reference version of Java test source code.
-
-CPD
-Duplicate code detection.
-
-PMD
-Verification of coding rules.
- Plugin Documentation
-This report provides goals and parameters documentation of a plugin. juplo
- Java bits from nerds for nerds
-
- Project Summary
Project Summary
-Project Information
-
-
-
-Field
-Value
-
-Name
-Hibernate Maven Plugin
-
-Description
-Plugin for generating a database-schema from Hibernate-Mapping-Annotations
- Homepage
-http://juplo.de/hibernate-maven-plugin juplo
- Java bits from nerds for nerds
-
- Skipping Execution
-<plugin>
- <groupId>de.juplo</groupId>
- <artifactId>hibernate-maven-plugin</artifactId>
- ...
- <configuration>
- <skip>false</skip>
- </configuration>
-</plugin>
-<plugin>
- <groupId>de.juplo</groupId>
- <artifactId>hibernate-maven-plugin</artifactId>
- ...
- <configuration>
- <skip>${foo.bar}</skip>
- </configuration>
-</plugin>
juplo
- Java bits from nerds for nerds
-
- Source Repository
Overview
-Anonymous access
-$ git clone http://juplo.de/git/hibernate-maven-plugin
Developer access
-$ git clone ssh://juplo.de/var/lib/git/juplo/hibernate-maven-plugin
juplo
- Java bits from nerds for nerds
-
- Project Team
The Team
-Members
-
-
-
-Image
-Id
-Name
-Email
-
- kai
-Kai Moritz
-kai@juplo.de Contributors
-
-
-
-Image
-Name
-Email
-
-
- Adriano Machado
-adriano.m.machado@hotmail.com
-
-
- Lorenzo Nicora
-lorenzo.nicora@nicus.it
-
-
- Eduard Szente
-eduard.szente@gmail.com
-
-
- Stephen Johnson
-stejohns@redhat.com
-
-
- Victor Tatai
-vtatai@gmail.com
-
-
- Erik-Berndt Scheper
-erik.berndt.scheper@gmail.com
-
-
- Guido Wimmel
-Wimmel.Guido@swm.de
-
-
- Joel Johnson
-mrjoel@lixil.net
-
-
- Paul K. Moore
-paulkmoore@gmail.com
-
-
- Mark Robinson
-mark@mrobinson.ca
-
-
- Claus Graf
-clausgraf@gmail.com
-
-
- Joachim Van der Auwera
-joachim@progs.be
-
- Andreas Kuhtz
-andreas.kuhtz@gmail.com All Classes
-All Classes
-Constant Field Values
-Contents
-Class FileComparator
-
-
-
-
-
-
-
-
-public class FileComparator
-extends Object
-
-
-
-
-
-Constructor Summary
-
-
-
-
-Constructor and Description
-
-
-
-FileComparator(File basedir)
-
-Method Summary
-
-
-
-
-
-Modifier and Type
-Method and Description
-
-
-
-boolean
-isEqual(String expectedFile,
- String foundFile)
-
-
-
-Method Detail
-
-
-
-
-
-isEqual
-public boolean isEqual(String expectedFile,
- String foundFile)
- throws FileNotFoundException,
- IOException
-
-
-FileNotFoundException
IOException
Uses of Class
-
de.juplo.test.FileComparatorde.juplo.test
-Classes
-
-Package de.juplo.test
-
-
-
-
-
-
-
-Class
-Description
-
-
-
-FileComparator
-
-Hierarchy For Package de.juplo.test
-Class Hierarchy
-
-
-
-
-Uses of Package
-
de.juplo.testDeprecated API
-Contents
-How This API Document Is Organized
-
-
-This help file applies to API documentation generated using the standard doclet.Package
-
-
-Class/Interface
-
-
-
-
-
-
-Annotation Type
-
-
-Enum
-
-
-Use
-Tree (Class Hierarchy)
-java.lang.Object
. The interfaces do not inherit from java.lang.Object
.
-
-Deprecated API
-Index
-Prev/Next
-Frames/No Frames
-All Classes
-Serialized Form
-Constant Field Values
-D
-
-
-
-
-
-F
-
-
-
-
-
-I
-
-
-D F I Frame Alert
-Class Hierarchy
-
-
-
-
-All Classes
-
-
-
-
-
-
diff --git a/dist/hibernate-maven-plugin-2.0.0/xref-test/de/juplo/test/FileComparator.html b/dist/hibernate-maven-plugin-2.0.0/xref-test/de/juplo/test/FileComparator.html
deleted file mode 100644
index 15fac226..00000000
--- a/dist/hibernate-maven-plugin-2.0.0/xref-test/de/juplo/test/FileComparator.html
+++ /dev/null
@@ -1,70 +0,0 @@
-
-
-
-
-1 package de.juplo.test;
-2
-3 import java.io.BufferedReader;
-4 import java.io.File;
-5 import java.io.FileNotFoundException;
-6 import java.io.FileReader;
-7 import java.io.IOException;
-8
-9
-10 public class FileComparator
-11 {
-12 private final File basedir;
-13 private BufferedReader expectedReader;
-14 private BufferedReader foundReader;
-15
-16 public FileComparator(File basedir)
-17 {
-18 this.basedir = basedir;
-19 }
-20
-21 public boolean isEqual(final String expectedFile, final String foundFile)
-22 throws
-23 FileNotFoundException,
-24 IOException
-25 {
-26 File file;
-27 String expected, found;
-28
-29 file = new File(basedir, expectedFile);
-30 expectedReader = new BufferedReader(new FileReader(file));
-31
-32 file = new File(basedir, foundFile);
-33 foundReader = new BufferedReader(new FileReader(file));
-34
-35
-36 while ((expected = expectedReader.readLine()) != null)
-37 {
-38 found = foundReader.readLine();
-39 if (!expected.equals(found))
-40 {
-41 System.err.println("Mismatch!");
-42 System.err.println("Expected: " + expected);
-43 System.err.println("Found: " + found);
-44 return false;
-45 }
-46 }
-47
-48 if ((found = foundReader.readLine()) != null)
-49 {
-50 System.err.println("Found more content than expected!");
-51 System.err.println("Starting with: " + found);
-52 return false;
-53 }
-54
-55 return true;
-56 }
-57 }
-
-
-
-
-
diff --git a/dist/hibernate-maven-plugin-2.0.0/xref-test/de/juplo/test/package-frame.html b/dist/hibernate-maven-plugin-2.0.0/xref-test/de/juplo/test/package-frame.html
deleted file mode 100644
index 9ea5ede4..00000000
--- a/dist/hibernate-maven-plugin-2.0.0/xref-test/de/juplo/test/package-frame.html
+++ /dev/null
@@ -1,24 +0,0 @@
-
-
-
-
-
-
- de.juplo.test
-
-
- Classes
-
-
-
-
-
-
\ No newline at end of file
diff --git a/dist/hibernate-maven-plugin-2.0.0/xref-test/de/juplo/test/package-summary.html b/dist/hibernate-maven-plugin-2.0.0/xref-test/de/juplo/test/package-summary.html
deleted file mode 100644
index d3e73e1e..00000000
--- a/dist/hibernate-maven-plugin-2.0.0/xref-test/de/juplo/test/package-summary.html
+++ /dev/null
@@ -1,69 +0,0 @@
-
-
-
-
-
-
-
- Package de.juplo.test
-
-
-
-
-
-
-
-
-
- Class Summary
-
-
-
-
- FileComparator
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/dist/hibernate-maven-plugin-2.0.0/xref-test/index.html b/dist/hibernate-maven-plugin-2.0.0/xref-test/index.html
deleted file mode 100644
index cc2b5579..00000000
--- a/dist/hibernate-maven-plugin-2.0.0/xref-test/index.html
+++ /dev/null
@@ -1,25 +0,0 @@
-
-
-
-
-
-
- Frame Alert
-
- All Classes
-
-
- Packages
-
-
-
-
-
-
-
diff --git a/dist/hibernate-maven-plugin-2.0.0/xref-test/overview-summary.html b/dist/hibernate-maven-plugin-2.0.0/xref-test/overview-summary.html
deleted file mode 100644
index ba82dc58..00000000
--- a/dist/hibernate-maven-plugin-2.0.0/xref-test/overview-summary.html
+++ /dev/null
@@ -1,66 +0,0 @@
-
-
-
-
-
-
-
- Hibernate Maven Plugin 2.0.0 Reference
-
-
-
-
-
-
-
-
-
- Packages
-
-
-
-
- de.juplo.test
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/dist/hibernate-maven-plugin-2.0.0/xref-test/stylesheet.css b/dist/hibernate-maven-plugin-2.0.0/xref-test/stylesheet.css
deleted file mode 100644
index 89732f81..00000000
--- a/dist/hibernate-maven-plugin-2.0.0/xref-test/stylesheet.css
+++ /dev/null
@@ -1,114 +0,0 @@
-/* Javadoc style sheet */
-/* Define colors, fonts and other style attributes here to override the defaults */
-body {
- background-color: #fff;
- font-family: Arial, Helvetica, sans-serif;
-}
-
-a:link {
- color: #00f;
-}
-a:visited {
- color: #00a;
-}
-
-a:active, a:hover {
- color: #f30 !important;
-}
-
-ul, li {
- list-style-type:none;
- margin:0;
- padding:0;
-}
-
-table td {
- padding: 3px;
- border: 1px solid #000;
-}
-table {
- width:100%;
- border: 1px solid #000;
- border-collapse: collapse;
-}
-
-div.overview {
- background-color:#ddd;
- padding: 4px 4px 4px 0;
-}
-div.overview li, div.framenoframe li {
- display: inline;
-}
-div.framenoframe {
- text-align: center;
- font-size: x-small;
-}
-div.framenoframe li {
- margin: 0 3px 0 3px;
-}
-div.overview li {
- margin:3px 3px 0 3px;
- padding: 4px;
-}
-li.selected {
- background-color:#888;
- color: #fff;
- font-weight: bold;
-}
-
-table.summary {
- margin-bottom: 20px;
-}
-table.summary td, table.summary th {
- font-weight: bold;
- text-align: left;
- padding: 3px;
-}
-table.summary th {
- background-color:#036;
- color: #fff;
-}
-table.summary td {
- background-color:#eee;
- border: 1px solid black;
-}
-
-em {
- color: #A00;
-}
-em.comment {
- color: #390;
-}
-.string {
- color: #009;
-}
-
-#overview {
- padding:2px;
-}
-
-hr {
- height: 1px;
- color: #000;
-}
-
-/* JXR style sheet */
-.jxr_comment
-{
- color: #390;
-}
-
-.jxr_javadoccomment
-{
- color: #A00;
-}
-
-.jxr_string
-{
- color: #009;
-}
-
-.jxr_keyword
-{
- color: #000;
-}
diff --git a/dist/hibernate-maven-plugin-2.0.0/xref/allclasses-frame.html b/dist/hibernate-maven-plugin-2.0.0/xref/allclasses-frame.html
deleted file mode 100644
index 563b5e91..00000000
--- a/dist/hibernate-maven-plugin-2.0.0/xref/allclasses-frame.html
+++ /dev/null
@@ -1,41 +0,0 @@
-
-
-
-
-
- All Classes
-
-
-
-
-
-
diff --git a/dist/hibernate-maven-plugin-2.0.0/xref/de/juplo/plugins/hibernate/AbstractSchemaMojo.html b/dist/hibernate-maven-plugin-2.0.0/xref/de/juplo/plugins/hibernate/AbstractSchemaMojo.html
deleted file mode 100644
index 16fa7a9e..00000000
--- a/dist/hibernate-maven-plugin-2.0.0/xref/de/juplo/plugins/hibernate/AbstractSchemaMojo.html
+++ /dev/null
@@ -1,1191 +0,0 @@
-
-
-
-
-1 package de.juplo.plugins.hibernate;
-2
-3
-4 import com.pyx4j.log4j.MavenLogAppender;
-5 import java.io.File;
-6 import java.io.FileInputStream;
-7 import java.io.IOException;
-8 import java.io.InputStream;
-9 import java.net.MalformedURLException;
-10 import java.net.URL;
-11 import java.security.NoSuchAlgorithmException;
-12 import java.util.Collections;
-13 import java.util.HashSet;
-14 import java.util.Iterator;
-15 import java.util.LinkedHashSet;
-16 import java.util.List;
-17 import java.util.Map;
-18 import java.util.Map.Entry;
-19 import java.util.Properties;
-20 import java.util.Set;
-21 import java.util.regex.Matcher;
-22 import java.util.regex.Pattern;
-23 import javax.persistence.Embeddable;
-24 import javax.persistence.Entity;
-25 import javax.persistence.MappedSuperclass;
-26 import javax.persistence.spi.PersistenceUnitTransactionType;
-27 import org.apache.maven.artifact.Artifact;
-28 import org.apache.maven.model.Resource;
-29 import org.apache.maven.plugin.AbstractMojo;
-30 import org.apache.maven.plugin.MojoExecutionException;
-31 import org.apache.maven.plugin.MojoFailureException;
-32 import org.apache.maven.project.MavenProject;
-33 import org.hibernate.boot.MetadataBuilder;
-34 import org.hibernate.boot.MetadataSources;
-35 import org.hibernate.boot.cfgxml.internal.ConfigLoader;
-36 import org.hibernate.boot.cfgxml.spi.LoadedConfig;
-37 import org.hibernate.boot.cfgxml.spi.MappingReference;
-38 import org.hibernate.boot.model.naming.ImplicitNamingStrategy;
-39 import org.hibernate.boot.model.naming.PhysicalNamingStrategy;
-40 import org.hibernate.boot.registry.BootstrapServiceRegistry;
-41 import org.hibernate.boot.registry.BootstrapServiceRegistryBuilder;
-42 import org.hibernate.boot.registry.StandardServiceRegistry;
-43 import org.hibernate.boot.registry.StandardServiceRegistryBuilder;
-44 import org.hibernate.boot.registry.classloading.spi.ClassLoaderService;
-45 import org.hibernate.boot.registry.classloading.spi.ClassLoadingException;
-46 import org.hibernate.boot.registry.selector.spi.StrategySelector;
-47 import org.hibernate.boot.spi.MetadataImplementor;
-48 import static org.hibernate.cfg.AvailableSettings.DIALECT;
-49 import static org.hibernate.cfg.AvailableSettings.DRIVER;
-50 import static org.hibernate.cfg.AvailableSettings.FORMAT_SQL;
-51 import static org.hibernate.cfg.AvailableSettings.HBM2DLL_CREATE_NAMESPACES;
-52 import static org.hibernate.cfg.AvailableSettings.IMPLICIT_NAMING_STRATEGY;
-53 import static org.hibernate.cfg.AvailableSettings.PASS;
-54 import static org.hibernate.cfg.AvailableSettings.PHYSICAL_NAMING_STRATEGY;
-55 import static org.hibernate.cfg.AvailableSettings.SHOW_SQL;
-56 import static org.hibernate.cfg.AvailableSettings.USER;
-57 import static org.hibernate.cfg.AvailableSettings.URL;
-58 import org.hibernate.engine.jdbc.connections.spi.ConnectionProvider;
-59 import org.hibernate.internal.util.config.ConfigurationException;
-60 import static org.hibernate.jpa.AvailableSettings.JDBC_DRIVER;
-61 import static org.hibernate.jpa.AvailableSettings.JDBC_PASSWORD;
-62 import static org.hibernate.jpa.AvailableSettings.JDBC_URL;
-63 import static org.hibernate.jpa.AvailableSettings.JDBC_USER;
-64 import org.hibernate.jpa.boot.internal.ParsedPersistenceXmlDescriptor;
-65 import org.hibernate.jpa.boot.internal.PersistenceXmlParser;
-66 import org.hibernate.jpa.boot.spi.ProviderChecker;
-67 import org.scannotation.AnnotationDB;
-68
-69
-70 /**
-71 * Baseclass with common attributes and methods.
-72 *
-73 * @phase process-classes
-74 * @threadSafe
-75 * @requiresDependencyResolution runtime
-76 */
-77 public abstract class AbstractSchemaMojo extends AbstractMojo
-78 {
-79 public final static String EXPORT = "hibernate.schema.export";
-80 public final static String DELIMITER = "hibernate.schema.delimiter";
-81 public final static String OUTPUTDIRECTORY = "project.build.outputDirectory";
-82 public final static String SCAN_CLASSES = "hibernate.schema.scan.classes";
-83 public final static String SCAN_DEPENDENCIES = "hibernate.schema.scan.dependencies";
-84 public final static String SCAN_TESTCLASSES = "hibernate.schema.scan.test_classes";
-85 public final static String TEST_OUTPUTDIRECTORY = "project.build.testOutputDirectory";
-86 public final static String SKIPPED = "hibernate.schema.skipped";
-87
-88 private final static Pattern SPLIT = Pattern.compile("[^,\\s]+");
-89
-90 private final Set<String> packages = new HashSet<String>();
-91
-92 /**
-93 * The maven project.
-94 * <p>
-95 * Only needed internally.
-96 *
-97 * @parameter property="project"
-98 * @required
-99 * @readonly
-100 */
-101 private MavenProject project;
-102
-103 /**
-104 * Build-directory.
-105 * <p>
-106 * Only needed internally.
-107 *
-108 * @parameter property="project.build.directory"
-109 * @required
-110 * @readonly
-111 */
-112 String buildDirectory;
-113
-114
-115 /** Parameters to configure the genaration of the SQL *********************/
-116
-117 /**
-118 * Export the database-schma to the database.
-119 * If set to <code>false</code>, only the SQL-script is created and the
-120 * database is not touched.
-121 * <p>
-122 * <strong>Important:</strong>
-123 * This configuration value can only be configured through the
-124 * <code>pom.xml</code>, or by the definition of a system-property, because
-125 * it is not known by Hibernate nor JPA and, hence, not picked up from
-126 * their configuration!
-127 *
-128 * @parameter property="hibernate.schema.export" default-value="true"
-129 * @since 2.0
-130 */
-131 Boolean export;
-132
-133 /**
-134 * Skip execution
-135 * <p>
-136 * If set to <code>true</code>, the execution is skipped.
-137 * <p>
-138 * A skipped execution is signaled via the maven-property
-139 * <code>${hibernate.schema.skipped}</code>.
-140 * <p>
-141 * The execution is skipped automatically, if no modified or newly added
-142 * annotated classes are found and the dialect was not changed.
-143 * <p>
-144 * <strong>Important:</strong>
-145 * This configuration value can only be configured through the
-146 * <code>pom.xml</code>, or by the definition of a system-property, because
-147 * it is not known by Hibernate nor JPA and, hence, not picked up from
-148 * their configuration!
-149 *
-150 * @parameter property="hibernate.schema.skip" default-value="${maven.test.skip}"
-151 * @since 1.0
-152 */
-153 private boolean skip;
-154
-155 /**
-156 * Force execution
-157 * <p>
-158 * Force execution, even if no modified or newly added annotated classes
-159 * where found and the dialect was not changed.
-160 * <p>
-161 * <code>skip</code> takes precedence over <code>force</code>.
-162 * <p>
-163 * <strong>Important:</strong>
-164 * This configuration value can only be configured through the
-165 * <code>pom.xml</code>, or by the definition of a system-property, because
-166 * it is not known by Hibernate nor JPA and, hence, not picked up from
-167 * their configuration!
-168 *
-169 * @parameter property="hibernate.schema.force" default-value="false"
-170 * @since 1.0
-171 */
-172 private boolean force;
-173
-174 /**
-175 * Hibernate dialect.
-176 *
-177 * @parameter property="hibernate.dialect"
-178 * @since 1.0
-179 */
-180 private String dialect;
-181
-182 /**
-183 * Delimiter in output-file.
-184 * <p>
-185 * <strong>Important:</strong>
-186 * This configuration value can only be configured through the
-187 * <code>pom.xml</code>, or by the definition of a system-property, because
-188 * it is not known by Hibernate nor JPA and, hence, not picked up from
-189 * their configuration!
-190 *
-191 * @parameter property="hibernate.schema.delimiter" default-value=";"
-192 * @since 1.0
-193 */
-194 String delimiter;
-195
-196 /**
-197 * Show the generated SQL in the command-line output.
-198 *
-199 * @parameter property="hibernate.show_sql"
-200 * @since 1.0
-201 */
-202 Boolean show;
-203
-204 /**
-205 * Format output-file.
-206 *
-207 * @parameter property="hibernate.format_sql"
-208 * @since 1.0
-209 */
-210 Boolean format;
-211
-212 /**
-213 * Specifies whether to automatically create also the database schema/catalog.
-214 *
-215 * @parameter property="hibernate.hbm2dll.create_namespaces" default-value="false"
-216 * @since 2.0
-217 */
-218 Boolean createNamespaces;
-219
-220 /**
-221 * Implicit naming strategy
-222 *
-223 * @parameter property="hibernate.implicit_naming_strategy"
-224 * @since 2.0
-225 */
-226 private String implicitNamingStrategy;
-227
-228 /**
-229 * Physical naming strategy
-230 *
-231 * @parameter property="hibernate.physical_naming_strategy"
-232 * @since 2.0
-233 */
-234 private String physicalNamingStrategy;
-235
-236 /**
-237 * Wether the project should be scanned for annotated-classes, or not
-238 * <p>
-239 * This parameter is intended to allow overwriting of the parameter
-240 * <code>exclude-unlisted-classes</code> of a <code>persistence-unit</code>.
-241 * If not specified, it defaults to <code>true</code>
-242 *
-243 * @parameter property="hibernate.schema.scan.classes"
-244 * @since 2.0
-245 */
-246 private Boolean scanClasses;
-247
-248 /**
-249 * Classes-Directory to scan.
-250 * <p>
-251 * This parameter defaults to the maven build-output-directory for classes.
-252 * Additionally, all dependencies are scanned for annotated classes.
-253 * <p>
-254 * <strong>Important:</strong>
-255 * This configuration value can only be configured through the
-256 * <code>pom.xml</code>, or by the definition of a system-property, because
-257 * it is not known by Hibernate nor JPA and, hence, not picked up from
-258 * their configuration!
-259 *
-260 * @parameter property="project.build.outputDirectory"
-261 * @since 1.0
-262 */
-263 private String outputDirectory;
-264
-265 /**
-266 * Dependency-Scopes, that should be scanned for annotated classes.
-267 * <p>
-268 * By default, only dependencies in the scope <code>compile</code> are
-269 * scanned for annotated classes. Multiple scopes can be seperated by
-270 * white space or commas.
-271 * <p>
-272 * If you do not want any dependencies to be scanned for annotated
-273 * classes, set this parameter to <code>none</code>.
-274 * <p>
-275 * The plugin does not scan for annotated classes in transitive
-276 * dependencies. If some of your annotated classes are hidden in a
-277 * transitive dependency, you can simply add that dependency explicitly.
-278 *
-279 * @parameter property="hibernate.schema.scan.dependencies" default-value="compile"
-280 * @since 1.0.3
-281 */
-282 private String scanDependencies;
-283
-284 /**
-285 * Whether to scan the test-branch of the project for annotated classes, or
-286 * not.
-287 * <p>
-288 * If this parameter is set to <code>true</code> the test-classes of the
-289 * artifact will be scanned for hibernate-annotated classes additionally.
-290 * <p>
-291 * <strong>Important:</strong>
-292 * This configuration value can only be configured through the
-293 * <code>pom.xml</code>, or by the definition of a system-property, because
-294 * it is not known by Hibernate nor JPA and, hence, not picked up from
-295 * their configuration!
-296 *
-297 * @parameter property="hibernate.schema.scan.test_classes" default-value="false"
-298 * @since 1.0.1
-299 */
-300 private Boolean scanTestClasses;
-301
-302 /**
-303 * Test-Classes-Directory to scan.
-304 * <p>
-305 * This parameter defaults to the maven build-output-directory for
-306 * test-classes.
-307 * <p>
-308 * This parameter is only used, when <code>scanTestClasses</code> is set
-309 * to <code>true</code>!
-310 * <p>
-311 * <strong>Important:</strong>
-312 * This configuration value can only be configured through the
-313 * <code>pom.xml</code>, or by the definition of a system-property, because
-314 * it is not known by Hibernate nor JPA and, hence, not picked up from
-315 * their configuration!
-316 *
-317 * @parameter property="project.build.testOutputDirectory"
-318 * @since 1.0.2
-319 */
-320 private String testOutputDirectory;
-321
-322
-323 /** Conection parameters *************************************************/
-324
-325 /**
-326 * SQL-Driver name.
-327 *
-328 * @parameter property="hibernate.connection.driver_class"
-329 * @since 1.0
-330 */
-331 private String driver;
-332
-333 /**
-334 * Database URL.
-335 *
-336 * @parameter property="hibernate.connection.url"
-337 * @since 1.0
-338 */
-339 private String url;
-340
-341 /**
-342 * Database username
-343 *
-344 * @parameter property="hibernate.connection.username"
-345 * @since 1.0
-346 */
-347 private String username;
-348
-349 /**
-350 * Database password
-351 *
-352 * @parameter property="hibernate.connection.password"
-353 * @since 1.0
-354 */
-355 private String password;
-356
-357
-358 /** Parameters to locate configuration sources ****************************/
-359
-360 /**
-361 * Path to a file or name of a ressource with hibernate properties.
-362 * If this parameter is specified, the plugin will try to load configuration
-363 * values from a file with the given path or a ressource on the classpath with
-364 * the given name. If both fails, the execution of the plugin will fail.
-365 * <p>
-366 * If this parameter is not set the plugin will load configuration values
-367 * from a ressource named <code>hibernate.properties</code> on the classpath,
-368 * if it is present, but will not fail if there is no such ressource.
-369 * <p>
-370 * During ressource-lookup, the test-classpath takes precedence.
-371 *
-372 * @parameter
-373 * @since 1.0
-374 */
-375 private String hibernateProperties;
-376
-377 /**
-378 * Path to Hibernate configuration file (.cfg.xml).
-379 * If this parameter is specified, the plugin will try to load configuration
-380 * values from a file with the given path or a ressource on the classpath with
-381 * the given name. If both fails, the execution of the plugin will fail.
-382 * <p>
-383 * If this parameter is not set the plugin will load configuration values
-384 * from a ressource named <code>hibernate.cfg.xml</code> on the classpath,
-385 * if it is present, but will not fail if there is no such ressource.
-386 * <p>
-387 * During ressource-lookup, the test-classpath takes precedence.
-388 * <p>
-389 * Settings in this file will overwrite settings in the properties file.
-390 *
-391 * @parameter
-392 * @since 1.1.0
-393 */
-394 private String hibernateConfig;
-395
-396 /**
-397 * Name of the persistence-unit.
-398 * If this parameter is specified, the plugin will try to load configuration
-399 * values from a persistence-unit with the specified name. If no such
-400 * persistence-unit can be found, the plugin will throw an exception.
-401 * <p>
-402 * If this parameter is not set and there is only one persistence-unit
-403 * available, that unit will be used automatically. But if this parameter is
-404 * not set and there are multiple persistence-units available on,
-405 * the class-path, the execution of the plugin will fail.
-406 * <p>
-407 * Settings in this file will overwrite settings in the properties or the
-408 * configuration file.
-409 *
-410 * @parameter
-411 * @since 1.1.0
-412 */
-413 private String persistenceUnit;
-414
-415 /**
-416 * List of Hibernate-Mapping-Files (XML).
-417 * Multiple files can be separated with white-spaces and/or commas.
-418 *
-419 * @parameter property="hibernate.mapping"
-420 * @since 1.0.2
-421 */
-422 private String mappings;
-423
-424
-425
-426 public final void execute(String filename)
-427 throws
-428 MojoFailureException,
-429 MojoExecutionException
-430 {
-431 if (skip)
-432 {
-433 getLog().info("Execution of hibernate-maven-plugin was skipped!");
-434 project.getProperties().setProperty(SKIPPED, "true");
-435 return;
-436 }
-437
-438 ModificationTracker tracker;
-439 try
-440 {
-441 tracker = new ModificationTracker(buildDirectory, filename, getLog());
-442 }
-443 catch (NoSuchAlgorithmException e)
-444 {
-445 throw new MojoFailureException("Digest-Algorithm MD5 is missing!", e);
-446 }
-447
-448 SimpleConnectionProvider connectionProvider =
-449 new SimpleConnectionProvider(getLog());
-450
-451 try
-452 {
-453 /** Start extended logging */
-454 MavenLogAppender.startPluginLog(this);
-455
-456 /** Load checksums for old mapping and configuration */
-457 tracker.load();
-458
-459 /** Create the ClassLoader */
-460 MutableClassLoader classLoader = createClassLoader();
-461
-462 /** Create a BootstrapServiceRegistry with the created ClassLoader */
-463 BootstrapServiceRegistry bootstrapServiceRegitry =
-464 new BootstrapServiceRegistryBuilder()
-465 .applyClassLoader(classLoader)
-466 .build();
-467 ClassLoaderService classLoaderService =
-468 bootstrapServiceRegitry.getService(ClassLoaderService.class);
-469
-470 Properties properties = new Properties();
-471 ConfigLoader configLoader = new ConfigLoader(bootstrapServiceRegitry);
-472
-473 /** Loading and merging configuration */
-474 properties.putAll(loadProperties(configLoader));
-475 LoadedConfig config = loadConfig(configLoader);
-476 if (config != null)
-477 properties.putAll(config.getConfigurationValues());
-478 ParsedPersistenceXmlDescriptor unit =
-479 loadPersistenceUnit(classLoaderService, properties);
-480 if (unit != null)
-481 properties.putAll(unit.getProperties());
-482
-483 /** Overwriting/Completing configuration */
-484 configure(properties, tracker);
-485
-486 /** Check configuration for modifications */
-487 if(tracker.track(properties))
-488 getLog().debug("Configuration has changed.");
-489 else
-490 getLog().debug("Configuration unchanged.");
-491
-492 /** Configure Hibernate */
-493 StandardServiceRegistry serviceRegistry =
-494 new StandardServiceRegistryBuilder(bootstrapServiceRegitry)
-495 .applySettings(properties)
-496 .addService(ConnectionProvider.class, connectionProvider)
-497 .build();
-498 MetadataSources sources = new MetadataSources(serviceRegistry);
-499
-500 /** Add the remaining class-path-elements */
-501 completeClassPath(classLoader);
-502
-503 /** Apply mappings from hibernate-configuration, if present */
-504 if (config != null)
-505 {
-506 for (MappingReference mapping : config.getMappingReferences())
-507 mapping.apply(sources);
-508 }
-509
-510 Set<String> classes;
-511 if (unit == null)
-512 {
-513 /** No persistent unit: default behaviour */
-514 if (scanClasses == null)
-515 scanClasses = true;
-516 Set<URL> urls = new HashSet<URL>();
-517 if (scanClasses)
-518 addRoot(urls, outputDirectory);
-519 if (scanTestClasses)
-520 addRoot(urls, testOutputDirectory);
-521 addDependencies(urls);
-522 classes = scanUrls(urls);
-523 }
-524 else
-525 {
-526 /** Follow configuration in persisten unit */
-527 if (scanClasses == null)
-528 scanClasses = !unit.isExcludeUnlistedClasses();
-529 Set<URL> urls = new HashSet<URL>();
-530 if (scanClasses)
-531 {
-532 /**
-533 * Scan the root of the persiten unit and configured jars for
-534 * annotated classes
-535 */
-536 urls.add(unit.getPersistenceUnitRootUrl());
-537 for (URL url : unit.getJarFileUrls())
-538 urls.add(url);
-539 }
-540 if (scanTestClasses)
-541 addRoot(urls, testOutputDirectory);
-542 classes = scanUrls(urls);
-543 for (String className : unit.getManagedClassNames())
-544 classes.add(className);
-545 /**
-546 * Add mappings from the default mapping-file
-547 * <code>META-INF/orm.xml</code>, if present
-548 */
-549 try
-550 {
-551 InputStream is = classLoader.getResourceAsStream("META-INF/orm.xml");
-552 if (is != null)
-553 {
-554 getLog().info("Adding default JPA-XML-mapping from META-INF/orm.xml");
-555 tracker.track("META-INF/orm.xml", is);
-556 sources.addResource("META-INF/orm.xml");
-557 }
-558 /**
-559 * Add mappings from files, that are explicitly configured in the
-560 * persistence unit
-561 */
-562 for (String mapping : unit.getMappingFileNames())
-563 {
-564 getLog().info("Adding explicitly configured mapping from " + mapping);
-565 tracker.track(mapping, classLoader.getResourceAsStream(mapping));
-566 sources.addResource(mapping);
-567 }
-568 }
-569 catch (IOException e)
-570 {
-571 throw new MojoFailureException("Error reading XML-mappings", e);
-572 }
-573 }
-574
-575 /** Add the configured/collected annotated classes */
-576 for (String className : classes)
-577 addAnnotated(className, sources, classLoaderService, tracker);
-578
-579 /** Add explicitly configured classes */
-580 addMappings(sources, tracker);
-581
-582 /** Skip execution, if mapping and configuration is unchanged */
-583 if (!tracker.modified())
-584 {
-585 getLog().info(
-586 "Mapping and configuration unchanged."
-587 );
-588 if (force)
-589 getLog().info("Schema generation is forced!");
-590 else
-591 {
-592 getLog().info("Skipping schema generation!");
-593 project.getProperties().setProperty(SKIPPED, "true");
-594 return;
-595 }
-596 }
-597
-598
-599 /** Create a connection, if sufficient configuration infromation is available */
-600 connectionProvider.open(classLoaderService, properties);
-601
-602 MetadataBuilder metadataBuilder = sources.getMetadataBuilder();
-603
-604 StrategySelector strategySelector =
-605 serviceRegistry.getService(StrategySelector.class);
-606
-607 if (properties.containsKey(IMPLICIT_NAMING_STRATEGY))
-608 {
-609 metadataBuilder.applyImplicitNamingStrategy(
-610 strategySelector.resolveStrategy(
-611 ImplicitNamingStrategy.class,
-612 properties.getProperty(IMPLICIT_NAMING_STRATEGY)
-613 )
-614 );
-615 }
-616
-617 if (properties.containsKey(PHYSICAL_NAMING_STRATEGY))
-618 {
-619 metadataBuilder.applyPhysicalNamingStrategy(
-620 strategySelector.resolveStrategy(
-621 PhysicalNamingStrategy.class,
-622 properties.getProperty(PHYSICAL_NAMING_STRATEGY)
-623 )
-624 );
-625 }
-626
-627 /**
-628 * Change class-loader of current thread.
-629 * This is necessary, because still not all parts of Hibernate 5 use
-630 * the newly introduced ClassLoaderService and will fail otherwise!
-631 */
-632 Thread thread = Thread.currentThread();
-633 ClassLoader contextClassLoader = thread.getContextClassLoader();
-634 try
-635 {
-636 thread.setContextClassLoader(classLoader);
-637 build((MetadataImplementor)metadataBuilder.build());
-638 }
-639 finally
-640 {
-641 thread.setContextClassLoader(contextClassLoader);
-642 }
-643 }
-644 catch (MojoExecutionException e)
-645 {
-646 tracker.failed();
-647 throw e;
-648 }
-649 catch (MojoFailureException e)
-650 {
-651 tracker.failed();
-652 throw e;
-653 }
-654 catch (RuntimeException e)
-655 {
-656 tracker.failed();
-657 throw e;
-658 }
-659 finally
-660 {
-661 /** Remember mappings and configuration */
-662 tracker.save();
-663
-664 /** Close the connection - if one was opened */
-665 connectionProvider.close();
-666
-667 /** Stop Log-Capturing */
-668 MavenLogAppender.endPluginLog(this);
-669 }
-670 }
-671
-672
-673 abstract void build(MetadataImplementor metadata)
-674 throws
-675 MojoFailureException,
-676 MojoExecutionException;
-677
-678
-679 private MutableClassLoader createClassLoader() throws MojoExecutionException
-680 {
-681 try
-682 {
-683 getLog().debug("Creating ClassLoader for project-dependencies...");
-684 LinkedHashSet<URL> urls = new LinkedHashSet<URL>();
-685 File file;
-686
-687 file = new File(testOutputDirectory);
-688 if (!file.exists())
-689 {
-690 getLog().info("Creating test-output-directory: " + testOutputDirectory);
-691 file.mkdirs();
-692 }
-693 urls.add(file.toURI().toURL());
-694
-695 file = new File(outputDirectory);
-696 if (!file.exists())
-697 {
-698 getLog().info("Creating output-directory: " + outputDirectory);
-699 file.mkdirs();
-700 }
-701 urls.add(file.toURI().toURL());
-702
-703 return new MutableClassLoader(urls, getLog());
-704 }
-705 catch (Exception e)
-706 {
-707 getLog().error("Error while creating ClassLoader!", e);
-708 throw new MojoExecutionException(e.getMessage());
-709 }
-710 }
-711
-712 private void completeClassPath(MutableClassLoader classLoader)
-713 throws
-714 MojoExecutionException
-715 {
-716 try
-717 {
-718 getLog().debug("Completing class-paths of the ClassLoader for project-dependencies...");
-719 List<String> classpathFiles = project.getCompileClasspathElements();
-720 if (scanTestClasses)
-721 classpathFiles.addAll(project.getTestClasspathElements());
-722 LinkedHashSet<URL> urls = new LinkedHashSet<URL>();
-723 for (String pathElement : classpathFiles)
-724 {
-725 getLog().debug("Dependency: " + pathElement);
-726 urls.add(new File(pathElement).toURI().toURL());
-727 }
-728 classLoader.add(urls);
-729 }
-730 catch (Exception e)
-731 {
-732 getLog().error("Error while creating ClassLoader!", e);
-733 throw new MojoExecutionException(e.getMessage());
-734 }
-735 }
-736
-737 private Map loadProperties(ConfigLoader configLoader)
-738 throws
-739 MojoExecutionException
-740 {
-741 /** Try to read configuration from properties-file */
-742 if (hibernateProperties == null)
-743 {
-744 try
-745 {
-746 return configLoader.loadProperties("hibernate.properties");
-747 }
-748 catch (ConfigurationException e)
-749 {
-750 getLog().debug(e.getMessage());
-751 return Collections.EMPTY_MAP;
-752 }
-753 }
-754 else
-755 {
-756 try
-757 {
-758 File file = new File(hibernateProperties);
-759 if (file.exists())
-760 {
-761 getLog().info("Reading settings from file " + hibernateProperties + "...");
-762 return configLoader.loadProperties(file);
-763 }
-764 else
-765 return configLoader.loadProperties(hibernateProperties);
-766 }
-767 catch (ConfigurationException e)
-768 {
-769 getLog().error("Error while reading properties!", e);
-770 throw new MojoExecutionException(e.getMessage());
-771 }
-772 }
-773 }
-774
-775 private LoadedConfig loadConfig(ConfigLoader configLoader)
-776 throws MojoExecutionException
-777 {
-778 /** Try to read configuration from configuration-file */
-779 if (hibernateConfig == null)
-780 {
-781 try
-782 {
-783 return configLoader.loadConfigXmlResource("hibernate.cfg.xml");
-784 }
-785 catch (ConfigurationException e)
-786 {
-787 getLog().debug(e.getMessage());
-788 return null;
-789 }
-790 }
-791 else
-792 {
-793 try
-794 {
-795 File file = new File(hibernateConfig);
-796 if (file.exists())
-797 {
-798 getLog().info("Reading configuration from file " + hibernateConfig + "...");
-799 return configLoader.loadConfigXmlFile(file);
-800 }
-801 else
-802 {
-803 return configLoader.loadConfigXmlResource(hibernateConfig);
-804 }
-805 }
-806 catch (ConfigurationException e)
-807 {
-808 getLog().error("Error while reading configuration!", e);
-809 throw new MojoExecutionException(e.getMessage());
-810 }
-811 }
-812 }
-813
-814 private void configure(Properties properties, ModificationTracker tracker)
-815 throws MojoFailureException
-816 {
-817 /**
-818 * Special treatment for the configuration-value "export": if it is
-819 * switched to "true", the genearation fo the schema should be forced!
-820 */
-821 if (tracker.check(EXPORT, export.toString()) && export)
-822 tracker.touch();
-823
-824 /**
-825 * Configure the generation of the SQL.
-826 * Overwrite values from properties-file if the configuration parameter is
-827 * known to Hibernate.
-828 */
-829 dialect = configure(properties, dialect, DIALECT);
-830 tracker.track(DELIMITER, delimiter); // << not reflected in hibernate configuration!
-831 format = configure(properties, format, FORMAT_SQL);
-832 createNamespaces = configure(properties, createNamespaces, HBM2DLL_CREATE_NAMESPACES);
-833 implicitNamingStrategy = configure(properties, implicitNamingStrategy, IMPLICIT_NAMING_STRATEGY);
-834 physicalNamingStrategy = configure(properties, physicalNamingStrategy, PHYSICAL_NAMING_STRATEGY);
-835 tracker.track(OUTPUTDIRECTORY, outputDirectory); // << not reflected in hibernate configuration!
-836 tracker.track(SCAN_DEPENDENCIES, scanDependencies); // << not reflected in hibernate configuration!
-837 tracker.track(SCAN_TESTCLASSES, scanTestClasses.toString()); // << not reflected in hibernate configuration!
-838 tracker.track(TEST_OUTPUTDIRECTORY, testOutputDirectory); // << not reflected in hibernate configuration!
-839
-840 /**
-841 * Special treatment for the configuration-value "show": a change of its
-842 * configured value should not lead to a regeneration of the database
-843 * schama!
-844 */
-845 if (show == null)
-846 show = Boolean.valueOf(properties.getProperty(SHOW_SQL));
-847 else
-848 properties.setProperty(SHOW_SQL, show.toString());
-849
-850 /**
-851 * Configure the connection parameters.
-852 * Overwrite values from properties-file.
-853 */
-854 driver = configure(properties, driver, DRIVER, JDBC_DRIVER);
-855 url = configure(properties, url, URL, JDBC_URL);
-856 username = configure(properties, username, USER, JDBC_USER);
-857 password = configure(properties, password, PASS, JDBC_PASSWORD);
-858
-859 if (properties.isEmpty())
-860 {
-861 getLog().error("No properties set!");
-862 throw new MojoFailureException("Hibernate configuration is missing!");
-863 }
-864
-865 getLog().info("Gathered hibernate-configuration (turn on debugging for details):");
-866 for (Entry<Object,Object> entry : properties.entrySet())
-867 getLog().info(" " + entry.getKey() + " = " + entry.getValue());
-868 }
-869
-870 private String configure(
-871 Properties properties,
-872 String value,
-873 String key,
-874 String alternativeKey
-875 )
-876 {
-877 value = configure(properties, value, key);
-878 if (value == null)
-879 return properties.getProperty(alternativeKey);
-880
-881 if (properties.containsKey(alternativeKey))
-882 {
-883 getLog().warn(
-884 "Ignoring property " + alternativeKey + "=" +
-885 properties.getProperty(alternativeKey) + " in favour for property " +
-886 key + "=" + properties.getProperty(key)
-887 );
-888 properties.remove(alternativeKey);
-889 }
-890 return properties.getProperty(alternativeKey);
-891 }
-892
-893 private String configure(Properties properties, String value, String key)
-894 {
-895 if (value != null)
-896 {
-897 if (properties.containsKey(key))
-898 getLog().debug(
-899 "Overwriting property " + key + "=" + properties.getProperty(key) +
-900 " with the value " + value
-901 );
-902 else
-903 getLog().debug("Using the value " + value + " for property " + key);
-904 properties.setProperty(key, value);
-905 }
-906 return properties.getProperty(key);
-907 }
-908
-909 private boolean configure(Properties properties, Boolean value, String key)
-910 {
-911 if (value != null)
-912 {
-913 if (properties.containsKey(key))
-914 getLog().debug(
-915 "Overwriting property " + key + "=" + properties.getProperty(key) +
-916 " with the value " + value
-917 );
-918 else
-919 getLog().debug("Using the value " + value + " for property " + key);
-920 properties.setProperty(key, value.toString());
-921 }
-922 return Boolean.valueOf(properties.getProperty(key));
-923 }
-924
-925 private void addMappings(MetadataSources sources, ModificationTracker tracker)
-926 throws MojoFailureException
-927 {
-928 getLog().debug("Adding explicitly configured mappings...");
-929 if (mappings != null)
-930 {
-931 try
-932 {
-933 for (String filename : mappings.split("[\\s,]+"))
-934 {
-935 // First try the filename as absolute/relative path
-936 File file = new File(filename);
-937 if (!file.exists())
-938 {
-939 // If the file was not found, search for it in the resource-directories
-940 for (Resource resource : project.getResources())
-941 {
-942 file = new File(resource.getDirectory() + File.separator + filename);
-943 if (file.exists())
-944 break;
-945 }
-946 }
-947 if (file.exists())
-948 {
-949 if (file.isDirectory())
-950 // TODO: add support to read all mappings under a directory
-951 throw new MojoFailureException(file.getAbsolutePath() + " is a directory");
-952 if (tracker.track(filename, new FileInputStream(file)))
-953 getLog().debug("Found new or modified mapping-file: " + filename);
-954 else
-955 getLog().debug("Mapping-file unchanged: " + filename);
-956
-957 sources.addFile(file);
-958 }
-959 else
-960 throw new MojoFailureException("File " + filename + " could not be found in any of the configured resource-directories!");
-961 }
-962 }
-963 catch (IOException e)
-964 {
-965 throw new MojoFailureException("Cannot calculate MD5 sums!", e);
-966 }
-967 }
-968 }
-969
-970 private void addRoot(Set<URL> urls, String path) throws MojoFailureException
-971 {
-972 try
-973 {
-974 File dir = new File(outputDirectory);
-975 if (dir.exists())
-976 {
-977 getLog().info("Adding " + dir.getAbsolutePath() + " to the list of roots to scan...");
-978 urls.add(dir.toURI().toURL());
-979 }
-980 }
-981 catch (MalformedURLException e)
-982 {
-983 getLog().error("error while adding the project-root to the list of roots to scan!", e);
-984 throw new MojoFailureException(e.getMessage());
-985 }
-986 }
-987
-988 private void addDependencies(Set<URL> urls) throws MojoFailureException
-989 {
-990 try
-991 {
-992 if (scanDependencies != null)
-993 {
-994 Matcher matcher = SPLIT.matcher(scanDependencies);
-995 while (matcher.find())
-996 {
-997 getLog().info("Adding dependencies from scope " + matcher.group() + " to the list of roots to scan");
-998 for (Artifact artifact : project.getDependencyArtifacts())
-999 {
-1000 if (!artifact.getScope().equalsIgnoreCase(matcher.group()))
-1001 continue;
-1002 if (artifact.getFile() == null)
-1003 {
-1004 getLog().warn("Cannot add dependency " + artifact.getId() + ": no JAR-file available!");
-1005 continue;
-1006 }
-1007 getLog().info("Adding dependencies from scope " + artifact.getId() + " to the list of roots to scan");
-1008 urls.add(artifact.getFile().toURI().toURL());
-1009 }
-1010 }
-1011 }
-1012 }
-1013 catch (MalformedURLException e)
-1014 {
-1015 getLog().error("Error while adding dependencies to the list of roots to scan!", e);
-1016 throw new MojoFailureException(e.getMessage());
-1017 }
-1018 }
-1019
-1020 private Set<String> scanUrls(Set<URL> scanRoots)
-1021 throws
-1022 MojoFailureException
-1023 {
-1024 try
-1025 {
-1026 AnnotationDB db = new AnnotationDB();
-1027 for (URL root : scanRoots)
-1028 db.scanArchives(root);
-1029
-1030 Set<String> classes = new HashSet<String>();
-1031 if (db.getAnnotationIndex().containsKey(Entity.class.getName()))
-1032 classes.addAll(db.getAnnotationIndex().get(Entity.class.getName()));
-1033 if (db.getAnnotationIndex().containsKey(MappedSuperclass.class.getName()))
-1034 classes.addAll(db.getAnnotationIndex().get(MappedSuperclass.class.getName()));
-1035 if (db.getAnnotationIndex().containsKey(Embeddable.class.getName()))
-1036 classes.addAll(db.getAnnotationIndex().get(Embeddable.class.getName()));
-1037
-1038 return classes;
-1039 }
-1040 catch (Exception e)
-1041 {
-1042 getLog().error("Error while scanning!", e);
-1043 throw new MojoFailureException(e.getMessage());
-1044 }
-1045 }
-1046
-1047 private void addAnnotated(
-1048 String name,
-1049 MetadataSources sources,
-1050 ClassLoaderService classLoaderService,
-1051 ModificationTracker tracker
-1052 )
-1053 throws
-1054 MojoFailureException,
-1055 MojoExecutionException
-1056 {
-1057 try
-1058 {
-1059 getLog().info("Adding annotated resource: " + name);
-1060 String packageName;
-1061
-1062 try
-1063 {
-1064 Class<?> annotatedClass = classLoaderService.classForName(name);
-1065 String resourceName = annotatedClass.getName();
-1066 resourceName =
-1067 resourceName.substring(
-1068 resourceName.lastIndexOf(".") + 1,
-1069 resourceName.length()
-1070 ) + ".class";
-1071 InputStream is = annotatedClass.getResourceAsStream(resourceName);
-1072 if (tracker.track(name, is))
-1073 getLog().debug("New or modified class: " + name);
-1074 else
-1075 getLog().debug("Unchanged class: " + name);
-1076 sources.addAnnotatedClass(annotatedClass);
-1077 packageName = annotatedClass.getPackage().getName();
-1078 }
-1079 catch(ClassLoadingException e)
-1080 {
-1081 packageName = name;
-1082 }
-1083
-1084 while (packageName != null)
-1085 {
-1086 if (packages.contains(packageName))
-1087 return;
-1088 String resource = packageName.replace('.', '/') + "/package-info.class";
-1089 InputStream is = classLoaderService.locateResourceStream(resource);
-1090 if (is == null)
-1091 {
-1092 // No compiled package-info available: no package-level annotations!
-1093 getLog().debug("Package " + packageName + " is not annotated.");
-1094 }
-1095 else
-1096 {
-1097 if (tracker.track(packageName, is))
-1098 getLog().debug("New or modified package: " + packageName);
-1099 else
-1100 getLog().debug("Unchanged package: " + packageName);
-1101 getLog().info("Adding annotations from package " + packageName);
-1102 sources.addPackage(packageName);
-1103 }
-1104 packages.add(packageName);
-1105 int i = packageName.lastIndexOf('.');
-1106 if (i < 0)
-1107 packageName = null;
-1108 else
-1109 packageName = packageName.substring(0,i);
-1110 }
-1111 }
-1112 catch (Exception e)
-1113 {
-1114 getLog().error("Error while adding the annotated class " + name, e);
-1115 throw new MojoFailureException(e.getMessage());
-1116 }
-1117 }
-1118
-1119 private ParsedPersistenceXmlDescriptor loadPersistenceUnit(
-1120 ClassLoaderService classLoaderService,
-1121 Properties properties
-1122 )
-1123 throws
-1124 MojoFailureException
-1125 {
-1126 PersistenceXmlParser parser =
-1127 new PersistenceXmlParser(
-1128 classLoaderService,
-1129 PersistenceUnitTransactionType.RESOURCE_LOCAL
-1130 );
-1131
-1132 List<ParsedPersistenceXmlDescriptor> units = parser.doResolve(properties);
-1133
-1134 if (persistenceUnit == null)
-1135 {
-1136 switch (units.size())
-1137 {
-1138 case 0:
-1139 getLog().info("Found no META-INF/persistence.xml.");
-1140 return null;
-1141 case 1:
-1142 getLog().info("Using persistence-unit " + units.get(0).getName());
-1143 return units.get(0);
-1144 default:
-1145 StringBuilder builder = new StringBuilder();
-1146 builder.append("No name provided and multiple persistence units found: ");
-1147 Iterator<ParsedPersistenceXmlDescriptor> it = units.iterator();
-1148 builder.append(it.next().getName());
-1149 while (it.hasNext())
-1150 {
-1151 builder.append(", ");
-1152 builder.append(it.next().getName());
-1153 }
-1154 builder.append('.');
-1155 throw new MojoFailureException(builder.toString());
-1156 }
-1157 }
-1158
-1159 for (ParsedPersistenceXmlDescriptor unit : units)
-1160 {
-1161 getLog().debug("Found persistence-unit " + unit.getName());
-1162 if (!unit.getName().equals(persistenceUnit))
-1163 continue;
-1164
-1165 // See if we (Hibernate) are the persistence provider
-1166 if (!ProviderChecker.isProvider(unit, properties))
-1167 {
-1168 getLog().debug("Wrong provider: " + unit.getProviderClassName());
-1169 continue;
-1170 }
-1171
-1172 getLog().info("Using persistence-unit " + unit.getName());
-1173 return unit;
-1174 }
-1175
-1176 throw new MojoFailureException("Could not find persistence-unit " + persistenceUnit);
-1177 }
-1178 }
-
-
-
-
-
diff --git a/dist/hibernate-maven-plugin-2.0.0/xref/de/juplo/plugins/hibernate/CreateMojo.html b/dist/hibernate-maven-plugin-2.0.0/xref/de/juplo/plugins/hibernate/CreateMojo.html
deleted file mode 100644
index 133e6f86..00000000
--- a/dist/hibernate-maven-plugin-2.0.0/xref/de/juplo/plugins/hibernate/CreateMojo.html
+++ /dev/null
@@ -1,113 +0,0 @@
-
-
-
-
-1 package de.juplo.plugins.hibernate;
-2
-3 /*
-4 * Copyright 2001-2005 The Apache Software Foundation.
-5 *
-6 * Licensed under the Apache License, Version 2.0 (the "License");
-7 * you may not use this file except in compliance with the License.
-8 * You may obtain a copy of the License at
-9 *
-10 * http://www.apache.org/licenses/LICENSE-2.0
-11 *
-12 * Unless required by applicable law or agreed to in writing, software
-13 * distributed under the License is distributed on an "AS IS" BASIS,
-14 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-15 * See the License for the specific language governing permissions and
-16 * limitations under the License.
-17 */
-18
-19 import java.io.File;
-20 import org.apache.maven.plugin.MojoExecutionException;
-21 import org.apache.maven.plugin.MojoFailureException;
-22 import org.hibernate.boot.spi.MetadataImplementor;
-23 import org.hibernate.tool.hbm2ddl.SchemaExport;
-24
-25
-26 /**
-27 * Goal which extracts the hibernate-mapping-configuration and
-28 * exports an according SQL-database-schema.
-29 *
-30 * @goal create
-31 * @phase process-classes
-32 * @threadSafe
-33 * @requiresDependencyResolution runtime
-34 */
-35 public class CreateMojo extends AbstractSchemaMojo
-36 {
-37 /**
-38 * Output file.
-39 * <p>
-40 * If the specified filename is not absolut, the file will be created
-41 * relative to the project build directory
-42 * (<code>project.build.directory</code>).
-43 *
-44 * @parameter property="hibernate.schema.export.create" default-value="create.sql"
-45 * @since 1.0
-46 */
-47 private String outputFile;
-48
-49
-50 @Override
-51 public final void execute()
-52 throws
-53 MojoFailureException,
-54 MojoExecutionException
-55 {
-56 super.execute(outputFile);
-57 }
-58
-59
-60 @Override
-61 void build(MetadataImplementor metadata)
-62 throws
-63 MojoExecutionException,
-64 MojoFailureException
-65 {
-66 SchemaExport schemaExport = new SchemaExport(metadata, createNamespaces);
-67 schemaExport.setDelimiter(delimiter);
-68 schemaExport.setFormat(format);
-69
-70 File output = new File(outputFile);
-71
-72 if (!output.isAbsolute())
-73 {
-74 // Interpret relative file path relative to build directory
-75 output = new File(buildDirectory, outputFile);
-76 getLog().debug("Adjusted relative path, resulting path is " + output.getPath());
-77 }
-78
-79 // Ensure that directory path for specified file exists
-80 File outFileParentDir = output.getParentFile();
-81 if (null != outFileParentDir && !outFileParentDir.exists())
-82 {
-83 try
-84 {
-85 getLog().info("Creating directory path for output file:" + outFileParentDir.getPath());
-86 outFileParentDir.mkdirs();
-87 }
-88 catch (Exception e)
-89 {
-90 getLog().error("Error creating directory path for output file: " + e.getLocalizedMessage());
-91 }
-92 }
-93
-94 schemaExport.setOutputFile(output.getPath());
-95 schemaExport.execute(false, this.export, false, true);
-96
-97 for (Object exception : schemaExport.getExceptions())
-98 getLog().error(exception.toString());
-99 }
-100 }
-
-
-
-
-
diff --git a/dist/hibernate-maven-plugin-2.0.0/xref/de/juplo/plugins/hibernate/DropMojo.html b/dist/hibernate-maven-plugin-2.0.0/xref/de/juplo/plugins/hibernate/DropMojo.html
deleted file mode 100644
index a4fb66e1..00000000
--- a/dist/hibernate-maven-plugin-2.0.0/xref/de/juplo/plugins/hibernate/DropMojo.html
+++ /dev/null
@@ -1,113 +0,0 @@
-
-
-
-
-1 package de.juplo.plugins.hibernate;
-2
-3 /*
-4 * Copyright 2001-2005 The Apache Software Foundation.
-5 *
-6 * Licensed under the Apache License, Version 2.0 (the "License");
-7 * you may not use this file except in compliance with the License.
-8 * You may obtain a copy of the License at
-9 *
-10 * http://www.apache.org/licenses/LICENSE-2.0
-11 *
-12 * Unless required by applicable law or agreed to in writing, software
-13 * distributed under the License is distributed on an "AS IS" BASIS,
-14 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-15 * See the License for the specific language governing permissions and
-16 * limitations under the License.
-17 */
-18
-19 import java.io.File;
-20 import org.apache.maven.plugin.MojoExecutionException;
-21 import org.apache.maven.plugin.MojoFailureException;
-22 import org.hibernate.boot.spi.MetadataImplementor;
-23 import org.hibernate.tool.hbm2ddl.SchemaExport;
-24
-25
-26 /**
-27 * Goal which extracts the hibernate-mapping-configuration and
-28 * exports an according SQL-database-schema.
-29 *
-30 * @goal drop
-31 * @phase process-classes
-32 * @threadSafe
-33 * @requiresDependencyResolution runtime
-34 */
-35 public class DropMojo extends AbstractSchemaMojo
-36 {
-37 /**
-38 * Output file.
-39 * <p>
-40 * If the specified filename is not absolut, the file will be created
-41 * relative to the project build directory
-42 * (<code>project.build.directory</code>).
-43 *
-44 * @parameter property="hibernate.schema.export.drop" default-value="drop.sql"
-45 * @since 1.0
-46 */
-47 private String outputFile;
-48
-49
-50 @Override
-51 public final void execute()
-52 throws
-53 MojoFailureException,
-54 MojoExecutionException
-55 {
-56 super.execute(outputFile);
-57 }
-58
-59
-60 @Override
-61 void build(MetadataImplementor metadata)
-62 throws
-63 MojoExecutionException,
-64 MojoFailureException
-65 {
-66 SchemaExport schemaExport = new SchemaExport(metadata, createNamespaces);
-67 schemaExport.setDelimiter(delimiter);
-68 schemaExport.setFormat(format);
-69
-70 File output = new File(outputFile);
-71
-72 if (!output.isAbsolute())
-73 {
-74 // Interpret relative file path relative to build directory
-75 output = new File(buildDirectory, outputFile);
-76 getLog().debug("Adjusted relative path, resulting path is " + output.getPath());
-77 }
-78
-79 // Ensure that directory path for specified file exists
-80 File outFileParentDir = output.getParentFile();
-81 if (null != outFileParentDir && !outFileParentDir.exists())
-82 {
-83 try
-84 {
-85 getLog().info("Creating directory path for output file:" + outFileParentDir.getPath());
-86 outFileParentDir.mkdirs();
-87 }
-88 catch (Exception e)
-89 {
-90 getLog().error("Error creating directory path for output file: " + e.getLocalizedMessage());
-91 }
-92 }
-93
-94 schemaExport.setOutputFile(output.getPath());
-95 schemaExport.execute(false, this.export, true, false);
-96
-97 for (Object exception : schemaExport.getExceptions())
-98 getLog().error(exception.toString());
-99 }
-100 }
-
-
-
-
-
diff --git a/dist/hibernate-maven-plugin-2.0.0/xref/de/juplo/plugins/hibernate/HelpMojo.html b/dist/hibernate-maven-plugin-2.0.0/xref/de/juplo/plugins/hibernate/HelpMojo.html
deleted file mode 100644
index 217919cb..00000000
--- a/dist/hibernate-maven-plugin-2.0.0/xref/de/juplo/plugins/hibernate/HelpMojo.html
+++ /dev/null
@@ -1,467 +0,0 @@
-
-
-
-
-1
-2 package de.juplo.plugins.hibernate;
-3
-4 import org.apache.maven.plugin.AbstractMojo;
-5 import org.apache.maven.plugin.MojoExecutionException;
-6
-7 import org.w3c.dom.Document;
-8 import org.w3c.dom.Element;
-9 import org.w3c.dom.Node;
-10 import org.w3c.dom.NodeList;
-11 import org.xml.sax.SAXException;
-12
-13 import javax.xml.parsers.DocumentBuilder;
-14 import javax.xml.parsers.DocumentBuilderFactory;
-15 import javax.xml.parsers.ParserConfigurationException;
-16 import java.io.IOException;
-17 import java.io.InputStream;
-18 import java.util.ArrayList;
-19 import java.util.List;
-20
-21 /**
-22 * Display help information on hibernate-maven-plugin.<br>
-23 * Call <code>mvn hibernate:help -Ddetail=true -Dgoal=<goal-name></code> to display parameter details.
-24 * @author maven-plugin-tools
-25 * @goal help
-26 * @requiresProject false
-27 * @threadSafe
-28 */
-29 public class HelpMojo
-30 extends AbstractMojo
-31 {
-32 /**
-33 * If <code>true</code>, display all settable properties for each goal.
-34 *
-35 * @parameter property="detail" default-value="false"
-36 */
-37 private boolean detail;
-38
-39 /**
-40 * The name of the goal for which to show help. If unspecified, all goals will be displayed.
-41 *
-42 * @parameter property="goal"
-43 */
-44 private java.lang.String goal;
-45
-46 /**
-47 * The maximum length of a display line, should be positive.
-48 *
-49 * @parameter property="lineLength" default-value="80"
-50 */
-51 private int lineLength;
-52
-53 /**
-54 * The number of spaces per indentation level, should be positive.
-55 *
-56 * @parameter property="indentSize" default-value="2"
-57 */
-58 private int indentSize;
-59
-60 // groupId/artifactId/plugin-help.xml
-61 private static final String PLUGIN_HELP_PATH =
-62 "/META-INF/maven/de.juplo/hibernate-maven-plugin/plugin-help.xml";
-63
-64 private static final int DEFAULT_LINE_LENGTH = 80;
-65
-66 private Document build()
-67 throws MojoExecutionException
-68 {
-69 getLog().debug( "load plugin-help.xml: " + PLUGIN_HELP_PATH );
-70 InputStream is = null;
-71 try
-72 {
-73 is = getClass().getResourceAsStream( PLUGIN_HELP_PATH );
-74 DocumentBuilderFactory dbFactory = DocumentBuilderFactory.newInstance();
-75 DocumentBuilder dBuilder = dbFactory.newDocumentBuilder();
-76 return dBuilder.parse( is );
-77 }
-78 catch ( IOException e )
-79 {
-80 throw new MojoExecutionException( e.getMessage(), e );
-81 }
-82 catch ( ParserConfigurationException e )
-83 {
-84 throw new MojoExecutionException( e.getMessage(), e );
-85 }
-86 catch ( SAXException e )
-87 {
-88 throw new MojoExecutionException( e.getMessage(), e );
-89 }
-90 finally
-91 {
-92 if ( is != null )
-93 {
-94 try
-95 {
-96 is.close();
-97 }
-98 catch ( IOException e )
-99 {
-100 throw new MojoExecutionException( e.getMessage(), e );
-101 }
-102 }
-103 }
-104 }
-105
-106 /**
-107 * {@inheritDoc}
-108 */
-109 public void execute()
-110 throws MojoExecutionException
-111 {
-112 if ( lineLength <= 0 )
-113 {
-114 getLog().warn( "The parameter 'lineLength' should be positive, using '80' as default." );
-115 lineLength = DEFAULT_LINE_LENGTH;
-116 }
-117 if ( indentSize <= 0 )
-118 {
-119 getLog().warn( "The parameter 'indentSize' should be positive, using '2' as default." );
-120 indentSize = 2;
-121 }
-122
-123 Document doc = build();
-124
-125 StringBuilder sb = new StringBuilder();
-126 Node plugin = getSingleChild( doc, "plugin" );
-127
-128
-129 String name = getValue( plugin, "name" );
-130 String version = getValue( plugin, "version" );
-131 String id = getValue( plugin, "groupId" ) + ":" + getValue( plugin, "artifactId" ) + ":" + version;
-132 if ( isNotEmpty( name ) && !name.contains( id ) )
-133 {
-134 append( sb, name + " " + version, 0 );
-135 }
-136 else
-137 {
-138 if ( isNotEmpty( name ) )
-139 {
-140 append( sb, name, 0 );
-141 }
-142 else
-143 {
-144 append( sb, id, 0 );
-145 }
-146 }
-147 append( sb, getValue( plugin, "description" ), 1 );
-148 append( sb, "", 0 );
-149
-150 //<goalPrefix>plugin</goalPrefix>
-151 String goalPrefix = getValue( plugin, "goalPrefix" );
-152
-153 Node mojos1 = getSingleChild( plugin, "mojos" );
-154
-155 List<Node> mojos = findNamedChild( mojos1, "mojo" );
-156
-157 if ( goal == null || goal.length() <= 0 )
-158 {
-159 append( sb, "This plugin has " + mojos.size() + ( mojos.size() > 1 ? " goals:" : " goal:" ), 0 );
-160 append( sb, "", 0 );
-161 }
-162
-163 for ( Node mojo : mojos )
-164 {
-165 writeGoal( sb, goalPrefix, (Element) mojo );
-166 }
-167
-168 if ( getLog().isInfoEnabled() )
-169 {
-170 getLog().info( sb.toString() );
-171 }
-172 }
-173
-174
-175 private static boolean isNotEmpty( String string )
-176 {
-177 return string != null && string.length() > 0;
-178 }
-179
-180 private String getValue( Node node, String elementName )
-181 throws MojoExecutionException
-182 {
-183 return getSingleChild( node, elementName ).getTextContent();
-184 }
-185
-186 private Node getSingleChild( Node node, String elementName )
-187 throws MojoExecutionException
-188 {
-189 List<Node> namedChild = findNamedChild( node, elementName );
-190 if ( namedChild.isEmpty() )
-191 {
-192 throw new MojoExecutionException( "Could not find " + elementName + " in plugin-help.xml" );
-193 }
-194 if ( namedChild.size() > 1 )
-195 {
-196 throw new MojoExecutionException( "Multiple " + elementName + " in plugin-help.xml" );
-197 }
-198 return namedChild.get( 0 );
-199 }
-200
-201 private List<Node> findNamedChild( Node node, String elementName )
-202 {
-203 List<Node> result = new ArrayList<Node>();
-204 NodeList childNodes = node.getChildNodes();
-205 for ( int i = 0; i < childNodes.getLength(); i++ )
-206 {
-207 Node item = childNodes.item( i );
-208 if ( elementName.equals( item.getNodeName() ) )
-209 {
-210 result.add( item );
-211 }
-212 }
-213 return result;
-214 }
-215
-216 private Node findSingleChild( Node node, String elementName )
-217 throws MojoExecutionException
-218 {
-219 List<Node> elementsByTagName = findNamedChild( node, elementName );
-220 if ( elementsByTagName.isEmpty() )
-221 {
-222 return null;
-223 }
-224 if ( elementsByTagName.size() > 1 )
-225 {
-226 throw new MojoExecutionException( "Multiple " + elementName + "in plugin-help.xml" );
-227 }
-228 return elementsByTagName.get( 0 );
-229 }
-230
-231 private void writeGoal( StringBuilder sb, String goalPrefix, Element mojo )
-232 throws MojoExecutionException
-233 {
-234 String mojoGoal = getValue( mojo, "goal" );
-235 Node configurationElement = findSingleChild( mojo, "configuration" );
-236 Node description = findSingleChild( mojo, "description" );
-237 if ( goal == null || goal.length() <= 0 || mojoGoal.equals( goal ) )
-238 {
-239 append( sb, goalPrefix + ":" + mojoGoal, 0 );
-240 Node deprecated = findSingleChild( mojo, "deprecated" );
-241 if ( ( deprecated != null ) && isNotEmpty( deprecated.getTextContent() ) )
-242 {
-243 append( sb, "Deprecated. " + deprecated.getTextContent(), 1 );
-244 if ( detail && description != null )
-245 {
-246 append( sb, "", 0 );
-247 append( sb, description.getTextContent(), 1 );
-248 }
-249 }
-250 else if ( description != null )
-251 {
-252 append( sb, description.getTextContent(), 1 );
-253 }
-254 append( sb, "", 0 );
-255
-256 if ( detail )
-257 {
-258 Node parametersNode = getSingleChild( mojo, "parameters" );
-259 List<Node> parameters = findNamedChild( parametersNode, "parameter" );
-260 append( sb, "Available parameters:", 1 );
-261 append( sb, "", 0 );
-262
-263 for ( Node parameter : parameters )
-264 {
-265 writeParameter( sb, parameter, configurationElement );
-266 }
-267 }
-268 }
-269 }
-270
-271 private void writeParameter( StringBuilder sb, Node parameter, Node configurationElement )
-272 throws MojoExecutionException
-273 {
-274 String parameterName = getValue( parameter, "name" );
-275 String parameterDescription = getValue( parameter, "description" );
-276
-277 Element fieldConfigurationElement = (Element) findSingleChild( configurationElement, parameterName );
-278
-279 String parameterDefaultValue = "";
-280 if ( fieldConfigurationElement != null && fieldConfigurationElement.hasAttribute( "default-value" ) )
-281 {
-282 parameterDefaultValue = " (Default: " + fieldConfigurationElement.getAttribute( "default-value" ) + ")";
-283 }
-284 append( sb, parameterName + parameterDefaultValue, 2 );
-285 Node deprecated = findSingleChild( parameter, "deprecated" );
-286 if ( ( deprecated != null ) && isNotEmpty( deprecated.getTextContent() ) )
-287 {
-288 append( sb, "Deprecated. " + deprecated.getTextContent(), 3 );
-289 append( sb, "", 0 );
-290 }
-291 append( sb, parameterDescription, 3 );
-292 if ( "true".equals( getValue( parameter, "required" ) ) )
-293 {
-294 append( sb, "Required: Yes", 3 );
-295 }
-296 if ( ( fieldConfigurationElement != null ) && isNotEmpty( fieldConfigurationElement.getTextContent() ) )
-297 {
-298 String property = getPropertyFromExpression( fieldConfigurationElement.getTextContent() );
-299 append( sb, "User property: " + property, 3 );
-300 }
-301
-302 append( sb, "", 0 );
-303 }
-304
-305 /**
-306 * <p>Repeat a String <code>n</code> times to form a new string.</p>
-307 *
-308 * @param str String to repeat
-309 * @param repeat number of times to repeat str
-310 * @return String with repeated String
-311 * @throws NegativeArraySizeException if <code>repeat < 0</code>
-312 * @throws NullPointerException if str is <code>null</code>
-313 */
-314 private static String repeat( String str, int repeat )
-315 {
-316 StringBuilder buffer = new StringBuilder( repeat * str.length() );
-317
-318 for ( int i = 0; i < repeat; i++ )
-319 {
-320 buffer.append( str );
-321 }
-322
-323 return buffer.toString();
-324 }
-325
-326 /**
-327 * Append a description to the buffer by respecting the indentSize and lineLength parameters.
-328 * <b>Note</b>: The last character is always a new line.
-329 *
-330 * @param sb The buffer to append the description, not <code>null</code>.
-331 * @param description The description, not <code>null</code>.
-332 * @param indent The base indentation level of each line, must not be negative.
-333 */
-334 private void append( StringBuilder sb, String description, int indent )
-335 {
-336 for ( String line : toLines( description, indent, indentSize, lineLength ) )
-337 {
-338 sb.append( line ).append( '\n' );
-339 }
-340 }
-341
-342 /**
-343 * Splits the specified text into lines of convenient display length.
-344 *
-345 * @param text The text to split into lines, must not be <code>null</code>.
-346 * @param indent The base indentation level of each line, must not be negative.
-347 * @param indentSize The size of each indentation, must not be negative.
-348 * @param lineLength The length of the line, must not be negative.
-349 * @return The sequence of display lines, never <code>null</code>.
-350 * @throws NegativeArraySizeException if <code>indent < 0</code>
-351 */
-352 private static List<String> toLines( String text, int indent, int indentSize, int lineLength )
-353 {
-354 List<String> lines = new ArrayList<String>();
-355
-356 String ind = repeat( "\t", indent );
-357
-358 String[] plainLines = text.split( "(\r\n)|(\r)|(\n)" );
-359
-360 for ( String plainLine : plainLines )
-361 {
-362 toLines( lines, ind + plainLine, indentSize, lineLength );
-363 }
-364
-365 return lines;
-366 }
-367
-368 /**
-369 * Adds the specified line to the output sequence, performing line wrapping if necessary.
-370 *
-371 * @param lines The sequence of display lines, must not be <code>null</code>.
-372 * @param line The line to add, must not be <code>null</code>.
-373 * @param indentSize The size of each indentation, must not be negative.
-374 * @param lineLength The length of the line, must not be negative.
-375 */
-376 private static void toLines( List<String> lines, String line, int indentSize, int lineLength )
-377 {
-378 int lineIndent = getIndentLevel( line );
-379 StringBuilder buf = new StringBuilder( 256 );
-380
-381 String[] tokens = line.split( " +" );
-382
-383 for ( String token : tokens )
-384 {
-385 if ( buf.length() > 0 )
-386 {
-387 if ( buf.length() + token.length() >= lineLength )
-388 {
-389 lines.add( buf.toString() );
-390 buf.setLength( 0 );
-391 buf.append( repeat( " ", lineIndent * indentSize ) );
-392 }
-393 else
-394 {
-395 buf.append( ' ' );
-396 }
-397 }
-398
-399 for ( int j = 0; j < token.length(); j++ )
-400 {
-401 char c = token.charAt( j );
-402 if ( c == '\t' )
-403 {
-404 buf.append( repeat( " ", indentSize - buf.length() % indentSize ) );
-405 }
-406 else if ( c == '\u00A0' )
-407 {
-408 buf.append( ' ' );
-409 }
-410 else
-411 {
-412 buf.append( c );
-413 }
-414 }
-415 }
-416 lines.add( buf.toString() );
-417 }
-418
-419 /**
-420 * Gets the indentation level of the specified line.
-421 *
-422 * @param line The line whose indentation level should be retrieved, must not be <code>null</code>.
-423 * @return The indentation level of the line.
-424 */
-425 private static int getIndentLevel( String line )
-426 {
-427 int level = 0;
-428 for ( int i = 0; i < line.length() && line.charAt( i ) == '\t'; i++ )
-429 {
-430 level++;
-431 }
-432 for ( int i = level + 1; i <= level + 4 && i < line.length(); i++ )
-433 {
-434 if ( line.charAt( i ) == '\t' )
-435 {
-436 level++;
-437 break;
-438 }
-439 }
-440 return level;
-441 }
-442
-443 private String getPropertyFromExpression( String expression )
-444 {
-445 if ( expression != null && expression.startsWith( "${" ) && expression.endsWith( "}" )
-446 && !expression.substring( 2 ).contains( "${" ) )
-447 {
-448 // expression="${xxx}" -> property="xxx"
-449 return expression.substring( 2, expression.length() - 1 );
-450 }
-451 // no property can be extracted
-452 return null;
-453 }
-454 }
-
-
-
-
-
diff --git a/dist/hibernate-maven-plugin-2.0.0/xref/de/juplo/plugins/hibernate/ModificationTracker.html b/dist/hibernate-maven-plugin-2.0.0/xref/de/juplo/plugins/hibernate/ModificationTracker.html
deleted file mode 100644
index 62bdd9c5..00000000
--- a/dist/hibernate-maven-plugin-2.0.0/xref/de/juplo/plugins/hibernate/ModificationTracker.html
+++ /dev/null
@@ -1,224 +0,0 @@
-
-
-
-
-1 package de.juplo.plugins.hibernate;
-2
-3
-4 import java.io.File;
-5 import java.io.FileInputStream;
-6 import java.io.FileOutputStream;
-7 import java.io.IOException;
-8 import java.io.InputStream;
-9 import java.io.ObjectInputStream;
-10 import java.io.ObjectOutputStream;
-11 import java.math.BigInteger;
-12 import java.security.MessageDigest;
-13 import java.security.NoSuchAlgorithmException;
-14 import java.util.HashMap;
-15 import java.util.HashSet;
-16 import java.util.Map;
-17 import java.util.Properties;
-18 import java.util.Set;
-19 import org.apache.maven.plugin.logging.Log;
-20
-21
-22
-23 /**
-24 *
-25 * @author Kai Moritz
-26 */
-27 public class ModificationTracker
-28 {
-29 private Map<String,String> properties;
-30 private Map<String,String> classes;
-31
-32 private final Set<String> propertyNames;
-33 private final Set<String> classNames;
-34
-35 private boolean modified = false;
-36 private boolean failed = false;
-37
-38 private final File saved;
-39 private final MessageDigest digest;
-40 private final Log log;
-41
-42
-43 ModificationTracker(String buildDirectory, String filename, Log log)
-44 throws
-45 NoSuchAlgorithmException
-46 {
-47 propertyNames = new HashSet<String>();
-48 classNames = new HashSet<String>();
-49 File output = new File(filename + ".md5s");
-50 if (output.isAbsolute())
-51 {
-52 saved = output;
-53 }
-54 else
-55 {
-56 // Interpret relative file path relative to build directory
-57 saved = new File(buildDirectory, output.getPath());
-58 log.debug("Adjusted relative path, resulting path is " + saved.getPath());
-59 }
-60 digest = java.security.MessageDigest.getInstance("MD5");
-61 this.log = log;
-62 }
-63
-64
-65 private String calculate(InputStream is)
-66 throws
-67 IOException
-68 {
-69 byte[] buffer = new byte[1024*4]; // copy data in 4MB-chunks
-70 int i;
-71 while((i = is.read(buffer)) > -1)
-72 digest.update(buffer, 0, i);
-73 is.close();
-74 byte[] bytes = digest.digest();
-75 BigInteger bi = new BigInteger(1, bytes);
-76 return String.format("%0" + (bytes.length << 1) + "x", bi);
-77 }
-78
-79 private boolean check(Map<String,String> values, String name, String value)
-80 {
-81 if (!values.containsKey(name) || !values.get(name).equals(value))
-82 {
-83 values.put(name, value);
-84 return true;
-85 }
-86 else
-87 return false;
-88 }
-89
-90
-91 boolean track(String name, InputStream is) throws IOException
-92 {
-93 boolean result = check(classes, name, calculate(is));
-94 classNames.add(name);
-95 modified |= result;
-96 return result;
-97 }
-98
-99
-100 boolean check(String name, String property)
-101 {
-102 propertyNames.add(name);
-103 return check(properties, name, property);
-104 }
-105
-106 boolean track(String name, String property)
-107 {
-108 boolean result = check(name, property);
-109 modified |= result;
-110 return result;
-111 }
-112
-113 boolean track(Properties properties)
-114 {
-115 boolean result = false;
-116 for (String name : properties.stringPropertyNames())
-117 result |= track(name, properties.getProperty(name));
-118 return result;
-119 }
-120
-121
-122 void touch()
-123 {
-124 modified = true;
-125 }
-126
-127 boolean modified()
-128 {
-129 for (String property : new HashSet<String>(properties.keySet()))
-130 if (!propertyNames.contains(property))
-131 {
-132 modified = true;
-133 properties.remove(property);
-134 }
-135 for (String clazz : new HashSet<String>(classes.keySet()))
-136 if (!classNames.contains(clazz))
-137 {
-138 modified = true;
-139 classes.remove(clazz);
-140 }
-141 return modified;
-142 }
-143
-144
-145 void failed()
-146 {
-147 failed = true;
-148 }
-149
-150
-151 void load()
-152 {
-153 if (saved.isFile() && saved.length() > 0)
-154 {
-155 try
-156 {
-157 FileInputStream fis = new FileInputStream(saved);
-158 ObjectInputStream ois = new ObjectInputStream(fis);
-159 properties = (HashMap<String,String>)ois.readObject();
-160 classes = (HashMap<String,String>)ois.readObject();
-161 ois.close();
-162 }
-163 catch (Exception e)
-164 {
-165 properties = new HashMap<String,String>();
-166 classes = new HashMap<String,String>();
-167 log.warn("Cannot read md5s from saved: " + e);
-168 }
-169 }
-170 else
-171 {
-172 properties = new HashMap<String,String>();
-173 classes = new HashMap<String,String>();
-174 try
-175 {
-176 saved.createNewFile();
-177 }
-178 catch (IOException e)
-179 {
-180 log.debug("Cannot create file \"" + saved.getPath() + "\" for md5s: " + e);
-181 }
-182 }
-183 }
-184
-185 void save()
-186 {
-187 if (failed)
-188 {
-189 saved.delete();
-190 return;
-191 }
-192
-193 if (!modified)
-194 return;
-195
-196 /** Write md5-sums for annotated classes to file */
-197 try
-198 {
-199 FileOutputStream fos = new FileOutputStream(saved);
-200 ObjectOutputStream oos = new ObjectOutputStream(fos);
-201 oos.writeObject(properties);
-202 oos.writeObject(classes);
-203 oos.close();
-204 fos.close();
-205 }
-206 catch (Exception e)
-207 {
-208 log.error("Cannot write md5-sums to file: " + e);
-209 }
-210 }
-211 }
-
-
-
-
-
diff --git a/dist/hibernate-maven-plugin-2.0.0/xref/de/juplo/plugins/hibernate/MutableClassLoader.html b/dist/hibernate-maven-plugin-2.0.0/xref/de/juplo/plugins/hibernate/MutableClassLoader.html
deleted file mode 100644
index 6ac98c3c..00000000
--- a/dist/hibernate-maven-plugin-2.0.0/xref/de/juplo/plugins/hibernate/MutableClassLoader.html
+++ /dev/null
@@ -1,115 +0,0 @@
-
-
-
-
-1 package de.juplo.plugins.hibernate;
-2
-3 import java.io.IOException;
-4 import java.io.InputStream;
-5 import java.net.URL;
-6 import java.net.URLClassLoader;
-7 import java.util.Arrays;
-8 import java.util.Enumeration;
-9 import java.util.LinkedHashSet;
-10 import org.apache.maven.plugin.logging.Log;
-11
-12
-13 /**
-14 *
-15 * @author kai
-16 */
-17 public class MutableClassLoader extends ClassLoader
-18 {
-19 private URLClassLoader loader;
-20 private Log log;
-21
-22
-23 public MutableClassLoader(LinkedHashSet<URL> urls, Log log)
-24 {
-25 if (log.isDebugEnabled())
-26 for (URL url : urls)
-27 log.debug(url.toString());
-28 loader =
-29 new URLClassLoader(
-30 urls.toArray(new URL[urls.size()]),
-31 getClass().getClassLoader()
-32 );
-33 this.log = log;
-34 }
-35
-36
-37 public MutableClassLoader add(LinkedHashSet<URL> urls)
-38 {
-39 LinkedHashSet<URL> old =
-40 new LinkedHashSet<URL>(Arrays.asList(loader.getURLs()));
-41 old.addAll(urls);
-42 if (log.isDebugEnabled())
-43 for (URL url : urls)
-44 log.debug(url.toString());
-45 loader =
-46 new URLClassLoader(
-47 old.toArray(new URL[urls.size()]),
-48 getClass().getClassLoader()
-49 );
-50 return this;
-51 }
-52
-53
-54 @Override
-55 public void clearAssertionStatus()
-56 {
-57 loader.clearAssertionStatus();
-58 }
-59
-60 @Override
-61 public void setClassAssertionStatus(String className, boolean enabled)
-62 {
-63 loader.setClassAssertionStatus(className, enabled);
-64 }
-65
-66 @Override
-67 public void setPackageAssertionStatus(String packageName, boolean enabled)
-68 {
-69 loader.setPackageAssertionStatus(packageName, enabled);
-70 }
-71
-72 @Override
-73 public void setDefaultAssertionStatus(boolean enabled)
-74 {
-75 loader.setDefaultAssertionStatus(enabled);
-76 }
-77
-78 @Override
-79 public InputStream getResourceAsStream(String name)
-80 {
-81 return loader.getResourceAsStream(name);
-82 }
-83
-84 @Override
-85 public Enumeration<URL> getResources(String name) throws IOException
-86 {
-87 return loader.getResources(name);
-88 }
-89
-90 @Override
-91 public URL getResource(String name)
-92 {
-93 return loader.getResource(name);
-94 }
-95
-96 @Override
-97 public Class<?> loadClass(String name) throws ClassNotFoundException
-98 {
-99 return loader.loadClass(name);
-100 }
-101
-102 }
-
-
-
-
-
diff --git a/dist/hibernate-maven-plugin-2.0.0/xref/de/juplo/plugins/hibernate/SimpleConnectionProvider.html b/dist/hibernate-maven-plugin-2.0.0/xref/de/juplo/plugins/hibernate/SimpleConnectionProvider.html
deleted file mode 100644
index a2553db5..00000000
--- a/dist/hibernate-maven-plugin-2.0.0/xref/de/juplo/plugins/hibernate/SimpleConnectionProvider.html
+++ /dev/null
@@ -1,262 +0,0 @@
-
-
-
-
-1 package de.juplo.plugins.hibernate;
-2
-3 import java.sql.Connection;
-4 import java.sql.Driver;
-5 import java.sql.DriverManager;
-6 import java.sql.DriverPropertyInfo;
-7 import java.sql.SQLException;
-8 import java.sql.SQLFeatureNotSupportedException;
-9 import java.util.Properties;
-10 import java.util.logging.Logger;
-11 import org.apache.maven.plugin.MojoFailureException;
-12 import org.apache.maven.plugin.logging.Log;
-13 import static org.eclipse.aether.repository.AuthenticationContext.PASSWORD;
-14 import static org.eclipse.aether.repository.AuthenticationContext.USERNAME;
-15 import org.hibernate.boot.registry.classloading.spi.ClassLoaderService;
-16 import static org.hibernate.cfg.AvailableSettings.DRIVER;
-17 import static org.hibernate.cfg.AvailableSettings.PASS;
-18 import static org.hibernate.cfg.AvailableSettings.URL;
-19 import static org.hibernate.cfg.AvailableSettings.USER;
-20 import org.hibernate.engine.jdbc.connections.spi.ConnectionProvider;
-21 import static org.hibernate.jpa.AvailableSettings.JDBC_DRIVER;
-22 import static org.hibernate.jpa.AvailableSettings.JDBC_PASSWORD;
-23 import static org.hibernate.jpa.AvailableSettings.JDBC_URL;
-24 import static org.hibernate.jpa.AvailableSettings.JDBC_USER;
-25
-26 /**
-27 *
-28 * @author Kai Moritz
-29 */
-30 class SimpleConnectionProvider implements ConnectionProvider
-31 {
-32 private final Log log;
-33
-34 private Connection connection;
-35
-36
-37 SimpleConnectionProvider(Log log)
-38 {
-39 this.log = log;
-40 }
-41
-42
-43 void open(ClassLoaderService classLoaderService, Properties properties)
-44 throws
-45 MojoFailureException
-46 {
-47
-48 String driver = (String)
-49 (properties.containsKey(DRIVER)
-50 ? properties.getProperty(DRIVER)
-51 : properties.getProperty(JDBC_DRIVER)
-52 );
-53 String url = (String)
-54 (properties.containsKey(URL)
-55 ? properties.getProperty(URL)
-56 : properties.getProperty(JDBC_URL)
-57 );
-58 String user = (String)
-59 (properties.containsKey(USER)
-60 ? properties.getProperty(USER)
-61 : properties.getProperty(JDBC_USER)
-62 );
-63 String password = (String)
-64 (properties.containsKey(PASS)
-65 ? properties.getProperty(PASS)
-66 : properties.getProperty(JDBC_PASSWORD)
-67 );
-68
-69 if (driver == null || url == null || user == null)
-70 {
-71 log.info("No connection opened, because connection information is incomplete");
-72 log.info("Driver-Class: " + driver);
-73 log.info("URL: " + url);
-74 log.info("User: " + user);
-75 return;
-76 }
-77
-78 try
-79 {
-80 Class driverClass = classLoaderService.classForName(driver);
-81
-82 log.debug("Registering JDBC-driver " + driverClass.getName());
-83 DriverManager
-84 .registerDriver(new DriverProxy((Driver) driverClass.newInstance()));
-85
-86 log.debug(
-87 "Opening JDBC-connection to " + properties.getProperty(URL) +
-88 " as " + properties.getProperty(USERNAME) +
-89 " with password " + properties.getProperty(PASSWORD)
-90 );
-91
-92 connection = DriverManager.getConnection(url, user, password);
-93 }
-94 catch (Exception e)
-95 {
-96 throw new MojoFailureException("Could not open the JDBC-connection", e);
-97 }
-98 }
-99
-100 void close()
-101 {
-102 if (connection == null)
-103 return;
-104
-105 log.debug("Closing the JDBC-connection.");
-106 try
-107 {
-108 connection.close();
-109 }
-110 catch (SQLException e)
-111 {
-112 log.error("Error while closing the JDBC-connection: " + e.getMessage());
-113 }
-114 }
-115
-116 @Override
-117 public Connection getConnection() throws SQLException
-118 {
-119 log.debug("Connection aquired.");
-120
-121 if (connection == null)
-122 throw new SQLException("No connection available, because of insufficient connection information!");
-123
-124 return connection;
-125 }
-126
-127 @Override
-128 public void closeConnection(Connection conn) throws SQLException
-129 {
-130 log.debug("Connection released");
-131 }
-132
-133 @Override
-134 public boolean supportsAggressiveRelease()
-135 {
-136 return false;
-137 }
-138
-139 @Override
-140 public boolean isUnwrappableAs(Class unwrapType)
-141 {
-142 return false;
-143 }
-144
-145 @Override
-146 public <T> T unwrap(Class<T> unwrapType)
-147 {
-148 throw new UnsupportedOperationException("Not supported.");
-149 }
-150
-151 /**
-152 * Needed, because DriverManager won't pick up drivers, that were not
-153 * loaded by the system-classloader!
-154 * See:
-155 * http://stackoverflow.com/questions/288828/how-to-use-a-jdbc-driver-fromodifiedm-an-arbitrary-location
-156 */
-157 static final class DriverProxy implements Driver
-158 {
-159 private final Driver target;
-160
-161 DriverProxy(Driver target)
-162 {
-163 if (target == null)
-164 throw new NullPointerException();
-165 this.target = target;
-166 }
-167
-168 public java.sql.Driver getTarget()
-169 {
-170 return target;
-171 }
-172
-173 @Override
-174 public boolean acceptsURL(String url) throws SQLException
-175 {
-176 return target.acceptsURL(url);
-177 }
-178
-179 @Override
-180 public java.sql.Connection connect(
-181 String url,
-182 java.util.Properties info
-183 )
-184 throws
-185 SQLException
-186 {
-187 return target.connect(url, info);
-188 }
-189
-190 @Override
-191 public int getMajorVersion()
-192 {
-193 return target.getMajorVersion();
-194 }
-195
-196 @Override
-197 public int getMinorVersion()
-198 {
-199 return target.getMinorVersion();
-200 }
-201
-202 @Override
-203 public DriverPropertyInfo[] getPropertyInfo(
-204 String url,
-205 Properties info
-206 )
-207 throws
-208 SQLException
-209 {
-210 return target.getPropertyInfo(url, info);
-211 }
-212
-213 @Override
-214 public boolean jdbcCompliant()
-215 {
-216 return target.jdbcCompliant();
-217 }
-218
-219 /**
-220 * This Method cannot be annotated with @Override, becaus the plugin
-221 * will not compile then under Java 1.6!
-222 */
-223 public Logger getParentLogger() throws SQLFeatureNotSupportedException
-224 {
-225 throw new SQLFeatureNotSupportedException("Not supported, for backward-compatibility with Java 1.6");
-226 }
-227
-228 @Override
-229 public String toString()
-230 {
-231 return "Proxy: " + target;
-232 }
-233
-234 @Override
-235 public int hashCode()
-236 {
-237 return target.hashCode();
-238 }
-239
-240 @Override
-241 public boolean equals(Object obj)
-242 {
-243 if (!(obj instanceof DriverProxy))
-244 return false;
-245 DriverProxy other = (DriverProxy) obj;
-246 return this.target.equals(other.target);
-247 }
-248 }
-249 }
-
-
-
-
-
diff --git a/dist/hibernate-maven-plugin-2.0.0/xref/de/juplo/plugins/hibernate/package-frame.html b/dist/hibernate-maven-plugin-2.0.0/xref/de/juplo/plugins/hibernate/package-frame.html
deleted file mode 100644
index 8816bf86..00000000
--- a/dist/hibernate-maven-plugin-2.0.0/xref/de/juplo/plugins/hibernate/package-frame.html
+++ /dev/null
@@ -1,45 +0,0 @@
-
-
-
-
-
-
- de.juplo.plugins.hibernate
-
-
- Classes
-
-
-
-
-
-
\ No newline at end of file
diff --git a/dist/hibernate-maven-plugin-2.0.0/xref/de/juplo/plugins/hibernate/package-summary.html b/dist/hibernate-maven-plugin-2.0.0/xref/de/juplo/plugins/hibernate/package-summary.html
deleted file mode 100644
index 543f54aa..00000000
--- a/dist/hibernate-maven-plugin-2.0.0/xref/de/juplo/plugins/hibernate/package-summary.html
+++ /dev/null
@@ -1,104 +0,0 @@
-
-
-
-
-
-
-
- Package de.juplo.plugins.hibernate
-
-
-
-
-
-
-
-
-
- Class Summary
-
-
-
- AbstractSchemaMojo
-
-
-
-
- CreateMojo
-
-
-
-
- DriverProxy
-
-
-
-
- DropMojo
-
-
-
-
- HelpMojo
-
-
-
-
- ModificationTracker
-
-
-
-
- MutableClassLoader
-
-
-
-
-
- SimpleConnectionProvider
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/dist/hibernate-maven-plugin-2.0.0/xref/index.html b/dist/hibernate-maven-plugin-2.0.0/xref/index.html
deleted file mode 100644
index cc2b5579..00000000
--- a/dist/hibernate-maven-plugin-2.0.0/xref/index.html
+++ /dev/null
@@ -1,25 +0,0 @@
-
-
-
-
-
-
- Frame Alert
-
- All Classes
-
-
- Packages
-
-
-
-
-
-
-
diff --git a/dist/hibernate-maven-plugin-2.0.0/xref/overview-summary.html b/dist/hibernate-maven-plugin-2.0.0/xref/overview-summary.html
deleted file mode 100644
index 654b1471..00000000
--- a/dist/hibernate-maven-plugin-2.0.0/xref/overview-summary.html
+++ /dev/null
@@ -1,66 +0,0 @@
-
-
-
-
-
-
-
- Hibernate Maven Plugin 2.0.0 Reference
-
-
-
-
-
-
-
-
-
- Packages
-
-
-
-
- de.juplo.plugins.hibernate
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/dist/hibernate-maven-plugin-2.0.0/xref/stylesheet.css b/dist/hibernate-maven-plugin-2.0.0/xref/stylesheet.css
deleted file mode 100644
index 89732f81..00000000
--- a/dist/hibernate-maven-plugin-2.0.0/xref/stylesheet.css
+++ /dev/null
@@ -1,114 +0,0 @@
-/* Javadoc style sheet */
-/* Define colors, fonts and other style attributes here to override the defaults */
-body {
- background-color: #fff;
- font-family: Arial, Helvetica, sans-serif;
-}
-
-a:link {
- color: #00f;
-}
-a:visited {
- color: #00a;
-}
-
-a:active, a:hover {
- color: #f30 !important;
-}
-
-ul, li {
- list-style-type:none;
- margin:0;
- padding:0;
-}
-
-table td {
- padding: 3px;
- border: 1px solid #000;
-}
-table {
- width:100%;
- border: 1px solid #000;
- border-collapse: collapse;
-}
-
-div.overview {
- background-color:#ddd;
- padding: 4px 4px 4px 0;
-}
-div.overview li, div.framenoframe li {
- display: inline;
-}
-div.framenoframe {
- text-align: center;
- font-size: x-small;
-}
-div.framenoframe li {
- margin: 0 3px 0 3px;
-}
-div.overview li {
- margin:3px 3px 0 3px;
- padding: 4px;
-}
-li.selected {
- background-color:#888;
- color: #fff;
- font-weight: bold;
-}
-
-table.summary {
- margin-bottom: 20px;
-}
-table.summary td, table.summary th {
- font-weight: bold;
- text-align: left;
- padding: 3px;
-}
-table.summary th {
- background-color:#036;
- color: #fff;
-}
-table.summary td {
- background-color:#eee;
- border: 1px solid black;
-}
-
-em {
- color: #A00;
-}
-em.comment {
- color: #390;
-}
-.string {
- color: #009;
-}
-
-#overview {
- padding:2px;
-}
-
-hr {
- height: 1px;
- color: #000;
-}
-
-/* JXR style sheet */
-.jxr_comment
-{
- color: #390;
-}
-
-.jxr_javadoccomment
-{
- color: #A00;
-}
-
-.jxr_string
-{
- color: #009;
-}
-
-.jxr_keyword
-{
- color: #000;
-}
diff --git a/dist/hibernate-maven-plugin-2.1.0/apidocs/allclasses-frame.html b/dist/hibernate-maven-plugin-2.1.0/apidocs/allclasses-frame.html
deleted file mode 100644
index d491a69b..00000000
--- a/dist/hibernate-maven-plugin-2.1.0/apidocs/allclasses-frame.html
+++ /dev/null
@@ -1,26 +0,0 @@
-
-
-
-
-
-
-All Classes
-All Classes
-de.juplo.*
-
-
-
-
-
-
-
-Modifier and Type
-Constant Field
-Value
-
-
-
-
-
-public static final String
-EXECUTE
-"hibernate.schema.execute"
-
-
-
-
-public static final String
-OUTPUTDIRECTORY
-"project.build.outputDirectory"
-
-
-
-
-public static final String
-SCAN_CLASSES
-"hibernate.schema.scan.classes"
-
-
-
-
-public static final String
-SCAN_DEPENDENCIES
-"hibernate.schema.scan.dependencies"
-
-
-
-
-public static final String
-SCAN_TESTCLASSES
-"hibernate.schema.scan.test_classes"
-
-
-
-
-public static final String
-SCRIPT
-"hibernate.schema.script"
-
-
-
-
-public static final String
-SKIPPED
-"hibernate.schema.skipped"
-
-
-
-
-
-public static final String
-TEST_OUTPUTDIRECTORY
-"project.build.testOutputDirectory"
Class AbstractSchemaMojo
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-public abstract class AbstractSchemaMojo
-extends org.apache.maven.plugin.AbstractMojo
-
-
-
-
-
-
-
-Field Summary
-
-
-
-
-Modifier and Type
-Field and Description
-
-
-
-static String
-EXECUTE
-
-
-static String
-OUTPUTDIRECTORY
-
-
-static String
-SCAN_CLASSES
-
-
-static String
-SCAN_DEPENDENCIES
-
-
-static String
-SCAN_TESTCLASSES
-
-
-static String
-SCRIPT
-
-
-static String
-SKIPPED
-
-
-static String
-TEST_OUTPUTDIRECTORY
-
-Fields inherited from interface org.apache.maven.plugin.Mojo
-ROLE
-
-
-Constructor Summary
-
-
-
-
-Constructor and Description
-
-
-
-AbstractSchemaMojo()
-
-Method Summary
-
-
-
-
-Modifier and Type
-Method and Description
-
-
-
-void
-execute(String filename)
-
-
-static void
-printStrackTrace(StringBuilder builder,
- Throwable t)
-
-Methods inherited from class org.apache.maven.plugin.AbstractMojo
-getLog, getPluginContext, setLog, setPluginContext
-
-Methods inherited from class java.lang.Object
-clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
-Methods inherited from interface org.apache.maven.plugin.Mojo
-execute
-
-
-
-
-
-
-Field Detail
-
-
-
-
-
-
-
-
-EXECUTE
-public static final String EXECUTE
-
-
-
-
-
-
-
-OUTPUTDIRECTORY
-public static final String OUTPUTDIRECTORY
-
-
-
-
-
-
-
-SCAN_CLASSES
-public static final String SCAN_CLASSES
-
-
-
-
-
-
-
-SCAN_DEPENDENCIES
-public static final String SCAN_DEPENDENCIES
-
-
-
-
-
-
-
-SCAN_TESTCLASSES
-public static final String SCAN_TESTCLASSES
-
-
-
-
-
-
-
-TEST_OUTPUTDIRECTORY
-public static final String TEST_OUTPUTDIRECTORY
-
-
-
-
-
-
-
-SKIPPED
-public static final String SKIPPED
-
-
-
-
-SCRIPT
-public static final String SCRIPT
-
-
-
-
-Method Detail
-
-
-
-
-
-
-
-
-execute
-public final void execute(String filename)
- throws org.apache.maven.plugin.MojoFailureException,
- org.apache.maven.plugin.MojoExecutionException
-
-
-org.apache.maven.plugin.MojoFailureException
org.apache.maven.plugin.MojoExecutionException
-
-printStrackTrace
-public static void printStrackTrace(StringBuilder builder,
- Throwable t)
-Class CreateMojo
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-public class CreateMojo
-extends AbstractSchemaMojo
-
-
-
-
-
-
-
-Field Summary
-
-
-Fields inherited from class de.juplo.plugins.hibernate.AbstractSchemaMojo
-EXECUTE, OUTPUTDIRECTORY, SCAN_CLASSES, SCAN_DEPENDENCIES, SCAN_TESTCLASSES, SCRIPT, SKIPPED, TEST_OUTPUTDIRECTORY
-
-Fields inherited from interface org.apache.maven.plugin.Mojo
-ROLE
-
-
-Constructor Summary
-
-
-
-
-Constructor and Description
-
-
-
-CreateMojo()
-
-Method Summary
-
-
-
-
-Modifier and Type
-Method and Description
-
-
-
-void
-execute()
-
-Methods inherited from class de.juplo.plugins.hibernate.AbstractSchemaMojo
-execute, printStrackTrace
-
-
-Methods inherited from class org.apache.maven.plugin.AbstractMojo
-getLog, getPluginContext, setLog, setPluginContext
-
-Class DropMojo
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-public class DropMojo
-extends AbstractSchemaMojo
-
-
-
-
-
-
-
-
-
-Field Summary
-
-
-Fields inherited from class de.juplo.plugins.hibernate.AbstractSchemaMojo
-EXECUTE, OUTPUTDIRECTORY, SCAN_CLASSES, SCAN_DEPENDENCIES, SCAN_TESTCLASSES, SCRIPT, SKIPPED, TEST_OUTPUTDIRECTORY
-
-Fields inherited from interface org.apache.maven.plugin.Mojo
-ROLE
-
-Method Summary
-
-
-
-
-Modifier and Type
-Method and Description
-
-
-
-void
-execute()
-
-Methods inherited from class de.juplo.plugins.hibernate.AbstractSchemaMojo
-execute, printStrackTrace
-
-
-Methods inherited from class org.apache.maven.plugin.AbstractMojo
-getLog, getPluginContext, setLog, setPluginContext
-
-Class HelpMojo
-
-
-
-
-
-
-
-
-
-
-
-
-public class HelpMojo
-extends org.apache.maven.plugin.AbstractMojo
-
- Call mvn hibernate:help -Ddetail=true -Dgoal=<goal-name>
to display parameter details.
-
-
-
-
-
-
-
-
-Field Summary
-
-
-Fields inherited from interface org.apache.maven.plugin.Mojo
-ROLE
-
-Method Summary
-
-
-
-
-Modifier and Type
-Method and Description
-
-
-
-void
-execute()
-
-
-Methods inherited from class org.apache.maven.plugin.AbstractMojo
-getLog, getPluginContext, setLog, setPluginContext
-
-
-
-Class ModificationTracker
-
-
-
-
-
-
-
-
-public class ModificationTracker
-extends Object
-
-
-
-
-
-
-Class MutableClassLoader
-
-
-
-
-
-
-
-
-
-
-public class MutableClassLoader
-extends ClassLoader
-
-
-
-
-
-
-
-Constructor Summary
-
-
-
-
-Constructor and Description
-
-
-
-MutableClassLoader(LinkedHashSet<URL> urls,
- org.apache.maven.plugin.logging.Log log)
-
-Method Summary
-
-
-
-
-Modifier and Type
-Method and Description
-
-
-
-MutableClassLoader
-add(LinkedHashSet<URL> urls)
-
-
-void
-clearAssertionStatus()
-
-
-URL
-getResource(String name)
-
-
-InputStream
-getResourceAsStream(String name)
-
-
-Enumeration<URL>
-getResources(String name)
-
-
-Class<?>
-loadClass(String name)
-
-
-void
-setClassAssertionStatus(String className,
- boolean enabled)
-
-
-void
-setDefaultAssertionStatus(boolean enabled)
-
-
-void
-setPackageAssertionStatus(String packageName,
- boolean enabled)
-
-
-Methods inherited from class java.lang.ClassLoader
-defineClass, defineClass, defineClass, defineClass, definePackage, findClass, findLibrary, findLoadedClass, findResource, findResources, findSystemClass, getClassLoadingLock, getPackage, getPackages, getParent, getSystemClassLoader, getSystemResource, getSystemResourceAsStream, getSystemResources, loadClass, registerAsParallelCapable, resolveClass, setSigners
-
-
-
-
-Constructor Detail
-
-
-
-
-
-MutableClassLoader
-public MutableClassLoader(LinkedHashSet<URL> urls,
- org.apache.maven.plugin.logging.Log log)
-
-
-Method Detail
-
-
-
-
-
-
-
-
-add
-public MutableClassLoader add(LinkedHashSet<URL> urls)
-
-
-
-
-
-clearAssertionStatus
-public void clearAssertionStatus()
-
-
-clearAssertionStatus
in class ClassLoader
-
-
-
-
-setClassAssertionStatus
-public void setClassAssertionStatus(String className,
- boolean enabled)
-
-
-setClassAssertionStatus
in class ClassLoader
-
-
-
-
-setPackageAssertionStatus
-public void setPackageAssertionStatus(String packageName,
- boolean enabled)
-
-
-setPackageAssertionStatus
in class ClassLoader
-
-
-
-
-setDefaultAssertionStatus
-public void setDefaultAssertionStatus(boolean enabled)
-
-
-setDefaultAssertionStatus
in class ClassLoader
-
-
-
-
-getResourceAsStream
-public InputStream getResourceAsStream(String name)
-
-
-getResourceAsStream
in class ClassLoader
-
-
-
-
-getResources
-public Enumeration<URL> getResources(String name)
- throws IOException
-
-
-getResources
in class ClassLoader
IOException
-
-
-
-
-getResource
-public URL getResource(String name)
-
-
-getResource
in class ClassLoader
-
-loadClass
-public Class<?> loadClass(String name)
- throws ClassNotFoundException
-
-
-loadClass
in class ClassLoader
ClassNotFoundException
Class UpdateMojo
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-public class UpdateMojo
-extends AbstractSchemaMojo
-
-
-
-
-
-
-
-Field Summary
-
-
-Fields inherited from class de.juplo.plugins.hibernate.AbstractSchemaMojo
-EXECUTE, OUTPUTDIRECTORY, SCAN_CLASSES, SCAN_DEPENDENCIES, SCAN_TESTCLASSES, SCRIPT, SKIPPED, TEST_OUTPUTDIRECTORY
-
-Fields inherited from interface org.apache.maven.plugin.Mojo
-ROLE
-
-
-Constructor Summary
-
-
-
-
-Constructor and Description
-
-
-
-UpdateMojo()
-
-Method Summary
-
-
-
-
-Modifier and Type
-Method and Description
-
-
-
-void
-execute()
-
-Methods inherited from class de.juplo.plugins.hibernate.AbstractSchemaMojo
-execute, printStrackTrace
-
-
-Methods inherited from class org.apache.maven.plugin.AbstractMojo
-getLog, getPluginContext, setLog, setPluginContext
-
-Uses of Class
-
de.juplo.plugins.hibernate.AbstractSchemaMojo
-
-
-
-Uses of AbstractSchemaMojo in de.juplo.plugins.hibernate
-
-
-
-
-
-Modifier and Type
-Class and Description
-
-
-
-class
-CreateMojo
-
-
-
-class
-DropMojo
-
-
-
-
-class
-UpdateMojo
-Uses of Class
-
de.juplo.plugins.hibernate.CreateMojoUses of Class
-
de.juplo.plugins.hibernate.DropMojoUses of Class
-
de.juplo.plugins.hibernate.HelpMojoUses of Class
-
de.juplo.plugins.hibernate.ModificationTrackerUses of Class
-
de.juplo.plugins.hibernate.MutableClassLoader
-
-
-
-Uses of MutableClassLoader in de.juplo.plugins.hibernate
-
-
-
-
-
-Modifier and Type
-Method and Description
-
-
-
-
-MutableClassLoader
MutableClassLoader.
-add(LinkedHashSet<URL> urls)
Uses of Class
-
de.juplo.plugins.hibernate.UpdateMojode.juplo.plugins.hibernate
-Classes
-
-Package de.juplo.plugins.hibernate
-
-
-
-
-
-
-
-Class
-Description
-
-
-AbstractSchemaMojo
-
-
-
-
-CreateMojo
-
-
-
-
-DropMojo
-
-
-
-
-HelpMojo
-
-
-
-
-ModificationTracker
-
-
-
-MutableClassLoader
-
-
-
-
-UpdateMojo
-
-
-Hierarchy For Package de.juplo.plugins.hibernate
-Class Hierarchy
-
-
-
-
-
-
-
-
-
-
-Uses of Package
-
de.juplo.plugins.hibernate
-
-
-
-
-
-
-Class and Description
-
-
-AbstractSchemaMojo
-
-
-
-
-MutableClassLoader
-Deprecated API
-Contents
-How This API Document Is Organized
-
-
-This help file applies to API documentation generated using the standard doclet.Package
-
-
-Class/Interface
-
-
-
-
-
-
-Annotation Type
-
-
-Enum
-
-
-Use
-Tree (Class Hierarchy)
-java.lang.Object
. The interfaces do not inherit from java.lang.Object
.
-
-Deprecated API
-Index
-Prev/Next
-Frames/No Frames
-All Classes
-Serialized Form
-Constant Field Values
-A
-
-
-
-
-
-C
-
-
-
-
-
-D
-
-
-
-
-
-E
-
-
-
-
-
-G
-
-
-
-
-
-H
-
-
-
-
-
-L
-
-
-
-
-
-M
-
-
-
-
-
-O
-
-
-
-
-
-P
-
-
-
-
-
-S
-
-
-
-
-
-T
-
-
-
-
-
-U
-
-
-A C D E G H L M O P S T U Frame Alert
-Class Hierarchy
-
-
-
-
-
-
-
-
-
-
-Path
-
- The most simple way to configure the plugin is, to put all the - hibernate-configuration in a hibernate.properties- or - a hibernate.cfg.xml-file on your classpath or in the - persistence.xml-file of your JPA-configuration, just - like you would do, if you are not using the - hibernate-maven-plugin. -
- -- Doing so, the only additionally configuration needed, to activat the plugin - is the following entry in the plugins-section of your pom.xml: -
- --<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate-maven-plugin</artifactId> - <version>2.1.0</version> - <executions> - <execution> - <goals> - <goal>create</goal> - </goals> - </execution> - </executions> -</plugin>
- This would create the configured database. - If you want it to be droped beforehand, you have to add the goal - drop: -
- --<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate-maven-plugin</artifactId> - <version>2.1.0</version> - <executions> - <execution> - <goals> - <goal>drop</goal> - <goal>create</goal> - </goals> - </execution> - </executions> -</plugin>
- A correspondin goal for the command update is missing in this - version, but we are planning to implement it in near feature. -
- -- In order to let this configuration work, your configuration file must - contain a complete valid configuration for the database, that you want - to use. - A simple example hibernate.properties-file may look like this: -
- --hibernate.dialect=org.hibernate.dialect.H2Dialect -hibernate.connection.url=jdbc:h2:file:./target/db -hibernate.connection.driver_class=org.h2.Driver -hibernate.connection.username=sa -hibernate.connection.password=
- But be aware, that using this configuration-approach the database-url, - that is build in the application is the same that is used while testing, - where the database is droped and recreated by the plugin. - Because of that, - - you should never fire up this configuration on your production - system, or your database might be erased! - -
- -- A better approach is, to specify a different url for testing like in the - following snippet: -
- --<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate-maven-plugin</artifactId> - <version>2.1.0</version> - <executions> - <execution> - <goals> - <goal>drop</goal> - <goal>create</goal> - </goals> - </execution> - </executions> - <configuration> - <url><![CDATA[jdbc:mysql://localhost/test-db]]></url> - </configuration> -</plugin>
- Configuration properties, that are set in the configuration-section - of the plugin-configuration cannnot be overwritten elsewere (for details - see Configuration-Method-Precedence). - You never can overwrite them by accident when specifying a property on - the commandline or in your settings.xml. -
-- Alternatively, it is possible, to configure the plugin via maven-properties. - Each relevant configuration-option has a corresponding maven-property - (for a full list see the Documentation of the goal create). - These are named after the - Hibernate JDBC Properties: -
- -- So, instead of writing the hibernate-configuration in the properties-file, - like above, you could put it in the properties-section of your - pom.xml. -
- -- Thogether with the plugin-definition from above, the following would - be a complete configuration (again, the database-url was overwritten in - the plugin-configuration, to be sure to have a separate database for - testing): -
- --<properties> - <hibernate.connection.driver_class>org.hsqldb.jdbcDriver</hibernate.connection.driver_class> - <hibernate.dialect>org.hibernate.dialect.HSQLDialect</hibernate.dialect> - <hibernate.connection.url><![CDATA[jdbc:hsqldb:res:org.my.path.production_db]]></hibernate.connection.url> - <hibernate.connection.username>sa</hibernate.connection.username> - <hibernate.connection.password></hibernate.connection.password> -</properties> - -... - -<plugins> - - ... - - <plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate-maven-plugin</artifactId> - <version>2.1.0</version> - <executions> - <execution> - <goals> - <goal>drop</goal> - <goal>create</goal> - </goals> - </execution> - </executions> - <configuration> - <url><![CDATA[jdbc:hsqldb:target/db/testdb;shutdown=true]]></url> - </configuration> - </plugin> - -<plugins>
- This way, you can reuse the same properties to provide a - default-configurationthe, that is build into your application, and - overwrite the database-url, that is used during testing to prevent - accidential drops of your production database. -
-- A third way for configuring the plugin is the plugin-configuration. - The relevant configuration-parameters are: -
- -- The equivalent of the configuration from the last section would look - like this: -
- --<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate-maven-plugin</artifactId> - <version>2.1.0</version> - <executions> - <execution> - <goals> - <goal>drop</goal> - <goal>create</goal> - </goals> - </execution> - </executions> - <configuration> - <driver>org.hsqldb.jdbcDriver</driver> - <dialect>org.hibernate.dialect.HSQLDialect</dialect> - <url><![CDATA[jdbc:hsqldb:target/db/fotos;shutdown=true]]></url> - <username>sa</username> - <password></password> - </configuration> -</plugin>
- The parameter hibernateProperties (name of the hibernate-properties-file - to use, defaults to hibernate.properties) can only be configured through - this approach. -
- -- For more explanations, see the - Documentation of the goal create. -
-- The configuration is gathered in a fix order: -
- -- If you are in doubt about where a configuration-value comes from, run - maven with the debug-output enabled: mvn -X hibernate:create - and be aware, that maven-properties can be overwitten on the command-line, - in your ~/.m2/settings.xml and in a profile. -
- -- The plugin-configuration comes last and overwrites everything else. - That way, you can be sure, that a configuration-value, that is - specified in the plugin-configuration will never be overwritten by any - other configuration-method. -
- -- If you need to overwrite plugin-configuration-values with - maven-properties, you can use maven-properties in the plugin-configuration: -
- --<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate-maven-plugin</artifactId> - <version>2.1.0</version> - <executions> - <execution> - <goals> - <goal>drop</goal> - <goal>create</goal> - </goals> - </execution> - </executions> - <configuration> - <password>${my-password-property}</password> - </configuration> -</plugin>
-
-
- -The following document contains the results of PMD's CPD 5.2.3.
File | -Line |
---|---|
de/juplo/plugins/hibernate/CreateMojo.java | -41 |
de/juplo/plugins/hibernate/DropMojo.java | -41 |
-
- public class CreateMojo extends AbstractSchemaMojo -{ - /** - * Output file. - * <p> - * If the specified filename is not absolut, the file will be created - * relative to the project build directory - * (<code>project.build.directory</code>). - * - * @parameter property="hibernate.schema.create" default-value="create.sql" - * @since 1.0 - */ - private String outputFile; - - - @Override - public final void execute() - throws - MojoFailureException, - MojoExecutionException - { - super.execute(outputFile); - } - - - @Override - void build( - MetadataImplementor metadata, - ExecutionOptions options, - TargetDescriptor target - ) - throws - MojoExecutionException, - MojoFailureException - { - ServiceRegistry service = - metadata.getMetadataBuildingOptions().getServiceRegistry(); - SchemaManagementTool tool = service.getService(SchemaManagementTool.class); - - Map config = options.getConfigurationValues(); - SourceDescriptor source = new SourceDescriptor() - { - @Override - public SourceType getSourceType() - { - return SourceType.METADATA; - } - - @Override - public ScriptSourceInput getScriptSourceInput() - { - return null; - } - }; - - tool.getSchemaCreator(config).doCreation(metadata, options, source, target); |
-
-
- -Full name:
- -de.juplo:hibernate-maven-plugin:2.1.0:create
- -Description:
- -Attributes:
- -Name | - -Type | - -Since | - -Description | -
---|---|---|---|
createNamespaces | - -Boolean | - -2.0 | - -Specifies whether to automatically create also the database
-schema/catalog. Default value is: false. User property is: hibernate.hbm2dll.create_namespaces. |
-
delimiter | - -String | - -1.0 | - -Delimiter in output-file.
-
- Important: This configuration value can only be -configured through the pom.xml, or by the definition -of a system-property, because it is not known by Hibernate nor JPA -and, hence, not picked up from their configuration! Default value is: ;. User property is: hibernate.hbm2ddl.delimiter. |
-
dialect | - -String | - -1.0 | - -Hibernate dialect. User property is: hibernate.dialect. |
-
driver | - -String | - -1.0 | - -SQL-Driver name. User property is: hibernate.connection.driver_class. |
-
execute | - -Boolean | - -2.0 | - -Excecute the generated SQL. If set to false, only the
-SQL-script is created and the database is not touched.
-
- Important: This configuration value can only be -configured through the pom.xml, or by the definition -of a system-property, because it is not known by Hibernate nor JPA -and, hence, not picked up from their configuration! Default value is: true. User property is: hibernate.schema.execute. |
-
force | - -boolean | - -1.0 | - -Force generation/execution
-
- Force the generation and (if configured) the execution of the -SQL, even if no modified or newly added annotated classes where -found and the configuration was not changed. - -skip takes precedence over force. - -Important: This configuration value can only be -configured through the pom.xml, or by the definition -of a system-property, because it is not known by Hibernate nor JPA -and, hence, not picked up from their configuration! Default value is: false. User property is: hibernate.schema.force. |
-
format | - -Boolean | - -1.0 | - -Format output-file. User property is: hibernate.format_sql. |
-
hibernateConfig | - -String | - -1.1.0 | - -Path to Hibernate configuration file (.cfg.xml). If this parameter
-is specified, the plugin will try to load configuration values from
-a file with the given path or a ressource on the classpath with the
-given name. If both fails, the execution of the plugin will fail.
-
- If this parameter is not set the plugin will load configuration -values from a ressource named hibernate.cfg.xml on the -classpath, if it is present, but will not fail if there is no such -ressource. - -During ressource-lookup, the test-classpath takes -precedence. - -Settings in this file will overwrite settings in the properties -file. |
-
hibernateProperties | - -String | - -1.0 | - -Path to a file or name of a ressource with hibernate properties. If
-this parameter is specified, the plugin will try to load
-configuration values from a file with the given path or a ressource
-on the classpath with the given name. If both fails, the execution
-of the plugin will fail.
-
- If this parameter is not set the plugin will load configuration -values from a ressource named hibernate.properties on -the classpath, if it is present, but will not fail if there is no -such ressource. - -During ressource-lookup, the test-classpath takes -precedence. |
-
implicitNamingStrategy | - -String | - -2.0 | - -Implicit naming strategy User property is: hibernate.implicit_naming_strategy. |
-
mappings | - -String | - -1.0.2 | - -List of Hibernate-Mapping-Files (XML). Multiple files can be
-separated with white-spaces and/or commas. User property is: hibernate.mapping. |
-
outputDirectory | - -String | - -1.0 | - -Classes-Directory to scan.
-
- This parameter defaults to the maven build-output-directory for -classes. Additionally, all dependencies are scanned for annotated -classes. - -Important: This configuration value can only be -configured through the pom.xml, or by the definition -of a system-property, because it is not known by Hibernate nor JPA -and, hence, not picked up from their configuration! User property is: project.build.outputDirectory. |
-
outputFile | - -String | - -1.0 | - -Output file.
-
- If the specified filename is not absolut, the file will be -created relative to the project build directory -(project.build.directory). Default value is: create.sql. User property is: hibernate.schema.create. |
-
password | - -String | - -1.0 | - -Database password User property is: hibernate.connection.password. |
-
persistenceUnit | - -String | - -1.1.0 | - -Name of the persistence-unit. If this parameter is specified, the
-plugin will try to load configuration values from a
-persistence-unit with the specified name. If no such
-persistence-unit can be found, the plugin will throw an exception.
-
- If this parameter is not set and there is only one -persistence-unit available, that unit will be used automatically. -But if this parameter is not set and there are multiple -persistence-units available on, the class-path, the execution of -the plugin will fail. - -Settings in this file will overwrite settings in the properties -or the configuration file. |
-
physicalNamingStrategy | - -String | - -2.0 | - -Physical naming strategy User property is: hibernate.physical_naming_strategy. |
-
scanClasses | - -Boolean | - -2.0 | - -Wether the project should be scanned for annotated-classes, or not
-
- This parameter is intended to allow overwriting of the parameter -exclude-unlisted-classes of a -persistence-unit. If not specified, it defaults to -true User property is: hibernate.schema.scan.classes. |
-
scanDependencies | - -String | - -1.0.3 | - -Dependency-Scopes, that should be scanned for annotated classes.
-
- By default, only dependencies in the scope compile -are scanned for annotated classes. Multiple scopes can be seperated -by white space or commas. - -If you do not want any dependencies to be scanned for annotated -classes, set this parameter to none. - -The plugin does not scan for annotated classes in transitive -dependencies. If some of your annotated classes are hidden in a -transitive dependency, you can simply add that dependency -explicitly. Default value is: compile. User property is: hibernate.schema.scan.dependencies. |
-
scanTestClasses | - -Boolean | - -1.0.1 | - -Whether to scan the test-branch of the project for annotated
-classes, or not.
-
- If this parameter is set to true the test-classes -of the artifact will be scanned for hibernate-annotated classes -additionally. - -Important: This configuration value can only be -configured through the pom.xml, or by the definition -of a system-property, because it is not known by Hibernate nor JPA -and, hence, not picked up from their configuration! Default value is: false. User property is: hibernate.schema.scan.test_classes. |
-
show | - -Boolean | - -1.0 | - -Show the generated SQL in the command-line output. User property is: hibernate.show_sql. |
-
skip | - -boolean | - -1.0 | - -Skip execution
-
- If set to true, the execution is skipped. - -A skipped execution is signaled via the maven-property -${hibernate.schema.skipped}. - -The execution is skipped automatically, if no modified or newly -added annotated classes are found and the dialect was not -changed. - -Important: This configuration value can only be -configured through the pom.xml, or by the definition -of a system-property, because it is not known by Hibernate nor JPA -and, hence, not picked up from their configuration! Default value is: ${maven.test.skip}. User property is: hibernate.schema.skip. |
-
testOutputDirectory | - -String | - -1.0.2 | - -Test-Classes-Directory to scan.
-
- This parameter defaults to the maven build-output-directory for -test-classes. - -This parameter is only used, when scanTestClasses -is set to true! - -Important: This configuration value can only be -configured through the pom.xml, or by the definition -of a system-property, because it is not known by Hibernate nor JPA -and, hence, not picked up from their configuration! User property is: project.build.testOutputDirectory. |
-
url | - -String | - -1.0 | - -Database URL. User property is: hibernate.connection.url. |
-
username | - -String | - -1.0 | - -Database username User property is: hibernate.connection.username. |
-
Important: This configuration value can only be -configured through the pom.xml, or by the definition -of a system-property, because it is not known by Hibernate nor JPA -and, hence, not picked up from their configuration!
Important: This configuration value can only be -configured through the pom.xml, or by the definition -of a system-property, because it is not known by Hibernate nor JPA -and, hence, not picked up from their configuration!
Force the generation and (if configured) the execution of the -SQL, even if no modified or newly added annotated classes where -found and the configuration was not changed.
- -skip takes precedence over force.
- -Important: This configuration value can only be -configured through the pom.xml, or by the definition -of a system-property, because it is not known by Hibernate nor JPA -and, hence, not picked up from their configuration!
If this parameter is not set the plugin will load configuration -values from a ressource named hibernate.cfg.xml on the -classpath, if it is present, but will not fail if there is no such -ressource.
- -During ressource-lookup, the test-classpath takes -precedence.
- -Settings in this file will overwrite settings in the properties -file.
If this parameter is not set the plugin will load configuration -values from a ressource named hibernate.properties on -the classpath, if it is present, but will not fail if there is no -such ressource.
- -During ressource-lookup, the test-classpath takes -precedence.
This parameter defaults to the maven build-output-directory for -classes. Additionally, all dependencies are scanned for annotated -classes.
- -Important: This configuration value can only be -configured through the pom.xml, or by the definition -of a system-property, because it is not known by Hibernate nor JPA -and, hence, not picked up from their configuration!
If the specified filename is not absolut, the file will be -created relative to the project build directory -(project.build.directory).
If this parameter is not set and there is only one -persistence-unit available, that unit will be used automatically. -But if this parameter is not set and there are multiple -persistence-units available on, the class-path, the execution of -the plugin will fail.
- -Settings in this file will overwrite settings in the properties -or the configuration file.
This parameter is intended to allow overwriting of the parameter -exclude-unlisted-classes of a -persistence-unit. If not specified, it defaults to -true
By default, only dependencies in the scope compile -are scanned for annotated classes. Multiple scopes can be seperated -by white space or commas.
- -If you do not want any dependencies to be scanned for annotated -classes, set this parameter to none.
- -The plugin does not scan for annotated classes in transitive -dependencies. If some of your annotated classes are hidden in a -transitive dependency, you can simply add that dependency -explicitly.
If this parameter is set to true the test-classes -of the artifact will be scanned for hibernate-annotated classes -additionally.
- -Important: This configuration value can only be -configured through the pom.xml, or by the definition -of a system-property, because it is not known by Hibernate nor JPA -and, hence, not picked up from their configuration!
show:
- -skip:
- -If set to true, the execution is skipped.
- -A skipped execution is signaled via the maven-property -${hibernate.schema.skipped}.
- -The execution is skipped automatically, if no modified or newly -added annotated classes are found and the dialect was not -changed.
- -Important: This configuration value can only be -configured through the pom.xml, or by the definition -of a system-property, because it is not known by Hibernate nor JPA -and, hence, not picked up from their configuration!
This parameter defaults to the maven build-output-directory for -test-classes.
- -This parameter is only used, when scanTestClasses -is set to true!
- -Important: This configuration value can only be -configured through the pom.xml, or by the definition -of a system-property, because it is not known by Hibernate nor JPA -and, hence, not picked up from their configuration!
url:
- --
-
- -- If you are new to hibernate-maven-plugin, in many cases, the - Configuration-Method-Precedence - may be the source of configuration errors. - To solve this problem, you should run maven with the debugging output - enabled. - For example, by executing: -
- --mvn -X compile hibernate:create
- (The compile might be necessary, because hibernate-maven-plugin - has to scan the compiled classes for annotations!) -
- -- Unlike the majority of the maven-plugins, hibernate-maven-plugin was - designed to give a good many hints, when debugging is enabled. - Because, if you do not know, what went wrong, you can't fix it! -
- -- But be warned: hibernate-maven-plugin tends to be very chatty ;) -
- - --
-
- -The following is a list of compile dependencies for this project. These dependencies are required to compile and run the application:
-GroupId | -ArtifactId | -Version | -Type | -Licenses |
---|---|---|---|---|
com.pyx4j | -maven-plugin-log4j | -1.0.1 | -jar | -The Apache Software License, Version 2.0 |
de.juplo | -scannotation | -1.0.4 | -jar | -- |
javax.el | -javax.el-api | -3.0.0 | -jar | -CDDL + GPLv2 with classpath exception |
org.apache.maven | -maven-core | -3.3.3 | -jar | -Apache License, Version 2.0 |
org.apache.maven | -maven-plugin-api | -3.3.3 | -jar | -Apache License, Version 2.0 |
org.hibernate | -hibernate-core | -5.2.4.Final | -jar | -GNU Lesser General Public License |
org.hibernate | -hibernate-envers | -5.2.4.Final | -jar | -GNU Lesser General Public License |
org.hibernate | -hibernate-validator | -5.3.1.Final | -jar | -Apache License, Version 2.0 |
The following is a list of transitive dependencies for this project. Transitive dependencies are the dependencies of the project dependencies.
-The following is a list of compile dependencies for this project. These dependencies are required to compile and run the application:
-Apache License, version 2.0: JBoss Logging 3
-Eclipse Public License (EPL), Version 1.0: Java Persistence API, Version 2.1
-Apache Public License 2.0: Plexus Cipher: encryption/decryption Component, Plexus Security Dispatcher Component
-lgpl: Interceptors 1.1 API
-Public Domain: AOP alliance
-GNU Lesser General Public License: Core Hibernate O/RM functionality, ENtity VERSioning support, Hibernate Commons Annotations
-Eclipse Distribution License (EDL), Version 1.0: Java Persistence API, Version 2.1
-Eclipse Public License, Version 1.0: Aether API, Aether Implementation, Aether SPI, Aether Utilities, org.eclipse.sisu.inject, org.eclipse.sisu.plexus
-Unknown: Expression Language API (2.1 Maintenance Release), dom4j, scannotation
-Apache License 2.0: Javassist
-BSD License: AntLR Parser Generator
-Apache License, Version 2.0: CDI APIs, Hibernate Validator Engine, Java Annotation Indexer, Maven Aether Provider, Maven Artifact, Maven Builder Support, Maven Core, Maven Model, Maven Model Builder, Maven Plugin API, Maven Repository Metadata Model, Maven Settings, Maven Settings Builder
-COMMON DEVELOPMENT AND DISTRIBUTION LICENSE (CDDL) Version 1.0: JSR-250 Common Annotations for the JavaTM Platform
-LGPL 2.1: Javassist
-CDDL + GPLv2 with classpath exception: Expression Language 3.0 API
-MPL 1.1: Javassist
-The Apache Software License, Version 2.0: Bean Validation API, ClassMate, Guava: Google Core Libraries for Java, Hibernate Maven Plugin, JTA 1.1, Log4j, Plexus :: Component Annotations, Plexus Classworlds, Plexus Interpolation API, Sisu Guice - Core Library, javax.inject, maven-plugin-log4j
Filename | -Size | -Entries | -Classes | -Packages | -Java Version | -Debug Information |
---|---|---|---|---|---|---|
antlr-2.7.7.jar | -445.3 kB | -239 | -224 | -12 | -1.2 | -Yes |
aopalliance-1.0.jar | -4.5 kB | -15 | -9 | -2 | -1.3 | -Yes |
classmate-1.3.0.jar | -64.1 kB | -52 | -37 | -4 | -1.6 | -Yes |
guava-18.0.jar | -2.3 MB | -1719 | -1690 | -17 | -1.6 | -Yes |
maven-plugin-log4j-1.0.1.jar | -3.7 kB | -12 | -1 | -1 | -1.4 | -Yes |
scannotation-1.0.4.jar | -20.3 kB | -23 | -13 | -2 | -1.6 | -Yes |
dom4j-1.6.1.jar | -313.9 kB | -208 | -190 | -14 | -1.3 | -Yes |
jsr250-api-1.0.jar | -5.8 kB | -16 | -11 | -2 | -1.5 | -Yes |
el-api-2.2.jar | -33.9 kB | -38 | -28 | -1 | -1.5 | -Yes |
javax.el-api-3.0.0.jar | -73.1 kB | -57 | -46 | -1 | -1.7 | -Yes |
cdi-api-1.1.jar | -70.7 kB | -118 | -98 | -7 | -1.6 | -Yes |
javax.inject-1.jar | -2.5 kB | -8 | -6 | -1 | -1.5 | -No |
validation-api-1.1.0.Final.jar | -63.8 kB | -122 | -106 | -8 | -1.6 | -Yes |
log4j-1.2.14.jar | -367.4 kB | -288 | -256 | -19 | -1.1 | -Yes |
geronimo-jta_1.1_spec-1.1.1.jar | -16 kB | -30 | -18 | -2 | -1.5 | -Yes |
maven-aether-provider-3.3.3.jar | -66.3 kB | -43 | -26 | -1 | -1.7 | -Yes |
maven-artifact-3.3.3.jar | -55.1 kB | -57 | -32 | -11 | -1.7 | -Yes |
maven-builder-support-3.3.3.jar | -15 kB | -24 | -10 | -1 | -1.7 | -Yes |
maven-core-3.3.3.jar | -631.9 kB | -489 | -390 | -56 | -1.7 | -Yes |
maven-model-3.3.3.jar | -160.8 kB | -67 | -50 | -3 | -1.7 | -Yes |
maven-model-builder-3.3.3.jar | -176.4 kB | -154 | -121 | -16 | -1.7 | -Yes |
maven-plugin-api-3.3.3.jar | -46.1 kB | -46 | -25 | -6 | -1.7 | -Yes |
maven-repository-metadata-3.3.3.jar | -26 kB | -25 | -7 | -2 | -1.7 | -Yes |
maven-settings-3.3.3.jar | -43 kB | -33 | -17 | -2 | -1.7 | -Yes |
maven-settings-builder-3.3.3.jar | -43.2 kB | -53 | -32 | -5 | -1.7 | -Yes |
plexus-classworlds-2.5.2.jar | -52.7 kB | -52 | -37 | -5 | -1.6 | -Yes |
plexus-component-annotations-1.5.5.jar | -4.2 kB | -15 | -3 | -1 | -1.5 | -No |
plexus-interpolation-1.21.jar | -62.5 kB | -60 | -44 | -6 | -1.5 | -Yes |
aether-api-1.0.2.v20150114.jar | -136.3 kB | -149 | -128 | -11 | -1.5 | -Yes |
aether-impl-1.0.2.v20150114.jar | -173 kB | -114 | -96 | -4 | -1.5 | -Yes |
aether-spi-1.0.2.v20150114.jar | -30.7 kB | -54 | -34 | -8 | -1.5 | -Yes |
aether-util-1.0.2.v20150114.jar | -146.9 kB | -126 | -101 | -13 | -1.5 | -Yes |
org.eclipse.sisu.inject-0.3.0.jar | -375.3 kB | -287 | -269 | -9 | -1.6 | -Yes |
org.eclipse.sisu.plexus-0.3.0.jar | -205.4 kB | -196 | -164 | -20 | -1.6 | -Yes |
hibernate-core-5.2.4.Final.jar | -6.4 MB | -4645 | -4317 | -249 | -1.8 | -Yes |
hibernate-envers-5.2.4.Final.jar | -436.6 kB | -333 | -278 | -37 | -1.8 | -Yes |
hibernate-validator-5.3.1.Final.jar | -723.4 kB | -548 | -458 | -54 | -1.6 | -Yes |
hibernate-commons-annotations-5.0.1.Final.jar | -75.3 kB | -80 | -67 | -7 | -1.6 | -Yes |
hibernate-jpa-2.1-api-1.0.0.Final.jar | -113.4 kB | -207 | -200 | -4 | -1.6 | -Yes |
javassist-3.20.0-GA.jar | -750.6 kB | -423 | -399 | -17 | -1.6 | -Yes |
jandex-2.0.0.Final.jar | -187.8 kB | -112 | -102 | -1 | -1.6 | -Yes |
jboss-logging-3.3.0.Final.jar | -66.8 kB | -60 | -48 | -1 | -1.6 | -Yes |
jboss-interceptors-api_1.1_spec-1.0.0.Beta1.jar | -5.6 kB | -17 | -8 | -1 | -1.5 | -No |
plexus-cipher-1.4.jar | -13.5 kB | -20 | -6 | -1 | -1.4 | -Yes |
plexus-sec-dispatcher-1.3.jar | -28.6 kB | -31 | -13 | -3 | -1.4 | -Yes |
sisu-guice-3.2.5-no_aop.jar | -399.7 kB | -331 | -316 | -8 | -1.6 | -Yes |
Total | -Size | -Entries | -Classes | -Packages | -Java Version | -Debug Information |
46 | -15.4 MB | -11796 | -10531 | -656 | -1.8 | -43 |
compile: 46 | -compile: 15.4 MB | -compile: 11796 | -compile: 10531 | -compile: 656 | -- | -compile: 43 |
Repo ID | -URL | -Release | -Snapshot | -Blacklisted |
---|---|---|---|---|
plexus.snapshots | -https://oss.sonatype.org/content/repositories/plexus-snapshots | -No | -Yes | -No |
central | -https://repo.maven.apache.org/maven2 | -Yes | -No | -No |
codehaus-snapshots | -http://snapshots.repository.codehaus.org | -No | -Yes | -Yes |
apache-snapshots | -http://people.apache.org/repo/m2-snapshot-repository | -No | -Yes | -Yes |
sonatype-nexus-snapshots | -https://oss.sonatype.org/content/repositories/snapshots | -No | -Yes | -No |
jvnet-nexus-snapshots | -https://maven.java.net/content/repositories/snapshots | -No | -Yes | -No |
apache-incubator | -http://people.apache.org/repo/m2-incubating-repository/ | -Yes | -No | -Yes |
jboss-public-repository-group | -http://repository.jboss.org/nexus/content/groups/public | -Yes | -No | -No |
apache.snapshots | -http://repository.apache.org/snapshots | -No | -Yes | -No |
Repository locations for each of the Dependencies.
--
-
- -<dependency> - <groupId>de.juplo</groupId> - <artifactId>hibernate-maven-plugin</artifactId> - <version>2.1.0</version> - <type>maven-plugin</type> -</dependency>
<dependency org="de.juplo" name="hibernate-maven-plugin" rev="2.1.0"> - <artifact name="hibernate-maven-plugin" type="maven-plugin" /> -</dependency>
-
-
- -The following is the distribution management information used by this project.
- --
-
- -Full name:
- -de.juplo:hibernate-maven-plugin:2.1.0:drop
- -Description:
- -Attributes:
- -Name | - -Type | - -Since | - -Description | -
---|---|---|---|
createNamespaces | - -Boolean | - -2.0 | - -Specifies whether to automatically create also the database
-schema/catalog. Default value is: false. User property is: hibernate.hbm2dll.create_namespaces. |
-
delimiter | - -String | - -1.0 | - -Delimiter in output-file.
-
- Important: This configuration value can only be -configured through the pom.xml, or by the definition -of a system-property, because it is not known by Hibernate nor JPA -and, hence, not picked up from their configuration! Default value is: ;. User property is: hibernate.hbm2ddl.delimiter. |
-
dialect | - -String | - -1.0 | - -Hibernate dialect. User property is: hibernate.dialect. |
-
driver | - -String | - -1.0 | - -SQL-Driver name. User property is: hibernate.connection.driver_class. |
-
execute | - -Boolean | - -2.0 | - -Excecute the generated SQL. If set to false, only the
-SQL-script is created and the database is not touched.
-
- Important: This configuration value can only be -configured through the pom.xml, or by the definition -of a system-property, because it is not known by Hibernate nor JPA -and, hence, not picked up from their configuration! Default value is: true. User property is: hibernate.schema.execute. |
-
force | - -boolean | - -1.0 | - -Force generation/execution
-
- Force the generation and (if configured) the execution of the -SQL, even if no modified or newly added annotated classes where -found and the configuration was not changed. - -skip takes precedence over force. - -Important: This configuration value can only be -configured through the pom.xml, or by the definition -of a system-property, because it is not known by Hibernate nor JPA -and, hence, not picked up from their configuration! Default value is: false. User property is: hibernate.schema.force. |
-
format | - -Boolean | - -1.0 | - -Format output-file. User property is: hibernate.format_sql. |
-
hibernateConfig | - -String | - -1.1.0 | - -Path to Hibernate configuration file (.cfg.xml). If this parameter
-is specified, the plugin will try to load configuration values from
-a file with the given path or a ressource on the classpath with the
-given name. If both fails, the execution of the plugin will fail.
-
- If this parameter is not set the plugin will load configuration -values from a ressource named hibernate.cfg.xml on the -classpath, if it is present, but will not fail if there is no such -ressource. - -During ressource-lookup, the test-classpath takes -precedence. - -Settings in this file will overwrite settings in the properties -file. |
-
hibernateProperties | - -String | - -1.0 | - -Path to a file or name of a ressource with hibernate properties. If
-this parameter is specified, the plugin will try to load
-configuration values from a file with the given path or a ressource
-on the classpath with the given name. If both fails, the execution
-of the plugin will fail.
-
- If this parameter is not set the plugin will load configuration -values from a ressource named hibernate.properties on -the classpath, if it is present, but will not fail if there is no -such ressource. - -During ressource-lookup, the test-classpath takes -precedence. |
-
implicitNamingStrategy | - -String | - -2.0 | - -Implicit naming strategy User property is: hibernate.implicit_naming_strategy. |
-
mappings | - -String | - -1.0.2 | - -List of Hibernate-Mapping-Files (XML). Multiple files can be
-separated with white-spaces and/or commas. User property is: hibernate.mapping. |
-
outputDirectory | - -String | - -1.0 | - -Classes-Directory to scan.
-
- This parameter defaults to the maven build-output-directory for -classes. Additionally, all dependencies are scanned for annotated -classes. - -Important: This configuration value can only be -configured through the pom.xml, or by the definition -of a system-property, because it is not known by Hibernate nor JPA -and, hence, not picked up from their configuration! User property is: project.build.outputDirectory. |
-
outputFile | - -String | - -1.0 | - -Output file.
-
- If the specified filename is not absolut, the file will be -created relative to the project build directory -(project.build.directory). Default value is: drop.sql. User property is: hibernate.schema.drop. |
-
password | - -String | - -1.0 | - -Database password User property is: hibernate.connection.password. |
-
persistenceUnit | - -String | - -1.1.0 | - -Name of the persistence-unit. If this parameter is specified, the
-plugin will try to load configuration values from a
-persistence-unit with the specified name. If no such
-persistence-unit can be found, the plugin will throw an exception.
-
- If this parameter is not set and there is only one -persistence-unit available, that unit will be used automatically. -But if this parameter is not set and there are multiple -persistence-units available on, the class-path, the execution of -the plugin will fail. - -Settings in this file will overwrite settings in the properties -or the configuration file. |
-
physicalNamingStrategy | - -String | - -2.0 | - -Physical naming strategy User property is: hibernate.physical_naming_strategy. |
-
scanClasses | - -Boolean | - -2.0 | - -Wether the project should be scanned for annotated-classes, or not
-
- This parameter is intended to allow overwriting of the parameter -exclude-unlisted-classes of a -persistence-unit. If not specified, it defaults to -true User property is: hibernate.schema.scan.classes. |
-
scanDependencies | - -String | - -1.0.3 | - -Dependency-Scopes, that should be scanned for annotated classes.
-
- By default, only dependencies in the scope compile -are scanned for annotated classes. Multiple scopes can be seperated -by white space or commas. - -If you do not want any dependencies to be scanned for annotated -classes, set this parameter to none. - -The plugin does not scan for annotated classes in transitive -dependencies. If some of your annotated classes are hidden in a -transitive dependency, you can simply add that dependency -explicitly. Default value is: compile. User property is: hibernate.schema.scan.dependencies. |
-
scanTestClasses | - -Boolean | - -1.0.1 | - -Whether to scan the test-branch of the project for annotated
-classes, or not.
-
- If this parameter is set to true the test-classes -of the artifact will be scanned for hibernate-annotated classes -additionally. - -Important: This configuration value can only be -configured through the pom.xml, or by the definition -of a system-property, because it is not known by Hibernate nor JPA -and, hence, not picked up from their configuration! Default value is: false. User property is: hibernate.schema.scan.test_classes. |
-
show | - -Boolean | - -1.0 | - -Show the generated SQL in the command-line output. User property is: hibernate.show_sql. |
-
skip | - -boolean | - -1.0 | - -Skip execution
-
- If set to true, the execution is skipped. - -A skipped execution is signaled via the maven-property -${hibernate.schema.skipped}. - -The execution is skipped automatically, if no modified or newly -added annotated classes are found and the dialect was not -changed. - -Important: This configuration value can only be -configured through the pom.xml, or by the definition -of a system-property, because it is not known by Hibernate nor JPA -and, hence, not picked up from their configuration! Default value is: ${maven.test.skip}. User property is: hibernate.schema.skip. |
-
testOutputDirectory | - -String | - -1.0.2 | - -Test-Classes-Directory to scan.
-
- This parameter defaults to the maven build-output-directory for -test-classes. - -This parameter is only used, when scanTestClasses -is set to true! - -Important: This configuration value can only be -configured through the pom.xml, or by the definition -of a system-property, because it is not known by Hibernate nor JPA -and, hence, not picked up from their configuration! User property is: project.build.testOutputDirectory. |
-
url | - -String | - -1.0 | - -Database URL. User property is: hibernate.connection.url. |
-
username | - -String | - -1.0 | - -Database username User property is: hibernate.connection.username. |
-
Important: This configuration value can only be -configured through the pom.xml, or by the definition -of a system-property, because it is not known by Hibernate nor JPA -and, hence, not picked up from their configuration!
Important: This configuration value can only be -configured through the pom.xml, or by the definition -of a system-property, because it is not known by Hibernate nor JPA -and, hence, not picked up from their configuration!
Force the generation and (if configured) the execution of the -SQL, even if no modified or newly added annotated classes where -found and the configuration was not changed.
- -skip takes precedence over force.
- -Important: This configuration value can only be -configured through the pom.xml, or by the definition -of a system-property, because it is not known by Hibernate nor JPA -and, hence, not picked up from their configuration!
If this parameter is not set the plugin will load configuration -values from a ressource named hibernate.cfg.xml on the -classpath, if it is present, but will not fail if there is no such -ressource.
- -During ressource-lookup, the test-classpath takes -precedence.
- -Settings in this file will overwrite settings in the properties -file.
If this parameter is not set the plugin will load configuration -values from a ressource named hibernate.properties on -the classpath, if it is present, but will not fail if there is no -such ressource.
- -During ressource-lookup, the test-classpath takes -precedence.
This parameter defaults to the maven build-output-directory for -classes. Additionally, all dependencies are scanned for annotated -classes.
- -Important: This configuration value can only be -configured through the pom.xml, or by the definition -of a system-property, because it is not known by Hibernate nor JPA -and, hence, not picked up from their configuration!
If the specified filename is not absolut, the file will be -created relative to the project build directory -(project.build.directory).
If this parameter is not set and there is only one -persistence-unit available, that unit will be used automatically. -But if this parameter is not set and there are multiple -persistence-units available on, the class-path, the execution of -the plugin will fail.
- -Settings in this file will overwrite settings in the properties -or the configuration file.
This parameter is intended to allow overwriting of the parameter -exclude-unlisted-classes of a -persistence-unit. If not specified, it defaults to -true
By default, only dependencies in the scope compile -are scanned for annotated classes. Multiple scopes can be seperated -by white space or commas.
- -If you do not want any dependencies to be scanned for annotated -classes, set this parameter to none.
- -The plugin does not scan for annotated classes in transitive -dependencies. If some of your annotated classes are hidden in a -transitive dependency, you can simply add that dependency -explicitly.
If this parameter is set to true the test-classes -of the artifact will be scanned for hibernate-annotated classes -additionally.
- -Important: This configuration value can only be -configured through the pom.xml, or by the definition -of a system-property, because it is not known by Hibernate nor JPA -and, hence, not picked up from their configuration!
show:
- -skip:
- -If set to true, the execution is skipped.
- -A skipped execution is signaled via the maven-property -${hibernate.schema.skipped}.
- -The execution is skipped automatically, if no modified or newly -added annotated classes are found and the dialect was not -changed.
- -Important: This configuration value can only be -configured through the pom.xml, or by the definition -of a system-property, because it is not known by Hibernate nor JPA -and, hence, not picked up from their configuration!
This parameter defaults to the maven build-output-directory for -test-classes.
- -This parameter is only used, when scanTestClasses -is set to true!
- -Important: This configuration value can only be -configured through the pom.xml, or by the definition -of a system-property, because it is not known by Hibernate nor JPA -and, hence, not picked up from their configuration!
url:
- --
-
- -- The hibernate-maven-plugin computes MD5-sums for all found annotated - classes and stores them together with the generated schema. - If no classes were changed or added and the dialect wasn't changed too, it - automatically skips the configured SQL-generation — and more - important in this respect — the execution of the generated SQL, - to speed up the development cycle. -
- -- The plugin signals, that the execution was skipped by setting the maven - property ${hibernate.schema.skipped} to true. - This may be helpful, because other plugins like - dbunit-plugin - may fail, when the execution is skipped. -
- -- If you need the hibernate-maven-plugin to never skip execution automatically, - you can force it to do so, if you set the parameter force to - true: -
- --<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate-maven-plugin</artifactId> - <version>2.1.0</version> - <configuration> - <force>true</force> - </configuration> -</plugin>
- Or you may specify -Dhibernate.schema.force=true at the command line, - if you want to force hibernate-maven-plugin only once. -
- - --
-
Full name:
- -de.juplo:hibernate-maven-plugin:2.1.0:help
- -Description:
- -Attributes:
- -Name | - -Type | - -Since | - -Description | -
---|---|---|---|
detail | - -boolean | - -- | - -If true, display all settable properties for each
-goal. Default value is: false. User property is: detail. |
-
goal | - -String | - -- | - -The name of the goal for which to show help. If unspecified, all
-goals will be displayed. User property is: goal. |
-
indentSize | - -int | - -- | - -The number of spaces per indentation level, should be positive. Default value is: 2. User property is: indentSize. |
-
lineLength | - -int | - -- | - -The maximum length of a display line, should be positive. Default value is: 80. User property is: lineLength. |
-
goal:
- --
-
- -- The hibernate-maven-plugin is a plugin for generating a database-schema - from your Hibernate-Mappings and create or update your database - accordingly. - Its main usage is to automatically create and populate a test-database - for unit-tests in cooperation with the - dbunit-maven-plugin. -
- -- The plugin was designed with three main goals in mind: -
- -- To achieve the first goal, the convention-over-configuration paradigma - was applied and the plugin was stuffed with usefull logging-messages. - So, if in doubt, just turn on the debugging output with the mvn -X .... -
- -- To achieve the second goal, the precedence in which the configuration - locations are consulted was layouted in a way that makes it possible, to - prevent overwrites of the wrong database by accident. -
- -- Last but not least, in order to not slow down the development cycle, the - hibernate-maven-plugin only executes the generated SQL, if the mapping - or the configuration has changed (or if you force it to do so). -
- -- For more information about the inspiration to write this tiny plugin, - read our blog-article about the hibernate-maven-plugin. -
--
-
- -Configuration for notifying developers/users when a build is unsuccessful, including user information and notification mode.
-Type | -Address | -Configuration |
---|---|---|
kai@juplo.de | -- |
-
-
- Please send your bug-reports, questions or feature-requests directly - to the developer. -
- - --
-
- -Typically the licenses listed for the project are that of the project itself, and not of dependencies.
A business-friendly OSS license
-- Apache License - Version 2.0, January 2004 - http://www.apache.org/licenses/ - - TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION - - 1. Definitions. - - "License" shall mean the terms and conditions for use, reproduction, - and distribution as defined by Sections 1 through 9 of this document. - - "Licensor" shall mean the copyright owner or entity authorized by - the copyright owner that is granting the License. - - "Legal Entity" shall mean the union of the acting entity and all - other entities that control, are controlled by, or are under common - control with that entity. For the purposes of this definition, - "control" means (i) the power, direct or indirect, to cause the - direction or management of such entity, whether by contract or - otherwise, or (ii) ownership of fifty percent (50%) or more of the - outstanding shares, or (iii) beneficial ownership of such entity. - - "You" (or "Your") shall mean an individual or Legal Entity - exercising permissions granted by this License. - - "Source" form shall mean the preferred form for making modifications, - including but not limited to software source code, documentation - source, and configuration files. - - "Object" form shall mean any form resulting from mechanical - transformation or translation of a Source form, including but - not limited to compiled object code, generated documentation, - and conversions to other media types. - - "Work" shall mean the work of authorship, whether in Source or - Object form, made available under the License, as indicated by a - copyright notice that is included in or attached to the work - (an example is provided in the Appendix below). - - "Derivative Works" shall mean any work, whether in Source or Object - form, that is based on (or derived from) the Work and for which the - editorial revisions, annotations, elaborations, or other modifications - represent, as a whole, an original work of authorship. For the purposes - of this License, Derivative Works shall not include works that remain - separable from, or merely link (or bind by name) to the interfaces of, - the Work and Derivative Works thereof. - - "Contribution" shall mean any work of authorship, including - the original version of the Work and any modifications or additions - to that Work or Derivative Works thereof, that is intentionally - submitted to Licensor for inclusion in the Work by the copyright owner - or by an individual or Legal Entity authorized to submit on behalf of - the copyright owner. For the purposes of this definition, "submitted" - means any form of electronic, verbal, or written communication sent - to the Licensor or its representatives, including but not limited to - communication on electronic mailing lists, source code control systems, - and issue tracking systems that are managed by, or on behalf of, the - Licensor for the purpose of discussing and improving the Work, but - excluding communication that is conspicuously marked or otherwise - designated in writing by the copyright owner as "Not a Contribution." - - "Contributor" shall mean Licensor and any individual or Legal Entity - on behalf of whom a Contribution has been received by Licensor and - subsequently incorporated within the Work. - - 2. Grant of Copyright License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - copyright license to reproduce, prepare Derivative Works of, - publicly display, publicly perform, sublicense, and distribute the - Work and such Derivative Works in Source or Object form. - - 3. Grant of Patent License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - (except as stated in this section) patent license to make, have made, - use, offer to sell, sell, import, and otherwise transfer the Work, - where such license applies only to those patent claims licensable - by such Contributor that are necessarily infringed by their - Contribution(s) alone or by combination of their Contribution(s) - with the Work to which such Contribution(s) was submitted. If You - institute patent litigation against any entity (including a - cross-claim or counterclaim in a lawsuit) alleging that the Work - or a Contribution incorporated within the Work constitutes direct - or contributory patent infringement, then any patent licenses - granted to You under this License for that Work shall terminate - as of the date such litigation is filed. - - 4. Redistribution. You may reproduce and distribute copies of the - Work or Derivative Works thereof in any medium, with or without - modifications, and in Source or Object form, provided that You - meet the following conditions: - - (a) You must give any other recipients of the Work or - Derivative Works a copy of this License; and - - (b) You must cause any modified files to carry prominent notices - stating that You changed the files; and - - (c) You must retain, in the Source form of any Derivative Works - that You distribute, all copyright, patent, trademark, and - attribution notices from the Source form of the Work, - excluding those notices that do not pertain to any part of - the Derivative Works; and - - (d) If the Work includes a "NOTICE" text file as part of its - distribution, then any Derivative Works that You distribute must - include a readable copy of the attribution notices contained - within such NOTICE file, excluding those notices that do not - pertain to any part of the Derivative Works, in at least one - of the following places: within a NOTICE text file distributed - as part of the Derivative Works; within the Source form or - documentation, if provided along with the Derivative Works; or, - within a display generated by the Derivative Works, if and - wherever such third-party notices normally appear. The contents - of the NOTICE file are for informational purposes only and - do not modify the License. You may add Your own attribution - notices within Derivative Works that You distribute, alongside - or as an addendum to the NOTICE text from the Work, provided - that such additional attribution notices cannot be construed - as modifying the License. - - You may add Your own copyright statement to Your modifications and - may provide additional or different license terms and conditions - for use, reproduction, or distribution of Your modifications, or - for any such Derivative Works as a whole, provided Your use, - reproduction, and distribution of the Work otherwise complies with - the conditions stated in this License. - - 5. Submission of Contributions. Unless You explicitly state otherwise, - any Contribution intentionally submitted for inclusion in the Work - by You to the Licensor shall be under the terms and conditions of - this License, without any additional terms or conditions. - Notwithstanding the above, nothing herein shall supersede or modify - the terms of any separate license agreement you may have executed - with Licensor regarding such Contributions. - - 6. Trademarks. This License does not grant permission to use the trade - names, trademarks, service marks, or product names of the Licensor, - except as required for reasonable and customary use in describing the - origin of the Work and reproducing the content of the NOTICE file. - - 7. Disclaimer of Warranty. Unless required by applicable law or - agreed to in writing, Licensor provides the Work (and each - Contributor provides its Contributions) on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or - implied, including, without limitation, any warranties or conditions - of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A - PARTICULAR PURPOSE. You are solely responsible for determining the - appropriateness of using or redistributing the Work and assume any - risks associated with Your exercise of permissions under this License. - - 8. Limitation of Liability. In no event and under no legal theory, - whether in tort (including negligence), contract, or otherwise, - unless required by applicable law (such as deliberate and grossly - negligent acts) or agreed to in writing, shall any Contributor be - liable to You for damages, including any direct, indirect, special, - incidental, or consequential damages of any character arising as a - result of this License or out of the use or inability to use the - Work (including but not limited to damages for loss of goodwill, - work stoppage, computer failure or malfunction, or any and all - other commercial damages or losses), even if such Contributor - has been advised of the possibility of such damages. - - 9. Accepting Warranty or Additional Liability. While redistributing - the Work or Derivative Works thereof, You may choose to offer, - and charge a fee for, acceptance of support, warranty, indemnity, - or other liability obligations and/or rights consistent with this - License. However, in accepting such obligations, You may act only - on Your own behalf and on Your sole responsibility, not on behalf - of any other Contributor, and only if You agree to indemnify, - defend, and hold each Contributor harmless for any liability - incurred by, or claims asserted against, such Contributor by reason - of your accepting any such warranty or additional liability. - - END OF TERMS AND CONDITIONS - - APPENDIX: How to apply the Apache License to your work. - - To apply the Apache License to your work, attach the following - boilerplate notice, with the fields enclosed by brackets "[]" - replaced with your own identifying information. (Don't include - the brackets!) The text should be enclosed in the appropriate - comment syntax for the file format. We also recommend that a - file or class name and description of purpose be included on the - same "printed page" as the copyright notice for easier - identification within third-party archives. - - Copyright [yyyy] [name of copyright owner] - - Licensed under the Apache License, Version 2.0 (the "License"); - you may not use this file except in compliance with the License. - You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. -
-
-
- Please send your bug-reports, questions or feature-requests directly - to the developer. -
- - --
-
- -- hibernate-maven-plugin by default scans dependencies in the scope - compile. You can configure it to scan dependencies in other - scopes as well. But it scans only direct dependencies. Transitive - dependencies are not scanned for annotated classes. If some of your - annotated classes are hidden in a transitive dependency, you can simply - add that dependency explicitly. -
-- The default-configuration executes the created SQL. - Therefore, it needs a valid database-connection and fails, if none is - available. - If you do not need the generated SQL to be executed automatically, - you can set the property hibernate.schema.execute to - false. - This can be achieved with the command-line parameter - -Dhibernate.schema.execute=false or with the following - configuration: -
- --<configuration> - <execute>false</execute> -</configuration>
- But even when no database is to be created, hibernate always needs to know - the dialect. Hence, the plugin will still fail, if this parameter is also - missing! -
-- One regular problem is the scope of the jdbc-driver-dependency. - It is very unlikely, that this dependency is needed at compile-time. - So a tidy maven-developer would usually scope it for runtime. -
- -- But this will break the execution of the hibernate-maven-plugin. - Since it will not be able to see the needed dependency, it will fail with - an error-message like: -
- --[INFO] Gathered hibernate-configuration (turn on debugging for details): -[INFO] hibernate.connection.username = sa -[INFO] hibernate.connection.password = -[INFO] hibernate.dialect = org.hibernate.dialect.H2Dialect -[INFO] hibernate.connection.url = jdbc:h2:file:./db -[INFO] hibernate.hbm2dll.create_namespaces = false -[INFO] hibernate.connection.driver_class = org.h2.Driver -[INFO] hibernate.format_sql = true -[INFO] HHH000412: Hibernate Core {5.0.2.Final} -[INFO] HHH000206: hibernate.properties not found -[INFO] HHH000021: Bytecode provider name : javassist -[INFO] Adding /home/kai/project/target/classes to the list of roots to scan... -[INFO] Adding dependencies from scope compile to the list of roots to scan -[INFO] Adding dependencies from scope org.hibernate:hibernate-core:jar:4.3.0.Final to the list of roots to scan -[INFO] Adding annotated resource: de.juplo.tests.SimplestMavenHib4Test -[INFO] ------------------------------------------------------------------------ -[INFO] BUILD FAILURE -[INFO] ------------------------------------------------------------------------ -[INFO] Total time: 1.760s -[INFO] Finished at: Mon Mar 07 19:06:54 CET 2016 -[INFO] Final Memory: 11M/215M -[INFO] ------------------------------------------------------------------------ -[ERROR] Failed to execute goal de.juplo:hibernate-maven-plugin:2.1.0:drop (default) on project hibernate4-properties-test: Could not open the JDBC-connection: Unable to load class [org.h2.Driver]: Could not load requested class : org.h2.Driver -> [Help 1] -[ERROR] -[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch. -[ERROR] Re-run Maven using the -X switch to enable full debug logging. -[ERROR] -[ERROR] For more information about the errors and possible solutions, please read the following articles: -[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException
- A quick workaround for this error would be, to delete the runtime-constraint - for the jdbc-driver-dependency. -
- -- A much cleaner way is, to (additionally) ad the dependency, to the - plugin-definition: -
- --<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate-maven-plugin</artifactId> - <version>2.1.0</version> - <executions> - <execution> - <goals> - <goal>drop</goal> - <goal>create</goal> - </goals> - </execution> - </executions> - <dependencies> - <dependency> - <groupId>org.hsqldb</groupId> - <artifactId>hsqldb</artifactId> - <version>2.2.8</version> - </dependency> - </dependencies> -</plugin>
- This is also the best way, if you use a different jdbc-driver for - testing, than in production. - Because otherwise, this dependency will unnecessarily bloat the - runtime-dependencies of your project. -
-- If hibernate-maven-plugin skips its excecution, this may lead to errors in - other plugins. - For example, when importing sample-data in the automatically created database - with the help of the dbunit-plugin, - the CLEAN_INSERT-operation may fail because of foreign-key-constraints, - if the database was not recreated, because the hibernate-maven-plugin has - skipped its excecution. -
- -- A quick fix to this problem is, to force - hibernate-maven-plugin to generate and execute the SQL every time it is running. - But to recreate the database on every testrun may noticeable slow down your - development cycle, if you have to wait for slow IO. -
- -- To circumvent this problem, hibernate-maven-plugin signals a skipped - excecution by setting the maven property ${hibernate.schema.skipped} to - true. - You can configure other plugins to react on this signal. - For example, the dbunit-plugin can be configured to skip its excecution, if - hibernate-maven-plugin was skipped like this: -
- --<plugin> - <groupId>org.codehaus.mojo</groupId> - <artifactId>dbunit-maven-plugin</artifactId> - <configuration> - <skip>${hibernate.schema.skipped}</skip> - </configuration> -</plugin>
- If one manually drops the database or removes the hsqldb-files, it will not - be recreated by the hibernate-maven-plugin, because it cannot detect, that - the database needs to be recreated. - This happens, because the plugin will not recreate the database if neither - the configuration nor the annotated classes have changed, because an - unnecessary drop-create-cycle might take a long time. The plugin will - report that like this: -
- --[INFO] No modified annotated classes found and dialect unchanged. -[INFO] Skipping schema generation!
- If one always uses mvn clean for cleanup, this will not happen. - Otherwise the recreation must be forced: -
- --mvn hibernate:create -Dhibernate.schema.force=true
- The hibernate-maven-plugin automatically skips its execution, when - maven.test.skip is set to true. If you need it to be always - executed, you can configure that explicitly like this: -
- --<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate-maven-plugin</artifactId> - ... - <configuration> - <skip>false</skip> - </configuration> -</plugin>
- Background-information for this design-decission can be found on the extra - page To skip or not to skip: that is the question... -
-- If you do not want your dependencies to be scanned for hibernate annotations, - you can pass -Dhibernate.schema.scan.dependencies=none to maven - or set scanDependencies to none in the configuration - of the plugin like this: -
- --<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate-maven-plugin</artifactId> - ... - <configuration> - <scanDependencies>none</scanDependencies> - </configuration> -</plugin>
- If you are working under Windows and get the error-message - No annotated classes found in directory C:\projects\X Y Z\path-to-project\target\classes, - but you are really sure, that there are annotated classes in that - directory, you are expiriencing a bug, in the scannotation-library, that - was closed in version 1.1.0 of the hibernate-maven-plugin. -
- -- - You should consider to upgrade to the latest version of the plugin. - -
-- If you specify two goals, for example drop and - create, each goal has to be specified in its own - execution, so that you can specify two different - output-files for the two goals. - Otherwise, both goals will use the same output-file and the goal, that - is run second, will always skip, becaus it will find, that the output - file already exists and conclude, that its work was already done in a - prior run. -
- -- Example configuration for two goals: -
- --<executions> - <execution> - <id>Create Drop-Schema</id> - <phase>test-compile</phase> - <goals> - <goal>drop</goal> - </goals> - <configuration> - <outputFile>db-schema/drop-schema.ddl</outputFile> - </configuration> - </execution> - <execution> - <id>Create Create-Schema</id> - <phase>test-compile</phase> - <goals> - <goal>create</goal> - </goals> - <configuration> - <outputFile>db-schema/create-schema.ddl</outputFile> - </configuration> - </execution> -</executions>
-
-
- -Goals available for this plugin:
-Goal | -Description |
---|---|
hibernate:create | -Generate/Execute SQL to create a database-schema that represents -the configured mappings. |
hibernate:drop | -Generate/Execute SQL to drop all tables of a database-schema that -represents the configured mappings. |
hibernate:help | -Display help information on hibernate-maven-plugin. -Call mvn hibernate:help -Ddetail=true
--Dgoal=<goal-name> to display parameter details. |
hibernate:update | -Generate/Execute SQL to update the database-schema according to the -configured mappings. |
The following specifies the minimum requirements to run this Maven plugin:
-Maven | -2.0.6 |
JDK | -1.6 |
Memory | -No minimum requirement. |
Disk Space | -No minimum requirement. |
You should specify the version in your project's plugin configuration:
-<project> - ... - <build> - <!-- To define the plugin version in your parent POM --> - <pluginManagement> - <plugins> - <plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate-maven-plugin</artifactId> - <version>2.1.0</version> - </plugin> - ... - </plugins> - </pluginManagement> - <!-- To use the plugin goals in your POM or parent POM --> - <plugins> - <plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate-maven-plugin</artifactId> - <version>2.1.0</version> - </plugin> - ... - </plugins> - </build> - ... -</project> -
For more information, see "Guide to Configuring Plug-ins"
-
-
- -GroupId | -ArtifactId | -Version |
---|---|---|
org.apache.maven.plugins | -maven-antrun-plugin | -1.7 |
org.apache.maven.plugins | -maven-assembly-plugin | -2.4.1 |
org.apache.maven.plugins | -maven-dependency-plugin | -2.8 |
org.apache.maven.plugins | -maven-release-plugin | -2.1 |
org.apache.maven.plugins | -maven-site-plugin | -3.5.1 |
-
-
- -GroupId | -ArtifactId | -Version |
---|---|---|
org.apache.maven.plugins | -maven-clean-plugin | -2.5 |
org.apache.maven.plugins | -maven-compiler-plugin | -3.3 |
org.apache.maven.plugins | -maven-dependency-plugin | -2.10 |
org.apache.maven.plugins | -maven-deploy-plugin | -2.7 |
org.apache.maven.plugins | -maven-enforcer-plugin | -1.2 |
org.apache.maven.plugins | -maven-install-plugin | -2.5.2 |
org.apache.maven.plugins | -maven-invoker-plugin | -1.10 |
org.apache.maven.plugins | -maven-jar-plugin | -2.4 |
org.apache.maven.plugins | -maven-javadoc-plugin | -2.7 |
org.apache.maven.plugins | -maven-plugin-plugin | -3.4 |
org.apache.maven.plugins | -maven-resources-plugin | -2.7 |
org.apache.maven.plugins | -maven-scm-plugin | -1.9.4 |
org.apache.maven.plugins | -maven-site-plugin | -3.5.1 |
org.apache.maven.plugins | -maven-source-plugin | -2.1.2 |
org.apache.maven.plugins | -maven-surefire-plugin | -2.17 |
GroupId | -ArtifactId | -Version |
---|---|---|
org.apache.maven.plugins | -maven-changes-plugin | -2.11 |
org.apache.maven.plugins | -maven-javadoc-plugin | -2.7 |
org.apache.maven.plugins | -maven-jxr-plugin | -2.5 |
org.apache.maven.plugins | -maven-plugin-plugin | -3.4 |
org.apache.maven.plugins | -maven-pmd-plugin | -3.4 |
-
-
- -The following document contains the results of PMD 5.2.3.
Violation | -Line |
---|---|
Too many static imports may lead to messy code | -1–1420 |
Violation | -Line |
---|---|
Unnecessary use of fully qualified name 'java.security.MessageDigest.getInstance' due to existing import 'java.security.MessageDigest' | -60 |
Violation | -Line |
---|---|
Too many static imports may lead to messy code | -1–232 |
Avoid unused imports such as 'org.eclipse.aether.repository.AuthenticationContext.PASSWORD' | -13 |
Avoid unused imports such as 'org.eclipse.aether.repository.AuthenticationContext.USERNAME' | -14 |
Avoid unused imports such as 'org.hibernate.jpa.AvailableSettings.JDBC_DRIVER' | -21 |
Avoid unused imports such as 'org.hibernate.jpa.AvailableSettings.JDBC_PASSWORD' | -22 |
Avoid unused imports such as 'org.hibernate.jpa.AvailableSettings.JDBC_URL' | -23 |
Avoid unused imports such as 'org.hibernate.jpa.AvailableSettings.JDBC_USER' | -24 |
Unnecessary use of fully qualified name 'java.sql.Driver' due to existing import 'java.sql.Driver' | -151 |
Unnecessary use of fully qualified name 'java.sql.Connection' due to existing import 'java.sql.Connection' | -163 |
Unnecessary use of fully qualified name 'java.util.Properties' due to existing import 'java.util.Properties' | -165 |
-
-
- -This document provides an overview of the various documents and links that are part of this project's general information. All of this content is automatically generated by Maven on behalf of the project.
-Document | -Description |
---|---|
CI Management | -This is a link to the definitions of all continuous integration processes that builds and tests code on a frequent, regular basis. |
Dependencies | -This document lists the project's dependencies and provides information on each dependency. |
Dependency Information | -This document describes how to to include this project as a dependency using various dependency management tools. |
Distribution Management | -This document provides informations on the distribution management of this project. |
About | -A simple plugin for generating a database-schema from Hibernate-Mappings |
Licenses | -This document lists the project license(s). |
Plugin Management | -This document lists the plugins that are defined through pluginManagement. |
Plugins | -This document lists the build plugins and the report plugins used by this project. |
Team | -This document provides information on the members of this project. These are the individuals who have contributed to the project in one form or another. |
Source Code Management | -This document lists ways to access the online source repository. |
Summary | -This document lists other related information of this project |
-
-
- -This document provides an overview of the various reports that are automatically generated by Maven . Each report is briefly described below.
-Document | -Description |
---|---|
Test JavaDocs | -Test JavaDoc API documentation. |
JavaDocs | -JavaDoc API documentation. |
Source Xref | -HTML based, cross-reference version of Java source code. |
Test Source Xref | -HTML based, cross-reference version of Java test source code. |
CPD | -Duplicate code detection. |
PMD | -Verification of coding rules. |
Plugin Documentation | -This report provides goals and parameters documentation of a plugin. |
-
-
- -Field | -Value |
---|---|
Name | -Hibernate Maven Plugin |
Description | -A simple plugin for generating a database-schema from Hibernate-Mappings |
Homepage | -http://juplo.de/hibernate-maven-plugin/index.html |
-
-
- -- In most use-cases, the hibernate-maven-plugin is used to create a - test-database automatically. In this use-cases, it is very likely, that it - will result in mistakes/errors, if the goal is executed, when the tests - are skipped. - For example, one might manually overwrite the database-url with the url of - the production-database, in order to run other tests, like starting a - local webserver with the - jetty-maven-plugin. - If the drop-goal would be executed in such a scenario, it might erase the - hole production-database, which is not very desireable. -
- -- Because of this, the configuration-parameter skip defaults to the value - of the proptery maven.test.skip. This way, the execution of the - hibernate-maven-plugin is skipped automatically, when the tests are - skipped. Think of it as a build-in security-belt. -
- -- If you do not like that, because you need the plugin to always, - even if the tests are skipped you can configure that explicitly, - by setting the configuration-parameter skip to false: -
- --<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate-maven-plugin</artifactId> - ... - <configuration> - <skip>false</skip> - </configuration> -</plugin>
- Or, if you want the plugin to be executed by default and to be skipped - if you say so, you can bind the value of the configuration-parameter - skip to a custom property. For example: -
- --<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate-maven-plugin</artifactId> - ... - <configuration> - <skip>${foo.bar}</skip> - </configuration> -</plugin>
- This way, the plugin would be skipped, if you set the property - foo.bar to true. For example, if you specify -Dfoo.bar=true - on the command-line. -
- - --
-
- -This project uses Git to manage its source code. Instructions on Git use can be found at http://git-scm.com/documentation.
The source can be checked out anonymously from Git with this command (See http://git-scm.com/docs/git-clone):
-$ git clone http://juplo.de/git/hibernate-maven-plugin
Only project developers can access the Git tree via this method (See http://git-scm.com/docs/git-clone).
-$ git clone ssh://juplo.de/var/lib/git/juplo/hibernate-maven-plugin
-
-
- -A successful project requires many people to play many roles. Some members write code or documentation, while others are valuable as testers, submitting patches and suggestions.
-The project team is comprised of Members and Contributors. Members have direct access to the source of a project and actively evolve the code-base. Contributors improve the project through submission of patches and suggestions to the Members. The number of Contributors to the project is unbounded. Get involved today. All contributions to the project are greatly appreciated.
-The following is a list of developers with commit privileges that have directly contributed to the project in one way or another.
-Image | -Id | -Name | -|
---|---|---|---|
- | kai | -Kai Moritz | -kai@juplo.de |
The following additional people have contributed to this project through the way of suggestions, patches or documentation.
-Image | -Name | -|
---|---|---|
- | Adriano Machado | -adriano.m.machado@hotmail.com |
- | Lorenzo Nicora | -lorenzo.nicora@nicus.it |
- | Eduard Szente | -eduard.szente@gmail.com |
- | Stephen Johnson | -stejohns@redhat.com |
- | Victor Tatai | -vtatai@gmail.com |
- | Erik-Berndt Scheper | -erik.berndt.scheper@gmail.com |
- | Guido Wimmel | -Wimmel.Guido@swm.de |
- | Joel Johnson | -mrjoel@lixil.net |
- | Paul K. Moore | -paulkmoore@gmail.com |
- | Mark Robinson | -mark@mrobinson.ca |
- | Claus Graf | -clausgraf@gmail.com |
- | Joachim Van der Auwera | -joachim@progs.be |
- | Andreas Kuhtz | -andreas.kuhtz@gmail.com |
- | Heer Fabio | -fabio.heer@dvbern.ch |
-
Copyright © 2017. All Rights Reserved.
- - diff --git a/dist/hibernate-maven-plugin-2.1.0/testapidocs/de/juplo/test/FileComparator.html b/dist/hibernate-maven-plugin-2.1.0/testapidocs/de/juplo/test/FileComparator.html deleted file mode 100644 index 3d214b4b..00000000 --- a/dist/hibernate-maven-plugin-2.1.0/testapidocs/de/juplo/test/FileComparator.html +++ /dev/null @@ -1,280 +0,0 @@ - - - - - - -public class FileComparator -extends Object-
Constructor and Description | -
---|
FileComparator(File basedir) |
-
Modifier and Type | -Method and Description | -
---|---|
boolean |
-isEqual(String expectedFile,
- String foundFile) |
-
public boolean isEqual(String expectedFile, - String foundFile) - throws FileNotFoundException, - IOException-
FileNotFoundException
IOException
Copyright © 2017. All Rights Reserved.
- - diff --git a/dist/hibernate-maven-plugin-2.1.0/testapidocs/de/juplo/test/class-use/FileComparator.html b/dist/hibernate-maven-plugin-2.1.0/testapidocs/de/juplo/test/class-use/FileComparator.html deleted file mode 100644 index 5ae41924..00000000 --- a/dist/hibernate-maven-plugin-2.1.0/testapidocs/de/juplo/test/class-use/FileComparator.html +++ /dev/null @@ -1,124 +0,0 @@ - - - - - - -Copyright © 2017. All Rights Reserved.
- - diff --git a/dist/hibernate-maven-plugin-2.1.0/testapidocs/de/juplo/test/package-frame.html b/dist/hibernate-maven-plugin-2.1.0/testapidocs/de/juplo/test/package-frame.html deleted file mode 100644 index 490e27ab..00000000 --- a/dist/hibernate-maven-plugin-2.1.0/testapidocs/de/juplo/test/package-frame.html +++ /dev/null @@ -1,21 +0,0 @@ - - - - - - -Class | -Description | -
---|---|
FileComparator | -- |
Copyright © 2017. All Rights Reserved.
- - diff --git a/dist/hibernate-maven-plugin-2.1.0/testapidocs/de/juplo/test/package-tree.html b/dist/hibernate-maven-plugin-2.1.0/testapidocs/de/juplo/test/package-tree.html deleted file mode 100644 index 590032d7..00000000 --- a/dist/hibernate-maven-plugin-2.1.0/testapidocs/de/juplo/test/package-tree.html +++ /dev/null @@ -1,133 +0,0 @@ - - - - - - -Copyright © 2017. All Rights Reserved.
- - diff --git a/dist/hibernate-maven-plugin-2.1.0/testapidocs/de/juplo/test/package-use.html b/dist/hibernate-maven-plugin-2.1.0/testapidocs/de/juplo/test/package-use.html deleted file mode 100644 index 8e1031f9..00000000 --- a/dist/hibernate-maven-plugin-2.1.0/testapidocs/de/juplo/test/package-use.html +++ /dev/null @@ -1,124 +0,0 @@ - - - - - - -Copyright © 2017. All Rights Reserved.
- - diff --git a/dist/hibernate-maven-plugin-2.1.0/testapidocs/deprecated-list.html b/dist/hibernate-maven-plugin-2.1.0/testapidocs/deprecated-list.html deleted file mode 100644 index 8bfbdb19..00000000 --- a/dist/hibernate-maven-plugin-2.1.0/testapidocs/deprecated-list.html +++ /dev/null @@ -1,124 +0,0 @@ - - - - - - -Copyright © 2017. All Rights Reserved.
- - diff --git a/dist/hibernate-maven-plugin-2.1.0/testapidocs/help-doc.html b/dist/hibernate-maven-plugin-2.1.0/testapidocs/help-doc.html deleted file mode 100644 index 9932ae93..00000000 --- a/dist/hibernate-maven-plugin-2.1.0/testapidocs/help-doc.html +++ /dev/null @@ -1,225 +0,0 @@ - - - - - - -Each package has a page that contains a list of its classes and interfaces, with a summary for each. This page can contain six categories:
-Each class, interface, nested class and nested interface has its own separate page. Each of these pages has three sections consisting of a class/interface description, summary tables, and detailed member descriptions:
-Each summary entry contains the first sentence from the detailed description for that item. The summary entries are alphabetical, while the detailed descriptions are in the order they appear in the source code. This preserves the logical groupings established by the programmer.
-Each annotation type has its own separate page with the following sections:
-Each enum has its own separate page with the following sections:
-Each documented package, class and interface has its own Use page. This page describes what packages, classes, methods, constructors and fields use any part of the given class or package. Given a class or interface A, its Use page includes subclasses of A, fields declared as A, methods that return A, and methods and constructors with parameters of type A. You can access this page by first going to the package, class or interface, then clicking on the "Use" link in the navigation bar.
-There is a Class Hierarchy page for all packages, plus a hierarchy for each package. Each hierarchy page contains a list of classes and a list of interfaces. The classes are organized by inheritance structure starting with java.lang.Object
. The interfaces do not inherit from java.lang.Object
.
The Deprecated API page lists all of the API that have been deprecated. A deprecated API is not recommended for use, generally due to improvements, and a replacement API is usually given. Deprecated APIs may be removed in future implementations.
-The Index contains an alphabetic list of all classes, interfaces, constructors, methods, and fields.
-These links take you to the next or previous class, interface, package, or related page.
-These links show and hide the HTML frames. All pages are available with or without frames.
-The All Classes link shows all classes and interfaces except non-static nested types.
-Each serializable or externalizable class has a description of its serialization fields and methods. This information is of interest to re-implementors, not to developers using the API. While there is no link in the navigation bar, you can get to this information by going to any serialized class and clicking "Serialized Form" in the "See also" section of the class description.
-The Constant Field Values page lists the static final fields and their values.
-Copyright © 2017. All Rights Reserved.
- - diff --git a/dist/hibernate-maven-plugin-2.1.0/testapidocs/index-all.html b/dist/hibernate-maven-plugin-2.1.0/testapidocs/index-all.html deleted file mode 100644 index 814dca73..00000000 --- a/dist/hibernate-maven-plugin-2.1.0/testapidocs/index-all.html +++ /dev/null @@ -1,147 +0,0 @@ - - - - - - -Copyright © 2017. All Rights Reserved.
- - diff --git a/dist/hibernate-maven-plugin-2.1.0/testapidocs/index.html b/dist/hibernate-maven-plugin-2.1.0/testapidocs/index.html deleted file mode 100644 index a4395614..00000000 --- a/dist/hibernate-maven-plugin-2.1.0/testapidocs/index.html +++ /dev/null @@ -1,73 +0,0 @@ - - - - - - -This document is designed to be viewed using the frames feature. If you see this message, you are using a non-frame-capable web client. Link to Non-frame version.
-Copyright © 2017. All Rights Reserved.
- - diff --git a/dist/hibernate-maven-plugin-2.1.0/testapidocs/package-list b/dist/hibernate-maven-plugin-2.1.0/testapidocs/package-list deleted file mode 100644 index 4774195e..00000000 --- a/dist/hibernate-maven-plugin-2.1.0/testapidocs/package-list +++ /dev/null @@ -1 +0,0 @@ -de.juplo.test diff --git a/dist/hibernate-maven-plugin-2.1.0/testapidocs/script.js b/dist/hibernate-maven-plugin-2.1.0/testapidocs/script.js deleted file mode 100644 index b3463569..00000000 --- a/dist/hibernate-maven-plugin-2.1.0/testapidocs/script.js +++ /dev/null @@ -1,30 +0,0 @@ -function show(type) -{ - count = 0; - for (var key in methods) { - var row = document.getElementById(key); - if ((methods[key] & type) != 0) { - row.style.display = ''; - row.className = (count++ % 2) ? rowColor : altColor; - } - else - row.style.display = 'none'; - } - updateTabs(type); -} - -function updateTabs(type) -{ - for (var value in tabs) { - var sNode = document.getElementById(tabs[value][0]); - var spanNode = sNode.firstChild; - if (value == type) { - sNode.className = activeTableTab; - spanNode.innerHTML = tabs[value][1]; - } - else { - sNode.className = tableTab; - spanNode.innerHTML = "" + tabs[value][1] + ""; - } - } -} diff --git a/dist/hibernate-maven-plugin-2.1.0/testapidocs/stylesheet.css b/dist/hibernate-maven-plugin-2.1.0/testapidocs/stylesheet.css deleted file mode 100644 index 98055b22..00000000 --- a/dist/hibernate-maven-plugin-2.1.0/testapidocs/stylesheet.css +++ /dev/null @@ -1,574 +0,0 @@ -/* Javadoc style sheet */ -/* -Overall document style -*/ - -@import url('resources/fonts/dejavu.css'); - -body { - background-color:#ffffff; - color:#353833; - font-family:'DejaVu Sans', Arial, Helvetica, sans-serif; - font-size:14px; - margin:0; -} -a:link, a:visited { - text-decoration:none; - color:#4A6782; -} -a:hover, a:focus { - text-decoration:none; - color:#bb7a2a; -} -a:active { - text-decoration:none; - color:#4A6782; -} -a[name] { - color:#353833; -} -a[name]:hover { - text-decoration:none; - color:#353833; -} -pre { - font-family:'DejaVu Sans Mono', monospace; - font-size:14px; -} -h1 { - font-size:20px; -} -h2 { - font-size:18px; -} -h3 { - font-size:16px; - font-style:italic; -} -h4 { - font-size:13px; -} -h5 { - font-size:12px; -} -h6 { - font-size:11px; -} -ul { - list-style-type:disc; -} -code, tt { - font-family:'DejaVu Sans Mono', monospace; - font-size:14px; - padding-top:4px; - margin-top:8px; - line-height:1.4em; -} -dt code { - font-family:'DejaVu Sans Mono', monospace; - font-size:14px; - padding-top:4px; -} -table tr td dt code { - font-family:'DejaVu Sans Mono', monospace; - font-size:14px; - vertical-align:top; - padding-top:4px; -} -sup { - font-size:8px; -} -/* -Document title and Copyright styles -*/ -.clear { - clear:both; - height:0px; - overflow:hidden; -} -.aboutLanguage { - float:right; - padding:0px 21px; - font-size:11px; - z-index:200; - margin-top:-9px; -} -.legalCopy { - margin-left:.5em; -} -.bar a, .bar a:link, .bar a:visited, .bar a:active { - color:#FFFFFF; - text-decoration:none; -} -.bar a:hover, .bar a:focus { - color:#bb7a2a; -} -.tab { - background-color:#0066FF; - color:#ffffff; - padding:8px; - width:5em; - font-weight:bold; -} -/* -Navigation bar styles -*/ -.bar { - background-color:#4D7A97; - color:#FFFFFF; - padding:.8em .5em .4em .8em; - height:auto;/*height:1.8em;*/ - font-size:11px; - margin:0; -} -.topNav { - background-color:#4D7A97; - color:#FFFFFF; - float:left; - padding:0; - width:100%; - clear:right; - height:2.8em; - padding-top:10px; - overflow:hidden; - font-size:12px; -} -.bottomNav { - margin-top:10px; - background-color:#4D7A97; - color:#FFFFFF; - float:left; - padding:0; - width:100%; - clear:right; - height:2.8em; - padding-top:10px; - overflow:hidden; - font-size:12px; -} -.subNav { - background-color:#dee3e9; - float:left; - width:100%; - overflow:hidden; - font-size:12px; -} -.subNav div { - clear:left; - float:left; - padding:0 0 5px 6px; - text-transform:uppercase; -} -ul.navList, ul.subNavList { - float:left; - margin:0 25px 0 0; - padding:0; -} -ul.navList li{ - list-style:none; - float:left; - padding: 5px 6px; - text-transform:uppercase; -} -ul.subNavList li{ - list-style:none; - float:left; -} -.topNav a:link, .topNav a:active, .topNav a:visited, .bottomNav a:link, .bottomNav a:active, .bottomNav a:visited { - color:#FFFFFF; - text-decoration:none; - text-transform:uppercase; -} -.topNav a:hover, .bottomNav a:hover { - text-decoration:none; - color:#bb7a2a; - text-transform:uppercase; -} -.navBarCell1Rev { - background-color:#F8981D; - color:#253441; - margin: auto 5px; -} -.skipNav { - position:absolute; - top:auto; - left:-9999px; - overflow:hidden; -} -/* -Page header and footer styles -*/ -.header, .footer { - clear:both; - margin:0 20px; - padding:5px 0 0 0; -} -.indexHeader { - margin:10px; - position:relative; -} -.indexHeader span{ - margin-right:15px; -} -.indexHeader h1 { - font-size:13px; -} -.title { - color:#2c4557; - margin:10px 0; -} -.subTitle { - margin:5px 0 0 0; -} -.header ul { - margin:0 0 15px 0; - padding:0; -} -.footer ul { - margin:20px 0 5px 0; -} -.header ul li, .footer ul li { - list-style:none; - font-size:13px; -} -/* -Heading styles -*/ -div.details ul.blockList ul.blockList ul.blockList li.blockList h4, div.details ul.blockList ul.blockList ul.blockListLast li.blockList h4 { - background-color:#dee3e9; - border:1px solid #d0d9e0; - margin:0 0 6px -8px; - padding:7px 5px; -} -ul.blockList ul.blockList ul.blockList li.blockList h3 { - background-color:#dee3e9; - border:1px solid #d0d9e0; - margin:0 0 6px -8px; - padding:7px 5px; -} -ul.blockList ul.blockList li.blockList h3 { - padding:0; - margin:15px 0; -} -ul.blockList li.blockList h2 { - padding:0px 0 20px 0; -} -/* -Page layout container styles -*/ -.contentContainer, .sourceContainer, .classUseContainer, .serializedFormContainer, .constantValuesContainer { - clear:both; - padding:10px 20px; - position:relative; -} -.indexContainer { - margin:10px; - position:relative; - font-size:12px; -} -.indexContainer h2 { - font-size:13px; - padding:0 0 3px 0; -} -.indexContainer ul { - margin:0; - padding:0; -} -.indexContainer ul li { - list-style:none; - padding-top:2px; -} -.contentContainer .description dl dt, .contentContainer .details dl dt, .serializedFormContainer dl dt { - font-size:12px; - font-weight:bold; - margin:10px 0 0 0; - color:#4E4E4E; -} -.contentContainer .description dl dd, .contentContainer .details dl dd, .serializedFormContainer dl dd { - margin:5px 0 10px 0px; - font-size:14px; - font-family:'DejaVu Sans Mono',monospace; -} -.serializedFormContainer dl.nameValue dt { - margin-left:1px; - font-size:1.1em; - display:inline; - font-weight:bold; -} -.serializedFormContainer dl.nameValue dd { - margin:0 0 0 1px; - font-size:1.1em; - display:inline; -} -/* -List styles -*/ -ul.horizontal li { - display:inline; - font-size:0.9em; -} -ul.inheritance { - margin:0; - padding:0; -} -ul.inheritance li { - display:inline; - list-style:none; -} -ul.inheritance li ul.inheritance { - margin-left:15px; - padding-left:15px; - padding-top:1px; -} -ul.blockList, ul.blockListLast { - margin:10px 0 10px 0; - padding:0; -} -ul.blockList li.blockList, ul.blockListLast li.blockList { - list-style:none; - margin-bottom:15px; - line-height:1.4; -} -ul.blockList ul.blockList li.blockList, ul.blockList ul.blockListLast li.blockList { - padding:0px 20px 5px 10px; - border:1px solid #ededed; - background-color:#f8f8f8; -} -ul.blockList ul.blockList ul.blockList li.blockList, ul.blockList ul.blockList ul.blockListLast li.blockList { - padding:0 0 5px 8px; - background-color:#ffffff; - border:none; -} -ul.blockList ul.blockList ul.blockList ul.blockList li.blockList { - margin-left:0; - padding-left:0; - padding-bottom:15px; - border:none; -} -ul.blockList ul.blockList ul.blockList ul.blockList li.blockListLast { - list-style:none; - border-bottom:none; - padding-bottom:0; -} -table tr td dl, table tr td dl dt, table tr td dl dd { - margin-top:0; - margin-bottom:1px; -} -/* -Table styles -*/ -.overviewSummary, .memberSummary, .typeSummary, .useSummary, .constantsSummary, .deprecatedSummary { - width:100%; - border-left:1px solid #EEE; - border-right:1px solid #EEE; - border-bottom:1px solid #EEE; -} -.overviewSummary, .memberSummary { - padding:0px; -} -.overviewSummary caption, .memberSummary caption, .typeSummary caption, -.useSummary caption, .constantsSummary caption, .deprecatedSummary caption { - position:relative; - text-align:left; - background-repeat:no-repeat; - color:#253441; - font-weight:bold; - clear:none; - overflow:hidden; - padding:0px; - padding-top:10px; - padding-left:1px; - margin:0px; - white-space:pre; -} -.overviewSummary caption a:link, .memberSummary caption a:link, .typeSummary caption a:link, -.useSummary caption a:link, .constantsSummary caption a:link, .deprecatedSummary caption a:link, -.overviewSummary caption a:hover, .memberSummary caption a:hover, .typeSummary caption a:hover, -.useSummary caption a:hover, .constantsSummary caption a:hover, .deprecatedSummary caption a:hover, -.overviewSummary caption a:active, .memberSummary caption a:active, .typeSummary caption a:active, -.useSummary caption a:active, .constantsSummary caption a:active, .deprecatedSummary caption a:active, -.overviewSummary caption a:visited, .memberSummary caption a:visited, .typeSummary caption a:visited, -.useSummary caption a:visited, .constantsSummary caption a:visited, .deprecatedSummary caption a:visited { - color:#FFFFFF; -} -.overviewSummary caption span, .memberSummary caption span, .typeSummary caption span, -.useSummary caption span, .constantsSummary caption span, .deprecatedSummary caption span { - white-space:nowrap; - padding-top:5px; - padding-left:12px; - padding-right:12px; - padding-bottom:7px; - display:inline-block; - float:left; - background-color:#F8981D; - border: none; - height:16px; -} -.memberSummary caption span.activeTableTab span { - white-space:nowrap; - padding-top:5px; - padding-left:12px; - padding-right:12px; - margin-right:3px; - display:inline-block; - float:left; - background-color:#F8981D; - height:16px; -} -.memberSummary caption span.tableTab span { - white-space:nowrap; - padding-top:5px; - padding-left:12px; - padding-right:12px; - margin-right:3px; - display:inline-block; - float:left; - background-color:#4D7A97; - height:16px; -} -.memberSummary caption span.tableTab, .memberSummary caption span.activeTableTab { - padding-top:0px; - padding-left:0px; - padding-right:0px; - background-image:none; - float:none; - display:inline; -} -.overviewSummary .tabEnd, .memberSummary .tabEnd, .typeSummary .tabEnd, -.useSummary .tabEnd, .constantsSummary .tabEnd, .deprecatedSummary .tabEnd { - display:none; - width:5px; - position:relative; - float:left; - background-color:#F8981D; -} -.memberSummary .activeTableTab .tabEnd { - display:none; - width:5px; - margin-right:3px; - position:relative; - float:left; - background-color:#F8981D; -} -.memberSummary .tableTab .tabEnd { - display:none; - width:5px; - margin-right:3px; - position:relative; - background-color:#4D7A97; - float:left; - -} -.overviewSummary td, .memberSummary td, .typeSummary td, -.useSummary td, .constantsSummary td, .deprecatedSummary td { - text-align:left; - padding:0px 0px 12px 10px; -} -th.colOne, th.colFirst, th.colLast, .useSummary th, .constantsSummary th, -td.colOne, td.colFirst, td.colLast, .useSummary td, .constantsSummary td{ - vertical-align:top; - padding-right:0px; - padding-top:8px; - padding-bottom:3px; -} -th.colFirst, th.colLast, th.colOne, .constantsSummary th { - background:#dee3e9; - text-align:left; - padding:8px 3px 3px 7px; -} -td.colFirst, th.colFirst { - white-space:nowrap; - font-size:13px; -} -td.colLast, th.colLast { - font-size:13px; -} -td.colOne, th.colOne { - font-size:13px; -} -.overviewSummary td.colFirst, .overviewSummary th.colFirst, -.useSummary td.colFirst, .useSummary th.colFirst, -.overviewSummary td.colOne, .overviewSummary th.colOne, -.memberSummary td.colFirst, .memberSummary th.colFirst, -.memberSummary td.colOne, .memberSummary th.colOne, -.typeSummary td.colFirst{ - width:25%; - vertical-align:top; -} -td.colOne a:link, td.colOne a:active, td.colOne a:visited, td.colOne a:hover, td.colFirst a:link, td.colFirst a:active, td.colFirst a:visited, td.colFirst a:hover, td.colLast a:link, td.colLast a:active, td.colLast a:visited, td.colLast a:hover, .constantValuesContainer td a:link, .constantValuesContainer td a:active, .constantValuesContainer td a:visited, .constantValuesContainer td a:hover { - font-weight:bold; -} -.tableSubHeadingColor { - background-color:#EEEEFF; -} -.altColor { - background-color:#FFFFFF; -} -.rowColor { - background-color:#EEEEEF; -} -/* -Content styles -*/ -.description pre { - margin-top:0; -} -.deprecatedContent { - margin:0; - padding:10px 0; -} -.docSummary { - padding:0; -} - -ul.blockList ul.blockList ul.blockList li.blockList h3 { - font-style:normal; -} - -div.block { - font-size:14px; - font-family:'DejaVu Serif', Georgia, "Times New Roman", Times, serif; -} - -td.colLast div { - padding-top:0px; -} - - -td.colLast a { - padding-bottom:3px; -} -/* -Formatting effect styles -*/ -.sourceLineNo { - color:green; - padding:0 30px 0 0; -} -h1.hidden { - visibility:hidden; - overflow:hidden; - font-size:10px; -} -.block { - display:block; - margin:3px 10px 2px 0px; - color:#474747; -} -.deprecatedLabel, .descfrmTypeLabel, .memberNameLabel, .memberNameLink, -.overrideSpecifyLabel, .packageHierarchyLabel, .paramLabel, .returnLabel, -.seeLabel, .simpleTagLabel, .throwsLabel, .typeNameLabel, .typeNameLink { - font-weight:bold; -} -.deprecationComment, .emphasizedPhrase, .interfaceName { - font-style:italic; -} - -div.block div.block span.deprecationComment, div.block div.block span.emphasizedPhrase, -div.block div.block span.interfaceName { - font-style:normal; -} - -div.contentContainer ul.blockList li.blockList h2{ - padding-bottom:0px; -} diff --git a/dist/hibernate-maven-plugin-2.1.0/update-mojo.html b/dist/hibernate-maven-plugin-2.1.0/update-mojo.html deleted file mode 100644 index 29e383a6..00000000 --- a/dist/hibernate-maven-plugin-2.1.0/update-mojo.html +++ /dev/null @@ -1,1343 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - --
Full name:
- -de.juplo:hibernate-maven-plugin:2.1.0:update
- -Description:
- -Attributes:
- -Name | - -Type | - -Since | - -Description | -
---|---|---|---|
createNamespaces | - -Boolean | - -2.0 | - -Specifies whether to automatically create also the database
-schema/catalog. Default value is: false. User property is: hibernate.hbm2dll.create_namespaces. |
-
delimiter | - -String | - -1.0 | - -Delimiter in output-file.
-
- Important: This configuration value can only be -configured through the pom.xml, or by the definition -of a system-property, because it is not known by Hibernate nor JPA -and, hence, not picked up from their configuration! Default value is: ;. User property is: hibernate.hbm2ddl.delimiter. |
-
dialect | - -String | - -1.0 | - -Hibernate dialect. User property is: hibernate.dialect. |
-
driver | - -String | - -1.0 | - -SQL-Driver name. User property is: hibernate.connection.driver_class. |
-
execute | - -Boolean | - -2.0 | - -Excecute the generated SQL. If set to false, only the
-SQL-script is created and the database is not touched.
-
- Important: This configuration value can only be -configured through the pom.xml, or by the definition -of a system-property, because it is not known by Hibernate nor JPA -and, hence, not picked up from their configuration! Default value is: true. User property is: hibernate.schema.execute. |
-
force | - -boolean | - -1.0 | - -Force generation/execution
-
- Force the generation and (if configured) the execution of the -SQL, even if no modified or newly added annotated classes where -found and the configuration was not changed. - -skip takes precedence over force. - -Important: This configuration value can only be -configured through the pom.xml, or by the definition -of a system-property, because it is not known by Hibernate nor JPA -and, hence, not picked up from their configuration! Default value is: false. User property is: hibernate.schema.force. |
-
format | - -Boolean | - -1.0 | - -Format output-file. User property is: hibernate.format_sql. |
-
hibernateConfig | - -String | - -1.1.0 | - -Path to Hibernate configuration file (.cfg.xml). If this parameter
-is specified, the plugin will try to load configuration values from
-a file with the given path or a ressource on the classpath with the
-given name. If both fails, the execution of the plugin will fail.
-
- If this parameter is not set the plugin will load configuration -values from a ressource named hibernate.cfg.xml on the -classpath, if it is present, but will not fail if there is no such -ressource. - -During ressource-lookup, the test-classpath takes -precedence. - -Settings in this file will overwrite settings in the properties -file. |
-
hibernateProperties | - -String | - -1.0 | - -Path to a file or name of a ressource with hibernate properties. If
-this parameter is specified, the plugin will try to load
-configuration values from a file with the given path or a ressource
-on the classpath with the given name. If both fails, the execution
-of the plugin will fail.
-
- If this parameter is not set the plugin will load configuration -values from a ressource named hibernate.properties on -the classpath, if it is present, but will not fail if there is no -such ressource. - -During ressource-lookup, the test-classpath takes -precedence. |
-
implicitNamingStrategy | - -String | - -2.0 | - -Implicit naming strategy User property is: hibernate.implicit_naming_strategy. |
-
mappings | - -String | - -1.0.2 | - -List of Hibernate-Mapping-Files (XML). Multiple files can be
-separated with white-spaces and/or commas. User property is: hibernate.mapping. |
-
outputDirectory | - -String | - -1.0 | - -Classes-Directory to scan.
-
- This parameter defaults to the maven build-output-directory for -classes. Additionally, all dependencies are scanned for annotated -classes. - -Important: This configuration value can only be -configured through the pom.xml, or by the definition -of a system-property, because it is not known by Hibernate nor JPA -and, hence, not picked up from their configuration! User property is: project.build.outputDirectory. |
-
outputFile | - -String | - -1.0 | - -Output file.
-
- If the specified filename is not absolut, the file will be -created relative to the project build directory -(project.build.directory). Default value is: update.sql. User property is: hibernate.schema.update. |
-
password | - -String | - -1.0 | - -Database password User property is: hibernate.connection.password. |
-
persistenceUnit | - -String | - -1.1.0 | - -Name of the persistence-unit. If this parameter is specified, the
-plugin will try to load configuration values from a
-persistence-unit with the specified name. If no such
-persistence-unit can be found, the plugin will throw an exception.
-
- If this parameter is not set and there is only one -persistence-unit available, that unit will be used automatically. -But if this parameter is not set and there are multiple -persistence-units available on, the class-path, the execution of -the plugin will fail. - -Settings in this file will overwrite settings in the properties -or the configuration file. |
-
physicalNamingStrategy | - -String | - -2.0 | - -Physical naming strategy User property is: hibernate.physical_naming_strategy. |
-
scanClasses | - -Boolean | - -2.0 | - -Wether the project should be scanned for annotated-classes, or not
-
- This parameter is intended to allow overwriting of the parameter -exclude-unlisted-classes of a -persistence-unit. If not specified, it defaults to -true User property is: hibernate.schema.scan.classes. |
-
scanDependencies | - -String | - -1.0.3 | - -Dependency-Scopes, that should be scanned for annotated classes.
-
- By default, only dependencies in the scope compile -are scanned for annotated classes. Multiple scopes can be seperated -by white space or commas. - -If you do not want any dependencies to be scanned for annotated -classes, set this parameter to none. - -The plugin does not scan for annotated classes in transitive -dependencies. If some of your annotated classes are hidden in a -transitive dependency, you can simply add that dependency -explicitly. Default value is: compile. User property is: hibernate.schema.scan.dependencies. |
-
scanTestClasses | - -Boolean | - -1.0.1 | - -Whether to scan the test-branch of the project for annotated
-classes, or not.
-
- If this parameter is set to true the test-classes -of the artifact will be scanned for hibernate-annotated classes -additionally. - -Important: This configuration value can only be -configured through the pom.xml, or by the definition -of a system-property, because it is not known by Hibernate nor JPA -and, hence, not picked up from their configuration! Default value is: false. User property is: hibernate.schema.scan.test_classes. |
-
show | - -Boolean | - -1.0 | - -Show the generated SQL in the command-line output. User property is: hibernate.show_sql. |
-
skip | - -boolean | - -1.0 | - -Skip execution
-
- If set to true, the execution is skipped. - -A skipped execution is signaled via the maven-property -${hibernate.schema.skipped}. - -The execution is skipped automatically, if no modified or newly -added annotated classes are found and the dialect was not -changed. - -Important: This configuration value can only be -configured through the pom.xml, or by the definition -of a system-property, because it is not known by Hibernate nor JPA -and, hence, not picked up from their configuration! Default value is: ${maven.test.skip}. User property is: hibernate.schema.skip. |
-
testOutputDirectory | - -String | - -1.0.2 | - -Test-Classes-Directory to scan.
-
- This parameter defaults to the maven build-output-directory for -test-classes. - -This parameter is only used, when scanTestClasses -is set to true! - -Important: This configuration value can only be -configured through the pom.xml, or by the definition -of a system-property, because it is not known by Hibernate nor JPA -and, hence, not picked up from their configuration! User property is: project.build.testOutputDirectory. |
-
url | - -String | - -1.0 | - -Database URL. User property is: hibernate.connection.url. |
-
username | - -String | - -1.0 | - -Database username User property is: hibernate.connection.username. |
-
Important: This configuration value can only be -configured through the pom.xml, or by the definition -of a system-property, because it is not known by Hibernate nor JPA -and, hence, not picked up from their configuration!
Important: This configuration value can only be -configured through the pom.xml, or by the definition -of a system-property, because it is not known by Hibernate nor JPA -and, hence, not picked up from their configuration!
Force the generation and (if configured) the execution of the -SQL, even if no modified or newly added annotated classes where -found and the configuration was not changed.
- -skip takes precedence over force.
- -Important: This configuration value can only be -configured through the pom.xml, or by the definition -of a system-property, because it is not known by Hibernate nor JPA -and, hence, not picked up from their configuration!
If this parameter is not set the plugin will load configuration -values from a ressource named hibernate.cfg.xml on the -classpath, if it is present, but will not fail if there is no such -ressource.
- -During ressource-lookup, the test-classpath takes -precedence.
- -Settings in this file will overwrite settings in the properties -file.
If this parameter is not set the plugin will load configuration -values from a ressource named hibernate.properties on -the classpath, if it is present, but will not fail if there is no -such ressource.
- -During ressource-lookup, the test-classpath takes -precedence.
This parameter defaults to the maven build-output-directory for -classes. Additionally, all dependencies are scanned for annotated -classes.
- -Important: This configuration value can only be -configured through the pom.xml, or by the definition -of a system-property, because it is not known by Hibernate nor JPA -and, hence, not picked up from their configuration!
If the specified filename is not absolut, the file will be -created relative to the project build directory -(project.build.directory).
If this parameter is not set and there is only one -persistence-unit available, that unit will be used automatically. -But if this parameter is not set and there are multiple -persistence-units available on, the class-path, the execution of -the plugin will fail.
- -Settings in this file will overwrite settings in the properties -or the configuration file.
This parameter is intended to allow overwriting of the parameter -exclude-unlisted-classes of a -persistence-unit. If not specified, it defaults to -true
By default, only dependencies in the scope compile -are scanned for annotated classes. Multiple scopes can be seperated -by white space or commas.
- -If you do not want any dependencies to be scanned for annotated -classes, set this parameter to none.
- -The plugin does not scan for annotated classes in transitive -dependencies. If some of your annotated classes are hidden in a -transitive dependency, you can simply add that dependency -explicitly.
If this parameter is set to true the test-classes -of the artifact will be scanned for hibernate-annotated classes -additionally.
- -Important: This configuration value can only be -configured through the pom.xml, or by the definition -of a system-property, because it is not known by Hibernate nor JPA -and, hence, not picked up from their configuration!
show:
- -skip:
- -If set to true, the execution is skipped.
- -A skipped execution is signaled via the maven-property -${hibernate.schema.skipped}.
- -The execution is skipped automatically, if no modified or newly -added annotated classes are found and the dialect was not -changed.
- -Important: This configuration value can only be -configured through the pom.xml, or by the definition -of a system-property, because it is not known by Hibernate nor JPA -and, hence, not picked up from their configuration!
This parameter defaults to the maven build-output-directory for -test-classes.
- -This parameter is only used, when scanTestClasses -is set to true!
- -Important: This configuration value can only be -configured through the pom.xml, or by the definition -of a system-property, because it is not known by Hibernate nor JPA -and, hence, not picked up from their configuration!
url:
- --
-1 package de.juplo.test; -2 -3 import java.io.BufferedReader; -4 import java.io.File; -5 import java.io.FileNotFoundException; -6 import java.io.FileReader; -7 import java.io.IOException; -8 -9 -10 public class FileComparator -11 { -12 private final File basedir; -13 private BufferedReader expectedReader; -14 private BufferedReader foundReader; -15 -16 public FileComparator(File basedir) -17 { -18 this.basedir = basedir; -19 } -20 -21 public boolean isEqual(final String expectedFile, final String foundFile) -22 throws -23 FileNotFoundException, -24 IOException -25 { -26 File file; -27 String expected, found; -28 -29 file = new File(basedir, expectedFile); -30 expectedReader = new BufferedReader(new FileReader(file)); -31 -32 file = new File(basedir, foundFile); -33 foundReader = new BufferedReader(new FileReader(file)); -34 -35 -36 while ((expected = expectedReader.readLine()) != null) -37 { -38 found = foundReader.readLine(); -39 if (!expected.equals(found)) -40 { -41 System.err.println("Mismatch!"); -42 System.err.println("Expected: " + expected); -43 System.err.println("Found: " + found); -44 return false; -45 } -46 } -47 -48 if ((found = foundReader.readLine()) != null) -49 { -50 System.err.println("Found more content than expected!"); -51 System.err.println("Starting with: " + found); -52 return false; -53 } -54 -55 return true; -56 } -57 } --
Class Summary | -
---|
- FileComparator - | -
- You don't have frames. Go here -
- -Packages | -
---|
- de.juplo.test - | -
-1 package de.juplo.plugins.hibernate; -2 -3 -4 import com.pyx4j.log4j.MavenLogAppender; -5 import java.io.File; -6 import java.io.FileInputStream; -7 import java.io.FileOutputStream; -8 import java.io.IOException; -9 import java.io.InputStream; -10 import java.net.MalformedURLException; -11 import java.net.URL; -12 import java.security.NoSuchAlgorithmException; -13 import java.time.ZonedDateTime; -14 import java.util.Collections; -15 import java.util.EnumSet; -16 import java.util.HashMap; -17 import java.util.HashSet; -18 import java.util.Iterator; -19 import java.util.LinkedHashSet; -20 import java.util.List; -21 import java.util.Map; -22 import java.util.Map.Entry; -23 import java.util.Properties; -24 import java.util.Set; -25 import java.util.regex.Matcher; -26 import java.util.regex.Pattern; -27 import javax.persistence.Embeddable; -28 import javax.persistence.Entity; -29 import javax.persistence.MappedSuperclass; -30 import javax.persistence.spi.PersistenceUnitTransactionType; -31 import org.apache.maven.artifact.Artifact; -32 import org.apache.maven.model.Resource; -33 import org.apache.maven.plugin.AbstractMojo; -34 import org.apache.maven.plugin.MojoExecutionException; -35 import org.apache.maven.plugin.MojoFailureException; -36 import org.apache.maven.project.MavenProject; -37 import org.hibernate.boot.MetadataBuilder; -38 import org.hibernate.boot.MetadataSources; -39 import org.hibernate.boot.cfgxml.internal.ConfigLoader; -40 import org.hibernate.boot.cfgxml.spi.LoadedConfig; -41 import org.hibernate.boot.cfgxml.spi.MappingReference; -42 import org.hibernate.boot.model.naming.ImplicitNamingStrategy; -43 import org.hibernate.boot.model.naming.PhysicalNamingStrategy; -44 import org.hibernate.boot.registry.BootstrapServiceRegistry; -45 import org.hibernate.boot.registry.BootstrapServiceRegistryBuilder; -46 import org.hibernate.boot.registry.StandardServiceRegistry; -47 import org.hibernate.boot.registry.StandardServiceRegistryBuilder; -48 import org.hibernate.boot.registry.classloading.spi.ClassLoaderService; -49 import org.hibernate.boot.registry.classloading.spi.ClassLoadingException; -50 import org.hibernate.boot.registry.selector.spi.StrategySelector; -51 import org.hibernate.boot.spi.MetadataImplementor; -52 import org.hibernate.cfg.AvailableSettings; -53 import static org.hibernate.cfg.AvailableSettings.DIALECT; -54 import static org.hibernate.cfg.AvailableSettings.DRIVER; -55 import static org.hibernate.cfg.AvailableSettings.FORMAT_SQL; -56 import static org.hibernate.cfg.AvailableSettings.HBM2DDL_DELIMITER; -57 import static org.hibernate.cfg.AvailableSettings.HBM2DLL_CREATE_NAMESPACES; -58 import static org.hibernate.cfg.AvailableSettings.IMPLICIT_NAMING_STRATEGY; -59 import static org.hibernate.cfg.AvailableSettings.JPA_JDBC_DRIVER; -60 import static org.hibernate.cfg.AvailableSettings.JPA_JDBC_PASSWORD; -61 import static org.hibernate.cfg.AvailableSettings.JPA_JDBC_URL; -62 import static org.hibernate.cfg.AvailableSettings.JPA_JDBC_USER; -63 import static org.hibernate.cfg.AvailableSettings.PASS; -64 import static org.hibernate.cfg.AvailableSettings.PHYSICAL_NAMING_STRATEGY; -65 import static org.hibernate.cfg.AvailableSettings.SHOW_SQL; -66 import static org.hibernate.cfg.AvailableSettings.USER; -67 import static org.hibernate.cfg.AvailableSettings.URL; -68 import org.hibernate.engine.config.spi.ConfigurationService; -69 import org.hibernate.engine.jdbc.connections.spi.ConnectionProvider; -70 import org.hibernate.internal.util.config.ConfigurationException; -71 import org.hibernate.jpa.boot.internal.ParsedPersistenceXmlDescriptor; -72 import org.hibernate.jpa.boot.internal.PersistenceXmlParser; -73 import org.hibernate.tool.schema.TargetType; -74 import org.hibernate.tool.schema.internal.ExceptionHandlerCollectingImpl; -75 import org.hibernate.tool.schema.internal.exec.ScriptTargetOutputToFile; -76 import org.hibernate.tool.schema.spi.ExecutionOptions; -77 import org.hibernate.tool.schema.spi.SchemaManagementToolCoordinator; -78 import org.hibernate.tool.schema.spi.ScriptTargetOutput; -79 import org.hibernate.tool.schema.spi.TargetDescriptor; -80 import org.scannotation.AnnotationDB; -81 -82 -83 /** -84 * Baseclass with common attributes and methods. -85 * -86 * @phase process-classes -87 * @threadSafe -88 * @requiresDependencyResolution runtime -89 */ -90 public abstract class AbstractSchemaMojo extends AbstractMojo -91 { -92 public final static String EXECUTE = "hibernate.schema.execute"; -93 public final static String OUTPUTDIRECTORY = "project.build.outputDirectory"; -94 public final static String SCAN_CLASSES = "hibernate.schema.scan.classes"; -95 public final static String SCAN_DEPENDENCIES = "hibernate.schema.scan.dependencies"; -96 public final static String SCAN_TESTCLASSES = "hibernate.schema.scan.test_classes"; -97 public final static String TEST_OUTPUTDIRECTORY = "project.build.testOutputDirectory"; -98 public final static String SKIPPED = "hibernate.schema.skipped"; -99 public final static String SCRIPT = "hibernate.schema.script"; -100 -101 private final static Pattern SPLIT = Pattern.compile("[^,\\s]+"); -102 -103 private final Set<String> packages = new HashSet<String>(); -104 -105 -106 /** -107 * The maven project. -108 * <p> -109 * Only needed internally. -110 * -111 * @parameter property="project" -112 * @required -113 * @readonly -114 */ -115 private MavenProject project; -116 -117 /** -118 * Build-directory. -119 * <p> -120 * Only needed internally. -121 * -122 * @parameter property="project.build.directory" -123 * @required -124 * @readonly -125 */ -126 private String buildDirectory; -127 -128 -129 /** Parameters to configure the genaration of the SQL *********************/ -130 -131 /** -132 * Excecute the generated SQL. -133 * If set to <code>false</code>, only the SQL-script is created and the -134 * database is not touched. -135 * <p> -136 * <strong>Important:</strong> -137 * This configuration value can only be configured through the -138 * <code>pom.xml</code>, or by the definition of a system-property, because -139 * it is not known by Hibernate nor JPA and, hence, not picked up from -140 * their configuration! -141 * -142 * @parameter property="hibernate.schema.execute" default-value="true" -143 * @since 2.0 -144 */ -145 private Boolean execute; -146 -147 /** -148 * Skip execution -149 * <p> -150 * If set to <code>true</code>, the execution is skipped. -151 * <p> -152 * A skipped execution is signaled via the maven-property -153 * <code>${hibernate.schema.skipped}</code>. -154 * <p> -155 * The execution is skipped automatically, if no modified or newly added -156 * annotated classes are found and the dialect was not changed. -157 * <p> -158 * <strong>Important:</strong> -159 * This configuration value can only be configured through the -160 * <code>pom.xml</code>, or by the definition of a system-property, because -161 * it is not known by Hibernate nor JPA and, hence, not picked up from -162 * their configuration! -163 * -164 * @parameter property="hibernate.schema.skip" default-value="${maven.test.skip}" -165 * @since 1.0 -166 */ -167 private boolean skip; -168 -169 /** -170 * Force generation/execution -171 * <p> -172 * Force the generation and (if configured) the execution of the SQL, even if -173 * no modified or newly added annotated classes where found and the -174 * configuration was not changed. -175 * <p> -176 * <code>skip</code> takes precedence over <code>force</code>. -177 * <p> -178 * <strong>Important:</strong> -179 * This configuration value can only be configured through the -180 * <code>pom.xml</code>, or by the definition of a system-property, because -181 * it is not known by Hibernate nor JPA and, hence, not picked up from -182 * their configuration! -183 * -184 * @parameter property="hibernate.schema.force" default-value="false" -185 * @since 1.0 -186 */ -187 private boolean force; -188 -189 /** -190 * Hibernate dialect. -191 * -192 * @parameter property="hibernate.dialect" -193 * @since 1.0 -194 */ -195 private String dialect; -196 -197 /** -198 * Delimiter in output-file. -199 * <p> -200 * <strong>Important:</strong> -201 * This configuration value can only be configured through the -202 * <code>pom.xml</code>, or by the definition of a system-property, because -203 * it is not known by Hibernate nor JPA and, hence, not picked up from -204 * their configuration! -205 * -206 * @parameter property="hibernate.hbm2ddl.delimiter" default-value=";" -207 * @since 1.0 -208 */ -209 private String delimiter; -210 -211 /** -212 * Show the generated SQL in the command-line output. -213 * -214 * @parameter property="hibernate.show_sql" -215 * @since 1.0 -216 */ -217 private Boolean show; -218 -219 /** -220 * Format output-file. -221 * -222 * @parameter property="hibernate.format_sql" -223 * @since 1.0 -224 */ -225 private Boolean format; -226 -227 /** -228 * Specifies whether to automatically create also the database schema/catalog. -229 * -230 * @parameter property="hibernate.hbm2dll.create_namespaces" default-value="false" -231 * @since 2.0 -232 */ -233 private Boolean createNamespaces; -234 -235 /** -236 * Implicit naming strategy -237 * -238 * @parameter property="hibernate.implicit_naming_strategy" -239 * @since 2.0 -240 */ -241 private String implicitNamingStrategy; -242 -243 /** -244 * Physical naming strategy -245 * -246 * @parameter property="hibernate.physical_naming_strategy" -247 * @since 2.0 -248 */ -249 private String physicalNamingStrategy; -250 -251 /** -252 * Wether the project should be scanned for annotated-classes, or not -253 * <p> -254 * This parameter is intended to allow overwriting of the parameter -255 * <code>exclude-unlisted-classes</code> of a <code>persistence-unit</code>. -256 * If not specified, it defaults to <code>true</code> -257 * -258 * @parameter property="hibernate.schema.scan.classes" -259 * @since 2.0 -260 */ -261 private Boolean scanClasses; -262 -263 /** -264 * Classes-Directory to scan. -265 * <p> -266 * This parameter defaults to the maven build-output-directory for classes. -267 * Additionally, all dependencies are scanned for annotated classes. -268 * <p> -269 * <strong>Important:</strong> -270 * This configuration value can only be configured through the -271 * <code>pom.xml</code>, or by the definition of a system-property, because -272 * it is not known by Hibernate nor JPA and, hence, not picked up from -273 * their configuration! -274 * -275 * @parameter property="project.build.outputDirectory" -276 * @since 1.0 -277 */ -278 private String outputDirectory; -279 -280 /** -281 * Dependency-Scopes, that should be scanned for annotated classes. -282 * <p> -283 * By default, only dependencies in the scope <code>compile</code> are -284 * scanned for annotated classes. Multiple scopes can be seperated by -285 * white space or commas. -286 * <p> -287 * If you do not want any dependencies to be scanned for annotated -288 * classes, set this parameter to <code>none</code>. -289 * <p> -290 * The plugin does not scan for annotated classes in transitive -291 * dependencies. If some of your annotated classes are hidden in a -292 * transitive dependency, you can simply add that dependency explicitly. -293 * -294 * @parameter property="hibernate.schema.scan.dependencies" default-value="compile" -295 * @since 1.0.3 -296 */ -297 private String scanDependencies; -298 -299 /** -300 * Whether to scan the test-branch of the project for annotated classes, or -301 * not. -302 * <p> -303 * If this parameter is set to <code>true</code> the test-classes of the -304 * artifact will be scanned for hibernate-annotated classes additionally. -305 * <p> -306 * <strong>Important:</strong> -307 * This configuration value can only be configured through the -308 * <code>pom.xml</code>, or by the definition of a system-property, because -309 * it is not known by Hibernate nor JPA and, hence, not picked up from -310 * their configuration! -311 * -312 * @parameter property="hibernate.schema.scan.test_classes" default-value="false" -313 * @since 1.0.1 -314 */ -315 private Boolean scanTestClasses; -316 -317 /** -318 * Test-Classes-Directory to scan. -319 * <p> -320 * This parameter defaults to the maven build-output-directory for -321 * test-classes. -322 * <p> -323 * This parameter is only used, when <code>scanTestClasses</code> is set -324 * to <code>true</code>! -325 * <p> -326 * <strong>Important:</strong> -327 * This configuration value can only be configured through the -328 * <code>pom.xml</code>, or by the definition of a system-property, because -329 * it is not known by Hibernate nor JPA and, hence, not picked up from -330 * their configuration! -331 * -332 * @parameter property="project.build.testOutputDirectory" -333 * @since 1.0.2 -334 */ -335 private String testOutputDirectory; -336 -337 -338 /** Conection parameters *************************************************/ -339 -340 /** -341 * SQL-Driver name. -342 * -343 * @parameter property="hibernate.connection.driver_class" -344 * @since 1.0 -345 */ -346 private String driver; -347 -348 /** -349 * Database URL. -350 * -351 * @parameter property="hibernate.connection.url" -352 * @since 1.0 -353 */ -354 private String url; -355 -356 /** -357 * Database username -358 * -359 * @parameter property="hibernate.connection.username" -360 * @since 1.0 -361 */ -362 private String username; -363 -364 /** -365 * Database password -366 * -367 * @parameter property="hibernate.connection.password" -368 * @since 1.0 -369 */ -370 private String password; -371 -372 -373 /** Parameters to locate configuration sources ****************************/ -374 -375 /** -376 * Path to a file or name of a ressource with hibernate properties. -377 * If this parameter is specified, the plugin will try to load configuration -378 * values from a file with the given path or a ressource on the classpath with -379 * the given name. If both fails, the execution of the plugin will fail. -380 * <p> -381 * If this parameter is not set the plugin will load configuration values -382 * from a ressource named <code>hibernate.properties</code> on the classpath, -383 * if it is present, but will not fail if there is no such ressource. -384 * <p> -385 * During ressource-lookup, the test-classpath takes precedence. -386 * -387 * @parameter -388 * @since 1.0 -389 */ -390 private String hibernateProperties; -391 -392 /** -393 * Path to Hibernate configuration file (.cfg.xml). -394 * If this parameter is specified, the plugin will try to load configuration -395 * values from a file with the given path or a ressource on the classpath with -396 * the given name. If both fails, the execution of the plugin will fail. -397 * <p> -398 * If this parameter is not set the plugin will load configuration values -399 * from a ressource named <code>hibernate.cfg.xml</code> on the classpath, -400 * if it is present, but will not fail if there is no such ressource. -401 * <p> -402 * During ressource-lookup, the test-classpath takes precedence. -403 * <p> -404 * Settings in this file will overwrite settings in the properties file. -405 * -406 * @parameter -407 * @since 1.1.0 -408 */ -409 private String hibernateConfig; -410 -411 /** -412 * Name of the persistence-unit. -413 * If this parameter is specified, the plugin will try to load configuration -414 * values from a persistence-unit with the specified name. If no such -415 * persistence-unit can be found, the plugin will throw an exception. -416 * <p> -417 * If this parameter is not set and there is only one persistence-unit -418 * available, that unit will be used automatically. But if this parameter is -419 * not set and there are multiple persistence-units available on, -420 * the class-path, the execution of the plugin will fail. -421 * <p> -422 * Settings in this file will overwrite settings in the properties or the -423 * configuration file. -424 * -425 * @parameter -426 * @since 1.1.0 -427 */ -428 private String persistenceUnit; -429 -430 /** -431 * List of Hibernate-Mapping-Files (XML). -432 * Multiple files can be separated with white-spaces and/or commas. -433 * -434 * @parameter property="hibernate.mapping" -435 * @since 1.0.2 -436 */ -437 private String mappings; -438 -439 -440 -441 public final void execute(String filename) -442 throws -443 MojoFailureException, -444 MojoExecutionException -445 { -446 if (skip) -447 { -448 getLog().info("Execution of hibernate-maven-plugin was skipped!"); -449 project.getProperties().setProperty(SKIPPED, "true"); -450 return; -451 } -452 -453 ModificationTracker tracker; -454 try -455 { -456 tracker = new ModificationTracker(buildDirectory, filename, getLog()); -457 } -458 catch (NoSuchAlgorithmException e) -459 { -460 throw new MojoFailureException("Digest-Algorithm MD5 is missing!", e); -461 } -462 -463 final SimpleConnectionProvider connectionProvider = -464 new SimpleConnectionProvider(getLog()); -465 -466 try -467 { -468 /** Start extended logging */ -469 MavenLogAppender.startPluginLog(this); -470 -471 /** Load checksums for old mapping and configuration */ -472 tracker.load(); -473 -474 /** Create the ClassLoader */ -475 MutableClassLoader classLoader = createClassLoader(); -476 -477 /** Create a BootstrapServiceRegistry with the created ClassLoader */ -478 BootstrapServiceRegistry bootstrapServiceRegitry = -479 new BootstrapServiceRegistryBuilder() -480 .applyClassLoader(classLoader) -481 .build(); -482 ClassLoaderService classLoaderService = -483 bootstrapServiceRegitry.getService(ClassLoaderService.class); -484 -485 Properties properties = new Properties(); -486 ConfigLoader configLoader = new ConfigLoader(bootstrapServiceRegitry); -487 -488 /** Loading and merging configuration */ -489 properties.putAll(loadProperties(configLoader)); -490 LoadedConfig config = loadConfig(configLoader); -491 if (config != null) -492 properties.putAll(config.getConfigurationValues()); -493 ParsedPersistenceXmlDescriptor unit = -494 loadPersistenceUnit(classLoaderService, properties); -495 if (unit != null) -496 properties.putAll(unit.getProperties()); -497 -498 /** Overwriting/Completing configuration */ -499 configure(properties, tracker); -500 -501 /** Check configuration for modifications */ -502 if(tracker.track(properties)) -503 getLog().debug("Configuration has changed."); -504 else -505 getLog().debug("Configuration unchanged."); -506 -507 /** Check, that the outputfile is writable */ -508 final File output = getOutputFile(filename); -509 /** Check, if the outputfile is missing or was changed */ -510 checkOutputFile(output, tracker); -511 -512 /** Configure Hibernate */ -513 final StandardServiceRegistry serviceRegistry = -514 new StandardServiceRegistryBuilder(bootstrapServiceRegitry) -515 .applySettings(properties) -516 .addService(ConnectionProvider.class, connectionProvider) -517 .build(); -518 final MetadataSources sources = new MetadataSources(serviceRegistry); -519 -520 /** Add the remaining class-path-elements */ -521 completeClassPath(classLoader); -522 -523 /** Apply mappings from hibernate-configuration, if present */ -524 if (config != null) -525 { -526 for (MappingReference mapping : config.getMappingReferences()) -527 mapping.apply(sources); -528 } -529 -530 Set<String> classes; -531 if (unit == null) -532 { -533 /** No persistent unit: default behaviour */ -534 if (scanClasses == null) -535 scanClasses = true; -536 Set<URL> urls = new HashSet<URL>(); -537 if (scanClasses) -538 addRoot(urls, outputDirectory); -539 if (scanTestClasses) -540 addRoot(urls, testOutputDirectory); -541 addDependencies(urls); -542 classes = scanUrls(urls); -543 } -544 else -545 { -546 /** Follow configuration in persisten unit */ -547 if (scanClasses == null) -548 scanClasses = !unit.isExcludeUnlistedClasses(); -549 Set<URL> urls = new HashSet<URL>(); -550 if (scanClasses) -551 { -552 /** -553 * Scan the root of the persiten unit and configured jars for -554 * annotated classes -555 */ -556 urls.add(unit.getPersistenceUnitRootUrl()); -557 for (URL url : unit.getJarFileUrls()) -558 urls.add(url); -559 } -560 if (scanTestClasses) -561 addRoot(urls, testOutputDirectory); -562 classes = scanUrls(urls); -563 for (String className : unit.getManagedClassNames()) -564 classes.add(className); -565 /** -566 * Add mappings from the default mapping-file -567 * <code>META-INF/orm.xml</code>, if present -568 */ -569 boolean error = false; -570 InputStream is; -571 is = classLoader.getResourceAsStream("META-INF/orm.xml"); -572 if (is != null) -573 { -574 getLog().info("Adding default JPA-XML-mapping from META-INF/orm.xml"); -575 try -576 { -577 tracker.track("META-INF/orm.xml", is); -578 sources.addResource("META-INF/orm.xml"); -579 } -580 catch (IOException e) -581 { -582 getLog().error("cannot read META-INF/orm.xml: " + e); -583 error = true; -584 } -585 } -586 else -587 { -588 getLog().debug("no META-INF/orm.xml found"); -589 } -590 /** -591 * Add mappings from files, that are explicitly configured in the -592 * persistence unit -593 */ -594 for (String mapping : unit.getMappingFileNames()) -595 { -596 getLog().info("Adding explicitly configured mapping from " + mapping); -597 is = classLoader.getResourceAsStream(mapping); -598 if (is != null) -599 { -600 try -601 { -602 tracker.track(mapping, is); -603 sources.addResource(mapping); -604 } -605 catch (IOException e) -606 { -607 getLog().info("cannot read mapping-file " + mapping + ": " + e); -608 error = true; -609 } -610 } -611 else -612 { -613 getLog().error("cannot find mapping-file " + mapping); -614 error = true; -615 } -616 } -617 if (error) -618 throw new MojoFailureException( -619 "error, while reading mappings configured in persistence-unit \"" + -620 unit.getName() + -621 "\"" -622 ); -623 } -624 -625 /** Add the configured/collected annotated classes */ -626 for (String className : classes) -627 addAnnotated(className, sources, classLoaderService, tracker); -628 -629 /** Add explicitly configured classes */ -630 addMappings(sources, tracker); -631 -632 /** Skip execution, if mapping and configuration is unchanged */ -633 if (!tracker.modified()) -634 { -635 getLog().info("Mapping and configuration unchanged."); -636 if (force) -637 getLog().info("Generation/execution is forced!"); -638 else -639 { -640 getLog().info("Skipping schema generation!"); -641 project.getProperties().setProperty(SKIPPED, "true"); -642 return; -643 } -644 } -645 -646 -647 /** Truncate output file */ -648 try -649 { -650 new FileOutputStream(output).getChannel().truncate(0).close(); -651 } -652 catch (IOException e) -653 { -654 String error = -655 "Error while truncating " + output.getAbsolutePath() + ": " -656 + e.getMessage(); -657 getLog().warn(error); -658 throw new MojoExecutionException(error); -659 } -660 -661 /** Create a connection, if sufficient configuration infromation is available */ -662 connectionProvider.open(classLoaderService, properties); -663 -664 MetadataBuilder metadataBuilder = sources.getMetadataBuilder(); -665 -666 StrategySelector strategySelector = -667 serviceRegistry.getService(StrategySelector.class); -668 -669 if (properties.containsKey(IMPLICIT_NAMING_STRATEGY)) -670 { -671 metadataBuilder.applyImplicitNamingStrategy( -672 strategySelector.resolveStrategy( -673 ImplicitNamingStrategy.class, -674 properties.getProperty(IMPLICIT_NAMING_STRATEGY) -675 ) -676 ); -677 } -678 -679 if (properties.containsKey(PHYSICAL_NAMING_STRATEGY)) -680 { -681 metadataBuilder.applyPhysicalNamingStrategy( -682 strategySelector.resolveStrategy( -683 PhysicalNamingStrategy.class, -684 properties.getProperty(PHYSICAL_NAMING_STRATEGY) -685 ) -686 ); -687 } -688 -689 /** Prepare the generation of the SQL */ -690 Map settings = new HashMap(); -691 settings.putAll( -692 serviceRegistry -693 .getService(ConfigurationService.class) -694 .getSettings() -695 ); -696 ExceptionHandlerCollectingImpl handler = -697 new ExceptionHandlerCollectingImpl(); -698 ExecutionOptions options = -699 SchemaManagementToolCoordinator -700 .buildExecutionOptions(settings, handler); -701 final EnumSet<TargetType> targetTypes = EnumSet.of(TargetType.SCRIPT); -702 if (execute) -703 targetTypes.add(TargetType.DATABASE); -704 TargetDescriptor target = new TargetDescriptor() -705 { -706 @Override -707 public EnumSet<TargetType> getTargetTypes() -708 { -709 return targetTypes; -710 } -711 -712 @Override -713 public ScriptTargetOutput getScriptTargetOutput() -714 { -715 String charset = -716 (String) -717 serviceRegistry -718 .getService(ConfigurationService.class) -719 .getSettings() -720 .get(AvailableSettings.HBM2DDL_CHARSET_NAME); -721 return new ScriptTargetOutputToFile(output, charset); -722 } -723 }; -724 -725 /** -726 * Change class-loader of current thread. -727 * This is necessary, because still not all parts of Hibernate 5 use -728 * the newly introduced ClassLoaderService and will fail otherwise! -729 */ -730 Thread thread = Thread.currentThread(); -731 ClassLoader contextClassLoader = thread.getContextClassLoader(); -732 try -733 { -734 thread.setContextClassLoader(classLoader); -735 build((MetadataImplementor)metadataBuilder.build(), options, target); -736 if (handler.getExceptions().size() > 0) -737 { -738 StringBuilder builder = new StringBuilder(); -739 builder.append("Hibernate failed:"); -740 for (Exception e : handler.getExceptions()) -741 { -742 builder.append("\n * "); -743 builder.append(e.getMessage()); -744 AbstractSchemaMojo.printStrackTrace(builder, e); -745 builder.append("\n"); -746 } -747 String error = builder.toString(); -748 getLog().error(error); -749 throw new MojoFailureException(error); -750 } -751 } -752 finally -753 { -754 thread.setContextClassLoader(contextClassLoader); -755 /** Track, the content of the generated script */ -756 checkOutputFile(output, tracker); -757 } -758 } -759 catch (MojoExecutionException e) -760 { -761 tracker.failed(); -762 throw e; -763 } -764 catch (MojoFailureException e) -765 { -766 tracker.failed(); -767 throw e; -768 } -769 catch (RuntimeException e) -770 { -771 tracker.failed(); -772 throw e; -773 } -774 finally -775 { -776 /** Remember mappings and configuration */ -777 tracker.save(); -778 -779 /** Close the connection - if one was opened */ -780 connectionProvider.close(); -781 -782 /** Stop Log-Capturing */ -783 MavenLogAppender.endPluginLog(this); -784 } -785 } -786 -787 -788 abstract void build( -789 MetadataImplementor metadata, -790 ExecutionOptions options, -791 TargetDescriptor target -792 ) -793 throws -794 MojoFailureException, -795 MojoExecutionException; -796 -797 -798 private MutableClassLoader createClassLoader() throws MojoExecutionException -799 { -800 try -801 { -802 getLog().debug("Creating ClassLoader for project-dependencies..."); -803 LinkedHashSet<URL> urls = new LinkedHashSet<URL>(); -804 File file; -805 -806 file = new File(testOutputDirectory); -807 if (!file.exists()) -808 { -809 getLog().info("Creating test-output-directory: " + testOutputDirectory); -810 file.mkdirs(); -811 } -812 urls.add(file.toURI().toURL()); -813 -814 file = new File(outputDirectory); -815 if (!file.exists()) -816 { -817 getLog().info("Creating output-directory: " + outputDirectory); -818 file.mkdirs(); -819 } -820 urls.add(file.toURI().toURL()); -821 -822 return new MutableClassLoader(urls, getLog()); -823 } -824 catch (Exception e) -825 { -826 getLog().error("Error while creating ClassLoader!", e); -827 throw new MojoExecutionException(e.getMessage()); -828 } -829 } -830 -831 private void completeClassPath(MutableClassLoader classLoader) -832 throws -833 MojoExecutionException -834 { -835 try -836 { -837 getLog().debug("Completing class-paths of the ClassLoader for project-dependencies..."); -838 List<String> classpathFiles = project.getCompileClasspathElements(); -839 if (scanTestClasses) -840 classpathFiles.addAll(project.getTestClasspathElements()); -841 LinkedHashSet<URL> urls = new LinkedHashSet<URL>(); -842 for (String pathElement : classpathFiles) -843 { -844 getLog().debug("Dependency: " + pathElement); -845 urls.add(new File(pathElement).toURI().toURL()); -846 } -847 classLoader.add(urls); -848 } -849 catch (Exception e) -850 { -851 getLog().error("Error while creating ClassLoader!", e); -852 throw new MojoExecutionException(e.getMessage()); -853 } -854 } -855 -856 private Map loadProperties(ConfigLoader configLoader) -857 throws -858 MojoExecutionException -859 { -860 /** Try to read configuration from properties-file */ -861 if (hibernateProperties == null) -862 { -863 try -864 { -865 return configLoader.loadProperties("hibernate.properties"); -866 } -867 catch (ConfigurationException e) -868 { -869 getLog().debug(e.getMessage()); -870 return Collections.EMPTY_MAP; -871 } -872 } -873 else -874 { -875 try -876 { -877 File file = new File(hibernateProperties); -878 if (file.exists()) -879 { -880 getLog().info("Reading settings from file " + hibernateProperties + "..."); -881 return configLoader.loadProperties(file); -882 } -883 else -884 return configLoader.loadProperties(hibernateProperties); -885 } -886 catch (ConfigurationException e) -887 { -888 getLog().error("Error while reading properties!", e); -889 throw new MojoExecutionException(e.getMessage()); -890 } -891 } -892 } -893 -894 private LoadedConfig loadConfig(ConfigLoader configLoader) -895 throws MojoExecutionException -896 { -897 /** Try to read configuration from configuration-file */ -898 if (hibernateConfig == null) -899 { -900 try -901 { -902 return configLoader.loadConfigXmlResource("hibernate.cfg.xml"); -903 } -904 catch (ConfigurationException e) -905 { -906 getLog().debug(e.getMessage()); -907 return null; -908 } -909 } -910 else -911 { -912 try -913 { -914 File file = new File(hibernateConfig); -915 if (file.exists()) -916 { -917 getLog().info("Reading configuration from file " + hibernateConfig + "..."); -918 return configLoader.loadConfigXmlFile(file); -919 } -920 else -921 { -922 return configLoader.loadConfigXmlResource(hibernateConfig); -923 } -924 } -925 catch (ConfigurationException e) -926 { -927 getLog().error("Error while reading configuration!", e); -928 throw new MojoExecutionException(e.getMessage()); -929 } -930 } -931 } -932 -933 private void configure(Properties properties, ModificationTracker tracker) -934 throws MojoFailureException -935 { -936 /** -937 * Special treatment for the configuration-value "execute": if it is -938 * switched to "true", the genearation fo the schema should be forced! -939 */ -940 if (tracker.check(EXECUTE, execute.toString()) && execute) -941 { -942 getLog().info( -943 "hibernate.schema.execute was switched on: " + -944 "forcing generation/execution of SQL" -945 ); -946 tracker.touch(); -947 } -948 configure(properties, execute, EXECUTE); -949 -950 /** -951 * Configure the generation of the SQL. -952 * Overwrite values from properties-file if the configuration parameter is -953 * known to Hibernate. -954 */ -955 configure(properties, dialect, DIALECT); -956 configure(properties, delimiter, HBM2DDL_DELIMITER); -957 configure(properties, format, FORMAT_SQL); -958 configure(properties, createNamespaces, HBM2DLL_CREATE_NAMESPACES); -959 configure(properties, implicitNamingStrategy, IMPLICIT_NAMING_STRATEGY); -960 configure(properties, physicalNamingStrategy, PHYSICAL_NAMING_STRATEGY); -961 configure(properties, outputDirectory, OUTPUTDIRECTORY); -962 configure(properties, scanDependencies, SCAN_DEPENDENCIES); -963 configure(properties, scanTestClasses, SCAN_TESTCLASSES); -964 configure(properties, testOutputDirectory, TEST_OUTPUTDIRECTORY); -965 -966 /** -967 * Special treatment for the configuration-value "show": a change of its -968 * configured value should not lead to a regeneration of the database -969 * schama! -970 */ -971 if (show == null) -972 show = Boolean.valueOf(properties.getProperty(SHOW_SQL)); -973 else -974 properties.setProperty(SHOW_SQL, show.toString()); -975 -976 /** -977 * Configure the connection parameters. -978 * Overwrite values from properties-file. -979 */ -980 configure(properties, driver, DRIVER, JPA_JDBC_DRIVER); -981 configure(properties, url, URL, JPA_JDBC_URL); -982 configure(properties, username, USER, JPA_JDBC_USER); -983 configure(properties, password, PASS, JPA_JDBC_PASSWORD); -984 -985 if (properties.isEmpty()) -986 { -987 getLog().error("No properties set!"); -988 throw new MojoFailureException("Hibernate configuration is missing!"); -989 } -990 -991 getLog().info("Gathered configuration:"); -992 for (Entry<Object,Object> entry : properties.entrySet()) -993 getLog().info(" " + entry.getKey() + " = " + entry.getValue()); -994 } -995 -996 private void configure( -997 Properties properties, -998 String value, -999 String key, -1000 String alternativeKey -1001 ) -1002 { -1003 configure(properties, value, key); -1004 -1005 if (properties.containsKey(alternativeKey)) -1006 { -1007 if (properties.containsKey(key)) -1008 { -1009 getLog().warn( -1010 "Ignoring property " + alternativeKey + "=\"" + -1011 properties.getProperty(alternativeKey) + -1012 "\" in favour for property " + key + "=\"" + -1013 properties.getProperty(key) + "\"" -1014 ); -1015 properties.remove(alternativeKey); -1016 } -1017 else -1018 { -1019 value = properties.getProperty(alternativeKey); -1020 properties.remove(alternativeKey); -1021 getLog().info( -1022 "Using value \"" + value + "\" from property " + alternativeKey + -1023 " for property " + key -1024 ); -1025 properties.setProperty(key, value); -1026 } -1027 } -1028 } -1029 -1030 private void configure(Properties properties, String value, String key) -1031 { -1032 if (value != null) -1033 { -1034 if (properties.containsKey(key)) -1035 { -1036 if (!properties.getProperty(key).equals(value)) -1037 { -1038 getLog().info( -1039 "Overwriting property " + key + "=\"" + -1040 properties.getProperty(key) + -1041 "\" with value \"" + value + "\"" -1042 ); -1043 properties.setProperty(key, value); -1044 } -1045 } -1046 else -1047 { -1048 getLog().debug("Using value \"" + value + "\" for property " + key); -1049 properties.setProperty(key, value); -1050 } -1051 } -1052 } -1053 -1054 private void configure(Properties properties, Boolean value, String key) -1055 { -1056 configure(properties, value == null ? null : value.toString(), key); -1057 } -1058 -1059 private File getOutputFile(String filename) -1060 throws -1061 MojoExecutionException -1062 { -1063 File output = new File(filename); -1064 -1065 if (!output.isAbsolute()) -1066 { -1067 // Interpret relative file path relative to build directory -1068 output = new File(buildDirectory, filename); -1069 } -1070 getLog().debug("Output file: " + output.getPath()); -1071 -1072 // Ensure that directory path for specified file exists -1073 File outFileParentDir = output.getParentFile(); -1074 if (null != outFileParentDir && !outFileParentDir.exists()) -1075 { -1076 try -1077 { -1078 getLog().info( -1079 "Creating directory path for output file:" + -1080 outFileParentDir.getPath() -1081 ); -1082 outFileParentDir.mkdirs(); -1083 } -1084 catch (Exception e) -1085 { -1086 String error = -1087 "Error creating directory path for output file: " + e.getMessage(); -1088 getLog().error(error); -1089 throw new MojoExecutionException(error); -1090 } -1091 } -1092 -1093 try -1094 { -1095 output.createNewFile(); -1096 } -1097 catch (IOException e) -1098 { -1099 String error = "Error creating output file: " + e.getMessage(); -1100 getLog().error(error); -1101 throw new MojoExecutionException(error); -1102 } -1103 -1104 if (!output.canWrite()) -1105 { -1106 String error = -1107 "Output file " + output.getAbsolutePath() + " is not writable!"; -1108 getLog().error(error); -1109 throw new MojoExecutionException(error); -1110 } -1111 -1112 return output; -1113 } -1114 -1115 private void checkOutputFile(File output, ModificationTracker tracker) -1116 throws -1117 MojoExecutionException -1118 { -1119 try -1120 { -1121 if (output.exists()) -1122 tracker.track(SCRIPT, new FileInputStream(output)); -1123 else -1124 tracker.track(SCRIPT, ZonedDateTime.now().toString()); -1125 } -1126 catch (IOException e) -1127 { -1128 String error = -1129 "Error while checking the generated script: " + e.getMessage(); -1130 getLog().error(error); -1131 throw new MojoExecutionException(error); -1132 } -1133 } -1134 -1135 private void addMappings(MetadataSources sources, ModificationTracker tracker) -1136 throws MojoFailureException -1137 { -1138 getLog().debug("Adding explicitly configured mappings..."); -1139 if (mappings != null) -1140 { -1141 try -1142 { -1143 for (String filename : mappings.split("[\\s,]+")) -1144 { -1145 // First try the filename as absolute/relative path -1146 File file = new File(filename); -1147 if (!file.exists()) -1148 { -1149 // If the file was not found, search for it in the resource-directories -1150 for (Resource resource : project.getResources()) -1151 { -1152 file = new File(resource.getDirectory() + File.separator + filename); -1153 if (file.exists()) -1154 break; -1155 } -1156 } -1157 if (file.exists()) -1158 { -1159 if (file.isDirectory()) -1160 // TODO: add support to read all mappings under a directory -1161 throw new MojoFailureException(file.getAbsolutePath() + " is a directory"); -1162 if (tracker.track(filename, new FileInputStream(file))) -1163 getLog().debug("Found new or modified mapping-file: " + filename); -1164 else -1165 getLog().debug("Mapping-file unchanged: " + filename); -1166 -1167 sources.addFile(file); -1168 } -1169 else -1170 throw new MojoFailureException("File " + filename + " could not be found in any of the configured resource-directories!"); -1171 } -1172 } -1173 catch (IOException e) -1174 { -1175 throw new MojoFailureException("Cannot calculate MD5 sums!", e); -1176 } -1177 } -1178 } -1179 -1180 private void addRoot(Set<URL> urls, String path) throws MojoFailureException -1181 { -1182 try -1183 { -1184 File dir = new File(path); -1185 if (dir.exists()) -1186 { -1187 getLog().info("Adding " + dir.getAbsolutePath() + " to the list of roots to scan..."); -1188 urls.add(dir.toURI().toURL()); -1189 } -1190 else -1191 getLog().warn( -1192 "the directory cannot be scanned for annotated classes, " + -1193 "because it does not exist: " + -1194 dir.getAbsolutePath() -1195 ); -1196 } -1197 catch (MalformedURLException e) -1198 { -1199 getLog().error("error while adding the project-root to the list of roots to scan!", e); -1200 throw new MojoFailureException(e.getMessage()); -1201 } -1202 } -1203 -1204 private void addDependencies(Set<URL> urls) throws MojoFailureException -1205 { -1206 try -1207 { -1208 if (scanDependencies != null) -1209 { -1210 Matcher matcher = SPLIT.matcher(scanDependencies); -1211 while (matcher.find()) -1212 { -1213 getLog().info("Adding dependencies from scope " + matcher.group() + " to the list of roots to scan"); -1214 for (Artifact artifact : project.getDependencyArtifacts()) -1215 { -1216 if (!artifact.getScope().equalsIgnoreCase(matcher.group())) -1217 continue; -1218 if (artifact.getFile() == null) -1219 { -1220 getLog().warn("Cannot add dependency " + artifact.getId() + ": no JAR-file available!"); -1221 continue; -1222 } -1223 getLog().info("Adding dependencies from scope " + artifact.getId() + " to the list of roots to scan"); -1224 urls.add(artifact.getFile().toURI().toURL()); -1225 } -1226 } -1227 } -1228 } -1229 catch (MalformedURLException e) -1230 { -1231 getLog().error("Error while adding dependencies to the list of roots to scan!", e); -1232 throw new MojoFailureException(e.getMessage()); -1233 } -1234 } -1235 -1236 private Set<String> scanUrls(Set<URL> scanRoots) -1237 throws -1238 MojoFailureException -1239 { -1240 try -1241 { -1242 AnnotationDB db = new AnnotationDB(); -1243 for (URL root : scanRoots) -1244 db.scanArchives(root); -1245 -1246 Set<String> classes = new HashSet<String>(); -1247 if (db.getAnnotationIndex().containsKey(Entity.class.getName())) -1248 classes.addAll(db.getAnnotationIndex().get(Entity.class.getName())); -1249 if (db.getAnnotationIndex().containsKey(MappedSuperclass.class.getName())) -1250 classes.addAll(db.getAnnotationIndex().get(MappedSuperclass.class.getName())); -1251 if (db.getAnnotationIndex().containsKey(Embeddable.class.getName())) -1252 classes.addAll(db.getAnnotationIndex().get(Embeddable.class.getName())); -1253 -1254 return classes; -1255 } -1256 catch (Exception e) -1257 { -1258 getLog().error("Error while scanning!", e); -1259 throw new MojoFailureException(e.getMessage()); -1260 } -1261 } -1262 -1263 private void addAnnotated( -1264 String name, -1265 MetadataSources sources, -1266 ClassLoaderService classLoaderService, -1267 ModificationTracker tracker -1268 ) -1269 throws -1270 MojoFailureException, -1271 MojoExecutionException -1272 { -1273 try -1274 { -1275 getLog().info("Adding annotated resource: " + name); -1276 String packageName = null; -1277 -1278 boolean error = false; -1279 try -1280 { -1281 Class<?> annotatedClass = classLoaderService.classForName(name); -1282 String resourceName = annotatedClass.getName(); -1283 resourceName = -1284 resourceName.substring( -1285 resourceName.lastIndexOf(".") + 1, -1286 resourceName.length() -1287 ) + ".class"; -1288 InputStream is = annotatedClass.getResourceAsStream(resourceName); -1289 if (is != null) -1290 { -1291 if (tracker.track(name, is)) -1292 getLog().debug("New or modified class: " + name); -1293 else -1294 getLog().debug("Unchanged class: " + name); -1295 sources.addAnnotatedClass(annotatedClass); -1296 packageName = annotatedClass.getPackage().getName(); -1297 } -1298 else -1299 { -1300 getLog().error("cannot find ressource " + resourceName + " for class " + name); -1301 error = true; -1302 } -1303 } -1304 catch(ClassLoadingException e) -1305 { -1306 packageName = name; -1307 } -1308 if (error) -1309 { -1310 throw new MojoExecutionException("error while inspecting annotated class " + name); -1311 } -1312 -1313 while (packageName != null) -1314 { -1315 if (packages.contains(packageName)) -1316 return; -1317 String resource = packageName.replace('.', '/') + "/package-info.class"; -1318 InputStream is = classLoaderService.locateResourceStream(resource); -1319 if (is == null) -1320 { -1321 // No compiled package-info available: no package-level annotations! -1322 getLog().debug("Package " + packageName + " is not annotated."); -1323 } -1324 else -1325 { -1326 if (tracker.track(packageName, is)) -1327 getLog().debug("New or modified package: " + packageName); -1328 else -1329 getLog().debug("Unchanged package: " + packageName); -1330 getLog().info("Adding annotations from package " + packageName); -1331 sources.addPackage(packageName); -1332 } -1333 packages.add(packageName); -1334 int i = packageName.lastIndexOf('.'); -1335 if (i < 0) -1336 packageName = null; -1337 else -1338 packageName = packageName.substring(0,i); -1339 } -1340 } -1341 catch (Exception e) -1342 { -1343 getLog().error("Error while adding the annotated class " + name, e); -1344 throw new MojoFailureException(e.getMessage()); -1345 } -1346 } -1347 -1348 private ParsedPersistenceXmlDescriptor loadPersistenceUnit( -1349 ClassLoaderService classLoaderService, -1350 Properties properties -1351 ) -1352 throws -1353 MojoFailureException -1354 { -1355 PersistenceXmlParser parser = -1356 new PersistenceXmlParser( -1357 classLoaderService, -1358 PersistenceUnitTransactionType.RESOURCE_LOCAL -1359 ); -1360 -1361 Map<String, ParsedPersistenceXmlDescriptor> units = -1362 parser.doResolve(properties); -1363 -1364 if (persistenceUnit == null) -1365 { -1366 Iterator<String> names = units.keySet().iterator(); -1367 if (!names.hasNext()) -1368 { -1369 getLog().info("Found no META-INF/persistence.xml."); -1370 return null; -1371 } -1372 -1373 String name = names.next(); -1374 if (!names.hasNext()) -1375 { -1376 getLog().info("Using persistence-unit " + name); -1377 return units.get(name); -1378 } -1379 -1380 StringBuilder builder = new StringBuilder(); -1381 builder.append("No name provided and multiple persistence units found: "); -1382 builder.append(name); -1383 while(names.hasNext()) -1384 { -1385 builder.append(", "); -1386 builder.append(names.next()); -1387 } -1388 builder.append('.'); -1389 throw new MojoFailureException(builder.toString()); -1390 } -1391 -1392 if (units.containsKey(persistenceUnit)) -1393 { -1394 getLog().info("Using configured persistence-unit " + persistenceUnit); -1395 return units.get(persistenceUnit); -1396 } -1397 -1398 throw new MojoFailureException("Could not find persistence-unit " + persistenceUnit); -1399 } -1400 -1401 -1402 public static void printStrackTrace(StringBuilder builder, Throwable t) -1403 { -1404 while (t != null) -1405 { -1406 builder.append("\n\tCause: "); -1407 builder.append(t.getMessage() == null ? "" : t.getMessage().replaceAll("\\s+", " ")); -1408 for (StackTraceElement trace : t.getStackTrace()) -1409 { -1410 builder.append("\n\t"); -1411 builder.append(trace.getClassName()); -1412 builder.append("."); -1413 builder.append(trace.getMethodName()); -1414 builder.append("():"); -1415 builder.append(trace.getLineNumber()); -1416 } -1417 t = t.getCause(); -1418 } -1419 } -1420 } --
-1 package de.juplo.plugins.hibernate; -2 -3 /* -4 * Copyright 2001-2005 The Apache Software Foundation. -5 * -6 * Licensed under the Apache License, Version 2.0 (the "License"); -7 * you may not use this file except in compliance with the License. -8 * You may obtain a copy of the License at -9 * -10 * http://www.apache.org/licenses/LICENSE-2.0 -11 * -12 * Unless required by applicable law or agreed to in writing, software -13 * distributed under the License is distributed on an "AS IS" BASIS, -14 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -15 * See the License for the specific language governing permissions and -16 * limitations under the License. -17 */ -18 -19 import java.util.Map; -20 import org.apache.maven.plugin.MojoExecutionException; -21 import org.apache.maven.plugin.MojoFailureException; -22 import org.hibernate.boot.spi.MetadataImplementor; -23 import org.hibernate.service.ServiceRegistry; -24 import org.hibernate.tool.schema.SourceType; -25 import org.hibernate.tool.schema.spi.ExecutionOptions; -26 import org.hibernate.tool.schema.spi.SchemaManagementTool; -27 import org.hibernate.tool.schema.spi.ScriptSourceInput; -28 import org.hibernate.tool.schema.spi.SourceDescriptor; -29 import org.hibernate.tool.schema.spi.TargetDescriptor; -30 -31 -32 /** -33 * Generate/Execute SQL to create a database-schema that represents the -34 * configured mappings. -35 * -36 * @goal create -37 * @phase process-classes -38 * @threadSafe -39 * @requiresDependencyResolution runtime -40 */ -41 public class CreateMojo extends AbstractSchemaMojo -42 { -43 /** -44 * Output file. -45 * <p> -46 * If the specified filename is not absolut, the file will be created -47 * relative to the project build directory -48 * (<code>project.build.directory</code>). -49 * -50 * @parameter property="hibernate.schema.create" default-value="create.sql" -51 * @since 1.0 -52 */ -53 private String outputFile; -54 -55 -56 @Override -57 public final void execute() -58 throws -59 MojoFailureException, -60 MojoExecutionException -61 { -62 super.execute(outputFile); -63 } -64 -65 -66 @Override -67 void build( -68 MetadataImplementor metadata, -69 ExecutionOptions options, -70 TargetDescriptor target -71 ) -72 throws -73 MojoExecutionException, -74 MojoFailureException -75 { -76 ServiceRegistry service = -77 metadata.getMetadataBuildingOptions().getServiceRegistry(); -78 SchemaManagementTool tool = service.getService(SchemaManagementTool.class); -79 -80 Map config = options.getConfigurationValues(); -81 SourceDescriptor source = new SourceDescriptor() -82 { -83 @Override -84 public SourceType getSourceType() -85 { -86 return SourceType.METADATA; -87 } -88 -89 @Override -90 public ScriptSourceInput getScriptSourceInput() -91 { -92 return null; -93 } -94 }; -95 -96 tool.getSchemaCreator(config).doCreation(metadata, options, source, target); -97 } -98 } --
-1 package de.juplo.plugins.hibernate; -2 -3 /* -4 * Copyright 2001-2005 The Apache Software Foundation. -5 * -6 * Licensed under the Apache License, Version 2.0 (the "License"); -7 * you may not use this file except in compliance with the License. -8 * You may obtain a copy of the License at -9 * -10 * http://www.apache.org/licenses/LICENSE-2.0 -11 * -12 * Unless required by applicable law or agreed to in writing, software -13 * distributed under the License is distributed on an "AS IS" BASIS, -14 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -15 * See the License for the specific language governing permissions and -16 * limitations under the License. -17 */ -18 -19 import java.util.Map; -20 import org.apache.maven.plugin.MojoExecutionException; -21 import org.apache.maven.plugin.MojoFailureException; -22 import org.hibernate.boot.spi.MetadataImplementor; -23 import org.hibernate.service.ServiceRegistry; -24 import org.hibernate.tool.schema.SourceType; -25 import org.hibernate.tool.schema.spi.ExecutionOptions; -26 import org.hibernate.tool.schema.spi.SchemaManagementTool; -27 import org.hibernate.tool.schema.spi.ScriptSourceInput; -28 import org.hibernate.tool.schema.spi.SourceDescriptor; -29 import org.hibernate.tool.schema.spi.TargetDescriptor; -30 -31 -32 /** -33 * Generate/Execute SQL to drop all tables of a database-schema that represents -34 * the configured mappings. -35 * -36 * @goal drop -37 * @phase process-classes -38 * @threadSafe -39 * @requiresDependencyResolution runtime -40 */ -41 public class DropMojo extends AbstractSchemaMojo -42 { -43 /** -44 * Output file. -45 * <p> -46 * If the specified filename is not absolut, the file will be created -47 * relative to the project build directory -48 * (<code>project.build.directory</code>). -49 * -50 * @parameter property="hibernate.schema.drop" default-value="drop.sql" -51 * @since 1.0 -52 */ -53 private String outputFile; -54 -55 -56 @Override -57 public final void execute() -58 throws -59 MojoFailureException, -60 MojoExecutionException -61 { -62 super.execute(outputFile); -63 } -64 -65 -66 @Override -67 void build( -68 MetadataImplementor metadata, -69 ExecutionOptions options, -70 TargetDescriptor target -71 ) -72 throws -73 MojoExecutionException, -74 MojoFailureException -75 { -76 ServiceRegistry service = -77 metadata.getMetadataBuildingOptions().getServiceRegistry(); -78 SchemaManagementTool tool = service.getService(SchemaManagementTool.class); -79 -80 Map config = options.getConfigurationValues(); -81 SourceDescriptor source = new SourceDescriptor() -82 { -83 @Override -84 public SourceType getSourceType() -85 { -86 return SourceType.METADATA; -87 } -88 -89 @Override -90 public ScriptSourceInput getScriptSourceInput() -91 { -92 return null; -93 } -94 }; -95 -96 tool.getSchemaDropper(config).doDrop(metadata, options, source, target); -97 } -98 } --
-1 -2 package de.juplo.plugins.hibernate; -3 -4 import org.apache.maven.plugin.AbstractMojo; -5 import org.apache.maven.plugin.MojoExecutionException; -6 -7 import org.w3c.dom.Document; -8 import org.w3c.dom.Element; -9 import org.w3c.dom.Node; -10 import org.w3c.dom.NodeList; -11 import org.xml.sax.SAXException; -12 -13 import javax.xml.parsers.DocumentBuilder; -14 import javax.xml.parsers.DocumentBuilderFactory; -15 import javax.xml.parsers.ParserConfigurationException; -16 import java.io.IOException; -17 import java.io.InputStream; -18 import java.util.ArrayList; -19 import java.util.List; -20 -21 /** -22 * Display help information on hibernate-maven-plugin.<br> -23 * Call <code>mvn hibernate:help -Ddetail=true -Dgoal=<goal-name></code> to display parameter details. -24 * @author maven-plugin-tools -25 * @goal help -26 * @requiresProject false -27 * @threadSafe -28 */ -29 public class HelpMojo -30 extends AbstractMojo -31 { -32 /** -33 * If <code>true</code>, display all settable properties for each goal. -34 * -35 * @parameter property="detail" default-value="false" -36 */ -37 private boolean detail; -38 -39 /** -40 * The name of the goal for which to show help. If unspecified, all goals will be displayed. -41 * -42 * @parameter property="goal" -43 */ -44 private java.lang.String goal; -45 -46 /** -47 * The maximum length of a display line, should be positive. -48 * -49 * @parameter property="lineLength" default-value="80" -50 */ -51 private int lineLength; -52 -53 /** -54 * The number of spaces per indentation level, should be positive. -55 * -56 * @parameter property="indentSize" default-value="2" -57 */ -58 private int indentSize; -59 -60 // groupId/artifactId/plugin-help.xml -61 private static final String PLUGIN_HELP_PATH = -62 "/META-INF/maven/de.juplo/hibernate-maven-plugin/plugin-help.xml"; -63 -64 private static final int DEFAULT_LINE_LENGTH = 80; -65 -66 private Document build() -67 throws MojoExecutionException -68 { -69 getLog().debug( "load plugin-help.xml: " + PLUGIN_HELP_PATH ); -70 InputStream is = null; -71 try -72 { -73 is = getClass().getResourceAsStream( PLUGIN_HELP_PATH ); -74 DocumentBuilderFactory dbFactory = DocumentBuilderFactory.newInstance(); -75 DocumentBuilder dBuilder = dbFactory.newDocumentBuilder(); -76 return dBuilder.parse( is ); -77 } -78 catch ( IOException e ) -79 { -80 throw new MojoExecutionException( e.getMessage(), e ); -81 } -82 catch ( ParserConfigurationException e ) -83 { -84 throw new MojoExecutionException( e.getMessage(), e ); -85 } -86 catch ( SAXException e ) -87 { -88 throw new MojoExecutionException( e.getMessage(), e ); -89 } -90 finally -91 { -92 if ( is != null ) -93 { -94 try -95 { -96 is.close(); -97 } -98 catch ( IOException e ) -99 { -100 throw new MojoExecutionException( e.getMessage(), e ); -101 } -102 } -103 } -104 } -105 -106 /** -107 * {@inheritDoc} -108 */ -109 public void execute() -110 throws MojoExecutionException -111 { -112 if ( lineLength <= 0 ) -113 { -114 getLog().warn( "The parameter 'lineLength' should be positive, using '80' as default." ); -115 lineLength = DEFAULT_LINE_LENGTH; -116 } -117 if ( indentSize <= 0 ) -118 { -119 getLog().warn( "The parameter 'indentSize' should be positive, using '2' as default." ); -120 indentSize = 2; -121 } -122 -123 Document doc = build(); -124 -125 StringBuilder sb = new StringBuilder(); -126 Node plugin = getSingleChild( doc, "plugin" ); -127 -128 -129 String name = getValue( plugin, "name" ); -130 String version = getValue( plugin, "version" ); -131 String id = getValue( plugin, "groupId" ) + ":" + getValue( plugin, "artifactId" ) + ":" + version; -132 if ( isNotEmpty( name ) && !name.contains( id ) ) -133 { -134 append( sb, name + " " + version, 0 ); -135 } -136 else -137 { -138 if ( isNotEmpty( name ) ) -139 { -140 append( sb, name, 0 ); -141 } -142 else -143 { -144 append( sb, id, 0 ); -145 } -146 } -147 append( sb, getValue( plugin, "description" ), 1 ); -148 append( sb, "", 0 ); -149 -150 //<goalPrefix>plugin</goalPrefix> -151 String goalPrefix = getValue( plugin, "goalPrefix" ); -152 -153 Node mojos1 = getSingleChild( plugin, "mojos" ); -154 -155 List<Node> mojos = findNamedChild( mojos1, "mojo" ); -156 -157 if ( goal == null || goal.length() <= 0 ) -158 { -159 append( sb, "This plugin has " + mojos.size() + ( mojos.size() > 1 ? " goals:" : " goal:" ), 0 ); -160 append( sb, "", 0 ); -161 } -162 -163 for ( Node mojo : mojos ) -164 { -165 writeGoal( sb, goalPrefix, (Element) mojo ); -166 } -167 -168 if ( getLog().isInfoEnabled() ) -169 { -170 getLog().info( sb.toString() ); -171 } -172 } -173 -174 -175 private static boolean isNotEmpty( String string ) -176 { -177 return string != null && string.length() > 0; -178 } -179 -180 private String getValue( Node node, String elementName ) -181 throws MojoExecutionException -182 { -183 return getSingleChild( node, elementName ).getTextContent(); -184 } -185 -186 private Node getSingleChild( Node node, String elementName ) -187 throws MojoExecutionException -188 { -189 List<Node> namedChild = findNamedChild( node, elementName ); -190 if ( namedChild.isEmpty() ) -191 { -192 throw new MojoExecutionException( "Could not find " + elementName + " in plugin-help.xml" ); -193 } -194 if ( namedChild.size() > 1 ) -195 { -196 throw new MojoExecutionException( "Multiple " + elementName + " in plugin-help.xml" ); -197 } -198 return namedChild.get( 0 ); -199 } -200 -201 private List<Node> findNamedChild( Node node, String elementName ) -202 { -203 List<Node> result = new ArrayList<Node>(); -204 NodeList childNodes = node.getChildNodes(); -205 for ( int i = 0; i < childNodes.getLength(); i++ ) -206 { -207 Node item = childNodes.item( i ); -208 if ( elementName.equals( item.getNodeName() ) ) -209 { -210 result.add( item ); -211 } -212 } -213 return result; -214 } -215 -216 private Node findSingleChild( Node node, String elementName ) -217 throws MojoExecutionException -218 { -219 List<Node> elementsByTagName = findNamedChild( node, elementName ); -220 if ( elementsByTagName.isEmpty() ) -221 { -222 return null; -223 } -224 if ( elementsByTagName.size() > 1 ) -225 { -226 throw new MojoExecutionException( "Multiple " + elementName + "in plugin-help.xml" ); -227 } -228 return elementsByTagName.get( 0 ); -229 } -230 -231 private void writeGoal( StringBuilder sb, String goalPrefix, Element mojo ) -232 throws MojoExecutionException -233 { -234 String mojoGoal = getValue( mojo, "goal" ); -235 Node configurationElement = findSingleChild( mojo, "configuration" ); -236 Node description = findSingleChild( mojo, "description" ); -237 if ( goal == null || goal.length() <= 0 || mojoGoal.equals( goal ) ) -238 { -239 append( sb, goalPrefix + ":" + mojoGoal, 0 ); -240 Node deprecated = findSingleChild( mojo, "deprecated" ); -241 if ( ( deprecated != null ) && isNotEmpty( deprecated.getTextContent() ) ) -242 { -243 append( sb, "Deprecated. " + deprecated.getTextContent(), 1 ); -244 if ( detail && description != null ) -245 { -246 append( sb, "", 0 ); -247 append( sb, description.getTextContent(), 1 ); -248 } -249 } -250 else if ( description != null ) -251 { -252 append( sb, description.getTextContent(), 1 ); -253 } -254 append( sb, "", 0 ); -255 -256 if ( detail ) -257 { -258 Node parametersNode = getSingleChild( mojo, "parameters" ); -259 List<Node> parameters = findNamedChild( parametersNode, "parameter" ); -260 append( sb, "Available parameters:", 1 ); -261 append( sb, "", 0 ); -262 -263 for ( Node parameter : parameters ) -264 { -265 writeParameter( sb, parameter, configurationElement ); -266 } -267 } -268 } -269 } -270 -271 private void writeParameter( StringBuilder sb, Node parameter, Node configurationElement ) -272 throws MojoExecutionException -273 { -274 String parameterName = getValue( parameter, "name" ); -275 String parameterDescription = getValue( parameter, "description" ); -276 -277 Element fieldConfigurationElement = (Element) findSingleChild( configurationElement, parameterName ); -278 -279 String parameterDefaultValue = ""; -280 if ( fieldConfigurationElement != null && fieldConfigurationElement.hasAttribute( "default-value" ) ) -281 { -282 parameterDefaultValue = " (Default: " + fieldConfigurationElement.getAttribute( "default-value" ) + ")"; -283 } -284 append( sb, parameterName + parameterDefaultValue, 2 ); -285 Node deprecated = findSingleChild( parameter, "deprecated" ); -286 if ( ( deprecated != null ) && isNotEmpty( deprecated.getTextContent() ) ) -287 { -288 append( sb, "Deprecated. " + deprecated.getTextContent(), 3 ); -289 append( sb, "", 0 ); -290 } -291 append( sb, parameterDescription, 3 ); -292 if ( "true".equals( getValue( parameter, "required" ) ) ) -293 { -294 append( sb, "Required: Yes", 3 ); -295 } -296 if ( ( fieldConfigurationElement != null ) && isNotEmpty( fieldConfigurationElement.getTextContent() ) ) -297 { -298 String property = getPropertyFromExpression( fieldConfigurationElement.getTextContent() ); -299 append( sb, "User property: " + property, 3 ); -300 } -301 -302 append( sb, "", 0 ); -303 } -304 -305 /** -306 * <p>Repeat a String <code>n</code> times to form a new string.</p> -307 * -308 * @param str String to repeat -309 * @param repeat number of times to repeat str -310 * @return String with repeated String -311 * @throws NegativeArraySizeException if <code>repeat < 0</code> -312 * @throws NullPointerException if str is <code>null</code> -313 */ -314 private static String repeat( String str, int repeat ) -315 { -316 StringBuilder buffer = new StringBuilder( repeat * str.length() ); -317 -318 for ( int i = 0; i < repeat; i++ ) -319 { -320 buffer.append( str ); -321 } -322 -323 return buffer.toString(); -324 } -325 -326 /** -327 * Append a description to the buffer by respecting the indentSize and lineLength parameters. -328 * <b>Note</b>: The last character is always a new line. -329 * -330 * @param sb The buffer to append the description, not <code>null</code>. -331 * @param description The description, not <code>null</code>. -332 * @param indent The base indentation level of each line, must not be negative. -333 */ -334 private void append( StringBuilder sb, String description, int indent ) -335 { -336 for ( String line : toLines( description, indent, indentSize, lineLength ) ) -337 { -338 sb.append( line ).append( '\n' ); -339 } -340 } -341 -342 /** -343 * Splits the specified text into lines of convenient display length. -344 * -345 * @param text The text to split into lines, must not be <code>null</code>. -346 * @param indent The base indentation level of each line, must not be negative. -347 * @param indentSize The size of each indentation, must not be negative. -348 * @param lineLength The length of the line, must not be negative. -349 * @return The sequence of display lines, never <code>null</code>. -350 * @throws NegativeArraySizeException if <code>indent < 0</code> -351 */ -352 private static List<String> toLines( String text, int indent, int indentSize, int lineLength ) -353 { -354 List<String> lines = new ArrayList<String>(); -355 -356 String ind = repeat( "\t", indent ); -357 -358 String[] plainLines = text.split( "(\r\n)|(\r)|(\n)" ); -359 -360 for ( String plainLine : plainLines ) -361 { -362 toLines( lines, ind + plainLine, indentSize, lineLength ); -363 } -364 -365 return lines; -366 } -367 -368 /** -369 * Adds the specified line to the output sequence, performing line wrapping if necessary. -370 * -371 * @param lines The sequence of display lines, must not be <code>null</code>. -372 * @param line The line to add, must not be <code>null</code>. -373 * @param indentSize The size of each indentation, must not be negative. -374 * @param lineLength The length of the line, must not be negative. -375 */ -376 private static void toLines( List<String> lines, String line, int indentSize, int lineLength ) -377 { -378 int lineIndent = getIndentLevel( line ); -379 StringBuilder buf = new StringBuilder( 256 ); -380 -381 String[] tokens = line.split( " +" ); -382 -383 for ( String token : tokens ) -384 { -385 if ( buf.length() > 0 ) -386 { -387 if ( buf.length() + token.length() >= lineLength ) -388 { -389 lines.add( buf.toString() ); -390 buf.setLength( 0 ); -391 buf.append( repeat( " ", lineIndent * indentSize ) ); -392 } -393 else -394 { -395 buf.append( ' ' ); -396 } -397 } -398 -399 for ( int j = 0; j < token.length(); j++ ) -400 { -401 char c = token.charAt( j ); -402 if ( c == '\t' ) -403 { -404 buf.append( repeat( " ", indentSize - buf.length() % indentSize ) ); -405 } -406 else if ( c == '\u00A0' ) -407 { -408 buf.append( ' ' ); -409 } -410 else -411 { -412 buf.append( c ); -413 } -414 } -415 } -416 lines.add( buf.toString() ); -417 } -418 -419 /** -420 * Gets the indentation level of the specified line. -421 * -422 * @param line The line whose indentation level should be retrieved, must not be <code>null</code>. -423 * @return The indentation level of the line. -424 */ -425 private static int getIndentLevel( String line ) -426 { -427 int level = 0; -428 for ( int i = 0; i < line.length() && line.charAt( i ) == '\t'; i++ ) -429 { -430 level++; -431 } -432 for ( int i = level + 1; i <= level + 4 && i < line.length(); i++ ) -433 { -434 if ( line.charAt( i ) == '\t' ) -435 { -436 level++; -437 break; -438 } -439 } -440 return level; -441 } -442 -443 private String getPropertyFromExpression( String expression ) -444 { -445 if ( expression != null && expression.startsWith( "${" ) && expression.endsWith( "}" ) -446 && !expression.substring( 2 ).contains( "${" ) ) -447 { -448 // expression="${xxx}" -> property="xxx" -449 return expression.substring( 2, expression.length() - 1 ); -450 } -451 // no property can be extracted -452 return null; -453 } -454 } --
-1 package de.juplo.plugins.hibernate; -2 -3 -4 import java.io.File; -5 import java.io.FileInputStream; -6 import java.io.FileOutputStream; -7 import java.io.IOException; -8 import java.io.InputStream; -9 import java.io.ObjectInputStream; -10 import java.io.ObjectOutputStream; -11 import java.math.BigInteger; -12 import java.security.MessageDigest; -13 import java.security.NoSuchAlgorithmException; -14 import java.util.HashMap; -15 import java.util.HashSet; -16 import java.util.Map; -17 import java.util.Properties; -18 import java.util.Set; -19 import org.apache.maven.plugin.logging.Log; -20 -21 -22 -23 /** -24 * -25 * @author Kai Moritz -26 */ -27 public class ModificationTracker -28 { -29 private Map<String,String> properties; -30 private Map<String,String> classes; -31 -32 private final Set<String> propertyNames; -33 private final Set<String> classNames; -34 -35 private boolean modified = false; -36 private boolean failed = false; -37 -38 private final File saved; -39 private final MessageDigest digest; -40 private final Log log; -41 -42 -43 ModificationTracker(String buildDirectory, String filename, Log log) -44 throws -45 NoSuchAlgorithmException -46 { -47 propertyNames = new HashSet<String>(); -48 classNames = new HashSet<String>(); -49 File output = new File(filename + ".md5s"); -50 if (output.isAbsolute()) -51 { -52 saved = output; -53 } -54 else -55 { -56 // Interpret relative file path relative to build directory -57 saved = new File(buildDirectory, output.getPath()); -58 log.debug("Adjusted relative path, resulting path is " + saved.getPath()); -59 } -60 digest = java.security.MessageDigest.getInstance("MD5"); -61 this.log = log; -62 } -63 -64 -65 private String calculate(InputStream is) -66 throws -67 IOException -68 { -69 byte[] buffer = new byte[1024*4]; // copy data in 4MB-chunks -70 int i; -71 while((i = is.read(buffer)) > -1) -72 digest.update(buffer, 0, i); -73 is.close(); -74 byte[] bytes = digest.digest(); -75 BigInteger bi = new BigInteger(1, bytes); -76 return String.format("%0" + (bytes.length << 1) + "x", bi); -77 } -78 -79 private boolean check(Map<String,String> values, String name, String value) -80 { -81 if (!values.containsKey(name) || !values.get(name).equals(value)) -82 { -83 values.put(name, value); -84 return true; -85 } -86 else -87 return false; -88 } -89 -90 -91 boolean track(String name, InputStream is) throws IOException -92 { -93 boolean result = check(classes, name, calculate(is)); -94 classNames.add(name); -95 modified |= result; -96 return result; -97 } -98 -99 -100 boolean check(String name, String property) -101 { -102 propertyNames.add(name); -103 return check(properties, name, property); -104 } -105 -106 boolean track(String name, String property) -107 { -108 boolean result = check(name, property); -109 modified |= result; -110 return result; -111 } -112 -113 boolean track(Properties properties) -114 { -115 boolean result = false; -116 for (String name : properties.stringPropertyNames()) -117 result |= track(name, properties.getProperty(name)); -118 return result; -119 } -120 -121 -122 void touch() -123 { -124 modified = true; -125 } -126 -127 boolean modified() -128 { -129 for (String property : new HashSet<String>(properties.keySet())) -130 if (!propertyNames.contains(property)) -131 { -132 modified = true; -133 properties.remove(property); -134 } -135 for (String clazz : new HashSet<String>(classes.keySet())) -136 if (!classNames.contains(clazz)) -137 { -138 modified = true; -139 classes.remove(clazz); -140 } -141 return modified; -142 } -143 -144 -145 void failed() -146 { -147 failed = true; -148 } -149 -150 -151 void load() -152 { -153 if (saved.isFile() && saved.length() > 0) -154 { -155 try -156 { -157 FileInputStream fis = new FileInputStream(saved); -158 ObjectInputStream ois = new ObjectInputStream(fis); -159 properties = (HashMap<String,String>)ois.readObject(); -160 classes = (HashMap<String,String>)ois.readObject(); -161 ois.close(); -162 } -163 catch (Exception e) -164 { -165 properties = new HashMap<String,String>(); -166 classes = new HashMap<String,String>(); -167 log.warn("Cannot read md5s from saved: " + e); -168 } -169 } -170 else -171 { -172 properties = new HashMap<String,String>(); -173 classes = new HashMap<String,String>(); -174 try -175 { -176 saved.createNewFile(); -177 } -178 catch (IOException e) -179 { -180 log.debug("Cannot create file \"" + saved.getPath() + "\" for md5s: " + e); -181 } -182 } -183 } -184 -185 void save() -186 { -187 if (failed) -188 { -189 saved.delete(); -190 return; -191 } -192 -193 if (!modified) -194 return; -195 -196 /** Write md5-sums for annotated classes to file */ -197 try -198 { -199 FileOutputStream fos = new FileOutputStream(saved); -200 ObjectOutputStream oos = new ObjectOutputStream(fos); -201 oos.writeObject(properties); -202 oos.writeObject(classes); -203 oos.close(); -204 fos.close(); -205 } -206 catch (Exception e) -207 { -208 log.error("Cannot write md5-sums to file: " + e); -209 } -210 } -211 } --
-1 package de.juplo.plugins.hibernate; -2 -3 import java.io.IOException; -4 import java.io.InputStream; -5 import java.net.URL; -6 import java.net.URLClassLoader; -7 import java.util.Arrays; -8 import java.util.Enumeration; -9 import java.util.LinkedHashSet; -10 import org.apache.maven.plugin.logging.Log; -11 -12 -13 /** -14 * -15 * @author kai -16 */ -17 public class MutableClassLoader extends ClassLoader -18 { -19 private URLClassLoader loader; -20 private Log log; -21 -22 -23 public MutableClassLoader(LinkedHashSet<URL> urls, Log log) -24 { -25 if (log.isDebugEnabled()) -26 for (URL url : urls) -27 log.debug(url.toString()); -28 loader = -29 new URLClassLoader( -30 urls.toArray(new URL[urls.size()]), -31 getClass().getClassLoader() -32 ); -33 this.log = log; -34 } -35 -36 -37 public MutableClassLoader add(LinkedHashSet<URL> urls) -38 { -39 LinkedHashSet<URL> old = -40 new LinkedHashSet<URL>(Arrays.asList(loader.getURLs())); -41 old.addAll(urls); -42 if (log.isDebugEnabled()) -43 for (URL url : urls) -44 log.debug(url.toString()); -45 loader = -46 new URLClassLoader( -47 old.toArray(new URL[urls.size()]), -48 getClass().getClassLoader() -49 ); -50 return this; -51 } -52 -53 -54 @Override -55 public void clearAssertionStatus() -56 { -57 loader.clearAssertionStatus(); -58 } -59 -60 @Override -61 public void setClassAssertionStatus(String className, boolean enabled) -62 { -63 loader.setClassAssertionStatus(className, enabled); -64 } -65 -66 @Override -67 public void setPackageAssertionStatus(String packageName, boolean enabled) -68 { -69 loader.setPackageAssertionStatus(packageName, enabled); -70 } -71 -72 @Override -73 public void setDefaultAssertionStatus(boolean enabled) -74 { -75 loader.setDefaultAssertionStatus(enabled); -76 } -77 -78 @Override -79 public InputStream getResourceAsStream(String name) -80 { -81 return loader.getResourceAsStream(name); -82 } -83 -84 @Override -85 public Enumeration<URL> getResources(String name) throws IOException -86 { -87 return loader.getResources(name); -88 } -89 -90 @Override -91 public URL getResource(String name) -92 { -93 return loader.getResource(name); -94 } -95 -96 @Override -97 public Class<?> loadClass(String name) throws ClassNotFoundException -98 { -99 return loader.loadClass(name); -100 } -101 -102 } --
-1 package de.juplo.plugins.hibernate; -2 -3 import java.sql.Connection; -4 import java.sql.Driver; -5 import java.sql.DriverManager; -6 import java.sql.DriverPropertyInfo; -7 import java.sql.SQLException; -8 import java.sql.SQLFeatureNotSupportedException; -9 import java.util.Properties; -10 import java.util.logging.Logger; -11 import org.apache.maven.plugin.MojoFailureException; -12 import org.apache.maven.plugin.logging.Log; -13 import static org.eclipse.aether.repository.AuthenticationContext.PASSWORD; -14 import static org.eclipse.aether.repository.AuthenticationContext.USERNAME; -15 import org.hibernate.boot.registry.classloading.spi.ClassLoaderService; -16 import static org.hibernate.cfg.AvailableSettings.DRIVER; -17 import static org.hibernate.cfg.AvailableSettings.PASS; -18 import static org.hibernate.cfg.AvailableSettings.URL; -19 import static org.hibernate.cfg.AvailableSettings.USER; -20 import org.hibernate.engine.jdbc.connections.spi.ConnectionProvider; -21 import static org.hibernate.jpa.AvailableSettings.JDBC_DRIVER; -22 import static org.hibernate.jpa.AvailableSettings.JDBC_PASSWORD; -23 import static org.hibernate.jpa.AvailableSettings.JDBC_URL; -24 import static org.hibernate.jpa.AvailableSettings.JDBC_USER; -25 -26 /** -27 * -28 * @author Kai Moritz -29 */ -30 class SimpleConnectionProvider implements ConnectionProvider -31 { -32 private final Log log; -33 -34 private Connection connection; -35 -36 -37 SimpleConnectionProvider(Log log) -38 { -39 this.log = log; -40 } -41 -42 -43 void open(ClassLoaderService classLoaderService, Properties properties) -44 throws -45 MojoFailureException -46 { -47 -48 String driver = (String)properties.getProperty(DRIVER); -49 String url = (String)properties.getProperty(URL); -50 String user = (String)properties.getProperty(USER); -51 String password = (String)properties.getProperty(PASS); -52 -53 if (driver == null || url == null) -54 { -55 log.info("No connection opened, because connection information is incomplete"); -56 log.info("Driver-Class: " + driver); -57 log.info("URL: " + url); -58 return; -59 } -60 -61 try -62 { -63 Class driverClass = classLoaderService.classForName(driver); -64 -65 log.debug("Registering JDBC-driver " + driverClass.getName()); -66 DriverManager -67 .registerDriver(new DriverProxy((Driver) driverClass.newInstance())); -68 -69 log.debug( -70 "Opening JDBC-connection to " + url + -71 " as " + user + -72 " with password " + password -73 ); -74 -75 connection = DriverManager.getConnection(url, user, password); -76 } -77 catch (Exception e) -78 { -79 log.info("Could not open the JDBC-connection: " + e.getMessage()); -80 } -81 } -82 -83 void close() -84 { -85 if (connection == null) -86 return; -87 -88 log.debug("Closing the JDBC-connection."); -89 try -90 { -91 connection.close(); -92 } -93 catch (SQLException e) -94 { -95 log.error("Error while closing the JDBC-connection: " + e.getMessage()); -96 } -97 } -98 -99 @Override -100 public Connection getConnection() throws SQLException -101 { -102 log.debug("Connection aquired."); -103 -104 if (connection == null) -105 throw new SQLException("No connection available, because of insufficient connection information!"); -106 -107 return connection; -108 } -109 -110 @Override -111 public void closeConnection(Connection conn) throws SQLException -112 { -113 log.debug("Connection released"); -114 } -115 -116 @Override -117 public boolean supportsAggressiveRelease() -118 { -119 return false; -120 } -121 -122 @Override -123 public boolean isUnwrappableAs(Class unwrapType) -124 { -125 return false; -126 } -127 -128 @Override -129 public <T> T unwrap(Class<T> unwrapType) -130 { -131 throw new UnsupportedOperationException("Not supported."); -132 } -133 -134 /** -135 * Needed, because DriverManager won't pick up drivers, that were not -136 * loaded by the system-classloader! -137 * See: -138 * http://stackoverflow.com/questions/288828/how-to-use-a-jdbc-driver-fromodifiedm-an-arbitrary-location -139 */ -140 static final class DriverProxy implements Driver -141 { -142 private final Driver target; -143 -144 DriverProxy(Driver target) -145 { -146 if (target == null) -147 throw new NullPointerException(); -148 this.target = target; -149 } -150 -151 public java.sql.Driver getTarget() -152 { -153 return target; -154 } -155 -156 @Override -157 public boolean acceptsURL(String url) throws SQLException -158 { -159 return target.acceptsURL(url); -160 } -161 -162 @Override -163 public java.sql.Connection connect( -164 String url, -165 java.util.Properties info -166 ) -167 throws -168 SQLException -169 { -170 return target.connect(url, info); -171 } -172 -173 @Override -174 public int getMajorVersion() -175 { -176 return target.getMajorVersion(); -177 } -178 -179 @Override -180 public int getMinorVersion() -181 { -182 return target.getMinorVersion(); -183 } -184 -185 @Override -186 public DriverPropertyInfo[] getPropertyInfo( -187 String url, -188 Properties info -189 ) -190 throws -191 SQLException -192 { -193 return target.getPropertyInfo(url, info); -194 } -195 -196 @Override -197 public boolean jdbcCompliant() -198 { -199 return target.jdbcCompliant(); -200 } -201 -202 /** -203 * This Method cannot be annotated with @Override, becaus the plugin -204 * will not compile then under Java 1.6! -205 */ -206 public Logger getParentLogger() throws SQLFeatureNotSupportedException -207 { -208 throw new SQLFeatureNotSupportedException("Not supported, for backward-compatibility with Java 1.6"); -209 } -210 -211 @Override -212 public String toString() -213 { -214 return "Proxy: " + target; -215 } -216 -217 @Override -218 public int hashCode() -219 { -220 return target.hashCode(); -221 } -222 -223 @Override -224 public boolean equals(Object obj) -225 { -226 if (!(obj instanceof DriverProxy)) -227 return false; -228 DriverProxy other = (DriverProxy) obj; -229 return this.target.equals(other.target); -230 } -231 } -232 } --
-1 package de.juplo.plugins.hibernate; -2 -3 /* -4 * Copyright 2001-2005 The Apache Software Foundation. -5 * -6 * Licensed under the Apache License, Version 2.0 (the "License"); -7 * you may not use this file except in compliance with the License. -8 * You may obtain a copy of the License at -9 * -10 * http://www.apache.org/licenses/LICENSE-2.0 -11 * -12 * Unless required by applicable law or agreed to in writing, software -13 * distributed under the License is distributed on an "AS IS" BASIS, -14 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -15 * See the License for the specific language governing permissions and -16 * limitations under the License. -17 */ -18 -19 import java.util.Map; -20 import org.apache.maven.plugin.MojoExecutionException; -21 import org.apache.maven.plugin.MojoFailureException; -22 import org.hibernate.boot.spi.MetadataImplementor; -23 import org.hibernate.service.ServiceRegistry; -24 import org.hibernate.tool.schema.spi.ExecutionOptions; -25 import org.hibernate.tool.schema.spi.SchemaManagementTool; -26 import org.hibernate.tool.schema.spi.TargetDescriptor; -27 -28 -29 /** -30 * Generate/Execute SQL to update the database-schema according to the -31 * configured mappings. -32 * -33 * @goal update -34 * @phase process-classes -35 * @threadSafe -36 * @requiresDependencyResolution runtime -37 */ -38 public class UpdateMojo extends AbstractSchemaMojo -39 { -40 /** -41 * Output file. -42 * <p> -43 * If the specified filename is not absolut, the file will be created -44 * relative to the project build directory -45 * (<code>project.build.directory</code>). -46 * -47 * @parameter property="hibernate.schema.update" default-value="update.sql" -48 * @since 1.0 -49 */ -50 private String outputFile; -51 -52 -53 @Override -54 public final void execute() -55 throws -56 MojoFailureException, -57 MojoExecutionException -58 { -59 super.execute(outputFile); -60 } -61 -62 -63 @Override -64 void build( -65 MetadataImplementor metadata, -66 ExecutionOptions options, -67 TargetDescriptor target -68 ) -69 throws -70 MojoExecutionException, -71 MojoFailureException -72 { -73 ServiceRegistry service = -74 metadata.getMetadataBuildingOptions().getServiceRegistry(); -75 SchemaManagementTool tool = service.getService(SchemaManagementTool.class); -76 -77 Map config = options.getConfigurationValues(); -78 -79 tool.getSchemaMigrator(config).doMigration(metadata, options, target); -80 } -81 } --
Class Summary | -
---|
- AbstractSchemaMojo - | -
- CreateMojo - | -
- DriverProxy - | -
- DropMojo - | -
- HelpMojo - | -
- ModificationTracker - | -
- MutableClassLoader - | -
- SimpleConnectionProvider - | -
- UpdateMojo - | -
- You don't have frames. Go here -
- -Packages | -
---|
- de.juplo.plugins.hibernate - | -
Hbm2DdlMojo
- - |
-
Hbm2DdlMojo
- - |
-
-
-
|
-- - | -||||||||
- PREV - NEXT | -- FRAMES - NO FRAMES - - - - - | -
-de.juplo.* | -
---|
- -
de.juplo.plugins.hibernate4.Hbm2DdlMojo | -||
---|---|---|
-public static final String |
-DIALECT |
-"hibernate.dialect" |
-
-public static final String |
-DRIVER_CLASS |
-"hibernate.connection.driver_class" |
-
-public static final String |
-EXPORT_SKIPPED_PROPERTY |
-"hibernate.export.skipped" |
-
-public static final String |
-PASSWORD |
-"hibernate.connection.password" |
-
-public static final String |
-URL |
-"hibernate.connection.url" |
-
-public static final String |
-USERNAME |
-"hibernate.connection.username" |
-
- -
-
-
-
|
-- - | -||||||||
- PREV - NEXT | -- FRAMES - NO FRAMES - - - - - | -
-
-
|
-- - | -||||||||
- PREV CLASS - NEXT CLASS | -- FRAMES - NO FRAMES - - - - - | -||||||||
- SUMMARY: NESTED | FIELD | CONSTR | METHOD | --DETAIL: FIELD | CONSTR | METHOD | -
-java.lang.Object - org.apache.maven.plugin.AbstractMojo - de.juplo.plugins.hibernate4.Hbm2DdlMojo --
public class Hbm2DdlMojo
-Goal which extracts the hibernate-mapping-configuration and - exports an according SQL-database-schema. -
- -
-
-Field Summary | -|
---|---|
-static String |
-DIALECT
-
-- |
-
-static String |
-DRIVER_CLASS
-
-- |
-
-static String |
-EXPORT_SKIPPED_PROPERTY
-
-- |
-
-static String |
-PASSWORD
-
-- |
-
-static String |
-URL
-
-- |
-
-static String |
-USERNAME
-
-- |
-
Fields inherited from interface org.apache.maven.plugin.Mojo | -
---|
ROLE |
-
-Constructor Summary | -|
---|---|
Hbm2DdlMojo()
-
-- |
-
-Method Summary | -|
---|---|
- void |
-execute()
-
-- |
-
Methods inherited from class org.apache.maven.plugin.AbstractMojo | -
---|
getLog, getPluginContext, setLog, setPluginContext |
-
Methods inherited from class java.lang.Object | -
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
-
-Field Detail | -
---|
-public static final String EXPORT_SKIPPED_PROPERTY-
-public static final String DRIVER_CLASS-
-public static final String URL-
-public static final String USERNAME-
-public static final String PASSWORD-
-public static final String DIALECT-
-Constructor Detail | -
---|
-public Hbm2DdlMojo()-
-Method Detail | -
---|
-public void execute() - throws org.apache.maven.plugin.MojoFailureException, - org.apache.maven.plugin.MojoExecutionException-
org.apache.maven.plugin.MojoFailureException
-org.apache.maven.plugin.MojoExecutionException
-
-
|
-- - | -||||||||
- PREV CLASS - NEXT CLASS | -- FRAMES - NO FRAMES - - - - - | -||||||||
- SUMMARY: NESTED | FIELD | CONSTR | METHOD | --DETAIL: FIELD | CONSTR | METHOD | -
-
-
|
-- - | -||||||||
- PREV - NEXT | -- FRAMES - NO FRAMES - - - - - | -
-
-
-
|
-- - | -||||||||
- PREV - NEXT | -- FRAMES - NO FRAMES - - - - - | -
-Classes
-
- -Hbm2DdlMojo |
-
-
-
|
-- - | -||||||||
- PREV PACKAGE - NEXT PACKAGE | -- FRAMES - NO FRAMES - - - - - | -
-Class Summary | -|
---|---|
Hbm2DdlMojo | -Goal which extracts the hibernate-mapping-configuration and - exports an according SQL-database-schema. | -
-
-
-
|
-- - | -||||||||
- PREV PACKAGE - NEXT PACKAGE | -- FRAMES - NO FRAMES - - - - - | -
-
-
|
-- - | -||||||||
- PREV - NEXT | -- FRAMES - NO FRAMES - - - - - | -
-
-
|
-- - | -||||||||
- PREV - NEXT | -- FRAMES - NO FRAMES - - - - - | -
-
-
|
-- - | -||||||||
- PREV - NEXT | -- FRAMES - NO FRAMES - - - - - | -
-
-
-
|
-- - | -||||||||
- PREV - NEXT | -- FRAMES - NO FRAMES - - - - - | -
-
-
|
-- - | -||||||||
- PREV - NEXT | -- FRAMES - NO FRAMES - - - - - | -
-
-
|
-- - | -||||||||
- PREV - NEXT | -- FRAMES - NO FRAMES - - - - - | -
-
-
|
-- - | -||||||||
- PREV - NEXT | -- FRAMES - NO FRAMES - - - - - | -
- ---Each package has a page that contains a list of its classes and interfaces, with a summary for each. This page can contain four categories:
-
-- Interfaces (italic)
- Classes
- Enums
- Exceptions
- Errors
- Annotation Types
- -- --Each class, interface, nested class and nested interface has its own separate page. Each of these pages has three sections consisting of a class/interface description, summary tables, and detailed member descriptions:
-
-Each summary entry contains the first sentence from the detailed description for that item. The summary entries are alphabetical, while the detailed descriptions are in the order they appear in the source code. This preserves the logical groupings established by the programmer.- Class inheritance diagram
- Direct Subclasses
- All Known Subinterfaces
- All Known Implementing Classes
- Class/interface declaration
- Class/interface description -
-
- Nested Class Summary
- Field Summary
- Constructor Summary
- Method Summary -
-
- Field Detail
- Constructor Detail
- Method Detail
- -- --Each annotation type has its own separate page with the following sections:
-
-- Annotation Type declaration
- Annotation Type description
- Required Element Summary
- Optional Element Summary
- Element Detail
- ---Each enum has its own separate page with the following sections:
-
-- Enum declaration
- Enum description
- Enum Constant Summary
- Enum Constant Detail
-Each documented package, class and interface has its own Use page. This page describes what packages, classes, methods, constructors and fields use any part of the given class or package. Given a class or interface A, its Use page includes subclasses of A, fields declared as A, methods that return A, and methods and constructors with parameters of type A. You can access this page by first going to the package, class or interface, then clicking on the "Use" link in the navigation bar.-
-There is a Class Hierarchy page for all packages, plus a hierarchy for each package. Each hierarchy page contains a list of classes and a list of interfaces. The classes are organized by inheritance structure starting with-java.lang.Object
. The interfaces do not inherit fromjava.lang.Object
.-
-- When viewing the Overview page, clicking on "Tree" displays the hierarchy for all packages.
- When viewing a particular package, class or interface page, clicking "Tree" displays the hierarchy for only that package.
-The Deprecated API page lists all of the API that have been deprecated. A deprecated API is not recommended for use, generally due to improvements, and a replacement API is usually given. Deprecated APIs may be removed in future implementations.-
-The Index contains an alphabetic list of all classes, interfaces, constructors, methods, and fields.-
-
-
-
-
-This help file applies to API documentation generated using the standard doclet.
-
-
-
-
-
|
-- - | -||||||||
- PREV - NEXT | -- FRAMES - NO FRAMES - - - - - | -
-
-
|
-- - | -||||||||
- PREV - NEXT | -- FRAMES - NO FRAMES - - - - - | -
-
-
|
-- - | -||||||||
- PREV - NEXT | -- FRAMES - NO FRAMES - - - - - | -
-This document is designed to be viewed using the frames feature. If you see this message, you are using a non-frame-capable web client.
-
-Link toNon-frame version.
-
-
-
|
-- - | -||||||||
- PREV - NEXT | -- FRAMES - NO FRAMES - - - - - | -
-
-
|
-- - | -||||||||
- PREV - NEXT | -- FRAMES - NO FRAMES - - - - - | -
The most simple way to configure the plugin is, to put all the hibernate-configuration in a hibernate.properties-file on your classpath. Put the file in the resources-folder. Maven will put it in the class-folder of your webapp, where it will be picked up by this plugin as well as by Hibernate 4.
Doing so, the only additionally configuration needed, to activat the plugin is the following entry in the plugins-section of your pom.xml:
<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.0.1</version> - <executions> - <execution> - <goals> - <goal>export</goal> - </goals> - </execution> - </executions> -</plugin>
But be aware, that in this case the database-url, that is build in the application is the same that is used while testing, where the database is droped and recreated by the plugin. So, you should never fire up this configuration on your production system, or your database might be erased!
Hence, you should specify a different url for testing like in the following snippet:
<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.0.1</version> - <executions> - <execution> - <goals> - <goal>export</goal> - </goals> - </execution> - </executions> - <configuration> - <url><![CDATA[jdbc:mysql://localhost/test-db]]></url> - </configuration> -</plugin>
Configuration properties, that are set in the configuration-section of the plugin-configuration cannnot be overwritten elsewere (for details see Configuration-Method-Precedence). You never can overwrite them by accident when specifying a property on the commandline or in your settings.xml.
Alternatively, it is possible, to configure the plugin via maven-properties. Each relevant configuration-option has a corresponding maven-property (for a full list see the Documentation of the export-Mojo). These are named after the Hibernate JDBC Properties:
So, instead of writing the hibernate-configuration in the properties-file, like above, you could put it in the properties-section of your pom.xml.
Thogether with the plugin-definition from above, the following would be a complete configuration (again, the database-url was overwritten in the plugin-configuration, to be sure to have a separate database for testing):
<properties> - <hibernate.connection.driver_class>org.hsqldb.jdbcDriver</hibernate.connection.driver_class> - <hibernate.dialect>org.hibernate.dialect.HSQLDialect</hibernate.dialect> - <hibernate.connection.url><![CDATA[jdbc:hsqldb:res:org.my.path.production_db]]></hibernate.connection.url> - <hibernate.connection.username>sa</hibernate.connection.username> - <hibernate.connection.password></hibernate.connection.password> -</properties> - -... - -<plugins> - - ... - - <plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.0.1</version> - <executions> - <execution> - <goals> - <goal>export</goal> - </goals> - </execution> - </executions> - <configuration> - <url><![CDATA[jdbc:hsqldb:target/db/testdb;shutdown=true]]></url> - </configuration> - </plugin> - -<plugins>
A third way for configuring the plugin is the plugin-configuration. The relevant configuration-parameters are:
The equivalent of the configuration from the last section would look like this:
<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.0.1</version> - <executions> - <execution> - <goals> - <goal>export</goal> - </goals> - </execution> - </executions> - <configuration> - <driverClassName>org.hsqldb.jdbcDriver</driverClassName> - <hibernateDialect>org.hibernate.dialect.HSQLDialect</hibernateDialect> - <url><![CDATA[jdbc:hsqldb:target/db/fotos;shutdown=true]]></url> - <username>sa</username> - <password></password> - </configuration> -</plugin>
There are some seldom used parameters, that can only be configured throug this method:
For explanations, see the Documentation of the export-Mojo.
The configuration is gathered in a fix order:
If you are in doubt about where a configuration-value comes from, run maven with the debug-output enabled: mvn -X hibernate4:export and be aware, that maven-properties can be overwitten on the command-line, in your ~/.m2/settings.xml and in a profile.
The plugin-configuration comes last and overwrites everything else. That way, you can be sure, that a configuration-value, that is specified in the plugin-configuration will never be overwritten by any other configuration-method.
If you realy need to overwrite plugin-configuration-values with maven-properties, you can use maven-properties in the plugin-configuration:
<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.0.1</version> - <executions> - <execution> - <goals> - <goal>export</goal> - </goals> - </execution> - </executions> - <configuration> - <password>${my-password-property}</password> - </configuration> -</plugin>
The following document contains the results of PMD's CPD 4.3.
If you are new to hibernate4-maven-plugin, in many cases, the Configuration-Method-Precedence may be the source of configuration errors. To solve this problem, you should run maven with the debugging output enabled. For example, by executing:
mvn -X compile hibernate4:export
(The compile might be necessary, because hibernate4-maven-plugin has to scan the compiled classes for annotations!)
Unlike the majority of the maven-plugins, hibernate4-maven-plugin was designed to give a good many hints, when debugging is enabled. Because, if you do not know, what went wrong, you can't fix it!
But be warned: hibernate4-maven-plugin tends to be very chatty ;)
The following is a list of compile dependencies for this project. These dependencies are required to compile and run the application:
GroupId | ArtifactId | Version | Type |
---|---|---|---|
com.pyx4j | maven-plugin-log4j | 1.0.1 | jar |
net.sf.scannotation | scannotation | 1.0.2 | jar |
org.apache.maven | maven-core | 3.0.4 | jar |
org.apache.maven | maven-plugin-api | 3.0.4 | jar |
org.hibernate | hibernate-core | 4.1.8.Final | jar |
The following is a list of transitive dependencies for this project. Transitive dependencies are the dependencies of the project dependencies.
The following is a list of compile dependencies for this project. These dependencies are required to compile and run the application:
GroupId | ArtifactId | Version | Classifier | Type |
---|---|---|---|---|
antlr | antlr | 2.7.7 | - | jar |
dom4j | dom4j | 1.6.1 | - | jar |
javassist | javassist | 3.6.0.GA | - | jar |
log4j | log4j | 1.2.14 | - | jar |
org.apache.maven | maven-aether-provider | 3.0.4 | - | jar |
org.apache.maven | maven-artifact | 3.0.4 | - | jar |
org.apache.maven | maven-model | 3.0.4 | - | jar |
org.apache.maven | maven-model-builder | 3.0.4 | - | jar |
org.apache.maven | maven-repository-metadata | 3.0.4 | - | jar |
org.apache.maven | maven-settings | 3.0.4 | - | jar |
org.apache.maven | maven-settings-builder | 3.0.4 | - | jar |
org.codehaus.plexus | plexus-classworlds | 2.4 | - | jar |
org.codehaus.plexus | plexus-component-annotations | 1.5.5 | - | jar |
org.codehaus.plexus | plexus-interpolation | 1.14 | - | jar |
org.hibernate.common | hibernate-commons-annotations | 4.0.1.Final | - | jar |
org.hibernate.javax.persistence | hibernate-jpa-2.0-api | 1.0.1.Final | - | jar |
org.javassist | javassist | 3.15.0-GA | - | jar |
org.jboss.logging | jboss-logging | 3.1.0.GA | - | jar |
org.jboss.spec.javax.transaction | jboss-transaction-api_1.1_spec | 1.0.0.Final | - | jar |
org.sonatype.aether | aether-api | 1.13.1 | - | jar |
org.sonatype.aether | aether-impl | 1.13.1 | - | jar |
org.sonatype.aether | aether-spi | 1.13.1 | - | jar |
org.sonatype.aether | aether-util | 1.13.1 | - | jar |
org.sonatype.plexus | plexus-cipher | 1.4 | - | jar |
org.sonatype.plexus | plexus-sec-dispatcher | 1.3 | - | jar |
org.sonatype.sisu | sisu-guava | 0.9.9 | - | jar |
org.sonatype.sisu | sisu-guice | 3.1.0 | no_aop | jar |
org.sonatype.sisu | sisu-inject-bean | 2.3.0 | - | jar |
org.sonatype.sisu | sisu-inject-plexus | 2.3.0 | - | jar |
de.juplo:hibernate4-maven-plugin:maven-plugin:1.0.1
org.apache.maven:maven-core:jar:3.0.4 (compile)
org.apache.maven:maven-model:jar:3.0.4 (compile)
org.apache.maven:maven-settings:jar:3.0.4 (compile)
org.apache.maven:maven-settings-builder:jar:3.0.4 (compile)
org.codehaus.plexus:plexus-interpolation:jar:1.14 (compile)
org.codehaus.plexus:plexus-component-annotations:jar:1.5.5 (compile)
org.apache.maven:maven-settings:jar:3.0.4 (compile)
org.sonatype.plexus:plexus-sec-dispatcher:jar:1.3 (compile)
org.apache.maven:maven-repository-metadata:jar:3.0.4 (compile)
org.apache.maven:maven-artifact:jar:3.0.4 (compile)
org.apache.maven:maven-plugin-api:jar:3.0.4 (compile)
org.apache.maven:maven-model-builder:jar:3.0.4 (compile)
org.codehaus.plexus:plexus-interpolation:jar:1.14 (compile)
org.codehaus.plexus:plexus-component-annotations:jar:1.5.5 (compile)
org.apache.maven:maven-model:jar:3.0.4 (compile)
org.apache.maven:maven-aether-provider:jar:3.0.4 (compile)
org.apache.maven:maven-model:jar:3.0.4 (compile)
org.apache.maven:maven-model-builder:jar:3.0.4 (compile)
org.apache.maven:maven-repository-metadata:jar:3.0.4 (compile)
org.sonatype.aether:aether-api:jar:1.13.1 (compile)
org.sonatype.aether:aether-spi:jar:1.13.1 (compile)
org.sonatype.aether:aether-api:jar:1.13.1 (compile)
org.sonatype.aether:aether-util:jar:1.13.1 (compile)
org.sonatype.aether:aether-impl:jar:1.13.1 (compile)
org.codehaus.plexus:plexus-component-annotations:jar:1.5.5 (compile)
org.sonatype.aether:aether-impl:jar:1.13.1 (compile)
org.sonatype.aether:aether-api:jar:1.13.1 (compile)
org.sonatype.aether:aether-spi:jar:1.13.1 (compile)
org.sonatype.aether:aether-util:jar:1.13.1 (compile)
org.sonatype.aether:aether-api:jar:1.13.1 (compile)
org.sonatype.aether:aether-util:jar:1.13.1 (compile)
org.sonatype.aether:aether-api:jar:1.13.1 (compile)
org.sonatype.sisu:sisu-inject-plexus:jar:2.3.0 (compile)
org.codehaus.plexus:plexus-component-annotations:jar:1.5.5 (compile)
org.codehaus.plexus:plexus-classworlds:jar:2.4 (compile)
org.sonatype.sisu:sisu-inject-bean:jar:2.3.0 (compile)
org.sonatype.sisu:sisu-guice:jar:no_aop:3.1.0 (compile)
org.sonatype.sisu:sisu-guava:jar:0.9.9 (compile)
org.codehaus.plexus:plexus-interpolation:jar:1.14 (compile)
org.codehaus.plexus:plexus-classworlds:jar:2.4 (compile)
org.codehaus.plexus:plexus-component-annotations:jar:1.5.5 (compile)
org.sonatype.plexus:plexus-sec-dispatcher:jar:1.3 (compile)
org.sonatype.plexus:plexus-cipher:jar:1.4 (compile)
org.apache.maven:maven-plugin-api:jar:3.0.4 (compile)
org.apache.maven:maven-model:jar:3.0.4 (compile)
org.apache.maven:maven-artifact:jar:3.0.4 (compile)
org.sonatype.sisu:sisu-inject-plexus:jar:2.3.0 (compile)
org.hibernate:hibernate-core:jar:4.1.8.Final (compile)
antlr:antlr:jar:2.7.7 (compile)
org.jboss.logging:jboss-logging:jar:3.1.0.GA (compile)
org.jboss.spec.javax.transaction:jboss-transaction-api_1.1_spec:jar:1.0.0.Final (compile)
dom4j:dom4j:jar:1.6.1 (compile)
org.hibernate.javax.persistence:hibernate-jpa-2.0-api:jar:1.0.1.Final (compile)
org.javassist:javassist:jar:3.15.0-GA (compile)
org.hibernate.common:hibernate-commons-annotations:jar:4.0.1.Final (compile)
net.sf.scannotation:scannotation:jar:1.0.2 (compile)
javassist:javassist:jar:3.6.0.GA (compile)
com.pyx4j:maven-plugin-log4j:jar:1.0.1 (compile)
log4j:log4j:jar:1.2.14 (compile)
Unamed: JPA 2.0 API
Apache Public License 2.0: Plexus Cipher: encryption/decryption Component, Plexus Security Dispatcher Component
GNU LESSER GENERAL PUBLIC LICENSE: Hibernate Commons Annotations
Unknown: Unnamed - javassist:javassist:jar:3.6.0.GA, dom4j
LGPL 2.1: Javassist
MPL 1.1: Javassist
The Apache Software License, Version 2.0: Hibernate 4 Maven Plugin, Log4j, Maven Aether Provider, Maven Artifact, Maven Core, Maven Model, Maven Model Builder, Maven Plugin API, Maven Repository Metadata Model, Maven Settings, Maven Settings Builder, Plexus :: Component Annotations, Plexus Classworlds, Plexus Interpolation API, Sisu Guava - Core Library, Sisu Guice - Core Library, Sisu-Inject-Bean : Aggregate OSGi bundle, maven-plugin-log4j
GNU Lesser General Public License: A Hibernate Core Module
GNU Lesser General Public License, version 2.1: JBoss Logging 3
lgpl: Transaction 1.1 API
Apache License V2.0: scannotation
BSD License: AntLR Parser Generator
Eclipse Public License, Version 1.0: Aether :: API, Aether :: Implementation, Aether :: SPI, Aether :: Utilities, Sisu-Inject-Bean : Aggregate OSGi bundle, Sisu-Inject-Plexus : Aggregate OSGi bundle
Apache License 2.0: Javassist
Filename | Size | Entries | Classes | Packages | JDK Rev | Debug |
---|---|---|---|---|---|---|
antlr-2.7.7.jar | 434.85 kB | 239 | 224 | 12 | 1.2 | debug |
maven-plugin-log4j-1.0.1.jar | 3.64 kB | 12 | 1 | 1 | 1.4 | debug |
dom4j-1.6.1.jar | 306.54 kB | 208 | 190 | 14 | 1.3 | debug |
javassist-3.6.0.GA.jar | 529.53 kB | 323 | 305 | 16 | 1.2 | debug |
log4j-1.2.14.jar | 358.83 kB | 288 | 256 | 19 | 1.1 | debug |
scannotation-1.0.2.jar | 18.04 kB | 23 | 13 | 2 | 1.5 | debug |
maven-aether-provider-3.0.4.jar | 55.17 kB | 40 | 23 | 1 | 1.5 | debug |
maven-artifact-3.0.4.jar | 50.87 kB | 57 | 32 | 11 | 1.5 | debug |
maven-core-3.0.4.jar | 545.94 kB | 428 | 350 | 43 | 1.5 | debug |
maven-model-3.0.4.jar | 159.72 kB | 67 | 50 | 3 | 1.5 | debug |
maven-model-builder-3.0.4.jar | 147.06 kB | 142 | 109 | 16 | 1.5 | debug |
maven-plugin-api-3.0.4.jar | 48.16 kB | 46 | 25 | 6 | 1.5 | debug |
maven-repository-metadata-3.0.4.jar | 29.37 kB | 25 | 7 | 2 | 1.5 | debug |
maven-settings-3.0.4.jar | 45.57 kB | 33 | 17 | 2 | 1.5 | debug |
maven-settings-builder-3.0.4.jar | 40.41 kB | 53 | 32 | 5 | 1.5 | debug |
plexus-classworlds-2.4.jar | 45.96 kB | 52 | 37 | 5 | 1.4 | debug |
plexus-component-annotations-1.5.5.jar | 4.11 kB | 15 | 3 | 1 | 1.5 | release |
plexus-interpolation-1.14.jar | 59.64 kB | 60 | 44 | 6 | 1.4 | debug |
hibernate-core-4.1.8.Final.jar | 4.29 MB | 3,104 | 2,899 | 166 | 1.6 | debug |
hibernate-commons-annotations-4.0.1.Final.jar | 79.37 kB | 82 | 64 | 7 | 1.6 | debug |
hibernate-jpa-2.0-api-1.0.1.Final.jar | 100.25 kB | 190 | 176 | 4 | 1.5 | debug |
javassist-3.15.0-GA.jar | 633.06 kB | 391 | 367 | 17 | 1.4 | debug |
jboss-logging-3.1.0.GA.jar | 59.34 kB | 55 | 43 | 1 | 1.6 | debug |
jboss-transaction-api_1.1_spec-1.0.0.Final.jar | 10.95 kB | 28 | 18 | 2 | 1.5 | debug |
aether-api-1.13.1.jar | 87.56 kB | 116 | 96 | 11 | 1.5 | debug |
aether-impl-1.13.1.jar | 127.10 kB | 87 | 73 | 2 | 1.5 | debug |
aether-spi-1.13.1.jar | 15.07 kB | 33 | 17 | 5 | 1.5 | debug |
aether-util-1.13.1.jar | 126.98 kB | 116 | 92 | 14 | 1.5 | debug |
plexus-cipher-1.4.jar | 13.18 kB | 20 | 6 | 1 | 1.4 | debug |
plexus-sec-dispatcher-1.3.jar | 27.89 kB | 31 | 13 | 3 | 1.4 | debug |
sisu-guava-0.9.9.jar | 1.44 MB | 1,183 | 1,163 | 10 | 1.5 | debug |
sisu-guice-3.1.0-no_aop.jar | 349.05 kB | 310 | 295 | 8 | 1.5 | debug |
sisu-inject-bean-2.3.0.jar | 282.29 kB | 256 | 224 | 15 | 1.5 | debug |
sisu-inject-plexus-2.3.0.jar | 199.64 kB | 207 | 163 | 27 | 1.5 | debug |
Total | Size | Entries | Classes | Packages | JDK Rev | Debug |
34 | 10.60 MB | 8,320 | 7,427 | 458 | 1.6 | 33 |
compile: 34 | compile: 10.60 MB | compile: 8,320 | compile: 7,427 | compile: 458 | - | compile: 33 |
Repo ID | URL | Release | Snapshot |
---|---|---|---|
apache.snapshots | http://repository.apache.org/snapshots | - | Yes |
sonatype-nexus-snapshots | https://oss.sonatype.org/content/repositories/snapshots | - | Yes |
central | http://repo1.maven.org/maven2 | Yes | - |
Repository locations for each of the Dependencies.
Full name:
-de.juplo:hibernate4-maven-plugin:1.0.1:export
-Description:
-Attributes:
-Name | -Type | -Since | -Description | -
---|---|---|---|
delimiter | -String | -- | -Delimiter in output-file. Default value is: ;. User property is: hibernate.export.schema.delimiter. |
-
driverClassName | -String | -- | -SQL-Driver name. User property is: hibernate.connection.driver_class. |
-
force | -boolean | -- | -Force execution
- Force execution, even if no modified or newly added annotated -classes where found and the dialect was not changed. -skip takes precedence over force. Default value is: false. User property is: hibernate.export.force. |
-
format | -boolean | -- | -Format output-file. Default value is: true. User property is: hibernate.export.schema.format. |
-
hibernateDialect | -String | -- | -Hibernate dialect. User property is: hibernate.dialect. |
-
hibernateProperties | -String | -- | -Path to Hibernate configuration file. Default value is: ${project.build.outputDirectory}/hibernate.properties. |
-
outputDirectory | -String | -- | -Classes-Directory to scan.
- This parameter defaults to the maven build-output-directory for -classes. Additonally, all dependencies are scanned for annotated -classes. User property is: project.build.outputDirectory. |
-
outputFile | -String | -- | -Output file. Default value is: ${project.build.directory}/schema.sql. User property is: hibernate.export.schema.filename. |
-
password | -String | -- | -Database password User property is: hibernate.connection.password. |
-
scanTestClasses | -boolean | -- | -Wether to scan test-classes too, or not.
- If this parameter is set to true the test-classes -of the artifact will be scanned for hibernate-annotated classes -additionally. Default value is: false. User property is: hibernate.export.scann_testclasses. |
-
skip | -boolean | -- | -Skip execution
- If set to true, the execution is skipped. -A skipped excecution is signaled via the maven-property -${hibernate.export.skipped}. -The excecution is skipped automatically, if no modified or newly -added annotated classes are found and the dialect was not -changed. Default value is: false. User property is: maven.test.skip. |
-
target | -String | -- | -Target of execution:
-
Default value is: EXPORT. User property is: hibernate.export.target. |
-
testOutputDirectory | -String | -- | -Test-Classes-Directory to scan.
- This parameter defaults to the maven build-output-directory for -test-classes. -This parameter is only used, when scanTestClasses -is set to true! User property is: project.build.testOutputDirectory. |
-
type | -String | -- | -Type of execution.
-
Default value is: BOTH. User property is: hibernate.export.type. |
-
url | -String | -- | -Database URL. User property is: hibernate.connection.url. |
-
username | -String | -- | -Database username User property is: hibernate.connection.username. |
-
Force execution, even if no modified or newly added annotated -classes where found and the dialect was not changed.
-skip takes precedence over force.
This parameter defaults to the maven build-output-directory for -classes. Additonally, all dependencies are scanned for annotated -classes.
If this parameter is set to true the test-classes -of the artifact will be scanned for hibernate-annotated classes -additionally.
skip:
-If set to true, the execution is skipped.
-A skipped excecution is signaled via the maven-property -${hibernate.export.skipped}.
-The excecution is skipped automatically, if no modified or newly -added annotated classes are found and the dialect was not -changed.
This parameter defaults to the maven build-output-directory for -test-classes.
-This parameter is only used, when scanTestClasses -is set to true!
type:
-url:
-The hibernate4-maven-plugin computes MD5-sums for all found annotated classes and stores them together with the generated schema. If no classes were changed or added and the dialect wasn't changed too, it automatically skips the configured schema-export, to speed up the development cycle.
The plugin signals, that the execution was skipped by setting the maven property $hibernate.export.skipped to true. This may be helpful, because other plugins like dbunit-plugin may fail, when the execution is skipped.
If you need the hibernate4-maven-plugin to never skip automatically execution, you can force it to do so, if you set the parameter force to true:
<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.0.1</version> - <configuration> - <force>true</force> - </configuration> -</plugin>
Or you may specify -Dhibernate.export.force=true at the command line, if you want to force hibernate4-maven-plugin only once.
hibernate4-maven-plugin is a plugin for generating a database-schema from your Hibernate-4-Mappings and create or update your database accordingly.
The plugin was designed with three main goals in mind:
To achieve the first goal, the convention-over-configuration paradigma was applied and the plugin was stuffed with usefull logging-messages. So, if in doubt, just turn on the debugging output with the mvn -X ....
To achieve the second goal, the precedence in which the configuration locations are consulted was layouted in a way that makes it possible, to prevent overwrites of the wrong database by accident.
Last but not least, in order to not slow down the development cycle, the hibernate4-maven-plugin only executes the schema-export, if the mapping or the dialect changes (or if you force it to do so).
For more information about the inspiration to write this tiny plugin, read our blog-article about the hibernate4-maven-plugin.
Configuration for notifying developers/users when a build is unsuccessful, including user information and notification mode.
Type | Address | Configuration |
---|---|---|
kai@juplo.de | - |
Typically the licenses listed for the project are that of the project itself, and not of dependencies.
A business-friendly OSS license
- Apache License - Version 2.0, January 2004 - http://www.apache.org/licenses/ - - TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION - - 1. Definitions. - - "License" shall mean the terms and conditions for use, reproduction, - and distribution as defined by Sections 1 through 9 of this document. - - "Licensor" shall mean the copyright owner or entity authorized by - the copyright owner that is granting the License. - - "Legal Entity" shall mean the union of the acting entity and all - other entities that control, are controlled by, or are under common - control with that entity. For the purposes of this definition, - "control" means (i) the power, direct or indirect, to cause the - direction or management of such entity, whether by contract or - otherwise, or (ii) ownership of fifty percent (50%) or more of the - outstanding shares, or (iii) beneficial ownership of such entity. - - "You" (or "Your") shall mean an individual or Legal Entity - exercising permissions granted by this License. - - "Source" form shall mean the preferred form for making modifications, - including but not limited to software source code, documentation - source, and configuration files. - - "Object" form shall mean any form resulting from mechanical - transformation or translation of a Source form, including but - not limited to compiled object code, generated documentation, - and conversions to other media types. - - "Work" shall mean the work of authorship, whether in Source or - Object form, made available under the License, as indicated by a - copyright notice that is included in or attached to the work - (an example is provided in the Appendix below). - - "Derivative Works" shall mean any work, whether in Source or Object - form, that is based on (or derived from) the Work and for which the - editorial revisions, annotations, elaborations, or other modifications - represent, as a whole, an original work of authorship. For the purposes - of this License, Derivative Works shall not include works that remain - separable from, or merely link (or bind by name) to the interfaces of, - the Work and Derivative Works thereof. - - "Contribution" shall mean any work of authorship, including - the original version of the Work and any modifications or additions - to that Work or Derivative Works thereof, that is intentionally - submitted to Licensor for inclusion in the Work by the copyright owner - or by an individual or Legal Entity authorized to submit on behalf of - the copyright owner. For the purposes of this definition, "submitted" - means any form of electronic, verbal, or written communication sent - to the Licensor or its representatives, including but not limited to - communication on electronic mailing lists, source code control systems, - and issue tracking systems that are managed by, or on behalf of, the - Licensor for the purpose of discussing and improving the Work, but - excluding communication that is conspicuously marked or otherwise - designated in writing by the copyright owner as "Not a Contribution." - - "Contributor" shall mean Licensor and any individual or Legal Entity - on behalf of whom a Contribution has been received by Licensor and - subsequently incorporated within the Work. - - 2. Grant of Copyright License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - copyright license to reproduce, prepare Derivative Works of, - publicly display, publicly perform, sublicense, and distribute the - Work and such Derivative Works in Source or Object form. - - 3. Grant of Patent License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - (except as stated in this section) patent license to make, have made, - use, offer to sell, sell, import, and otherwise transfer the Work, - where such license applies only to those patent claims licensable - by such Contributor that are necessarily infringed by their - Contribution(s) alone or by combination of their Contribution(s) - with the Work to which such Contribution(s) was submitted. If You - institute patent litigation against any entity (including a - cross-claim or counterclaim in a lawsuit) alleging that the Work - or a Contribution incorporated within the Work constitutes direct - or contributory patent infringement, then any patent licenses - granted to You under this License for that Work shall terminate - as of the date such litigation is filed. - - 4. Redistribution. You may reproduce and distribute copies of the - Work or Derivative Works thereof in any medium, with or without - modifications, and in Source or Object form, provided that You - meet the following conditions: - - (a) You must give any other recipients of the Work or - Derivative Works a copy of this License; and - - (b) You must cause any modified files to carry prominent notices - stating that You changed the files; and - - (c) You must retain, in the Source form of any Derivative Works - that You distribute, all copyright, patent, trademark, and - attribution notices from the Source form of the Work, - excluding those notices that do not pertain to any part of - the Derivative Works; and - - (d) If the Work includes a "NOTICE" text file as part of its - distribution, then any Derivative Works that You distribute must - include a readable copy of the attribution notices contained - within such NOTICE file, excluding those notices that do not - pertain to any part of the Derivative Works, in at least one - of the following places: within a NOTICE text file distributed - as part of the Derivative Works; within the Source form or - documentation, if provided along with the Derivative Works; or, - within a display generated by the Derivative Works, if and - wherever such third-party notices normally appear. The contents - of the NOTICE file are for informational purposes only and - do not modify the License. You may add Your own attribution - notices within Derivative Works that You distribute, alongside - or as an addendum to the NOTICE text from the Work, provided - that such additional attribution notices cannot be construed - as modifying the License. - - You may add Your own copyright statement to Your modifications and - may provide additional or different license terms and conditions - for use, reproduction, or distribution of Your modifications, or - for any such Derivative Works as a whole, provided Your use, - reproduction, and distribution of the Work otherwise complies with - the conditions stated in this License. - - 5. Submission of Contributions. Unless You explicitly state otherwise, - any Contribution intentionally submitted for inclusion in the Work - by You to the Licensor shall be under the terms and conditions of - this License, without any additional terms or conditions. - Notwithstanding the above, nothing herein shall supersede or modify - the terms of any separate license agreement you may have executed - with Licensor regarding such Contributions. - - 6. Trademarks. This License does not grant permission to use the trade - names, trademarks, service marks, or product names of the Licensor, - except as required for reasonable and customary use in describing the - origin of the Work and reproducing the content of the NOTICE file. - - 7. Disclaimer of Warranty. Unless required by applicable law or - agreed to in writing, Licensor provides the Work (and each - Contributor provides its Contributions) on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or - implied, including, without limitation, any warranties or conditions - of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A - PARTICULAR PURPOSE. You are solely responsible for determining the - appropriateness of using or redistributing the Work and assume any - risks associated with Your exercise of permissions under this License. - - 8. Limitation of Liability. In no event and under no legal theory, - whether in tort (including negligence), contract, or otherwise, - unless required by applicable law (such as deliberate and grossly - negligent acts) or agreed to in writing, shall any Contributor be - liable to You for damages, including any direct, indirect, special, - incidental, or consequential damages of any character arising as a - result of this License or out of the use or inability to use the - Work (including but not limited to damages for loss of goodwill, - work stoppage, computer failure or malfunction, or any and all - other commercial damages or losses), even if such Contributor - has been advised of the possibility of such damages. - - 9. Accepting Warranty or Additional Liability. While redistributing - the Work or Derivative Works thereof, You may choose to offer, - and charge a fee for, acceptance of support, warranty, indemnity, - or other liability obligations and/or rights consistent with this - License. However, in accepting such obligations, You may act only - on Your own behalf and on Your sole responsibility, not on behalf - of any other Contributor, and only if You agree to indemnify, - defend, and hold each Contributor harmless for any liability - incurred by, or claims asserted against, such Contributor by reason - of your accepting any such warranty or additional liability. - - END OF TERMS AND CONDITIONS - - APPENDIX: How to apply the Apache License to your work. - - To apply the Apache License to your work, attach the following - boilerplate notice, with the fields enclosed by brackets "[]" - replaced with your own identifying information. (Don't include - the brackets!) The text should be enclosed in the appropriate - comment syntax for the file format. We also recommend that a - file or class name and description of purpose be included on the - same "printed page" as the copyright notice for easier - identification within third-party archives. - - Copyright [yyyy] [name of copyright owner] - - Licensed under the Apache License, Version 2.0 (the "License"); - you may not use this file except in compliance with the License. - You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. -
One regular problem is the scope of the jdbc-driver-dependency. It is very unlikely, that this dependency is needed at compile-time. So a tidy maven-developer would usually scope it for runtime.
But this will break the execution of the hibernate4-maven-plugin. Since it will not be able to see the needed dependency, it will fail with an error-message like:
[INFO] Gathered hibernate-configuration (turn on debugging for details): -[INFO] hibernate.connection.username = sa -[INFO] hibernate.connection.password = -[INFO] hibernate.dialect = org.hibernate.dialect.HSQLDialect -[INFO] hibernate.connection.url = jdbc:hsqldb:/home/kai/mmf/target/mmf;shutdown=true -[INFO] hibernate.connection.driver_class = org.hsqldb.jdbcDriver -[ERROR] Dependency for driver-class org.hsqldb.jdbcDriver is missing! -[INFO] ------------------------------------------------------------------------ -[ERROR] BUILD ERROR -[INFO] ------------------------------------------------------------------------ -[INFO] org.hsqldb.jdbcDriver -[INFO] ------------------------------------------------------------------------ -[INFO] For more information, run Maven with the -e switch -[INFO] ------------------------------------------------------------------------ -[INFO] Total time: 2 seconds -[INFO] Finished at: Thu Nov 29 11:31:14 CET 2012 -[INFO] Final Memory: 32M/342M -[INFO] ------------------------------------------------------------------------
A quick workaround for this error would be, to delete the runtime-constraint for the jdbc-driver-dependency.
A much cleaner way is, to (additionally) ad the dependency, to the plugin-definition:
<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.0.1</version> - <executions> - <execution> - <goals> - <goal>export</goal> - </goals> - </execution> - </executions> - <dependencies> - <dependency> - <groupId>org.hsqldb</groupId> - <artifactId>hsqldb</artifactId> - <version>2.2.8</version> - </dependency> - </dependencies> -</plugin>
This is also the best way, if you use a different jdbc-driver for testing, than in production. Because otherwise, this dependency will unnecessarily bloat the runtime-dependencies of your project.
If hibernate4-maven-plugin skips its excecution, this may lead to errors in other plugins. For example, when importing sample-data in the automatically created database with the help of the dbunit-plugin, the CLEAN_INSERT-operation may fail because of foreign-key-constraints, if the database was not recreated, because the hibernate4-maven-plugin has skipped its excecution.
A quick fix to this problem is, to force hibernate4-maven-plugin to export the schema every time it is running. But to recreate the database on every testrun may noticeable slow down your development cycle, if you have to wait for slow IO.
To circumvent this problem, hibernate4-maven-plugin signals a skipped excecution by setting the maven property $hibernate.export.skipped to true. You can configure other plugins to react on this signal. For example, the dbunit-plugin can be configured to skip its excecution, if hibernate4-maven-plugin was skipped like this:
<plugin> - <groupId>org.codehaus.mojo</groupId> - <artifactId>dbunit-maven-plugin</artifactId> - <configuration> - <skip>${hibernate.export.skipped}</skip> - </configuration> -</plugin>
Goals available for this plugin:
Goal | Description |
---|---|
hibernate4:export | Goal which extracts the hibernate-mapping-configuration and exports -an according SQL-database-schema. |
The following specifies the minimum requirements to run this Maven plugin:
Maven | 2.0.6 |
JDK | 1.6 |
Memory | No minimum requirement. |
Disk Space | No minimum requirement. |
You should specify the version in your project's plugin configuration:
<project> - ... - <build> - <!-- To define the plugin version in your parent POM --> - <pluginManagement> - <plugins> - <plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.0.1</version> - </plugin> - ... - </plugins> - </pluginManagement> - <!-- To use the plugin goals in your POM or parent POM --> - <plugins> - <plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.0.1</version> - </plugin> - ... - </plugins> - </build> - ... -</project> -
For more information, see "Guide to Configuring Plug-ins"
GroupId | ArtifactId | Version |
---|---|---|
org.apache.maven.plugins | maven-antrun-plugin | 1.6 |
org.apache.maven.plugins | maven-assembly-plugin | 2.2-beta-4 |
org.apache.maven.plugins | maven-clean-plugin | 2.3 |
org.apache.maven.plugins | maven-compiler-plugin | 2.0.2 |
org.apache.maven.plugins | maven-dependency-plugin | 2.1 |
org.apache.maven.plugins | maven-deploy-plugin | 2.4 |
org.apache.maven.plugins | maven-ear-plugin | 2.3.2 |
org.apache.maven.plugins | maven-ejb-plugin | 2.2 |
org.apache.maven.plugins | maven-install-plugin | 2.3 |
org.apache.maven.plugins | maven-jar-plugin | 2.2 |
org.apache.maven.plugins | maven-javadoc-plugin | 2.6.1 |
org.apache.maven.plugins | maven-plugin-plugin | 2.8 |
org.apache.maven.plugins | maven-rar-plugin | 2.2 |
org.apache.maven.plugins | maven-release-plugin | 2.1 |
org.apache.maven.plugins | maven-resources-plugin | 2.3 |
org.apache.maven.plugins | maven-site-plugin | 2.1 |
org.apache.maven.plugins | maven-source-plugin | 2.0.4 |
org.apache.maven.plugins | maven-surefire-plugin | 2.10 |
org.apache.maven.plugins | maven-war-plugin | 2.1.1 |
GroupId | ArtifactId | Version |
---|---|---|
org.apache.maven.plugins | maven-compiler-plugin | 2.0.2 |
org.apache.maven.plugins | maven-dependency-plugin | 2.1 |
org.apache.maven.plugins | maven-enforcer-plugin | 1.0 |
org.apache.maven.plugins | maven-resources-plugin | 2.3 |
org.apache.maven.plugins | scp://people.apache.org/www/maven.apache.org/scm/maven-scm-plugin | 1.7 |
org.apache.maven.plugins | maven-source-plugin | 2.1.2 |
GroupId | ArtifactId | Version |
---|---|---|
org.apache.maven.plugins | maven-changes-plugin | 2.7.1 |
org.apache.maven.plugins | maven-javadoc-plugin | 2.7 |
org.apache.maven.plugins | maven-jxr-plugin | 2.3 |
org.apache.maven.plugins | maven-plugin-plugin | 3.2 |
org.apache.maven.plugins | maven-pmd-plugin | 2.7.1 |
org.apache.maven.plugins | maven-site-plugin | 2.1 |
The following document contains the results of PMD 4.3.
This document provides an overview of the various documents and links that are part of this project's general information. All of this content is automatically generated by Maven on behalf of the project.
Document | Description |
---|---|
About | Plugin for generating a database-schema from Hibernate-4-Mapping-Annotations |
Continuous Integration | This is a link to the definitions of all continuous integration processes that builds and tests code on a frequent, regular basis. |
Dependencies | This document lists the project's dependencies and provides information on each dependency. |
Issue Tracking | This is a link to the issue management system for this project. Issues (bugs, features, change requests) can be created and queried using this link. |
Mailing Lists | This document provides subscription and archive information for this project's mailing lists. |
Plugin Management | This document lists the plugins that are defined through pluginManagement. |
Project License | This is a link to the definitions of project licenses. |
Project Plugins | This document lists the build plugins and the report plugins used by this project. |
Project Summary | This document lists other related information of this project |
Project Team | This document provides information on the members of this project. These are the individuals who have contributed to the project in one form or another. |
Source Repository | This is a link to the online source repository that can be viewed via a web browser. |
This document provides an overview of the various reports that are automatically generated by Maven . Each report is briefly described below.
Document | Description |
---|---|
CPD Report | Duplicate code detection. |
JavaDocs | JavaDoc API documentation. |
Plugin Documentation | This report provides goals and parameters documentation of a plugin. |
PMD Report | Verification of coding rules. |
Source Xref | HTML based, cross-reference version of Java source code. |
Field | Value |
---|---|
Name | Hibernate 4 Maven Plugin |
Description | Plugin for generating a database-schema from Hibernate-4-Mapping-Annotations |
Homepage | http://juplo.de/hibernate4-maven-plugin |
Refer to the documentation of the SCM used for more information about anonymously check out. The connection url is:
git:http://juplo.de/git/hibernate4-maven-plugin
A successful project requires many people to play many roles. Some members write code or documentation, while others are valuable as testers, submitting patches and suggestions.
The team is comprised of Members and Contributors. Members have direct access to the source of a project and actively evolve the code-base. Contributors improve the project through submission of patches and suggestions to the Members. The number of Contributors to the project is unbounded. Get involved today. All contributions to the project are greatly appreciated.
The following is a list of developers with commit privileges that have directly contributed to the project in one way or another.
Id | Name | |
---|---|---|
kai | Kai Moritz | kai@juplo.de |
- -1 package de.juplo.plugins.hibernate4; -2 -3 /* -4 * Copyright 2001-2005 The Apache Software Foundation. -5 * -6 * Licensed under the Apache License, Version 2.0 (the "License"); -7 * you may not use this file except in compliance with the License. -8 * You may obtain a copy of the License at -9 * -10 * http://www.apache.org/licenses/LICENSE-2.0 -11 * -12 * Unless required by applicable law or agreed to in writing, software -13 * distributed under the License is distributed on an "AS IS" BASIS, -14 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -15 * See the License for the specific language governing permissions and -16 * limitations under the License. -17 */ -18 -19 import com.pyx4j.log4j.MavenLogAppender; -20 import java.io.File; -21 import java.io.FileInputStream; -22 import java.io.FileOutputStream; -23 import java.io.IOException; -24 import java.io.InputStream; -25 import java.io.ObjectInputStream; -26 import java.io.ObjectOutputStream; -27 import java.math.BigInteger; -28 import java.net.URL; -29 import java.net.URLClassLoader; -30 import java.security.MessageDigest; -31 import java.sql.Connection; -32 import java.sql.Driver; -33 import java.sql.DriverManager; -34 import java.sql.DriverPropertyInfo; -35 import java.sql.SQLException; -36 import java.sql.SQLFeatureNotSupportedException; -37 import java.util.Comparator; -38 import java.util.Enumeration; -39 import java.util.HashMap; -40 import java.util.HashSet; -41 import java.util.List; -42 import java.util.Map; -43 import java.util.Map.Entry; -44 import java.util.Properties; -45 import java.util.Set; -46 import java.util.TreeSet; -47 import java.util.logging.Logger; -48 import javax.persistence.Embeddable; -49 import javax.persistence.Entity; -50 import javax.persistence.MappedSuperclass; -51 import org.apache.maven.plugin.AbstractMojo; -52 import org.apache.maven.plugin.MojoExecutionException; -53 import org.apache.maven.plugin.MojoFailureException; -54 import org.apache.maven.project.MavenProject; -55 import org.hibernate.cfg.Configuration; -56 import org.hibernate.tool.hbm2ddl.SchemaExport; -57 import org.hibernate.tool.hbm2ddl.SchemaExport.Type; -58 import org.hibernate.tool.hbm2ddl.Target; -59 import org.scannotation.AnnotationDB; -60 -61 -62 /** -63 * Goal which extracts the hibernate-mapping-configuration and -64 * exports an according SQL-database-schema. -65 * -66 * @goal export -67 * @phase process-classes -68 * @threadSafe -69 * @requiresDependencyResolution runtime -70 */ -71 public class Hbm2DdlMojo extends AbstractMojo -72 { -73 public final static String EXPORT_SKIPPED_PROPERTY = "hibernate.export.skipped"; -74 -75 public final static String DRIVER_CLASS = "hibernate.connection.driver_class"; -76 public final static String URL = "hibernate.connection.url"; -77 public final static String USERNAME = "hibernate.connection.username"; -78 public final static String PASSWORD = "hibernate.connection.password"; -79 public final static String DIALECT = "hibernate.dialect"; -80 -81 private final static String MD5S = "schema.md5s"; -82 -83 /** -84 * The maven project. -85 * <p> -86 * Only needed internally. -87 * -88 * @parameter expression="${project}" -89 * @required -90 * @readonly -91 */ -92 private MavenProject project; -93 -94 /** -95 * Build-directory. -96 * <p> -97 * Only needed internally. -98 * -99 * @parameter expression="${project.build.directory}" -100 * @required -101 * @readonly -102 */ -103 private String buildDirectory; -104 -105 /** -106 * Classes-Directory to scan. -107 * <p> -108 * This parameter defaults to the maven build-output-directory for classes. -109 * Additonally, all dependencies are scanned for annotated classes. -110 * -111 * @parameter expression="${project.build.outputDirectory}" -112 */ -113 private String outputDirectory; -114 -115 /** -116 * Wether to scan test-classes too, or not. -117 * <p> -118 * If this parameter is set to <code>true</code> the test-classes of the -119 * artifact will be scanned for hibernate-annotated classes additionally. -120 * -121 * @parameter expression="${hibernate.export.scann_testclasses}" default-value="false" -122 */ -123 private boolean scanTestClasses; -124 -125 /** -126 * Test-Classes-Directory to scan. -127 * <p> -128 * This parameter defaults to the maven build-output-directory for -129 * test-classes. -130 * <p> -131 * This parameter is only used, when <code>scanTestClasses</code> is set -132 * to <code>true</code>! -133 * -134 * @parameter expression="${project.build.testOutputDirectory}" -135 */ -136 private String testOutputDirectory; -137 -138 /** -139 * Skip execution -140 * <p> -141 * If set to <code>true</code>, the execution is skipped. -142 * <p> -143 * A skipped excecution is signaled via the maven-property -144 * <code>${hibernate.export.skipped}</code>. -145 * <p> -146 * The excecution is skipped automatically, if no modified or newly added -147 * annotated classes are found and the dialect was not changed. -148 * -149 * @parameter expression="${maven.test.skip}" default-value="false" -150 */ -151 private boolean skip; -152 -153 /** -154 * Force execution -155 * <p> -156 * Force execution, even if no modified or newly added annotated classes -157 * where found and the dialect was not changed. -158 * <p> -159 * <code>skip</code> takes precedence over <code>force</code>. -160 * -161 * @parameter expression="${hibernate.export.force}" default-value="false" -162 */ -163 private boolean force; -164 -165 /** -166 * SQL-Driver name. -167 * -168 * @parameter expression="${hibernate.connection.driver_class} -169 */ -170 private String driverClassName; -171 -172 /** -173 * Database URL. -174 * -175 * @parameter expression="${hibernate.connection.url}" -176 */ -177 private String url; -178 -179 /** -180 * Database username -181 * -182 * @parameter expression="${hibernate.connection.username}" -183 */ -184 private String username; -185 -186 /** -187 * Database password -188 * -189 * @parameter expression="${hibernate.connection.password}" -190 */ -191 private String password; -192 -193 /** -194 * Hibernate dialect. -195 * -196 * @parameter expression="${hibernate.dialect}" -197 */ -198 private String hibernateDialect; -199 -200 /** -201 * Path to Hibernate configuration file. -202 * -203 * @parameter default-value="${project.build.outputDirectory}/hibernate.properties" -204 */ -205 private String hibernateProperties; -206 -207 /** -208 * Target of execution: -209 * <ul> -210 * <li><strong>NONE</strong> do nothing - just validate the configuration (forces excecution, signals skip)</li> -211 * <li><strong>EXPORT</strong> create database (<strong>DEFAULT!</strong>. forces excecution, signals skip)</li> -212 * <li><strong>SCRIPT</strong> export schema to SQL-script</li> -213 * <li><strong>BOTH</strong></li> -214 * </ul> -215 * @parameter expression="${hibernate.export.target}" default-value="EXPORT" -216 */ -217 private String target; -218 -219 /** -220 * Type of execution. -221 * <ul> -222 * <li><strong>NONE</strong> do nothing - just validate the configuration</li> -223 * <li><strong>CREATE</strong> create database-schema</li> -224 * <li><strong>DROP</strong> drop database-schema</li> -225 * <li><strong>BOTH</strong> (<strong>DEFAULT!</strong>)</li> -226 * </ul> -227 * @parameter expression="${hibernate.export.type}" default-value="BOTH" -228 */ -229 private String type; -230 -231 /** -232 * Output file. -233 * -234 * @parameter expression="${hibernate.export.schema.filename}" default-value="${project.build.directory}/schema.sql" -235 */ -236 private String outputFile; -237 -238 /** -239 * Delimiter in output-file. -240 * -241 * @parameter expression="${hibernate.export.schema.delimiter}" default-value=";" -242 */ -243 private String delimiter; -244 -245 /** -246 * Format output-file. -247 * -248 * @parameter expression="${hibernate.export.schema.format}" default-value="true" -249 */ -250 private boolean format; -251 -252 -253 @Override -254 public void execute() -255 throws -256 MojoFailureException, -257 MojoExecutionException -258 { -259 if (skip) -260 { -261 getLog().info("Exectuion of hibernate4-maven-plugin:export was skipped!"); -262 project.getProperties().setProperty(EXPORT_SKIPPED_PROPERTY, "true"); -263 return; -264 } -265 -266 File dir = new File(outputDirectory); -267 if (!dir.exists()) -268 throw new MojoExecutionException("Cannot scan for annotated classes in " + outputDirectory + ": directory does not exist!"); -269 -270 Map<String,String> md5s; -271 boolean modified = false; -272 File saved = new File(buildDirectory + File.separator + MD5S); -273 -274 if (saved.exists()) -275 { -276 try -277 { -278 FileInputStream fis = new FileInputStream(saved); -279 ObjectInputStream ois = new ObjectInputStream(fis); -280 md5s = (HashMap<String,String>)ois.readObject(); -281 ois.close(); -282 } -283 catch (Exception e) -284 { -285 md5s = new HashMap<String,String>(); -286 getLog().warn("Cannot read timestamps from saved: " + e); -287 } -288 } -289 else -290 { -291 md5s = new HashMap<String,String>(); -292 try -293 { -294 saved.createNewFile(); -295 } -296 catch (IOException e) -297 { -298 getLog().warn("Cannot create saved for timestamps: " + e); -299 } -300 } -301 -302 ClassLoader classLoader = null; -303 try -304 { -305 getLog().debug("Creating ClassLoader for project-dependencies..."); -306 List<String> classpathFiles = project.getCompileClasspathElements(); -307 if (scanTestClasses) -308 classpathFiles.addAll(project.getTestClasspathElements()); -309 URL[] urls = new URL[classpathFiles.size()]; -310 for (int i = 0; i < classpathFiles.size(); ++i) -311 { -312 getLog().debug("Dependency: " + classpathFiles.get(i)); -313 urls[i] = new File(classpathFiles.get(i)).toURI().toURL(); -314 } -315 classLoader = new URLClassLoader(urls, getClass().getClassLoader()); -316 } -317 catch (Exception e) -318 { -319 getLog().error("Error while creating ClassLoader!", e); -320 throw new MojoExecutionException(e.getMessage()); -321 } -322 -323 Set<Class<?>> classes = -324 new TreeSet<Class<?>>( -325 new Comparator<Class<?>>() { -326 @Override -327 public int compare(Class<?> a, Class<?> b) -328 { -329 return a.getName().compareTo(b.getName()); -330 } -331 } -332 ); -333 -334 try -335 { -336 AnnotationDB db = new AnnotationDB(); -337 getLog().info("Scanning directory " + outputDirectory + " for annotated classes..."); -338 URL dirUrl = dir.toURI().toURL(); -339 db.scanArchives(dirUrl); -340 if (scanTestClasses) -341 { -342 dir = new File(testOutputDirectory); -343 if (!dir.exists()) -344 throw new MojoExecutionException("Cannot scan for annotated test-classes in " + testOutputDirectory + ": directory does not exist!"); -345 getLog().info("Scanning directory " + testOutputDirectory + " for annotated classes..."); -346 dirUrl = dir.toURI().toURL(); -347 db.scanArchives(dirUrl); -348 } -349 -350 Set<String> classNames = new HashSet<String>(); -351 if (db.getAnnotationIndex().containsKey(Entity.class.getName())) -352 classNames.addAll(db.getAnnotationIndex().get(Entity.class.getName())); -353 if (db.getAnnotationIndex().containsKey(MappedSuperclass.class.getName())) -354 classNames.addAll(db.getAnnotationIndex().get(MappedSuperclass.class.getName())); -355 if (db.getAnnotationIndex().containsKey(Embeddable.class.getName())) -356 classNames.addAll(db.getAnnotationIndex().get(Embeddable.class.getName())); -357 -358 MessageDigest digest = java.security.MessageDigest.getInstance("MD5"); -359 for (String name : classNames) -360 { -361 Class<?> annotatedClass = classLoader.loadClass(name); -362 classes.add(annotatedClass); -363 InputStream is = -364 annotatedClass -365 .getResourceAsStream(annotatedClass.getSimpleName() + ".class"); -366 byte[] buffer = new byte[1024*4]; // copy data in 4MB-chunks -367 int i; -368 while((i = is.read(buffer)) > -1) -369 digest.update(buffer, 0, i); -370 is.close(); -371 byte[] bytes = digest.digest(); -372 BigInteger bi = new BigInteger(1, bytes); -373 String newMd5 = String.format("%0" + (bytes.length << 1) + "x", bi); -374 String oldMd5 = !md5s.containsKey(name) ? "" : md5s.get(name); -375 if (!newMd5.equals(oldMd5)) -376 { -377 getLog().debug("Found new or modified annotated class: " + name); -378 modified = true; -379 md5s.put(name, newMd5); -380 } -381 else -382 { -383 getLog().debug(oldMd5 + " -> class unchanged: " + name); -384 } -385 } -386 } -387 catch (ClassNotFoundException e) -388 { -389 getLog().error("Error while adding annotated classes!", e); -390 throw new MojoExecutionException(e.getMessage()); -391 } -392 catch (Exception e) -393 { -394 getLog().error("Error while scanning!", e); -395 throw new MojoFailureException(e.getMessage()); -396 } -397 -398 if (classes.isEmpty()) -399 throw new MojoFailureException("No annotated classes found in directory " + outputDirectory); -400 -401 getLog().debug("Detected classes with mapping-annotations:"); -402 for (Class<?> annotatedClass : classes) -403 getLog().debug(" " + annotatedClass.getName()); -404 -405 -406 Properties properties = new Properties(); -407 -408 /** Try to read configuration from properties-file */ -409 try -410 { -411 File file = new File(hibernateProperties); -412 if (file.exists()) -413 { -414 getLog().info("Reading properties from file " + hibernateProperties + "..."); -415 properties.load(new FileInputStream(file)); -416 } -417 else -418 getLog().info("No hibernate-properties-file found! (Checked path: " + hibernateProperties + ")"); -419 } -420 catch (IOException e) -421 { -422 getLog().error("Error while reading properties!", e); -423 throw new MojoExecutionException(e.getMessage()); -424 } -425 -426 /** Overwrite values from propertie-file or set, if given */ -427 if (driverClassName != null) -428 { -429 if (properties.containsKey(DRIVER_CLASS)) -430 getLog().debug( -431 "Overwriting property " + -432 DRIVER_CLASS + "=" + properties.getProperty(DRIVER_CLASS) + -433 " with the value " + driverClassName -434 ); -435 else -436 getLog().debug("Using the value " + driverClassName); -437 properties.setProperty(DRIVER_CLASS, driverClassName); -438 } -439 if (url != null) -440 { -441 if (properties.containsKey(URL)) -442 getLog().debug( -443 "Overwriting property " + -444 URL + "=" + properties.getProperty(URL) + -445 " with the value " + url -446 ); -447 else -448 getLog().debug("Using the value " + url); -449 properties.setProperty(URL, url); -450 } -451 if (username != null) -452 { -453 if (properties.containsKey(USERNAME)) -454 getLog().debug( -455 "Overwriting property " + -456 USERNAME + "=" + properties.getProperty(USERNAME) + -457 " with the value " + username -458 ); -459 else -460 getLog().debug("Using the value " + username); -461 properties.setProperty(USERNAME, username); -462 } -463 if (password != null) -464 { -465 if (properties.containsKey(PASSWORD)) -466 getLog().debug( -467 "Overwriting property " + -468 PASSWORD + "=" + properties.getProperty(PASSWORD) + -469 " with the value " + password -470 ); -471 else -472 getLog().debug("Using the value " + password); -473 properties.setProperty(PASSWORD, password); -474 } -475 if (hibernateDialect != null) -476 { -477 if (properties.containsKey(DIALECT)) -478 getLog().debug( -479 "Overwriting property " + -480 DIALECT + "=" + properties.getProperty(DIALECT) + -481 " with the value " + hibernateDialect -482 ); -483 else -484 getLog().debug("Using the value " + hibernateDialect); -485 properties.setProperty(DIALECT, hibernateDialect); -486 } -487 -488 /** The generated SQL varies with the dialect! */ -489 if (md5s.containsKey(DIALECT)) -490 { -491 String dialect = properties.getProperty(DIALECT); -492 if (md5s.get(DIALECT).equals(dialect)) -493 getLog().debug("SQL-dialect unchanged."); -494 else -495 { -496 getLog().debug("SQL-dialect changed: " + dialect); -497 modified = true; -498 md5s.put(DIALECT, dialect); -499 } -500 } -501 else -502 { -503 modified = true; -504 md5s.put(DIALECT, properties.getProperty(DIALECT)); -505 } -506 -507 if (properties.isEmpty()) -508 { -509 getLog().error("No properties set!"); -510 throw new MojoFailureException("Hibernate-Configuration is missing!"); -511 } -512 -513 Configuration config = new Configuration(); -514 config.setProperties(properties); -515 getLog().debug("Adding annotated classes to hibernate-mapping-configuration..."); -516 for (Class<?> annotatedClass : classes) -517 { -518 getLog().debug("Class " + annotatedClass); -519 config.addAnnotatedClass(annotatedClass); -520 } -521 -522 Target target = null; -523 try -524 { -525 target = Target.valueOf(this.target.toUpperCase()); -526 } -527 catch (IllegalArgumentException e) -528 { -529 getLog().error("Invalid value for configuration-option \"target\": " + this.target); -530 getLog().error("Valid values are: NONE, SCRIPT, EXPORT, BOTH"); -531 throw new MojoExecutionException("Invalid value for configuration-option \"target\""); -532 } -533 Type type = null; -534 try -535 { -536 type = Type.valueOf(this.type.toUpperCase()); -537 } -538 catch (IllegalArgumentException e) -539 { -540 getLog().error("Invalid value for configuration-option \"type\": " + this.type); -541 getLog().error("Valid values are: NONE, CREATE, DROP, BOTH"); -542 throw new MojoExecutionException("Invalid value for configuration-option \"type\""); -543 } -544 -545 if (target.equals(Target.SCRIPT) || target.equals(Target.NONE)) -546 { -547 project.getProperties().setProperty(EXPORT_SKIPPED_PROPERTY, "true"); -548 } -549 if ( -550 !modified -551 && !target.equals(Target.SCRIPT) -552 && !target.equals(Target.NONE) -553 && !force -554 ) -555 { -556 getLog().info("No modified annotated classes found and dialect unchanged."); -557 getLog().info("Skipping schema generation!"); -558 project.getProperties().setProperty(EXPORT_SKIPPED_PROPERTY, "true"); -559 return; -560 } -561 -562 getLog().info("Gathered hibernate-configuration (turn on debugging for details):"); -563 for (Entry<Object,Object> entry : properties.entrySet()) -564 getLog().info(" " + entry.getKey() + " = " + entry.getValue()); -565 -566 Connection connection = null; -567 try -568 { -569 /** -570 * The connection must be established outside of hibernate, because -571 * hibernate does not use the context-classloader of the current -572 * thread and, hence, would not be able to resolve the driver-class! -573 */ -574 switch (target) -575 { -576 case EXPORT: -577 case BOTH: -578 switch (type) -579 { -580 case CREATE: -581 case DROP: -582 case BOTH: -583 Class driverClass = classLoader.loadClass(properties.getProperty(DRIVER_CLASS)); -584 getLog().debug("Registering JDBC-driver " + driverClass.getName()); -585 DriverManager.registerDriver(new DriverProxy((Driver)driverClass.newInstance())); -586 getLog().debug( -587 "Opening JDBC-connection to " -588 + properties.getProperty(URL) -589 + " as " -590 + properties.getProperty(USERNAME) -591 + " with password " -592 + properties.getProperty(PASSWORD) -593 ); -594 connection = DriverManager.getConnection( -595 properties.getProperty(URL), -596 properties.getProperty(USERNAME), -597 properties.getProperty(PASSWORD) -598 ); -599 } -600 } -601 } -602 catch (ClassNotFoundException e) -603 { -604 getLog().error("Dependency for driver-class " + properties.getProperty(DRIVER_CLASS) + " is missing!"); -605 throw new MojoExecutionException(e.getMessage()); -606 } -607 catch (Exception e) -608 { -609 getLog().error("Cannot establish connection to database!"); -610 Enumeration<Driver> drivers = DriverManager.getDrivers(); -611 if (!drivers.hasMoreElements()) -612 getLog().error("No drivers registered!"); -613 while (drivers.hasMoreElements()) -614 getLog().debug("Driver: " + drivers.nextElement()); -615 throw new MojoExecutionException(e.getMessage()); -616 } -617 -618 ClassLoader contextClassLoader = Thread.currentThread().getContextClassLoader(); -619 MavenLogAppender.startPluginLog(this); -620 try -621 { -622 /** -623 * Change class-loader of current thread, so that hibernate can -624 * see all dependencies! -625 */ -626 Thread.currentThread().setContextClassLoader(classLoader); -627 -628 SchemaExport export = new SchemaExport(config, connection); -629 export.setOutputFile(outputFile); -630 export.setDelimiter(delimiter); -631 export.setFormat(format); -632 export.execute(target, type); -633 -634 for (Object exception : export.getExceptions()) -635 getLog().debug(exception.toString()); -636 } -637 finally -638 { -639 /** Stop Log-Capturing */ -640 MavenLogAppender.endPluginLog(this); -641 -642 /** Restore the old class-loader (TODO: is this really necessary?) */ -643 Thread.currentThread().setContextClassLoader(contextClassLoader); -644 -645 /** Close the connection */ -646 try -647 { -648 if (connection != null) -649 connection.close(); -650 } -651 catch (SQLException e) -652 { -653 getLog().error("Error while closing connection: " + e.getMessage()); -654 } -655 } -656 -657 /** Write md5-sums for annotated classes to file */ -658 try -659 { -660 FileOutputStream fos = new FileOutputStream(saved); -661 ObjectOutputStream oos = new ObjectOutputStream(fos); -662 oos.writeObject(md5s); -663 oos.close(); -664 fos.close(); -665 } -666 catch (Exception e) -667 { -668 getLog().error("Cannot write md5-sums to file: " + e); -669 } -670 } -671 -672 /** -673 * Needed, because DriverManager won't pick up drivers, that were not -674 * loaded by the system-classloader! -675 * See: -676 * http://stackoverflow.com/questions/288828/how-to-use-a-jdbc-driver-fromodifiedm-an-arbitrary-location -677 */ -678 static final class DriverProxy implements Driver -679 { -680 private final Driver target; -681 -682 DriverProxy(Driver target) -683 { -684 if (target == null) -685 throw new NullPointerException(); -686 this.target = target; -687 } -688 -689 public java.sql.Driver getTarget() -690 { -691 return target; -692 } -693 -694 @Override -695 public boolean acceptsURL(String url) throws SQLException -696 { -697 return target.acceptsURL(url); -698 } -699 -700 @Override -701 public java.sql.Connection connect( -702 String url, -703 java.util.Properties info -704 ) -705 throws -706 SQLException -707 { -708 return target.connect(url, info); -709 } -710 -711 @Override -712 public int getMajorVersion() -713 { -714 return target.getMajorVersion(); -715 } -716 -717 @Override -718 public int getMinorVersion() -719 { -720 return target.getMinorVersion(); -721 } -722 -723 @Override -724 public DriverPropertyInfo[] getPropertyInfo( -725 String url, -726 Properties info -727 ) -728 throws -729 SQLException -730 { -731 return target.getPropertyInfo(url, info); -732 } -733 -734 @Override -735 public boolean jdbcCompliant() -736 { -737 return target.jdbcCompliant(); -738 } -739 -740 /** -741 * This Method cannot be annotated with @Override, becaus the plugin -742 * will not compile then under Java 1.6! -743 */ -744 public Logger getParentLogger() throws SQLFeatureNotSupportedException -745 { -746 throw new SQLFeatureNotSupportedException("Not supported, for backward-compatibility with Java 1.6"); -747 } -748 -749 @Override -750 public String toString() -751 { -752 return "Proxy: " + target; -753 } -754 -755 @Override -756 public int hashCode() -757 { -758 return target.hashCode(); -759 } -760 -761 @Override -762 public boolean equals(Object obj) -763 { -764 if (!(obj instanceof DriverProxy)) -765 return false; -766 DriverProxy other = (DriverProxy) obj; -767 return this.target.equals(other.target); -768 } -769 } -770 } --
Class Summary | -
---|
- DriverProxy - | -
- Hbm2DdlMojo - | -
- You don't have frames. Go here -
- -Packages | -
---|
- de.juplo.plugins.hibernate4 - | -
Modifier and Type | -Constant Field | -Value | -
---|---|---|
-
-public static final String |
-DIALECT |
-"hibernate.dialect" |
-
-
-public static final String |
-DRIVER_CLASS |
-"hibernate.connection.driver_class" |
-
-
-public static final String |
-EXPORT_SKIPPED_PROPERTY |
-"hibernate.export.skipped" |
-
-
-public static final String |
-NAMING_STRATEGY |
-"hibernate.ejb.naming_strategy" |
-
-
-public static final String |
-PASSWORD |
-"hibernate.connection.password" |
-
-
-public static final String |
-URL |
-"hibernate.connection.url" |
-
-
-public static final String |
-USERNAME |
-"hibernate.connection.username" |
-
Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.2/apidocs/de/juplo/plugins/hibernate4/Hbm2DdlMojo.html b/dist/hibernate4-maven-plugin-1.0.2/apidocs/de/juplo/plugins/hibernate4/Hbm2DdlMojo.html deleted file mode 100644 index 324e5d70..00000000 --- a/dist/hibernate4-maven-plugin-1.0.2/apidocs/de/juplo/plugins/hibernate4/Hbm2DdlMojo.html +++ /dev/null @@ -1,407 +0,0 @@ - - - - - - -public class Hbm2DdlMojo
-extends org.apache.maven.plugin.AbstractMojo
-Modifier and Type | -Field and Description | -
---|---|
static String |
-DIALECT |
-
static String |
-DRIVER_CLASS |
-
static String |
-EXPORT_SKIPPED_PROPERTY |
-
static String |
-NAMING_STRATEGY |
-
static String |
-PASSWORD |
-
static String |
-URL |
-
static String |
-USERNAME |
-
ROLE
Constructor and Description | -
---|
Hbm2DdlMojo() |
-
public static final String EXPORT_SKIPPED_PROPERTY-
public static final String DRIVER_CLASS-
public static final String URL-
public static final String USERNAME-
public static final String PASSWORD-
public static final String DIALECT-
public static final String NAMING_STRATEGY-
Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.2/apidocs/de/juplo/plugins/hibernate4/HelpMojo.html b/dist/hibernate4-maven-plugin-1.0.2/apidocs/de/juplo/plugins/hibernate4/HelpMojo.html deleted file mode 100644 index 88c2a06a..00000000 --- a/dist/hibernate4-maven-plugin-1.0.2/apidocs/de/juplo/plugins/hibernate4/HelpMojo.html +++ /dev/null @@ -1,296 +0,0 @@ - - - - - - -public class HelpMojo
-extends org.apache.maven.plugin.AbstractMojo
-mvn hibernate4:help -Ddetail=true -Dgoal=<goal-name>
to display parameter details.ROLE
Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.2/apidocs/de/juplo/plugins/hibernate4/ValidationConfiguration.html b/dist/hibernate4-maven-plugin-1.0.2/apidocs/de/juplo/plugins/hibernate4/ValidationConfiguration.html deleted file mode 100644 index 9ce78a40..00000000 --- a/dist/hibernate4-maven-plugin-1.0.2/apidocs/de/juplo/plugins/hibernate4/ValidationConfiguration.html +++ /dev/null @@ -1,323 +0,0 @@ - - - - - - -public class ValidationConfiguration
-extends org.hibernate.cfg.Configuration
-org.hibernate.cfg.Configuration.MappingsImpl, org.hibernate.cfg.Configuration.MetadataSourceQueue
ARTEFACT_PROCESSING_ORDER, auxiliaryDatabaseObjects, classes, collections, columnNameBindingPerTable, DEFAULT_ARTEFACT_PROCESSING_ORDER, DEFAULT_CACHE_CONCURRENCY_STRATEGY, extendsQueue, fetchProfiles, filterDefinitions, imports, metadataSourceQueue, namedEntityGraphMap, namedProcedureCallMap, namedQueries, namedSqlQueries, namingStrategy, propertyReferences, secondPasses, settingsFactory, sqlFunctions, sqlResultSetMappings, tableNameBinding, tables, typeDefs, USE_NEW_ID_GENERATOR_MAPPINGS, xmlHelper
Constructor and Description | -
---|
ValidationConfiguration(String dialectClass) |
-
Modifier and Type | -Method and Description | -
---|---|
protected void |
-secondPassCompile() |
-
add, addAnnotatedClass, addAttributeConverter, addAttributeConverter, addAttributeConverter, addAttributeConverter, addAttributeConverter, addAuxiliaryDatabaseObject, addCacheableFile, addCacheableFile, addCacheableFileStrictly, addClass, addDirectory, addDocument, addFetchProfile, addFile, addFile, addFilterDefinition, addInputStream, addJar, addPackage, addProperties, addResource, addResource, addSqlFunction, addURL, addXML, buildMapping, buildMappings, buildSessionFactory, buildSessionFactory, buildSettings, buildSettings, configure, configure, configure, configure, configure, createMappings, doConfigure, doConfigure, findPossibleExtends, generateDropSchemaScript, generateSchemaCreationScript, generateSchemaUpdateScript, generateSchemaUpdateScriptList, getClassMapping, getClassMappings, getCollectionMapping, getCollectionMappings, getConfigurationInputStream, getCurrentTenantIdentifierResolver, getEntityNotFoundDelegate, getEntityResolver, getEntityTuplizerFactory, getFilterDefinitions, getIdentifierGeneratorFactory, getImports, getInterceptor, getJaccPermissionDeclarations, getMappedSuperclassMappings, getMappedSuperclassMappingsCopy, getNamedEntityGraphs, getNamedProcedureCallMap, getNamedQueries, getNamedSQLQueries, getNamingStrategy, getProperties, getProperty, getReflectionManager, getSessionFactoryObserver, getSqlFunctions, getSqlResultSetMappings, getTableMappings, getTypeResolver, iterateFetchProfiles, iterateGenerators, mergeProperties, registerTypeContributor, registerTypeOverride, registerTypeOverride, registerTypeOverride, reset, secondPassCompileForeignKeys, setCacheConcurrencyStrategy, setCacheConcurrencyStrategy, setCacheConcurrencyStrategy, setCollectionCacheConcurrencyStrategy, setCollectionCacheConcurrencyStrategy, setCurrentTenantIdentifierResolver, setEntityNotFoundDelegate, setEntityResolver, setInterceptor, setNamingStrategy, setPrecedence, setProperties, setProperty, setSessionFactoryObserver, validateSchema
Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.2/apidocs/de/juplo/plugins/hibernate4/class-use/Hbm2DdlMojo.html b/dist/hibernate4-maven-plugin-1.0.2/apidocs/de/juplo/plugins/hibernate4/class-use/Hbm2DdlMojo.html deleted file mode 100644 index 6d632fc9..00000000 --- a/dist/hibernate4-maven-plugin-1.0.2/apidocs/de/juplo/plugins/hibernate4/class-use/Hbm2DdlMojo.html +++ /dev/null @@ -1,115 +0,0 @@ - - - - - - -Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.2/apidocs/de/juplo/plugins/hibernate4/class-use/HelpMojo.html b/dist/hibernate4-maven-plugin-1.0.2/apidocs/de/juplo/plugins/hibernate4/class-use/HelpMojo.html deleted file mode 100644 index 8d5d5fc3..00000000 --- a/dist/hibernate4-maven-plugin-1.0.2/apidocs/de/juplo/plugins/hibernate4/class-use/HelpMojo.html +++ /dev/null @@ -1,115 +0,0 @@ - - - - - - -Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.2/apidocs/de/juplo/plugins/hibernate4/class-use/ValidationConfiguration.html b/dist/hibernate4-maven-plugin-1.0.2/apidocs/de/juplo/plugins/hibernate4/class-use/ValidationConfiguration.html deleted file mode 100644 index 52ed8cbe..00000000 --- a/dist/hibernate4-maven-plugin-1.0.2/apidocs/de/juplo/plugins/hibernate4/class-use/ValidationConfiguration.html +++ /dev/null @@ -1,117 +0,0 @@ - - - - - - -Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.2/apidocs/de/juplo/plugins/hibernate4/package-frame.html b/dist/hibernate4-maven-plugin-1.0.2/apidocs/de/juplo/plugins/hibernate4/package-frame.html deleted file mode 100644 index 2dc5827b..00000000 --- a/dist/hibernate4-maven-plugin-1.0.2/apidocs/de/juplo/plugins/hibernate4/package-frame.html +++ /dev/null @@ -1,21 +0,0 @@ - - - - - - -Class | -Description | -
---|---|
Hbm2DdlMojo | -
- Goal which extracts the hibernate-mapping-configuration and
- exports an according SQL-database-schema.
- |
-
HelpMojo | -
- Display help information on hibernate4-maven-plugin.
- |
-
Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.2/apidocs/de/juplo/plugins/hibernate4/package-tree.html b/dist/hibernate4-maven-plugin-1.0.2/apidocs/de/juplo/plugins/hibernate4/package-tree.html deleted file mode 100644 index 5228d3af..00000000 --- a/dist/hibernate4-maven-plugin-1.0.2/apidocs/de/juplo/plugins/hibernate4/package-tree.html +++ /dev/null @@ -1,129 +0,0 @@ - - - - - - -Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.2/apidocs/de/juplo/plugins/hibernate4/package-use.html b/dist/hibernate4-maven-plugin-1.0.2/apidocs/de/juplo/plugins/hibernate4/package-use.html deleted file mode 100644 index 89f028fe..00000000 --- a/dist/hibernate4-maven-plugin-1.0.2/apidocs/de/juplo/plugins/hibernate4/package-use.html +++ /dev/null @@ -1,115 +0,0 @@ - - - - - - -Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.2/apidocs/deprecated-list.html b/dist/hibernate4-maven-plugin-1.0.2/apidocs/deprecated-list.html deleted file mode 100644 index 2a9dc313..00000000 --- a/dist/hibernate4-maven-plugin-1.0.2/apidocs/deprecated-list.html +++ /dev/null @@ -1,115 +0,0 @@ - - - - - - -Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.2/apidocs/help-doc.html b/dist/hibernate4-maven-plugin-1.0.2/apidocs/help-doc.html deleted file mode 100644 index 83ed1bd3..00000000 --- a/dist/hibernate4-maven-plugin-1.0.2/apidocs/help-doc.html +++ /dev/null @@ -1,216 +0,0 @@ - - - - - - -Each package has a page that contains a list of its classes and interfaces, with a summary for each. This page can contain six categories:
-Each class, interface, nested class and nested interface has its own separate page. Each of these pages has three sections consisting of a class/interface description, summary tables, and detailed member descriptions:
-Each summary entry contains the first sentence from the detailed description for that item. The summary entries are alphabetical, while the detailed descriptions are in the order they appear in the source code. This preserves the logical groupings established by the programmer.
-Each annotation type has its own separate page with the following sections:
-Each enum has its own separate page with the following sections:
-Each documented package, class and interface has its own Use page. This page describes what packages, classes, methods, constructors and fields use any part of the given class or package. Given a class or interface A, its Use page includes subclasses of A, fields declared as A, methods that return A, and methods and constructors with parameters of type A. You can access this page by first going to the package, class or interface, then clicking on the "Use" link in the navigation bar.
-There is a Class Hierarchy page for all packages, plus a hierarchy for each package. Each hierarchy page contains a list of classes and a list of interfaces. The classes are organized by inheritance structure starting with java.lang.Object
. The interfaces do not inherit from java.lang.Object
.
The Deprecated API page lists all of the API that have been deprecated. A deprecated API is not recommended for use, generally due to improvements, and a replacement API is usually given. Deprecated APIs may be removed in future implementations.
-The Index contains an alphabetic list of all classes, interfaces, constructors, methods, and fields.
-These links take you to the next or previous class, interface, package, or related page.
-These links show and hide the HTML frames. All pages are available with or without frames.
-The All Classes link shows all classes and interfaces except non-static nested types.
-Each serializable or externalizable class has a description of its serialization fields and methods. This information is of interest to re-implementors, not to developers using the API. While there is no link in the navigation bar, you can get to this information by going to any serialized class and clicking "Serialized Form" in the "See also" section of the class description.
-The Constant Field Values page lists the static final fields and their values.
-Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.2/apidocs/index-all.html b/dist/hibernate4-maven-plugin-1.0.2/apidocs/index-all.html deleted file mode 100644 index daa5d048..00000000 --- a/dist/hibernate4-maven-plugin-1.0.2/apidocs/index-all.html +++ /dev/null @@ -1,180 +0,0 @@ - - - - - - -Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.2/apidocs/index.html b/dist/hibernate4-maven-plugin-1.0.2/apidocs/index.html deleted file mode 100644 index 649cf18b..00000000 --- a/dist/hibernate4-maven-plugin-1.0.2/apidocs/index.html +++ /dev/null @@ -1,65 +0,0 @@ - - - - - - -This document is designed to be viewed using the frames feature. If you see this message, you are using a non-frame-capable web client. Link to Non-frame version.
-public class TypeSafeActivatorAccessor -extends Object-
TypeSafeActivator
- which itself is visible in the package only.Constructor and Description | -
---|
TypeSafeActivatorAccessor() |
-
Modifier and Type | -Method and Description | -
---|---|
static void |
-activate(org.hibernate.cfg.beanvalidation.ActivationContext arg0) |
-
static void |
-applyCallbackListeners(javax.validation.ValidatorFactory arg0,
- org.hibernate.cfg.beanvalidation.ActivationContext arg1) |
-
static void |
-applyRelationalConstraints(javax.validation.ValidatorFactory arg0,
- Collection<org.hibernate.mapping.PersistentClass> arg1,
- Properties arg2,
- org.hibernate.dialect.Dialect arg3) |
-
static void |
-validateSuppliedFactory(Object arg0) |
-
public TypeSafeActivatorAccessor()-
public static void validateSuppliedFactory(Object arg0)-
public static void activate(org.hibernate.cfg.beanvalidation.ActivationContext arg0)-
public static void applyCallbackListeners(javax.validation.ValidatorFactory arg0, - org.hibernate.cfg.beanvalidation.ActivationContext arg1)-
public static void applyRelationalConstraints(javax.validation.ValidatorFactory arg0, - Collection<org.hibernate.mapping.PersistentClass> arg1, - Properties arg2, - org.hibernate.dialect.Dialect arg3)-
Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.2/apidocs/org/hibernate/cfg/beanvalidation/class-use/TypeSafeActivatorAccessor.html b/dist/hibernate4-maven-plugin-1.0.2/apidocs/org/hibernate/cfg/beanvalidation/class-use/TypeSafeActivatorAccessor.html deleted file mode 100644 index ecafb368..00000000 --- a/dist/hibernate4-maven-plugin-1.0.2/apidocs/org/hibernate/cfg/beanvalidation/class-use/TypeSafeActivatorAccessor.html +++ /dev/null @@ -1,117 +0,0 @@ - - - - - - -Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.2/apidocs/org/hibernate/cfg/beanvalidation/package-frame.html b/dist/hibernate4-maven-plugin-1.0.2/apidocs/org/hibernate/cfg/beanvalidation/package-frame.html deleted file mode 100644 index 5e7f7ebb..00000000 --- a/dist/hibernate4-maven-plugin-1.0.2/apidocs/org/hibernate/cfg/beanvalidation/package-frame.html +++ /dev/null @@ -1,20 +0,0 @@ - - - - - - -Class | -Description | -
---|---|
TypeSafeActivatorAccessor | -
- This class enables access to the public methods of
-TypeSafeActivator
- which itself is visible in the package only. |
-
Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.2/apidocs/org/hibernate/cfg/beanvalidation/package-tree.html b/dist/hibernate4-maven-plugin-1.0.2/apidocs/org/hibernate/cfg/beanvalidation/package-tree.html deleted file mode 100644 index 4a8c2fb4..00000000 --- a/dist/hibernate4-maven-plugin-1.0.2/apidocs/org/hibernate/cfg/beanvalidation/package-tree.html +++ /dev/null @@ -1,130 +0,0 @@ - - - - - - -Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.2/apidocs/org/hibernate/cfg/beanvalidation/package-use.html b/dist/hibernate4-maven-plugin-1.0.2/apidocs/org/hibernate/cfg/beanvalidation/package-use.html deleted file mode 100644 index 5ccb8924..00000000 --- a/dist/hibernate4-maven-plugin-1.0.2/apidocs/org/hibernate/cfg/beanvalidation/package-use.html +++ /dev/null @@ -1,117 +0,0 @@ - - - - - - -Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.2/apidocs/overview-frame.html b/dist/hibernate4-maven-plugin-1.0.2/apidocs/overview-frame.html deleted file mode 100644 index 54c43fc1..00000000 --- a/dist/hibernate4-maven-plugin-1.0.2/apidocs/overview-frame.html +++ /dev/null @@ -1,22 +0,0 @@ - - - - - - -- - diff --git a/dist/hibernate4-maven-plugin-1.0.2/apidocs/overview-summary.html b/dist/hibernate4-maven-plugin-1.0.2/apidocs/overview-summary.html deleted file mode 100644 index 82119cf8..00000000 --- a/dist/hibernate4-maven-plugin-1.0.2/apidocs/overview-summary.html +++ /dev/null @@ -1,135 +0,0 @@ - - - - - - -
Package | -Description | -
---|---|
de.juplo.plugins.hibernate4 | -- |
org.hibernate.cfg.beanvalidation | -- |
Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.2/apidocs/overview-tree.html b/dist/hibernate4-maven-plugin-1.0.2/apidocs/overview-tree.html deleted file mode 100644 index 99598582..00000000 --- a/dist/hibernate4-maven-plugin-1.0.2/apidocs/overview-tree.html +++ /dev/null @@ -1,133 +0,0 @@ - - - - - - -Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.2/apidocs/package-list b/dist/hibernate4-maven-plugin-1.0.2/apidocs/package-list deleted file mode 100644 index 05307714..00000000 --- a/dist/hibernate4-maven-plugin-1.0.2/apidocs/package-list +++ /dev/null @@ -1 +0,0 @@ -de.juplo.plugins.hibernate4 diff --git a/dist/hibernate4-maven-plugin-1.0.2/apidocs/packages b/dist/hibernate4-maven-plugin-1.0.2/apidocs/packages deleted file mode 100644 index c4b51407..00000000 --- a/dist/hibernate4-maven-plugin-1.0.2/apidocs/packages +++ /dev/null @@ -1 +0,0 @@ -de.juplo.plugins.hibernate4 \ No newline at end of file diff --git a/dist/hibernate4-maven-plugin-1.0.2/apidocs/resources/background.gif b/dist/hibernate4-maven-plugin-1.0.2/apidocs/resources/background.gif deleted file mode 100644 index f471940f..00000000 Binary files a/dist/hibernate4-maven-plugin-1.0.2/apidocs/resources/background.gif and /dev/null differ diff --git a/dist/hibernate4-maven-plugin-1.0.2/apidocs/resources/tab.gif b/dist/hibernate4-maven-plugin-1.0.2/apidocs/resources/tab.gif deleted file mode 100644 index 1a73a83b..00000000 Binary files a/dist/hibernate4-maven-plugin-1.0.2/apidocs/resources/tab.gif and /dev/null differ diff --git a/dist/hibernate4-maven-plugin-1.0.2/apidocs/resources/titlebar.gif b/dist/hibernate4-maven-plugin-1.0.2/apidocs/resources/titlebar.gif deleted file mode 100644 index 17443b3e..00000000 Binary files a/dist/hibernate4-maven-plugin-1.0.2/apidocs/resources/titlebar.gif and /dev/null differ diff --git a/dist/hibernate4-maven-plugin-1.0.2/apidocs/resources/titlebar_end.gif b/dist/hibernate4-maven-plugin-1.0.2/apidocs/resources/titlebar_end.gif deleted file mode 100644 index 3ad78d46..00000000 Binary files a/dist/hibernate4-maven-plugin-1.0.2/apidocs/resources/titlebar_end.gif and /dev/null differ diff --git a/dist/hibernate4-maven-plugin-1.0.2/apidocs/serialized-form.html b/dist/hibernate4-maven-plugin-1.0.2/apidocs/serialized-form.html deleted file mode 100644 index c5e20ffd..00000000 --- a/dist/hibernate4-maven-plugin-1.0.2/apidocs/serialized-form.html +++ /dev/null @@ -1,187 +0,0 @@ - - - - - - -javax.validation.ValidatorFactory factory-
ConcurrentHashMap<K,V> associationsPerEntityPersister-
org.hibernate.cfg.beanvalidation.GroupsPerOperation groupsPerOperation-
boolean initialized-
Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.2/apidocs/stylesheet.css b/dist/hibernate4-maven-plugin-1.0.2/apidocs/stylesheet.css deleted file mode 100644 index 0aeaa97f..00000000 --- a/dist/hibernate4-maven-plugin-1.0.2/apidocs/stylesheet.css +++ /dev/null @@ -1,474 +0,0 @@ -/* Javadoc style sheet */ -/* -Overall document style -*/ -body { - background-color:#ffffff; - color:#353833; - font-family:Arial, Helvetica, sans-serif; - font-size:76%; - margin:0; -} -a:link, a:visited { - text-decoration:none; - color:#4c6b87; -} -a:hover, a:focus { - text-decoration:none; - color:#bb7a2a; -} -a:active { - text-decoration:none; - color:#4c6b87; -} -a[name] { - color:#353833; -} -a[name]:hover { - text-decoration:none; - color:#353833; -} -pre { - font-size:1.3em; -} -h1 { - font-size:1.8em; -} -h2 { - font-size:1.5em; -} -h3 { - font-size:1.4em; -} -h4 { - font-size:1.3em; -} -h5 { - font-size:1.2em; -} -h6 { - font-size:1.1em; -} -ul { - list-style-type:disc; -} -code, tt { - font-size:1.2em; -} -dt code { - font-size:1.2em; -} -table tr td dt code { - font-size:1.2em; - vertical-align:top; -} -sup { - font-size:.6em; -} -/* -Document title and Copyright styles -*/ -.clear { - clear:both; - height:0px; - overflow:hidden; -} -.aboutLanguage { - float:right; - padding:0px 21px; - font-size:.8em; - z-index:200; - margin-top:-7px; -} -.legalCopy { - margin-left:.5em; -} -.bar a, .bar a:link, .bar a:visited, .bar a:active { - color:#FFFFFF; - text-decoration:none; -} -.bar a:hover, .bar a:focus { - color:#bb7a2a; -} -.tab { - background-color:#0066FF; - background-image:url(resources/titlebar.gif); - background-position:left top; - background-repeat:no-repeat; - color:#ffffff; - padding:8px; - width:5em; - font-weight:bold; -} -/* -Navigation bar styles -*/ -.bar { - background-image:url(resources/background.gif); - background-repeat:repeat-x; - color:#FFFFFF; - padding:.8em .5em .4em .8em; - height:auto;/*height:1.8em;*/ - font-size:1em; - margin:0; -} -.topNav { - background-image:url(resources/background.gif); - background-repeat:repeat-x; - color:#FFFFFF; - float:left; - padding:0; - width:100%; - clear:right; - height:2.8em; - padding-top:10px; - overflow:hidden; -} -.bottomNav { - margin-top:10px; - background-image:url(resources/background.gif); - background-repeat:repeat-x; - color:#FFFFFF; - float:left; - padding:0; - width:100%; - clear:right; - height:2.8em; - padding-top:10px; - overflow:hidden; -} -.subNav { - background-color:#dee3e9; - border-bottom:1px solid #9eadc0; - float:left; - width:100%; - overflow:hidden; -} -.subNav div { - clear:left; - float:left; - padding:0 0 5px 6px; -} -ul.navList, ul.subNavList { - float:left; - margin:0 25px 0 0; - padding:0; -} -ul.navList li{ - list-style:none; - float:left; - padding:3px 6px; -} -ul.subNavList li{ - list-style:none; - float:left; - font-size:90%; -} -.topNav a:link, .topNav a:active, .topNav a:visited, .bottomNav a:link, .bottomNav a:active, .bottomNav a:visited { - color:#FFFFFF; - text-decoration:none; -} -.topNav a:hover, .bottomNav a:hover { - text-decoration:none; - color:#bb7a2a; -} -.navBarCell1Rev { - background-image:url(resources/tab.gif); - background-color:#a88834; - color:#FFFFFF; - margin: auto 5px; - border:1px solid #c9aa44; -} -/* -Page header and footer styles -*/ -.header, .footer { - clear:both; - margin:0 20px; - padding:5px 0 0 0; -} -.indexHeader { - margin:10px; - position:relative; -} -.indexHeader h1 { - font-size:1.3em; -} -.title { - color:#2c4557; - margin:10px 0; -} -.subTitle { - margin:5px 0 0 0; -} -.header ul { - margin:0 0 25px 0; - padding:0; -} -.footer ul { - margin:20px 0 5px 0; -} -.header ul li, .footer ul li { - list-style:none; - font-size:1.2em; -} -/* -Heading styles -*/ -div.details ul.blockList ul.blockList ul.blockList li.blockList h4, div.details ul.blockList ul.blockList ul.blockListLast li.blockList h4 { - background-color:#dee3e9; - border-top:1px solid #9eadc0; - border-bottom:1px solid #9eadc0; - margin:0 0 6px -8px; - padding:2px 5px; -} -ul.blockList ul.blockList ul.blockList li.blockList h3 { - background-color:#dee3e9; - border-top:1px solid #9eadc0; - border-bottom:1px solid #9eadc0; - margin:0 0 6px -8px; - padding:2px 5px; -} -ul.blockList ul.blockList li.blockList h3 { - padding:0; - margin:15px 0; -} -ul.blockList li.blockList h2 { - padding:0px 0 20px 0; -} -/* -Page layout container styles -*/ -.contentContainer, .sourceContainer, .classUseContainer, .serializedFormContainer, .constantValuesContainer { - clear:both; - padding:10px 20px; - position:relative; -} -.indexContainer { - margin:10px; - position:relative; - font-size:1.0em; -} -.indexContainer h2 { - font-size:1.1em; - padding:0 0 3px 0; -} -.indexContainer ul { - margin:0; - padding:0; -} -.indexContainer ul li { - list-style:none; -} -.contentContainer .description dl dt, .contentContainer .details dl dt, .serializedFormContainer dl dt { - font-size:1.1em; - font-weight:bold; - margin:10px 0 0 0; - color:#4E4E4E; -} -.contentContainer .description dl dd, .contentContainer .details dl dd, .serializedFormContainer dl dd { - margin:10px 0 10px 20px; -} -.serializedFormContainer dl.nameValue dt { - margin-left:1px; - font-size:1.1em; - display:inline; - font-weight:bold; -} -.serializedFormContainer dl.nameValue dd { - margin:0 0 0 1px; - font-size:1.1em; - display:inline; -} -/* -List styles -*/ -ul.horizontal li { - display:inline; - font-size:0.9em; -} -ul.inheritance { - margin:0; - padding:0; -} -ul.inheritance li { - display:inline; - list-style:none; -} -ul.inheritance li ul.inheritance { - margin-left:15px; - padding-left:15px; - padding-top:1px; -} -ul.blockList, ul.blockListLast { - margin:10px 0 10px 0; - padding:0; -} -ul.blockList li.blockList, ul.blockListLast li.blockList { - list-style:none; - margin-bottom:25px; -} -ul.blockList ul.blockList li.blockList, ul.blockList ul.blockListLast li.blockList { - padding:0px 20px 5px 10px; - border:1px solid #9eadc0; - background-color:#f9f9f9; -} -ul.blockList ul.blockList ul.blockList li.blockList, ul.blockList ul.blockList ul.blockListLast li.blockList { - padding:0 0 5px 8px; - background-color:#ffffff; - border:1px solid #9eadc0; - border-top:none; -} -ul.blockList ul.blockList ul.blockList ul.blockList li.blockList { - margin-left:0; - padding-left:0; - padding-bottom:15px; - border:none; - border-bottom:1px solid #9eadc0; -} -ul.blockList ul.blockList ul.blockList ul.blockList li.blockListLast { - list-style:none; - border-bottom:none; - padding-bottom:0; -} -table tr td dl, table tr td dl dt, table tr td dl dd { - margin-top:0; - margin-bottom:1px; -} -/* -Table styles -*/ -.contentContainer table, .classUseContainer table, .constantValuesContainer table { - border-bottom:1px solid #9eadc0; - width:100%; -} -.contentContainer ul li table, .classUseContainer ul li table, .constantValuesContainer ul li table { - width:100%; -} -.contentContainer .description table, .contentContainer .details table { - border-bottom:none; -} -.contentContainer ul li table th.colOne, .contentContainer ul li table th.colFirst, .contentContainer ul li table th.colLast, .classUseContainer ul li table th, .constantValuesContainer ul li table th, .contentContainer ul li table td.colOne, .contentContainer ul li table td.colFirst, .contentContainer ul li table td.colLast, .classUseContainer ul li table td, .constantValuesContainer ul li table td{ - vertical-align:top; - padding-right:20px; -} -.contentContainer ul li table th.colLast, .classUseContainer ul li table th.colLast,.constantValuesContainer ul li table th.colLast, -.contentContainer ul li table td.colLast, .classUseContainer ul li table td.colLast,.constantValuesContainer ul li table td.colLast, -.contentContainer ul li table th.colOne, .classUseContainer ul li table th.colOne, -.contentContainer ul li table td.colOne, .classUseContainer ul li table td.colOne { - padding-right:3px; -} -.overviewSummary caption, .packageSummary caption, .contentContainer ul.blockList li.blockList caption, .summary caption, .classUseContainer caption, .constantValuesContainer caption { - position:relative; - text-align:left; - background-repeat:no-repeat; - color:#FFFFFF; - font-weight:bold; - clear:none; - overflow:hidden; - padding:0px; - margin:0px; -} -caption a:link, caption a:hover, caption a:active, caption a:visited { - color:#FFFFFF; -} -.overviewSummary caption span, .packageSummary caption span, .contentContainer ul.blockList li.blockList caption span, .summary caption span, .classUseContainer caption span, .constantValuesContainer caption span { - white-space:nowrap; - padding-top:8px; - padding-left:8px; - display:block; - float:left; - background-image:url(resources/titlebar.gif); - height:18px; -} -.overviewSummary .tabEnd, .packageSummary .tabEnd, .contentContainer ul.blockList li.blockList .tabEnd, .summary .tabEnd, .classUseContainer .tabEnd, .constantValuesContainer .tabEnd { - width:10px; - background-image:url(resources/titlebar_end.gif); - background-repeat:no-repeat; - background-position:top right; - position:relative; - float:left; -} -ul.blockList ul.blockList li.blockList table { - margin:0 0 12px 0px; - width:100%; -} -.tableSubHeadingColor { - background-color: #EEEEFF; -} -.altColor { - background-color:#eeeeef; -} -.rowColor { - background-color:#ffffff; -} -.overviewSummary td, .packageSummary td, .contentContainer ul.blockList li.blockList td, .summary td, .classUseContainer td, .constantValuesContainer td { - text-align:left; - padding:3px 3px 3px 7px; -} -th.colFirst, th.colLast, th.colOne, .constantValuesContainer th { - background:#dee3e9; - border-top:1px solid #9eadc0; - border-bottom:1px solid #9eadc0; - text-align:left; - padding:3px 3px 3px 7px; -} -td.colOne a:link, td.colOne a:active, td.colOne a:visited, td.colOne a:hover, td.colFirst a:link, td.colFirst a:active, td.colFirst a:visited, td.colFirst a:hover, td.colLast a:link, td.colLast a:active, td.colLast a:visited, td.colLast a:hover, .constantValuesContainer td a:link, .constantValuesContainer td a:active, .constantValuesContainer td a:visited, .constantValuesContainer td a:hover { - font-weight:bold; -} -td.colFirst, th.colFirst { - border-left:1px solid #9eadc0; - white-space:nowrap; -} -td.colLast, th.colLast { - border-right:1px solid #9eadc0; -} -td.colOne, th.colOne { - border-right:1px solid #9eadc0; - border-left:1px solid #9eadc0; -} -table.overviewSummary { - padding:0px; - margin-left:0px; -} -table.overviewSummary td.colFirst, table.overviewSummary th.colFirst, -table.overviewSummary td.colOne, table.overviewSummary th.colOne { - width:25%; - vertical-align:middle; -} -table.packageSummary td.colFirst, table.overviewSummary th.colFirst { - width:25%; - vertical-align:middle; -} -/* -Content styles -*/ -.description pre { - margin-top:0; -} -.deprecatedContent { - margin:0; - padding:10px 0; -} -.docSummary { - padding:0; -} -/* -Formatting effect styles -*/ -.sourceLineNo { - color:green; - padding:0 30px 0 0; -} -h1.hidden { - visibility:hidden; - overflow:hidden; - font-size:.9em; -} -.block { - display:block; - margin:3px 0 0 0; -} -.strong { - font-weight:bold; -} diff --git a/dist/hibernate4-maven-plugin-1.0.2/configuration.html b/dist/hibernate4-maven-plugin-1.0.2/configuration.html deleted file mode 100644 index 87067028..00000000 --- a/dist/hibernate4-maven-plugin-1.0.2/configuration.html +++ /dev/null @@ -1,271 +0,0 @@ - - - - - - - - -The most simple way to configure the plugin is, to put all the hibernate-configuration in a hibernate.properties-file on your classpath. Put the file in the resources-folder. Maven will put it in the class-folder of your webapp, where it will be picked up by this plugin as well as by Hibernate 4.
-Doing so, the only additionally configuration needed, to activat the plugin is the following entry in the plugins-section of your pom.xml:
-<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>${project.version}</version> - <executions> - <execution> - <goals> - <goal>export</goal> - </goals> - </execution> - </executions> -</plugin>
But be aware, that in this case the database-url, that is build in the application is the same that is used while testing, where the database is droped and recreated by the plugin. So, you should never fire up this configuration on your production system, or your database might be erased!
-Hence, you should specify a different url for testing like in the following snippet:
-<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>${project.version}</version> - <executions> - <execution> - <goals> - <goal>export</goal> - </goals> - </execution> - </executions> - <configuration> - <url><![CDATA[jdbc:mysql://localhost/test-db]]></url> - </configuration> -</plugin>
Configuration properties, that are set in the configuration-section of the plugin-configuration cannnot be overwritten elsewere (for details see Configuration-Method-Precedence). You never can overwrite them by accident when specifying a property on the commandline or in your settings.xml.
Alternatively, it is possible, to configure the plugin via maven-properties. Each relevant configuration-option has a corresponding maven-property (for a full list see the Documentation of the export-Mojo). These are named after the Hibernate JDBC Properties:
-So, instead of writing the hibernate-configuration in the properties-file, like above, you could put it in the properties-section of your pom.xml.
-Thogether with the plugin-definition from above, the following would be a complete configuration (again, the database-url was overwritten in the plugin-configuration, to be sure to have a separate database for testing):
-<properties> - <hibernate.connection.driver_class>org.hsqldb.jdbcDriver</hibernate.connection.driver_class> - <hibernate.dialect>org.hibernate.dialect.HSQLDialect</hibernate.dialect> - <hibernate.connection.url><![CDATA[jdbc:hsqldb:res:org.my.path.production_db]]></hibernate.connection.url> - <hibernate.connection.username>sa</hibernate.connection.username> - <hibernate.connection.password></hibernate.connection.password> -</properties> - -... - -<plugins> - - ... - - <plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>${project.version}</version> - <executions> - <execution> - <goals> - <goal>export</goal> - </goals> - </execution> - </executions> - <configuration> - <url><![CDATA[jdbc:hsqldb:target/db/testdb;shutdown=true]]></url> - </configuration> - </plugin> - -<plugins>
A third way for configuring the plugin is the plugin-configuration. The relevant configuration-parameters are:
-The equivalent of the configuration from the last section would look like this:
-<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>${project.version}</version> - <executions> - <execution> - <goals> - <goal>export</goal> - </goals> - </execution> - </executions> - <configuration> - <driverClassName>org.hsqldb.jdbcDriver</driverClassName> - <hibernateDialect>org.hibernate.dialect.HSQLDialect</hibernateDialect> - <url><![CDATA[jdbc:hsqldb:target/db/fotos;shutdown=true]]></url> - <username>sa</username> - <password></password> - </configuration> -</plugin>
There are some seldom used parameters, that can only be configured throug this method:
-For explanations, see the Documentation of the export-Mojo.
The configuration is gathered in a fix order:
-If you are in doubt about where a configuration-value comes from, run maven with the debug-output enabled: mvn -X hibernate4:export and be aware, that maven-properties can be overwitten on the command-line, in your ~/.m2/settings.xml and in a profile.
-The plugin-configuration comes last and overwrites everything else. That way, you can be sure, that a configuration-value, that is specified in the plugin-configuration will never be overwritten by any other configuration-method.
-If you realy need to overwrite plugin-configuration-values with maven-properties, you can use maven-properties in the plugin-configuration:
-<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>${project.version}</version> - <executions> - <execution> - <goals> - <goal>export</goal> - </goals> - </execution> - </executions> - <configuration> - <password>${my-password-property}</password> - </configuration> -</plugin>
- - - -
-The following document contains the results of PMD's CPD 4.3.
- - - -
-If you are new to hibernate4-maven-plugin, in many cases, the Configuration-Method-Precedence may be the source of configuration errors. To solve this problem, you should run maven with the debugging output enabled. For example, by executing:
-mvn -X compile hibernate4:export
(The compile might be necessary, because hibernate4-maven-plugin has to scan the compiled classes for annotations!)
-Unlike the majority of the maven-plugins, hibernate4-maven-plugin was designed to give a good many hints, when debugging is enabled. Because, if you do not know, what went wrong, you can't fix it!
-But be warned: hibernate4-maven-plugin tends to be very chatty ;)
- - - -
-The following is a list of compile dependencies for this project. These dependencies are required to compile and run the application:
-GroupId | -ArtifactId | -Version | -Type | -License |
---|---|---|---|---|
com.pyx4j | -maven-plugin-log4j | -1.0.1 | -jar | -The Apache Software License, Version 2.0 |
net.sf.scannotation | -scannotation | -1.0.2 | -jar | -Apache License V2.0 |
org.apache.maven | -maven-core | -3.0.4 | -jar | -The Apache Software License, Version 2.0 |
org.apache.maven | -maven-plugin-api | -3.0.4 | -jar | -The Apache Software License, Version 2.0 |
org.hibernate | -hibernate-core | -4.2.3.Final | -jar | -GNU Lesser General Public License |
The following is a list of transitive dependencies for this project. Transitive dependencies are the dependencies of the project dependencies.
-The following is a list of compile dependencies for this project. These dependencies are required to compile and run the application:
-GroupId | -ArtifactId | -Version | -Classifier | -Type | -License |
---|---|---|---|---|---|
antlr | -antlr | -2.7.7 | -- | -jar | -BSD License |
dom4j | -dom4j | -1.6.1 | -- | -jar | -- |
javassist | -javassist | -3.6.0.GA | -- | -jar | -- |
log4j | -log4j | -1.2.14 | -- | -jar | -The Apache Software License, Version 2.0 |
org.apache.maven | -maven-aether-provider | -3.0.4 | -- | -jar | -The Apache Software License, Version 2.0 |
org.apache.maven | -maven-artifact | -3.0.4 | -- | -jar | -The Apache Software License, Version 2.0 |
org.apache.maven | -maven-model | -3.0.4 | -- | -jar | -The Apache Software License, Version 2.0 |
org.apache.maven | -maven-model-builder | -3.0.4 | -- | -jar | -The Apache Software License, Version 2.0 |
org.apache.maven | -maven-repository-metadata | -3.0.4 | -- | -jar | -The Apache Software License, Version 2.0 |
org.apache.maven | -maven-settings | -3.0.4 | -- | -jar | -The Apache Software License, Version 2.0 |
org.apache.maven | -maven-settings-builder | -3.0.4 | -- | -jar | -The Apache Software License, Version 2.0 |
org.codehaus.plexus | -plexus-classworlds | -2.4 | -- | -jar | -The Apache Software License, Version 2.0 |
org.codehaus.plexus | -plexus-component-annotations | -1.5.5 | -- | -jar | -The Apache Software License, Version 2.0 |
org.codehaus.plexus | -plexus-interpolation | -1.14 | -- | -jar | -The Apache Software License, Version 2.0 |
org.hibernate.common | -hibernate-commons-annotations | -4.0.2.Final | -- | -jar | -GNU LESSER GENERAL PUBLIC LICENSE |
org.hibernate.javax.persistence | -hibernate-jpa-2.0-api | -1.0.1.Final | -- | -jar | -license.txt |
org.javassist | -javassist | -3.15.0-GA | -- | -jar | -MPL 1.1-LGPL 2.1-Apache License 2.0 |
org.jboss.logging | -jboss-logging | -3.1.0.GA | -- | -jar | -GNU Lesser General Public License, version 2.1 |
org.jboss.spec.javax.transaction | -jboss-transaction-api_1.1_spec | -1.0.1.Final | -- | -jar | -Common Development and Distribution License-GNU General Public License, Version 2 with the Classpath Exception |
org.sonatype.aether | -aether-api | -1.13.1 | -- | -jar | -Eclipse Public License, Version 1.0 |
org.sonatype.aether | -aether-impl | -1.13.1 | -- | -jar | -Eclipse Public License, Version 1.0 |
org.sonatype.aether | -aether-spi | -1.13.1 | -- | -jar | -Eclipse Public License, Version 1.0 |
org.sonatype.aether | -aether-util | -1.13.1 | -- | -jar | -Eclipse Public License, Version 1.0 |
org.sonatype.plexus | -plexus-cipher | -1.4 | -- | -jar | -Apache Public License 2.0 |
org.sonatype.plexus | -plexus-sec-dispatcher | -1.3 | -- | -jar | -Apache Public License 2.0 |
org.sonatype.sisu | -sisu-guava | -0.9.9 | -- | -jar | -The Apache Software License, Version 2.0 |
org.sonatype.sisu | -sisu-guice | -3.1.0 | -no_aop | -jar | -The Apache Software License, Version 2.0 |
org.sonatype.sisu | -sisu-inject-bean | -2.3.0 | -- | -jar | -The Apache Software License, Version 2.0-Eclipse Public License, Version 1.0 |
org.sonatype.sisu | -sisu-inject-plexus | -2.3.0 | -- | -jar | -Eclipse Public License, Version 1.0 |
Unamed: JPA 2.0 API
-Apache Public License 2.0: Plexus Cipher: encryption/decryption Component, Plexus Security Dispatcher Component
-GNU LESSER GENERAL PUBLIC LICENSE: Hibernate Commons Annotations
-Unknown: dom4j, javassist
-Common Development and Distribution License: Java Transaction API
-LGPL 2.1: Javassist
-GNU General Public License, Version 2 with the Classpath Exception: Java Transaction API
-MPL 1.1: Javassist
-The Apache Software License, Version 2.0: Hibernate 4 Maven Plugin, Log4j, Maven Aether Provider, Maven Artifact, Maven Core, Maven Model, Maven Model Builder, Maven Plugin API, Maven Repository Metadata Model, Maven Settings, Maven Settings Builder, Plexus :: Component Annotations, Plexus Classworlds, Plexus Interpolation API, Sisu Guava - Core Library, Sisu Guice - Core Library, Sisu-Inject-Bean : Aggregate OSGi bundle, maven-plugin-log4j
-GNU Lesser General Public License: A Hibernate Core Module
-GNU Lesser General Public License, version 2.1: JBoss Logging 3
-Apache License V2.0: scannotation
-BSD License: AntLR Parser Generator
-Apache License 2.0: Javassist
-Eclipse Public License, Version 1.0: Aether :: API, Aether :: Implementation, Aether :: SPI, Aether :: Utilities, Sisu-Inject-Bean : Aggregate OSGi bundle, Sisu-Inject-Plexus : Aggregate OSGi bundle
Filename | -Size | -Entries | -Classes | -Packages | -JDK Rev | -Debug |
---|---|---|---|---|---|---|
antlr-2.7.7.jar | -434.85 kB | -239 | -224 | -12 | -1.2 | -debug |
maven-plugin-log4j-1.0.1.jar | -3.64 kB | -12 | -1 | -1 | -1.4 | -debug |
dom4j-1.6.1.jar | -306.54 kB | -208 | -190 | -14 | -1.3 | -debug |
javassist-3.6.0.GA.jar | -529.53 kB | -323 | -305 | -16 | -1.2 | -debug |
log4j-1.2.14.jar | -358.83 kB | -288 | -256 | -19 | -1.1 | -debug |
scannotation-1.0.2.jar | -18.04 kB | -23 | -13 | -2 | -1.5 | -debug |
maven-aether-provider-3.0.4.jar | -55.17 kB | -40 | -23 | -1 | -1.5 | -debug |
maven-artifact-3.0.4.jar | -50.87 kB | -57 | -32 | -11 | -1.5 | -debug |
maven-core-3.0.4.jar | -545.94 kB | -428 | -350 | -43 | -1.5 | -debug |
maven-model-3.0.4.jar | -159.72 kB | -67 | -50 | -3 | -1.5 | -debug |
maven-model-builder-3.0.4.jar | -147.06 kB | -142 | -109 | -16 | -1.5 | -debug |
maven-plugin-api-3.0.4.jar | -48.16 kB | -46 | -25 | -6 | -1.5 | -debug |
maven-repository-metadata-3.0.4.jar | -29.37 kB | -25 | -7 | -2 | -1.5 | -debug |
maven-settings-3.0.4.jar | -45.57 kB | -33 | -17 | -2 | -1.5 | -debug |
maven-settings-builder-3.0.4.jar | -40.41 kB | -53 | -32 | -5 | -1.5 | -debug |
plexus-classworlds-2.4.jar | -45.96 kB | -52 | -37 | -5 | -1.4 | -debug |
plexus-component-annotations-1.5.5.jar | -4.11 kB | -15 | -3 | -1 | -1.5 | -release |
plexus-interpolation-1.14.jar | -59.64 kB | -60 | -44 | -6 | -1.4 | -debug |
hibernate-core-4.2.3.Final.jar | -4.41 MB | -3,190 | -2,981 | -170 | -1.6 | -debug |
hibernate-commons-annotations-4.0.2.Final.jar | -79.91 kB | -82 | -64 | -7 | -1.6 | -debug |
hibernate-jpa-2.0-api-1.0.1.Final.jar | -100.25 kB | -190 | -176 | -4 | -1.5 | -debug |
javassist-3.15.0-GA.jar | -633.06 kB | -391 | -367 | -17 | -1.4 | -debug |
jboss-logging-3.1.0.GA.jar | -59.34 kB | -55 | -43 | -1 | -1.6 | -debug |
jboss-transaction-api_1.1_spec-1.0.1.Final.jar | -24.62 kB | -31 | -18 | -2 | -1.6 | -debug |
aether-api-1.13.1.jar | -87.56 kB | -116 | -96 | -11 | -1.5 | -debug |
aether-impl-1.13.1.jar | -127.10 kB | -87 | -73 | -2 | -1.5 | -debug |
aether-spi-1.13.1.jar | -15.07 kB | -33 | -17 | -5 | -1.5 | -debug |
aether-util-1.13.1.jar | -126.98 kB | -116 | -92 | -14 | -1.5 | -debug |
plexus-cipher-1.4.jar | -13.18 kB | -20 | -6 | -1 | -1.4 | -debug |
plexus-sec-dispatcher-1.3.jar | -27.89 kB | -31 | -13 | -3 | -1.4 | -debug |
sisu-guava-0.9.9.jar | -1.44 MB | -1,183 | -1,163 | -10 | -1.5 | -debug |
sisu-guice-3.1.0-no_aop.jar | -349.05 kB | -310 | -295 | -8 | -1.5 | -debug |
sisu-inject-bean-2.3.0.jar | -282.29 kB | -256 | -224 | -15 | -1.5 | -debug |
sisu-inject-plexus-2.3.0.jar | -199.64 kB | -207 | -163 | -27 | -1.5 | -debug |
Total | -Size | -Entries | -Classes | -Packages | -JDK Rev | -Debug |
34 | -10.74 MB | -8,409 | -7,509 | -462 | -1.6 | -33 |
compile: 34 | -compile: 10.74 MB | -compile: 8,409 | -compile: 7,509 | -compile: 462 | -- | -compile: 33 |
Repo ID | -URL | -Release | -Snapshot |
---|---|---|---|
apache.snapshots | -http://repository.apache.org/snapshots | -- | -Yes |
sonatype-nexus-snapshots | -https://oss.sonatype.org/content/repositories/snapshots | -- | -Yes |
central | -http://repo.maven.apache.org/maven2 | -Yes | -- |
Repository locations for each of the Dependencies.
-- - - -
-<dependency> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.0.2</version> - <type>maven-plugin</type> -</dependency>
<dependency org="de.juplo" name="hibernate4-maven-plugin" rev="1.0.2"> - <artifact name="hibernate4-maven-plugin" type="maven-plugin" /> -</dependency>
- - - -
-The following is the distribution management information used by this project.
- -- - - -
-Full name:
- -de.juplo:hibernate4-maven-plugin:1.0.2:export
- -Description:
- -Attributes:
- -Name | - -Type | - -Since | - -Description | -
---|---|---|---|
delimiter | - -String | - -- | - -Delimiter in output-file. Default value is: ;. User property is: hibernate.export.schema.delimiter. |
-
driverClassName | - -String | - -- | - -SQL-Driver name. User property is: hibernate.connection.driver_class. |
-
force | - -boolean | - -- | - -Force execution
-
- Force execution, even if no modified or newly added annotated -classes where found and the dialect was not changed. - -skip takes precedence over force. Default value is: false. User property is: hibernate.export.force. |
-
format | - -boolean | - -- | - -Format output-file. Default value is: true. User property is: hibernate.export.schema.format. |
-
hibernateDialect | - -String | - -- | - -Hibernate dialect. User property is: hibernate.dialect. |
-
hibernateMapping | - -String | - -- | - -List of Hibernate-Mapping-Files (XML). Multiple files can be
-separated with white-spaces and/or commas. User property is: hibernate.mapping. |
-
hibernateNamingStrategy | - -String | - -- | - -Hibernate Naming Strategy User property is: hibernate.ejb.naming_strategy. |
-
hibernateProperties | - -String | - -- | - -Path to Hibernate configuration file. Default value is: ${project.build.outputDirectory}/hibernate.properties. |
-
outputDirectory | - -String | - -- | - -Classes-Directory to scan.
-
- This parameter defaults to the maven build-output-directory for -classes. Additonally, all dependencies are scanned for annotated -classes. User property is: project.build.outputDirectory. |
-
outputFile | - -String | - -- | - -Output file. Default value is: ${project.build.directory}/schema.sql. User property is: hibernate.export.schema.filename. |
-
password | - -String | - -- | - -Database password User property is: hibernate.connection.password. |
-
scanTestClasses | - -boolean | - -- | - -Wether to scan test-classes too, or not.
-
- If this parameter is set to true the test-classes -of the artifact will be scanned for hibernate-annotated classes -additionally. Default value is: false. User property is: hibernate.export.scan_testclasses. |
-
skip | - -boolean | - -- | - -Skip execution
-
- If set to true, the execution is skipped. - -A skipped excecution is signaled via the maven-property -${hibernate.export.skipped}. - -The excecution is skipped automatically, if no modified or newly -added annotated classes are found and the dialect was not -changed. Default value is: false. User property is: maven.test.skip. |
-
target | - -String | - -- | - -Target of execution:
-
-
Default value is: EXPORT. User property is: hibernate.export.target. |
-
testOutputDirectory | - -String | - -- | - -Test-Classes-Directory to scan.
-
- This parameter defaults to the maven build-output-directory for -test-classes. - -This parameter is only used, when scanTestClasses -is set to true! User property is: project.build.testOutputDirectory. |
-
type | - -String | - -- | - -Type of execution.
-
-
Default value is: BOTH. User property is: hibernate.export.type. |
-
url | - -String | - -- | - -Database URL. User property is: hibernate.connection.url. |
-
username | - -String | - -- | - -Database username User property is: hibernate.connection.username. |
-
Force execution, even if no modified or newly added annotated -classes where found and the dialect was not changed.
- -skip takes precedence over force.
This parameter defaults to the maven build-output-directory for -classes. Additonally, all dependencies are scanned for annotated -classes.
If this parameter is set to true the test-classes -of the artifact will be scanned for hibernate-annotated classes -additionally.
skip:
- -If set to true, the execution is skipped.
- -A skipped excecution is signaled via the maven-property -${hibernate.export.skipped}.
- -The excecution is skipped automatically, if no modified or newly -added annotated classes are found and the dialect was not -changed.
This parameter defaults to the maven build-output-directory for -test-classes.
- -This parameter is only used, when scanTestClasses -is set to true!
type:
- -url:
- -- - - -
-The hibernate4-maven-plugin computes MD5-sums for all found annotated classes and stores them together with the generated schema. If no classes were changed or added and the dialect wasn't changed too, it automatically skips the configured schema-export, to speed up the development cycle.
-The plugin signals, that the execution was skipped by setting the maven property $hibernate.export.skipped to true. This may be helpful, because other plugins like dbunit-plugin may fail, when the execution is skipped.
-If you need the hibernate4-maven-plugin to never skip automatically execution, you can force it to do so, if you set the parameter force to true:
-<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>${project.version}</version> - <configuration> - <force>true</force> - </configuration> -</plugin>
Or you may specify -Dhibernate.export.force=true at the command line, if you want to force hibernate4-maven-plugin only once.
- - - -
-Full name:
- -de.juplo:hibernate4-maven-plugin:1.0.2:help
- -Description:
- -Attributes:
- -Name | - -Type | - -Since | - -Description | -
---|---|---|---|
detail | - -boolean | - -- | - -If true, display all settable properties for each
-goal. Default value is: false. User property is: detail. |
-
goal | - -String | - -- | - -The name of the goal for which to show help. If unspecified, all
-goals will be displayed. User property is: goal. |
-
indentSize | - -int | - -- | - -The number of spaces per indentation level, should be positive. Default value is: 2. User property is: indentSize. |
-
lineLength | - -int | - -- | - -The maximum length of a display line, should be positive. Default value is: 80. User property is: lineLength. |
-
goal:
- -- - - -
-hibernate4-maven-plugin is a plugin for generating a database-schema from your Hibernate-4-Mappings and create or update your database accordingly.
-The plugin was designed with three main goals in mind:
-To achieve the first goal, the convention-over-configuration paradigma was applied and the plugin was stuffed with usefull logging-messages. So, if in doubt, just turn on the debugging output with the mvn -X ....
-To achieve the second goal, the precedence in which the configuration locations are consulted was layouted in a way that makes it possible, to prevent overwrites of the wrong database by accident.
-Last but not least, in order to not slow down the development cycle, the hibernate4-maven-plugin only executes the schema-export, if the mapping or the dialect changes (or if you force it to do so).
-For more information about the inspiration to write this tiny plugin, read our blog-article about the hibernate4-maven-plugin.
-- - - -
-Configuration for notifying developers/users when a build is unsuccessful, including user information and notification mode.
-Type | -Address | -Configuration |
---|---|---|
kai@juplo.de | -- |
- - - -
-- - - -
-Typically the licenses listed for the project are that of the project itself, and not of dependencies.
A business-friendly OSS license
-- Apache License - Version 2.0, January 2004 - http://www.apache.org/licenses/ - - TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION - - 1. Definitions. - - "License" shall mean the terms and conditions for use, reproduction, - and distribution as defined by Sections 1 through 9 of this document. - - "Licensor" shall mean the copyright owner or entity authorized by - the copyright owner that is granting the License. - - "Legal Entity" shall mean the union of the acting entity and all - other entities that control, are controlled by, or are under common - control with that entity. For the purposes of this definition, - "control" means (i) the power, direct or indirect, to cause the - direction or management of such entity, whether by contract or - otherwise, or (ii) ownership of fifty percent (50%) or more of the - outstanding shares, or (iii) beneficial ownership of such entity. - - "You" (or "Your") shall mean an individual or Legal Entity - exercising permissions granted by this License. - - "Source" form shall mean the preferred form for making modifications, - including but not limited to software source code, documentation - source, and configuration files. - - "Object" form shall mean any form resulting from mechanical - transformation or translation of a Source form, including but - not limited to compiled object code, generated documentation, - and conversions to other media types. - - "Work" shall mean the work of authorship, whether in Source or - Object form, made available under the License, as indicated by a - copyright notice that is included in or attached to the work - (an example is provided in the Appendix below). - - "Derivative Works" shall mean any work, whether in Source or Object - form, that is based on (or derived from) the Work and for which the - editorial revisions, annotations, elaborations, or other modifications - represent, as a whole, an original work of authorship. For the purposes - of this License, Derivative Works shall not include works that remain - separable from, or merely link (or bind by name) to the interfaces of, - the Work and Derivative Works thereof. - - "Contribution" shall mean any work of authorship, including - the original version of the Work and any modifications or additions - to that Work or Derivative Works thereof, that is intentionally - submitted to Licensor for inclusion in the Work by the copyright owner - or by an individual or Legal Entity authorized to submit on behalf of - the copyright owner. For the purposes of this definition, "submitted" - means any form of electronic, verbal, or written communication sent - to the Licensor or its representatives, including but not limited to - communication on electronic mailing lists, source code control systems, - and issue tracking systems that are managed by, or on behalf of, the - Licensor for the purpose of discussing and improving the Work, but - excluding communication that is conspicuously marked or otherwise - designated in writing by the copyright owner as "Not a Contribution." - - "Contributor" shall mean Licensor and any individual or Legal Entity - on behalf of whom a Contribution has been received by Licensor and - subsequently incorporated within the Work. - - 2. Grant of Copyright License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - copyright license to reproduce, prepare Derivative Works of, - publicly display, publicly perform, sublicense, and distribute the - Work and such Derivative Works in Source or Object form. - - 3. Grant of Patent License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - (except as stated in this section) patent license to make, have made, - use, offer to sell, sell, import, and otherwise transfer the Work, - where such license applies only to those patent claims licensable - by such Contributor that are necessarily infringed by their - Contribution(s) alone or by combination of their Contribution(s) - with the Work to which such Contribution(s) was submitted. If You - institute patent litigation against any entity (including a - cross-claim or counterclaim in a lawsuit) alleging that the Work - or a Contribution incorporated within the Work constitutes direct - or contributory patent infringement, then any patent licenses - granted to You under this License for that Work shall terminate - as of the date such litigation is filed. - - 4. Redistribution. You may reproduce and distribute copies of the - Work or Derivative Works thereof in any medium, with or without - modifications, and in Source or Object form, provided that You - meet the following conditions: - - (a) You must give any other recipients of the Work or - Derivative Works a copy of this License; and - - (b) You must cause any modified files to carry prominent notices - stating that You changed the files; and - - (c) You must retain, in the Source form of any Derivative Works - that You distribute, all copyright, patent, trademark, and - attribution notices from the Source form of the Work, - excluding those notices that do not pertain to any part of - the Derivative Works; and - - (d) If the Work includes a "NOTICE" text file as part of its - distribution, then any Derivative Works that You distribute must - include a readable copy of the attribution notices contained - within such NOTICE file, excluding those notices that do not - pertain to any part of the Derivative Works, in at least one - of the following places: within a NOTICE text file distributed - as part of the Derivative Works; within the Source form or - documentation, if provided along with the Derivative Works; or, - within a display generated by the Derivative Works, if and - wherever such third-party notices normally appear. The contents - of the NOTICE file are for informational purposes only and - do not modify the License. You may add Your own attribution - notices within Derivative Works that You distribute, alongside - or as an addendum to the NOTICE text from the Work, provided - that such additional attribution notices cannot be construed - as modifying the License. - - You may add Your own copyright statement to Your modifications and - may provide additional or different license terms and conditions - for use, reproduction, or distribution of Your modifications, or - for any such Derivative Works as a whole, provided Your use, - reproduction, and distribution of the Work otherwise complies with - the conditions stated in this License. - - 5. Submission of Contributions. Unless You explicitly state otherwise, - any Contribution intentionally submitted for inclusion in the Work - by You to the Licensor shall be under the terms and conditions of - this License, without any additional terms or conditions. - Notwithstanding the above, nothing herein shall supersede or modify - the terms of any separate license agreement you may have executed - with Licensor regarding such Contributions. - - 6. Trademarks. This License does not grant permission to use the trade - names, trademarks, service marks, or product names of the Licensor, - except as required for reasonable and customary use in describing the - origin of the Work and reproducing the content of the NOTICE file. - - 7. Disclaimer of Warranty. Unless required by applicable law or - agreed to in writing, Licensor provides the Work (and each - Contributor provides its Contributions) on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or - implied, including, without limitation, any warranties or conditions - of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A - PARTICULAR PURPOSE. You are solely responsible for determining the - appropriateness of using or redistributing the Work and assume any - risks associated with Your exercise of permissions under this License. - - 8. Limitation of Liability. In no event and under no legal theory, - whether in tort (including negligence), contract, or otherwise, - unless required by applicable law (such as deliberate and grossly - negligent acts) or agreed to in writing, shall any Contributor be - liable to You for damages, including any direct, indirect, special, - incidental, or consequential damages of any character arising as a - result of this License or out of the use or inability to use the - Work (including but not limited to damages for loss of goodwill, - work stoppage, computer failure or malfunction, or any and all - other commercial damages or losses), even if such Contributor - has been advised of the possibility of such damages. - - 9. Accepting Warranty or Additional Liability. While redistributing - the Work or Derivative Works thereof, You may choose to offer, - and charge a fee for, acceptance of support, warranty, indemnity, - or other liability obligations and/or rights consistent with this - License. However, in accepting such obligations, You may act only - on Your own behalf and on Your sole responsibility, not on behalf - of any other Contributor, and only if You agree to indemnify, - defend, and hold each Contributor harmless for any liability - incurred by, or claims asserted against, such Contributor by reason - of your accepting any such warranty or additional liability. - - END OF TERMS AND CONDITIONS - - APPENDIX: How to apply the Apache License to your work. - - To apply the Apache License to your work, attach the following - boilerplate notice, with the fields enclosed by brackets "[]" - replaced with your own identifying information. (Don't include - the brackets!) The text should be enclosed in the appropriate - comment syntax for the file format. We also recommend that a - file or class name and description of purpose be included on the - same "printed page" as the copyright notice for easier - identification within third-party archives. - - Copyright [yyyy] [name of copyright owner] - - Licensed under the Apache License, Version 2.0 (the "License"); - you may not use this file except in compliance with the License. - You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. -
- - - -
-- - - -
-The default-configuration uses the EXPORT-target of the SchemaExport-Tool. If you do not need to create a database with the evaluated schema, you can use the NONE- or the SCRIPT-target. This can be achieved with the commandline-parameter -Dhibernate.export.target=SCRIPT or with the following configuration:
-<configuration> - <target>SCRIPT</target> -</configuration>
But even when no database is to be created, hibernate always needs to know the dialect. Hence, the plugin will fail if this parameter is missing!
One regular problem is the scope of the jdbc-driver-dependency. It is very unlikely, that this dependency is needed at compile-time. So a tidy maven-developer would usually scope it for runtime.
-But this will break the execution of the hibernate4-maven-plugin. Since it will not be able to see the needed dependency, it will fail with an error-message like:
-[INFO] Gathered hibernate-configuration (turn on debugging for details): -[INFO] hibernate.connection.username = sa -[INFO] hibernate.connection.password = -[INFO] hibernate.dialect = org.hibernate.dialect.HSQLDialect -[INFO] hibernate.connection.url = jdbc:hsqldb:/home/kai/mmf/target/mmf;shutdown=true -[INFO] hibernate.connection.driver_class = org.hsqldb.jdbcDriver -[ERROR] Dependency for driver-class org.hsqldb.jdbcDriver is missing! -[INFO] ------------------------------------------------------------------------ -[ERROR] BUILD ERROR -[INFO] ------------------------------------------------------------------------ -[INFO] org.hsqldb.jdbcDriver -[INFO] ------------------------------------------------------------------------ -[INFO] For more information, run Maven with the -e switch -[INFO] ------------------------------------------------------------------------ -[INFO] Total time: 2 seconds -[INFO] Finished at: Thu Nov 29 11:31:14 CET 2012 -[INFO] Final Memory: 32M/342M -[INFO] ------------------------------------------------------------------------
A quick workaround for this error would be, to delete the runtime-constraint for the jdbc-driver-dependency.
-A much cleaner way is, to (additionally) ad the dependency, to the plugin-definition:
-<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>${project.version}</version> - <executions> - <execution> - <goals> - <goal>export</goal> - </goals> - </execution> - </executions> - <dependencies> - <dependency> - <groupId>org.hsqldb</groupId> - <artifactId>hsqldb</artifactId> - <version>2.2.8</version> - </dependency> - </dependencies> -</plugin>
This is also the best way, if you use a different jdbc-driver for testing, than in production. Because otherwise, this dependency will unnecessarily bloat the runtime-dependencies of your project.
If hibernate4-maven-plugin skips its excecution, this may lead to errors in other plugins. For example, when importing sample-data in the automatically created database with the help of the dbunit-plugin, the CLEAN_INSERT-operation may fail because of foreign-key-constraints, if the database was not recreated, because the hibernate4-maven-plugin has skipped its excecution.
-A quick fix to this problem is, to force hibernate4-maven-plugin to export the schema every time it is running. But to recreate the database on every testrun may noticeable slow down your development cycle, if you have to wait for slow IO.
-To circumvent this problem, hibernate4-maven-plugin signals a skipped excecution by setting the maven property $hibernate.export.skipped to true. You can configure other plugins to react on this signal. For example, the dbunit-plugin can be configured to skip its excecution, if hibernate4-maven-plugin was skipped like this:
-<plugin> - <groupId>org.codehaus.mojo</groupId> - <artifactId>dbunit-maven-plugin</artifactId> - <configuration> - <skip>${hibernate.export.skipped}</skip> - </configuration> -</plugin>
If one manually drops the database or removes the hsqldb-files, it will not be recreated by the hibernate4-maven-plugin, because it cannot detect, that the database needs to be recreated. This happens, because the plugin will not recreate the database if neither the configuration nor the annotated classes have changed, because an unnecessary drop-create-cycle might take a long time. The plugin will report that like this: ------------- [INFO] No modified annotated classes found and dialect unchanged. [INFO] Skipping schema generation! [------------
-If one always uses mvn clen for cleanup, this will not happen. Otherwise the recreation must be forced:
-mvn hibernate4:export -Dhibernate.export.force=true
- - - -
-Goals available for this plugin:
-Goal | -Description |
---|---|
hibernate4:export | -Goal which extracts the hibernate-mapping-configuration and exports -an according SQL-database-schema. |
hibernate4:help | -Display help information on hibernate4-maven-plugin. -Call mvn hibernate4:help -Ddetail=true
--Dgoal=<goal-name> to display parameter details. |
The following specifies the minimum requirements to run this Maven plugin:
-Maven | -2.0.6 |
JDK | -1.6 |
Memory | -No minimum requirement. |
Disk Space | -No minimum requirement. |
You should specify the version in your project's plugin configuration:
-<project> - ... - <build> - <!-- To define the plugin version in your parent POM --> - <pluginManagement> - <plugins> - <plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.0.2</version> - </plugin> - ... - </plugins> - </pluginManagement> - <!-- To use the plugin goals in your POM or parent POM --> - <plugins> - <plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.0.2</version> - </plugin> - ... - </plugins> - </build> - ... -</project> -
For more information, see "Guide to Configuring Plug-ins"
- - - -
-GroupId | -ArtifactId | -Version |
---|---|---|
org.apache.maven.plugins | -maven-antrun-plugin | -1.3 |
org.apache.maven.plugins | -maven-assembly-plugin | -2.2-beta-5 |
org.apache.maven.plugins | -maven-dependency-plugin | -2.1 |
org.apache.maven.plugins | -maven-release-plugin | -2.1 |
org.apache.maven.plugins | -maven-site-plugin | -3.3 |
- - - -
-GroupId | -ArtifactId | -Version |
---|---|---|
org.apache.maven.plugins | -maven-clean-plugin | -2.5 |
org.apache.maven.plugins | -maven-compiler-plugin | -2.0.2 |
org.apache.maven.plugins | -maven-dependency-plugin | -2.1 |
org.apache.maven.plugins | -maven-deploy-plugin | -2.7 |
org.apache.maven.plugins | -maven-enforcer-plugin | -1.0 |
org.apache.maven.plugins | -maven-install-plugin | -2.3 |
org.apache.maven.plugins | -maven-jar-plugin | -2.2 |
org.apache.maven.plugins | -maven-plugin-plugin | -3.2 |
org.apache.maven.plugins | -maven-resources-plugin | -2.3 |
org.apache.maven.plugins | -scp://people.apache.org/www/maven.apache.org/scm/maven-scm-plugin | -1.7 |
org.apache.maven.plugins | -maven-site-plugin | -3.3 |
org.apache.maven.plugins | -maven-source-plugin | -2.1.2 |
org.apache.maven.plugins | -maven-surefire-plugin | -2.10 |
GroupId | -ArtifactId | -Version |
---|---|---|
org.apache.maven.plugins | -maven-changes-plugin | -2.7.1 |
org.apache.maven.plugins | -maven-javadoc-plugin | -2.7 |
org.apache.maven.plugins | -maven-jxr-plugin | -2.3 |
org.apache.maven.plugins | -maven-plugin-plugin | -3.2 |
org.apache.maven.plugins | -maven-pmd-plugin | -2.7.1 |
org.apache.maven.plugins | -maven-site-plugin | -3.3 |
- - - -
-The following document contains the results of PMD 4.3.
- - - -
-This document provides an overview of the various documents and links that are part of this project's general information. All of this content is automatically generated by Maven on behalf of the project.
-Document | -Description |
---|---|
About | -Plugin for generating a database-schema from Hibernate-4-Mapping-Annotations |
Plugin Management | -This document lists the plugins that are defined through pluginManagement. |
Distribution Management | -This document provides informations on the distribution management of this project. |
Dependency Information | -This document describes how to to include this project as a dependency using various dependency management tools. |
Source Repository | -This is a link to the online source repository that can be viewed via a web browser. |
Mailing Lists | -This document provides subscription and archive information for this project's mailing lists. |
Issue Tracking | -This is a link to the issue management system for this project. Issues (bugs, features, change requests) can be created and queried using this link. |
Continuous Integration | -This is a link to the definitions of all continuous integration processes that builds and tests code on a frequent, regular basis. |
Project Plugins | -This document lists the build plugins and the report plugins used by this project. |
Project License | -This is a link to the definitions of project licenses. |
Project Team | -This document provides information on the members of this project. These are the individuals who have contributed to the project in one form or another. |
Project Summary | -This document lists other related information of this project |
Dependencies | -This document lists the project's dependencies and provides information on each dependency. |
- - - -
-This document provides an overview of the various reports that are automatically generated by Maven . Each report is briefly described below.
-Document | -Description |
---|---|
JavaDocs | -JavaDoc API documentation. |
Source Xref | -HTML based, cross-reference version of Java source code. |
PMD Report | -Verification of coding rules. |
CPD Report | -Duplicate code detection. |
Plugin Documentation | -This report provides goals and parameters documentation of a plugin. |
- - - -
-Field | -Value |
---|---|
Name | -Hibernate 4 Maven Plugin |
Description | -Plugin for generating a database-schema from Hibernate-4-Mapping-Annotations |
Homepage | -http://juplo.de/hibernate4-maven-plugin |
- - - -
-In most use-cases, the hibernate4-maven-plugin is used to create a test-database automatically. In this use-cases, it is very likely, that it will result in mistakes/errors, if the goal is executed, when the tests are skipped. For example, one might manually overwrite the database-url with the url of the production-database, in order to run other tests, like starting a local webserver with the jetty-maven-plugin. If the export-goal would be executed in such a scenario, it might erase the hole production-database, which is not very desireable.
-Because of this, the configuration-parameter skip defaults to the value of the proptery maven.test.skip. This way, the execution of the hibernate4-maven-plugin is skipped automatically, when the tests are skipped. Think of it as a build-in security-belt.
-If you do not like that, because you need the plugin to always execute the export-goal, even if the tests are skipped you can configure that explicitly, by setting the configuration-parameter skip to false:
-<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - ... - <configuration> - <skip>false</skip> - </configuration> -</plugin>
Or, if you want the export-goal to be executed by default and to be skipped if you say so, you can bind the value of the configuration-parameter skip to a custom property. For example:
-<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - ... - <configuration> - <skip>${foo.bar}</skip> - </configuration> -</plugin>
This way, the export-goal would be skipped, if you set the property foo.bar to true. For example, if you specify -Dfoo.bar=true on the command-line.
-- - - -
-This project uses GIT to manage its source code. Instructions on GIT use can be found at http://git-scm.com/documentation.
The source can be checked out anonymously from GIT with this command (See http://git-scm.com/docs/git-clone):
-$ git clone http://juplo.de/git/hibernate4-maven-plugin
Only project developers can access the GIT tree via this method (See http://git-scm.com/docs/git-clone).
-$ git clone ssh://juplo.de/var/lib/git/juplo/hibernate4-maven-plugin
- - - -
-A successful project requires many people to play many roles. Some members write code or documentation, while others are valuable as testers, submitting patches and suggestions.
-The team is comprised of Members and Contributors. Members have direct access to the source of a project and actively evolve the code-base. Contributors improve the project through submission of patches and suggestions to the Members. The number of Contributors to the project is unbounded. Get involved today. All contributions to the project are greatly appreciated.
-The following is a list of developers with commit privileges that have directly contributed to the project in one way or another.
-Image | -Id | -Name | -|
---|---|---|---|
- | kai | -Kai Moritz | -kai@juplo.de |
The following additional people have contributed to this project through the way of suggestions, patches or documentation.
-Image | -Name | -|
---|---|---|
- | Adriano Machado | -adriano.m.machado@hotmail.com |
- | Lorenzo Nicora | -lorenzo.nicora@nicus.it |
- - - -
-Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.2/testapidocs/de/juplo/test/FileComparator.html b/dist/hibernate4-maven-plugin-1.0.2/testapidocs/de/juplo/test/FileComparator.html deleted file mode 100644 index 7c4baa52..00000000 --- a/dist/hibernate4-maven-plugin-1.0.2/testapidocs/de/juplo/test/FileComparator.html +++ /dev/null @@ -1,263 +0,0 @@ - - - - - - -public class FileComparator -extends Object-
Constructor and Description | -
---|
FileComparator(File basedir) |
-
public boolean isEqual(String expectedFile, - String foundFile) - throws FileNotFoundException, - IOException-
FileNotFoundException
IOException
Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.2/testapidocs/de/juplo/test/class-use/FileComparator.html b/dist/hibernate4-maven-plugin-1.0.2/testapidocs/de/juplo/test/class-use/FileComparator.html deleted file mode 100644 index 96d63fbd..00000000 --- a/dist/hibernate4-maven-plugin-1.0.2/testapidocs/de/juplo/test/class-use/FileComparator.html +++ /dev/null @@ -1,115 +0,0 @@ - - - - - - -Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.2/testapidocs/de/juplo/test/package-frame.html b/dist/hibernate4-maven-plugin-1.0.2/testapidocs/de/juplo/test/package-frame.html deleted file mode 100644 index 32a451a8..00000000 --- a/dist/hibernate4-maven-plugin-1.0.2/testapidocs/de/juplo/test/package-frame.html +++ /dev/null @@ -1,20 +0,0 @@ - - - - - - -Class | -Description | -
---|---|
FileComparator | -- |
Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.2/testapidocs/de/juplo/test/package-tree.html b/dist/hibernate4-maven-plugin-1.0.2/testapidocs/de/juplo/test/package-tree.html deleted file mode 100644 index 6c6a155c..00000000 --- a/dist/hibernate4-maven-plugin-1.0.2/testapidocs/de/juplo/test/package-tree.html +++ /dev/null @@ -1,124 +0,0 @@ - - - - - - -Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.2/testapidocs/de/juplo/test/package-use.html b/dist/hibernate4-maven-plugin-1.0.2/testapidocs/de/juplo/test/package-use.html deleted file mode 100644 index 0eb5d488..00000000 --- a/dist/hibernate4-maven-plugin-1.0.2/testapidocs/de/juplo/test/package-use.html +++ /dev/null @@ -1,115 +0,0 @@ - - - - - - -Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.2/testapidocs/deprecated-list.html b/dist/hibernate4-maven-plugin-1.0.2/testapidocs/deprecated-list.html deleted file mode 100644 index dc3bc2b4..00000000 --- a/dist/hibernate4-maven-plugin-1.0.2/testapidocs/deprecated-list.html +++ /dev/null @@ -1,115 +0,0 @@ - - - - - - -Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.2/testapidocs/help-doc.html b/dist/hibernate4-maven-plugin-1.0.2/testapidocs/help-doc.html deleted file mode 100644 index dcf0de82..00000000 --- a/dist/hibernate4-maven-plugin-1.0.2/testapidocs/help-doc.html +++ /dev/null @@ -1,216 +0,0 @@ - - - - - - -Each package has a page that contains a list of its classes and interfaces, with a summary for each. This page can contain six categories:
-Each class, interface, nested class and nested interface has its own separate page. Each of these pages has three sections consisting of a class/interface description, summary tables, and detailed member descriptions:
-Each summary entry contains the first sentence from the detailed description for that item. The summary entries are alphabetical, while the detailed descriptions are in the order they appear in the source code. This preserves the logical groupings established by the programmer.
-Each annotation type has its own separate page with the following sections:
-Each enum has its own separate page with the following sections:
-Each documented package, class and interface has its own Use page. This page describes what packages, classes, methods, constructors and fields use any part of the given class or package. Given a class or interface A, its Use page includes subclasses of A, fields declared as A, methods that return A, and methods and constructors with parameters of type A. You can access this page by first going to the package, class or interface, then clicking on the "Use" link in the navigation bar.
-There is a Class Hierarchy page for all packages, plus a hierarchy for each package. Each hierarchy page contains a list of classes and a list of interfaces. The classes are organized by inheritance structure starting with java.lang.Object
. The interfaces do not inherit from java.lang.Object
.
The Deprecated API page lists all of the API that have been deprecated. A deprecated API is not recommended for use, generally due to improvements, and a replacement API is usually given. Deprecated APIs may be removed in future implementations.
-The Index contains an alphabetic list of all classes, interfaces, constructors, methods, and fields.
-These links take you to the next or previous class, interface, package, or related page.
-These links show and hide the HTML frames. All pages are available with or without frames.
-The All Classes link shows all classes and interfaces except non-static nested types.
-Each serializable or externalizable class has a description of its serialization fields and methods. This information is of interest to re-implementors, not to developers using the API. While there is no link in the navigation bar, you can get to this information by going to any serialized class and clicking "Serialized Form" in the "See also" section of the class description.
-The Constant Field Values page lists the static final fields and their values.
-Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.2/testapidocs/index-all.html b/dist/hibernate4-maven-plugin-1.0.2/testapidocs/index-all.html deleted file mode 100644 index 9cae0335..00000000 --- a/dist/hibernate4-maven-plugin-1.0.2/testapidocs/index-all.html +++ /dev/null @@ -1,138 +0,0 @@ - - - - - - -Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.2/testapidocs/index.html b/dist/hibernate4-maven-plugin-1.0.2/testapidocs/index.html deleted file mode 100644 index fff21be6..00000000 --- a/dist/hibernate4-maven-plugin-1.0.2/testapidocs/index.html +++ /dev/null @@ -1,65 +0,0 @@ - - - - - - -This document is designed to be viewed using the frames feature. If you see this message, you are using a non-frame-capable web client. Link to Non-frame version.
-Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.2/testapidocs/package-list b/dist/hibernate4-maven-plugin-1.0.2/testapidocs/package-list deleted file mode 100644 index 4774195e..00000000 --- a/dist/hibernate4-maven-plugin-1.0.2/testapidocs/package-list +++ /dev/null @@ -1 +0,0 @@ -de.juplo.test diff --git a/dist/hibernate4-maven-plugin-1.0.2/testapidocs/resources/background.gif b/dist/hibernate4-maven-plugin-1.0.2/testapidocs/resources/background.gif deleted file mode 100644 index f471940f..00000000 Binary files a/dist/hibernate4-maven-plugin-1.0.2/testapidocs/resources/background.gif and /dev/null differ diff --git a/dist/hibernate4-maven-plugin-1.0.2/testapidocs/resources/tab.gif b/dist/hibernate4-maven-plugin-1.0.2/testapidocs/resources/tab.gif deleted file mode 100644 index 1a73a83b..00000000 Binary files a/dist/hibernate4-maven-plugin-1.0.2/testapidocs/resources/tab.gif and /dev/null differ diff --git a/dist/hibernate4-maven-plugin-1.0.2/testapidocs/resources/titlebar.gif b/dist/hibernate4-maven-plugin-1.0.2/testapidocs/resources/titlebar.gif deleted file mode 100644 index 17443b3e..00000000 Binary files a/dist/hibernate4-maven-plugin-1.0.2/testapidocs/resources/titlebar.gif and /dev/null differ diff --git a/dist/hibernate4-maven-plugin-1.0.2/testapidocs/resources/titlebar_end.gif b/dist/hibernate4-maven-plugin-1.0.2/testapidocs/resources/titlebar_end.gif deleted file mode 100644 index 3ad78d46..00000000 Binary files a/dist/hibernate4-maven-plugin-1.0.2/testapidocs/resources/titlebar_end.gif and /dev/null differ diff --git a/dist/hibernate4-maven-plugin-1.0.2/testapidocs/stylesheet.css b/dist/hibernate4-maven-plugin-1.0.2/testapidocs/stylesheet.css deleted file mode 100644 index 0aeaa97f..00000000 --- a/dist/hibernate4-maven-plugin-1.0.2/testapidocs/stylesheet.css +++ /dev/null @@ -1,474 +0,0 @@ -/* Javadoc style sheet */ -/* -Overall document style -*/ -body { - background-color:#ffffff; - color:#353833; - font-family:Arial, Helvetica, sans-serif; - font-size:76%; - margin:0; -} -a:link, a:visited { - text-decoration:none; - color:#4c6b87; -} -a:hover, a:focus { - text-decoration:none; - color:#bb7a2a; -} -a:active { - text-decoration:none; - color:#4c6b87; -} -a[name] { - color:#353833; -} -a[name]:hover { - text-decoration:none; - color:#353833; -} -pre { - font-size:1.3em; -} -h1 { - font-size:1.8em; -} -h2 { - font-size:1.5em; -} -h3 { - font-size:1.4em; -} -h4 { - font-size:1.3em; -} -h5 { - font-size:1.2em; -} -h6 { - font-size:1.1em; -} -ul { - list-style-type:disc; -} -code, tt { - font-size:1.2em; -} -dt code { - font-size:1.2em; -} -table tr td dt code { - font-size:1.2em; - vertical-align:top; -} -sup { - font-size:.6em; -} -/* -Document title and Copyright styles -*/ -.clear { - clear:both; - height:0px; - overflow:hidden; -} -.aboutLanguage { - float:right; - padding:0px 21px; - font-size:.8em; - z-index:200; - margin-top:-7px; -} -.legalCopy { - margin-left:.5em; -} -.bar a, .bar a:link, .bar a:visited, .bar a:active { - color:#FFFFFF; - text-decoration:none; -} -.bar a:hover, .bar a:focus { - color:#bb7a2a; -} -.tab { - background-color:#0066FF; - background-image:url(resources/titlebar.gif); - background-position:left top; - background-repeat:no-repeat; - color:#ffffff; - padding:8px; - width:5em; - font-weight:bold; -} -/* -Navigation bar styles -*/ -.bar { - background-image:url(resources/background.gif); - background-repeat:repeat-x; - color:#FFFFFF; - padding:.8em .5em .4em .8em; - height:auto;/*height:1.8em;*/ - font-size:1em; - margin:0; -} -.topNav { - background-image:url(resources/background.gif); - background-repeat:repeat-x; - color:#FFFFFF; - float:left; - padding:0; - width:100%; - clear:right; - height:2.8em; - padding-top:10px; - overflow:hidden; -} -.bottomNav { - margin-top:10px; - background-image:url(resources/background.gif); - background-repeat:repeat-x; - color:#FFFFFF; - float:left; - padding:0; - width:100%; - clear:right; - height:2.8em; - padding-top:10px; - overflow:hidden; -} -.subNav { - background-color:#dee3e9; - border-bottom:1px solid #9eadc0; - float:left; - width:100%; - overflow:hidden; -} -.subNav div { - clear:left; - float:left; - padding:0 0 5px 6px; -} -ul.navList, ul.subNavList { - float:left; - margin:0 25px 0 0; - padding:0; -} -ul.navList li{ - list-style:none; - float:left; - padding:3px 6px; -} -ul.subNavList li{ - list-style:none; - float:left; - font-size:90%; -} -.topNav a:link, .topNav a:active, .topNav a:visited, .bottomNav a:link, .bottomNav a:active, .bottomNav a:visited { - color:#FFFFFF; - text-decoration:none; -} -.topNav a:hover, .bottomNav a:hover { - text-decoration:none; - color:#bb7a2a; -} -.navBarCell1Rev { - background-image:url(resources/tab.gif); - background-color:#a88834; - color:#FFFFFF; - margin: auto 5px; - border:1px solid #c9aa44; -} -/* -Page header and footer styles -*/ -.header, .footer { - clear:both; - margin:0 20px; - padding:5px 0 0 0; -} -.indexHeader { - margin:10px; - position:relative; -} -.indexHeader h1 { - font-size:1.3em; -} -.title { - color:#2c4557; - margin:10px 0; -} -.subTitle { - margin:5px 0 0 0; -} -.header ul { - margin:0 0 25px 0; - padding:0; -} -.footer ul { - margin:20px 0 5px 0; -} -.header ul li, .footer ul li { - list-style:none; - font-size:1.2em; -} -/* -Heading styles -*/ -div.details ul.blockList ul.blockList ul.blockList li.blockList h4, div.details ul.blockList ul.blockList ul.blockListLast li.blockList h4 { - background-color:#dee3e9; - border-top:1px solid #9eadc0; - border-bottom:1px solid #9eadc0; - margin:0 0 6px -8px; - padding:2px 5px; -} -ul.blockList ul.blockList ul.blockList li.blockList h3 { - background-color:#dee3e9; - border-top:1px solid #9eadc0; - border-bottom:1px solid #9eadc0; - margin:0 0 6px -8px; - padding:2px 5px; -} -ul.blockList ul.blockList li.blockList h3 { - padding:0; - margin:15px 0; -} -ul.blockList li.blockList h2 { - padding:0px 0 20px 0; -} -/* -Page layout container styles -*/ -.contentContainer, .sourceContainer, .classUseContainer, .serializedFormContainer, .constantValuesContainer { - clear:both; - padding:10px 20px; - position:relative; -} -.indexContainer { - margin:10px; - position:relative; - font-size:1.0em; -} -.indexContainer h2 { - font-size:1.1em; - padding:0 0 3px 0; -} -.indexContainer ul { - margin:0; - padding:0; -} -.indexContainer ul li { - list-style:none; -} -.contentContainer .description dl dt, .contentContainer .details dl dt, .serializedFormContainer dl dt { - font-size:1.1em; - font-weight:bold; - margin:10px 0 0 0; - color:#4E4E4E; -} -.contentContainer .description dl dd, .contentContainer .details dl dd, .serializedFormContainer dl dd { - margin:10px 0 10px 20px; -} -.serializedFormContainer dl.nameValue dt { - margin-left:1px; - font-size:1.1em; - display:inline; - font-weight:bold; -} -.serializedFormContainer dl.nameValue dd { - margin:0 0 0 1px; - font-size:1.1em; - display:inline; -} -/* -List styles -*/ -ul.horizontal li { - display:inline; - font-size:0.9em; -} -ul.inheritance { - margin:0; - padding:0; -} -ul.inheritance li { - display:inline; - list-style:none; -} -ul.inheritance li ul.inheritance { - margin-left:15px; - padding-left:15px; - padding-top:1px; -} -ul.blockList, ul.blockListLast { - margin:10px 0 10px 0; - padding:0; -} -ul.blockList li.blockList, ul.blockListLast li.blockList { - list-style:none; - margin-bottom:25px; -} -ul.blockList ul.blockList li.blockList, ul.blockList ul.blockListLast li.blockList { - padding:0px 20px 5px 10px; - border:1px solid #9eadc0; - background-color:#f9f9f9; -} -ul.blockList ul.blockList ul.blockList li.blockList, ul.blockList ul.blockList ul.blockListLast li.blockList { - padding:0 0 5px 8px; - background-color:#ffffff; - border:1px solid #9eadc0; - border-top:none; -} -ul.blockList ul.blockList ul.blockList ul.blockList li.blockList { - margin-left:0; - padding-left:0; - padding-bottom:15px; - border:none; - border-bottom:1px solid #9eadc0; -} -ul.blockList ul.blockList ul.blockList ul.blockList li.blockListLast { - list-style:none; - border-bottom:none; - padding-bottom:0; -} -table tr td dl, table tr td dl dt, table tr td dl dd { - margin-top:0; - margin-bottom:1px; -} -/* -Table styles -*/ -.contentContainer table, .classUseContainer table, .constantValuesContainer table { - border-bottom:1px solid #9eadc0; - width:100%; -} -.contentContainer ul li table, .classUseContainer ul li table, .constantValuesContainer ul li table { - width:100%; -} -.contentContainer .description table, .contentContainer .details table { - border-bottom:none; -} -.contentContainer ul li table th.colOne, .contentContainer ul li table th.colFirst, .contentContainer ul li table th.colLast, .classUseContainer ul li table th, .constantValuesContainer ul li table th, .contentContainer ul li table td.colOne, .contentContainer ul li table td.colFirst, .contentContainer ul li table td.colLast, .classUseContainer ul li table td, .constantValuesContainer ul li table td{ - vertical-align:top; - padding-right:20px; -} -.contentContainer ul li table th.colLast, .classUseContainer ul li table th.colLast,.constantValuesContainer ul li table th.colLast, -.contentContainer ul li table td.colLast, .classUseContainer ul li table td.colLast,.constantValuesContainer ul li table td.colLast, -.contentContainer ul li table th.colOne, .classUseContainer ul li table th.colOne, -.contentContainer ul li table td.colOne, .classUseContainer ul li table td.colOne { - padding-right:3px; -} -.overviewSummary caption, .packageSummary caption, .contentContainer ul.blockList li.blockList caption, .summary caption, .classUseContainer caption, .constantValuesContainer caption { - position:relative; - text-align:left; - background-repeat:no-repeat; - color:#FFFFFF; - font-weight:bold; - clear:none; - overflow:hidden; - padding:0px; - margin:0px; -} -caption a:link, caption a:hover, caption a:active, caption a:visited { - color:#FFFFFF; -} -.overviewSummary caption span, .packageSummary caption span, .contentContainer ul.blockList li.blockList caption span, .summary caption span, .classUseContainer caption span, .constantValuesContainer caption span { - white-space:nowrap; - padding-top:8px; - padding-left:8px; - display:block; - float:left; - background-image:url(resources/titlebar.gif); - height:18px; -} -.overviewSummary .tabEnd, .packageSummary .tabEnd, .contentContainer ul.blockList li.blockList .tabEnd, .summary .tabEnd, .classUseContainer .tabEnd, .constantValuesContainer .tabEnd { - width:10px; - background-image:url(resources/titlebar_end.gif); - background-repeat:no-repeat; - background-position:top right; - position:relative; - float:left; -} -ul.blockList ul.blockList li.blockList table { - margin:0 0 12px 0px; - width:100%; -} -.tableSubHeadingColor { - background-color: #EEEEFF; -} -.altColor { - background-color:#eeeeef; -} -.rowColor { - background-color:#ffffff; -} -.overviewSummary td, .packageSummary td, .contentContainer ul.blockList li.blockList td, .summary td, .classUseContainer td, .constantValuesContainer td { - text-align:left; - padding:3px 3px 3px 7px; -} -th.colFirst, th.colLast, th.colOne, .constantValuesContainer th { - background:#dee3e9; - border-top:1px solid #9eadc0; - border-bottom:1px solid #9eadc0; - text-align:left; - padding:3px 3px 3px 7px; -} -td.colOne a:link, td.colOne a:active, td.colOne a:visited, td.colOne a:hover, td.colFirst a:link, td.colFirst a:active, td.colFirst a:visited, td.colFirst a:hover, td.colLast a:link, td.colLast a:active, td.colLast a:visited, td.colLast a:hover, .constantValuesContainer td a:link, .constantValuesContainer td a:active, .constantValuesContainer td a:visited, .constantValuesContainer td a:hover { - font-weight:bold; -} -td.colFirst, th.colFirst { - border-left:1px solid #9eadc0; - white-space:nowrap; -} -td.colLast, th.colLast { - border-right:1px solid #9eadc0; -} -td.colOne, th.colOne { - border-right:1px solid #9eadc0; - border-left:1px solid #9eadc0; -} -table.overviewSummary { - padding:0px; - margin-left:0px; -} -table.overviewSummary td.colFirst, table.overviewSummary th.colFirst, -table.overviewSummary td.colOne, table.overviewSummary th.colOne { - width:25%; - vertical-align:middle; -} -table.packageSummary td.colFirst, table.overviewSummary th.colFirst { - width:25%; - vertical-align:middle; -} -/* -Content styles -*/ -.description pre { - margin-top:0; -} -.deprecatedContent { - margin:0; - padding:10px 0; -} -.docSummary { - padding:0; -} -/* -Formatting effect styles -*/ -.sourceLineNo { - color:green; - padding:0 30px 0 0; -} -h1.hidden { - visibility:hidden; - overflow:hidden; - font-size:.9em; -} -.block { - display:block; - margin:3px 0 0 0; -} -.strong { - font-weight:bold; -} diff --git a/dist/hibernate4-maven-plugin-1.0.2/xref-test/allclasses-frame.html b/dist/hibernate4-maven-plugin-1.0.2/xref-test/allclasses-frame.html deleted file mode 100644 index 4c39da54..00000000 --- a/dist/hibernate4-maven-plugin-1.0.2/xref-test/allclasses-frame.html +++ /dev/null @@ -1,20 +0,0 @@ - - - - - -- -1 package de.juplo.test; -2 -3 import java.io.BufferedReader; -4 import java.io.File; -5 import java.io.FileNotFoundException; -6 import java.io.FileReader; -7 import java.io.IOException; -8 -9 -10 public class FileComparator -11 { -12 private final File basedir; -13 private BufferedReader expectedReader; -14 private BufferedReader foundReader; -15 -16 public FileComparator(File basedir) -17 { -18 this.basedir = basedir; -19 } -20 -21 public boolean isEqual(final String expectedFile, final String foundFile) -22 throws -23 FileNotFoundException, -24 IOException -25 { -26 File file; -27 String expected, found; -28 -29 file = new File(basedir, expectedFile); -30 expectedReader = new BufferedReader(new FileReader(file)); -31 -32 file = new File(basedir, foundFile); -33 foundReader = new BufferedReader(new FileReader(file)); -34 -35 -36 while ((expected = expectedReader.readLine()) != null) -37 { -38 found = foundReader.readLine(); -39 if (!expected.equals(found)) -40 { -41 System.err.println("Mismatch!"); -42 System.err.println("Expected: " + expected); -43 System.err.println("Found: " + found); -44 return false; -45 } -46 } -47 -48 if ((found = foundReader.readLine()) != null) -49 { -50 System.err.println("Found more content than expected!"); -51 System.err.println("Starting with: " + found); -52 return false; -53 } -54 -55 return true; -56 } -57 } --
Class Summary | -
---|
- FileComparator - | -
- You don't have frames. Go here -
- -Packages | -
---|
- de.juplo.test - | -
- -1 package de.juplo.plugins.hibernate4; -2 -3 /* -4 * Copyright 2001-2005 The Apache Software Foundation. -5 * -6 * Licensed under the Apache License, Version 2.0 (the "License"); -7 * you may not use this file except in compliance with the License. -8 * You may obtain a copy of the License at -9 * -10 * http://www.apache.org/licenses/LICENSE-2.0 -11 * -12 * Unless required by applicable law or agreed to in writing, software -13 * distributed under the License is distributed on an "AS IS" BASIS, -14 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -15 * See the License for the specific language governing permissions and -16 * limitations under the License. -17 */ -18 -19 import com.pyx4j.log4j.MavenLogAppender; -20 import java.io.File; -21 import java.io.FileInputStream; -22 import java.io.FileNotFoundException; -23 import java.io.FileOutputStream; -24 import java.io.IOException; -25 import java.io.InputStream; -26 import java.io.ObjectInputStream; -27 import java.io.ObjectOutputStream; -28 import java.math.BigInteger; -29 import java.net.URL; -30 import java.net.URLClassLoader; -31 import java.security.MessageDigest; -32 import java.security.NoSuchAlgorithmException; -33 import java.sql.Connection; -34 import java.sql.Driver; -35 import java.sql.DriverManager; -36 import java.sql.DriverPropertyInfo; -37 import java.sql.SQLException; -38 import java.sql.SQLFeatureNotSupportedException; -39 import java.util.Comparator; -40 import java.util.Enumeration; -41 import java.util.HashMap; -42 import java.util.HashSet; -43 import java.util.List; -44 import java.util.Map; -45 import java.util.Map.Entry; -46 import java.util.Properties; -47 import java.util.Set; -48 import java.util.TreeSet; -49 import java.util.logging.Logger; -50 import javax.persistence.Embeddable; -51 import javax.persistence.Entity; -52 import javax.persistence.MappedSuperclass; -53 import org.apache.maven.model.Resource; -54 import org.apache.maven.plugin.AbstractMojo; -55 import org.apache.maven.plugin.MojoExecutionException; -56 import org.apache.maven.plugin.MojoFailureException; -57 import org.apache.maven.project.MavenProject; -58 import org.hibernate.cfg.Configuration; -59 import org.hibernate.cfg.NamingStrategy; -60 import org.hibernate.tool.hbm2ddl.SchemaExport; -61 import org.hibernate.tool.hbm2ddl.SchemaExport.Type; -62 import org.hibernate.tool.hbm2ddl.Target; -63 import org.scannotation.AnnotationDB; -64 -65 -66 /** -67 * Goal which extracts the hibernate-mapping-configuration and -68 * exports an according SQL-database-schema. -69 * -70 * @goal export -71 * @phase process-classes -72 * @threadSafe -73 * @requiresDependencyResolution runtime -74 */ -75 public class Hbm2DdlMojo extends AbstractMojo -76 { -77 public final static String EXPORT_SKIPPED_PROPERTY = "hibernate.export.skipped"; -78 -79 public final static String DRIVER_CLASS = "hibernate.connection.driver_class"; -80 public final static String URL = "hibernate.connection.url"; -81 public final static String USERNAME = "hibernate.connection.username"; -82 public final static String PASSWORD = "hibernate.connection.password"; -83 public final static String DIALECT = "hibernate.dialect"; -84 public final static String NAMING_STRATEGY="hibernate.ejb.naming_strategy"; -85 -86 private final static String MD5S = "schema.md5s"; -87 -88 /** -89 * The maven project. -90 * <p> -91 * Only needed internally. -92 * -93 * @parameter property="project" -94 * @required -95 * @readonly -96 */ -97 private MavenProject project; -98 -99 /** -100 * Build-directory. -101 * <p> -102 * Only needed internally. -103 * -104 * @parameter property="project.build.directory" -105 * @required -106 * @readonly -107 */ -108 private String buildDirectory; -109 -110 /** -111 * Classes-Directory to scan. -112 * <p> -113 * This parameter defaults to the maven build-output-directory for classes. -114 * Additonally, all dependencies are scanned for annotated classes. -115 * -116 * @parameter property="project.build.outputDirectory" -117 */ -118 private String outputDirectory; -119 -120 /** -121 * Wether to scan test-classes too, or not. -122 * <p> -123 * If this parameter is set to <code>true</code> the test-classes of the -124 * artifact will be scanned for hibernate-annotated classes additionally. -125 * -126 * @parameter property="hibernate.export.scan_testclasses" default-value="false" -127 */ -128 private boolean scanTestClasses; -129 -130 /** -131 * Test-Classes-Directory to scan. -132 * <p> -133 * This parameter defaults to the maven build-output-directory for -134 * test-classes. -135 * <p> -136 * This parameter is only used, when <code>scanTestClasses</code> is set -137 * to <code>true</code>! -138 * -139 * @parameter property="project.build.testOutputDirectory" -140 */ -141 private String testOutputDirectory; -142 -143 /** -144 * Skip execution -145 * <p> -146 * If set to <code>true</code>, the execution is skipped. -147 * <p> -148 * A skipped excecution is signaled via the maven-property -149 * <code>${hibernate.export.skipped}</code>. -150 * <p> -151 * The excecution is skipped automatically, if no modified or newly added -152 * annotated classes are found and the dialect was not changed. -153 * -154 * @parameter property="maven.test.skip" default-value="false" -155 */ -156 private boolean skip; -157 -158 /** -159 * Force execution -160 * <p> -161 * Force execution, even if no modified or newly added annotated classes -162 * where found and the dialect was not changed. -163 * <p> -164 * <code>skip</code> takes precedence over <code>force</code>. -165 * -166 * @parameter property="hibernate.export.force" default-value="false" -167 */ -168 private boolean force; -169 -170 /** -171 * SQL-Driver name. -172 * -173 * @parameter property="hibernate.connection.driver_class" -174 */ -175 private String driverClassName; -176 -177 /** -178 * Database URL. -179 * -180 * @parameter property="hibernate.connection.url" -181 */ -182 private String url; -183 -184 /** -185 * Database username -186 * -187 * @parameter property="hibernate.connection.username" -188 */ -189 private String username; -190 -191 /** -192 * Database password -193 * -194 * @parameter property="hibernate.connection.password" -195 */ -196 private String password; -197 -198 /** -199 * Hibernate dialect. -200 * -201 * @parameter property="hibernate.dialect" -202 */ -203 private String hibernateDialect; -204 -205 /** -206 * Hibernate Naming Strategy -207 * @parameter property="hibernate.ejb.naming_strategy" -208 */ -209 private String hibernateNamingStrategy; -210 -211 /** -212 * Path to Hibernate configuration file. -213 * -214 * @parameter default-value="${project.build.outputDirectory}/hibernate.properties" -215 */ -216 private String hibernateProperties; -217 -218 /** -219 * List of Hibernate-Mapping-Files (XML). -220 * Multiple files can be separated with white-spaces and/or commas. -221 * -222 * @parameter property="hibernate.mapping" -223 */ -224 private String hibernateMapping; -225 -226 /** -227 * Target of execution: -228 * <ul> -229 * <li><strong>NONE</strong> only export schema to SQL-script (forces excecution, signals skip)</li> -230 * <li><strong>EXPORT</strong> create database (<strong>DEFAULT!</strong>). forces excecution, signals skip)</li> -231 * <li><strong>SCRIPT</strong> export schema to SQL-script and print it to STDOUT</li> -232 * <li><strong>BOTH</strong></li> -233 * </ul> -234 * -235 * A databaseconnection is only needed for EXPORT and BOTH, but a -236 * Hibernate-Dialect must always be choosen. -237 * -238 * @parameter property="hibernate.export.target" default-value="EXPORT" -239 */ -240 private String target; -241 -242 /** -243 * Type of execution. -244 * <ul> -245 * <li><strong>NONE</strong> do nothing - just validate the configuration</li> -246 * <li><strong>CREATE</strong> create database-schema</li> -247 * <li><strong>DROP</strong> drop database-schema</li> -248 * <li><strong>BOTH</strong> (<strong>DEFAULT!</strong>)</li> -249 * </ul> -250 * -251 * If NONE is choosen, no databaseconnection is needed. -252 * -253 * @parameter property="hibernate.export.type" default-value="BOTH" -254 */ -255 private String type; -256 -257 /** -258 * Output file. -259 * -260 * @parameter property="hibernate.export.schema.filename" default-value="${project.build.directory}/schema.sql" -261 */ -262 private String outputFile; -263 -264 /** -265 * Delimiter in output-file. -266 * -267 * @parameter property="hibernate.export.schema.delimiter" default-value=";" -268 */ -269 private String delimiter; -270 -271 /** -272 * Format output-file. -273 * -274 * @parameter property="hibernate.export.schema.format" default-value="true" -275 */ -276 private boolean format; -277 -278 -279 @Override -280 public void execute() -281 throws -282 MojoFailureException, -283 MojoExecutionException -284 { -285 if (skip) -286 { -287 getLog().info("Exectuion of hibernate4-maven-plugin:export was skipped!"); -288 project.getProperties().setProperty(EXPORT_SKIPPED_PROPERTY, "true"); -289 return; -290 } -291 -292 File dir = new File(outputDirectory); -293 if (!dir.exists()) -294 throw new MojoExecutionException("Cannot scan for annotated classes in " + outputDirectory + ": directory does not exist!"); -295 -296 Map<String,String> md5s; -297 boolean modified = false; -298 File saved = new File(buildDirectory + File.separator + MD5S); -299 -300 if (saved.exists()) -301 { -302 try -303 { -304 FileInputStream fis = new FileInputStream(saved); -305 ObjectInputStream ois = new ObjectInputStream(fis); -306 md5s = (HashMap<String,String>)ois.readObject(); -307 ois.close(); -308 } -309 catch (Exception e) -310 { -311 md5s = new HashMap<String,String>(); -312 getLog().warn("Cannot read timestamps from saved: " + e); -313 } -314 } -315 else -316 { -317 md5s = new HashMap<String,String>(); -318 try -319 { -320 saved.createNewFile(); -321 } -322 catch (IOException e) -323 { -324 getLog().warn("Cannot create saved for timestamps: " + e); -325 } -326 } -327 -328 ClassLoader classLoader = null; -329 try -330 { -331 getLog().debug("Creating ClassLoader for project-dependencies..."); -332 List<String> classpathFiles = project.getCompileClasspathElements(); -333 if (scanTestClasses) -334 classpathFiles.addAll(project.getTestClasspathElements()); -335 URL[] urls = new URL[classpathFiles.size()]; -336 for (int i = 0; i < classpathFiles.size(); ++i) -337 { -338 getLog().debug("Dependency: " + classpathFiles.get(i)); -339 urls[i] = new File(classpathFiles.get(i)).toURI().toURL(); -340 } -341 classLoader = new URLClassLoader(urls, getClass().getClassLoader()); -342 } -343 catch (Exception e) -344 { -345 getLog().error("Error while creating ClassLoader!", e); -346 throw new MojoExecutionException(e.getMessage()); -347 } -348 -349 Set<Class<?>> classes = -350 new TreeSet<Class<?>>( -351 new Comparator<Class<?>>() { -352 @Override -353 public int compare(Class<?> a, Class<?> b) -354 { -355 return a.getName().compareTo(b.getName()); -356 } -357 } -358 ); -359 -360 try -361 { -362 AnnotationDB db = new AnnotationDB(); -363 getLog().info("Scanning directory " + outputDirectory + " for annotated classes..."); -364 URL dirUrl = dir.toURI().toURL(); -365 db.scanArchives(dirUrl); -366 if (scanTestClasses) -367 { -368 dir = new File(testOutputDirectory); -369 if (!dir.exists()) -370 throw new MojoExecutionException("Cannot scan for annotated test-classes in " + testOutputDirectory + ": directory does not exist!"); -371 getLog().info("Scanning directory " + testOutputDirectory + " for annotated classes..."); -372 dirUrl = dir.toURI().toURL(); -373 db.scanArchives(dirUrl); -374 } -375 -376 Set<String> classNames = new HashSet<String>(); -377 if (db.getAnnotationIndex().containsKey(Entity.class.getName())) -378 classNames.addAll(db.getAnnotationIndex().get(Entity.class.getName())); -379 if (db.getAnnotationIndex().containsKey(MappedSuperclass.class.getName())) -380 classNames.addAll(db.getAnnotationIndex().get(MappedSuperclass.class.getName())); -381 if (db.getAnnotationIndex().containsKey(Embeddable.class.getName())) -382 classNames.addAll(db.getAnnotationIndex().get(Embeddable.class.getName())); -383 -384 MessageDigest digest = java.security.MessageDigest.getInstance("MD5"); -385 for (String name : classNames) -386 { -387 Class<?> annotatedClass = classLoader.loadClass(name); -388 classes.add(annotatedClass); -389 InputStream is = -390 annotatedClass -391 .getResourceAsStream(annotatedClass.getSimpleName() + ".class"); -392 byte[] buffer = new byte[1024*4]; // copy data in 4MB-chunks -393 int i; -394 while((i = is.read(buffer)) > -1) -395 digest.update(buffer, 0, i); -396 is.close(); -397 byte[] bytes = digest.digest(); -398 BigInteger bi = new BigInteger(1, bytes); -399 String newMd5 = String.format("%0" + (bytes.length << 1) + "x", bi); -400 String oldMd5 = !md5s.containsKey(name) ? "" : md5s.get(name); -401 if (!newMd5.equals(oldMd5)) -402 { -403 getLog().debug("Found new or modified annotated class: " + name); -404 modified = true; -405 md5s.put(name, newMd5); -406 } -407 else -408 { -409 getLog().debug(oldMd5 + " -> class unchanged: " + name); -410 } -411 } -412 } -413 catch (ClassNotFoundException e) -414 { -415 getLog().error("Error while adding annotated classes!", e); -416 throw new MojoExecutionException(e.getMessage()); -417 } -418 catch (Exception e) -419 { -420 getLog().error("Error while scanning!", e); -421 throw new MojoFailureException(e.getMessage()); -422 } -423 -424 if (classes.isEmpty()) -425 { -426 if (hibernateMapping == null || hibernateMapping.isEmpty()) -427 throw new MojoFailureException("No annotated classes found in directory " + outputDirectory); -428 } -429 else -430 { -431 getLog().debug("Detected classes with mapping-annotations:"); -432 for (Class<?> annotatedClass : classes) -433 getLog().debug(" " + annotatedClass.getName()); -434 } -435 -436 -437 Properties properties = new Properties(); -438 -439 /** Try to read configuration from properties-file */ -440 try -441 { -442 File file = new File(hibernateProperties); -443 if (file.exists()) -444 { -445 getLog().info("Reading properties from file " + hibernateProperties + "..."); -446 properties.load(new FileInputStream(file)); -447 } -448 else -449 getLog().info("No hibernate-properties-file found! (Checked path: " + hibernateProperties + ")"); -450 } -451 catch (IOException e) -452 { -453 getLog().error("Error while reading properties!", e); -454 throw new MojoExecutionException(e.getMessage()); -455 } -456 -457 /** Overwrite values from propertie-file or set, if given */ -458 if (driverClassName != null) -459 { -460 if (properties.containsKey(DRIVER_CLASS)) -461 getLog().debug( -462 "Overwriting property " + -463 DRIVER_CLASS + "=" + properties.getProperty(DRIVER_CLASS) + -464 " with the value " + driverClassName -465 ); -466 else -467 getLog().debug("Using the value " + driverClassName); -468 properties.setProperty(DRIVER_CLASS, driverClassName); -469 } -470 if (url != null) -471 { -472 if (properties.containsKey(URL)) -473 getLog().debug( -474 "Overwriting property " + -475 URL + "=" + properties.getProperty(URL) + -476 " with the value " + url -477 ); -478 else -479 getLog().debug("Using the value " + url); -480 properties.setProperty(URL, url); -481 } -482 if (username != null) -483 { -484 if (properties.containsKey(USERNAME)) -485 getLog().debug( -486 "Overwriting property " + -487 USERNAME + "=" + properties.getProperty(USERNAME) + -488 " with the value " + username -489 ); -490 else -491 getLog().debug("Using the value " + username); -492 properties.setProperty(USERNAME, username); -493 } -494 if (password != null) -495 { -496 if (properties.containsKey(PASSWORD)) -497 getLog().debug( -498 "Overwriting property " + -499 PASSWORD + "=" + properties.getProperty(PASSWORD) + -500 " with the value " + password -501 ); -502 else -503 getLog().debug("Using the value " + password); -504 properties.setProperty(PASSWORD, password); -505 } -506 if (hibernateDialect != null) -507 { -508 if (properties.containsKey(DIALECT)) -509 getLog().debug( -510 "Overwriting property " + -511 DIALECT + "=" + properties.getProperty(DIALECT) + -512 " with the value " + hibernateDialect -513 ); -514 else -515 getLog().debug("Using the value " + hibernateDialect); -516 properties.setProperty(DIALECT, hibernateDialect); -517 } -518 if ( hibernateNamingStrategy != null ) -519 { -520 if ( properties.contains(NAMING_STRATEGY)) -521 getLog().debug( -522 "Overwriting property " + -523 NAMING_STRATEGY + "=" + properties.getProperty(NAMING_STRATEGY) + -524 " with the value " + hibernateNamingStrategy -525 ); -526 else -527 getLog().debug("Using the value " + hibernateNamingStrategy); -528 properties.setProperty(NAMING_STRATEGY, hibernateNamingStrategy); -529 } -530 -531 /** The generated SQL varies with the dialect! */ -532 if (md5s.containsKey(DIALECT)) -533 { -534 String dialect = properties.getProperty(DIALECT); -535 if (md5s.get(DIALECT).equals(dialect)) -536 getLog().debug("SQL-dialect unchanged."); -537 else -538 { -539 getLog().debug("SQL-dialect changed: " + dialect); -540 modified = true; -541 md5s.put(DIALECT, dialect); -542 } -543 } -544 else -545 { -546 modified = true; -547 md5s.put(DIALECT, properties.getProperty(DIALECT)); -548 } -549 -550 if (properties.isEmpty()) -551 { -552 getLog().error("No properties set!"); -553 throw new MojoFailureException("Hibernate-Configuration is missing!"); -554 } -555 -556 Configuration config = new Configuration(); -557 config.setProperties(properties); -558 -559 if ( properties.containsKey(NAMING_STRATEGY)) -560 { -561 String namingStrategy = properties.getProperty(NAMING_STRATEGY); -562 getLog().debug("Explicitly set NamingStrategy: " + namingStrategy); -563 try -564 { -565 @SuppressWarnings("unchecked") -566 Class<NamingStrategy> namingStrategyClass = (Class<NamingStrategy>) Class.forName(namingStrategy); -567 config.setNamingStrategy(namingStrategyClass.newInstance()); -568 } -569 catch (Exception e) -570 { -571 getLog().error("Error setting NamingStrategy", e); -572 throw new MojoExecutionException(e.getMessage()); -573 } -574 } -575 -576 getLog().debug("Adding annotated classes to hibernate-mapping-configuration..."); -577 for (Class<?> annotatedClass : classes) -578 { -579 getLog().debug("Class " + annotatedClass); -580 config.addAnnotatedClass(annotatedClass); -581 } -582 -583 if (hibernateMapping != null) -584 { -585 try -586 { -587 MessageDigest digest = java.security.MessageDigest.getInstance("MD5"); -588 for (String filename : hibernateMapping.split("[\\s,]+")) -589 { -590 // First try the filename as absolute/relative path -591 File file = new File(filename); -592 if (!file.exists()) -593 { -594 // If the file was not found, search for it in the resource-directories -595 for (Resource resource : project.getResources()) -596 { -597 file = new File(resource.getDirectory() + File.separator + filename); -598 if (file.exists()) -599 break; -600 } -601 } -602 if (file != null && file.exists()) -603 { -604 InputStream is = new FileInputStream(file); -605 byte[] buffer = new byte[1024*4]; // copy data in 4MB-chunks -606 int i; -607 while((i = is.read(buffer)) > -1) -608 digest.update(buffer, 0, i); -609 is.close(); -610 byte[] bytes = digest.digest(); -611 BigInteger bi = new BigInteger(1, bytes); -612 String newMd5 = String.format("%0" + (bytes.length << 1) + "x", bi); -613 String oldMd5 = !md5s.containsKey(filename) ? "" : md5s.get(filename); -614 if (!newMd5.equals(oldMd5)) -615 { -616 getLog().debug("Found new or modified mapping-file: " + filename); -617 modified = true; -618 md5s.put(filename, newMd5); -619 } -620 else -621 { -622 getLog().debug(oldMd5 + " -> mapping-file unchanged: " + filename); -623 } -624 getLog().debug("Adding mappings from XML-configurationfile: " + file); -625 config.addFile(file); -626 } -627 else -628 throw new MojoFailureException("File " + filename + " could not be found in any of the configured resource-directories!"); -629 } -630 } -631 catch (NoSuchAlgorithmException e) -632 { -633 throw new MojoFailureException("Cannot calculate MD5-summs!", e); -634 } -635 catch (FileNotFoundException e) -636 { -637 throw new MojoFailureException("Cannot calculate MD5-summs!", e); -638 } -639 catch (IOException e) -640 { -641 throw new MojoFailureException("Cannot calculate MD5-summs!", e); -642 } -643 } -644 -645 Target target = null; -646 try -647 { -648 target = Target.valueOf(this.target.toUpperCase()); -649 } -650 catch (IllegalArgumentException e) -651 { -652 getLog().error("Invalid value for configuration-option \"target\": " + this.target); -653 getLog().error("Valid values are: NONE, SCRIPT, EXPORT, BOTH"); -654 throw new MojoExecutionException("Invalid value for configuration-option \"target\""); -655 } -656 Type type = null; -657 try -658 { -659 type = Type.valueOf(this.type.toUpperCase()); -660 } -661 catch (IllegalArgumentException e) -662 { -663 getLog().error("Invalid value for configuration-option \"type\": " + this.type); -664 getLog().error("Valid values are: NONE, CREATE, DROP, BOTH"); -665 throw new MojoExecutionException("Invalid value for configuration-option \"type\""); -666 } -667 -668 if (target.equals(Target.SCRIPT) || target.equals(Target.NONE)) -669 { -670 project.getProperties().setProperty(EXPORT_SKIPPED_PROPERTY, "true"); -671 } -672 if ( -673 !modified -674 && !target.equals(Target.SCRIPT) -675 && !target.equals(Target.NONE) -676 && !force -677 ) -678 { -679 getLog().info("No modified annotated classes or mapping-files found and dialect unchanged."); -680 getLog().info("Skipping schema generation!"); -681 project.getProperties().setProperty(EXPORT_SKIPPED_PROPERTY, "true"); -682 return; -683 } -684 -685 getLog().info("Gathered hibernate-configuration (turn on debugging for details):"); -686 for (Entry<Object,Object> entry : properties.entrySet()) -687 getLog().info(" " + entry.getKey() + " = " + entry.getValue()); -688 -689 Connection connection = null; -690 try -691 { -692 /** -693 * The connection must be established outside of hibernate, because -694 * hibernate does not use the context-classloader of the current -695 * thread and, hence, would not be able to resolve the driver-class! -696 */ -697 getLog().debug("Target: " + target + ", Type: " + type); -698 switch (target) -699 { -700 case EXPORT: -701 case BOTH: -702 switch (type) -703 { -704 case CREATE: -705 case DROP: -706 case BOTH: -707 Class driverClass = classLoader.loadClass(properties.getProperty(DRIVER_CLASS)); -708 getLog().debug("Registering JDBC-driver " + driverClass.getName()); -709 DriverManager.registerDriver(new DriverProxy((Driver)driverClass.newInstance())); -710 getLog().debug( -711 "Opening JDBC-connection to " -712 + properties.getProperty(URL) -713 + " as " -714 + properties.getProperty(USERNAME) -715 + " with password " -716 + properties.getProperty(PASSWORD) -717 ); -718 connection = DriverManager.getConnection( -719 properties.getProperty(URL), -720 properties.getProperty(USERNAME), -721 properties.getProperty(PASSWORD) -722 ); -723 } -724 } -725 } -726 catch (ClassNotFoundException e) -727 { -728 getLog().error("Dependency for driver-class " + properties.getProperty(DRIVER_CLASS) + " is missing!"); -729 throw new MojoExecutionException(e.getMessage()); -730 } -731 catch (Exception e) -732 { -733 getLog().error("Cannot establish connection to database!"); -734 Enumeration<Driver> drivers = DriverManager.getDrivers(); -735 if (!drivers.hasMoreElements()) -736 getLog().error("No drivers registered!"); -737 while (drivers.hasMoreElements()) -738 getLog().debug("Driver: " + drivers.nextElement()); -739 throw new MojoExecutionException(e.getMessage()); -740 } -741 -742 ClassLoader contextClassLoader = Thread.currentThread().getContextClassLoader(); -743 MavenLogAppender.startPluginLog(this); -744 try -745 { -746 /** -747 * Change class-loader of current thread, so that hibernate can -748 * see all dependencies! -749 */ -750 Thread.currentThread().setContextClassLoader(classLoader); -751 -752 SchemaExport export = new SchemaExport(config, connection); -753 export.setOutputFile(outputFile); -754 export.setDelimiter(delimiter); -755 export.setFormat(format); -756 export.execute(target, type); -757 -758 for (Object exception : export.getExceptions()) -759 getLog().debug(exception.toString()); -760 } -761 finally -762 { -763 /** Stop Log-Capturing */ -764 MavenLogAppender.endPluginLog(this); -765 -766 /** Restore the old class-loader (TODO: is this really necessary?) */ -767 Thread.currentThread().setContextClassLoader(contextClassLoader); -768 -769 /** Close the connection */ -770 try -771 { -772 if (connection != null) -773 connection.close(); -774 } -775 catch (SQLException e) -776 { -777 getLog().error("Error while closing connection: " + e.getMessage()); -778 } -779 } -780 -781 /** Write md5-sums for annotated classes to file */ -782 try -783 { -784 FileOutputStream fos = new FileOutputStream(saved); -785 ObjectOutputStream oos = new ObjectOutputStream(fos); -786 oos.writeObject(md5s); -787 oos.close(); -788 fos.close(); -789 } -790 catch (Exception e) -791 { -792 getLog().error("Cannot write md5-sums to file: " + e); -793 } -794 } -795 -796 /** -797 * Needed, because DriverManager won't pick up drivers, that were not -798 * loaded by the system-classloader! -799 * See: -800 * http://stackoverflow.com/questions/288828/how-to-use-a-jdbc-driver-fromodifiedm-an-arbitrary-location -801 */ -802 static final class DriverProxy implements Driver -803 { -804 private final Driver target; -805 -806 DriverProxy(Driver target) -807 { -808 if (target == null) -809 throw new NullPointerException(); -810 this.target = target; -811 } -812 -813 public java.sql.Driver getTarget() -814 { -815 return target; -816 } -817 -818 @Override -819 public boolean acceptsURL(String url) throws SQLException -820 { -821 return target.acceptsURL(url); -822 } -823 -824 @Override -825 public java.sql.Connection connect( -826 String url, -827 java.util.Properties info -828 ) -829 throws -830 SQLException -831 { -832 return target.connect(url, info); -833 } -834 -835 @Override -836 public int getMajorVersion() -837 { -838 return target.getMajorVersion(); -839 } -840 -841 @Override -842 public int getMinorVersion() -843 { -844 return target.getMinorVersion(); -845 } -846 -847 @Override -848 public DriverPropertyInfo[] getPropertyInfo( -849 String url, -850 Properties info -851 ) -852 throws -853 SQLException -854 { -855 return target.getPropertyInfo(url, info); -856 } -857 -858 @Override -859 public boolean jdbcCompliant() -860 { -861 return target.jdbcCompliant(); -862 } -863 -864 /** -865 * This Method cannot be annotated with @Override, becaus the plugin -866 * will not compile then under Java 1.6! -867 */ -868 public Logger getParentLogger() throws SQLFeatureNotSupportedException -869 { -870 throw new SQLFeatureNotSupportedException("Not supported, for backward-compatibility with Java 1.6"); -871 } -872 -873 @Override -874 public String toString() -875 { -876 return "Proxy: " + target; -877 } -878 -879 @Override -880 public int hashCode() -881 { -882 return target.hashCode(); -883 } -884 -885 @Override -886 public boolean equals(Object obj) -887 { -888 if (!(obj instanceof DriverProxy)) -889 return false; -890 DriverProxy other = (DriverProxy) obj; -891 return this.target.equals(other.target); -892 } -893 } -894 } --
- -1 package de.juplo.plugins.hibernate4; -2 -3 import org.apache.maven.plugin.AbstractMojo; -4 import org.apache.maven.plugin.MojoExecutionException; -5 -6 import org.w3c.dom.Document; -7 import org.w3c.dom.Element; -8 import org.w3c.dom.Node; -9 import org.w3c.dom.NodeList; -10 import org.xml.sax.SAXException; -11 -12 import javax.xml.parsers.DocumentBuilder; -13 import javax.xml.parsers.DocumentBuilderFactory; -14 import javax.xml.parsers.ParserConfigurationException; -15 import java.io.IOException; -16 import java.io.InputStream; -17 import java.util.ArrayList; -18 import java.util.Iterator; -19 import java.util.List; -20 -21 /** -22 * Display help information on hibernate4-maven-plugin.<br/> -23 * Call <code>mvn hibernate4:help -Ddetail=true -Dgoal=<goal-name></code> to display parameter details. -24 * @author -25 * @version -26 * @goal help -27 * @requiresProject false -28 * @threadSafe -29 */ -30 public class HelpMojo -31 extends AbstractMojo -32 { -33 /** -34 * If <code>true</code>, display all settable properties for each goal. -35 * -36 * @parameter property="detail" default-value="false" -37 */ -38 private boolean detail; -39 -40 /** -41 * The name of the goal for which to show help. If unspecified, all goals will be displayed. -42 * -43 * @parameter property="goal" -44 */ -45 private java.lang.String goal; -46 -47 /** -48 * The maximum length of a display line, should be positive. -49 * -50 * @parameter property="lineLength" default-value="80" -51 */ -52 private int lineLength; -53 -54 /** -55 * The number of spaces per indentation level, should be positive. -56 * -57 * @parameter property="indentSize" default-value="2" -58 */ -59 private int indentSize; -60 -61 // groupId/artifactId/plugin-help.xml -62 private static final String PLUGIN_HELP_PATH = "/META-INF/maven/de.juplo/hibernate4-maven-plugin/plugin-help.xml"; -63 -64 private Document build() -65 throws MojoExecutionException -66 { -67 getLog().debug( "load plugin-help.xml: " + PLUGIN_HELP_PATH ); -68 InputStream is = getClass().getResourceAsStream( PLUGIN_HELP_PATH ); -69 try -70 { -71 DocumentBuilderFactory dbFactory = DocumentBuilderFactory.newInstance(); -72 DocumentBuilder dBuilder = dbFactory.newDocumentBuilder(); -73 return dBuilder.parse( is ); -74 } -75 catch ( IOException e ) -76 { -77 throw new MojoExecutionException( e.getMessage(), e ); -78 } -79 catch ( ParserConfigurationException e ) -80 { -81 throw new MojoExecutionException( e.getMessage(), e ); -82 } -83 catch ( SAXException e ) -84 { -85 throw new MojoExecutionException( e.getMessage(), e ); -86 } -87 } -88 -89 /** -90 * {@inheritDoc} -91 */ -92 public void execute() -93 throws MojoExecutionException -94 { -95 if ( lineLength <= 0 ) -96 { -97 getLog().warn( "The parameter 'lineLength' should be positive, using '80' as default." ); -98 lineLength = 80; -99 } -100 if ( indentSize <= 0 ) -101 { -102 getLog().warn( "The parameter 'indentSize' should be positive, using '2' as default." ); -103 indentSize = 2; -104 } -105 -106 Document doc = build(); -107 -108 StringBuilder sb = new StringBuilder(); -109 Node plugin = getSingleChild( doc, "plugin" ); -110 -111 -112 String name = getValue( plugin, "name" ); -113 String version = getValue( plugin, "version" ); -114 String id = getValue( plugin, "groupId" ) + ":" + getValue( plugin, "artifactId" ) + ":" + version; -115 if ( isNotEmpty( name ) && !name.contains( id ) ) -116 { -117 append( sb, name + " " + version, 0 ); -118 } -119 else -120 { -121 if ( isNotEmpty( name ) ) -122 { -123 append( sb, name, 0 ); -124 } -125 else -126 { -127 append( sb, id, 0 ); -128 } -129 } -130 append( sb, getValue( plugin, "description" ), 1 ); -131 append( sb, "", 0 ); -132 -133 //<goalPrefix>plugin</goalPrefix> -134 String goalPrefix = getValue( plugin, "goalPrefix" ); -135 -136 Node mojos1 = getSingleChild( plugin, "mojos" ); -137 -138 List<Node> mojos = findNamedChild( mojos1, "mojo" ); -139 -140 if ( goal == null || goal.length() <= 0 ) -141 { -142 append( sb, "This plugin has " + mojos.size() + ( mojos.size() > 1 ? " goals:" : " goal:" ), 0 ); -143 append( sb, "", 0 ); -144 } -145 -146 for ( Node mojo : mojos ) -147 { -148 writeGoal( sb, goalPrefix, (Element) mojo ); -149 } -150 -151 if ( getLog().isInfoEnabled() ) -152 { -153 getLog().info( sb.toString() ); -154 } -155 } -156 -157 -158 private static boolean isNotEmpty( String string ) -159 { -160 return string != null && string.length() > 0; -161 } -162 -163 private String getValue( Node node, String elementName ) -164 throws MojoExecutionException -165 { -166 return getSingleChild( node, elementName ).getTextContent(); -167 } -168 -169 private Node getSingleChild( Node node, String elementName ) -170 throws MojoExecutionException -171 { -172 List<Node> namedChild = findNamedChild( node, elementName ); -173 if ( namedChild.isEmpty() ) -174 { -175 throw new MojoExecutionException( "Could not find " + elementName + " in plugin-help.xml" ); -176 } -177 if ( namedChild.size() > 1 ) -178 { -179 throw new MojoExecutionException( "Multiple " + elementName + " in plugin-help.xml" ); -180 } -181 return namedChild.get( 0 ); -182 } -183 -184 private List<Node> findNamedChild( Node node, String elementName ) -185 { -186 List<Node> result = new ArrayList<Node>(); -187 NodeList childNodes = node.getChildNodes(); -188 for ( int i = 0; i < childNodes.getLength(); i++ ) -189 { -190 Node item = childNodes.item( i ); -191 if ( elementName.equals( item.getNodeName() ) ) -192 { -193 result.add( item ); -194 } -195 } -196 return result; -197 } -198 -199 private Node findSingleChild( Node node, String elementName ) -200 throws MojoExecutionException -201 { -202 List<Node> elementsByTagName = findNamedChild( node, elementName ); -203 if ( elementsByTagName.isEmpty() ) -204 { -205 return null; -206 } -207 if ( elementsByTagName.size() > 1 ) -208 { -209 throw new MojoExecutionException( "Multiple " + elementName + "in plugin-help.xml" ); -210 } -211 return elementsByTagName.get( 0 ); -212 } -213 -214 private void writeGoal( StringBuilder sb, String goalPrefix, Element mojo ) -215 throws MojoExecutionException -216 { -217 String mojoGoal = getValue( mojo, "goal" ); -218 Node configurationElement = findSingleChild( mojo, "configuration" ); -219 Node description = findSingleChild( mojo, "description" ); -220 if ( goal == null || goal.length() <= 0 || mojoGoal.equals( goal ) ) -221 { -222 append( sb, goalPrefix + ":" + mojoGoal, 0 ); -223 Node deprecated = findSingleChild( mojo, "deprecated" ); -224 if ( ( deprecated != null ) && isNotEmpty( deprecated.getNodeValue() ) ) -225 { -226 append( sb, "Deprecated. " + deprecated, 1 ); -227 if ( detail && description != null ) -228 { -229 append( sb, "", 0 ); -230 append( sb, description.getTextContent(), 1 ); -231 } -232 } -233 else if (description != null ) -234 { -235 append( sb, description.getTextContent(), 1 ); -236 } -237 append( sb, "", 0 ); -238 -239 if ( detail ) -240 { -241 Node parametersNode = getSingleChild( mojo, "parameters" ); -242 List<Node> parameters = findNamedChild( parametersNode, "parameter" ); -243 append( sb, "Available parameters:", 1 ); -244 append( sb, "", 0 ); -245 -246 for ( Node parameter : parameters ) -247 { -248 writeParameter( sb, parameter, configurationElement ); -249 } -250 } -251 } -252 } -253 -254 private void writeParameter( StringBuilder sb, Node parameter, Node configurationElement ) -255 throws MojoExecutionException -256 { -257 String parameterName = getValue( parameter, "name" ); -258 String parameterDescription = getValue( parameter, "description" ); -259 -260 Node fieldConfigurationElement = findSingleChild( configurationElement, parameterName ); -261 -262 String parameterDefaultValue = ""; -263 if ( fieldConfigurationElement != null && fieldConfigurationElement.getNodeValue() != null ) -264 { -265 parameterDefaultValue = " (Default: " + ((Element)fieldConfigurationElement).getAttribute( "default-value" ) + ")"; -266 } -267 append( sb, parameterName + parameterDefaultValue, 2 ); -268 Node deprecated = findSingleChild( parameter, "deprecated" ); -269 if ( ( deprecated != null ) && isNotEmpty( deprecated.getNodeValue() ) ) -270 { -271 append( sb, "Deprecated. " + deprecated.getNodeValue(), 3 ); -272 append( sb, "", 0 ); -273 } -274 append( sb, parameterDescription, 3 ); -275 if ( "true".equals( getValue( parameter, "required" ) ) ) -276 { -277 append( sb, "Required: Yes", 3 ); -278 } -279 Node expression = findSingleChild( parameter, "expression" ); -280 if ( ( expression != null ) && isNotEmpty( expression.getNodeValue() ) ) -281 { -282 String property = getPropertyFromExpression( expression.getNodeValue() ); -283 append( sb, "User property: " + property, 3 ); -284 } -285 -286 append( sb, "", 0 ); -287 } -288 -289 /** -290 * <p>Repeat a String <code>n</code> times to form a new string.</p> -291 * -292 * @param str String to repeat -293 * @param repeat number of times to repeat str -294 * @return String with repeated String -295 * @throws NegativeArraySizeException if <code>repeat < 0</code> -296 * @throws NullPointerException if str is <code>null</code> -297 */ -298 private static String repeat( String str, int repeat ) -299 { -300 StringBuilder buffer = new StringBuilder( repeat * str.length() ); -301 -302 for ( int i = 0; i < repeat; i++ ) -303 { -304 buffer.append( str ); -305 } -306 -307 return buffer.toString(); -308 } -309 -310 /** -311 * Append a description to the buffer by respecting the indentSize and lineLength parameters. -312 * <b>Note</b>: The last character is always a new line. -313 * -314 * @param sb The buffer to append the description, not <code>null</code>. -315 * @param description The description, not <code>null</code>. -316 * @param indent The base indentation level of each line, must not be negative. -317 */ -318 private void append( StringBuilder sb, String description, int indent ) -319 { -320 for ( String line : toLines( description, indent, indentSize, lineLength ) ) -321 { -322 sb.append( line ).append( '\n' ); -323 } -324 } -325 -326 /** -327 * Splits the specified text into lines of convenient display length. -328 * -329 * @param text The text to split into lines, must not be <code>null</code>. -330 * @param indent The base indentation level of each line, must not be negative. -331 * @param indentSize The size of each indentation, must not be negative. -332 * @param lineLength The length of the line, must not be negative. -333 * @return The sequence of display lines, never <code>null</code>. -334 * @throws NegativeArraySizeException if <code>indent < 0</code> -335 */ -336 private static List<String> toLines( String text, int indent, int indentSize, int lineLength ) -337 { -338 List<String> lines = new ArrayList<String>(); -339 -340 String ind = repeat( "\t", indent ); -341 -342 String[] plainLines = text.split( "(\r\n)|(\r)|(\n)" ); -343 -344 for ( String plainLine : plainLines ) -345 { -346 toLines( lines, ind + plainLine, indentSize, lineLength ); -347 } -348 -349 return lines; -350 } -351 -352 /** -353 * Adds the specified line to the output sequence, performing line wrapping if necessary. -354 * -355 * @param lines The sequence of display lines, must not be <code>null</code>. -356 * @param line The line to add, must not be <code>null</code>. -357 * @param indentSize The size of each indentation, must not be negative. -358 * @param lineLength The length of the line, must not be negative. -359 */ -360 private static void toLines( List<String> lines, String line, int indentSize, int lineLength ) -361 { -362 int lineIndent = getIndentLevel( line ); -363 StringBuilder buf = new StringBuilder( 256 ); -364 -365 String[] tokens = line.split( " +" ); -366 -367 for ( String token : tokens ) -368 { -369 if ( buf.length() > 0 ) -370 { -371 if ( buf.length() + token.length() >= lineLength ) -372 { -373 lines.add( buf.toString() ); -374 buf.setLength( 0 ); -375 buf.append( repeat( " ", lineIndent * indentSize ) ); -376 } -377 else -378 { -379 buf.append( ' ' ); -380 } -381 } -382 -383 for ( int j = 0; j < token.length(); j++ ) -384 { -385 char c = token.charAt( j ); -386 if ( c == '\t' ) -387 { -388 buf.append( repeat( " ", indentSize - buf.length() % indentSize ) ); -389 } -390 else if ( c == '\u00A0' ) -391 { -392 buf.append( ' ' ); -393 } -394 else -395 { -396 buf.append( c ); -397 } -398 } -399 } -400 lines.add( buf.toString() ); -401 } -402 -403 /** -404 * Gets the indentation level of the specified line. -405 * -406 * @param line The line whose indentation level should be retrieved, must not be <code>null</code>. -407 * @return The indentation level of the line. -408 */ -409 private static int getIndentLevel( String line ) -410 { -411 int level = 0; -412 for ( int i = 0; i < line.length() && line.charAt( i ) == '\t'; i++ ) -413 { -414 level++; -415 } -416 for ( int i = level + 1; i <= level + 4 && i < line.length(); i++ ) -417 { -418 if ( line.charAt( i ) == '\t' ) -419 { -420 level++; -421 break; -422 } -423 } -424 return level; -425 } -426 -427 private String getPropertyFromExpression( String expression ) -428 { -429 if ( expression != null && expression.startsWith( "${" ) && expression.endsWith( "}" ) -430 && !expression.substring( 2 ).contains( "${" ) ) -431 { -432 // expression="${xxx}" -> property="xxx" -433 return expression.substring( 2, expression.length() - 1 ); -434 } -435 // no property can be extracted -436 return null; -437 } -438 } --
- -1 package de.juplo.plugins.hibernate4; -2 -3 import javax.validation.Validation; -4 -5 import org.hibernate.cfg.Configuration; -6 import org.hibernate.cfg.beanvalidation.TypeSafeActivatorAccessor; -7 import org.hibernate.dialect.Dialect; -8 import org.hibernate.metamodel.source.MappingException; -9 -10 -11 /** -12 * This integration is usually performed by BeanValidationIntegrator. -13 * Unfortunately, that integration will only be activated upon -14 * initialization of the ServiceRegistry, which initializes -15 * DatasourceConnectionProviderImpl, which looks up the datasource, -16 * which requires a JNDI context ... -17 * We therefore reimplement the relevant parts of BeanValidatorIntegrator. -18 * Since that must occur after secondPassCompile(), which is invoked by -19 * Configuration.generateSchemaCreationScript, which is invoked by -20 * SchemaExport, some fancy subclassing is needed to invoke the integration -21 * at the right time. -22 * @author Mark Robinson <mark@mrobinson.ca> -23 * @author Frank Schimmel <frank.schimmel@cm4all.com> -24 */ -25 public class ValidationConfiguration extends Configuration -26 { -27 private static final long serialVersionUID = 1L; -28 -29 private Class<Dialect> dialectClass; -30 -31 public ValidationConfiguration(final String dialectClass) -32 { -33 try { -34 this.dialectClass = (Class<Dialect>) Class.forName(dialectClass); -35 } catch (ClassNotFoundException e) { -36 throw new RuntimeException(e); -37 } -38 } -39 -40 @Override -41 protected void secondPassCompile() throws MappingException -42 { -43 super.secondPassCompile(); -44 -45 try -46 { -47 TypeSafeActivatorAccessor.applyRelationalConstraints( -48 Validation.buildDefaultValidatorFactory(), -49 classes.values(), -50 getProperties(), -51 dialectClass.newInstance() -52 ); -53 } -54 catch (Exception e) -55 { -56 throw new RuntimeException(e); -57 } -58 } -59 } --
Class Summary | -
---|
- DriverProxy - | -
- Hbm2DdlMojo - | -
- HelpMojo - | -
- You don't have frames. Go here -
- -- -1 package org.hibernate.cfg.beanvalidation; -2 -3 /** -4 * This class enables access to the public methods of {@link TypeSafeActivator} -5 * which itself is visible in the package only. -6 * -7 * @author Frank Schimmel <frank.schimmel@cm4all.com> -8 */ -9 public class TypeSafeActivatorAccessor extends TypeSafeActivator { -10 // Empty: just makes public methods accessible. -11 } --
Class Summary | -
---|
- TypeSafeActivatorAccessor - | -
Packages | -
---|
- de.juplo.plugins.hibernate4 - | -
Modifier and Type | -Constant Field | -Value | -
---|---|---|
-
-public static final String |
-DIALECT |
-"hibernate.dialect" |
-
-
-public static final String |
-DRIVER_CLASS |
-"hibernate.connection.driver_class" |
-
-
-public static final String |
-ENVERS |
-"hibernate.export.envers" |
-
-
-public static final String |
-EXPORT_SKIPPED_PROPERTY |
-"hibernate.export.skipped" |
-
-
-public static final String |
-MD5S |
-"schema.md5s" |
-
-
-public static final String |
-NAMING_STRATEGY |
-"hibernate.ejb.naming_strategy" |
-
-
-public static final String |
-PASSWORD |
-"hibernate.connection.password" |
-
-
-public static final String |
-URL |
-"hibernate.connection.url" |
-
-
-public static final String |
-USERNAME |
-"hibernate.connection.username" |
-
Copyright © 2013. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.3/apidocs/de/juplo/plugins/hibernate4/Hbm2DdlMojo.html b/dist/hibernate4-maven-plugin-1.0.3/apidocs/de/juplo/plugins/hibernate4/Hbm2DdlMojo.html deleted file mode 100644 index df0600e1..00000000 --- a/dist/hibernate4-maven-plugin-1.0.3/apidocs/de/juplo/plugins/hibernate4/Hbm2DdlMojo.html +++ /dev/null @@ -1,435 +0,0 @@ - - - - - - -public class Hbm2DdlMojo
-extends org.apache.maven.plugin.AbstractMojo
-Modifier and Type | -Field and Description | -
---|---|
static String |
-DIALECT |
-
static String |
-DRIVER_CLASS |
-
static String |
-ENVERS |
-
static String |
-EXPORT_SKIPPED_PROPERTY |
-
static String |
-MD5S |
-
static String |
-NAMING_STRATEGY |
-
static String |
-PASSWORD |
-
static String |
-URL |
-
static String |
-USERNAME |
-
ROLE
Constructor and Description | -
---|
Hbm2DdlMojo() |
-
public static final String EXPORT_SKIPPED_PROPERTY-
public static final String DRIVER_CLASS-
public static final String URL-
public static final String USERNAME-
public static final String PASSWORD-
public static final String DIALECT-
public static final String NAMING_STRATEGY-
public static final String ENVERS-
public static final String MD5S-
Copyright © 2013. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.3/apidocs/de/juplo/plugins/hibernate4/HelpMojo.html b/dist/hibernate4-maven-plugin-1.0.3/apidocs/de/juplo/plugins/hibernate4/HelpMojo.html deleted file mode 100644 index 514d3d77..00000000 --- a/dist/hibernate4-maven-plugin-1.0.3/apidocs/de/juplo/plugins/hibernate4/HelpMojo.html +++ /dev/null @@ -1,296 +0,0 @@ - - - - - - -public class HelpMojo
-extends org.apache.maven.plugin.AbstractMojo
-mvn hibernate4:help -Ddetail=true -Dgoal=<goal-name>
to display parameter details.ROLE
Copyright © 2013. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.3/apidocs/de/juplo/plugins/hibernate4/class-use/Hbm2DdlMojo.html b/dist/hibernate4-maven-plugin-1.0.3/apidocs/de/juplo/plugins/hibernate4/class-use/Hbm2DdlMojo.html deleted file mode 100644 index 4f7a11b8..00000000 --- a/dist/hibernate4-maven-plugin-1.0.3/apidocs/de/juplo/plugins/hibernate4/class-use/Hbm2DdlMojo.html +++ /dev/null @@ -1,115 +0,0 @@ - - - - - - -Copyright © 2013. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.3/apidocs/de/juplo/plugins/hibernate4/class-use/HelpMojo.html b/dist/hibernate4-maven-plugin-1.0.3/apidocs/de/juplo/plugins/hibernate4/class-use/HelpMojo.html deleted file mode 100644 index f3dd2c78..00000000 --- a/dist/hibernate4-maven-plugin-1.0.3/apidocs/de/juplo/plugins/hibernate4/class-use/HelpMojo.html +++ /dev/null @@ -1,115 +0,0 @@ - - - - - - -Copyright © 2013. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.3/apidocs/de/juplo/plugins/hibernate4/package-frame.html b/dist/hibernate4-maven-plugin-1.0.3/apidocs/de/juplo/plugins/hibernate4/package-frame.html deleted file mode 100644 index 2fe816ce..00000000 --- a/dist/hibernate4-maven-plugin-1.0.3/apidocs/de/juplo/plugins/hibernate4/package-frame.html +++ /dev/null @@ -1,21 +0,0 @@ - - - - - - -Class | -Description | -
---|---|
Hbm2DdlMojo | -
- Goal which extracts the hibernate-mapping-configuration and
- exports an according SQL-database-schema.
- |
-
HelpMojo | -
- Display help information on hibernate4-maven-plugin.
- |
-
Copyright © 2013. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.3/apidocs/de/juplo/plugins/hibernate4/package-tree.html b/dist/hibernate4-maven-plugin-1.0.3/apidocs/de/juplo/plugins/hibernate4/package-tree.html deleted file mode 100644 index 6073ff12..00000000 --- a/dist/hibernate4-maven-plugin-1.0.3/apidocs/de/juplo/plugins/hibernate4/package-tree.html +++ /dev/null @@ -1,129 +0,0 @@ - - - - - - -Copyright © 2013. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.3/apidocs/de/juplo/plugins/hibernate4/package-use.html b/dist/hibernate4-maven-plugin-1.0.3/apidocs/de/juplo/plugins/hibernate4/package-use.html deleted file mode 100644 index 5f1ce7a6..00000000 --- a/dist/hibernate4-maven-plugin-1.0.3/apidocs/de/juplo/plugins/hibernate4/package-use.html +++ /dev/null @@ -1,115 +0,0 @@ - - - - - - -Copyright © 2013. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.3/apidocs/deprecated-list.html b/dist/hibernate4-maven-plugin-1.0.3/apidocs/deprecated-list.html deleted file mode 100644 index ec713902..00000000 --- a/dist/hibernate4-maven-plugin-1.0.3/apidocs/deprecated-list.html +++ /dev/null @@ -1,115 +0,0 @@ - - - - - - -Copyright © 2013. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.3/apidocs/help-doc.html b/dist/hibernate4-maven-plugin-1.0.3/apidocs/help-doc.html deleted file mode 100644 index c9c3fd44..00000000 --- a/dist/hibernate4-maven-plugin-1.0.3/apidocs/help-doc.html +++ /dev/null @@ -1,216 +0,0 @@ - - - - - - -Each package has a page that contains a list of its classes and interfaces, with a summary for each. This page can contain six categories:
-Each class, interface, nested class and nested interface has its own separate page. Each of these pages has three sections consisting of a class/interface description, summary tables, and detailed member descriptions:
-Each summary entry contains the first sentence from the detailed description for that item. The summary entries are alphabetical, while the detailed descriptions are in the order they appear in the source code. This preserves the logical groupings established by the programmer.
-Each annotation type has its own separate page with the following sections:
-Each enum has its own separate page with the following sections:
-Each documented package, class and interface has its own Use page. This page describes what packages, classes, methods, constructors and fields use any part of the given class or package. Given a class or interface A, its Use page includes subclasses of A, fields declared as A, methods that return A, and methods and constructors with parameters of type A. You can access this page by first going to the package, class or interface, then clicking on the "Use" link in the navigation bar.
-There is a Class Hierarchy page for all packages, plus a hierarchy for each package. Each hierarchy page contains a list of classes and a list of interfaces. The classes are organized by inheritance structure starting with java.lang.Object
. The interfaces do not inherit from java.lang.Object
.
The Deprecated API page lists all of the API that have been deprecated. A deprecated API is not recommended for use, generally due to improvements, and a replacement API is usually given. Deprecated APIs may be removed in future implementations.
-The Index contains an alphabetic list of all classes, interfaces, constructors, methods, and fields.
-These links take you to the next or previous class, interface, package, or related page.
-These links show and hide the HTML frames. All pages are available with or without frames.
-The All Classes link shows all classes and interfaces except non-static nested types.
-Each serializable or externalizable class has a description of its serialization fields and methods. This information is of interest to re-implementors, not to developers using the API. While there is no link in the navigation bar, you can get to this information by going to any serialized class and clicking "Serialized Form" in the "See also" section of the class description.
-The Constant Field Values page lists the static final fields and their values.
-Copyright © 2013. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.3/apidocs/index-all.html b/dist/hibernate4-maven-plugin-1.0.3/apidocs/index-all.html deleted file mode 100644 index 9ef079b3..00000000 --- a/dist/hibernate4-maven-plugin-1.0.3/apidocs/index-all.html +++ /dev/null @@ -1,190 +0,0 @@ - - - - - - -Copyright © 2013. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.3/apidocs/index.html b/dist/hibernate4-maven-plugin-1.0.3/apidocs/index.html deleted file mode 100644 index e9e1d698..00000000 --- a/dist/hibernate4-maven-plugin-1.0.3/apidocs/index.html +++ /dev/null @@ -1,65 +0,0 @@ - - - - - - -This document is designed to be viewed using the frames feature. If you see this message, you are using a non-frame-capable web client. Link to Non-frame version.
-Copyright © 2013. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.3/apidocs/package-list b/dist/hibernate4-maven-plugin-1.0.3/apidocs/package-list deleted file mode 100644 index 05307714..00000000 --- a/dist/hibernate4-maven-plugin-1.0.3/apidocs/package-list +++ /dev/null @@ -1 +0,0 @@ -de.juplo.plugins.hibernate4 diff --git a/dist/hibernate4-maven-plugin-1.0.3/apidocs/packages b/dist/hibernate4-maven-plugin-1.0.3/apidocs/packages deleted file mode 100644 index c4b51407..00000000 --- a/dist/hibernate4-maven-plugin-1.0.3/apidocs/packages +++ /dev/null @@ -1 +0,0 @@ -de.juplo.plugins.hibernate4 \ No newline at end of file diff --git a/dist/hibernate4-maven-plugin-1.0.3/apidocs/resources/background.gif b/dist/hibernate4-maven-plugin-1.0.3/apidocs/resources/background.gif deleted file mode 100644 index f471940f..00000000 Binary files a/dist/hibernate4-maven-plugin-1.0.3/apidocs/resources/background.gif and /dev/null differ diff --git a/dist/hibernate4-maven-plugin-1.0.3/apidocs/resources/tab.gif b/dist/hibernate4-maven-plugin-1.0.3/apidocs/resources/tab.gif deleted file mode 100644 index 1a73a83b..00000000 Binary files a/dist/hibernate4-maven-plugin-1.0.3/apidocs/resources/tab.gif and /dev/null differ diff --git a/dist/hibernate4-maven-plugin-1.0.3/apidocs/resources/titlebar.gif b/dist/hibernate4-maven-plugin-1.0.3/apidocs/resources/titlebar.gif deleted file mode 100644 index 17443b3e..00000000 Binary files a/dist/hibernate4-maven-plugin-1.0.3/apidocs/resources/titlebar.gif and /dev/null differ diff --git a/dist/hibernate4-maven-plugin-1.0.3/apidocs/resources/titlebar_end.gif b/dist/hibernate4-maven-plugin-1.0.3/apidocs/resources/titlebar_end.gif deleted file mode 100644 index 3ad78d46..00000000 Binary files a/dist/hibernate4-maven-plugin-1.0.3/apidocs/resources/titlebar_end.gif and /dev/null differ diff --git a/dist/hibernate4-maven-plugin-1.0.3/apidocs/stylesheet.css b/dist/hibernate4-maven-plugin-1.0.3/apidocs/stylesheet.css deleted file mode 100644 index 0aeaa97f..00000000 --- a/dist/hibernate4-maven-plugin-1.0.3/apidocs/stylesheet.css +++ /dev/null @@ -1,474 +0,0 @@ -/* Javadoc style sheet */ -/* -Overall document style -*/ -body { - background-color:#ffffff; - color:#353833; - font-family:Arial, Helvetica, sans-serif; - font-size:76%; - margin:0; -} -a:link, a:visited { - text-decoration:none; - color:#4c6b87; -} -a:hover, a:focus { - text-decoration:none; - color:#bb7a2a; -} -a:active { - text-decoration:none; - color:#4c6b87; -} -a[name] { - color:#353833; -} -a[name]:hover { - text-decoration:none; - color:#353833; -} -pre { - font-size:1.3em; -} -h1 { - font-size:1.8em; -} -h2 { - font-size:1.5em; -} -h3 { - font-size:1.4em; -} -h4 { - font-size:1.3em; -} -h5 { - font-size:1.2em; -} -h6 { - font-size:1.1em; -} -ul { - list-style-type:disc; -} -code, tt { - font-size:1.2em; -} -dt code { - font-size:1.2em; -} -table tr td dt code { - font-size:1.2em; - vertical-align:top; -} -sup { - font-size:.6em; -} -/* -Document title and Copyright styles -*/ -.clear { - clear:both; - height:0px; - overflow:hidden; -} -.aboutLanguage { - float:right; - padding:0px 21px; - font-size:.8em; - z-index:200; - margin-top:-7px; -} -.legalCopy { - margin-left:.5em; -} -.bar a, .bar a:link, .bar a:visited, .bar a:active { - color:#FFFFFF; - text-decoration:none; -} -.bar a:hover, .bar a:focus { - color:#bb7a2a; -} -.tab { - background-color:#0066FF; - background-image:url(resources/titlebar.gif); - background-position:left top; - background-repeat:no-repeat; - color:#ffffff; - padding:8px; - width:5em; - font-weight:bold; -} -/* -Navigation bar styles -*/ -.bar { - background-image:url(resources/background.gif); - background-repeat:repeat-x; - color:#FFFFFF; - padding:.8em .5em .4em .8em; - height:auto;/*height:1.8em;*/ - font-size:1em; - margin:0; -} -.topNav { - background-image:url(resources/background.gif); - background-repeat:repeat-x; - color:#FFFFFF; - float:left; - padding:0; - width:100%; - clear:right; - height:2.8em; - padding-top:10px; - overflow:hidden; -} -.bottomNav { - margin-top:10px; - background-image:url(resources/background.gif); - background-repeat:repeat-x; - color:#FFFFFF; - float:left; - padding:0; - width:100%; - clear:right; - height:2.8em; - padding-top:10px; - overflow:hidden; -} -.subNav { - background-color:#dee3e9; - border-bottom:1px solid #9eadc0; - float:left; - width:100%; - overflow:hidden; -} -.subNav div { - clear:left; - float:left; - padding:0 0 5px 6px; -} -ul.navList, ul.subNavList { - float:left; - margin:0 25px 0 0; - padding:0; -} -ul.navList li{ - list-style:none; - float:left; - padding:3px 6px; -} -ul.subNavList li{ - list-style:none; - float:left; - font-size:90%; -} -.topNav a:link, .topNav a:active, .topNav a:visited, .bottomNav a:link, .bottomNav a:active, .bottomNav a:visited { - color:#FFFFFF; - text-decoration:none; -} -.topNav a:hover, .bottomNav a:hover { - text-decoration:none; - color:#bb7a2a; -} -.navBarCell1Rev { - background-image:url(resources/tab.gif); - background-color:#a88834; - color:#FFFFFF; - margin: auto 5px; - border:1px solid #c9aa44; -} -/* -Page header and footer styles -*/ -.header, .footer { - clear:both; - margin:0 20px; - padding:5px 0 0 0; -} -.indexHeader { - margin:10px; - position:relative; -} -.indexHeader h1 { - font-size:1.3em; -} -.title { - color:#2c4557; - margin:10px 0; -} -.subTitle { - margin:5px 0 0 0; -} -.header ul { - margin:0 0 25px 0; - padding:0; -} -.footer ul { - margin:20px 0 5px 0; -} -.header ul li, .footer ul li { - list-style:none; - font-size:1.2em; -} -/* -Heading styles -*/ -div.details ul.blockList ul.blockList ul.blockList li.blockList h4, div.details ul.blockList ul.blockList ul.blockListLast li.blockList h4 { - background-color:#dee3e9; - border-top:1px solid #9eadc0; - border-bottom:1px solid #9eadc0; - margin:0 0 6px -8px; - padding:2px 5px; -} -ul.blockList ul.blockList ul.blockList li.blockList h3 { - background-color:#dee3e9; - border-top:1px solid #9eadc0; - border-bottom:1px solid #9eadc0; - margin:0 0 6px -8px; - padding:2px 5px; -} -ul.blockList ul.blockList li.blockList h3 { - padding:0; - margin:15px 0; -} -ul.blockList li.blockList h2 { - padding:0px 0 20px 0; -} -/* -Page layout container styles -*/ -.contentContainer, .sourceContainer, .classUseContainer, .serializedFormContainer, .constantValuesContainer { - clear:both; - padding:10px 20px; - position:relative; -} -.indexContainer { - margin:10px; - position:relative; - font-size:1.0em; -} -.indexContainer h2 { - font-size:1.1em; - padding:0 0 3px 0; -} -.indexContainer ul { - margin:0; - padding:0; -} -.indexContainer ul li { - list-style:none; -} -.contentContainer .description dl dt, .contentContainer .details dl dt, .serializedFormContainer dl dt { - font-size:1.1em; - font-weight:bold; - margin:10px 0 0 0; - color:#4E4E4E; -} -.contentContainer .description dl dd, .contentContainer .details dl dd, .serializedFormContainer dl dd { - margin:10px 0 10px 20px; -} -.serializedFormContainer dl.nameValue dt { - margin-left:1px; - font-size:1.1em; - display:inline; - font-weight:bold; -} -.serializedFormContainer dl.nameValue dd { - margin:0 0 0 1px; - font-size:1.1em; - display:inline; -} -/* -List styles -*/ -ul.horizontal li { - display:inline; - font-size:0.9em; -} -ul.inheritance { - margin:0; - padding:0; -} -ul.inheritance li { - display:inline; - list-style:none; -} -ul.inheritance li ul.inheritance { - margin-left:15px; - padding-left:15px; - padding-top:1px; -} -ul.blockList, ul.blockListLast { - margin:10px 0 10px 0; - padding:0; -} -ul.blockList li.blockList, ul.blockListLast li.blockList { - list-style:none; - margin-bottom:25px; -} -ul.blockList ul.blockList li.blockList, ul.blockList ul.blockListLast li.blockList { - padding:0px 20px 5px 10px; - border:1px solid #9eadc0; - background-color:#f9f9f9; -} -ul.blockList ul.blockList ul.blockList li.blockList, ul.blockList ul.blockList ul.blockListLast li.blockList { - padding:0 0 5px 8px; - background-color:#ffffff; - border:1px solid #9eadc0; - border-top:none; -} -ul.blockList ul.blockList ul.blockList ul.blockList li.blockList { - margin-left:0; - padding-left:0; - padding-bottom:15px; - border:none; - border-bottom:1px solid #9eadc0; -} -ul.blockList ul.blockList ul.blockList ul.blockList li.blockListLast { - list-style:none; - border-bottom:none; - padding-bottom:0; -} -table tr td dl, table tr td dl dt, table tr td dl dd { - margin-top:0; - margin-bottom:1px; -} -/* -Table styles -*/ -.contentContainer table, .classUseContainer table, .constantValuesContainer table { - border-bottom:1px solid #9eadc0; - width:100%; -} -.contentContainer ul li table, .classUseContainer ul li table, .constantValuesContainer ul li table { - width:100%; -} -.contentContainer .description table, .contentContainer .details table { - border-bottom:none; -} -.contentContainer ul li table th.colOne, .contentContainer ul li table th.colFirst, .contentContainer ul li table th.colLast, .classUseContainer ul li table th, .constantValuesContainer ul li table th, .contentContainer ul li table td.colOne, .contentContainer ul li table td.colFirst, .contentContainer ul li table td.colLast, .classUseContainer ul li table td, .constantValuesContainer ul li table td{ - vertical-align:top; - padding-right:20px; -} -.contentContainer ul li table th.colLast, .classUseContainer ul li table th.colLast,.constantValuesContainer ul li table th.colLast, -.contentContainer ul li table td.colLast, .classUseContainer ul li table td.colLast,.constantValuesContainer ul li table td.colLast, -.contentContainer ul li table th.colOne, .classUseContainer ul li table th.colOne, -.contentContainer ul li table td.colOne, .classUseContainer ul li table td.colOne { - padding-right:3px; -} -.overviewSummary caption, .packageSummary caption, .contentContainer ul.blockList li.blockList caption, .summary caption, .classUseContainer caption, .constantValuesContainer caption { - position:relative; - text-align:left; - background-repeat:no-repeat; - color:#FFFFFF; - font-weight:bold; - clear:none; - overflow:hidden; - padding:0px; - margin:0px; -} -caption a:link, caption a:hover, caption a:active, caption a:visited { - color:#FFFFFF; -} -.overviewSummary caption span, .packageSummary caption span, .contentContainer ul.blockList li.blockList caption span, .summary caption span, .classUseContainer caption span, .constantValuesContainer caption span { - white-space:nowrap; - padding-top:8px; - padding-left:8px; - display:block; - float:left; - background-image:url(resources/titlebar.gif); - height:18px; -} -.overviewSummary .tabEnd, .packageSummary .tabEnd, .contentContainer ul.blockList li.blockList .tabEnd, .summary .tabEnd, .classUseContainer .tabEnd, .constantValuesContainer .tabEnd { - width:10px; - background-image:url(resources/titlebar_end.gif); - background-repeat:no-repeat; - background-position:top right; - position:relative; - float:left; -} -ul.blockList ul.blockList li.blockList table { - margin:0 0 12px 0px; - width:100%; -} -.tableSubHeadingColor { - background-color: #EEEEFF; -} -.altColor { - background-color:#eeeeef; -} -.rowColor { - background-color:#ffffff; -} -.overviewSummary td, .packageSummary td, .contentContainer ul.blockList li.blockList td, .summary td, .classUseContainer td, .constantValuesContainer td { - text-align:left; - padding:3px 3px 3px 7px; -} -th.colFirst, th.colLast, th.colOne, .constantValuesContainer th { - background:#dee3e9; - border-top:1px solid #9eadc0; - border-bottom:1px solid #9eadc0; - text-align:left; - padding:3px 3px 3px 7px; -} -td.colOne a:link, td.colOne a:active, td.colOne a:visited, td.colOne a:hover, td.colFirst a:link, td.colFirst a:active, td.colFirst a:visited, td.colFirst a:hover, td.colLast a:link, td.colLast a:active, td.colLast a:visited, td.colLast a:hover, .constantValuesContainer td a:link, .constantValuesContainer td a:active, .constantValuesContainer td a:visited, .constantValuesContainer td a:hover { - font-weight:bold; -} -td.colFirst, th.colFirst { - border-left:1px solid #9eadc0; - white-space:nowrap; -} -td.colLast, th.colLast { - border-right:1px solid #9eadc0; -} -td.colOne, th.colOne { - border-right:1px solid #9eadc0; - border-left:1px solid #9eadc0; -} -table.overviewSummary { - padding:0px; - margin-left:0px; -} -table.overviewSummary td.colFirst, table.overviewSummary th.colFirst, -table.overviewSummary td.colOne, table.overviewSummary th.colOne { - width:25%; - vertical-align:middle; -} -table.packageSummary td.colFirst, table.overviewSummary th.colFirst { - width:25%; - vertical-align:middle; -} -/* -Content styles -*/ -.description pre { - margin-top:0; -} -.deprecatedContent { - margin:0; - padding:10px 0; -} -.docSummary { - padding:0; -} -/* -Formatting effect styles -*/ -.sourceLineNo { - color:green; - padding:0 30px 0 0; -} -h1.hidden { - visibility:hidden; - overflow:hidden; - font-size:.9em; -} -.block { - display:block; - margin:3px 0 0 0; -} -.strong { - font-weight:bold; -} diff --git a/dist/hibernate4-maven-plugin-1.0.3/configuration.html b/dist/hibernate4-maven-plugin-1.0.3/configuration.html deleted file mode 100644 index c9d28667..00000000 --- a/dist/hibernate4-maven-plugin-1.0.3/configuration.html +++ /dev/null @@ -1,266 +0,0 @@ - - - - - - - - -The most simple way to configure the plugin is, to put all the hibernate-configuration in a hibernate.properties-file on your classpath. Put the file in the resources-folder. Maven will put it in the class-folder of your webapp, where it will be picked up by this plugin as well as by Hibernate 4.
-Doing so, the only additionally configuration needed, to activat the plugin is the following entry in the plugins-section of your pom.xml:
-<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>${project.version}</version> - <executions> - <execution> - <goals> - <goal>export</goal> - </goals> - </execution> - </executions> -</plugin>
But be aware, that in this case the database-url, that is build in the application is the same that is used while testing, where the database is droped and recreated by the plugin. So, you should never fire up this configuration on your production system, or your database might be erased!
-Hence, you should specify a different url for testing like in the following snippet:
-<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>${project.version}</version> - <executions> - <execution> - <goals> - <goal>export</goal> - </goals> - </execution> - </executions> - <configuration> - <url><![CDATA[jdbc:mysql://localhost/test-db]]></url> - </configuration> -</plugin>
Configuration properties, that are set in the configuration-section of the plugin-configuration cannnot be overwritten elsewere (for details see Configuration-Method-Precedence). You never can overwrite them by accident when specifying a property on the commandline or in your settings.xml.
Alternatively, it is possible, to configure the plugin via maven-properties. Each relevant configuration-option has a corresponding maven-property (for a full list see the Documentation of the export-Mojo). These are named after the Hibernate JDBC Properties:
-So, instead of writing the hibernate-configuration in the properties-file, like above, you could put it in the properties-section of your pom.xml.
-Thogether with the plugin-definition from above, the following would be a complete configuration (again, the database-url was overwritten in the plugin-configuration, to be sure to have a separate database for testing):
-<properties> - <hibernate.connection.driver_class>org.hsqldb.jdbcDriver</hibernate.connection.driver_class> - <hibernate.dialect>org.hibernate.dialect.HSQLDialect</hibernate.dialect> - <hibernate.connection.url><![CDATA[jdbc:hsqldb:res:org.my.path.production_db]]></hibernate.connection.url> - <hibernate.connection.username>sa</hibernate.connection.username> - <hibernate.connection.password></hibernate.connection.password> -</properties> - -... - -<plugins> - - ... - - <plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>${project.version}</version> - <executions> - <execution> - <goals> - <goal>export</goal> - </goals> - </execution> - </executions> - <configuration> - <url><![CDATA[jdbc:hsqldb:target/db/testdb;shutdown=true]]></url> - </configuration> - </plugin> - -<plugins>
A third way for configuring the plugin is the plugin-configuration. The relevant configuration-parameters are:
-The equivalent of the configuration from the last section would look like this:
-<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>${project.version}</version> - <executions> - <execution> - <goals> - <goal>export</goal> - </goals> - </execution> - </executions> - <configuration> - <driverClassName>org.hsqldb.jdbcDriver</driverClassName> - <hibernateDialect>org.hibernate.dialect.HSQLDialect</hibernateDialect> - <url><![CDATA[jdbc:hsqldb:target/db/fotos;shutdown=true]]></url> - <username>sa</username> - <password></password> - </configuration> -</plugin>
The parameter hibernateProperties (name of the hibernate-properties-file to use, defaults to hibernate.properties) can only be configured through this approach.
-For more explanations, see the Documentation of the export-Mojo.
The configuration is gathered in a fix order:
-If you are in doubt about where a configuration-value comes from, run maven with the debug-output enabled: mvn -X hibernate4:export and be aware, that maven-properties can be overwitten on the command-line, in your ~/.m2/settings.xml and in a profile.
-The plugin-configuration comes last and overwrites everything else. That way, you can be sure, that a configuration-value, that is specified in the plugin-configuration will never be overwritten by any other configuration-method.
-If you realy need to overwrite plugin-configuration-values with maven-properties, you can use maven-properties in the plugin-configuration:
-<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>${project.version}</version> - <executions> - <execution> - <goals> - <goal>export</goal> - </goals> - </execution> - </executions> - <configuration> - <password>${my-password-property}</password> - </configuration> -</plugin>
- - - -
-If you are new to hibernate4-maven-plugin, in many cases, the Configuration-Method-Precedence may be the source of configuration errors. To solve this problem, you should run maven with the debugging output enabled. For example, by executing:
-mvn -X compile hibernate4:export
(The compile might be necessary, because hibernate4-maven-plugin has to scan the compiled classes for annotations!)
-Unlike the majority of the maven-plugins, hibernate4-maven-plugin was designed to give a good many hints, when debugging is enabled. Because, if you do not know, what went wrong, you can't fix it!
-But be warned: hibernate4-maven-plugin tends to be very chatty ;)
-- - - -
-The following is a list of compile dependencies for this project. These dependencies are required to compile and run the application:
-GroupId | -ArtifactId | -Version | -Type | -License |
---|---|---|---|---|
com.pyx4j | -maven-plugin-log4j | -1.0.1 | -jar | -The Apache Software License, Version 2.0 |
org.apache.maven | -maven-core | -3.0.4 | -jar | -The Apache Software License, Version 2.0 |
org.apache.maven | -maven-plugin-api | -3.0.4 | -jar | -The Apache Software License, Version 2.0 |
org.hibernate | -hibernate-core | -4.2.5.Final | -jar | -GNU Lesser General Public License |
org.hibernate | -hibernate-envers | -4.2.5.Final | -jar | -GNU Lesser General Public License |
org.scannotation | -scannotation | -1.0.3 | -jar | -- |
The following is a list of transitive dependencies for this project. Transitive dependencies are the dependencies of the project dependencies.
-The following is a list of compile dependencies for this project. These dependencies are required to compile and run the application:
-Unamed: JPA 2.0 API
-Apache Public License 2.0: Plexus Cipher: encryption/decryption Component, Plexus Security Dispatcher Component
-GNU LESSER GENERAL PUBLIC LICENSE: Hibernate Commons Annotations
-Unknown: dom4j, scannotation
-Common Development and Distribution License: Java Transaction API
-LGPL 2.1: Javassist
-GNU General Public License, Version 2 with the Classpath Exception: Java Transaction API
-MPL 1.1: Javassist
-The Apache Software License, Version 2.0: Hibernate 4 Maven Plugin, Log4j, Maven Aether Provider, Maven Artifact, Maven Core, Maven Model, Maven Model Builder, Maven Plugin API, Maven Repository Metadata Model, Maven Settings, Maven Settings Builder, Plexus :: Component Annotations, Plexus Classworlds, Plexus Interpolation API, Sisu Guava - Core Library, Sisu Guice - Core Library, Sisu-Inject-Bean : Aggregate OSGi bundle, maven-plugin-log4j
-GNU Lesser General Public License: A Hibernate Core Module
-GNU Lesser General Public License, version 2.1: JBoss Logging 3
-BSD License: AntLR Parser Generator
-Apache License 2.0: Javassist
-Eclipse Public License, Version 1.0: Aether :: API, Aether :: Implementation, Aether :: SPI, Aether :: Utilities, Sisu-Inject-Bean : Aggregate OSGi bundle, Sisu-Inject-Plexus : Aggregate OSGi bundle
Filename | -Size | -Entries | -Classes | -Packages | -JDK Rev | -Debug |
---|---|---|---|---|---|---|
antlr-2.7.7.jar | -434.85 kB | -239 | -224 | -12 | -1.2 | -debug |
maven-plugin-log4j-1.0.1.jar | -3.64 kB | -12 | -1 | -1 | -1.4 | -debug |
dom4j-1.6.1.jar | -306.54 kB | -208 | -190 | -14 | -1.3 | -debug |
javassist-3.12.1.GA.jar | -629.05 kB | -390 | -366 | -17 | -1.4 | -debug |
log4j-1.2.14.jar | -358.83 kB | -288 | -256 | -19 | -1.1 | -debug |
maven-aether-provider-3.0.4.jar | -55.17 kB | -40 | -23 | -1 | -1.5 | -debug |
maven-artifact-3.0.4.jar | -50.87 kB | -57 | -32 | -11 | -1.5 | -debug |
maven-core-3.0.4.jar | -545.94 kB | -428 | -350 | -43 | -1.5 | -debug |
maven-model-3.0.4.jar | -159.72 kB | -67 | -50 | -3 | -1.5 | -debug |
maven-model-builder-3.0.4.jar | -147.06 kB | -142 | -109 | -16 | -1.5 | -debug |
maven-plugin-api-3.0.4.jar | -48.16 kB | -46 | -25 | -6 | -1.5 | -debug |
maven-repository-metadata-3.0.4.jar | -29.37 kB | -25 | -7 | -2 | -1.5 | -debug |
maven-settings-3.0.4.jar | -45.57 kB | -33 | -17 | -2 | -1.5 | -debug |
maven-settings-builder-3.0.4.jar | -40.41 kB | -53 | -32 | -5 | -1.5 | -debug |
plexus-classworlds-2.4.jar | -45.96 kB | -52 | -37 | -5 | -1.4 | -debug |
plexus-component-annotations-1.5.5.jar | -4.11 kB | -15 | -3 | -1 | -1.5 | -release |
plexus-interpolation-1.14.jar | -59.64 kB | -60 | -44 | -6 | -1.4 | -debug |
hibernate-core-4.2.5.Final.jar | -4.41 MB | -3,191 | -2,982 | -170 | -1.6 | -debug |
hibernate-entitymanager-4.2.5.Final.jar | -473.46 kB | -334 | -309 | -15 | -1.6 | -debug |
hibernate-envers-4.2.5.Final.jar | -403.09 kB | -300 | -253 | -35 | -1.6 | -debug |
hibernate-commons-annotations-4.0.2.Final.jar | -79.91 kB | -82 | -64 | -7 | -1.6 | -debug |
hibernate-jpa-2.0-api-1.0.1.Final.jar | -100.25 kB | -190 | -176 | -4 | -1.5 | -debug |
javassist-3.15.0-GA.jar | -633.06 kB | -391 | -367 | -17 | -1.4 | -debug |
jboss-logging-3.1.0.GA.jar | -59.34 kB | -55 | -43 | -1 | -1.6 | -debug |
jboss-transaction-api_1.1_spec-1.0.1.Final.jar | -24.62 kB | -31 | -18 | -2 | -1.6 | -debug |
scannotation-1.0.3.jar | -18.33 kB | -23 | -13 | -2 | -1.5 | -debug |
aether-api-1.13.1.jar | -87.56 kB | -116 | -96 | -11 | -1.5 | -debug |
aether-impl-1.13.1.jar | -127.10 kB | -87 | -73 | -2 | -1.5 | -debug |
aether-spi-1.13.1.jar | -15.07 kB | -33 | -17 | -5 | -1.5 | -debug |
aether-util-1.13.1.jar | -126.98 kB | -116 | -92 | -14 | -1.5 | -debug |
plexus-cipher-1.4.jar | -13.18 kB | -20 | -6 | -1 | -1.4 | -debug |
plexus-sec-dispatcher-1.3.jar | -27.89 kB | -31 | -13 | -3 | -1.4 | -debug |
sisu-guava-0.9.9.jar | -1.44 MB | -1,183 | -1,163 | -10 | -1.5 | -debug |
sisu-guice-3.1.0-no_aop.jar | -349.05 kB | -310 | -295 | -8 | -1.5 | -debug |
sisu-inject-bean-2.3.0.jar | -282.29 kB | -256 | -224 | -15 | -1.5 | -debug |
sisu-inject-plexus-2.3.0.jar | -199.64 kB | -207 | -163 | -27 | -1.5 | -debug |
Total | -Size | -Entries | -Classes | -Packages | -JDK Rev | -Debug |
36 | -11.69 MB | -9,111 | -8,133 | -513 | -1.6 | -35 |
compile: 36 | -compile: 11.69 MB | -compile: 9,111 | -compile: 8,133 | -compile: 513 | -- | -compile: 35 |
Repo ID | -URL | -Release | -Snapshot |
---|---|---|---|
apache.snapshots | -http://repository.apache.org/snapshots | -- | -Yes |
sonatype-nexus-snapshots | -https://oss.sonatype.org/content/repositories/snapshots | -- | -Yes |
jboss | -http://repository.jboss.org/nexus/content/groups/public/ | -Yes | -Yes |
central | -http://repo.maven.apache.org/maven2 | -Yes | -- |
Repository locations for each of the Dependencies.
-- - - -
-<dependency> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.0.3</version> - <type>maven-plugin</type> -</dependency>
<dependency org="de.juplo" name="hibernate4-maven-plugin" rev="1.0.3"> - <artifact name="hibernate4-maven-plugin" type="maven-plugin" /> -</dependency>
- - - -
-The following is the distribution management information used by this project.
- -- - - -
-Full name:
- -de.juplo:hibernate4-maven-plugin:1.0.3:export
- -Description:
- -Attributes:
- -Name | - -Type | - -Since | - -Description | -
---|---|---|---|
delimiter | - -String | - -1.0 | - -Delimiter in output-file. Default value is: ;. User property is: hibernate.export.schema.delimiter. |
-
driverClassName | - -String | - -1.0 | - -SQL-Driver name. User property is: hibernate.connection.driver_class. |
-
envers | - -boolean | - -1.0.3 | - -Generate envers schema for auditing tables. Default value is: false. User property is: hibernate.export.envers. |
-
force | - -boolean | - -1.0 | - -Force execution
-
- Force execution, even if no modified or newly added annotated -classes where found and the dialect was not changed. - -skip takes precedence over force. Default value is: false. User property is: hibernate.export.force. |
-
format | - -boolean | - -1.0 | - -Format output-file. Default value is: true. User property is: hibernate.export.schema.format. |
-
hibernateDialect | - -String | - -1.0 | - -Hibernate dialect. User property is: hibernate.dialect. |
-
hibernateMapping | - -String | - -1.0.2 | - -List of Hibernate-Mapping-Files (XML). Multiple files can be
-separated with white-spaces and/or commas. User property is: hibernate.mapping. |
-
hibernateNamingStrategy | - -String | - -1.0.2 | - -Hibernate Naming Strategy User property is: hibernate.ejb.naming_strategy. |
-
hibernateProperties | - -String | - -1.0 | - -Path to Hibernate configuration file. Default value is: ${project.build.outputDirectory}/hibernate.properties. |
-
outputDirectory | - -String | - -1.0 | - -Classes-Directory to scan.
-
- This parameter defaults to the maven build-output-directory for -classes. Additonally, all dependencies are scanned for annotated -classes. User property is: project.build.outputDirectory. |
-
outputFile | - -String | - -1.0 | - -Output file. Default value is: ${project.build.directory}/schema.sql. User property is: hibernate.export.schema.filename. |
-
password | - -String | - -1.0 | - -Database password User property is: hibernate.connection.password. |
-
scanDependencies | - -String | - -1.0.3 | - -Dependency-Scopes, that should be scanned for annotated classes.
-
- By default, only dependencies in the scope compile -are scanned for annotated classes. Multiple scopes can be seperated -by white space or commas. - -The plugin does not scan for annotated classes in transitive -dependencies. If some of your annotated classes are hidden in a -transitive dependency, you can simply add that dependency -explicitly. Default value is: compile. User property is: hibernate.export.scan_dependencies. |
-
scanTestClasses | - -boolean | - -1.0.1 | - -Wether to scan test-classes too, or not.
-
- If this parameter is set to true the test-classes -of the artifact will be scanned for hibernate-annotated classes -additionally. Default value is: false. User property is: hibernate.export.scan_testclasses. |
-
skip | - -boolean | - -1.0 | - -Skip execution
-
- If set to true, the execution is skipped. - -A skipped excecution is signaled via the maven-property -${hibernate.export.skipped}. - -The excecution is skipped automatically, if no modified or newly -added annotated classes are found and the dialect was not -changed. Default value is: false. User property is: maven.test.skip. |
-
target | - -String | - -1.0 | - -Target of execution:
-
-
Default value is: EXPORT. User property is: hibernate.export.target. |
-
testOutputDirectory | - -String | - -1.0.2 | - -Test-Classes-Directory to scan.
-
- This parameter defaults to the maven build-output-directory for -test-classes. - -This parameter is only used, when scanTestClasses -is set to true! User property is: project.build.testOutputDirectory. |
-
type | - -String | - -1.0 | - -Type of execution.
-
-
Default value is: BOTH. User property is: hibernate.export.type. |
-
url | - -String | - -1.0 | - -Database URL. User property is: hibernate.connection.url. |
-
username | - -String | - -1.0 | - -Database username User property is: hibernate.connection.username. |
-
Force execution, even if no modified or newly added annotated -classes where found and the dialect was not changed.
- -skip takes precedence over force.
This parameter defaults to the maven build-output-directory for -classes. Additonally, all dependencies are scanned for annotated -classes.
By default, only dependencies in the scope compile -are scanned for annotated classes. Multiple scopes can be seperated -by white space or commas.
- -The plugin does not scan for annotated classes in transitive -dependencies. If some of your annotated classes are hidden in a -transitive dependency, you can simply add that dependency -explicitly.
If this parameter is set to true the test-classes -of the artifact will be scanned for hibernate-annotated classes -additionally.
skip:
- -If set to true, the execution is skipped.
- -A skipped excecution is signaled via the maven-property -${hibernate.export.skipped}.
- -The excecution is skipped automatically, if no modified or newly -added annotated classes are found and the dialect was not -changed.
This parameter defaults to the maven build-output-directory for -test-classes.
- -This parameter is only used, when scanTestClasses -is set to true!
type:
- -url:
- -- - - -
-The hibernate4-maven-plugin computes MD5-sums for all found annotated classes and stores them together with the generated schema. If no classes were changed or added and the dialect wasn't changed too, it automatically skips the configured schema-export, to speed up the development cycle.
-The plugin signals, that the execution was skipped by setting the maven property $hibernate.export.skipped to true. This may be helpful, because other plugins like dbunit-plugin may fail, when the execution is skipped.
-If you need the hibernate4-maven-plugin to never skip execution automatically, you can force it to do so, if you set the parameter force to true:
-<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>${project.version}</version> - <configuration> - <force>true</force> - </configuration> -</plugin>
Or you may specify -Dhibernate.export.force=true at the command line, if you want to force hibernate4-maven-plugin only once.
-- - - -
-Full name:
- -de.juplo:hibernate4-maven-plugin:1.0.3:help
- -Description:
- -Attributes:
- -Name | - -Type | - -Since | - -Description | -
---|---|---|---|
detail | - -boolean | - -- | - -If true, display all settable properties for each
-goal. Default value is: false. User property is: detail. |
-
goal | - -String | - -- | - -The name of the goal for which to show help. If unspecified, all
-goals will be displayed. User property is: goal. |
-
indentSize | - -int | - -- | - -The number of spaces per indentation level, should be positive. Default value is: 2. User property is: indentSize. |
-
lineLength | - -int | - -- | - -The maximum length of a display line, should be positive. Default value is: 80. User property is: lineLength. |
-
goal:
- -- - - -
-hibernate4-maven-plugin is a plugin for generating a database-schema from your Hibernate-4-Mappings and create or update your database accordingly. Its main usage is to automatically create and populate a test-database for unit-tests in cooperation with the dbunit-maven-plugin.
-The plugin was designed with three main goals in mind:
-To achieve the first goal, the convention-over-configuration paradigma was applied and the plugin was stuffed with usefull logging-messages. So, if in doubt, just turn on the debugging output with the mvn -X ....
-To achieve the second goal, the precedence in which the configuration locations are consulted was layouted in a way that makes it possible, to prevent overwrites of the wrong database by accident.
-Last but not least, in order to not slow down the development cycle, the hibernate4-maven-plugin only executes the schema-export, if the mapping or the dialect changes (or if you force it to do so).
-For more information about the inspiration to write this tiny plugin, read our blog-article about the hibernate4-maven-plugin.
-- - - -
-Configuration for notifying developers/users when a build is unsuccessful, including user information and notification mode.
-Type | -Address | -Configuration |
---|---|---|
kai@juplo.de | -- |
- - - -
-There is no bug-tracking system set up for this project!
-Please send your bug-reports, questions or feature-requests directly to the developer.
-- - - -
-Typically the licenses listed for the project are that of the project itself, and not of dependencies.
A business-friendly OSS license
-- Apache License - Version 2.0, January 2004 - http://www.apache.org/licenses/ - - TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION - - 1. Definitions. - - "License" shall mean the terms and conditions for use, reproduction, - and distribution as defined by Sections 1 through 9 of this document. - - "Licensor" shall mean the copyright owner or entity authorized by - the copyright owner that is granting the License. - - "Legal Entity" shall mean the union of the acting entity and all - other entities that control, are controlled by, or are under common - control with that entity. For the purposes of this definition, - "control" means (i) the power, direct or indirect, to cause the - direction or management of such entity, whether by contract or - otherwise, or (ii) ownership of fifty percent (50%) or more of the - outstanding shares, or (iii) beneficial ownership of such entity. - - "You" (or "Your") shall mean an individual or Legal Entity - exercising permissions granted by this License. - - "Source" form shall mean the preferred form for making modifications, - including but not limited to software source code, documentation - source, and configuration files. - - "Object" form shall mean any form resulting from mechanical - transformation or translation of a Source form, including but - not limited to compiled object code, generated documentation, - and conversions to other media types. - - "Work" shall mean the work of authorship, whether in Source or - Object form, made available under the License, as indicated by a - copyright notice that is included in or attached to the work - (an example is provided in the Appendix below). - - "Derivative Works" shall mean any work, whether in Source or Object - form, that is based on (or derived from) the Work and for which the - editorial revisions, annotations, elaborations, or other modifications - represent, as a whole, an original work of authorship. For the purposes - of this License, Derivative Works shall not include works that remain - separable from, or merely link (or bind by name) to the interfaces of, - the Work and Derivative Works thereof. - - "Contribution" shall mean any work of authorship, including - the original version of the Work and any modifications or additions - to that Work or Derivative Works thereof, that is intentionally - submitted to Licensor for inclusion in the Work by the copyright owner - or by an individual or Legal Entity authorized to submit on behalf of - the copyright owner. For the purposes of this definition, "submitted" - means any form of electronic, verbal, or written communication sent - to the Licensor or its representatives, including but not limited to - communication on electronic mailing lists, source code control systems, - and issue tracking systems that are managed by, or on behalf of, the - Licensor for the purpose of discussing and improving the Work, but - excluding communication that is conspicuously marked or otherwise - designated in writing by the copyright owner as "Not a Contribution." - - "Contributor" shall mean Licensor and any individual or Legal Entity - on behalf of whom a Contribution has been received by Licensor and - subsequently incorporated within the Work. - - 2. Grant of Copyright License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - copyright license to reproduce, prepare Derivative Works of, - publicly display, publicly perform, sublicense, and distribute the - Work and such Derivative Works in Source or Object form. - - 3. Grant of Patent License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - (except as stated in this section) patent license to make, have made, - use, offer to sell, sell, import, and otherwise transfer the Work, - where such license applies only to those patent claims licensable - by such Contributor that are necessarily infringed by their - Contribution(s) alone or by combination of their Contribution(s) - with the Work to which such Contribution(s) was submitted. If You - institute patent litigation against any entity (including a - cross-claim or counterclaim in a lawsuit) alleging that the Work - or a Contribution incorporated within the Work constitutes direct - or contributory patent infringement, then any patent licenses - granted to You under this License for that Work shall terminate - as of the date such litigation is filed. - - 4. Redistribution. You may reproduce and distribute copies of the - Work or Derivative Works thereof in any medium, with or without - modifications, and in Source or Object form, provided that You - meet the following conditions: - - (a) You must give any other recipients of the Work or - Derivative Works a copy of this License; and - - (b) You must cause any modified files to carry prominent notices - stating that You changed the files; and - - (c) You must retain, in the Source form of any Derivative Works - that You distribute, all copyright, patent, trademark, and - attribution notices from the Source form of the Work, - excluding those notices that do not pertain to any part of - the Derivative Works; and - - (d) If the Work includes a "NOTICE" text file as part of its - distribution, then any Derivative Works that You distribute must - include a readable copy of the attribution notices contained - within such NOTICE file, excluding those notices that do not - pertain to any part of the Derivative Works, in at least one - of the following places: within a NOTICE text file distributed - as part of the Derivative Works; within the Source form or - documentation, if provided along with the Derivative Works; or, - within a display generated by the Derivative Works, if and - wherever such third-party notices normally appear. The contents - of the NOTICE file are for informational purposes only and - do not modify the License. You may add Your own attribution - notices within Derivative Works that You distribute, alongside - or as an addendum to the NOTICE text from the Work, provided - that such additional attribution notices cannot be construed - as modifying the License. - - You may add Your own copyright statement to Your modifications and - may provide additional or different license terms and conditions - for use, reproduction, or distribution of Your modifications, or - for any such Derivative Works as a whole, provided Your use, - reproduction, and distribution of the Work otherwise complies with - the conditions stated in this License. - - 5. Submission of Contributions. Unless You explicitly state otherwise, - any Contribution intentionally submitted for inclusion in the Work - by You to the Licensor shall be under the terms and conditions of - this License, without any additional terms or conditions. - Notwithstanding the above, nothing herein shall supersede or modify - the terms of any separate license agreement you may have executed - with Licensor regarding such Contributions. - - 6. Trademarks. This License does not grant permission to use the trade - names, trademarks, service marks, or product names of the Licensor, - except as required for reasonable and customary use in describing the - origin of the Work and reproducing the content of the NOTICE file. - - 7. Disclaimer of Warranty. Unless required by applicable law or - agreed to in writing, Licensor provides the Work (and each - Contributor provides its Contributions) on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or - implied, including, without limitation, any warranties or conditions - of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A - PARTICULAR PURPOSE. You are solely responsible for determining the - appropriateness of using or redistributing the Work and assume any - risks associated with Your exercise of permissions under this License. - - 8. Limitation of Liability. In no event and under no legal theory, - whether in tort (including negligence), contract, or otherwise, - unless required by applicable law (such as deliberate and grossly - negligent acts) or agreed to in writing, shall any Contributor be - liable to You for damages, including any direct, indirect, special, - incidental, or consequential damages of any character arising as a - result of this License or out of the use or inability to use the - Work (including but not limited to damages for loss of goodwill, - work stoppage, computer failure or malfunction, or any and all - other commercial damages or losses), even if such Contributor - has been advised of the possibility of such damages. - - 9. Accepting Warranty or Additional Liability. While redistributing - the Work or Derivative Works thereof, You may choose to offer, - and charge a fee for, acceptance of support, warranty, indemnity, - or other liability obligations and/or rights consistent with this - License. However, in accepting such obligations, You may act only - on Your own behalf and on Your sole responsibility, not on behalf - of any other Contributor, and only if You agree to indemnify, - defend, and hold each Contributor harmless for any liability - incurred by, or claims asserted against, such Contributor by reason - of your accepting any such warranty or additional liability. - - END OF TERMS AND CONDITIONS - - APPENDIX: How to apply the Apache License to your work. - - To apply the Apache License to your work, attach the following - boilerplate notice, with the fields enclosed by brackets "[]" - replaced with your own identifying information. (Don't include - the brackets!) The text should be enclosed in the appropriate - comment syntax for the file format. We also recommend that a - file or class name and description of purpose be included on the - same "printed page" as the copyright notice for easier - identification within third-party archives. - - Copyright [yyyy] [name of copyright owner] - - Licensed under the Apache License, Version 2.0 (the "License"); - you may not use this file except in compliance with the License. - You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. -
- - - -
-There are no mailinglists defined for this project!
-Please send your bug-reports, questions or feature-requests directly to the developer.
-- - - -
-hibernate4-maven-plugin does not scan transitive dependencies for annotated classes. If some of your annotated classes are hidden in a transitive dependency, you can simply add that dependency explicitly.
The default-configuration uses the EXPORT-target of the SchemaExport-Tool. If you do not need to create a database with the evaluated schema, you can use the NONE- or the SCRIPT-target. This can be achieved with the command-line parameter -Dhibernate.export.target=SCRIPT or with the following configuration:
-<configuration> - <target>SCRIPT</target> -</configuration>
But even when no database is to be created, hibernate always needs to know the dialect. Hence, the plugin will fail if this parameter is missing!
One regular problem is the scope of the jdbc-driver-dependency. It is very unlikely, that this dependency is needed at compile-time. So a tidy maven-developer would usually scope it for runtime.
-But this will break the execution of the hibernate4-maven-plugin. Since it will not be able to see the needed dependency, it will fail with an error-message like:
-[INFO] Gathered hibernate-configuration (turn on debugging for details): -[INFO] hibernate.connection.username = sa -[INFO] hibernate.connection.password = -[INFO] hibernate.dialect = org.hibernate.dialect.HSQLDialect -[INFO] hibernate.connection.url = jdbc:hsqldb:/home/kai/mmf/target/mmf;shutdown=true -[INFO] hibernate.connection.driver_class = org.hsqldb.jdbcDriver -[ERROR] Dependency for driver-class org.hsqldb.jdbcDriver is missing! -[INFO] ------------------------------------------------------------------------ -[ERROR] BUILD ERROR -[INFO] ------------------------------------------------------------------------ -[INFO] org.hsqldb.jdbcDriver -[INFO] ------------------------------------------------------------------------ -[INFO] For more information, run Maven with the -e switch -[INFO] ------------------------------------------------------------------------ -[INFO] Total time: 2 seconds -[INFO] Finished at: Thu Nov 29 11:31:14 CET 2012 -[INFO] Final Memory: 32M/342M -[INFO] ------------------------------------------------------------------------
A quick workaround for this error would be, to delete the runtime-constraint for the jdbc-driver-dependency.
-A much cleaner way is, to (additionally) ad the dependency, to the plugin-definition:
-<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>${project.version}</version> - <executions> - <execution> - <goals> - <goal>export</goal> - </goals> - </execution> - </executions> - <dependencies> - <dependency> - <groupId>org.hsqldb</groupId> - <artifactId>hsqldb</artifactId> - <version>2.2.8</version> - </dependency> - </dependencies> -</plugin>
This is also the best way, if you use a different jdbc-driver for testing, than in production. Because otherwise, this dependency will unnecessarily bloat the runtime-dependencies of your project.
If hibernate4-maven-plugin skips its excecution, this may lead to errors in other plugins. For example, when importing sample-data in the automatically created database with the help of the dbunit-plugin, the CLEAN_INSERT-operation may fail because of foreign-key-constraints, if the database was not recreated, because the hibernate4-maven-plugin has skipped its excecution.
-A quick fix to this problem is, to force hibernate4-maven-plugin to export the schema every time it is running. But to recreate the database on every testrun may noticeable slow down your development cycle, if you have to wait for slow IO.
-To circumvent this problem, hibernate4-maven-plugin signals a skipped excecution by setting the maven property $hibernate.export.skipped to true. You can configure other plugins to react on this signal. For example, the dbunit-plugin can be configured to skip its excecution, if hibernate4-maven-plugin was skipped like this:
-<plugin> - <groupId>org.codehaus.mojo</groupId> - <artifactId>dbunit-maven-plugin</artifactId> - <configuration> - <skip>${hibernate.export.skipped}</skip> - </configuration> -</plugin>
If one manually drops the database or removes the hsqldb-files, it will not be recreated by the hibernate4-maven-plugin, because it cannot detect, that the database needs to be recreated. This happens, because the plugin will not recreate the database if neither the configuration nor the annotated classes have changed, because an unnecessary drop-create-cycle might take a long time. The plugin will report that like this:
-[INFO] No modified annotated classes found and dialect unchanged. -[INFO] Skipping schema generation!
If one always uses mvn clean for cleanup, this will not happen. Otherwise the recreation must be forced:
-mvn hibernate4:export -Dhibernate.export.force=true
The hibernate4-maven-plugin automatically skips its execution, when maven.test.skip is set to true. If you need it to be always executed, you can configure that explicitly like this:
-<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - ... - <configuration> - <skip>false</skip> - </configuration> -</plugin>
Background-information for this design-decission can be found on the extra page To skip or not to skip: that is the question...
- - - -
-Goals available for this plugin:
-Goal | -Description |
---|---|
hibernate4:export | -Goal which extracts the hibernate-mapping-configuration and exports -an according SQL-database-schema. |
hibernate4:help | -Display help information on hibernate4-maven-plugin. -Call mvn hibernate4:help -Ddetail=true
--Dgoal=<goal-name> to display parameter details. |
The following specifies the minimum requirements to run this Maven plugin:
-Maven | -2.0.6 |
JDK | -1.6 |
Memory | -No minimum requirement. |
Disk Space | -No minimum requirement. |
You should specify the version in your project's plugin configuration:
-<project> - ... - <build> - <!-- To define the plugin version in your parent POM --> - <pluginManagement> - <plugins> - <plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.0.3</version> - </plugin> - ... - </plugins> - </pluginManagement> - <!-- To use the plugin goals in your POM or parent POM --> - <plugins> - <plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.0.3</version> - </plugin> - ... - </plugins> - </build> - ... -</project> -
For more information, see "Guide to Configuring Plug-ins"
- - - -
-GroupId | -ArtifactId | -Version |
---|---|---|
org.apache.maven.plugins | -maven-antrun-plugin | -1.3 |
org.apache.maven.plugins | -maven-assembly-plugin | -2.2-beta-5 |
org.apache.maven.plugins | -maven-dependency-plugin | -2.1 |
org.apache.maven.plugins | -maven-release-plugin | -2.1 |
org.apache.maven.plugins | -maven-site-plugin | -3.3 |
- - - -
-GroupId | -ArtifactId | -Version |
---|---|---|
org.apache.maven.plugins | -maven-clean-plugin | -2.3 |
org.apache.maven.plugins | -maven-compiler-plugin | -2.0.2 |
org.apache.maven.plugins | -maven-dependency-plugin | -2.1 |
org.apache.maven.plugins | -maven-deploy-plugin | -2.7 |
org.apache.maven.plugins | -maven-enforcer-plugin | -1.0 |
org.apache.maven.plugins | -maven-install-plugin | -2.3 |
org.apache.maven.plugins | -maven-jar-plugin | -2.2 |
org.apache.maven.plugins | -maven-plugin-plugin | -3.2 |
org.apache.maven.plugins | -maven-resources-plugin | -2.3 |
org.apache.maven.plugins | -scp://people.apache.org/www/maven.apache.org/scm/maven-scm-plugin | -1.7 |
org.apache.maven.plugins | -maven-site-plugin | -3.3 |
org.apache.maven.plugins | -maven-source-plugin | -2.1.2 |
org.apache.maven.plugins | -maven-surefire-plugin | -2.10 |
GroupId | -ArtifactId | -Version |
---|---|---|
org.apache.maven.plugins | -maven-changes-plugin | -2.7.1 |
org.apache.maven.plugins | -maven-javadoc-plugin | -2.7 |
org.apache.maven.plugins | -maven-jxr-plugin | -2.3 |
org.apache.maven.plugins | -maven-plugin-plugin | -3.2 |
org.apache.maven.plugins | -maven-pmd-plugin | -2.7.1 |
org.apache.maven.plugins | -maven-site-plugin | -3.3 |
- - - -
-This document provides an overview of the various documents and links that are part of this project's general information. All of this content is automatically generated by Maven on behalf of the project.
-Document | -Description |
---|---|
About | -Plugin for generating a database-schema from Hibernate-4-Mapping-Annotations |
Plugin Management | -This document lists the plugins that are defined through pluginManagement. |
Distribution Management | -This document provides informations on the distribution management of this project. |
Dependency Information | -This document describes how to to include this project as a dependency using various dependency management tools. |
Source Repository | -This is a link to the online source repository that can be viewed via a web browser. |
Mailing Lists | -This document provides subscription and archive information for this project's mailing lists. |
Issue Tracking | -This is a link to the issue management system for this project. Issues (bugs, features, change requests) can be created and queried using this link. |
Continuous Integration | -This is a link to the definitions of all continuous integration processes that builds and tests code on a frequent, regular basis. |
Project Plugins | -This document lists the build plugins and the report plugins used by this project. |
Project License | -This is a link to the definitions of project licenses. |
Project Team | -This document provides information on the members of this project. These are the individuals who have contributed to the project in one form or another. |
Project Summary | -This document lists other related information of this project |
Dependencies | -This document lists the project's dependencies and provides information on each dependency. |
- - - -
-This document provides an overview of the various reports that are automatically generated by Maven . Each report is briefly described below.
-Document | -Description |
---|---|
JavaDocs | -JavaDoc API documentation. |
Source Xref | -HTML based, cross-reference version of Java source code. |
PMD Report | -Verification of coding rules. |
CPD Report | -Duplicate code detection. |
Plugin Documentation | -This report provides goals and parameters documentation of a plugin. |
- - - -
-Field | -Value |
---|---|
Name | -Hibernate 4 Maven Plugin |
Description | -Plugin for generating a database-schema from Hibernate-4-Mapping-Annotations |
Homepage | -http://juplo.de/hibernate4-maven-plugin |
- - - -
-In most use-cases, the hibernate4-maven-plugin is used to create a test-database automatically. In this use-cases, it is very likely, that it will result in mistakes/errors, if the goal is executed, when the tests are skipped. For example, one might manually overwrite the database-url with the url of the production-database, in order to run other tests, like starting a local webserver with the jetty-maven-plugin. If the export-goal would be executed in such a scenario, it might erase the hole production-database, which is not very desireable.
-Because of this, the configuration-parameter skip defaults to the value of the proptery maven.test.skip. This way, the execution of the hibernate4-maven-plugin is skipped automatically, when the tests are skipped. Think of it as a build-in security-belt.
-If you do not like that, because you need the plugin to always execute the export-goal, even if the tests are skipped you can configure that explicitly, by setting the configuration-parameter skip to false:
-<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - ... - <configuration> - <skip>false</skip> - </configuration> -</plugin>
Or, if you want the export-goal to be executed by default and to be skipped if you say so, you can bind the value of the configuration-parameter skip to a custom property. For example:
-<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - ... - <configuration> - <skip>${foo.bar}</skip> - </configuration> -</plugin>
This way, the export-goal would be skipped, if you set the property foo.bar to true. For example, if you specify -Dfoo.bar=true on the command-line.
-- - - -
-This project uses GIT to manage its source code. Instructions on GIT use can be found at http://git-scm.com/documentation.
The source can be checked out anonymously from GIT with this command (See http://git-scm.com/docs/git-clone):
-$ git clone http://juplo.de/git/hibernate4-maven-plugin
Only project developers can access the GIT tree via this method (See http://git-scm.com/docs/git-clone).
-$ git clone ssh://juplo.de/var/lib/git/juplo/hibernate4-maven-plugin
- - - -
-A successful project requires many people to play many roles. Some members write code or documentation, while others are valuable as testers, submitting patches and suggestions.
-The team is comprised of Members and Contributors. Members have direct access to the source of a project and actively evolve the code-base. Contributors improve the project through submission of patches and suggestions to the Members. The number of Contributors to the project is unbounded. Get involved today. All contributions to the project are greatly appreciated.
-The following is a list of developers with commit privileges that have directly contributed to the project in one way or another.
-Image | -Id | -Name | -|
---|---|---|---|
- | kai | -Kai Moritz | -kai@juplo.de |
The following additional people have contributed to this project through the way of suggestions, patches or documentation.
-Image | -Name | -|
---|---|---|
- | Adriano Machado | -adriano.m.machado@hotmail.com |
- | Lorenzo Nicora | -lorenzo.nicora@nicus.it |
- | Eduard Szente | -eduard.szente@gmail.com |
- | Stephen Johnson | -stejohns@redhat.com |
- | Victor Tatai | -vtatai@gmail.com |
- | Erik-Berndt Scheper | -erik.berndt.scheper@gmail.com |
- | Guido Wimmel | -Wimmel.Guido@swm.de |
- - - -
-Modifier and Type | -Constant Field | -Value | -
---|---|---|
-
-public static final String |
-DIALECT |
-"hibernate.dialect" |
-
-
-public static final String |
-DRIVER_CLASS |
-"hibernate.connection.driver_class" |
-
-
-public static final String |
-ENVERS |
-"hibernate.export.envers" |
-
-
-public static final String |
-EXPORT_SKIPPED_PROPERTY |
-"hibernate.export.skipped" |
-
-
-public static final String |
-MD5S |
-"hibernate4-generatedschema.md5s" |
-
-
-public static final String |
-NAMING_STRATEGY |
-"hibernate.ejb.naming_strategy" |
-
-
-public static final String |
-PASSWORD |
-"hibernate.connection.password" |
-
-
-public static final String |
-URL |
-"hibernate.connection.url" |
-
-
-public static final String |
-USERNAME |
-"hibernate.connection.username" |
-
Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.4/apidocs/de/juplo/plugins/hibernate4/Hbm2DdlMojo.html b/dist/hibernate4-maven-plugin-1.0.4/apidocs/de/juplo/plugins/hibernate4/Hbm2DdlMojo.html deleted file mode 100644 index 11a1ce02..00000000 --- a/dist/hibernate4-maven-plugin-1.0.4/apidocs/de/juplo/plugins/hibernate4/Hbm2DdlMojo.html +++ /dev/null @@ -1,437 +0,0 @@ - - - - - - -public class Hbm2DdlMojo
-extends org.apache.maven.plugin.AbstractMojo
-Modifier and Type | -Field and Description | -
---|---|
static String |
-DIALECT |
-
static String |
-DRIVER_CLASS |
-
static String |
-ENVERS |
-
static String |
-EXPORT_SKIPPED_PROPERTY |
-
static String |
-MD5S |
-
static String |
-NAMING_STRATEGY |
-
static String |
-PASSWORD |
-
static String |
-URL |
-
static String |
-USERNAME |
-
ROLE
Constructor and Description | -
---|
Hbm2DdlMojo() |
-
public static final String EXPORT_SKIPPED_PROPERTY-
public static final String DRIVER_CLASS-
public static final String URL-
public static final String USERNAME-
public static final String PASSWORD-
public static final String DIALECT-
public static final String NAMING_STRATEGY-
public static final String ENVERS-
public static final String MD5S-
Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.4/apidocs/de/juplo/plugins/hibernate4/HelpMojo.html b/dist/hibernate4-maven-plugin-1.0.4/apidocs/de/juplo/plugins/hibernate4/HelpMojo.html deleted file mode 100644 index 64a772fa..00000000 --- a/dist/hibernate4-maven-plugin-1.0.4/apidocs/de/juplo/plugins/hibernate4/HelpMojo.html +++ /dev/null @@ -1,298 +0,0 @@ - - - - - - -public class HelpMojo
-extends org.apache.maven.plugin.AbstractMojo
-mvn hibernate4:help -Ddetail=true -Dgoal=<goal-name>
to display parameter details.ROLE
Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.4/apidocs/de/juplo/plugins/hibernate4/ValidationConfiguration.html b/dist/hibernate4-maven-plugin-1.0.4/apidocs/de/juplo/plugins/hibernate4/ValidationConfiguration.html deleted file mode 100644 index a6e39ab2..00000000 --- a/dist/hibernate4-maven-plugin-1.0.4/apidocs/de/juplo/plugins/hibernate4/ValidationConfiguration.html +++ /dev/null @@ -1,323 +0,0 @@ - - - - - - -public class ValidationConfiguration
-extends org.hibernate.cfg.Configuration
-org.hibernate.cfg.Configuration.MappingsImpl, org.hibernate.cfg.Configuration.MetadataSourceQueue
ARTEFACT_PROCESSING_ORDER, auxiliaryDatabaseObjects, classes, collections, columnNameBindingPerTable, DEFAULT_ARTEFACT_PROCESSING_ORDER, DEFAULT_CACHE_CONCURRENCY_STRATEGY, extendsQueue, fetchProfiles, filterDefinitions, imports, metadataSourceQueue, namedEntityGraphMap, namedProcedureCallMap, namedQueries, namedSqlQueries, namingStrategy, propertyReferences, secondPasses, settingsFactory, sqlFunctions, sqlResultSetMappings, tableNameBinding, tables, typeDefs, USE_NEW_ID_GENERATOR_MAPPINGS, xmlHelper
Constructor and Description | -
---|
ValidationConfiguration(String dialectClass) |
-
Modifier and Type | -Method and Description | -
---|---|
protected void |
-secondPassCompile() |
-
add, addAnnotatedClass, addAttributeConverter, addAttributeConverter, addAttributeConverter, addAttributeConverter, addAttributeConverter, addAuxiliaryDatabaseObject, addCacheableFile, addCacheableFile, addCacheableFileStrictly, addClass, addDirectory, addDocument, addFetchProfile, addFile, addFile, addFilterDefinition, addInputStream, addJar, addPackage, addProperties, addResource, addResource, addSqlFunction, addURL, addXML, buildMapping, buildMappings, buildSessionFactory, buildSessionFactory, buildSettings, buildSettings, configure, configure, configure, configure, configure, createMappings, doConfigure, doConfigure, findPossibleExtends, generateDropSchemaScript, generateSchemaCreationScript, generateSchemaUpdateScript, generateSchemaUpdateScriptList, getClassMapping, getClassMappings, getCollectionMapping, getCollectionMappings, getConfigurationInputStream, getCurrentTenantIdentifierResolver, getEntityNotFoundDelegate, getEntityResolver, getEntityTuplizerFactory, getFilterDefinitions, getIdentifierGeneratorFactory, getImports, getInterceptor, getJaccPermissionDeclarations, getMappedSuperclassMappings, getMappedSuperclassMappingsCopy, getNamedEntityGraphs, getNamedProcedureCallMap, getNamedQueries, getNamedSQLQueries, getNamingStrategy, getProperties, getProperty, getReflectionManager, getSessionFactoryObserver, getSqlFunctions, getSqlResultSetMappings, getTableMappings, getTypeResolver, iterateFetchProfiles, iterateGenerators, mergeProperties, registerTypeContributor, registerTypeOverride, registerTypeOverride, registerTypeOverride, reset, secondPassCompileForeignKeys, setCacheConcurrencyStrategy, setCacheConcurrencyStrategy, setCacheConcurrencyStrategy, setCollectionCacheConcurrencyStrategy, setCollectionCacheConcurrencyStrategy, setCurrentTenantIdentifierResolver, setEntityNotFoundDelegate, setEntityResolver, setInterceptor, setNamingStrategy, setPrecedence, setProperties, setProperty, setSessionFactoryObserver, validateSchema
Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.4/apidocs/de/juplo/plugins/hibernate4/class-use/Hbm2DdlMojo.html b/dist/hibernate4-maven-plugin-1.0.4/apidocs/de/juplo/plugins/hibernate4/class-use/Hbm2DdlMojo.html deleted file mode 100644 index 8d2812db..00000000 --- a/dist/hibernate4-maven-plugin-1.0.4/apidocs/de/juplo/plugins/hibernate4/class-use/Hbm2DdlMojo.html +++ /dev/null @@ -1,117 +0,0 @@ - - - - - - -Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.4/apidocs/de/juplo/plugins/hibernate4/class-use/HelpMojo.html b/dist/hibernate4-maven-plugin-1.0.4/apidocs/de/juplo/plugins/hibernate4/class-use/HelpMojo.html deleted file mode 100644 index 613dab36..00000000 --- a/dist/hibernate4-maven-plugin-1.0.4/apidocs/de/juplo/plugins/hibernate4/class-use/HelpMojo.html +++ /dev/null @@ -1,117 +0,0 @@ - - - - - - -Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.4/apidocs/de/juplo/plugins/hibernate4/class-use/ValidationConfiguration.html b/dist/hibernate4-maven-plugin-1.0.4/apidocs/de/juplo/plugins/hibernate4/class-use/ValidationConfiguration.html deleted file mode 100644 index 4db9c94c..00000000 --- a/dist/hibernate4-maven-plugin-1.0.4/apidocs/de/juplo/plugins/hibernate4/class-use/ValidationConfiguration.html +++ /dev/null @@ -1,117 +0,0 @@ - - - - - - -Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.4/apidocs/de/juplo/plugins/hibernate4/package-frame.html b/dist/hibernate4-maven-plugin-1.0.4/apidocs/de/juplo/plugins/hibernate4/package-frame.html deleted file mode 100644 index f2ecbe4b..00000000 --- a/dist/hibernate4-maven-plugin-1.0.4/apidocs/de/juplo/plugins/hibernate4/package-frame.html +++ /dev/null @@ -1,22 +0,0 @@ - - - - - - -Class | -Description | -
---|---|
Hbm2DdlMojo | -
- Goal which extracts the hibernate-mapping-configuration and
- exports an according SQL-database-schema.
- |
-
HelpMojo | -
- Display help information on hibernate4-maven-plugin.
- |
-
ValidationConfiguration | -
- This integration is usually performed by BeanValidationIntegrator.
- |
-
Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.4/apidocs/de/juplo/plugins/hibernate4/package-tree.html b/dist/hibernate4-maven-plugin-1.0.4/apidocs/de/juplo/plugins/hibernate4/package-tree.html deleted file mode 100644 index d6a95fb2..00000000 --- a/dist/hibernate4-maven-plugin-1.0.4/apidocs/de/juplo/plugins/hibernate4/package-tree.html +++ /dev/null @@ -1,140 +0,0 @@ - - - - - - -Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.4/apidocs/de/juplo/plugins/hibernate4/package-use.html b/dist/hibernate4-maven-plugin-1.0.4/apidocs/de/juplo/plugins/hibernate4/package-use.html deleted file mode 100644 index 7f0dc715..00000000 --- a/dist/hibernate4-maven-plugin-1.0.4/apidocs/de/juplo/plugins/hibernate4/package-use.html +++ /dev/null @@ -1,117 +0,0 @@ - - - - - - -Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.4/apidocs/deprecated-list.html b/dist/hibernate4-maven-plugin-1.0.4/apidocs/deprecated-list.html deleted file mode 100644 index aa599045..00000000 --- a/dist/hibernate4-maven-plugin-1.0.4/apidocs/deprecated-list.html +++ /dev/null @@ -1,117 +0,0 @@ - - - - - - -Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.4/apidocs/help-doc.html b/dist/hibernate4-maven-plugin-1.0.4/apidocs/help-doc.html deleted file mode 100644 index 46b16015..00000000 --- a/dist/hibernate4-maven-plugin-1.0.4/apidocs/help-doc.html +++ /dev/null @@ -1,222 +0,0 @@ - - - - - - -The Overview page is the front page of this API document and provides a list of all packages with a summary for each. This page can also contain an overall description of the set of packages.
-Each package has a page that contains a list of its classes and interfaces, with a summary for each. This page can contain six categories:
-Each class, interface, nested class and nested interface has its own separate page. Each of these pages has three sections consisting of a class/interface description, summary tables, and detailed member descriptions:
-Each summary entry contains the first sentence from the detailed description for that item. The summary entries are alphabetical, while the detailed descriptions are in the order they appear in the source code. This preserves the logical groupings established by the programmer.
-Each annotation type has its own separate page with the following sections:
-Each enum has its own separate page with the following sections:
-Each documented package, class and interface has its own Use page. This page describes what packages, classes, methods, constructors and fields use any part of the given class or package. Given a class or interface A, its Use page includes subclasses of A, fields declared as A, methods that return A, and methods and constructors with parameters of type A. You can access this page by first going to the package, class or interface, then clicking on the "Use" link in the navigation bar.
-There is a Class Hierarchy page for all packages, plus a hierarchy for each package. Each hierarchy page contains a list of classes and a list of interfaces. The classes are organized by inheritance structure starting with java.lang.Object
. The interfaces do not inherit from java.lang.Object
.
The Deprecated API page lists all of the API that have been deprecated. A deprecated API is not recommended for use, generally due to improvements, and a replacement API is usually given. Deprecated APIs may be removed in future implementations.
-The Index contains an alphabetic list of all classes, interfaces, constructors, methods, and fields.
-These links take you to the next or previous class, interface, package, or related page.
-These links show and hide the HTML frames. All pages are available with or without frames.
-The All Classes link shows all classes and interfaces except non-static nested types.
-Each serializable or externalizable class has a description of its serialization fields and methods. This information is of interest to re-implementors, not to developers using the API. While there is no link in the navigation bar, you can get to this information by going to any serialized class and clicking "Serialized Form" in the "See also" section of the class description.
-The Constant Field Values page lists the static final fields and their values.
-Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.4/apidocs/index-all.html b/dist/hibernate4-maven-plugin-1.0.4/apidocs/index-all.html deleted file mode 100644 index 4ace7182..00000000 --- a/dist/hibernate4-maven-plugin-1.0.4/apidocs/index-all.html +++ /dev/null @@ -1,233 +0,0 @@ - - - - - - -TypeSafeActivator
- which itself is visible in the package only.Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.4/apidocs/index.html b/dist/hibernate4-maven-plugin-1.0.4/apidocs/index.html deleted file mode 100644 index b5c8a14a..00000000 --- a/dist/hibernate4-maven-plugin-1.0.4/apidocs/index.html +++ /dev/null @@ -1,68 +0,0 @@ - - - - - - -This document is designed to be viewed using the frames feature. If you see this message, you are using a non-frame-capable web client. Link to Non-frame version.
-public class TypeSafeActivatorAccessor -extends Object-
TypeSafeActivator
- which itself is visible in the package only.Constructor and Description | -
---|
TypeSafeActivatorAccessor() |
-
Modifier and Type | -Method and Description | -
---|---|
static void |
-activate(org.hibernate.cfg.beanvalidation.ActivationContext arg0) |
-
static void |
-applyCallbackListeners(javax.validation.ValidatorFactory arg0,
- org.hibernate.cfg.beanvalidation.ActivationContext arg1) |
-
static void |
-applyRelationalConstraints(javax.validation.ValidatorFactory arg0,
- Collection<org.hibernate.mapping.PersistentClass> arg1,
- Properties arg2,
- org.hibernate.dialect.Dialect arg3) |
-
static void |
-validateSuppliedFactory(Object arg0) |
-
public TypeSafeActivatorAccessor()-
public static void validateSuppliedFactory(Object arg0)-
public static void activate(org.hibernate.cfg.beanvalidation.ActivationContext arg0)-
public static void applyCallbackListeners(javax.validation.ValidatorFactory arg0, - org.hibernate.cfg.beanvalidation.ActivationContext arg1)-
public static void applyRelationalConstraints(javax.validation.ValidatorFactory arg0, - Collection<org.hibernate.mapping.PersistentClass> arg1, - Properties arg2, - org.hibernate.dialect.Dialect arg3)-
Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.4/apidocs/org/hibernate/cfg/beanvalidation/class-use/TypeSafeActivatorAccessor.html b/dist/hibernate4-maven-plugin-1.0.4/apidocs/org/hibernate/cfg/beanvalidation/class-use/TypeSafeActivatorAccessor.html deleted file mode 100644 index a570654e..00000000 --- a/dist/hibernate4-maven-plugin-1.0.4/apidocs/org/hibernate/cfg/beanvalidation/class-use/TypeSafeActivatorAccessor.html +++ /dev/null @@ -1,117 +0,0 @@ - - - - - - -Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.4/apidocs/org/hibernate/cfg/beanvalidation/package-frame.html b/dist/hibernate4-maven-plugin-1.0.4/apidocs/org/hibernate/cfg/beanvalidation/package-frame.html deleted file mode 100644 index 36c669ea..00000000 --- a/dist/hibernate4-maven-plugin-1.0.4/apidocs/org/hibernate/cfg/beanvalidation/package-frame.html +++ /dev/null @@ -1,20 +0,0 @@ - - - - - - -Class | -Description | -
---|---|
TypeSafeActivatorAccessor | -
- This class enables access to the public methods of
-TypeSafeActivator
- which itself is visible in the package only. |
-
Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.4/apidocs/org/hibernate/cfg/beanvalidation/package-tree.html b/dist/hibernate4-maven-plugin-1.0.4/apidocs/org/hibernate/cfg/beanvalidation/package-tree.html deleted file mode 100644 index 17985c8d..00000000 --- a/dist/hibernate4-maven-plugin-1.0.4/apidocs/org/hibernate/cfg/beanvalidation/package-tree.html +++ /dev/null @@ -1,130 +0,0 @@ - - - - - - -Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.4/apidocs/org/hibernate/cfg/beanvalidation/package-use.html b/dist/hibernate4-maven-plugin-1.0.4/apidocs/org/hibernate/cfg/beanvalidation/package-use.html deleted file mode 100644 index 0062ecbe..00000000 --- a/dist/hibernate4-maven-plugin-1.0.4/apidocs/org/hibernate/cfg/beanvalidation/package-use.html +++ /dev/null @@ -1,117 +0,0 @@ - - - - - - -Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.4/apidocs/overview-frame.html b/dist/hibernate4-maven-plugin-1.0.4/apidocs/overview-frame.html deleted file mode 100644 index ad93ecd5..00000000 --- a/dist/hibernate4-maven-plugin-1.0.4/apidocs/overview-frame.html +++ /dev/null @@ -1,22 +0,0 @@ - - - - - - -- - diff --git a/dist/hibernate4-maven-plugin-1.0.4/apidocs/overview-summary.html b/dist/hibernate4-maven-plugin-1.0.4/apidocs/overview-summary.html deleted file mode 100644 index 1d6d6993..00000000 --- a/dist/hibernate4-maven-plugin-1.0.4/apidocs/overview-summary.html +++ /dev/null @@ -1,135 +0,0 @@ - - - - - - -
Package | -Description | -
---|---|
de.juplo.plugins.hibernate4 | -- |
org.hibernate.cfg.beanvalidation | -- |
Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.4/apidocs/overview-tree.html b/dist/hibernate4-maven-plugin-1.0.4/apidocs/overview-tree.html deleted file mode 100644 index 1d8569ce..00000000 --- a/dist/hibernate4-maven-plugin-1.0.4/apidocs/overview-tree.html +++ /dev/null @@ -1,142 +0,0 @@ - - - - - - -Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.4/apidocs/package-list b/dist/hibernate4-maven-plugin-1.0.4/apidocs/package-list deleted file mode 100644 index b80422d3..00000000 --- a/dist/hibernate4-maven-plugin-1.0.4/apidocs/package-list +++ /dev/null @@ -1,2 +0,0 @@ -de.juplo.plugins.hibernate4 -org.hibernate.cfg.beanvalidation diff --git a/dist/hibernate4-maven-plugin-1.0.4/apidocs/packages b/dist/hibernate4-maven-plugin-1.0.4/apidocs/packages deleted file mode 100644 index ad55515c..00000000 --- a/dist/hibernate4-maven-plugin-1.0.4/apidocs/packages +++ /dev/null @@ -1,2 +0,0 @@ -de.juplo.plugins.hibernate4 -org.hibernate.cfg.beanvalidation \ No newline at end of file diff --git a/dist/hibernate4-maven-plugin-1.0.4/apidocs/resources/background.gif b/dist/hibernate4-maven-plugin-1.0.4/apidocs/resources/background.gif deleted file mode 100644 index f471940f..00000000 Binary files a/dist/hibernate4-maven-plugin-1.0.4/apidocs/resources/background.gif and /dev/null differ diff --git a/dist/hibernate4-maven-plugin-1.0.4/apidocs/resources/tab.gif b/dist/hibernate4-maven-plugin-1.0.4/apidocs/resources/tab.gif deleted file mode 100644 index 1a73a83b..00000000 Binary files a/dist/hibernate4-maven-plugin-1.0.4/apidocs/resources/tab.gif and /dev/null differ diff --git a/dist/hibernate4-maven-plugin-1.0.4/apidocs/resources/titlebar.gif b/dist/hibernate4-maven-plugin-1.0.4/apidocs/resources/titlebar.gif deleted file mode 100644 index 17443b3e..00000000 Binary files a/dist/hibernate4-maven-plugin-1.0.4/apidocs/resources/titlebar.gif and /dev/null differ diff --git a/dist/hibernate4-maven-plugin-1.0.4/apidocs/resources/titlebar_end.gif b/dist/hibernate4-maven-plugin-1.0.4/apidocs/resources/titlebar_end.gif deleted file mode 100644 index 3ad78d46..00000000 Binary files a/dist/hibernate4-maven-plugin-1.0.4/apidocs/resources/titlebar_end.gif and /dev/null differ diff --git a/dist/hibernate4-maven-plugin-1.0.4/apidocs/serialized-form.html b/dist/hibernate4-maven-plugin-1.0.4/apidocs/serialized-form.html deleted file mode 100644 index a549ad1a..00000000 --- a/dist/hibernate4-maven-plugin-1.0.4/apidocs/serialized-form.html +++ /dev/null @@ -1,187 +0,0 @@ - - - - - - -javax.validation.ValidatorFactory factory-
ConcurrentHashMap<K,V> associationsPerEntityPersister-
org.hibernate.cfg.beanvalidation.GroupsPerOperation groupsPerOperation-
boolean initialized-
Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.4/apidocs/stylesheet.css b/dist/hibernate4-maven-plugin-1.0.4/apidocs/stylesheet.css deleted file mode 100644 index 0aeaa97f..00000000 --- a/dist/hibernate4-maven-plugin-1.0.4/apidocs/stylesheet.css +++ /dev/null @@ -1,474 +0,0 @@ -/* Javadoc style sheet */ -/* -Overall document style -*/ -body { - background-color:#ffffff; - color:#353833; - font-family:Arial, Helvetica, sans-serif; - font-size:76%; - margin:0; -} -a:link, a:visited { - text-decoration:none; - color:#4c6b87; -} -a:hover, a:focus { - text-decoration:none; - color:#bb7a2a; -} -a:active { - text-decoration:none; - color:#4c6b87; -} -a[name] { - color:#353833; -} -a[name]:hover { - text-decoration:none; - color:#353833; -} -pre { - font-size:1.3em; -} -h1 { - font-size:1.8em; -} -h2 { - font-size:1.5em; -} -h3 { - font-size:1.4em; -} -h4 { - font-size:1.3em; -} -h5 { - font-size:1.2em; -} -h6 { - font-size:1.1em; -} -ul { - list-style-type:disc; -} -code, tt { - font-size:1.2em; -} -dt code { - font-size:1.2em; -} -table tr td dt code { - font-size:1.2em; - vertical-align:top; -} -sup { - font-size:.6em; -} -/* -Document title and Copyright styles -*/ -.clear { - clear:both; - height:0px; - overflow:hidden; -} -.aboutLanguage { - float:right; - padding:0px 21px; - font-size:.8em; - z-index:200; - margin-top:-7px; -} -.legalCopy { - margin-left:.5em; -} -.bar a, .bar a:link, .bar a:visited, .bar a:active { - color:#FFFFFF; - text-decoration:none; -} -.bar a:hover, .bar a:focus { - color:#bb7a2a; -} -.tab { - background-color:#0066FF; - background-image:url(resources/titlebar.gif); - background-position:left top; - background-repeat:no-repeat; - color:#ffffff; - padding:8px; - width:5em; - font-weight:bold; -} -/* -Navigation bar styles -*/ -.bar { - background-image:url(resources/background.gif); - background-repeat:repeat-x; - color:#FFFFFF; - padding:.8em .5em .4em .8em; - height:auto;/*height:1.8em;*/ - font-size:1em; - margin:0; -} -.topNav { - background-image:url(resources/background.gif); - background-repeat:repeat-x; - color:#FFFFFF; - float:left; - padding:0; - width:100%; - clear:right; - height:2.8em; - padding-top:10px; - overflow:hidden; -} -.bottomNav { - margin-top:10px; - background-image:url(resources/background.gif); - background-repeat:repeat-x; - color:#FFFFFF; - float:left; - padding:0; - width:100%; - clear:right; - height:2.8em; - padding-top:10px; - overflow:hidden; -} -.subNav { - background-color:#dee3e9; - border-bottom:1px solid #9eadc0; - float:left; - width:100%; - overflow:hidden; -} -.subNav div { - clear:left; - float:left; - padding:0 0 5px 6px; -} -ul.navList, ul.subNavList { - float:left; - margin:0 25px 0 0; - padding:0; -} -ul.navList li{ - list-style:none; - float:left; - padding:3px 6px; -} -ul.subNavList li{ - list-style:none; - float:left; - font-size:90%; -} -.topNav a:link, .topNav a:active, .topNav a:visited, .bottomNav a:link, .bottomNav a:active, .bottomNav a:visited { - color:#FFFFFF; - text-decoration:none; -} -.topNav a:hover, .bottomNav a:hover { - text-decoration:none; - color:#bb7a2a; -} -.navBarCell1Rev { - background-image:url(resources/tab.gif); - background-color:#a88834; - color:#FFFFFF; - margin: auto 5px; - border:1px solid #c9aa44; -} -/* -Page header and footer styles -*/ -.header, .footer { - clear:both; - margin:0 20px; - padding:5px 0 0 0; -} -.indexHeader { - margin:10px; - position:relative; -} -.indexHeader h1 { - font-size:1.3em; -} -.title { - color:#2c4557; - margin:10px 0; -} -.subTitle { - margin:5px 0 0 0; -} -.header ul { - margin:0 0 25px 0; - padding:0; -} -.footer ul { - margin:20px 0 5px 0; -} -.header ul li, .footer ul li { - list-style:none; - font-size:1.2em; -} -/* -Heading styles -*/ -div.details ul.blockList ul.blockList ul.blockList li.blockList h4, div.details ul.blockList ul.blockList ul.blockListLast li.blockList h4 { - background-color:#dee3e9; - border-top:1px solid #9eadc0; - border-bottom:1px solid #9eadc0; - margin:0 0 6px -8px; - padding:2px 5px; -} -ul.blockList ul.blockList ul.blockList li.blockList h3 { - background-color:#dee3e9; - border-top:1px solid #9eadc0; - border-bottom:1px solid #9eadc0; - margin:0 0 6px -8px; - padding:2px 5px; -} -ul.blockList ul.blockList li.blockList h3 { - padding:0; - margin:15px 0; -} -ul.blockList li.blockList h2 { - padding:0px 0 20px 0; -} -/* -Page layout container styles -*/ -.contentContainer, .sourceContainer, .classUseContainer, .serializedFormContainer, .constantValuesContainer { - clear:both; - padding:10px 20px; - position:relative; -} -.indexContainer { - margin:10px; - position:relative; - font-size:1.0em; -} -.indexContainer h2 { - font-size:1.1em; - padding:0 0 3px 0; -} -.indexContainer ul { - margin:0; - padding:0; -} -.indexContainer ul li { - list-style:none; -} -.contentContainer .description dl dt, .contentContainer .details dl dt, .serializedFormContainer dl dt { - font-size:1.1em; - font-weight:bold; - margin:10px 0 0 0; - color:#4E4E4E; -} -.contentContainer .description dl dd, .contentContainer .details dl dd, .serializedFormContainer dl dd { - margin:10px 0 10px 20px; -} -.serializedFormContainer dl.nameValue dt { - margin-left:1px; - font-size:1.1em; - display:inline; - font-weight:bold; -} -.serializedFormContainer dl.nameValue dd { - margin:0 0 0 1px; - font-size:1.1em; - display:inline; -} -/* -List styles -*/ -ul.horizontal li { - display:inline; - font-size:0.9em; -} -ul.inheritance { - margin:0; - padding:0; -} -ul.inheritance li { - display:inline; - list-style:none; -} -ul.inheritance li ul.inheritance { - margin-left:15px; - padding-left:15px; - padding-top:1px; -} -ul.blockList, ul.blockListLast { - margin:10px 0 10px 0; - padding:0; -} -ul.blockList li.blockList, ul.blockListLast li.blockList { - list-style:none; - margin-bottom:25px; -} -ul.blockList ul.blockList li.blockList, ul.blockList ul.blockListLast li.blockList { - padding:0px 20px 5px 10px; - border:1px solid #9eadc0; - background-color:#f9f9f9; -} -ul.blockList ul.blockList ul.blockList li.blockList, ul.blockList ul.blockList ul.blockListLast li.blockList { - padding:0 0 5px 8px; - background-color:#ffffff; - border:1px solid #9eadc0; - border-top:none; -} -ul.blockList ul.blockList ul.blockList ul.blockList li.blockList { - margin-left:0; - padding-left:0; - padding-bottom:15px; - border:none; - border-bottom:1px solid #9eadc0; -} -ul.blockList ul.blockList ul.blockList ul.blockList li.blockListLast { - list-style:none; - border-bottom:none; - padding-bottom:0; -} -table tr td dl, table tr td dl dt, table tr td dl dd { - margin-top:0; - margin-bottom:1px; -} -/* -Table styles -*/ -.contentContainer table, .classUseContainer table, .constantValuesContainer table { - border-bottom:1px solid #9eadc0; - width:100%; -} -.contentContainer ul li table, .classUseContainer ul li table, .constantValuesContainer ul li table { - width:100%; -} -.contentContainer .description table, .contentContainer .details table { - border-bottom:none; -} -.contentContainer ul li table th.colOne, .contentContainer ul li table th.colFirst, .contentContainer ul li table th.colLast, .classUseContainer ul li table th, .constantValuesContainer ul li table th, .contentContainer ul li table td.colOne, .contentContainer ul li table td.colFirst, .contentContainer ul li table td.colLast, .classUseContainer ul li table td, .constantValuesContainer ul li table td{ - vertical-align:top; - padding-right:20px; -} -.contentContainer ul li table th.colLast, .classUseContainer ul li table th.colLast,.constantValuesContainer ul li table th.colLast, -.contentContainer ul li table td.colLast, .classUseContainer ul li table td.colLast,.constantValuesContainer ul li table td.colLast, -.contentContainer ul li table th.colOne, .classUseContainer ul li table th.colOne, -.contentContainer ul li table td.colOne, .classUseContainer ul li table td.colOne { - padding-right:3px; -} -.overviewSummary caption, .packageSummary caption, .contentContainer ul.blockList li.blockList caption, .summary caption, .classUseContainer caption, .constantValuesContainer caption { - position:relative; - text-align:left; - background-repeat:no-repeat; - color:#FFFFFF; - font-weight:bold; - clear:none; - overflow:hidden; - padding:0px; - margin:0px; -} -caption a:link, caption a:hover, caption a:active, caption a:visited { - color:#FFFFFF; -} -.overviewSummary caption span, .packageSummary caption span, .contentContainer ul.blockList li.blockList caption span, .summary caption span, .classUseContainer caption span, .constantValuesContainer caption span { - white-space:nowrap; - padding-top:8px; - padding-left:8px; - display:block; - float:left; - background-image:url(resources/titlebar.gif); - height:18px; -} -.overviewSummary .tabEnd, .packageSummary .tabEnd, .contentContainer ul.blockList li.blockList .tabEnd, .summary .tabEnd, .classUseContainer .tabEnd, .constantValuesContainer .tabEnd { - width:10px; - background-image:url(resources/titlebar_end.gif); - background-repeat:no-repeat; - background-position:top right; - position:relative; - float:left; -} -ul.blockList ul.blockList li.blockList table { - margin:0 0 12px 0px; - width:100%; -} -.tableSubHeadingColor { - background-color: #EEEEFF; -} -.altColor { - background-color:#eeeeef; -} -.rowColor { - background-color:#ffffff; -} -.overviewSummary td, .packageSummary td, .contentContainer ul.blockList li.blockList td, .summary td, .classUseContainer td, .constantValuesContainer td { - text-align:left; - padding:3px 3px 3px 7px; -} -th.colFirst, th.colLast, th.colOne, .constantValuesContainer th { - background:#dee3e9; - border-top:1px solid #9eadc0; - border-bottom:1px solid #9eadc0; - text-align:left; - padding:3px 3px 3px 7px; -} -td.colOne a:link, td.colOne a:active, td.colOne a:visited, td.colOne a:hover, td.colFirst a:link, td.colFirst a:active, td.colFirst a:visited, td.colFirst a:hover, td.colLast a:link, td.colLast a:active, td.colLast a:visited, td.colLast a:hover, .constantValuesContainer td a:link, .constantValuesContainer td a:active, .constantValuesContainer td a:visited, .constantValuesContainer td a:hover { - font-weight:bold; -} -td.colFirst, th.colFirst { - border-left:1px solid #9eadc0; - white-space:nowrap; -} -td.colLast, th.colLast { - border-right:1px solid #9eadc0; -} -td.colOne, th.colOne { - border-right:1px solid #9eadc0; - border-left:1px solid #9eadc0; -} -table.overviewSummary { - padding:0px; - margin-left:0px; -} -table.overviewSummary td.colFirst, table.overviewSummary th.colFirst, -table.overviewSummary td.colOne, table.overviewSummary th.colOne { - width:25%; - vertical-align:middle; -} -table.packageSummary td.colFirst, table.overviewSummary th.colFirst { - width:25%; - vertical-align:middle; -} -/* -Content styles -*/ -.description pre { - margin-top:0; -} -.deprecatedContent { - margin:0; - padding:10px 0; -} -.docSummary { - padding:0; -} -/* -Formatting effect styles -*/ -.sourceLineNo { - color:green; - padding:0 30px 0 0; -} -h1.hidden { - visibility:hidden; - overflow:hidden; - font-size:.9em; -} -.block { - display:block; - margin:3px 0 0 0; -} -.strong { - font-weight:bold; -} diff --git a/dist/hibernate4-maven-plugin-1.0.4/configuration.html b/dist/hibernate4-maven-plugin-1.0.4/configuration.html deleted file mode 100644 index 62766ab1..00000000 --- a/dist/hibernate4-maven-plugin-1.0.4/configuration.html +++ /dev/null @@ -1,390 +0,0 @@ - - - - - - - - -- The most simple way to configure the plugin is, to put all the - hibernate-configuration in a hibernate.properties-file on your - classpath. Put the file in the resources-folder. Maven will put - it in the class-folder of your webapp, where it will be picked up - by this plugin as well as by Hibernate 4. -
- -- Doing so, the only additionally configuration needed, to activat the plugin - is the following entry in the plugins-section of your pom.xml: -
- --<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.0.4</version> - <executions> - <execution> - <goals> - <goal>export</goal> - </goals> - </execution> - </executions> -</plugin>
- But be aware, that in this case the database-url, that is - build in the application is the same that is used while testing, where - the database is droped and recreated by the plugin. - Because of that, - - you should never fire up this configuration on your production - system, or your database might be erased! - -
- -- A better approach is, to specify a different url for testing like in the - following snippet: -
- --<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.0.4</version> - <executions> - <execution> - <goals> - <goal>export</goal> - </goals> - </execution> - </executions> - <configuration> - <url><![CDATA[jdbc:mysql://localhost/test-db]]></url> - </configuration> -</plugin>
- Configuration properties, that are set in the configuration-section - of the plugin-configuration cannnot be overwritten elsewere (for details - see Configuration-Method-Precedence). - You never can overwrite them by accident when specifying a property on - the commandline or in your settings.xml. -
-- Alternatively, it is possible, to configure the plugin via maven-properties. - Each relevant configuration-option has a corresponding maven-property - (for a full list see the Documentation of the export-Mojo). - These are named after the - Hibernate JDBC Properties: -
- -- So, instead of writing the hibernate-configuration in the properties-file, - like above, you could put it in the properties-section of your - pom.xml. -
- -- Thogether with the plugin-definition from above, the following would - be a complete configuration (again, the database-url was overwritten in - the plugin-configuration, to be sure to have a separate database for - testing): -
- --<properties> - <hibernate.connection.driver_class>org.hsqldb.jdbcDriver</hibernate.connection.driver_class> - <hibernate.dialect>org.hibernate.dialect.HSQLDialect</hibernate.dialect> - <hibernate.connection.url><![CDATA[jdbc:hsqldb:res:org.my.path.production_db]]></hibernate.connection.url> - <hibernate.connection.username>sa</hibernate.connection.username> - <hibernate.connection.password></hibernate.connection.password> -</properties> - -... - -<plugins> - - ... - - <plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.0.4</version> - <executions> - <execution> - <goals> - <goal>export</goal> - </goals> - </execution> - </executions> - <configuration> - <url><![CDATA[jdbc:hsqldb:target/db/testdb;shutdown=true]]></url> - </configuration> - </plugin> - -<plugins>
- A third way for configuring the plugin is the plugin-configuration. - The relevant configuration-parameters are: -
- -- The equivalent of the configuration from the last section would look - like this: -
- --<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.0.4</version> - <executions> - <execution> - <goals> - <goal>export</goal> - </goals> - </execution> - </executions> - <configuration> - <driverClassName>org.hsqldb.jdbcDriver</driverClassName> - <hibernateDialect>org.hibernate.dialect.HSQLDialect</hibernateDialect> - <url><![CDATA[jdbc:hsqldb:target/db/fotos;shutdown=true]]></url> - <username>sa</username> - <password></password> - </configuration> -</plugin>
- The parameter hibernateProperties (name of the hibernate-properties-file - to use, defaults to hibernate.properties) can only be configured through - this approach. -
- -- For more explanations, see the - Documentation of the export-Mojo. -
-- The configuration is gathered in a fix order: -
- -- If you are in doubt about where a configuration-value comes from, run - maven with the debug-output enabled: mvn -X hibernate4:export - and be aware, that maven-properties can be overwitten on the command-line, - in your ~/.m2/settings.xml and in a profile. -
- -- The plugin-configuration comes last and overwrites everything else. - That way, you can be sure, that a configuration-value, that is - specified in the plugin-configuration will never be overwritten by any - other configuration-method. -
- -- If you need to overwrite plugin-configuration-values with - maven-properties, you can use maven-properties in the plugin-configuration: -
- --<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.0.4</version> - <executions> - <execution> - <goals> - <goal>export</goal> - </goals> - </execution> - </executions> - <configuration> - <password>${my-password-property}</password> - </configuration> -</plugin>
The following document contains the results of PMD's CPD 4.3.
- If you are new to hibernate4-maven-plugin, in many cases, the - {Configuration-Method-Precedence} may be the source of configuration - errors. - To solve this problem, you should run maven with the debugging output - enabled. - For example, by executing: -
- --mvn -X compile hibernate4:export
- (The compile might be necessary, because hibernate4-maven-plugin - has to scan the compiled classes for annotations!) -
- -- Unlike the majority of the maven-plugins, hibernate4-maven-plugin was - designed to give a good many hints, when debugging is enabled. - Because, if you do not know, what went wrong, you can't fix it! -
- -- But be warned: hibernate4-maven-plugin tends to be very chatty ;) -
- - -The following is a list of compile dependencies for this project. These dependencies are required to compile and run the application:
-GroupId | -ArtifactId | -Version | -Type | -License |
---|---|---|---|---|
com.pyx4j | -maven-plugin-log4j | -1.0.1 | -jar | -The Apache Software License, Version 2.0 |
org.apache.maven | -maven-core | -3.2.1 | -jar | -The Apache Software License, Version 2.0 |
org.apache.maven | -maven-plugin-api | -3.2.1 | -jar | -The Apache Software License, Version 2.0 |
org.hibernate | -hibernate-core | -4.3.1.Final | -jar | -GNU Lesser General Public License |
org.hibernate | -hibernate-envers | -4.3.1.Final | -jar | -GNU Lesser General Public License |
org.hibernate | -hibernate-validator | -4.3.1.Final | -jar | -Apache License, Version 2.0 |
org.scannotation | -scannotation | -1.0.3 | -jar | -- |
The following is a list of transitive dependencies for this project. Transitive dependencies are the dependencies of the project dependencies.
-The following is a list of compile dependencies for this project. These dependencies are required to compile and run the application:
-Apache Public License 2.0: Plexus Cipher: encryption/decryption Component, Plexus Security Dispatcher Component
-Apache License, version 2.0: JBoss Logging 3
-Public Domain: AOP alliance, JBoss Logging I18n Annotations
-Unknown: dom4j, scannotation
-Common Development and Distribution License: Java Transaction API
-LGPL 2.1: Javassist
-Apache License, Version 2.0: Bean Validation API, CDI APIs, Hibernate Validator Engine
-MPL 1.1: Javassist
-GNU General Public License, Version 2 with the Classpath Exception: Java Transaction API
-COMMON DEVELOPMENT AND DISTRIBUTION LICENSE (CDDL) Version 1.0: JSR-250 Common Annotations for the JavaTM Platform
-The Apache Software License, Version 2.0: FindBugs-jsr305, Guava: Google Core Libraries for Java, Hibernate 4 Maven Plugin, Log4j, Maven Aether Provider, Maven Artifact, Maven Core, Maven Model, Maven Model Builder, Maven Plugin API, Maven Repository Metadata Model, Maven Settings, Maven Settings Builder, Plexus :: Component Annotations, Plexus Classworlds, Plexus Interpolation API, Sisu Guice - Core Library, XML Commons External Components XML APIs, javax.inject, maven-plugin-log4j
-GNU Lesser General Public License: Core Hibernate O/RM functionality, Entity versioning support, Hibernate Commons Annotations, Hibernate JPA Support
-Eclipse Public License (EPL), Version 1.0: Java Persistence API, Version 2.1
-BSD License: AntLR Parser Generator
-AL 2.0: Java Annotation Indexer
-Apache License 2.0: Javassist
-Eclipse Public License, Version 1.0: Aether API, Aether Implementation, Aether SPI, Aether Utilities, org.eclipse.sisu.inject, org.eclipse.sisu.plexus
-Eclipse Distribution License (EDL), Version 1.0: Java Persistence API, Version 2.1
Filename | -Size | -Entries | -Classes | -Packages | -JDK Rev | -Debug |
---|---|---|---|---|---|---|
antlr-2.7.7.jar | -434.85 kB | -239 | -224 | -12 | -1.2 | -debug |
aopalliance-1.0.jar | -4.36 kB | -15 | -9 | -2 | -1.3 | -debug |
jsr305-1.3.9.jar | -32.24 kB | -72 | -35 | -3 | -1.5 | -debug |
guava-10.0.1.jar | -1.43 MB | -1,185 | -1,164 | -10 | -1.5 | -debug |
maven-plugin-log4j-1.0.1.jar | -3.64 kB | -12 | -1 | -1 | -1.4 | -debug |
dom4j-1.6.1.jar | -306.54 kB | -208 | -190 | -14 | -1.3 | -debug |
javassist-3.12.1.GA.jar | -629.05 kB | -390 | -366 | -17 | -1.4 | -debug |
jsr250-api-1.0.jar | -5.71 kB | -16 | -11 | -2 | -1.5 | -debug |
cdi-api-1.0.jar | -43.86 kB | -92 | -75 | -7 | -1.5 | -debug |
javax.inject-1.jar | -2.44 kB | -8 | -6 | -1 | -1.5 | -release |
validation-api-1.0.0.GA.jar | -46.32 kB | -90 | -76 | -6 | -1.5 | -debug |
log4j-1.2.14.jar | -358.83 kB | -288 | -256 | -19 | -1.1 | -debug |
maven-aether-provider-3.2.1.jar | -59.92 kB | -40 | -23 | -1 | -1.6 | -debug |
maven-artifact-3.2.1.jar | -52.39 kB | -57 | -32 | -11 | -1.6 | -debug |
maven-core-3.2.1.jar | -561.18 kB | -445 | -359 | -48 | -1.6 | -debug |
maven-model-3.2.1.jar | -156.11 kB | -67 | -50 | -3 | -1.6 | -debug |
maven-model-builder-3.2.1.jar | -161.23 kB | -147 | -114 | -16 | -1.6 | -debug |
maven-plugin-api-3.2.1.jar | -44.76 kB | -46 | -25 | -6 | -1.6 | -debug |
maven-repository-metadata-3.2.1.jar | -25.15 kB | -25 | -7 | -2 | -1.6 | -debug |
maven-settings-3.2.1.jar | -41.80 kB | -33 | -17 | -2 | -1.6 | -debug |
maven-settings-builder-3.2.1.jar | -41.74 kB | -53 | -32 | -5 | -1.6 | -debug |
plexus-classworlds-2.5.1.jar | -48.63 kB | -52 | -37 | -5 | -1.5 | -debug |
plexus-component-annotations-1.5.5.jar | -4.11 kB | -15 | -3 | -1 | -1.5 | -release |
plexus-interpolation-1.19.jar | -60.25 kB | -60 | -44 | -6 | -1.5 | -debug |
aether-api-0.9.0.M2.jar | -130.82 kB | -147 | -126 | -11 | -1.5 | -debug |
aether-impl-0.9.0.M2.jar | -141.47 kB | -98 | -80 | -2 | -1.5 | -debug |
aether-spi-0.9.0.M2.jar | -17.29 kB | -36 | -19 | -5 | -1.5 | -debug |
aether-util-0.9.0.M2.jar | -130.46 kB | -118 | -93 | -13 | -1.5 | -debug |
org.eclipse.sisu.inject-0.0.0.M5.jar | -284.57 kB | -236 | -219 | -8 | -1.5 | -debug |
org.eclipse.sisu.plexus-0.0.0.M5.jar | -191.94 kB | -196 | -164 | -20 | -1.5 | -debug |
hibernate-core-4.3.1.Final.jar | -4.97 MB | -3,668 | -3,421 | -199 | -1.6 | -debug |
hibernate-entitymanager-4.3.1.Final.jar | -630.09 kB | -485 | -442 | -27 | -1.6 | -debug |
hibernate-envers-4.3.1.Final.jar | -415.84 kB | -310 | -258 | -38 | -1.6 | -debug |
hibernate-validator-4.3.1.Final.jar | -466.19 kB | -379 | -319 | -31 | -1.6 | -debug |
hibernate-commons-annotations-4.0.4.Final.jar | -73.55 kB | -79 | -67 | -7 | -1.6 | -debug |
hibernate-jpa-2.1-api-1.0.0.Final.jar | -110.71 kB | -207 | -200 | -4 | -1.6 | -debug |
javassist-3.18.1-GA.jar | -697.46 kB | -414 | -390 | -17 | -1.6 | -debug |
jandex-1.1.0.Final.jar | -74.76 kB | -55 | -44 | -1 | -1.6 | -debug |
jboss-logging-3.1.3.GA.jar | -55.84 kB | -57 | -45 | -1 | -1.6 | -debug |
jboss-logging-annotations-1.2.0.Beta1.jar | -11.29 kB | -28 | -16 | -1 | -1.6 | -debug |
jboss-transaction-api_1.2_spec-1.0.0.Final.jar | -27.07 kB | -35 | -22 | -2 | -1.6 | -debug |
scannotation-1.0.3.jar | -18.33 kB | -23 | -13 | -2 | -1.5 | -debug |
plexus-cipher-1.4.jar | -13.18 kB | -20 | -6 | -1 | -1.4 | -debug |
plexus-sec-dispatcher-1.3.jar | -27.89 kB | -31 | -13 | -3 | -1.4 | -debug |
sisu-guice-3.1.0-no_aop.jar | -349.05 kB | -310 | -295 | -8 | -1.5 | -debug |
xml-apis-1.0.b2.jar | -106.76 kB | -217 | -184 | -17 | -1.2 | -release |
Total | -Size | -Entries | -Classes | -Packages | -JDK Rev | -Debug |
46 | -13.34 MB | -10,804 | -9,592 | -618 | -1.6 | -43 |
compile: 46 | -compile: 13.34 MB | -compile: 10,804 | -compile: 9,592 | -compile: 618 | -- | -compile: 43 |
Repo ID | -URL | -Release | -Snapshot | -Blacklisted |
---|---|---|---|---|
plexus.snapshots | -https://oss.sonatype.org/content/repositories/plexus-snapshots | -- | -Yes | -- |
apache.snapshots | -http://repository.apache.org/snapshots | -- | -Yes | -- |
sonatype-nexus-snapshots | -https://oss.sonatype.org/content/repositories/snapshots | -- | -Yes | -- |
snapshots.jboss.org | -http://snapshots.jboss.org/maven2 | -- | -Yes | -- |
jboss | -http://repository.jboss.org/nexus/content/groups/public/ | -Yes | -Yes | -- |
oss.sonatype.org/jboss-snapshots | -http://oss.sonatype.org/content/repositories/jboss-snapshots | -- | -Yes | -- |
central | -http://repo.maven.apache.org/maven2 | -Yes | -- | -- |
repository.jboss.org | -http://repository.jboss.org/maven2 | -Yes | -- | -Yes |
Repository locations for each of the Dependencies.
-<dependency> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.0.4</version> - <type>maven-plugin</type> -</dependency>
<dependency org="de.juplo" name="hibernate4-maven-plugin" rev="1.0.4"> - <artifact name="hibernate4-maven-plugin" type="maven-plugin" /> -</dependency>
The following is the distribution management information used by this project.
- -Full name:
- -de.juplo:hibernate4-maven-plugin:1.0.4:export
- -Description:
- -Attributes:
- -Name | - -Type | - -Since | - -Description | -
---|---|---|---|
delimiter | - -String | - -1.0 | - -Delimiter in output-file. Default value is: ;. User property is: hibernate.export.schema.delimiter. |
-
driverClassName | - -String | - -1.0 | - -SQL-Driver name. User property is: hibernate.connection.driver_class. |
-
envers | - -boolean | - -1.0.3 | - -Generate envers schema for auditing tables. Default value is: false. User property is: hibernate.export.envers. |
-
force | - -boolean | - -1.0 | - -Force execution
-
- Force execution, even if no modified or newly added annotated -classes where found and the dialect was not changed. - -skip takes precedence over force. Default value is: false. User property is: hibernate.export.force. |
-
format | - -boolean | - -1.0 | - -Format output-file. Default value is: true. User property is: hibernate.export.schema.format. |
-
hibernateDialect | - -String | - -1.0 | - -Hibernate dialect. User property is: hibernate.dialect. |
-
hibernateMapping | - -String | - -1.0.2 | - -List of Hibernate-Mapping-Files (XML). Multiple files can be
-separated with white-spaces and/or commas. User property is: hibernate.mapping. |
-
hibernateNamingStrategy | - -String | - -1.0.2 | - -Hibernate Naming Strategy User property is: hibernate.ejb.naming_strategy. |
-
hibernateProperties | - -String | - -1.0 | - -Path to Hibernate configuration file. Default value is: ${project.build.outputDirectory}/hibernate.properties. |
-
outputDirectory | - -String | - -1.0 | - -Classes-Directory to scan.
-
- This parameter defaults to the maven build-output-directory for -classes. Additionally, all dependencies are scanned for annotated -classes. User property is: project.build.outputDirectory. |
-
outputFile | - -String | - -1.0 | - -Output file. Default value is: ${project.build.directory}/schema.sql. User property is: hibernate.export.schema.filename. |
-
password | - -String | - -1.0 | - -Database password User property is: hibernate.connection.password. |
-
scanDependencies | - -String | - -1.0.3 | - -Dependency-Scopes, that should be scanned for annotated classes.
-
- By default, only dependencies in the scope compile -are scanned for annotated classes. Multiple scopes can be seperated -by white space or commas. - -The plugin does not scan for annotated classes in transitive -dependencies. If some of your annotated classes are hidden in a -transitive dependency, you can simply add that dependency -explicitly. Default value is: compile. User property is: hibernate.export.scan_dependencies. |
-
scanTestClasses | - -boolean | - -1.0.1 | - -Whether to scan test-classes too, or not.
-
- If this parameter is set to true the test-classes -of the artifact will be scanned for hibernate-annotated classes -additionally. Default value is: false. User property is: hibernate.export.scan_testclasses. |
-
skip | - -boolean | - -1.0 | - -Skip execution
-
- If set to true, the execution is skipped. - -A skipped execution is signaled via the maven-property -${hibernate.export.skipped}. - -The execution is skipped automatically, if no modified or newly -added annotated classes are found and the dialect was not -changed. Default value is: ${maven.test.skip}. User property is: hibernate.skip. |
-
target | - -String | - -1.0 | - -Target of execution:
-
-
Default value is: EXPORT. User property is: hibernate.export.target. |
-
testOutputDirectory | - -String | - -1.0.2 | - -Test-Classes-Directory to scan.
-
- This parameter defaults to the maven build-output-directory for -test-classes. - -This parameter is only used, when scanTestClasses -is set to true! User property is: project.build.testOutputDirectory. |
-
type | - -String | - -1.0 | - -Type of execution.
-
-
Default value is: BOTH. User property is: hibernate.export.type. |
-
url | - -String | - -1.0 | - -Database URL. User property is: hibernate.connection.url. |
-
username | - -String | - -1.0 | - -Database username User property is: hibernate.connection.username. |
-
Force execution, even if no modified or newly added annotated -classes where found and the dialect was not changed.
- -skip takes precedence over force.
This parameter defaults to the maven build-output-directory for -classes. Additionally, all dependencies are scanned for annotated -classes.
By default, only dependencies in the scope compile -are scanned for annotated classes. Multiple scopes can be seperated -by white space or commas.
- -The plugin does not scan for annotated classes in transitive -dependencies. If some of your annotated classes are hidden in a -transitive dependency, you can simply add that dependency -explicitly.
If this parameter is set to true the test-classes -of the artifact will be scanned for hibernate-annotated classes -additionally.
skip:
- -If set to true, the execution is skipped.
- -A skipped execution is signaled via the maven-property -${hibernate.export.skipped}.
- -The execution is skipped automatically, if no modified or newly -added annotated classes are found and the dialect was not -changed.
This parameter defaults to the maven build-output-directory for -test-classes.
- -This parameter is only used, when scanTestClasses -is set to true!
type:
- -url:
- -- The hibernate4-maven-plugin computes MD5-sums for all found annotated - classes and stores them together with the generated schema. - If no classes were changed or added and the dialect wasn't changed too, it - automatically skips the configured schema-export, to speed up the development - cycle. -
- -- The plugin signals, that the execution was skipped by setting the maven - property $\{hibernate.export.skipped\} to true. - This may be helpful, because other plugins like - dbunit-plugin - may fail, when the execution is skipped. -
- -- If you need the hibernate4-maven-plugin to <never skip execution automatically>, - you can force it to do so, if you set the parameter force to - true: -
- --<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.0.4</version> - <configuration> - <force>true</force> - </configuration> -</plugin>
- Or you may specify -Dhibernate.export.force=true at the command line, - if you want to force hibernate4-maven-plugin only once. -
- - -Full name:
- -de.juplo:hibernate4-maven-plugin:1.0.4:help
- -Description:
- -Attributes:
- -Name | - -Type | - -Since | - -Description | -
---|---|---|---|
detail | - -boolean | - -- | - -If true, display all settable properties for each
-goal. Default value is: false. User property is: detail. |
-
goal | - -String | - -- | - -The name of the goal for which to show help. If unspecified, all
-goals will be displayed. User property is: goal. |
-
indentSize | - -int | - -- | - -The number of spaces per indentation level, should be positive. Default value is: 2. User property is: indentSize. |
-
lineLength | - -int | - -- | - -The maximum length of a display line, should be positive. Default value is: 80. User property is: lineLength. |
-
goal:
- -- The hibernate4-maven-plugin is a plugin for generating a database-schema - from your Hibernate-4-Mappings and create or update your database - accordingly. - Its main usage is to automatically create and populate a test-database - for unit-tests in cooperation with the - dbunit-maven-plugin. -
- -- The plugin was designed with three main goals in mind: -
- -- To achieve the first goal, the convention-over-configuration paradigma - was applied and the plugin was stuffed with usefull logging-messages. - So, if in doubt, just turn on the debugging output with the mvn -X .... -
- -- To achieve the second goal, the precedence in which the configuration - locations are consulted was layouted in a way that makes it possible, to - prevent overwrites of the wrong database by accident. -
- -- Last but not least, in order to not slow down the development cycle, the - hibernate4-maven-plugin only executes the schema-export, if the mapping - or the dialect changes (or if you force it to do so). -
- -- For more information about the inspiration to write this tiny plugin, - read our blog-article about the hibernate4-maven-plugin. -
-Configuration for notifying developers/users when a build is unsuccessful, including user information and notification mode.
-Type | -Address | -Configuration |
---|---|---|
kai@juplo.de | -- |
- Please send your bug-reports, questions or feature-requests directly - to the developer. -
- - -Typically the licenses listed for the project are that of the project itself, and not of dependencies.
A business-friendly OSS license
-- Apache License - Version 2.0, January 2004 - http://www.apache.org/licenses/ - - TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION - - 1. Definitions. - - "License" shall mean the terms and conditions for use, reproduction, - and distribution as defined by Sections 1 through 9 of this document. - - "Licensor" shall mean the copyright owner or entity authorized by - the copyright owner that is granting the License. - - "Legal Entity" shall mean the union of the acting entity and all - other entities that control, are controlled by, or are under common - control with that entity. For the purposes of this definition, - "control" means (i) the power, direct or indirect, to cause the - direction or management of such entity, whether by contract or - otherwise, or (ii) ownership of fifty percent (50%) or more of the - outstanding shares, or (iii) beneficial ownership of such entity. - - "You" (or "Your") shall mean an individual or Legal Entity - exercising permissions granted by this License. - - "Source" form shall mean the preferred form for making modifications, - including but not limited to software source code, documentation - source, and configuration files. - - "Object" form shall mean any form resulting from mechanical - transformation or translation of a Source form, including but - not limited to compiled object code, generated documentation, - and conversions to other media types. - - "Work" shall mean the work of authorship, whether in Source or - Object form, made available under the License, as indicated by a - copyright notice that is included in or attached to the work - (an example is provided in the Appendix below). - - "Derivative Works" shall mean any work, whether in Source or Object - form, that is based on (or derived from) the Work and for which the - editorial revisions, annotations, elaborations, or other modifications - represent, as a whole, an original work of authorship. For the purposes - of this License, Derivative Works shall not include works that remain - separable from, or merely link (or bind by name) to the interfaces of, - the Work and Derivative Works thereof. - - "Contribution" shall mean any work of authorship, including - the original version of the Work and any modifications or additions - to that Work or Derivative Works thereof, that is intentionally - submitted to Licensor for inclusion in the Work by the copyright owner - or by an individual or Legal Entity authorized to submit on behalf of - the copyright owner. For the purposes of this definition, "submitted" - means any form of electronic, verbal, or written communication sent - to the Licensor or its representatives, including but not limited to - communication on electronic mailing lists, source code control systems, - and issue tracking systems that are managed by, or on behalf of, the - Licensor for the purpose of discussing and improving the Work, but - excluding communication that is conspicuously marked or otherwise - designated in writing by the copyright owner as "Not a Contribution." - - "Contributor" shall mean Licensor and any individual or Legal Entity - on behalf of whom a Contribution has been received by Licensor and - subsequently incorporated within the Work. - - 2. Grant of Copyright License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - copyright license to reproduce, prepare Derivative Works of, - publicly display, publicly perform, sublicense, and distribute the - Work and such Derivative Works in Source or Object form. - - 3. Grant of Patent License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - (except as stated in this section) patent license to make, have made, - use, offer to sell, sell, import, and otherwise transfer the Work, - where such license applies only to those patent claims licensable - by such Contributor that are necessarily infringed by their - Contribution(s) alone or by combination of their Contribution(s) - with the Work to which such Contribution(s) was submitted. If You - institute patent litigation against any entity (including a - cross-claim or counterclaim in a lawsuit) alleging that the Work - or a Contribution incorporated within the Work constitutes direct - or contributory patent infringement, then any patent licenses - granted to You under this License for that Work shall terminate - as of the date such litigation is filed. - - 4. Redistribution. You may reproduce and distribute copies of the - Work or Derivative Works thereof in any medium, with or without - modifications, and in Source or Object form, provided that You - meet the following conditions: - - (a) You must give any other recipients of the Work or - Derivative Works a copy of this License; and - - (b) You must cause any modified files to carry prominent notices - stating that You changed the files; and - - (c) You must retain, in the Source form of any Derivative Works - that You distribute, all copyright, patent, trademark, and - attribution notices from the Source form of the Work, - excluding those notices that do not pertain to any part of - the Derivative Works; and - - (d) If the Work includes a "NOTICE" text file as part of its - distribution, then any Derivative Works that You distribute must - include a readable copy of the attribution notices contained - within such NOTICE file, excluding those notices that do not - pertain to any part of the Derivative Works, in at least one - of the following places: within a NOTICE text file distributed - as part of the Derivative Works; within the Source form or - documentation, if provided along with the Derivative Works; or, - within a display generated by the Derivative Works, if and - wherever such third-party notices normally appear. The contents - of the NOTICE file are for informational purposes only and - do not modify the License. You may add Your own attribution - notices within Derivative Works that You distribute, alongside - or as an addendum to the NOTICE text from the Work, provided - that such additional attribution notices cannot be construed - as modifying the License. - - You may add Your own copyright statement to Your modifications and - may provide additional or different license terms and conditions - for use, reproduction, or distribution of Your modifications, or - for any such Derivative Works as a whole, provided Your use, - reproduction, and distribution of the Work otherwise complies with - the conditions stated in this License. - - 5. Submission of Contributions. Unless You explicitly state otherwise, - any Contribution intentionally submitted for inclusion in the Work - by You to the Licensor shall be under the terms and conditions of - this License, without any additional terms or conditions. - Notwithstanding the above, nothing herein shall supersede or modify - the terms of any separate license agreement you may have executed - with Licensor regarding such Contributions. - - 6. Trademarks. This License does not grant permission to use the trade - names, trademarks, service marks, or product names of the Licensor, - except as required for reasonable and customary use in describing the - origin of the Work and reproducing the content of the NOTICE file. - - 7. Disclaimer of Warranty. Unless required by applicable law or - agreed to in writing, Licensor provides the Work (and each - Contributor provides its Contributions) on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or - implied, including, without limitation, any warranties or conditions - of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A - PARTICULAR PURPOSE. You are solely responsible for determining the - appropriateness of using or redistributing the Work and assume any - risks associated with Your exercise of permissions under this License. - - 8. Limitation of Liability. In no event and under no legal theory, - whether in tort (including negligence), contract, or otherwise, - unless required by applicable law (such as deliberate and grossly - negligent acts) or agreed to in writing, shall any Contributor be - liable to You for damages, including any direct, indirect, special, - incidental, or consequential damages of any character arising as a - result of this License or out of the use or inability to use the - Work (including but not limited to damages for loss of goodwill, - work stoppage, computer failure or malfunction, or any and all - other commercial damages or losses), even if such Contributor - has been advised of the possibility of such damages. - - 9. Accepting Warranty or Additional Liability. While redistributing - the Work or Derivative Works thereof, You may choose to offer, - and charge a fee for, acceptance of support, warranty, indemnity, - or other liability obligations and/or rights consistent with this - License. However, in accepting such obligations, You may act only - on Your own behalf and on Your sole responsibility, not on behalf - of any other Contributor, and only if You agree to indemnify, - defend, and hold each Contributor harmless for any liability - incurred by, or claims asserted against, such Contributor by reason - of your accepting any such warranty or additional liability. - - END OF TERMS AND CONDITIONS - - APPENDIX: How to apply the Apache License to your work. - - To apply the Apache License to your work, attach the following - boilerplate notice, with the fields enclosed by brackets "[]" - replaced with your own identifying information. (Don't include - the brackets!) The text should be enclosed in the appropriate - comment syntax for the file format. We also recommend that a - file or class name and description of purpose be included on the - same "printed page" as the copyright notice for easier - identification within third-party archives. - - Copyright [yyyy] [name of copyright owner] - - Licensed under the Apache License, Version 2.0 (the "License"); - you may not use this file except in compliance with the License. - You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. -
- Please send your bug-reports, questions or feature-requests directly - to the developer. -
- - -- hibernate4-maven-plugin by default scans dependencies in the scope - compile. You can configure it to scan dependencies in other - scopes as well. But it scans only direct dependencies. Transitive - dependencies are not scanned for annotated classes. If some of your - annotated classes are hidden in a transitive dependency, you can simply - add that dependency explicitly. -
-- The default-configuration uses the EXPORT-target of the SchemaExport-Tool. - If you do not need to create a database with the evaluated schema, you can - use the NONE- or the SCRIPT-target. - This can be achieved with the command-line parameter - -Dhibernate.export.target=SCRIPT or with the following configuration: -
- --<configuration> - <target>SCRIPT</target> -</configuration>
- But even when no database is to be created, hibernate always needs to know - the dialect. Hence, the plugin will fail if this parameter is missing! -
-- One regular problem is the scope of the jdbc-driver-dependency. - It is very unlikely, that this dependency is needed at compile-time. - So a tidy maven-developer would usually scope it for runtime. -
- -- But this will break the execution of the hibernate4-maven-plugin. - Since it will not be able to see the needed dependency, it will fail with - an error-message like: -
- --[INFO] Gathered hibernate-configuration (turn on debugging for details): -[INFO] hibernate.connection.username = sa -[INFO] hibernate.connection.password = -[INFO] hibernate.dialect = org.hibernate.dialect.HSQLDialect -[INFO] hibernate.connection.url = jdbc:hsqldb:/home/kai/mmf/target/mmf;shutdown=true -[INFO] hibernate.connection.driver_class = org.hsqldb.jdbcDriver -[ERROR] Dependency for driver-class org.hsqldb.jdbcDriver is missing! -[INFO] ------------------------------------------------------------------------ -[ERROR] BUILD ERROR -[INFO] ------------------------------------------------------------------------ -[INFO] org.hsqldb.jdbcDriver -[INFO] ------------------------------------------------------------------------ -[INFO] For more information, run Maven with the -e switch -[INFO] ------------------------------------------------------------------------ -[INFO] Total time: 2 seconds -[INFO] Finished at: Thu Nov 29 11:31:14 CET 2012 -[INFO] Final Memory: 32M/342M -[INFO] ------------------------------------------------------------------------
- A quick workaround for this error would be, to delete the runtime-constraint - for the jdbc-driver-dependency. -
- -- A much cleaner way is, to (additionally) ad the dependency, to the - plugin-definition: -
- --<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.0.4</version> - <executions> - <execution> - <goals> - <goal>export</goal> - </goals> - </execution> - </executions> - <dependencies> - <dependency> - <groupId>org.hsqldb</groupId> - <artifactId>hsqldb</artifactId> - <version>2.2.8</version> - </dependency> - </dependencies> -</plugin>
- This is also the best way, if you use a different jdbc-driver for - testing, than in production. - Because otherwise, this dependency will unnecessarily bloat the - runtime-dependencies of your project. -
-- If hibernate4-maven-plugin skips its excecution, this may lead to errors in - other plugins. - For example, when importing sample-data in the automatically created database - with the help of the dbunit-plugin, - the CLEAN_INSERT-operation may fail because of foreign-key-constraints, - if the database was not recreated, because the hibernate4-maven-plugin has - skipped its excecution. -
- -- A quick fix to this problem is, to force - hibernate4-maven-plugin to export the schema every time it is running. - But to recreate the database on every testrun may noticeable slow down your - development cycle, if you have to wait for slow IO. -
- -- To circumvent this problem, hibernate4-maven-plugin signals a skipped - excecution by setting the maven property $\{hibernate.export.skipped\} to - true. - You can configure other plugins to react on this signal. - For example, the dbunit-plugin can be configured to skip its excecution, if - hibernate4-maven-plugin was skipped like this: -
- --<plugin> - <groupId>org.codehaus.mojo</groupId> - <artifactId>dbunit-maven-plugin</artifactId> - <configuration> - <skip>${hibernate.export.skipped}</skip> - </configuration> -</plugin>
- If one manually drops the database or removes the hsqldb-files, it will not - be recreated by the hibernate4-maven-plugin, because it cannot detect, that - the database needs to be recreated. - This happens, because the plugin will not recreate the database if neither - the configuration nor the annotated classes have changed, because an - unnecessary drop-create-cycle might take a long time. The plugin will - report that like this: -
- --[INFO] No modified annotated classes found and dialect unchanged. -[INFO] Skipping schema generation!
- If one always uses mvn clean for cleanup, this will not happen. - Otherwise the recreation must be forced: -
- --mvn hibernate4:export -Dhibernate.export.force=true
- The hibernate4-maven-plugin automatically skips its execution, when - maven.test.skip is set to true. If you need it to be always - executed, you can configure that explicitly like this: -
- -->plugin< - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - ... - <configuration> - <skip>false</skip> - </configuration> -</plugin>
- Background-information for this design-decission can be found on the extra - page To skip or not to skip: that is the question... -
-Goals available for this plugin:
-Goal | -Description |
---|---|
hibernate4:export | -Goal which extracts the hibernate-mapping-configuration and exports -an according SQL-database-schema. |
hibernate4:help | -Display help information on hibernate4-maven-plugin. -Call mvn hibernate4:help -Ddetail=true
--Dgoal=<goal-name> to display parameter details. |
The following specifies the minimum requirements to run this Maven plugin:
-Maven | -2.0.6 |
JDK | -1.6 |
Memory | -No minimum requirement. |
Disk Space | -No minimum requirement. |
You should specify the version in your project's plugin configuration:
-<project> - ... - <build> - <!-- To define the plugin version in your parent POM --> - <pluginManagement> - <plugins> - <plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.0.4</version> - </plugin> - ... - </plugins> - </pluginManagement> - <!-- To use the plugin goals in your POM or parent POM --> - <plugins> - <plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.0.4</version> - </plugin> - ... - </plugins> - </build> - ... -</project> -
For more information, see "Guide to Configuring Plug-ins"
GroupId | -ArtifactId | -Version |
---|---|---|
org.apache.maven.plugins | -maven-antrun-plugin | -1.3 |
org.apache.maven.plugins | -maven-assembly-plugin | -2.2-beta-5 |
org.apache.maven.plugins | -maven-dependency-plugin | -2.1 |
org.apache.maven.plugins | -maven-release-plugin | -2.1 |
org.apache.maven.plugins | -maven-site-plugin | -3.3 |
GroupId | -ArtifactId | -Version |
---|---|---|
org.apache.maven.plugins | -maven-clean-plugin | -2.5 |
org.apache.maven.plugins | -maven-compiler-plugin | -2.0.2 |
org.apache.maven.plugins | -maven-dependency-plugin | -2.1 |
org.apache.maven.plugins | -maven-deploy-plugin | -2.7 |
org.apache.maven.plugins | -maven-enforcer-plugin | -1.0 |
org.apache.maven.plugins | -maven-install-plugin | -2.3 |
org.apache.maven.plugins | -maven-invoker-plugin | -1.8 |
org.apache.maven.plugins | -maven-jar-plugin | -2.2 |
org.apache.maven.plugins | -maven-plugin-plugin | -3.2 |
org.apache.maven.plugins | -maven-resources-plugin | -2.3 |
org.apache.maven.plugins | -scp://people.apache.org/www/maven.apache.org/scm/maven-scm-plugin | -1.7 |
org.apache.maven.plugins | -maven-site-plugin | -3.3 |
org.apache.maven.plugins | -maven-source-plugin | -2.1.2 |
org.apache.maven.plugins | -maven-surefire-plugin | -2.10 |
GroupId | -ArtifactId | -Version |
---|---|---|
org.apache.maven.plugins | -maven-changes-plugin | -2.7.1 |
org.apache.maven.plugins | -maven-javadoc-plugin | -2.7 |
org.apache.maven.plugins | -maven-jxr-plugin | -2.3 |
org.apache.maven.plugins | -maven-plugin-plugin | -3.2 |
org.apache.maven.plugins | -maven-pmd-plugin | -2.7.1 |
The following document contains the results of PMD 4.3.
This document provides an overview of the various documents and links that are part of this project's general information. All of this content is automatically generated by Maven on behalf of the project.
-Document | -Description |
---|---|
About | -Plugin for generating a database-schema from Hibernate-4-Mapping-Annotations |
Plugin Management | -This document lists the plugins that are defined through pluginManagement. |
Distribution Management | -This document provides informations on the distribution management of this project. |
Dependency Information | -This document describes how to to include this project as a dependency using various dependency management tools. |
Source Repository | -This is a link to the online source repository that can be viewed via a web browser. |
Mailing Lists | -This document provides subscription and archive information for this project's mailing lists. |
Issue Tracking | -This is a link to the issue management system for this project. Issues (bugs, features, change requests) can be created and queried using this link. |
Continuous Integration | -This is a link to the definitions of all continuous integration processes that builds and tests code on a frequent, regular basis. |
Project Plugins | -This document lists the build plugins and the report plugins used by this project. |
Project License | -This is a link to the definitions of project licenses. |
Project Team | -This document provides information on the members of this project. These are the individuals who have contributed to the project in one form or another. |
Project Summary | -This document lists other related information of this project |
Dependencies | -This document lists the project's dependencies and provides information on each dependency. |
This document provides an overview of the various reports that are automatically generated by Maven . Each report is briefly described below.
-Document | -Description |
---|---|
Test JavaDocs | -Test JavaDoc API documentation. |
JavaDocs | -JavaDoc API documentation. |
Source Xref | -HTML based, cross-reference version of Java source code. |
Test Source Xref | -HTML based, cross-reference version of Java test source code. |
PMD Report | -Verification of coding rules. |
CPD Report | -Duplicate code detection. |
Plugin Documentation | -This report provides goals and parameters documentation of a plugin. |
Field | -Value |
---|---|
Name | -Hibernate 4 Maven Plugin |
Description | -Plugin for generating a database-schema from Hibernate-4-Mapping-Annotations |
Homepage | -http://juplo.de/hibernate4-maven-plugin |
- In most use-cases, the hibernate4-maven-plugin is used to create a - test-database automatically. In this use-cases, it is very likely, that it - will result in mistakes/errors, if the goal is executed, when the tests - are skipped. - For example, one might manually overwrite the database-url with the url of - the production-database, in order to run other tests, like starting a - local webserver with the - jetty-maven-plugin. - If the export-goal would be executed in such a scenario, it might erase the - hole production-database, which is not very desireable. -
- -- Because of this, the configuration-parameter skip defaults to the value - of the proptery maven.test.skip. This way, the execution of the - hibernate4-maven-plugin is skipped automatically, when the tests are - skipped. Think of it as a build-in security-belt. -
- -- If you do not like that, because you need the plugin to always execute the - export-goal, even if the tests are skipped you can configure that explicitly, - by setting the configuration-parameter skip to false: -
- --<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - ... - <configuration> - <skip>false</skip> - </configuration> -</plugin>
- Or, if you want the export-goal to be executed by default and to be skipped - if you say so, you can bind the value of the configuration-parameter - skip to a custom property. For example: -
- --<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - ... - <configuration> - <skip>${foo.bar}</skip> - </configuration> -</plugin>
- This way, the export-goal would be skipped, if you set the property - foo.bar to true. For example, if you specify -Dfoo.bar=true - on the command-line. -
- - -This project uses GIT to manage its source code. Instructions on GIT use can be found at http://git-scm.com/documentation.
The source can be checked out anonymously from GIT with this command (See http://git-scm.com/docs/git-clone):
-$ git clone http://juplo.de/git/hibernate4-maven-plugin
Only project developers can access the GIT tree via this method (See http://git-scm.com/docs/git-clone).
-$ git clone ssh://juplo.de/var/lib/git/juplo/hibernate4-maven-plugin
A successful project requires many people to play many roles. Some members write code or documentation, while others are valuable as testers, submitting patches and suggestions.
-The team is comprised of Members and Contributors. Members have direct access to the source of a project and actively evolve the code-base. Contributors improve the project through submission of patches and suggestions to the Members. The number of Contributors to the project is unbounded. Get involved today. All contributions to the project are greatly appreciated.
-The following is a list of developers with commit privileges that have directly contributed to the project in one way or another.
-Image | -Id | -Name | -|
---|---|---|---|
- | kai | -Kai Moritz | -kai@juplo.de |
The following additional people have contributed to this project through the way of suggestions, patches or documentation.
-Image | -Name | -|
---|---|---|
- | Adriano Machado | -adriano.m.machado@hotmail.com |
- | Lorenzo Nicora | -lorenzo.nicora@nicus.it |
- | Eduard Szente | -eduard.szente@gmail.com |
- | Stephen Johnson | -stejohns@redhat.com |
- | Victor Tatai | -vtatai@gmail.com |
- | Erik-Berndt Scheper | -erik.berndt.scheper@gmail.com |
- | Guido Wimmel | -Wimmel.Guido@swm.de |
- | Joel Johnson | -mrjoel@lixil.net |
- | Paul K. Moore | -paulkmoore@gmail.com |
- | Mark Robinson | -mark@mrobinson.ca |
Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.4/testapidocs/de/juplo/test/FileComparator.html b/dist/hibernate4-maven-plugin-1.0.4/testapidocs/de/juplo/test/FileComparator.html deleted file mode 100644 index 3453c589..00000000 --- a/dist/hibernate4-maven-plugin-1.0.4/testapidocs/de/juplo/test/FileComparator.html +++ /dev/null @@ -1,263 +0,0 @@ - - - - - - -public class FileComparator -extends Object-
Constructor and Description | -
---|
FileComparator(File basedir) |
-
public boolean isEqual(String expectedFile, - String foundFile) - throws FileNotFoundException, - IOException-
FileNotFoundException
IOException
Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.4/testapidocs/de/juplo/test/class-use/FileComparator.html b/dist/hibernate4-maven-plugin-1.0.4/testapidocs/de/juplo/test/class-use/FileComparator.html deleted file mode 100644 index f08d1888..00000000 --- a/dist/hibernate4-maven-plugin-1.0.4/testapidocs/de/juplo/test/class-use/FileComparator.html +++ /dev/null @@ -1,115 +0,0 @@ - - - - - - -Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.4/testapidocs/de/juplo/test/package-frame.html b/dist/hibernate4-maven-plugin-1.0.4/testapidocs/de/juplo/test/package-frame.html deleted file mode 100644 index 477ab107..00000000 --- a/dist/hibernate4-maven-plugin-1.0.4/testapidocs/de/juplo/test/package-frame.html +++ /dev/null @@ -1,20 +0,0 @@ - - - - - - -Class | -Description | -
---|---|
FileComparator | -- |
Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.4/testapidocs/de/juplo/test/package-tree.html b/dist/hibernate4-maven-plugin-1.0.4/testapidocs/de/juplo/test/package-tree.html deleted file mode 100644 index 63300c95..00000000 --- a/dist/hibernate4-maven-plugin-1.0.4/testapidocs/de/juplo/test/package-tree.html +++ /dev/null @@ -1,124 +0,0 @@ - - - - - - -Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.4/testapidocs/de/juplo/test/package-use.html b/dist/hibernate4-maven-plugin-1.0.4/testapidocs/de/juplo/test/package-use.html deleted file mode 100644 index 4fec9955..00000000 --- a/dist/hibernate4-maven-plugin-1.0.4/testapidocs/de/juplo/test/package-use.html +++ /dev/null @@ -1,115 +0,0 @@ - - - - - - -Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.4/testapidocs/deprecated-list.html b/dist/hibernate4-maven-plugin-1.0.4/testapidocs/deprecated-list.html deleted file mode 100644 index 2f691805..00000000 --- a/dist/hibernate4-maven-plugin-1.0.4/testapidocs/deprecated-list.html +++ /dev/null @@ -1,115 +0,0 @@ - - - - - - -Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.4/testapidocs/help-doc.html b/dist/hibernate4-maven-plugin-1.0.4/testapidocs/help-doc.html deleted file mode 100644 index 020a2639..00000000 --- a/dist/hibernate4-maven-plugin-1.0.4/testapidocs/help-doc.html +++ /dev/null @@ -1,216 +0,0 @@ - - - - - - -Each package has a page that contains a list of its classes and interfaces, with a summary for each. This page can contain six categories:
-Each class, interface, nested class and nested interface has its own separate page. Each of these pages has three sections consisting of a class/interface description, summary tables, and detailed member descriptions:
-Each summary entry contains the first sentence from the detailed description for that item. The summary entries are alphabetical, while the detailed descriptions are in the order they appear in the source code. This preserves the logical groupings established by the programmer.
-Each annotation type has its own separate page with the following sections:
-Each enum has its own separate page with the following sections:
-Each documented package, class and interface has its own Use page. This page describes what packages, classes, methods, constructors and fields use any part of the given class or package. Given a class or interface A, its Use page includes subclasses of A, fields declared as A, methods that return A, and methods and constructors with parameters of type A. You can access this page by first going to the package, class or interface, then clicking on the "Use" link in the navigation bar.
-There is a Class Hierarchy page for all packages, plus a hierarchy for each package. Each hierarchy page contains a list of classes and a list of interfaces. The classes are organized by inheritance structure starting with java.lang.Object
. The interfaces do not inherit from java.lang.Object
.
The Deprecated API page lists all of the API that have been deprecated. A deprecated API is not recommended for use, generally due to improvements, and a replacement API is usually given. Deprecated APIs may be removed in future implementations.
-The Index contains an alphabetic list of all classes, interfaces, constructors, methods, and fields.
-These links take you to the next or previous class, interface, package, or related page.
-These links show and hide the HTML frames. All pages are available with or without frames.
-The All Classes link shows all classes and interfaces except non-static nested types.
-Each serializable or externalizable class has a description of its serialization fields and methods. This information is of interest to re-implementors, not to developers using the API. While there is no link in the navigation bar, you can get to this information by going to any serialized class and clicking "Serialized Form" in the "See also" section of the class description.
-The Constant Field Values page lists the static final fields and their values.
-Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.4/testapidocs/index-all.html b/dist/hibernate4-maven-plugin-1.0.4/testapidocs/index-all.html deleted file mode 100644 index 0dc2e035..00000000 --- a/dist/hibernate4-maven-plugin-1.0.4/testapidocs/index-all.html +++ /dev/null @@ -1,138 +0,0 @@ - - - - - - -Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.4/testapidocs/index.html b/dist/hibernate4-maven-plugin-1.0.4/testapidocs/index.html deleted file mode 100644 index 1cefceb7..00000000 --- a/dist/hibernate4-maven-plugin-1.0.4/testapidocs/index.html +++ /dev/null @@ -1,65 +0,0 @@ - - - - - - -This document is designed to be viewed using the frames feature. If you see this message, you are using a non-frame-capable web client. Link to Non-frame version.
-Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.4/testapidocs/package-list b/dist/hibernate4-maven-plugin-1.0.4/testapidocs/package-list deleted file mode 100644 index 4774195e..00000000 --- a/dist/hibernate4-maven-plugin-1.0.4/testapidocs/package-list +++ /dev/null @@ -1 +0,0 @@ -de.juplo.test diff --git a/dist/hibernate4-maven-plugin-1.0.4/testapidocs/packages b/dist/hibernate4-maven-plugin-1.0.4/testapidocs/packages deleted file mode 100644 index 8fbea680..00000000 --- a/dist/hibernate4-maven-plugin-1.0.4/testapidocs/packages +++ /dev/null @@ -1 +0,0 @@ -de.juplo.test \ No newline at end of file diff --git a/dist/hibernate4-maven-plugin-1.0.4/testapidocs/resources/background.gif b/dist/hibernate4-maven-plugin-1.0.4/testapidocs/resources/background.gif deleted file mode 100644 index f471940f..00000000 Binary files a/dist/hibernate4-maven-plugin-1.0.4/testapidocs/resources/background.gif and /dev/null differ diff --git a/dist/hibernate4-maven-plugin-1.0.4/testapidocs/resources/tab.gif b/dist/hibernate4-maven-plugin-1.0.4/testapidocs/resources/tab.gif deleted file mode 100644 index 1a73a83b..00000000 Binary files a/dist/hibernate4-maven-plugin-1.0.4/testapidocs/resources/tab.gif and /dev/null differ diff --git a/dist/hibernate4-maven-plugin-1.0.4/testapidocs/resources/titlebar.gif b/dist/hibernate4-maven-plugin-1.0.4/testapidocs/resources/titlebar.gif deleted file mode 100644 index 17443b3e..00000000 Binary files a/dist/hibernate4-maven-plugin-1.0.4/testapidocs/resources/titlebar.gif and /dev/null differ diff --git a/dist/hibernate4-maven-plugin-1.0.4/testapidocs/resources/titlebar_end.gif b/dist/hibernate4-maven-plugin-1.0.4/testapidocs/resources/titlebar_end.gif deleted file mode 100644 index 3ad78d46..00000000 Binary files a/dist/hibernate4-maven-plugin-1.0.4/testapidocs/resources/titlebar_end.gif and /dev/null differ diff --git a/dist/hibernate4-maven-plugin-1.0.4/testapidocs/stylesheet.css b/dist/hibernate4-maven-plugin-1.0.4/testapidocs/stylesheet.css deleted file mode 100644 index 0aeaa97f..00000000 --- a/dist/hibernate4-maven-plugin-1.0.4/testapidocs/stylesheet.css +++ /dev/null @@ -1,474 +0,0 @@ -/* Javadoc style sheet */ -/* -Overall document style -*/ -body { - background-color:#ffffff; - color:#353833; - font-family:Arial, Helvetica, sans-serif; - font-size:76%; - margin:0; -} -a:link, a:visited { - text-decoration:none; - color:#4c6b87; -} -a:hover, a:focus { - text-decoration:none; - color:#bb7a2a; -} -a:active { - text-decoration:none; - color:#4c6b87; -} -a[name] { - color:#353833; -} -a[name]:hover { - text-decoration:none; - color:#353833; -} -pre { - font-size:1.3em; -} -h1 { - font-size:1.8em; -} -h2 { - font-size:1.5em; -} -h3 { - font-size:1.4em; -} -h4 { - font-size:1.3em; -} -h5 { - font-size:1.2em; -} -h6 { - font-size:1.1em; -} -ul { - list-style-type:disc; -} -code, tt { - font-size:1.2em; -} -dt code { - font-size:1.2em; -} -table tr td dt code { - font-size:1.2em; - vertical-align:top; -} -sup { - font-size:.6em; -} -/* -Document title and Copyright styles -*/ -.clear { - clear:both; - height:0px; - overflow:hidden; -} -.aboutLanguage { - float:right; - padding:0px 21px; - font-size:.8em; - z-index:200; - margin-top:-7px; -} -.legalCopy { - margin-left:.5em; -} -.bar a, .bar a:link, .bar a:visited, .bar a:active { - color:#FFFFFF; - text-decoration:none; -} -.bar a:hover, .bar a:focus { - color:#bb7a2a; -} -.tab { - background-color:#0066FF; - background-image:url(resources/titlebar.gif); - background-position:left top; - background-repeat:no-repeat; - color:#ffffff; - padding:8px; - width:5em; - font-weight:bold; -} -/* -Navigation bar styles -*/ -.bar { - background-image:url(resources/background.gif); - background-repeat:repeat-x; - color:#FFFFFF; - padding:.8em .5em .4em .8em; - height:auto;/*height:1.8em;*/ - font-size:1em; - margin:0; -} -.topNav { - background-image:url(resources/background.gif); - background-repeat:repeat-x; - color:#FFFFFF; - float:left; - padding:0; - width:100%; - clear:right; - height:2.8em; - padding-top:10px; - overflow:hidden; -} -.bottomNav { - margin-top:10px; - background-image:url(resources/background.gif); - background-repeat:repeat-x; - color:#FFFFFF; - float:left; - padding:0; - width:100%; - clear:right; - height:2.8em; - padding-top:10px; - overflow:hidden; -} -.subNav { - background-color:#dee3e9; - border-bottom:1px solid #9eadc0; - float:left; - width:100%; - overflow:hidden; -} -.subNav div { - clear:left; - float:left; - padding:0 0 5px 6px; -} -ul.navList, ul.subNavList { - float:left; - margin:0 25px 0 0; - padding:0; -} -ul.navList li{ - list-style:none; - float:left; - padding:3px 6px; -} -ul.subNavList li{ - list-style:none; - float:left; - font-size:90%; -} -.topNav a:link, .topNav a:active, .topNav a:visited, .bottomNav a:link, .bottomNav a:active, .bottomNav a:visited { - color:#FFFFFF; - text-decoration:none; -} -.topNav a:hover, .bottomNav a:hover { - text-decoration:none; - color:#bb7a2a; -} -.navBarCell1Rev { - background-image:url(resources/tab.gif); - background-color:#a88834; - color:#FFFFFF; - margin: auto 5px; - border:1px solid #c9aa44; -} -/* -Page header and footer styles -*/ -.header, .footer { - clear:both; - margin:0 20px; - padding:5px 0 0 0; -} -.indexHeader { - margin:10px; - position:relative; -} -.indexHeader h1 { - font-size:1.3em; -} -.title { - color:#2c4557; - margin:10px 0; -} -.subTitle { - margin:5px 0 0 0; -} -.header ul { - margin:0 0 25px 0; - padding:0; -} -.footer ul { - margin:20px 0 5px 0; -} -.header ul li, .footer ul li { - list-style:none; - font-size:1.2em; -} -/* -Heading styles -*/ -div.details ul.blockList ul.blockList ul.blockList li.blockList h4, div.details ul.blockList ul.blockList ul.blockListLast li.blockList h4 { - background-color:#dee3e9; - border-top:1px solid #9eadc0; - border-bottom:1px solid #9eadc0; - margin:0 0 6px -8px; - padding:2px 5px; -} -ul.blockList ul.blockList ul.blockList li.blockList h3 { - background-color:#dee3e9; - border-top:1px solid #9eadc0; - border-bottom:1px solid #9eadc0; - margin:0 0 6px -8px; - padding:2px 5px; -} -ul.blockList ul.blockList li.blockList h3 { - padding:0; - margin:15px 0; -} -ul.blockList li.blockList h2 { - padding:0px 0 20px 0; -} -/* -Page layout container styles -*/ -.contentContainer, .sourceContainer, .classUseContainer, .serializedFormContainer, .constantValuesContainer { - clear:both; - padding:10px 20px; - position:relative; -} -.indexContainer { - margin:10px; - position:relative; - font-size:1.0em; -} -.indexContainer h2 { - font-size:1.1em; - padding:0 0 3px 0; -} -.indexContainer ul { - margin:0; - padding:0; -} -.indexContainer ul li { - list-style:none; -} -.contentContainer .description dl dt, .contentContainer .details dl dt, .serializedFormContainer dl dt { - font-size:1.1em; - font-weight:bold; - margin:10px 0 0 0; - color:#4E4E4E; -} -.contentContainer .description dl dd, .contentContainer .details dl dd, .serializedFormContainer dl dd { - margin:10px 0 10px 20px; -} -.serializedFormContainer dl.nameValue dt { - margin-left:1px; - font-size:1.1em; - display:inline; - font-weight:bold; -} -.serializedFormContainer dl.nameValue dd { - margin:0 0 0 1px; - font-size:1.1em; - display:inline; -} -/* -List styles -*/ -ul.horizontal li { - display:inline; - font-size:0.9em; -} -ul.inheritance { - margin:0; - padding:0; -} -ul.inheritance li { - display:inline; - list-style:none; -} -ul.inheritance li ul.inheritance { - margin-left:15px; - padding-left:15px; - padding-top:1px; -} -ul.blockList, ul.blockListLast { - margin:10px 0 10px 0; - padding:0; -} -ul.blockList li.blockList, ul.blockListLast li.blockList { - list-style:none; - margin-bottom:25px; -} -ul.blockList ul.blockList li.blockList, ul.blockList ul.blockListLast li.blockList { - padding:0px 20px 5px 10px; - border:1px solid #9eadc0; - background-color:#f9f9f9; -} -ul.blockList ul.blockList ul.blockList li.blockList, ul.blockList ul.blockList ul.blockListLast li.blockList { - padding:0 0 5px 8px; - background-color:#ffffff; - border:1px solid #9eadc0; - border-top:none; -} -ul.blockList ul.blockList ul.blockList ul.blockList li.blockList { - margin-left:0; - padding-left:0; - padding-bottom:15px; - border:none; - border-bottom:1px solid #9eadc0; -} -ul.blockList ul.blockList ul.blockList ul.blockList li.blockListLast { - list-style:none; - border-bottom:none; - padding-bottom:0; -} -table tr td dl, table tr td dl dt, table tr td dl dd { - margin-top:0; - margin-bottom:1px; -} -/* -Table styles -*/ -.contentContainer table, .classUseContainer table, .constantValuesContainer table { - border-bottom:1px solid #9eadc0; - width:100%; -} -.contentContainer ul li table, .classUseContainer ul li table, .constantValuesContainer ul li table { - width:100%; -} -.contentContainer .description table, .contentContainer .details table { - border-bottom:none; -} -.contentContainer ul li table th.colOne, .contentContainer ul li table th.colFirst, .contentContainer ul li table th.colLast, .classUseContainer ul li table th, .constantValuesContainer ul li table th, .contentContainer ul li table td.colOne, .contentContainer ul li table td.colFirst, .contentContainer ul li table td.colLast, .classUseContainer ul li table td, .constantValuesContainer ul li table td{ - vertical-align:top; - padding-right:20px; -} -.contentContainer ul li table th.colLast, .classUseContainer ul li table th.colLast,.constantValuesContainer ul li table th.colLast, -.contentContainer ul li table td.colLast, .classUseContainer ul li table td.colLast,.constantValuesContainer ul li table td.colLast, -.contentContainer ul li table th.colOne, .classUseContainer ul li table th.colOne, -.contentContainer ul li table td.colOne, .classUseContainer ul li table td.colOne { - padding-right:3px; -} -.overviewSummary caption, .packageSummary caption, .contentContainer ul.blockList li.blockList caption, .summary caption, .classUseContainer caption, .constantValuesContainer caption { - position:relative; - text-align:left; - background-repeat:no-repeat; - color:#FFFFFF; - font-weight:bold; - clear:none; - overflow:hidden; - padding:0px; - margin:0px; -} -caption a:link, caption a:hover, caption a:active, caption a:visited { - color:#FFFFFF; -} -.overviewSummary caption span, .packageSummary caption span, .contentContainer ul.blockList li.blockList caption span, .summary caption span, .classUseContainer caption span, .constantValuesContainer caption span { - white-space:nowrap; - padding-top:8px; - padding-left:8px; - display:block; - float:left; - background-image:url(resources/titlebar.gif); - height:18px; -} -.overviewSummary .tabEnd, .packageSummary .tabEnd, .contentContainer ul.blockList li.blockList .tabEnd, .summary .tabEnd, .classUseContainer .tabEnd, .constantValuesContainer .tabEnd { - width:10px; - background-image:url(resources/titlebar_end.gif); - background-repeat:no-repeat; - background-position:top right; - position:relative; - float:left; -} -ul.blockList ul.blockList li.blockList table { - margin:0 0 12px 0px; - width:100%; -} -.tableSubHeadingColor { - background-color: #EEEEFF; -} -.altColor { - background-color:#eeeeef; -} -.rowColor { - background-color:#ffffff; -} -.overviewSummary td, .packageSummary td, .contentContainer ul.blockList li.blockList td, .summary td, .classUseContainer td, .constantValuesContainer td { - text-align:left; - padding:3px 3px 3px 7px; -} -th.colFirst, th.colLast, th.colOne, .constantValuesContainer th { - background:#dee3e9; - border-top:1px solid #9eadc0; - border-bottom:1px solid #9eadc0; - text-align:left; - padding:3px 3px 3px 7px; -} -td.colOne a:link, td.colOne a:active, td.colOne a:visited, td.colOne a:hover, td.colFirst a:link, td.colFirst a:active, td.colFirst a:visited, td.colFirst a:hover, td.colLast a:link, td.colLast a:active, td.colLast a:visited, td.colLast a:hover, .constantValuesContainer td a:link, .constantValuesContainer td a:active, .constantValuesContainer td a:visited, .constantValuesContainer td a:hover { - font-weight:bold; -} -td.colFirst, th.colFirst { - border-left:1px solid #9eadc0; - white-space:nowrap; -} -td.colLast, th.colLast { - border-right:1px solid #9eadc0; -} -td.colOne, th.colOne { - border-right:1px solid #9eadc0; - border-left:1px solid #9eadc0; -} -table.overviewSummary { - padding:0px; - margin-left:0px; -} -table.overviewSummary td.colFirst, table.overviewSummary th.colFirst, -table.overviewSummary td.colOne, table.overviewSummary th.colOne { - width:25%; - vertical-align:middle; -} -table.packageSummary td.colFirst, table.overviewSummary th.colFirst { - width:25%; - vertical-align:middle; -} -/* -Content styles -*/ -.description pre { - margin-top:0; -} -.deprecatedContent { - margin:0; - padding:10px 0; -} -.docSummary { - padding:0; -} -/* -Formatting effect styles -*/ -.sourceLineNo { - color:green; - padding:0 30px 0 0; -} -h1.hidden { - visibility:hidden; - overflow:hidden; - font-size:.9em; -} -.block { - display:block; - margin:3px 0 0 0; -} -.strong { - font-weight:bold; -} diff --git a/dist/hibernate4-maven-plugin-1.0.4/xref-test/allclasses-frame.html b/dist/hibernate4-maven-plugin-1.0.4/xref-test/allclasses-frame.html deleted file mode 100644 index 4c39da54..00000000 --- a/dist/hibernate4-maven-plugin-1.0.4/xref-test/allclasses-frame.html +++ /dev/null @@ -1,20 +0,0 @@ - - - - - -- -1 package de.juplo.test; -2 -3 import java.io.BufferedReader; -4 import java.io.File; -5 import java.io.FileNotFoundException; -6 import java.io.FileReader; -7 import java.io.IOException; -8 -9 -10 public class FileComparator -11 { -12 private final File basedir; -13 private BufferedReader expectedReader; -14 private BufferedReader foundReader; -15 -16 public FileComparator(File basedir) -17 { -18 this.basedir = basedir; -19 } -20 -21 public boolean isEqual(final String expectedFile, final String foundFile) -22 throws -23 FileNotFoundException, -24 IOException -25 { -26 File file; -27 String expected, found; -28 -29 file = new File(basedir, expectedFile); -30 expectedReader = new BufferedReader(new FileReader(file)); -31 -32 file = new File(basedir, foundFile); -33 foundReader = new BufferedReader(new FileReader(file)); -34 -35 -36 while ((expected = expectedReader.readLine()) != null) -37 { -38 found = foundReader.readLine(); -39 if (!expected.equals(found)) -40 { -41 System.err.println("Mismatch!"); -42 System.err.println("Expected: " + expected); -43 System.err.println("Found: " + found); -44 return false; -45 } -46 } -47 -48 if ((found = foundReader.readLine()) != null) -49 { -50 System.err.println("Found more content than expected!"); -51 System.err.println("Starting with: " + found); -52 return false; -53 } -54 -55 return true; -56 } -57 } --
Class Summary | -
---|
- FileComparator - | -
- You don't have frames. Go here -
- -Packages | -
---|
- de.juplo.test - | -
- -1 package de.juplo.plugins.hibernate4; -2 -3 /* -4 * Copyright 2001-2005 The Apache Software Foundation. -5 * -6 * Licensed under the Apache License, Version 2.0 (the "License"); -7 * you may not use this file except in compliance with the License. -8 * You may obtain a copy of the License at -9 * -10 * http://www.apache.org/licenses/LICENSE-2.0 -11 * -12 * Unless required by applicable law or agreed to in writing, software -13 * distributed under the License is distributed on an "AS IS" BASIS, -14 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -15 * See the License for the specific language governing permissions and -16 * limitations under the License. -17 */ -18 -19 import com.pyx4j.log4j.MavenLogAppender; -20 import java.io.File; -21 import java.io.FileInputStream; -22 import java.io.FileNotFoundException; -23 import java.io.FileOutputStream; -24 import java.io.IOException; -25 import java.io.InputStream; -26 import java.io.ObjectInputStream; -27 import java.io.ObjectOutputStream; -28 import java.math.BigInteger; -29 import java.net.URL; -30 import java.net.URLClassLoader; -31 import java.security.MessageDigest; -32 import java.security.NoSuchAlgorithmException; -33 import java.sql.Connection; -34 import java.sql.Driver; -35 import java.sql.DriverManager; -36 import java.sql.DriverPropertyInfo; -37 import java.sql.SQLException; -38 import java.sql.SQLFeatureNotSupportedException; -39 import java.util.Comparator; -40 import java.util.Enumeration; -41 import java.util.HashMap; -42 import java.util.HashSet; -43 import java.util.List; -44 import java.util.Map; -45 import java.util.Map.Entry; -46 import java.util.Properties; -47 import java.util.Set; -48 import java.util.TreeSet; -49 import java.util.logging.Logger; -50 import java.util.regex.Matcher; -51 import java.util.regex.Pattern; -52 import javax.persistence.Embeddable; -53 import javax.persistence.Entity; -54 import javax.persistence.MappedSuperclass; -55 import org.apache.maven.artifact.Artifact; -56 import org.apache.maven.model.Resource; -57 import org.apache.maven.plugin.AbstractMojo; -58 import org.apache.maven.plugin.MojoExecutionException; -59 import org.apache.maven.plugin.MojoFailureException; -60 import org.apache.maven.project.MavenProject; -61 import org.hibernate.cfg.Configuration; -62 import org.hibernate.cfg.NamingStrategy; -63 import org.hibernate.envers.configuration.spi.AuditConfiguration; -64 import org.hibernate.tool.hbm2ddl.SchemaExport; -65 import org.hibernate.tool.hbm2ddl.SchemaExport.Type; -66 import org.hibernate.tool.hbm2ddl.Target; -67 import org.scannotation.AnnotationDB; -68 -69 -70 /** -71 * Goal which extracts the hibernate-mapping-configuration and -72 * exports an according SQL-database-schema. -73 * -74 * @goal export -75 * @phase process-classes -76 * @threadSafe -77 * @requiresDependencyResolution runtime -78 */ -79 public class Hbm2DdlMojo extends AbstractMojo -80 { -81 public final static String EXPORT_SKIPPED_PROPERTY = "hibernate.export.skipped"; -82 -83 public final static String DRIVER_CLASS = "hibernate.connection.driver_class"; -84 public final static String URL = "hibernate.connection.url"; -85 public final static String USERNAME = "hibernate.connection.username"; -86 public final static String PASSWORD = "hibernate.connection.password"; -87 public final static String DIALECT = "hibernate.dialect"; -88 public final static String NAMING_STRATEGY="hibernate.ejb.naming_strategy"; -89 public final static String ENVERS = "hibernate.export.envers"; -90 -91 public final static String MD5S = "hibernate4-generatedschema.md5s"; -92 -93 private final static Pattern split = Pattern.compile("[^,\\s]+"); -94 -95 -96 /** -97 * The maven project. -98 * <p> -99 * Only needed internally. -100 * -101 * @parameter property="project" -102 * @required -103 * @readonly -104 */ -105 private MavenProject project; -106 -107 /** -108 * Build-directory. -109 * <p> -110 * Only needed internally. -111 * -112 * @parameter property="project.build.directory" -113 * @required -114 * @readonly -115 */ -116 private String buildDirectory; -117 -118 /** -119 * Classes-Directory to scan. -120 * <p> -121 * This parameter defaults to the maven build-output-directory for classes. -122 * Additionally, all dependencies are scanned for annotated classes. -123 * -124 * @parameter property="project.build.outputDirectory" -125 * @since 1.0 -126 */ -127 private String outputDirectory; -128 -129 /** -130 * Whether to scan test-classes too, or not. -131 * <p> -132 * If this parameter is set to <code>true</code> the test-classes of the -133 * artifact will be scanned for hibernate-annotated classes additionally. -134 * -135 * @parameter property="hibernate.export.scan_testclasses" default-value="false" -136 * @since 1.0.1 -137 */ -138 private boolean scanTestClasses; -139 -140 /** -141 * Dependency-Scopes, that should be scanned for annotated classes. -142 * <p> -143 * By default, only dependencies in the scope <code>compile</code> are -144 * scanned for annotated classes. Multiple scopes can be seperated by -145 * white space or commas. -146 * <p> -147 * The plugin does not scan for annotated classes in transitive -148 * dependencies. If some of your annotated classes are hidden in a -149 * transitive dependency, you can simply add that dependency explicitly. -150 * -151 * @parameter property="hibernate.export.scan_dependencies" default-value="compile" -152 * @since 1.0.3 -153 */ -154 private String scanDependencies; -155 -156 /** -157 * Test-Classes-Directory to scan. -158 * <p> -159 * This parameter defaults to the maven build-output-directory for -160 * test-classes. -161 * <p> -162 * This parameter is only used, when <code>scanTestClasses</code> is set -163 * to <code>true</code>! -164 * -165 * @parameter property="project.build.testOutputDirectory" -166 * @since 1.0.2 -167 */ -168 private String testOutputDirectory; -169 -170 /** -171 * Skip execution -172 * <p> -173 * If set to <code>true</code>, the execution is skipped. -174 * <p> -175 * A skipped execution is signaled via the maven-property -176 * <code>${hibernate.export.skipped}</code>. -177 * <p> -178 * The execution is skipped automatically, if no modified or newly added -179 * annotated classes are found and the dialect was not changed. -180 * -181 * @parameter property="hibernate.skip" default-value="${maven.test.skip}" -182 * @since 1.0 -183 */ -184 private boolean skip; -185 -186 /** -187 * Force execution -188 * <p> -189 * Force execution, even if no modified or newly added annotated classes -190 * where found and the dialect was not changed. -191 * <p> -192 * <code>skip</code> takes precedence over <code>force</code>. -193 * -194 * @parameter property="hibernate.export.force" default-value="false" -195 * @since 1.0 -196 */ -197 private boolean force; -198 -199 /** -200 * SQL-Driver name. -201 * -202 * @parameter property="hibernate.connection.driver_class" -203 * @since 1.0 -204 */ -205 private String driverClassName; -206 -207 /** -208 * Database URL. -209 * -210 * @parameter property="hibernate.connection.url" -211 * @since 1.0 -212 */ -213 private String url; -214 -215 /** -216 * Database username -217 * -218 * @parameter property="hibernate.connection.username" -219 * @since 1.0 -220 */ -221 private String username; -222 -223 /** -224 * Database password -225 * -226 * @parameter property="hibernate.connection.password" -227 * @since 1.0 -228 */ -229 private String password; -230 -231 /** -232 * Hibernate dialect. -233 * -234 * @parameter property="hibernate.dialect" -235 * @since 1.0 -236 */ -237 private String hibernateDialect; -238 -239 /** -240 * Hibernate Naming Strategy -241 * -242 * @parameter property="hibernate.ejb.naming_strategy" -243 * @since 1.0.2 -244 */ -245 private String hibernateNamingStrategy; -246 -247 /** -248 * Path to Hibernate configuration file. -249 * -250 * @parameter default-value="${project.build.outputDirectory}/hibernate.properties" -251 * @since 1.0 -252 */ -253 private String hibernateProperties; -254 -255 /** -256 * List of Hibernate-Mapping-Files (XML). -257 * Multiple files can be separated with white-spaces and/or commas. -258 * -259 * @parameter property="hibernate.mapping" -260 * @since 1.0.2 -261 */ -262 private String hibernateMapping; -263 -264 /** -265 * Target of execution: -266 * <ul> -267 * <li><strong>NONE</strong> only export schema to SQL-script (forces execution, signals skip)</li> -268 * <li><strong>EXPORT</strong> create database (<strong>DEFAULT!</strong>). forces execution, signals skip)</li> -269 * <li><strong>SCRIPT</strong> export schema to SQL-script and print it to STDOUT</li> -270 * <li><strong>BOTH</strong></li> -271 * </ul> -272 * -273 * A database connection is only needed for EXPORT and BOTH, but a -274 * Hibernate-Dialect must always be chosen. -275 * -276 * @parameter property="hibernate.export.target" default-value="EXPORT" -277 * @since 1.0 -278 */ -279 private String target; -280 -281 /** -282 * Type of execution. -283 * <ul> -284 * <li><strong>NONE</strong> do nothing - just validate the configuration</li> -285 * <li><strong>CREATE</strong> create database-schema</li> -286 * <li><strong>DROP</strong> drop database-schema</li> -287 * <li><strong>BOTH</strong> (<strong>DEFAULT!</strong>)</li> -288 * </ul> -289 * -290 * If NONE is choosen, no databaseconnection is needed. -291 * -292 * @parameter property="hibernate.export.type" default-value="BOTH" -293 * @since 1.0 -294 */ -295 private String type; -296 -297 /** -298 * Output file. -299 * -300 * @parameter property="hibernate.export.schema.filename" default-value="${project.build.directory}/schema.sql" -301 * @since 1.0 -302 */ -303 private String outputFile; -304 -305 /** -306 * Delimiter in output-file. -307 * -308 * @parameter property="hibernate.export.schema.delimiter" default-value=";" -309 * @since 1.0 -310 */ -311 private String delimiter; -312 -313 /** -314 * Format output-file. -315 * -316 * @parameter property="hibernate.export.schema.format" default-value="true" -317 * @since 1.0 -318 */ -319 private boolean format; -320 -321 /** -322 * Generate envers schema for auditing tables. -323 * -324 * @parameter property="hibernate.export.envers" default-value="false" -325 * @since 1.0.3 -326 */ -327 private boolean envers; -328 -329 -330 @Override -331 public void execute() -332 throws -333 MojoFailureException, -334 MojoExecutionException -335 { -336 if (skip) -337 { -338 getLog().info("Execution of hibernate4-maven-plugin:export was skipped!"); -339 project.getProperties().setProperty(EXPORT_SKIPPED_PROPERTY, "true"); -340 return; -341 } -342 -343 Map<String,String> md5s; -344 boolean modified = false; -345 File saved = new File(buildDirectory + File.separator + MD5S); -346 -347 if (saved.isFile() && saved.length() > 0) -348 { -349 try -350 { -351 FileInputStream fis = new FileInputStream(saved); -352 ObjectInputStream ois = new ObjectInputStream(fis); -353 md5s = (HashMap<String,String>)ois.readObject(); -354 ois.close(); -355 } -356 catch (Exception e) -357 { -358 md5s = new HashMap<String,String>(); -359 getLog().warn("Cannot read timestamps from saved: " + e); -360 } -361 } -362 else -363 { -364 md5s = new HashMap<String,String>(); -365 try -366 { -367 saved.createNewFile(); -368 } -369 catch (IOException e) -370 { -371 getLog().debug("Cannot create file \"" + saved.getPath() + "\" for timestamps: " + e); -372 } -373 } -374 -375 ClassLoader classLoader = null; -376 try -377 { -378 getLog().debug("Creating ClassLoader for project-dependencies..."); -379 List<String> classpathFiles = project.getCompileClasspathElements(); -380 if (scanTestClasses) -381 classpathFiles.addAll(project.getTestClasspathElements()); -382 URL[] urls = new URL[classpathFiles.size()]; -383 for (int i = 0; i < classpathFiles.size(); ++i) -384 { -385 getLog().debug("Dependency: " + classpathFiles.get(i)); -386 urls[i] = new File(classpathFiles.get(i)).toURI().toURL(); -387 } -388 classLoader = new URLClassLoader(urls, getClass().getClassLoader()); -389 } -390 catch (Exception e) -391 { -392 getLog().error("Error while creating ClassLoader!", e); -393 throw new MojoExecutionException(e.getMessage()); -394 } -395 -396 Set<Class<?>> classes = -397 new TreeSet<Class<?>>( -398 new Comparator<Class<?>>() { -399 @Override -400 public int compare(Class<?> a, Class<?> b) -401 { -402 return a.getName().compareTo(b.getName()); -403 } -404 } -405 ); -406 -407 try -408 { -409 AnnotationDB db = new AnnotationDB(); -410 File dir = new File(outputDirectory); -411 if (dir.exists()) -412 { -413 getLog().info("Scanning directory " + outputDirectory + " for annotated classes..."); -414 URL dirUrl = dir.toURI().toURL(); -415 db.scanArchives(dirUrl); -416 } -417 if (scanTestClasses) -418 { -419 dir = new File(testOutputDirectory); -420 if (dir.exists()) -421 { -422 getLog().info("Scanning directory " + testOutputDirectory + " for annotated classes..."); -423 URL dirUrl = dir.toURI().toURL(); -424 db.scanArchives(dirUrl); -425 } -426 } -427 if (scanDependencies != null) -428 { -429 Matcher matcher = split.matcher(scanDependencies); -430 while (matcher.find()) -431 { -432 getLog().info("Scanning dependencies for scope " + matcher.group()); -433 for (Artifact artifact : project.getDependencyArtifacts()) -434 { -435 if (!artifact.getScope().equalsIgnoreCase(matcher.group())) -436 continue; -437 if (artifact.getFile() == null) -438 { -439 getLog().warn( -440 "Cannot scan dependency " + -441 artifact.getId() + -442 ": no JAR-file available!" -443 ); -444 continue; -445 } -446 getLog().info( -447 "Scanning dependency " + -448 artifact.getId() + -449 " for annotated classes..." -450 ); -451 db.scanArchives(artifact.getFile().toURI().toURL()); -452 } -453 } -454 } -455 -456 Set<String> classNames = new HashSet<String>(); -457 if (db.getAnnotationIndex().containsKey(Entity.class.getName())) -458 classNames.addAll(db.getAnnotationIndex().get(Entity.class.getName())); -459 if (db.getAnnotationIndex().containsKey(MappedSuperclass.class.getName())) -460 classNames.addAll(db.getAnnotationIndex().get(MappedSuperclass.class.getName())); -461 if (db.getAnnotationIndex().containsKey(Embeddable.class.getName())) -462 classNames.addAll(db.getAnnotationIndex().get(Embeddable.class.getName())); -463 -464 MessageDigest digest = java.security.MessageDigest.getInstance("MD5"); -465 for (String name : classNames) -466 { -467 Class<?> annotatedClass = classLoader.loadClass(name); -468 classes.add(annotatedClass); -469 String resourceName = annotatedClass.getName(); -470 resourceName = resourceName.substring(resourceName.lastIndexOf(".") + 1, resourceName.length()) + ".class"; -471 InputStream is = -472 annotatedClass -473 .getResourceAsStream(resourceName); -474 byte[] buffer = new byte[1024*4]; // copy data in 4MB-chunks -475 int i; -476 while((i = is.read(buffer)) > -1) -477 digest.update(buffer, 0, i); -478 is.close(); -479 byte[] bytes = digest.digest(); -480 BigInteger bi = new BigInteger(1, bytes); -481 String newMd5 = String.format("%0" + (bytes.length << 1) + "x", bi); -482 String oldMd5 = !md5s.containsKey(name) ? "" : md5s.get(name); -483 if (!newMd5.equals(oldMd5)) -484 { -485 getLog().debug("Found new or modified annotated class: " + name); -486 modified = true; -487 md5s.put(name, newMd5); -488 } -489 else -490 { -491 getLog().debug(oldMd5 + " -> class unchanged: " + name); -492 } -493 } -494 } -495 catch (ClassNotFoundException e) -496 { -497 getLog().error("Error while adding annotated classes!", e); -498 throw new MojoExecutionException(e.getMessage()); -499 } -500 catch (Exception e) -501 { -502 getLog().error("Error while scanning!", e); -503 throw new MojoFailureException(e.getMessage()); -504 } -505 -506 if (classes.isEmpty()) -507 { -508 if (hibernateMapping == null || hibernateMapping.isEmpty()) -509 throw new MojoFailureException("No annotated classes found in directory " + outputDirectory); -510 } -511 else -512 { -513 getLog().debug("Detected classes with mapping-annotations:"); -514 for (Class<?> annotatedClass : classes) -515 getLog().debug(" " + annotatedClass.getName()); -516 } -517 -518 -519 Properties properties = new Properties(); -520 -521 /** Try to read configuration from properties-file */ -522 try -523 { -524 File file = new File(hibernateProperties); -525 if (file.exists()) -526 { -527 getLog().info("Reading properties from file " + hibernateProperties + "..."); -528 properties.load(new FileInputStream(file)); -529 } -530 else -531 getLog().info("No hibernate-properties-file found! (Checked path: " + hibernateProperties + ")"); -532 } -533 catch (IOException e) -534 { -535 getLog().error("Error while reading properties!", e); -536 throw new MojoExecutionException(e.getMessage()); -537 } -538 -539 /** Overwrite values from properties-file or set, if given */ -540 if (driverClassName != null) -541 { -542 if (properties.containsKey(DRIVER_CLASS)) -543 getLog().debug( -544 "Overwriting property " + -545 DRIVER_CLASS + "=" + properties.getProperty(DRIVER_CLASS) + -546 " with the value " + driverClassName -547 ); -548 else -549 getLog().debug("Using the value " + driverClassName); -550 properties.setProperty(DRIVER_CLASS, driverClassName); -551 } -552 if (url != null) -553 { -554 if (properties.containsKey(URL)) -555 getLog().debug( -556 "Overwriting property " + -557 URL + "=" + properties.getProperty(URL) + -558 " with the value " + url -559 ); -560 else -561 getLog().debug("Using the value " + url); -562 properties.setProperty(URL, url); -563 } -564 if (username != null) -565 { -566 if (properties.containsKey(USERNAME)) -567 getLog().debug( -568 "Overwriting property " + -569 USERNAME + "=" + properties.getProperty(USERNAME) + -570 " with the value " + username -571 ); -572 else -573 getLog().debug("Using the value " + username); -574 properties.setProperty(USERNAME, username); -575 } -576 if (password != null) -577 { -578 if (properties.containsKey(PASSWORD)) -579 getLog().debug( -580 "Overwriting property " + -581 PASSWORD + "=" + properties.getProperty(PASSWORD) + -582 " with value " + password -583 ); -584 else -585 getLog().debug("Using value " + password + " for property " + PASSWORD); -586 properties.setProperty(PASSWORD, password); -587 } -588 if (hibernateDialect != null) -589 { -590 if (properties.containsKey(DIALECT)) -591 getLog().debug( -592 "Overwriting property " + -593 DIALECT + "=" + properties.getProperty(DIALECT) + -594 " with value " + hibernateDialect -595 ); -596 else -597 getLog().debug( -598 "Using value " + hibernateDialect + " for property " + DIALECT -599 ); -600 properties.setProperty(DIALECT, hibernateDialect); -601 } -602 if ( hibernateNamingStrategy != null ) -603 { -604 if ( properties.contains(NAMING_STRATEGY)) -605 getLog().debug( -606 "Overwriting property " + -607 NAMING_STRATEGY + "=" + properties.getProperty(NAMING_STRATEGY) + -608 " with value " + hibernateNamingStrategy -609 ); -610 else -611 getLog().debug( -612 "Using value " + hibernateNamingStrategy + " for property " + -613 NAMING_STRATEGY -614 ); -615 properties.setProperty(NAMING_STRATEGY, hibernateNamingStrategy); -616 } -617 -618 /** The generated SQL varies with the dialect! */ -619 if (md5s.containsKey(DIALECT)) -620 { -621 String dialect = properties.getProperty(DIALECT); -622 if (md5s.get(DIALECT).equals(dialect)) -623 getLog().debug("SQL-dialect unchanged."); -624 else -625 { -626 modified = true; -627 if (dialect == null) -628 { -629 getLog().debug("SQL-dialect was unset."); -630 md5s.remove(DIALECT); -631 } -632 else -633 { -634 getLog().debug("SQL-dialect changed: " + dialect); -635 md5s.put(DIALECT, dialect); -636 } -637 } -638 } -639 else -640 { -641 String dialect = properties.getProperty(DIALECT); -642 if (dialect != null) -643 { -644 modified = true; -645 md5s.put(DIALECT, properties.getProperty(DIALECT)); -646 } -647 } -648 -649 /** The generated SQL varies with the envers-configuration */ -650 if (md5s.get(ENVERS) != null) -651 { -652 if (md5s.get(ENVERS).equals(Boolean.toString(envers))) -653 getLog().debug("Envers-Configuration unchanged. Enabled: " + envers); -654 else -655 { -656 getLog().debug("Envers-Configuration changed. Enabled: " + envers); -657 modified = true; -658 md5s.put(ENVERS, Boolean.toString(envers)); -659 } -660 } -661 else -662 { -663 modified = true; -664 md5s.put(ENVERS, Boolean.toString(envers)); -665 } -666 -667 if (properties.isEmpty()) -668 { -669 getLog().error("No properties set!"); -670 throw new MojoFailureException("Hibernate configuration is missing!"); -671 } -672 -673 final Configuration config = new ValidationConfiguration(hibernateDialect); -674 -675 config.setProperties(properties); -676 -677 if ( properties.containsKey(NAMING_STRATEGY)) -678 { -679 String namingStrategy = properties.getProperty(NAMING_STRATEGY); -680 getLog().debug("Explicitly set NamingStrategy: " + namingStrategy); -681 try -682 { -683 @SuppressWarnings("unchecked") -684 Class<NamingStrategy> namingStrategyClass = (Class<NamingStrategy>) Class.forName(namingStrategy); -685 config.setNamingStrategy(namingStrategyClass.newInstance()); -686 } -687 catch (Exception e) -688 { -689 getLog().error("Error setting NamingStrategy", e); -690 throw new MojoExecutionException(e.getMessage()); -691 } -692 } -693 -694 getLog().debug("Adding annotated classes to hibernate-mapping-configuration..."); -695 for (Class<?> annotatedClass : classes) -696 { -697 getLog().debug("Class " + annotatedClass); -698 config.addAnnotatedClass(annotatedClass); -699 } -700 -701 if (hibernateMapping != null) -702 { -703 try -704 { -705 MessageDigest digest = java.security.MessageDigest.getInstance("MD5"); -706 for (String filename : hibernateMapping.split("[\\s,]+")) -707 { -708 // First try the filename as absolute/relative path -709 File file = new File(filename); -710 if (!file.exists()) -711 { -712 // If the file was not found, search for it in the resource-directories -713 for (Resource resource : project.getResources()) -714 { -715 file = new File(resource.getDirectory() + File.separator + filename); -716 if (file.exists()) -717 break; -718 } -719 } -720 if (file != null && file.exists()) -721 { -722 InputStream is = new FileInputStream(file); -723 byte[] buffer = new byte[1024*4]; // copy data in 4MB-chunks -724 int i; -725 while((i = is.read(buffer)) > -1) -726 digest.update(buffer, 0, i); -727 is.close(); -728 byte[] bytes = digest.digest(); -729 BigInteger bi = new BigInteger(1, bytes); -730 String newMd5 = String.format("%0" + (bytes.length << 1) + "x", bi); -731 String oldMd5 = !md5s.containsKey(filename) ? "" : md5s.get(filename); -732 if (!newMd5.equals(oldMd5)) -733 { -734 getLog().debug("Found new or modified mapping-file: " + filename); -735 modified = true; -736 md5s.put(filename, newMd5); -737 } -738 else -739 { -740 getLog().debug(oldMd5 + " -> mapping-file unchanged: " + filename); -741 } -742 getLog().debug("Adding mappings from XML-configurationfile: " + file); -743 config.addFile(file); -744 } -745 else -746 throw new MojoFailureException("File " + filename + " could not be found in any of the configured resource-directories!"); -747 } -748 } -749 catch (NoSuchAlgorithmException e) -750 { -751 throw new MojoFailureException("Cannot calculate MD5 sums!", e); -752 } -753 catch (FileNotFoundException e) -754 { -755 throw new MojoFailureException("Cannot calculate MD5 sums!", e); -756 } -757 catch (IOException e) -758 { -759 throw new MojoFailureException("Cannot calculate MD5 sums!", e); -760 } -761 } -762 -763 Target target = null; -764 try -765 { -766 target = Target.valueOf(this.target.toUpperCase()); -767 } -768 catch (IllegalArgumentException e) -769 { -770 getLog().error("Invalid value for configuration-option \"target\": " + this.target); -771 getLog().error("Valid values are: NONE, SCRIPT, EXPORT, BOTH"); -772 throw new MojoExecutionException("Invalid value for configuration-option \"target\""); -773 } -774 Type type = null; -775 try -776 { -777 type = Type.valueOf(this.type.toUpperCase()); -778 } -779 catch (IllegalArgumentException e) -780 { -781 getLog().error("Invalid value for configuration-option \"type\": " + this.type); -782 getLog().error("Valid values are: NONE, CREATE, DROP, BOTH"); -783 throw new MojoExecutionException("Invalid value for configuration-option \"type\""); -784 } -785 -786 if (target.equals(Target.SCRIPT) || target.equals(Target.NONE)) -787 { -788 project.getProperties().setProperty(EXPORT_SKIPPED_PROPERTY, "true"); -789 } -790 if ( -791 !modified -792 && !target.equals(Target.SCRIPT) -793 && !target.equals(Target.NONE) -794 && !force -795 ) -796 { -797 getLog().info("No modified annotated classes or mapping-files found and dialect unchanged."); -798 getLog().info("Skipping schema generation!"); -799 project.getProperties().setProperty(EXPORT_SKIPPED_PROPERTY, "true"); -800 return; -801 } -802 -803 getLog().info("Gathered hibernate-configuration (turn on debugging for details):"); -804 for (Entry<Object,Object> entry : properties.entrySet()) -805 getLog().info(" " + entry.getKey() + " = " + entry.getValue()); -806 -807 Connection connection = null; -808 try -809 { -810 /** -811 * The connection must be established outside of hibernate, because -812 * hibernate does not use the context-classloader of the current -813 * thread and, hence, would not be able to resolve the driver-class! -814 */ -815 getLog().debug("Target: " + target + ", Type: " + type); -816 switch (target) -817 { -818 case EXPORT: -819 case BOTH: -820 switch (type) -821 { -822 case CREATE: -823 case DROP: -824 case BOTH: -825 Class driverClass = classLoader.loadClass(properties.getProperty(DRIVER_CLASS)); -826 getLog().debug("Registering JDBC-driver " + driverClass.getName()); -827 DriverManager.registerDriver(new DriverProxy((Driver)driverClass.newInstance())); -828 getLog().debug( -829 "Opening JDBC-connection to " -830 + properties.getProperty(URL) -831 + " as " -832 + properties.getProperty(USERNAME) -833 + " with password " -834 + properties.getProperty(PASSWORD) -835 ); -836 connection = DriverManager.getConnection( -837 properties.getProperty(URL), -838 properties.getProperty(USERNAME), -839 properties.getProperty(PASSWORD) -840 ); -841 } -842 } -843 } -844 catch (ClassNotFoundException e) -845 { -846 getLog().error("Dependency for driver-class " + properties.getProperty(DRIVER_CLASS) + " is missing!"); -847 throw new MojoExecutionException(e.getMessage()); -848 } -849 catch (Exception e) -850 { -851 getLog().error("Cannot establish connection to database!"); -852 Enumeration<Driver> drivers = DriverManager.getDrivers(); -853 if (!drivers.hasMoreElements()) -854 getLog().error("No drivers registered!"); -855 while (drivers.hasMoreElements()) -856 getLog().debug("Driver: " + drivers.nextElement()); -857 throw new MojoExecutionException(e.getMessage()); -858 } -859 -860 ClassLoader contextClassLoader = Thread.currentThread().getContextClassLoader(); -861 MavenLogAppender.startPluginLog(this); -862 try -863 { -864 /** -865 * Change class-loader of current thread, so that hibernate can -866 * see all dependencies! -867 */ -868 Thread.currentThread().setContextClassLoader(classLoader); -869 -870 config.buildMappings(); -871 -872 if (envers) -873 { -874 getLog().info("Automatic auditing via hibernate-envers enabled!"); -875 AuditConfiguration.getFor(config); -876 } -877 -878 SchemaExport export = new SchemaExport(config, connection); -879 export.setDelimiter(delimiter); -880 export.setFormat(format); -881 -882 File outF = new File(outputFile); -883 -884 if (!outF.isAbsolute()) -885 { -886 // Interpret relative file path relative to build directory -887 outF = new File(buildDirectory, outputFile); -888 getLog().info("Adjusted relative path, resulting path is " + outF.getPath()); -889 } -890 -891 // Ensure that directory path for specified file exists -892 File outFileParentDir = outF.getParentFile(); -893 if (null != outFileParentDir && !outFileParentDir.exists()) -894 { -895 try -896 { -897 getLog().info("Creating directory path for output file:" + outFileParentDir.getPath()); -898 outFileParentDir.mkdirs(); -899 } -900 catch (Exception e) -901 { -902 getLog().error("Error creating directory path for output file: " + e.getLocalizedMessage()); -903 } -904 } -905 -906 export.setOutputFile(outF.getPath()); -907 export.execute(target, type); -908 -909 for (Object exception : export.getExceptions()) -910 getLog().debug(exception.toString()); -911 } -912 finally -913 { -914 /** Stop Log-Capturing */ -915 MavenLogAppender.endPluginLog(this); -916 -917 /** Restore the old class-loader (TODO: is this really necessary?) */ -918 Thread.currentThread().setContextClassLoader(contextClassLoader); -919 -920 /** Close the connection */ -921 try -922 { -923 if (connection != null) -924 connection.close(); -925 } -926 catch (SQLException e) -927 { -928 getLog().error("Error while closing connection: " + e.getMessage()); -929 } -930 } -931 -932 /** Write md5-sums for annotated classes to file */ -933 try -934 { -935 FileOutputStream fos = new FileOutputStream(saved); -936 ObjectOutputStream oos = new ObjectOutputStream(fos); -937 oos.writeObject(md5s); -938 oos.close(); -939 fos.close(); -940 } -941 catch (Exception e) -942 { -943 getLog().error("Cannot write md5-sums to file: " + e); -944 } -945 } -946 -947 /** -948 * Needed, because DriverManager won't pick up drivers, that were not -949 * loaded by the system-classloader! -950 * See: -951 * http://stackoverflow.com/questions/288828/how-to-use-a-jdbc-driver-fromodifiedm-an-arbitrary-location -952 */ -953 static final class DriverProxy implements Driver -954 { -955 private final Driver target; -956 -957 DriverProxy(Driver target) -958 { -959 if (target == null) -960 throw new NullPointerException(); -961 this.target = target; -962 } -963 -964 public java.sql.Driver getTarget() -965 { -966 return target; -967 } -968 -969 @Override -970 public boolean acceptsURL(String url) throws SQLException -971 { -972 return target.acceptsURL(url); -973 } -974 -975 @Override -976 public java.sql.Connection connect( -977 String url, -978 java.util.Properties info -979 ) -980 throws -981 SQLException -982 { -983 return target.connect(url, info); -984 } -985 -986 @Override -987 public int getMajorVersion() -988 { -989 return target.getMajorVersion(); -990 } -991 -992 @Override -993 public int getMinorVersion() -994 { -995 return target.getMinorVersion(); -996 } -997 -998 @Override -999 public DriverPropertyInfo[] getPropertyInfo( -1000 String url, -1001 Properties info -1002 ) -1003 throws -1004 SQLException -1005 { -1006 return target.getPropertyInfo(url, info); -1007 } -1008 -1009 @Override -1010 public boolean jdbcCompliant() -1011 { -1012 return target.jdbcCompliant(); -1013 } -1014 -1015 /** -1016 * This Method cannot be annotated with @Override, becaus the plugin -1017 * will not compile then under Java 1.6! -1018 */ -1019 public Logger getParentLogger() throws SQLFeatureNotSupportedException -1020 { -1021 throw new SQLFeatureNotSupportedException("Not supported, for backward-compatibility with Java 1.6"); -1022 } -1023 -1024 @Override -1025 public String toString() -1026 { -1027 return "Proxy: " + target; -1028 } -1029 -1030 @Override -1031 public int hashCode() -1032 { -1033 return target.hashCode(); -1034 } -1035 -1036 @Override -1037 public boolean equals(Object obj) -1038 { -1039 if (!(obj instanceof DriverProxy)) -1040 return false; -1041 DriverProxy other = (DriverProxy) obj; -1042 return this.target.equals(other.target); -1043 } -1044 } -1045 } --
- -1 package de.juplo.plugins.hibernate4; -2 -3 import org.apache.maven.plugin.AbstractMojo; -4 import org.apache.maven.plugin.MojoExecutionException; -5 -6 import org.w3c.dom.Document; -7 import org.w3c.dom.Element; -8 import org.w3c.dom.Node; -9 import org.w3c.dom.NodeList; -10 import org.xml.sax.SAXException; -11 -12 import javax.xml.parsers.DocumentBuilder; -13 import javax.xml.parsers.DocumentBuilderFactory; -14 import javax.xml.parsers.ParserConfigurationException; -15 import java.io.IOException; -16 import java.io.InputStream; -17 import java.util.ArrayList; -18 import java.util.Iterator; -19 import java.util.List; -20 -21 /** -22 * Display help information on hibernate4-maven-plugin.<br/> -23 * Call <code>mvn hibernate4:help -Ddetail=true -Dgoal=<goal-name></code> to display parameter details. -24 * @author -25 * @version -26 * @goal help -27 * @requiresProject false -28 * @threadSafe -29 */ -30 public class HelpMojo -31 extends AbstractMojo -32 { -33 /** -34 * If <code>true</code>, display all settable properties for each goal. -35 * -36 * @parameter property="detail" default-value="false" -37 */ -38 private boolean detail; -39 -40 /** -41 * The name of the goal for which to show help. If unspecified, all goals will be displayed. -42 * -43 * @parameter property="goal" -44 */ -45 private java.lang.String goal; -46 -47 /** -48 * The maximum length of a display line, should be positive. -49 * -50 * @parameter property="lineLength" default-value="80" -51 */ -52 private int lineLength; -53 -54 /** -55 * The number of spaces per indentation level, should be positive. -56 * -57 * @parameter property="indentSize" default-value="2" -58 */ -59 private int indentSize; -60 -61 // groupId/artifactId/plugin-help.xml -62 private static final String PLUGIN_HELP_PATH = "/META-INF/maven/de.juplo/hibernate4-maven-plugin/plugin-help.xml"; -63 -64 private Document build() -65 throws MojoExecutionException -66 { -67 getLog().debug( "load plugin-help.xml: " + PLUGIN_HELP_PATH ); -68 InputStream is = getClass().getResourceAsStream( PLUGIN_HELP_PATH ); -69 try -70 { -71 DocumentBuilderFactory dbFactory = DocumentBuilderFactory.newInstance(); -72 DocumentBuilder dBuilder = dbFactory.newDocumentBuilder(); -73 return dBuilder.parse( is ); -74 } -75 catch ( IOException e ) -76 { -77 throw new MojoExecutionException( e.getMessage(), e ); -78 } -79 catch ( ParserConfigurationException e ) -80 { -81 throw new MojoExecutionException( e.getMessage(), e ); -82 } -83 catch ( SAXException e ) -84 { -85 throw new MojoExecutionException( e.getMessage(), e ); -86 } -87 } -88 -89 /** -90 * {@inheritDoc} -91 */ -92 public void execute() -93 throws MojoExecutionException -94 { -95 if ( lineLength <= 0 ) -96 { -97 getLog().warn( "The parameter 'lineLength' should be positive, using '80' as default." ); -98 lineLength = 80; -99 } -100 if ( indentSize <= 0 ) -101 { -102 getLog().warn( "The parameter 'indentSize' should be positive, using '2' as default." ); -103 indentSize = 2; -104 } -105 -106 Document doc = build(); -107 -108 StringBuilder sb = new StringBuilder(); -109 Node plugin = getSingleChild( doc, "plugin" ); -110 -111 -112 String name = getValue( plugin, "name" ); -113 String version = getValue( plugin, "version" ); -114 String id = getValue( plugin, "groupId" ) + ":" + getValue( plugin, "artifactId" ) + ":" + version; -115 if ( isNotEmpty( name ) && !name.contains( id ) ) -116 { -117 append( sb, name + " " + version, 0 ); -118 } -119 else -120 { -121 if ( isNotEmpty( name ) ) -122 { -123 append( sb, name, 0 ); -124 } -125 else -126 { -127 append( sb, id, 0 ); -128 } -129 } -130 append( sb, getValue( plugin, "description" ), 1 ); -131 append( sb, "", 0 ); -132 -133 //<goalPrefix>plugin</goalPrefix> -134 String goalPrefix = getValue( plugin, "goalPrefix" ); -135 -136 Node mojos1 = getSingleChild( plugin, "mojos" ); -137 -138 List<Node> mojos = findNamedChild( mojos1, "mojo" ); -139 -140 if ( goal == null || goal.length() <= 0 ) -141 { -142 append( sb, "This plugin has " + mojos.size() + ( mojos.size() > 1 ? " goals:" : " goal:" ), 0 ); -143 append( sb, "", 0 ); -144 } -145 -146 for ( Node mojo : mojos ) -147 { -148 writeGoal( sb, goalPrefix, (Element) mojo ); -149 } -150 -151 if ( getLog().isInfoEnabled() ) -152 { -153 getLog().info( sb.toString() ); -154 } -155 } -156 -157 -158 private static boolean isNotEmpty( String string ) -159 { -160 return string != null && string.length() > 0; -161 } -162 -163 private String getValue( Node node, String elementName ) -164 throws MojoExecutionException -165 { -166 return getSingleChild( node, elementName ).getTextContent(); -167 } -168 -169 private Node getSingleChild( Node node, String elementName ) -170 throws MojoExecutionException -171 { -172 List<Node> namedChild = findNamedChild( node, elementName ); -173 if ( namedChild.isEmpty() ) -174 { -175 throw new MojoExecutionException( "Could not find " + elementName + " in plugin-help.xml" ); -176 } -177 if ( namedChild.size() > 1 ) -178 { -179 throw new MojoExecutionException( "Multiple " + elementName + " in plugin-help.xml" ); -180 } -181 return namedChild.get( 0 ); -182 } -183 -184 private List<Node> findNamedChild( Node node, String elementName ) -185 { -186 List<Node> result = new ArrayList<Node>(); -187 NodeList childNodes = node.getChildNodes(); -188 for ( int i = 0; i < childNodes.getLength(); i++ ) -189 { -190 Node item = childNodes.item( i ); -191 if ( elementName.equals( item.getNodeName() ) ) -192 { -193 result.add( item ); -194 } -195 } -196 return result; -197 } -198 -199 private Node findSingleChild( Node node, String elementName ) -200 throws MojoExecutionException -201 { -202 List<Node> elementsByTagName = findNamedChild( node, elementName ); -203 if ( elementsByTagName.isEmpty() ) -204 { -205 return null; -206 } -207 if ( elementsByTagName.size() > 1 ) -208 { -209 throw new MojoExecutionException( "Multiple " + elementName + "in plugin-help.xml" ); -210 } -211 return elementsByTagName.get( 0 ); -212 } -213 -214 private void writeGoal( StringBuilder sb, String goalPrefix, Element mojo ) -215 throws MojoExecutionException -216 { -217 String mojoGoal = getValue( mojo, "goal" ); -218 Node configurationElement = findSingleChild( mojo, "configuration" ); -219 Node description = findSingleChild( mojo, "description" ); -220 if ( goal == null || goal.length() <= 0 || mojoGoal.equals( goal ) ) -221 { -222 append( sb, goalPrefix + ":" + mojoGoal, 0 ); -223 Node deprecated = findSingleChild( mojo, "deprecated" ); -224 if ( ( deprecated != null ) && isNotEmpty( deprecated.getNodeValue() ) ) -225 { -226 append( sb, "Deprecated. " + deprecated, 1 ); -227 if ( detail && description != null ) -228 { -229 append( sb, "", 0 ); -230 append( sb, description.getTextContent(), 1 ); -231 } -232 } -233 else if (description != null ) -234 { -235 append( sb, description.getTextContent(), 1 ); -236 } -237 append( sb, "", 0 ); -238 -239 if ( detail ) -240 { -241 Node parametersNode = getSingleChild( mojo, "parameters" ); -242 List<Node> parameters = findNamedChild( parametersNode, "parameter" ); -243 append( sb, "Available parameters:", 1 ); -244 append( sb, "", 0 ); -245 -246 for ( Node parameter : parameters ) -247 { -248 writeParameter( sb, parameter, configurationElement ); -249 } -250 } -251 } -252 } -253 -254 private void writeParameter( StringBuilder sb, Node parameter, Node configurationElement ) -255 throws MojoExecutionException -256 { -257 String parameterName = getValue( parameter, "name" ); -258 String parameterDescription = getValue( parameter, "description" ); -259 -260 Node fieldConfigurationElement = findSingleChild( configurationElement, parameterName ); -261 -262 String parameterDefaultValue = ""; -263 if ( fieldConfigurationElement != null && fieldConfigurationElement.getNodeValue() != null ) -264 { -265 parameterDefaultValue = " (Default: " + ((Element)fieldConfigurationElement).getAttribute( "default-value" ) + ")"; -266 } -267 append( sb, parameterName + parameterDefaultValue, 2 ); -268 Node deprecated = findSingleChild( parameter, "deprecated" ); -269 if ( ( deprecated != null ) && isNotEmpty( deprecated.getNodeValue() ) ) -270 { -271 append( sb, "Deprecated. " + deprecated.getNodeValue(), 3 ); -272 append( sb, "", 0 ); -273 } -274 append( sb, parameterDescription, 3 ); -275 if ( "true".equals( getValue( parameter, "required" ) ) ) -276 { -277 append( sb, "Required: Yes", 3 ); -278 } -279 Node expression = findSingleChild( parameter, "expression" ); -280 if ( ( expression != null ) && isNotEmpty( expression.getNodeValue() ) ) -281 { -282 String property = getPropertyFromExpression( expression.getNodeValue() ); -283 append( sb, "User property: " + property, 3 ); -284 } -285 -286 append( sb, "", 0 ); -287 } -288 -289 /** -290 * <p>Repeat a String <code>n</code> times to form a new string.</p> -291 * -292 * @param str String to repeat -293 * @param repeat number of times to repeat str -294 * @return String with repeated String -295 * @throws NegativeArraySizeException if <code>repeat < 0</code> -296 * @throws NullPointerException if str is <code>null</code> -297 */ -298 private static String repeat( String str, int repeat ) -299 { -300 StringBuilder buffer = new StringBuilder( repeat * str.length() ); -301 -302 for ( int i = 0; i < repeat; i++ ) -303 { -304 buffer.append( str ); -305 } -306 -307 return buffer.toString(); -308 } -309 -310 /** -311 * Append a description to the buffer by respecting the indentSize and lineLength parameters. -312 * <b>Note</b>: The last character is always a new line. -313 * -314 * @param sb The buffer to append the description, not <code>null</code>. -315 * @param description The description, not <code>null</code>. -316 * @param indent The base indentation level of each line, must not be negative. -317 */ -318 private void append( StringBuilder sb, String description, int indent ) -319 { -320 for ( String line : toLines( description, indent, indentSize, lineLength ) ) -321 { -322 sb.append( line ).append( '\n' ); -323 } -324 } -325 -326 /** -327 * Splits the specified text into lines of convenient display length. -328 * -329 * @param text The text to split into lines, must not be <code>null</code>. -330 * @param indent The base indentation level of each line, must not be negative. -331 * @param indentSize The size of each indentation, must not be negative. -332 * @param lineLength The length of the line, must not be negative. -333 * @return The sequence of display lines, never <code>null</code>. -334 * @throws NegativeArraySizeException if <code>indent < 0</code> -335 */ -336 private static List<String> toLines( String text, int indent, int indentSize, int lineLength ) -337 { -338 List<String> lines = new ArrayList<String>(); -339 -340 String ind = repeat( "\t", indent ); -341 -342 String[] plainLines = text.split( "(\r\n)|(\r)|(\n)" ); -343 -344 for ( String plainLine : plainLines ) -345 { -346 toLines( lines, ind + plainLine, indentSize, lineLength ); -347 } -348 -349 return lines; -350 } -351 -352 /** -353 * Adds the specified line to the output sequence, performing line wrapping if necessary. -354 * -355 * @param lines The sequence of display lines, must not be <code>null</code>. -356 * @param line The line to add, must not be <code>null</code>. -357 * @param indentSize The size of each indentation, must not be negative. -358 * @param lineLength The length of the line, must not be negative. -359 */ -360 private static void toLines( List<String> lines, String line, int indentSize, int lineLength ) -361 { -362 int lineIndent = getIndentLevel( line ); -363 StringBuilder buf = new StringBuilder( 256 ); -364 -365 String[] tokens = line.split( " +" ); -366 -367 for ( String token : tokens ) -368 { -369 if ( buf.length() > 0 ) -370 { -371 if ( buf.length() + token.length() >= lineLength ) -372 { -373 lines.add( buf.toString() ); -374 buf.setLength( 0 ); -375 buf.append( repeat( " ", lineIndent * indentSize ) ); -376 } -377 else -378 { -379 buf.append( ' ' ); -380 } -381 } -382 -383 for ( int j = 0; j < token.length(); j++ ) -384 { -385 char c = token.charAt( j ); -386 if ( c == '\t' ) -387 { -388 buf.append( repeat( " ", indentSize - buf.length() % indentSize ) ); -389 } -390 else if ( c == '\u00A0' ) -391 { -392 buf.append( ' ' ); -393 } -394 else -395 { -396 buf.append( c ); -397 } -398 } -399 } -400 lines.add( buf.toString() ); -401 } -402 -403 /** -404 * Gets the indentation level of the specified line. -405 * -406 * @param line The line whose indentation level should be retrieved, must not be <code>null</code>. -407 * @return The indentation level of the line. -408 */ -409 private static int getIndentLevel( String line ) -410 { -411 int level = 0; -412 for ( int i = 0; i < line.length() && line.charAt( i ) == '\t'; i++ ) -413 { -414 level++; -415 } -416 for ( int i = level + 1; i <= level + 4 && i < line.length(); i++ ) -417 { -418 if ( line.charAt( i ) == '\t' ) -419 { -420 level++; -421 break; -422 } -423 } -424 return level; -425 } -426 -427 private String getPropertyFromExpression( String expression ) -428 { -429 if ( expression != null && expression.startsWith( "${" ) && expression.endsWith( "}" ) -430 && !expression.substring( 2 ).contains( "${" ) ) -431 { -432 // expression="${xxx}" -> property="xxx" -433 return expression.substring( 2, expression.length() - 1 ); -434 } -435 // no property can be extracted -436 return null; -437 } -438 } --
- -1 package de.juplo.plugins.hibernate4; -2 -3 import javax.validation.Validation; -4 -5 import org.hibernate.cfg.Configuration; -6 import org.hibernate.cfg.beanvalidation.TypeSafeActivatorAccessor; -7 import org.hibernate.dialect.Dialect; -8 import org.hibernate.metamodel.source.MappingException; -9 -10 -11 /** -12 * This integration is usually performed by BeanValidationIntegrator. -13 * Unfortunately, that integration will only be activated upon -14 * initialization of the ServiceRegistry, which initializes -15 * DatasourceConnectionProviderImpl, which looks up the datasource, -16 * which requires a JNDI context ... -17 * We therefore reimplement the relevant parts of BeanValidatorIntegrator. -18 * Since that must occur after secondPassCompile(), which is invoked by -19 * Configuration.generateSchemaCreationScript, which is invoked by -20 * SchemaExport, some fancy subclassing is needed to invoke the integration -21 * at the right time. -22 * @author Mark Robinson <mark@mrobinson.ca> -23 * @author Frank Schimmel <frank.schimmel@cm4all.com> -24 */ -25 public class ValidationConfiguration extends Configuration -26 { -27 private static final long serialVersionUID = 1L; -28 -29 private Class<Dialect> dialectClass; -30 -31 public ValidationConfiguration(final String dialectClass) -32 { -33 try { -34 this.dialectClass = (Class<Dialect>) Class.forName(dialectClass); -35 } catch (ClassNotFoundException e) { -36 throw new RuntimeException(e); -37 } -38 } -39 -40 @Override -41 protected void secondPassCompile() throws MappingException -42 { -43 super.secondPassCompile(); -44 -45 try -46 { -47 TypeSafeActivatorAccessor.applyRelationalConstraints( -48 Validation.buildDefaultValidatorFactory(), -49 classes.values(), -50 getProperties(), -51 dialectClass.newInstance() -52 ); -53 } -54 catch (Exception e) -55 { -56 throw new RuntimeException(e); -57 } -58 } -59 } --
Class Summary | -
---|
- DriverProxy - | -
- Hbm2DdlMojo - | -
- HelpMojo - | -
- ValidationConfiguration - | -
- You don't have frames. Go here -
- -- -1 package org.hibernate.cfg.beanvalidation; -2 -3 /** -4 * This class enables access to the public methods of {@link TypeSafeActivator} -5 * which itself is visible in the package only. -6 * -7 * @author Frank Schimmel <frank.schimmel@cm4all.com> -8 */ -9 public class TypeSafeActivatorAccessor extends TypeSafeActivator { -10 // Empty: just makes public methods accessible. -11 } --
Class Summary | -
---|
- TypeSafeActivatorAccessor - | -
Packages | -
---|
- de.juplo.plugins.hibernate4 - | -
- org.hibernate.cfg.beanvalidation - | -
Modifier and Type | -Constant Field | -Value | -
---|---|---|
-
-public static final java.lang.String |
-DIALECT |
-"hibernate.dialect" |
-
-
-public static final java.lang.String |
-DRIVER_CLASS |
-"hibernate.connection.driver_class" |
-
-
-public static final java.lang.String |
-ENVERS |
-"hibernate.export.envers" |
-
-
-public static final java.lang.String |
-EXPORT_SKIPPED_PROPERTY |
-"hibernate.export.skipped" |
-
-
-public static final java.lang.String |
-MD5S |
-"hibernate4-generatedschema.md5s" |
-
-
-public static final java.lang.String |
-NAMING_STRATEGY |
-"hibernate.ejb.naming_strategy" |
-
-
-public static final java.lang.String |
-PASSWORD |
-"hibernate.connection.password" |
-
-
-public static final java.lang.String |
-URL |
-"hibernate.connection.url" |
-
-
-public static final java.lang.String |
-USERNAME |
-"hibernate.connection.username" |
-
Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.5/apidocs/de/juplo/plugins/hibernate4/Hbm2DdlMojo.html b/dist/hibernate4-maven-plugin-1.0.5/apidocs/de/juplo/plugins/hibernate4/Hbm2DdlMojo.html deleted file mode 100644 index c8d48277..00000000 --- a/dist/hibernate4-maven-plugin-1.0.5/apidocs/de/juplo/plugins/hibernate4/Hbm2DdlMojo.html +++ /dev/null @@ -1,437 +0,0 @@ - - - - - - -public class Hbm2DdlMojo
-extends org.apache.maven.plugin.AbstractMojo
-Modifier and Type | -Field and Description | -
---|---|
static java.lang.String |
-DIALECT |
-
static java.lang.String |
-DRIVER_CLASS |
-
static java.lang.String |
-ENVERS |
-
static java.lang.String |
-EXPORT_SKIPPED_PROPERTY |
-
static java.lang.String |
-MD5S |
-
static java.lang.String |
-NAMING_STRATEGY |
-
static java.lang.String |
-PASSWORD |
-
static java.lang.String |
-URL |
-
static java.lang.String |
-USERNAME |
-
ROLE
Constructor and Description | -
---|
Hbm2DdlMojo() |
-
Modifier and Type | -Method and Description | -
---|---|
void |
-execute() |
-
getLog, getPluginContext, setLog, setPluginContext
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
public static final java.lang.String EXPORT_SKIPPED_PROPERTY-
public static final java.lang.String DRIVER_CLASS-
public static final java.lang.String URL-
public static final java.lang.String USERNAME-
public static final java.lang.String PASSWORD-
public static final java.lang.String DIALECT-
public static final java.lang.String NAMING_STRATEGY-
public static final java.lang.String ENVERS-
public static final java.lang.String MD5S-
Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.5/apidocs/de/juplo/plugins/hibernate4/HelpMojo.html b/dist/hibernate4-maven-plugin-1.0.5/apidocs/de/juplo/plugins/hibernate4/HelpMojo.html deleted file mode 100644 index 3584392a..00000000 --- a/dist/hibernate4-maven-plugin-1.0.5/apidocs/de/juplo/plugins/hibernate4/HelpMojo.html +++ /dev/null @@ -1,298 +0,0 @@ - - - - - - -public class HelpMojo
-extends org.apache.maven.plugin.AbstractMojo
-mvn hibernate4:help -Ddetail=true -Dgoal=<goal-name>
to display parameter details.ROLE
Modifier and Type | -Method and Description | -
---|---|
void |
-execute() |
-
getLog, getPluginContext, setLog, setPluginContext
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.5/apidocs/de/juplo/plugins/hibernate4/ValidationConfiguration.html b/dist/hibernate4-maven-plugin-1.0.5/apidocs/de/juplo/plugins/hibernate4/ValidationConfiguration.html deleted file mode 100644 index 00542e23..00000000 --- a/dist/hibernate4-maven-plugin-1.0.5/apidocs/de/juplo/plugins/hibernate4/ValidationConfiguration.html +++ /dev/null @@ -1,336 +0,0 @@ - - - - - - -public class ValidationConfiguration
-extends org.hibernate.cfg.Configuration
-org.hibernate.cfg.Configuration.MappingsImpl, org.hibernate.cfg.Configuration.MetadataSourceQueue
ARTEFACT_PROCESSING_ORDER, auxiliaryDatabaseObjects, classes, collections, columnNameBindingPerTable, DEFAULT_ARTEFACT_PROCESSING_ORDER, DEFAULT_CACHE_CONCURRENCY_STRATEGY, extendsQueue, fetchProfiles, filterDefinitions, imports, metadataSourceQueue, namedEntityGraphMap, namedProcedureCallMap, namedQueries, namedSqlQueries, propertyReferences, secondPasses, settingsFactory, sqlFunctions, sqlResultSetMappings, tableNameBinding, tables, typeDefs, USE_NEW_ID_GENERATOR_MAPPINGS, xmlHelper
Constructor and Description | -
---|
ValidationConfiguration(java.lang.String dialectClass) |
-
Modifier and Type | -Method and Description | -
---|---|
java.lang.String |
-getTypeDefs() |
-
protected void |
-secondPassCompile() |
-
add, addAnnotatedClass, addAttributeConverter, addAttributeConverter, addAttributeConverter, addAttributeConverter, addAttributeConverter, addAuxiliaryDatabaseObject, addCacheableFile, addCacheableFile, addCacheableFileStrictly, addClass, addDirectory, addDocument, addFetchProfile, addFile, addFile, addFilterDefinition, addInputStream, addJar, addPackage, addProperties, addResource, addResource, addSqlFunction, addURL, addXML, buildMapping, buildMappings, buildSessionFactory, buildSessionFactory, buildSettings, buildSettings, configure, configure, configure, configure, configure, createMappings, doConfigure, doConfigure, findPossibleExtends, generateDropSchemaScript, generateSchemaCreationScript, generateSchemaUpdateScript, generateSchemaUpdateScriptList, getClassMapping, getClassMappings, getCollectionMapping, getCollectionMappings, getConfigurationInputStream, getCurrentTenantIdentifierResolver, getEntityNotFoundDelegate, getEntityResolver, getEntityTuplizerFactory, getFilterDefinitions, getIdentifierGeneratorFactory, getImports, getInterceptor, getJaccPermissionDeclarations, getMappedSuperclassMappings, getMappedSuperclassMappingsCopy, getNamedEntityGraphs, getNamedProcedureCallMap, getNamedQueries, getNamedSQLQueries, getNamingStrategy, getNamingStrategyDelegator, getProperties, getProperty, getReflectionManager, getSessionFactoryObserver, getSqlFunctions, getSqlResultSetMappings, getTableMappings, getTypeResolver, iterateFetchProfiles, iterateGenerators, mergeProperties, registerTypeContributor, registerTypeOverride, registerTypeOverride, registerTypeOverride, reset, secondPassCompileForeignKeys, setCacheConcurrencyStrategy, setCacheConcurrencyStrategy, setCacheConcurrencyStrategy, setCollectionCacheConcurrencyStrategy, setCollectionCacheConcurrencyStrategy, setCurrentTenantIdentifierResolver, setEntityNotFoundDelegate, setEntityResolver, setInterceptor, setNamingStrategy, setNamingStrategyDelegator, setPrecedence, setProperties, setProperty, setSessionFactoryObserver, validateSchema
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
public ValidationConfiguration(java.lang.String dialectClass)-
protected void secondPassCompile() - throws org.hibernate.metamodel.source.MappingException-
secondPassCompile
in class org.hibernate.cfg.Configuration
org.hibernate.metamodel.source.MappingException
public java.lang.String getTypeDefs()-
Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.5/apidocs/de/juplo/plugins/hibernate4/class-use/Hbm2DdlMojo.html b/dist/hibernate4-maven-plugin-1.0.5/apidocs/de/juplo/plugins/hibernate4/class-use/Hbm2DdlMojo.html deleted file mode 100644 index bbc40cb5..00000000 --- a/dist/hibernate4-maven-plugin-1.0.5/apidocs/de/juplo/plugins/hibernate4/class-use/Hbm2DdlMojo.html +++ /dev/null @@ -1,117 +0,0 @@ - - - - - - -Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.5/apidocs/de/juplo/plugins/hibernate4/class-use/HelpMojo.html b/dist/hibernate4-maven-plugin-1.0.5/apidocs/de/juplo/plugins/hibernate4/class-use/HelpMojo.html deleted file mode 100644 index ab54ce03..00000000 --- a/dist/hibernate4-maven-plugin-1.0.5/apidocs/de/juplo/plugins/hibernate4/class-use/HelpMojo.html +++ /dev/null @@ -1,117 +0,0 @@ - - - - - - -Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.5/apidocs/de/juplo/plugins/hibernate4/class-use/ValidationConfiguration.html b/dist/hibernate4-maven-plugin-1.0.5/apidocs/de/juplo/plugins/hibernate4/class-use/ValidationConfiguration.html deleted file mode 100644 index 10c0c24e..00000000 --- a/dist/hibernate4-maven-plugin-1.0.5/apidocs/de/juplo/plugins/hibernate4/class-use/ValidationConfiguration.html +++ /dev/null @@ -1,117 +0,0 @@ - - - - - - -Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.5/apidocs/de/juplo/plugins/hibernate4/package-frame.html b/dist/hibernate4-maven-plugin-1.0.5/apidocs/de/juplo/plugins/hibernate4/package-frame.html deleted file mode 100644 index 45cf65fd..00000000 --- a/dist/hibernate4-maven-plugin-1.0.5/apidocs/de/juplo/plugins/hibernate4/package-frame.html +++ /dev/null @@ -1,22 +0,0 @@ - - - - - - -Class | -Description | -
---|---|
Hbm2DdlMojo | -
- Goal which extracts the hibernate-mapping-configuration and
- exports an according SQL-database-schema.
- |
-
HelpMojo | -
- Display help information on hibernate4-maven-plugin.
- |
-
ValidationConfiguration | -
- This integration is usually performed by BeanValidationIntegrator.
- |
-
Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.5/apidocs/de/juplo/plugins/hibernate4/package-tree.html b/dist/hibernate4-maven-plugin-1.0.5/apidocs/de/juplo/plugins/hibernate4/package-tree.html deleted file mode 100644 index 364eae64..00000000 --- a/dist/hibernate4-maven-plugin-1.0.5/apidocs/de/juplo/plugins/hibernate4/package-tree.html +++ /dev/null @@ -1,140 +0,0 @@ - - - - - - -Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.5/apidocs/de/juplo/plugins/hibernate4/package-use.html b/dist/hibernate4-maven-plugin-1.0.5/apidocs/de/juplo/plugins/hibernate4/package-use.html deleted file mode 100644 index e160dcb7..00000000 --- a/dist/hibernate4-maven-plugin-1.0.5/apidocs/de/juplo/plugins/hibernate4/package-use.html +++ /dev/null @@ -1,117 +0,0 @@ - - - - - - -Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.5/apidocs/deprecated-list.html b/dist/hibernate4-maven-plugin-1.0.5/apidocs/deprecated-list.html deleted file mode 100644 index 705ba587..00000000 --- a/dist/hibernate4-maven-plugin-1.0.5/apidocs/deprecated-list.html +++ /dev/null @@ -1,117 +0,0 @@ - - - - - - -Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.5/apidocs/help-doc.html b/dist/hibernate4-maven-plugin-1.0.5/apidocs/help-doc.html deleted file mode 100644 index 974a1bf8..00000000 --- a/dist/hibernate4-maven-plugin-1.0.5/apidocs/help-doc.html +++ /dev/null @@ -1,222 +0,0 @@ - - - - - - -The Overview page is the front page of this API document and provides a list of all packages with a summary for each. This page can also contain an overall description of the set of packages.
-Each package has a page that contains a list of its classes and interfaces, with a summary for each. This page can contain six categories:
-Each class, interface, nested class and nested interface has its own separate page. Each of these pages has three sections consisting of a class/interface description, summary tables, and detailed member descriptions:
-Each summary entry contains the first sentence from the detailed description for that item. The summary entries are alphabetical, while the detailed descriptions are in the order they appear in the source code. This preserves the logical groupings established by the programmer.
-Each annotation type has its own separate page with the following sections:
-Each enum has its own separate page with the following sections:
-Each documented package, class and interface has its own Use page. This page describes what packages, classes, methods, constructors and fields use any part of the given class or package. Given a class or interface A, its Use page includes subclasses of A, fields declared as A, methods that return A, and methods and constructors with parameters of type A. You can access this page by first going to the package, class or interface, then clicking on the "Use" link in the navigation bar.
-There is a Class Hierarchy page for all packages, plus a hierarchy for each package. Each hierarchy page contains a list of classes and a list of interfaces. The classes are organized by inheritance structure starting with java.lang.Object
. The interfaces do not inherit from java.lang.Object
.
The Deprecated API page lists all of the API that have been deprecated. A deprecated API is not recommended for use, generally due to improvements, and a replacement API is usually given. Deprecated APIs may be removed in future implementations.
-The Index contains an alphabetic list of all classes, interfaces, constructors, methods, and fields.
-These links take you to the next or previous class, interface, package, or related page.
-These links show and hide the HTML frames. All pages are available with or without frames.
-The All Classes link shows all classes and interfaces except non-static nested types.
-Each serializable or externalizable class has a description of its serialization fields and methods. This information is of interest to re-implementors, not to developers using the API. While there is no link in the navigation bar, you can get to this information by going to any serialized class and clicking "Serialized Form" in the "See also" section of the class description.
-The Constant Field Values page lists the static final fields and their values.
-Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.5/apidocs/index-all.html b/dist/hibernate4-maven-plugin-1.0.5/apidocs/index-all.html deleted file mode 100644 index dfd80224..00000000 --- a/dist/hibernate4-maven-plugin-1.0.5/apidocs/index-all.html +++ /dev/null @@ -1,241 +0,0 @@ - - - - - - -TypeSafeActivator
- which itself is visible in the package only.Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.5/apidocs/index.html b/dist/hibernate4-maven-plugin-1.0.5/apidocs/index.html deleted file mode 100644 index c49472c3..00000000 --- a/dist/hibernate4-maven-plugin-1.0.5/apidocs/index.html +++ /dev/null @@ -1,75 +0,0 @@ - - - - - - -This document is designed to be viewed using the frames feature. If you see this message, you are using a non-frame-capable web client. Link to Non-frame version.
-public class TypeSafeActivatorAccessor
-extends java.lang.Object
-TypeSafeActivator
- which itself is visible in the package only.Constructor and Description | -
---|
TypeSafeActivatorAccessor() |
-
Modifier and Type | -Method and Description | -
---|---|
static void |
-activate(org.hibernate.cfg.beanvalidation.ActivationContext arg0) |
-
static void |
-applyCallbackListeners(javax.validation.ValidatorFactory arg0,
- org.hibernate.cfg.beanvalidation.ActivationContext arg1) |
-
static void |
-applyRelationalConstraints(javax.validation.ValidatorFactory arg0,
- java.util.Collection<org.hibernate.mapping.PersistentClass> arg1,
- java.util.Properties arg2,
- org.hibernate.dialect.Dialect arg3) |
-
static void |
-validateSuppliedFactory(java.lang.Object arg0) |
-
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
public TypeSafeActivatorAccessor()-
public static void validateSuppliedFactory(java.lang.Object arg0)-
public static void activate(org.hibernate.cfg.beanvalidation.ActivationContext arg0)-
public static void applyCallbackListeners(javax.validation.ValidatorFactory arg0, - org.hibernate.cfg.beanvalidation.ActivationContext arg1)-
public static void applyRelationalConstraints(javax.validation.ValidatorFactory arg0, - java.util.Collection<org.hibernate.mapping.PersistentClass> arg1, - java.util.Properties arg2, - org.hibernate.dialect.Dialect arg3)-
Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.5/apidocs/org/hibernate/cfg/beanvalidation/class-use/TypeSafeActivatorAccessor.html b/dist/hibernate4-maven-plugin-1.0.5/apidocs/org/hibernate/cfg/beanvalidation/class-use/TypeSafeActivatorAccessor.html deleted file mode 100644 index a06b8e8b..00000000 --- a/dist/hibernate4-maven-plugin-1.0.5/apidocs/org/hibernate/cfg/beanvalidation/class-use/TypeSafeActivatorAccessor.html +++ /dev/null @@ -1,117 +0,0 @@ - - - - - - -Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.5/apidocs/org/hibernate/cfg/beanvalidation/package-frame.html b/dist/hibernate4-maven-plugin-1.0.5/apidocs/org/hibernate/cfg/beanvalidation/package-frame.html deleted file mode 100644 index 2728d250..00000000 --- a/dist/hibernate4-maven-plugin-1.0.5/apidocs/org/hibernate/cfg/beanvalidation/package-frame.html +++ /dev/null @@ -1,20 +0,0 @@ - - - - - - -Class | -Description | -
---|---|
TypeSafeActivatorAccessor | -
- This class enables access to the public methods of
-TypeSafeActivator
- which itself is visible in the package only. |
-
Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.5/apidocs/org/hibernate/cfg/beanvalidation/package-tree.html b/dist/hibernate4-maven-plugin-1.0.5/apidocs/org/hibernate/cfg/beanvalidation/package-tree.html deleted file mode 100644 index 8d2fa039..00000000 --- a/dist/hibernate4-maven-plugin-1.0.5/apidocs/org/hibernate/cfg/beanvalidation/package-tree.html +++ /dev/null @@ -1,130 +0,0 @@ - - - - - - -Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.5/apidocs/org/hibernate/cfg/beanvalidation/package-use.html b/dist/hibernate4-maven-plugin-1.0.5/apidocs/org/hibernate/cfg/beanvalidation/package-use.html deleted file mode 100644 index 1bee30e4..00000000 --- a/dist/hibernate4-maven-plugin-1.0.5/apidocs/org/hibernate/cfg/beanvalidation/package-use.html +++ /dev/null @@ -1,117 +0,0 @@ - - - - - - -Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.5/apidocs/overview-frame.html b/dist/hibernate4-maven-plugin-1.0.5/apidocs/overview-frame.html deleted file mode 100644 index f4be1784..00000000 --- a/dist/hibernate4-maven-plugin-1.0.5/apidocs/overview-frame.html +++ /dev/null @@ -1,22 +0,0 @@ - - - - - - -- - diff --git a/dist/hibernate4-maven-plugin-1.0.5/apidocs/overview-summary.html b/dist/hibernate4-maven-plugin-1.0.5/apidocs/overview-summary.html deleted file mode 100644 index 8308c502..00000000 --- a/dist/hibernate4-maven-plugin-1.0.5/apidocs/overview-summary.html +++ /dev/null @@ -1,135 +0,0 @@ - - - - - - -
Package | -Description | -
---|---|
de.juplo.plugins.hibernate4 | -- |
org.hibernate.cfg.beanvalidation | -- |
Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.5/apidocs/overview-tree.html b/dist/hibernate4-maven-plugin-1.0.5/apidocs/overview-tree.html deleted file mode 100644 index 322a9915..00000000 --- a/dist/hibernate4-maven-plugin-1.0.5/apidocs/overview-tree.html +++ /dev/null @@ -1,142 +0,0 @@ - - - - - - -Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.5/apidocs/package-list b/dist/hibernate4-maven-plugin-1.0.5/apidocs/package-list deleted file mode 100644 index b80422d3..00000000 --- a/dist/hibernate4-maven-plugin-1.0.5/apidocs/package-list +++ /dev/null @@ -1,2 +0,0 @@ -de.juplo.plugins.hibernate4 -org.hibernate.cfg.beanvalidation diff --git a/dist/hibernate4-maven-plugin-1.0.5/apidocs/packages b/dist/hibernate4-maven-plugin-1.0.5/apidocs/packages deleted file mode 100644 index ad55515c..00000000 --- a/dist/hibernate4-maven-plugin-1.0.5/apidocs/packages +++ /dev/null @@ -1,2 +0,0 @@ -de.juplo.plugins.hibernate4 -org.hibernate.cfg.beanvalidation \ No newline at end of file diff --git a/dist/hibernate4-maven-plugin-1.0.5/apidocs/resources/background.gif b/dist/hibernate4-maven-plugin-1.0.5/apidocs/resources/background.gif deleted file mode 100644 index f471940f..00000000 Binary files a/dist/hibernate4-maven-plugin-1.0.5/apidocs/resources/background.gif and /dev/null differ diff --git a/dist/hibernate4-maven-plugin-1.0.5/apidocs/resources/tab.gif b/dist/hibernate4-maven-plugin-1.0.5/apidocs/resources/tab.gif deleted file mode 100644 index 1a73a83b..00000000 Binary files a/dist/hibernate4-maven-plugin-1.0.5/apidocs/resources/tab.gif and /dev/null differ diff --git a/dist/hibernate4-maven-plugin-1.0.5/apidocs/resources/titlebar.gif b/dist/hibernate4-maven-plugin-1.0.5/apidocs/resources/titlebar.gif deleted file mode 100644 index 17443b3e..00000000 Binary files a/dist/hibernate4-maven-plugin-1.0.5/apidocs/resources/titlebar.gif and /dev/null differ diff --git a/dist/hibernate4-maven-plugin-1.0.5/apidocs/resources/titlebar_end.gif b/dist/hibernate4-maven-plugin-1.0.5/apidocs/resources/titlebar_end.gif deleted file mode 100644 index 3ad78d46..00000000 Binary files a/dist/hibernate4-maven-plugin-1.0.5/apidocs/resources/titlebar_end.gif and /dev/null differ diff --git a/dist/hibernate4-maven-plugin-1.0.5/apidocs/serialized-form.html b/dist/hibernate4-maven-plugin-1.0.5/apidocs/serialized-form.html deleted file mode 100644 index 6f992894..00000000 --- a/dist/hibernate4-maven-plugin-1.0.5/apidocs/serialized-form.html +++ /dev/null @@ -1,187 +0,0 @@ - - - - - - -java.lang.Class<T> dialectClass-
javax.validation.ValidatorFactory factory-
java.util.concurrent.ConcurrentHashMap<K,V> associationsPerEntityPersister-
org.hibernate.cfg.beanvalidation.GroupsPerOperation groupsPerOperation-
boolean initialized-
Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.5/apidocs/stylesheet.css b/dist/hibernate4-maven-plugin-1.0.5/apidocs/stylesheet.css deleted file mode 100644 index 0aeaa97f..00000000 --- a/dist/hibernate4-maven-plugin-1.0.5/apidocs/stylesheet.css +++ /dev/null @@ -1,474 +0,0 @@ -/* Javadoc style sheet */ -/* -Overall document style -*/ -body { - background-color:#ffffff; - color:#353833; - font-family:Arial, Helvetica, sans-serif; - font-size:76%; - margin:0; -} -a:link, a:visited { - text-decoration:none; - color:#4c6b87; -} -a:hover, a:focus { - text-decoration:none; - color:#bb7a2a; -} -a:active { - text-decoration:none; - color:#4c6b87; -} -a[name] { - color:#353833; -} -a[name]:hover { - text-decoration:none; - color:#353833; -} -pre { - font-size:1.3em; -} -h1 { - font-size:1.8em; -} -h2 { - font-size:1.5em; -} -h3 { - font-size:1.4em; -} -h4 { - font-size:1.3em; -} -h5 { - font-size:1.2em; -} -h6 { - font-size:1.1em; -} -ul { - list-style-type:disc; -} -code, tt { - font-size:1.2em; -} -dt code { - font-size:1.2em; -} -table tr td dt code { - font-size:1.2em; - vertical-align:top; -} -sup { - font-size:.6em; -} -/* -Document title and Copyright styles -*/ -.clear { - clear:both; - height:0px; - overflow:hidden; -} -.aboutLanguage { - float:right; - padding:0px 21px; - font-size:.8em; - z-index:200; - margin-top:-7px; -} -.legalCopy { - margin-left:.5em; -} -.bar a, .bar a:link, .bar a:visited, .bar a:active { - color:#FFFFFF; - text-decoration:none; -} -.bar a:hover, .bar a:focus { - color:#bb7a2a; -} -.tab { - background-color:#0066FF; - background-image:url(resources/titlebar.gif); - background-position:left top; - background-repeat:no-repeat; - color:#ffffff; - padding:8px; - width:5em; - font-weight:bold; -} -/* -Navigation bar styles -*/ -.bar { - background-image:url(resources/background.gif); - background-repeat:repeat-x; - color:#FFFFFF; - padding:.8em .5em .4em .8em; - height:auto;/*height:1.8em;*/ - font-size:1em; - margin:0; -} -.topNav { - background-image:url(resources/background.gif); - background-repeat:repeat-x; - color:#FFFFFF; - float:left; - padding:0; - width:100%; - clear:right; - height:2.8em; - padding-top:10px; - overflow:hidden; -} -.bottomNav { - margin-top:10px; - background-image:url(resources/background.gif); - background-repeat:repeat-x; - color:#FFFFFF; - float:left; - padding:0; - width:100%; - clear:right; - height:2.8em; - padding-top:10px; - overflow:hidden; -} -.subNav { - background-color:#dee3e9; - border-bottom:1px solid #9eadc0; - float:left; - width:100%; - overflow:hidden; -} -.subNav div { - clear:left; - float:left; - padding:0 0 5px 6px; -} -ul.navList, ul.subNavList { - float:left; - margin:0 25px 0 0; - padding:0; -} -ul.navList li{ - list-style:none; - float:left; - padding:3px 6px; -} -ul.subNavList li{ - list-style:none; - float:left; - font-size:90%; -} -.topNav a:link, .topNav a:active, .topNav a:visited, .bottomNav a:link, .bottomNav a:active, .bottomNav a:visited { - color:#FFFFFF; - text-decoration:none; -} -.topNav a:hover, .bottomNav a:hover { - text-decoration:none; - color:#bb7a2a; -} -.navBarCell1Rev { - background-image:url(resources/tab.gif); - background-color:#a88834; - color:#FFFFFF; - margin: auto 5px; - border:1px solid #c9aa44; -} -/* -Page header and footer styles -*/ -.header, .footer { - clear:both; - margin:0 20px; - padding:5px 0 0 0; -} -.indexHeader { - margin:10px; - position:relative; -} -.indexHeader h1 { - font-size:1.3em; -} -.title { - color:#2c4557; - margin:10px 0; -} -.subTitle { - margin:5px 0 0 0; -} -.header ul { - margin:0 0 25px 0; - padding:0; -} -.footer ul { - margin:20px 0 5px 0; -} -.header ul li, .footer ul li { - list-style:none; - font-size:1.2em; -} -/* -Heading styles -*/ -div.details ul.blockList ul.blockList ul.blockList li.blockList h4, div.details ul.blockList ul.blockList ul.blockListLast li.blockList h4 { - background-color:#dee3e9; - border-top:1px solid #9eadc0; - border-bottom:1px solid #9eadc0; - margin:0 0 6px -8px; - padding:2px 5px; -} -ul.blockList ul.blockList ul.blockList li.blockList h3 { - background-color:#dee3e9; - border-top:1px solid #9eadc0; - border-bottom:1px solid #9eadc0; - margin:0 0 6px -8px; - padding:2px 5px; -} -ul.blockList ul.blockList li.blockList h3 { - padding:0; - margin:15px 0; -} -ul.blockList li.blockList h2 { - padding:0px 0 20px 0; -} -/* -Page layout container styles -*/ -.contentContainer, .sourceContainer, .classUseContainer, .serializedFormContainer, .constantValuesContainer { - clear:both; - padding:10px 20px; - position:relative; -} -.indexContainer { - margin:10px; - position:relative; - font-size:1.0em; -} -.indexContainer h2 { - font-size:1.1em; - padding:0 0 3px 0; -} -.indexContainer ul { - margin:0; - padding:0; -} -.indexContainer ul li { - list-style:none; -} -.contentContainer .description dl dt, .contentContainer .details dl dt, .serializedFormContainer dl dt { - font-size:1.1em; - font-weight:bold; - margin:10px 0 0 0; - color:#4E4E4E; -} -.contentContainer .description dl dd, .contentContainer .details dl dd, .serializedFormContainer dl dd { - margin:10px 0 10px 20px; -} -.serializedFormContainer dl.nameValue dt { - margin-left:1px; - font-size:1.1em; - display:inline; - font-weight:bold; -} -.serializedFormContainer dl.nameValue dd { - margin:0 0 0 1px; - font-size:1.1em; - display:inline; -} -/* -List styles -*/ -ul.horizontal li { - display:inline; - font-size:0.9em; -} -ul.inheritance { - margin:0; - padding:0; -} -ul.inheritance li { - display:inline; - list-style:none; -} -ul.inheritance li ul.inheritance { - margin-left:15px; - padding-left:15px; - padding-top:1px; -} -ul.blockList, ul.blockListLast { - margin:10px 0 10px 0; - padding:0; -} -ul.blockList li.blockList, ul.blockListLast li.blockList { - list-style:none; - margin-bottom:25px; -} -ul.blockList ul.blockList li.blockList, ul.blockList ul.blockListLast li.blockList { - padding:0px 20px 5px 10px; - border:1px solid #9eadc0; - background-color:#f9f9f9; -} -ul.blockList ul.blockList ul.blockList li.blockList, ul.blockList ul.blockList ul.blockListLast li.blockList { - padding:0 0 5px 8px; - background-color:#ffffff; - border:1px solid #9eadc0; - border-top:none; -} -ul.blockList ul.blockList ul.blockList ul.blockList li.blockList { - margin-left:0; - padding-left:0; - padding-bottom:15px; - border:none; - border-bottom:1px solid #9eadc0; -} -ul.blockList ul.blockList ul.blockList ul.blockList li.blockListLast { - list-style:none; - border-bottom:none; - padding-bottom:0; -} -table tr td dl, table tr td dl dt, table tr td dl dd { - margin-top:0; - margin-bottom:1px; -} -/* -Table styles -*/ -.contentContainer table, .classUseContainer table, .constantValuesContainer table { - border-bottom:1px solid #9eadc0; - width:100%; -} -.contentContainer ul li table, .classUseContainer ul li table, .constantValuesContainer ul li table { - width:100%; -} -.contentContainer .description table, .contentContainer .details table { - border-bottom:none; -} -.contentContainer ul li table th.colOne, .contentContainer ul li table th.colFirst, .contentContainer ul li table th.colLast, .classUseContainer ul li table th, .constantValuesContainer ul li table th, .contentContainer ul li table td.colOne, .contentContainer ul li table td.colFirst, .contentContainer ul li table td.colLast, .classUseContainer ul li table td, .constantValuesContainer ul li table td{ - vertical-align:top; - padding-right:20px; -} -.contentContainer ul li table th.colLast, .classUseContainer ul li table th.colLast,.constantValuesContainer ul li table th.colLast, -.contentContainer ul li table td.colLast, .classUseContainer ul li table td.colLast,.constantValuesContainer ul li table td.colLast, -.contentContainer ul li table th.colOne, .classUseContainer ul li table th.colOne, -.contentContainer ul li table td.colOne, .classUseContainer ul li table td.colOne { - padding-right:3px; -} -.overviewSummary caption, .packageSummary caption, .contentContainer ul.blockList li.blockList caption, .summary caption, .classUseContainer caption, .constantValuesContainer caption { - position:relative; - text-align:left; - background-repeat:no-repeat; - color:#FFFFFF; - font-weight:bold; - clear:none; - overflow:hidden; - padding:0px; - margin:0px; -} -caption a:link, caption a:hover, caption a:active, caption a:visited { - color:#FFFFFF; -} -.overviewSummary caption span, .packageSummary caption span, .contentContainer ul.blockList li.blockList caption span, .summary caption span, .classUseContainer caption span, .constantValuesContainer caption span { - white-space:nowrap; - padding-top:8px; - padding-left:8px; - display:block; - float:left; - background-image:url(resources/titlebar.gif); - height:18px; -} -.overviewSummary .tabEnd, .packageSummary .tabEnd, .contentContainer ul.blockList li.blockList .tabEnd, .summary .tabEnd, .classUseContainer .tabEnd, .constantValuesContainer .tabEnd { - width:10px; - background-image:url(resources/titlebar_end.gif); - background-repeat:no-repeat; - background-position:top right; - position:relative; - float:left; -} -ul.blockList ul.blockList li.blockList table { - margin:0 0 12px 0px; - width:100%; -} -.tableSubHeadingColor { - background-color: #EEEEFF; -} -.altColor { - background-color:#eeeeef; -} -.rowColor { - background-color:#ffffff; -} -.overviewSummary td, .packageSummary td, .contentContainer ul.blockList li.blockList td, .summary td, .classUseContainer td, .constantValuesContainer td { - text-align:left; - padding:3px 3px 3px 7px; -} -th.colFirst, th.colLast, th.colOne, .constantValuesContainer th { - background:#dee3e9; - border-top:1px solid #9eadc0; - border-bottom:1px solid #9eadc0; - text-align:left; - padding:3px 3px 3px 7px; -} -td.colOne a:link, td.colOne a:active, td.colOne a:visited, td.colOne a:hover, td.colFirst a:link, td.colFirst a:active, td.colFirst a:visited, td.colFirst a:hover, td.colLast a:link, td.colLast a:active, td.colLast a:visited, td.colLast a:hover, .constantValuesContainer td a:link, .constantValuesContainer td a:active, .constantValuesContainer td a:visited, .constantValuesContainer td a:hover { - font-weight:bold; -} -td.colFirst, th.colFirst { - border-left:1px solid #9eadc0; - white-space:nowrap; -} -td.colLast, th.colLast { - border-right:1px solid #9eadc0; -} -td.colOne, th.colOne { - border-right:1px solid #9eadc0; - border-left:1px solid #9eadc0; -} -table.overviewSummary { - padding:0px; - margin-left:0px; -} -table.overviewSummary td.colFirst, table.overviewSummary th.colFirst, -table.overviewSummary td.colOne, table.overviewSummary th.colOne { - width:25%; - vertical-align:middle; -} -table.packageSummary td.colFirst, table.overviewSummary th.colFirst { - width:25%; - vertical-align:middle; -} -/* -Content styles -*/ -.description pre { - margin-top:0; -} -.deprecatedContent { - margin:0; - padding:10px 0; -} -.docSummary { - padding:0; -} -/* -Formatting effect styles -*/ -.sourceLineNo { - color:green; - padding:0 30px 0 0; -} -h1.hidden { - visibility:hidden; - overflow:hidden; - font-size:.9em; -} -.block { - display:block; - margin:3px 0 0 0; -} -.strong { - font-weight:bold; -} diff --git a/dist/hibernate4-maven-plugin-1.0.5/configuration.html b/dist/hibernate4-maven-plugin-1.0.5/configuration.html deleted file mode 100644 index a10ddb0d..00000000 --- a/dist/hibernate4-maven-plugin-1.0.5/configuration.html +++ /dev/null @@ -1,390 +0,0 @@ - - - - - - - - -- The most simple way to configure the plugin is, to put all the - hibernate-configuration in a hibernate.properties-file on your - classpath. Put the file in the resources-folder. Maven will put - it in the class-folder of your webapp, where it will be picked up - by this plugin as well as by Hibernate 4. -
- -- Doing so, the only additionally configuration needed, to activat the plugin - is the following entry in the plugins-section of your pom.xml: -
- --<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.0.5</version> - <executions> - <execution> - <goals> - <goal>export</goal> - </goals> - </execution> - </executions> -</plugin>
- But be aware, that in this case the database-url, that is - build in the application is the same that is used while testing, where - the database is droped and recreated by the plugin. - Because of that, - - you should never fire up this configuration on your production - system, or your database might be erased! - -
- -- A better approach is, to specify a different url for testing like in the - following snippet: -
- --<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.0.5</version> - <executions> - <execution> - <goals> - <goal>export</goal> - </goals> - </execution> - </executions> - <configuration> - <url><![CDATA[jdbc:mysql://localhost/test-db]]></url> - </configuration> -</plugin>
- Configuration properties, that are set in the configuration-section - of the plugin-configuration cannnot be overwritten elsewere (for details - see Configuration-Method-Precedence). - You never can overwrite them by accident when specifying a property on - the commandline or in your settings.xml. -
-- Alternatively, it is possible, to configure the plugin via maven-properties. - Each relevant configuration-option has a corresponding maven-property - (for a full list see the Documentation of the export-Mojo). - These are named after the - Hibernate JDBC Properties: -
- -- So, instead of writing the hibernate-configuration in the properties-file, - like above, you could put it in the properties-section of your - pom.xml. -
- -- Thogether with the plugin-definition from above, the following would - be a complete configuration (again, the database-url was overwritten in - the plugin-configuration, to be sure to have a separate database for - testing): -
- --<properties> - <hibernate.connection.driver_class>org.hsqldb.jdbcDriver</hibernate.connection.driver_class> - <hibernate.dialect>org.hibernate.dialect.HSQLDialect</hibernate.dialect> - <hibernate.connection.url><![CDATA[jdbc:hsqldb:res:org.my.path.production_db]]></hibernate.connection.url> - <hibernate.connection.username>sa</hibernate.connection.username> - <hibernate.connection.password></hibernate.connection.password> -</properties> - -... - -<plugins> - - ... - - <plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.0.5</version> - <executions> - <execution> - <goals> - <goal>export</goal> - </goals> - </execution> - </executions> - <configuration> - <url><![CDATA[jdbc:hsqldb:target/db/testdb;shutdown=true]]></url> - </configuration> - </plugin> - -<plugins>
- A third way for configuring the plugin is the plugin-configuration. - The relevant configuration-parameters are: -
- -- The equivalent of the configuration from the last section would look - like this: -
- --<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.0.5</version> - <executions> - <execution> - <goals> - <goal>export</goal> - </goals> - </execution> - </executions> - <configuration> - <driverClassName>org.hsqldb.jdbcDriver</driverClassName> - <hibernateDialect>org.hibernate.dialect.HSQLDialect</hibernateDialect> - <url><![CDATA[jdbc:hsqldb:target/db/fotos;shutdown=true]]></url> - <username>sa</username> - <password></password> - </configuration> -</plugin>
- The parameter hibernateProperties (name of the hibernate-properties-file - to use, defaults to hibernate.properties) can only be configured through - this approach. -
- -- For more explanations, see the - Documentation of the export-Mojo. -
-- The configuration is gathered in a fix order: -
- -- If you are in doubt about where a configuration-value comes from, run - maven with the debug-output enabled: mvn -X hibernate4:export - and be aware, that maven-properties can be overwitten on the command-line, - in your ~/.m2/settings.xml and in a profile. -
- -- The plugin-configuration comes last and overwrites everything else. - That way, you can be sure, that a configuration-value, that is - specified in the plugin-configuration will never be overwritten by any - other configuration-method. -
- -- If you need to overwrite plugin-configuration-values with - maven-properties, you can use maven-properties in the plugin-configuration: -
- --<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.0.5</version> - <executions> - <execution> - <goals> - <goal>export</goal> - </goals> - </execution> - </executions> - <configuration> - <password>${my-password-property}</password> - </configuration> -</plugin>
The following document contains the results of PMD's CPD 4.3.
- If you are new to hibernate4-maven-plugin, in many cases, the - {Configuration-Method-Precedence} may be the source of configuration - errors. - To solve this problem, you should run maven with the debugging output - enabled. - For example, by executing: -
- --mvn -X compile hibernate4:export
- (The compile might be necessary, because hibernate4-maven-plugin - has to scan the compiled classes for annotations!) -
- -- Unlike the majority of the maven-plugins, hibernate4-maven-plugin was - designed to give a good many hints, when debugging is enabled. - Because, if you do not know, what went wrong, you can't fix it! -
- -- But be warned: hibernate4-maven-plugin tends to be very chatty ;) -
- - -The following is a list of compile dependencies for this project. These dependencies are required to compile and run the application:
-GroupId | -ArtifactId | -Version | -Type | -License |
---|---|---|---|---|
com.pyx4j | -maven-plugin-log4j | -1.0.1 | -jar | -The Apache Software License, Version 2.0 |
javax.el | -javax.el-api | -3.0.0 | -jar | -CDDL + GPLv2 with classpath exception |
org.apache.maven | -maven-core | -3.2.3 | -jar | -Apache License, Version 2.0 |
org.apache.maven | -maven-plugin-api | -3.2.3 | -jar | -Apache License, Version 2.0 |
org.hibernate | -hibernate-core | -4.3.7.Final | -jar | -GNU Lesser General Public License |
org.hibernate | -hibernate-envers | -4.3.7.Final | -jar | -GNU Lesser General Public License |
org.hibernate | -hibernate-validator | -5.1.3.Final | -jar | -Apache License, Version 2.0 |
org.scannotation | -scannotation | -1.0.3 | -jar | -- |
The following is a list of transitive dependencies for this project. Transitive dependencies are the dependencies of the project dependencies.
-The following is a list of compile dependencies for this project. These dependencies are required to compile and run the application:
-Apache Public License 2.0: Plexus Cipher: encryption/decryption Component, Plexus Security Dispatcher Component
-Apache License, version 2.0: JBoss Logging 3
-CDDL + GPLv2 with classpath exception: Expression Language 3.0 API
-Public Domain: AOP alliance, JBoss Logging I18n Annotations
-Unknown: dom4j, scannotation
-Common Development and Distribution License: Java Transaction API
-LGPL 2.1: Javassist
-Apache License, Version 2.0: CDI APIs, Hibernate Validator Engine, Maven Aether Provider, Maven Artifact, Maven Core, Maven Model, Maven Model Builder, Maven Plugin API, Maven Repository Metadata Model, Maven Settings, Maven Settings Builder
-MPL 1.1: Javassist
-GNU General Public License, Version 2 with the Classpath Exception: Java Transaction API
-COMMON DEVELOPMENT AND DISTRIBUTION LICENSE (CDDL) Version 1.0: JSR-250 Common Annotations for the JavaTM Platform
-The Apache Software License, Version 2.0: Bean Validation API, ClassMate, FindBugs-jsr305, Guava: Google Core Libraries for Java, Hibernate 4 Maven Plugin, Log4j, Plexus :: Component Annotations, Plexus Classworlds, Plexus Interpolation API, Sisu Guice - Core Library, XML Commons External Components XML APIs, javax.inject, maven-plugin-log4j
-GNU Lesser General Public License: Core Hibernate O/RM functionality, Entity versioning support, Hibernate Commons Annotations, Hibernate JPA Support
-Eclipse Public License (EPL), Version 1.0: Java Persistence API, Version 2.1
-BSD License: AntLR Parser Generator
-AL 2.0: Java Annotation Indexer
-Apache License 2.0: Javassist
-Eclipse Public License, Version 1.0: Aether API, Aether Implementation, Aether SPI, Aether Utilities, org.eclipse.sisu.inject, org.eclipse.sisu.plexus
-Eclipse Distribution License (EDL), Version 1.0: Java Persistence API, Version 2.1
Filename | -Size | -Entries | -Classes | -Packages | -JDK Rev | -Debug |
---|---|---|---|---|---|---|
antlr-2.7.7.jar | -434.85 kB | -239 | -224 | -12 | -1.2 | -debug |
aopalliance-1.0.jar | -4.36 kB | -15 | -9 | -2 | -1.3 | -debug |
classmate-1.0.0.jar | -58.87 kB | -51 | -36 | -4 | -1.6 | -debug |
jsr305-1.3.9.jar | -32.24 kB | -72 | -35 | -3 | -1.5 | -debug |
guava-10.0.1.jar | -1.43 MB | -1,185 | -1,164 | -10 | -1.5 | -debug |
maven-plugin-log4j-1.0.1.jar | -3.64 kB | -12 | -1 | -1 | -1.4 | -debug |
dom4j-1.6.1.jar | -306.54 kB | -208 | -190 | -14 | -1.3 | -debug |
javassist-3.12.1.GA.jar | -629.05 kB | -390 | -366 | -17 | -1.4 | -debug |
jsr250-api-1.0.jar | -5.71 kB | -16 | -11 | -2 | -1.5 | -debug |
javax.el-api-3.0.0.jar | -71.35 kB | -57 | -46 | -1 | -1.6 | -debug |
cdi-api-1.0.jar | -43.86 kB | -92 | -75 | -7 | -1.5 | -debug |
javax.inject-1.jar | -2.44 kB | -8 | -6 | -1 | -1.5 | -release |
validation-api-1.1.0.Final.jar | -62.28 kB | -122 | -106 | -8 | -1.6 | -debug |
log4j-1.2.14.jar | -358.83 kB | -288 | -256 | -19 | -1.1 | -debug |
maven-aether-provider-3.2.3.jar | -62.41 kB | -41 | -24 | -1 | -1.6 | -debug |
maven-artifact-3.2.3.jar | -52.46 kB | -57 | -32 | -11 | -1.6 | -debug |
maven-core-3.2.3.jar | -577.74 kB | -452 | -365 | -49 | -1.6 | -debug |
maven-model-3.2.3.jar | -156.10 kB | -67 | -50 | -3 | -1.6 | -debug |
maven-model-builder-3.2.3.jar | -164.12 kB | -148 | -115 | -16 | -1.6 | -debug |
maven-plugin-api-3.2.3.jar | -44.68 kB | -46 | -25 | -6 | -1.6 | -debug |
maven-repository-metadata-3.2.3.jar | -25.15 kB | -25 | -7 | -2 | -1.6 | -debug |
maven-settings-3.2.3.jar | -41.66 kB | -33 | -17 | -2 | -1.6 | -debug |
maven-settings-builder-3.2.3.jar | -42.01 kB | -53 | -32 | -5 | -1.6 | -debug |
plexus-classworlds-2.5.1.jar | -48.63 kB | -52 | -37 | -5 | -1.5 | -debug |
plexus-component-annotations-1.5.5.jar | -4.11 kB | -15 | -3 | -1 | -1.5 | -release |
plexus-interpolation-1.19.jar | -60.25 kB | -60 | -44 | -6 | -1.5 | -debug |
aether-api-0.9.0.M2.jar | -130.82 kB | -147 | -126 | -11 | -1.5 | -debug |
aether-impl-0.9.0.M2.jar | -141.47 kB | -98 | -80 | -2 | -1.5 | -debug |
aether-spi-0.9.0.M2.jar | -17.29 kB | -36 | -19 | -5 | -1.5 | -debug |
aether-util-0.9.0.M2.jar | -130.46 kB | -118 | -93 | -13 | -1.5 | -debug |
org.eclipse.sisu.inject-0.0.0.M5.jar | -284.57 kB | -236 | -219 | -8 | -1.5 | -debug |
org.eclipse.sisu.plexus-0.0.0.M5.jar | -191.94 kB | -196 | -164 | -20 | -1.5 | -debug |
hibernate-core-4.3.7.Final.jar | -5.03 MB | -3,708 | -3,459 | -201 | -1.6 | -debug |
hibernate-entitymanager-4.3.7.Final.jar | -632.33 kB | -486 | -443 | -27 | -1.6 | -debug |
hibernate-envers-4.3.7.Final.jar | -417.04 kB | -311 | -259 | -38 | -1.6 | -debug |
hibernate-validator-5.1.3.Final.jar | -619.40 kB | -483 | -410 | -41 | -1.6 | -debug |
hibernate-commons-annotations-4.0.5.Final.jar | -73.56 kB | -79 | -67 | -7 | -1.6 | -debug |
hibernate-jpa-2.1-api-1.0.0.Final.jar | -110.71 kB | -207 | -200 | -4 | -1.6 | -debug |
javassist-3.18.1-GA.jar | -697.46 kB | -414 | -390 | -17 | -1.6 | -debug |
jandex-1.1.0.Final.jar | -74.76 kB | -55 | -44 | -1 | -1.6 | -debug |
jboss-logging-3.1.3.GA.jar | -55.84 kB | -57 | -45 | -1 | -1.6 | -debug |
jboss-logging-annotations-1.2.0.Beta1.jar | -11.29 kB | -28 | -16 | -1 | -1.6 | -debug |
jboss-transaction-api_1.2_spec-1.0.0.Final.jar | -27.07 kB | -35 | -22 | -2 | -1.6 | -debug |
scannotation-1.0.3.jar | -18.33 kB | -23 | -13 | -2 | -1.5 | -debug |
plexus-cipher-1.4.jar | -13.18 kB | -20 | -6 | -1 | -1.4 | -debug |
plexus-sec-dispatcher-1.3.jar | -27.89 kB | -31 | -13 | -3 | -1.4 | -debug |
sisu-guice-3.1.0-no_aop.jar | -349.05 kB | -310 | -295 | -8 | -1.5 | -debug |
xml-apis-1.0.b2.jar | -106.76 kB | -217 | -184 | -17 | -1.2 | -release |
Total | -Size | -Entries | -Classes | -Packages | -JDK Rev | -Debug |
48 | -13.71 MB | -11,099 | -9,843 | -638 | -1.6 | -45 |
compile: 48 | -compile: 13.71 MB | -compile: 11,099 | -compile: 9,843 | -compile: 638 | -- | -compile: 45 |
Repo ID | -URL | -Release | -Snapshot |
---|---|---|---|
plexus.snapshots | -https://oss.sonatype.org/content/repositories/plexus-snapshots | -- | -Yes |
apache.snapshots | -http://repository.apache.org/snapshots | -- | -Yes |
sonatype-nexus-snapshots | -https://oss.sonatype.org/content/repositories/snapshots | -- | -Yes |
snapshots.jboss.org | -http://snapshots.jboss.org/maven2 | -- | -Yes |
jboss | -http://repository.jboss.org/nexus/content/groups/public/ | -Yes | -Yes |
oss.sonatype.org/jboss-snapshots | -http://oss.sonatype.org/content/repositories/jboss-snapshots | -- | -Yes |
central | -http://repo.maven.apache.org/maven2 | -Yes | -- |
repository.jboss.org | -http://repository.jboss.org/maven2 | -Yes | -- |
jvnet-nexus-snapshots | -https://maven.java.net/content/repositories/snapshots | -- | -Yes |
Repository locations for each of the Dependencies.
-<dependency> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.0.5</version> - <type>maven-plugin</type> -</dependency>
<dependency org="de.juplo" name="hibernate4-maven-plugin" rev="1.0.5"> - <artifact name="hibernate4-maven-plugin" type="maven-plugin" /> -</dependency>
The following is the distribution management information used by this project.
- -Full name:
- -de.juplo:hibernate4-maven-plugin:1.0.5:export
- -Description:
- -Attributes:
- -Name | - -Type | - -Since | - -Description | -
---|---|---|---|
delimiter | - -String | - -1.0 | - -Delimiter in output-file. Default value is: ;. User property is: hibernate.export.schema.delimiter. |
-
driverClassName | - -String | - -1.0 | - -SQL-Driver name. User property is: hibernate.connection.driver_class. |
-
envers | - -boolean | - -1.0.3 | - -Generate envers schema for auditing tables. Default value is: false. User property is: hibernate.export.envers. |
-
force | - -boolean | - -1.0 | - -Force execution
-
- Force execution, even if no modified or newly added annotated -classes where found and the dialect was not changed. - -skip takes precedence over force. Default value is: false. User property is: hibernate.export.force. |
-
format | - -boolean | - -1.0 | - -Format output-file. Default value is: true. User property is: hibernate.export.schema.format. |
-
hibernateDialect | - -String | - -1.0 | - -Hibernate dialect. User property is: hibernate.dialect. |
-
hibernateMapping | - -String | - -1.0.2 | - -List of Hibernate-Mapping-Files (XML). Multiple files can be
-separated with white-spaces and/or commas. User property is: hibernate.mapping. |
-
hibernateNamingStrategy | - -String | - -1.0.2 | - -Hibernate Naming Strategy User property is: hibernate.ejb.naming_strategy. |
-
hibernateProperties | - -String | - -1.0 | - -Path to Hibernate configuration file. Default value is: ${project.build.outputDirectory}/hibernate.properties. |
-
outputDirectory | - -String | - -1.0 | - -Classes-Directory to scan.
-
- This parameter defaults to the maven build-output-directory for -classes. Additionally, all dependencies are scanned for annotated -classes. User property is: project.build.outputDirectory. |
-
outputFile | - -String | - -1.0 | - -Output file. Default value is: ${project.build.directory}/schema.sql. User property is: hibernate.export.schema.filename. |
-
password | - -String | - -1.0 | - -Database password User property is: hibernate.connection.password. |
-
scanDependencies | - -String | - -1.0.3 | - -Dependency-Scopes, that should be scanned for annotated classes.
-
- By default, only dependencies in the scope compile -are scanned for annotated classes. Multiple scopes can be seperated -by white space or commas. - -If you do not want any dependencies to be scanned for annotated -classes, set this parameter to none. - -The plugin does not scan for annotated classes in transitive -dependencies. If some of your annotated classes are hidden in a -transitive dependency, you can simply add that dependency -explicitly. Default value is: compile. User property is: hibernate.export.scan_dependencies. |
-
scanTestClasses | - -boolean | - -1.0.1 | - -Whether to scan test-classes too, or not.
-
- If this parameter is set to true the test-classes -of the artifact will be scanned for hibernate-annotated classes -additionally. Default value is: false. User property is: hibernate.export.scan_testclasses. |
-
skip | - -boolean | - -1.0 | - -Skip execution
-
- If set to true, the execution is skipped. - -A skipped execution is signaled via the maven-property -${hibernate.export.skipped}. - -The execution is skipped automatically, if no modified or newly -added annotated classes are found and the dialect was not -changed. Default value is: ${maven.test.skip}. User property is: hibernate.skip. |
-
target | - -String | - -1.0 | - -Target of execution:
-
-
Default value is: EXPORT. User property is: hibernate.export.target. |
-
testOutputDirectory | - -String | - -1.0.2 | - -Test-Classes-Directory to scan.
-
- This parameter defaults to the maven build-output-directory for -test-classes. - -This parameter is only used, when scanTestClasses -is set to true! User property is: project.build.testOutputDirectory. |
-
type | - -String | - -1.0 | - -Type of execution.
-
-
Default value is: BOTH. User property is: hibernate.export.type. |
-
url | - -String | - -1.0 | - -Database URL. User property is: hibernate.connection.url. |
-
username | - -String | - -1.0 | - -Database username User property is: hibernate.connection.username. |
-
Force execution, even if no modified or newly added annotated -classes where found and the dialect was not changed.
- -skip takes precedence over force.
This parameter defaults to the maven build-output-directory for -classes. Additionally, all dependencies are scanned for annotated -classes.
By default, only dependencies in the scope compile -are scanned for annotated classes. Multiple scopes can be seperated -by white space or commas.
- -If you do not want any dependencies to be scanned for annotated -classes, set this parameter to none.
- -The plugin does not scan for annotated classes in transitive -dependencies. If some of your annotated classes are hidden in a -transitive dependency, you can simply add that dependency -explicitly.
If this parameter is set to true the test-classes -of the artifact will be scanned for hibernate-annotated classes -additionally.
skip:
- -If set to true, the execution is skipped.
- -A skipped execution is signaled via the maven-property -${hibernate.export.skipped}.
- -The execution is skipped automatically, if no modified or newly -added annotated classes are found and the dialect was not -changed.
This parameter defaults to the maven build-output-directory for -test-classes.
- -This parameter is only used, when scanTestClasses -is set to true!
type:
- -url:
- -- The hibernate4-maven-plugin computes MD5-sums for all found annotated - classes and stores them together with the generated schema. - If no classes were changed or added and the dialect wasn't changed too, it - automatically skips the configured schema-export, to speed up the development - cycle. -
- -- The plugin signals, that the execution was skipped by setting the maven - property $\{hibernate.export.skipped\} to true. - This may be helpful, because other plugins like - dbunit-plugin - may fail, when the execution is skipped. -
- -- If you need the hibernate4-maven-plugin to <never skip execution automatically>, - you can force it to do so, if you set the parameter force to - true: -
- --<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.0.5</version> - <configuration> - <force>true</force> - </configuration> -</plugin>
- Or you may specify -Dhibernate.export.force=true at the command line, - if you want to force hibernate4-maven-plugin only once. -
- - -Full name:
- -de.juplo:hibernate4-maven-plugin:1.0.5:help
- -Description:
- -Attributes:
- -Name | - -Type | - -Since | - -Description | -
---|---|---|---|
detail | - -boolean | - -- | - -If true, display all settable properties for each
-goal. Default value is: false. User property is: detail. |
-
goal | - -String | - -- | - -The name of the goal for which to show help. If unspecified, all
-goals will be displayed. User property is: goal. |
-
indentSize | - -int | - -- | - -The number of spaces per indentation level, should be positive. Default value is: 2. User property is: indentSize. |
-
lineLength | - -int | - -- | - -The maximum length of a display line, should be positive. Default value is: 80. User property is: lineLength. |
-
goal:
- -- The hibernate4-maven-plugin is a plugin for generating a database-schema - from your Hibernate-4-Mappings and create or update your database - accordingly. - Its main usage is to automatically create and populate a test-database - for unit-tests in cooperation with the - dbunit-maven-plugin. -
- -- The plugin was designed with three main goals in mind: -
- -- To achieve the first goal, the convention-over-configuration paradigma - was applied and the plugin was stuffed with usefull logging-messages. - So, if in doubt, just turn on the debugging output with the mvn -X .... -
- -- To achieve the second goal, the precedence in which the configuration - locations are consulted was layouted in a way that makes it possible, to - prevent overwrites of the wrong database by accident. -
- -- Last but not least, in order to not slow down the development cycle, the - hibernate4-maven-plugin only executes the schema-export, if the mapping - or the dialect changes (or if you force it to do so). -
- -- For more information about the inspiration to write this tiny plugin, - read our blog-article about the hibernate4-maven-plugin. -
-Configuration for notifying developers/users when a build is unsuccessful, including user information and notification mode.
-Type | -Address | -Configuration |
---|---|---|
kai@juplo.de | -- |
- Please send your bug-reports, questions or feature-requests directly - to the developer. -
- - -Typically the licenses listed for the project are that of the project itself, and not of dependencies.
A business-friendly OSS license
-- Apache License - Version 2.0, January 2004 - http://www.apache.org/licenses/ - - TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION - - 1. Definitions. - - "License" shall mean the terms and conditions for use, reproduction, - and distribution as defined by Sections 1 through 9 of this document. - - "Licensor" shall mean the copyright owner or entity authorized by - the copyright owner that is granting the License. - - "Legal Entity" shall mean the union of the acting entity and all - other entities that control, are controlled by, or are under common - control with that entity. For the purposes of this definition, - "control" means (i) the power, direct or indirect, to cause the - direction or management of such entity, whether by contract or - otherwise, or (ii) ownership of fifty percent (50%) or more of the - outstanding shares, or (iii) beneficial ownership of such entity. - - "You" (or "Your") shall mean an individual or Legal Entity - exercising permissions granted by this License. - - "Source" form shall mean the preferred form for making modifications, - including but not limited to software source code, documentation - source, and configuration files. - - "Object" form shall mean any form resulting from mechanical - transformation or translation of a Source form, including but - not limited to compiled object code, generated documentation, - and conversions to other media types. - - "Work" shall mean the work of authorship, whether in Source or - Object form, made available under the License, as indicated by a - copyright notice that is included in or attached to the work - (an example is provided in the Appendix below). - - "Derivative Works" shall mean any work, whether in Source or Object - form, that is based on (or derived from) the Work and for which the - editorial revisions, annotations, elaborations, or other modifications - represent, as a whole, an original work of authorship. For the purposes - of this License, Derivative Works shall not include works that remain - separable from, or merely link (or bind by name) to the interfaces of, - the Work and Derivative Works thereof. - - "Contribution" shall mean any work of authorship, including - the original version of the Work and any modifications or additions - to that Work or Derivative Works thereof, that is intentionally - submitted to Licensor for inclusion in the Work by the copyright owner - or by an individual or Legal Entity authorized to submit on behalf of - the copyright owner. For the purposes of this definition, "submitted" - means any form of electronic, verbal, or written communication sent - to the Licensor or its representatives, including but not limited to - communication on electronic mailing lists, source code control systems, - and issue tracking systems that are managed by, or on behalf of, the - Licensor for the purpose of discussing and improving the Work, but - excluding communication that is conspicuously marked or otherwise - designated in writing by the copyright owner as "Not a Contribution." - - "Contributor" shall mean Licensor and any individual or Legal Entity - on behalf of whom a Contribution has been received by Licensor and - subsequently incorporated within the Work. - - 2. Grant of Copyright License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - copyright license to reproduce, prepare Derivative Works of, - publicly display, publicly perform, sublicense, and distribute the - Work and such Derivative Works in Source or Object form. - - 3. Grant of Patent License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - (except as stated in this section) patent license to make, have made, - use, offer to sell, sell, import, and otherwise transfer the Work, - where such license applies only to those patent claims licensable - by such Contributor that are necessarily infringed by their - Contribution(s) alone or by combination of their Contribution(s) - with the Work to which such Contribution(s) was submitted. If You - institute patent litigation against any entity (including a - cross-claim or counterclaim in a lawsuit) alleging that the Work - or a Contribution incorporated within the Work constitutes direct - or contributory patent infringement, then any patent licenses - granted to You under this License for that Work shall terminate - as of the date such litigation is filed. - - 4. Redistribution. You may reproduce and distribute copies of the - Work or Derivative Works thereof in any medium, with or without - modifications, and in Source or Object form, provided that You - meet the following conditions: - - (a) You must give any other recipients of the Work or - Derivative Works a copy of this License; and - - (b) You must cause any modified files to carry prominent notices - stating that You changed the files; and - - (c) You must retain, in the Source form of any Derivative Works - that You distribute, all copyright, patent, trademark, and - attribution notices from the Source form of the Work, - excluding those notices that do not pertain to any part of - the Derivative Works; and - - (d) If the Work includes a "NOTICE" text file as part of its - distribution, then any Derivative Works that You distribute must - include a readable copy of the attribution notices contained - within such NOTICE file, excluding those notices that do not - pertain to any part of the Derivative Works, in at least one - of the following places: within a NOTICE text file distributed - as part of the Derivative Works; within the Source form or - documentation, if provided along with the Derivative Works; or, - within a display generated by the Derivative Works, if and - wherever such third-party notices normally appear. The contents - of the NOTICE file are for informational purposes only and - do not modify the License. You may add Your own attribution - notices within Derivative Works that You distribute, alongside - or as an addendum to the NOTICE text from the Work, provided - that such additional attribution notices cannot be construed - as modifying the License. - - You may add Your own copyright statement to Your modifications and - may provide additional or different license terms and conditions - for use, reproduction, or distribution of Your modifications, or - for any such Derivative Works as a whole, provided Your use, - reproduction, and distribution of the Work otherwise complies with - the conditions stated in this License. - - 5. Submission of Contributions. Unless You explicitly state otherwise, - any Contribution intentionally submitted for inclusion in the Work - by You to the Licensor shall be under the terms and conditions of - this License, without any additional terms or conditions. - Notwithstanding the above, nothing herein shall supersede or modify - the terms of any separate license agreement you may have executed - with Licensor regarding such Contributions. - - 6. Trademarks. This License does not grant permission to use the trade - names, trademarks, service marks, or product names of the Licensor, - except as required for reasonable and customary use in describing the - origin of the Work and reproducing the content of the NOTICE file. - - 7. Disclaimer of Warranty. Unless required by applicable law or - agreed to in writing, Licensor provides the Work (and each - Contributor provides its Contributions) on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or - implied, including, without limitation, any warranties or conditions - of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A - PARTICULAR PURPOSE. You are solely responsible for determining the - appropriateness of using or redistributing the Work and assume any - risks associated with Your exercise of permissions under this License. - - 8. Limitation of Liability. In no event and under no legal theory, - whether in tort (including negligence), contract, or otherwise, - unless required by applicable law (such as deliberate and grossly - negligent acts) or agreed to in writing, shall any Contributor be - liable to You for damages, including any direct, indirect, special, - incidental, or consequential damages of any character arising as a - result of this License or out of the use or inability to use the - Work (including but not limited to damages for loss of goodwill, - work stoppage, computer failure or malfunction, or any and all - other commercial damages or losses), even if such Contributor - has been advised of the possibility of such damages. - - 9. Accepting Warranty or Additional Liability. While redistributing - the Work or Derivative Works thereof, You may choose to offer, - and charge a fee for, acceptance of support, warranty, indemnity, - or other liability obligations and/or rights consistent with this - License. However, in accepting such obligations, You may act only - on Your own behalf and on Your sole responsibility, not on behalf - of any other Contributor, and only if You agree to indemnify, - defend, and hold each Contributor harmless for any liability - incurred by, or claims asserted against, such Contributor by reason - of your accepting any such warranty or additional liability. - - END OF TERMS AND CONDITIONS - - APPENDIX: How to apply the Apache License to your work. - - To apply the Apache License to your work, attach the following - boilerplate notice, with the fields enclosed by brackets "[]" - replaced with your own identifying information. (Don't include - the brackets!) The text should be enclosed in the appropriate - comment syntax for the file format. We also recommend that a - file or class name and description of purpose be included on the - same "printed page" as the copyright notice for easier - identification within third-party archives. - - Copyright [yyyy] [name of copyright owner] - - Licensed under the Apache License, Version 2.0 (the "License"); - you may not use this file except in compliance with the License. - You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. -
- Please send your bug-reports, questions or feature-requests directly - to the developer. -
- - -- hibernate4-maven-plugin by default scans dependencies in the scope - compile. You can configure it to scan dependencies in other - scopes as well. But it scans only direct dependencies. Transitive - dependencies are not scanned for annotated classes. If some of your - annotated classes are hidden in a transitive dependency, you can simply - add that dependency explicitly. -
-- The default-configuration uses the EXPORT-target of the SchemaExport-Tool. - If you do not need to create a database with the evaluated schema, you can - use the NONE- or the SCRIPT-target. - This can be achieved with the command-line parameter - -Dhibernate.export.target=SCRIPT or with the following configuration: -
- --<configuration> - <target>SCRIPT</target> -</configuration>
- But even when no database is to be created, hibernate always needs to know - the dialect. Hence, the plugin will fail if this parameter is missing! -
-- One regular problem is the scope of the jdbc-driver-dependency. - It is very unlikely, that this dependency is needed at compile-time. - So a tidy maven-developer would usually scope it for runtime. -
- -- But this will break the execution of the hibernate4-maven-plugin. - Since it will not be able to see the needed dependency, it will fail with - an error-message like: -
- --[INFO] Gathered hibernate-configuration (turn on debugging for details): -[INFO] hibernate.connection.username = sa -[INFO] hibernate.connection.password = -[INFO] hibernate.dialect = org.hibernate.dialect.HSQLDialect -[INFO] hibernate.connection.url = jdbc:hsqldb:/home/kai/mmf/target/mmf;shutdown=true -[INFO] hibernate.connection.driver_class = org.hsqldb.jdbcDriver -[ERROR] Dependency for driver-class org.hsqldb.jdbcDriver is missing! -[INFO] ------------------------------------------------------------------------ -[ERROR] BUILD ERROR -[INFO] ------------------------------------------------------------------------ -[INFO] org.hsqldb.jdbcDriver -[INFO] ------------------------------------------------------------------------ -[INFO] For more information, run Maven with the -e switch -[INFO] ------------------------------------------------------------------------ -[INFO] Total time: 2 seconds -[INFO] Finished at: Thu Nov 29 11:31:14 CET 2012 -[INFO] Final Memory: 32M/342M -[INFO] ------------------------------------------------------------------------
- A quick workaround for this error would be, to delete the runtime-constraint - for the jdbc-driver-dependency. -
- -- A much cleaner way is, to (additionally) ad the dependency, to the - plugin-definition: -
- --<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.0.5</version> - <executions> - <execution> - <goals> - <goal>export</goal> - </goals> - </execution> - </executions> - <dependencies> - <dependency> - <groupId>org.hsqldb</groupId> - <artifactId>hsqldb</artifactId> - <version>2.2.8</version> - </dependency> - </dependencies> -</plugin>
- This is also the best way, if you use a different jdbc-driver for - testing, than in production. - Because otherwise, this dependency will unnecessarily bloat the - runtime-dependencies of your project. -
-- If hibernate4-maven-plugin skips its excecution, this may lead to errors in - other plugins. - For example, when importing sample-data in the automatically created database - with the help of the dbunit-plugin, - the CLEAN_INSERT-operation may fail because of foreign-key-constraints, - if the database was not recreated, because the hibernate4-maven-plugin has - skipped its excecution. -
- -- A quick fix to this problem is, to force - hibernate4-maven-plugin to export the schema every time it is running. - But to recreate the database on every testrun may noticeable slow down your - development cycle, if you have to wait for slow IO. -
- -- To circumvent this problem, hibernate4-maven-plugin signals a skipped - excecution by setting the maven property $\{hibernate.export.skipped\} to - true. - You can configure other plugins to react on this signal. - For example, the dbunit-plugin can be configured to skip its excecution, if - hibernate4-maven-plugin was skipped like this: -
- --<plugin> - <groupId>org.codehaus.mojo</groupId> - <artifactId>dbunit-maven-plugin</artifactId> - <configuration> - <skip>${hibernate.export.skipped}</skip> - </configuration> -</plugin>
- If one manually drops the database or removes the hsqldb-files, it will not - be recreated by the hibernate4-maven-plugin, because it cannot detect, that - the database needs to be recreated. - This happens, because the plugin will not recreate the database if neither - the configuration nor the annotated classes have changed, because an - unnecessary drop-create-cycle might take a long time. The plugin will - report that like this: -
- --[INFO] No modified annotated classes found and dialect unchanged. -[INFO] Skipping schema generation!
- If one always uses mvn clean for cleanup, this will not happen. - Otherwise the recreation must be forced: -
- --mvn hibernate4:export -Dhibernate.export.force=true
- The hibernate4-maven-plugin automatically skips its execution, when - maven.test.skip is set to true. If you need it to be always - executed, you can configure that explicitly like this: -
- --<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - ... - <configuration> - <skip>false</skip> - </configuration> -</plugin>
- Background-information for this design-decission can be found on the extra - page To skip or not to skip: that is the question... -
-- If you do not want your dependencies to be scanned for hibernate annotations, - you can pass -Dhibernate.export.scan_dependencies=none to maven - or set scanDependencies to none in the configuration - of the plugin like this: -
- --<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - ... - <configuration> - <scanDependencies>none</scanDependencies> - </configuration> -</plugin>
- If you are working under Windows and get the error-message - No annotated classes found in directory C:\projects\X Y Z\path-to-project\target\classes, - but you are really sure, that there are annotated classes in that - directory, you should try to rename your folders, so that their names - do not contain any whitespaces. -
- -- So fare, I got to bug-reports considering this. - In both cases, removing all whitespaces from the path solved the error. - In both cases, I was not able to reproduce the bug on my development - system, which is running under linux. -
- -- - Hence, I assume, this is a sublte bug in the way, the java-version for - Windows is handling paths, that contain whitespaces. - -
-Goals available for this plugin:
-Goal | -Description |
---|---|
hibernate4:export | -Goal which extracts the hibernate-mapping-configuration and exports -an according SQL-database-schema. |
hibernate4:help | -Display help information on hibernate4-maven-plugin. -Call mvn hibernate4:help -Ddetail=true
--Dgoal=<goal-name> to display parameter details. |
The following specifies the minimum requirements to run this Maven plugin:
-Maven | -2.0.6 |
JDK | -1.6 |
Memory | -No minimum requirement. |
Disk Space | -No minimum requirement. |
You should specify the version in your project's plugin configuration:
-<project> - ... - <build> - <!-- To define the plugin version in your parent POM --> - <pluginManagement> - <plugins> - <plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.0.5</version> - </plugin> - ... - </plugins> - </pluginManagement> - <!-- To use the plugin goals in your POM or parent POM --> - <plugins> - <plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.0.5</version> - </plugin> - ... - </plugins> - </build> - ... -</project> -
For more information, see "Guide to Configuring Plug-ins"
GroupId | -ArtifactId | -Version |
---|---|---|
org.apache.maven.plugins | -maven-antrun-plugin | -1.3 |
org.apache.maven.plugins | -maven-assembly-plugin | -2.2-beta-5 |
org.apache.maven.plugins | -maven-dependency-plugin | -2.1 |
org.apache.maven.plugins | -maven-release-plugin | -2.1 |
org.apache.maven.plugins | -maven-site-plugin | -3.3 |
GroupId | -ArtifactId | -Version |
---|---|---|
org.apache.maven.plugins | -maven-clean-plugin | -2.5 |
org.apache.maven.plugins | -maven-compiler-plugin | -2.0.2 |
org.apache.maven.plugins | -maven-dependency-plugin | -2.1 |
org.apache.maven.plugins | -maven-deploy-plugin | -2.7 |
org.apache.maven.plugins | -maven-enforcer-plugin | -1.0 |
org.apache.maven.plugins | -maven-install-plugin | -2.3 |
org.apache.maven.plugins | -maven-invoker-plugin | -1.8 |
org.apache.maven.plugins | -maven-jar-plugin | -2.2 |
org.apache.maven.plugins | -maven-plugin-plugin | -3.2 |
org.apache.maven.plugins | -maven-resources-plugin | -2.3 |
org.apache.maven.plugins | -scp://people.apache.org/www/maven.apache.org/scm/maven-scm-plugin | -1.7 |
org.apache.maven.plugins | -maven-site-plugin | -3.3 |
org.apache.maven.plugins | -maven-source-plugin | -2.1.2 |
org.apache.maven.plugins | -maven-surefire-plugin | -2.10 |
GroupId | -ArtifactId | -Version |
---|---|---|
org.apache.maven.plugins | -maven-changes-plugin | -2.7.1 |
org.apache.maven.plugins | -maven-javadoc-plugin | -2.7 |
org.apache.maven.plugins | -maven-jxr-plugin | -2.3 |
org.apache.maven.plugins | -maven-plugin-plugin | -3.2 |
org.apache.maven.plugins | -maven-pmd-plugin | -2.7.1 |
The following document contains the results of PMD 4.3.
This document provides an overview of the various documents and links that are part of this project's general information. All of this content is automatically generated by Maven on behalf of the project.
-Document | -Description |
---|---|
About | -Plugin for generating a database-schema from Hibernate-4-Mapping-Annotations |
Plugin Management | -This document lists the plugins that are defined through pluginManagement. |
Distribution Management | -This document provides informations on the distribution management of this project. |
Dependency Information | -This document describes how to to include this project as a dependency using various dependency management tools. |
Source Repository | -This is a link to the online source repository that can be viewed via a web browser. |
Mailing Lists | -This document provides subscription and archive information for this project's mailing lists. |
Issue Tracking | -This is a link to the issue management system for this project. Issues (bugs, features, change requests) can be created and queried using this link. |
Continuous Integration | -This is a link to the definitions of all continuous integration processes that builds and tests code on a frequent, regular basis. |
Project Plugins | -This document lists the build plugins and the report plugins used by this project. |
Project License | -This is a link to the definitions of project licenses. |
Project Team | -This document provides information on the members of this project. These are the individuals who have contributed to the project in one form or another. |
Project Summary | -This document lists other related information of this project |
Dependencies | -This document lists the project's dependencies and provides information on each dependency. |
This document provides an overview of the various reports that are automatically generated by Maven . Each report is briefly described below.
-Document | -Description |
---|---|
Test JavaDocs | -Test JavaDoc API documentation. |
JavaDocs | -JavaDoc API documentation. |
Source Xref | -HTML based, cross-reference version of Java source code. |
Test Source Xref | -HTML based, cross-reference version of Java test source code. |
PMD Report | -Verification of coding rules. |
CPD Report | -Duplicate code detection. |
Plugin Documentation | -This report provides goals and parameters documentation of a plugin. |
Field | -Value |
---|---|
Name | -Hibernate 4 Maven Plugin |
Description | -Plugin for generating a database-schema from Hibernate-4-Mapping-Annotations |
Homepage | -http://juplo.de/hibernate4-maven-plugin |
- In most use-cases, the hibernate4-maven-plugin is used to create a - test-database automatically. In this use-cases, it is very likely, that it - will result in mistakes/errors, if the goal is executed, when the tests - are skipped. - For example, one might manually overwrite the database-url with the url of - the production-database, in order to run other tests, like starting a - local webserver with the - jetty-maven-plugin. - If the export-goal would be executed in such a scenario, it might erase the - hole production-database, which is not very desireable. -
- -- Because of this, the configuration-parameter skip defaults to the value - of the proptery maven.test.skip. This way, the execution of the - hibernate4-maven-plugin is skipped automatically, when the tests are - skipped. Think of it as a build-in security-belt. -
- -- If you do not like that, because you need the plugin to always execute the - export-goal, even if the tests are skipped you can configure that explicitly, - by setting the configuration-parameter skip to false: -
- --<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - ... - <configuration> - <skip>false</skip> - </configuration> -</plugin>
- Or, if you want the export-goal to be executed by default and to be skipped - if you say so, you can bind the value of the configuration-parameter - skip to a custom property. For example: -
- --<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - ... - <configuration> - <skip>${foo.bar}</skip> - </configuration> -</plugin>
- This way, the export-goal would be skipped, if you set the property - foo.bar to true. For example, if you specify -Dfoo.bar=true - on the command-line. -
- - -This project uses GIT to manage its source code. Instructions on GIT use can be found at http://git-scm.com/documentation.
The source can be checked out anonymously from GIT with this command (See http://git-scm.com/docs/git-clone):
-$ git clone http://juplo.de/git/hibernate4-maven-plugin
Only project developers can access the GIT tree via this method (See http://git-scm.com/docs/git-clone).
-$ git clone ssh://juplo.de/var/lib/git/juplo/hibernate4-maven-plugin
A successful project requires many people to play many roles. Some members write code or documentation, while others are valuable as testers, submitting patches and suggestions.
-The team is comprised of Members and Contributors. Members have direct access to the source of a project and actively evolve the code-base. Contributors improve the project through submission of patches and suggestions to the Members. The number of Contributors to the project is unbounded. Get involved today. All contributions to the project are greatly appreciated.
-The following is a list of developers with commit privileges that have directly contributed to the project in one way or another.
-Image | -Id | -Name | -|
---|---|---|---|
- | kai | -Kai Moritz | -kai@juplo.de |
The following additional people have contributed to this project through the way of suggestions, patches or documentation.
-Image | -Name | -|
---|---|---|
- | Adriano Machado | -adriano.m.machado@hotmail.com |
- | Lorenzo Nicora | -lorenzo.nicora@nicus.it |
- | Eduard Szente | -eduard.szente@gmail.com |
- | Stephen Johnson | -stejohns@redhat.com |
- | Victor Tatai | -vtatai@gmail.com |
- | Erik-Berndt Scheper | -erik.berndt.scheper@gmail.com |
- | Guido Wimmel | -Wimmel.Guido@swm.de |
- | Joel Johnson | -mrjoel@lixil.net |
- | Paul K. Moore | -paulkmoore@gmail.com |
- | Mark Robinson | -mark@mrobinson.ca |
- | Claus Graf | -clausgraf@gmail.com |
- | Joachim Van der Auwera | -joachim@progs.be |
Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.5/testapidocs/de/juplo/test/FileComparator.html b/dist/hibernate4-maven-plugin-1.0.5/testapidocs/de/juplo/test/FileComparator.html deleted file mode 100644 index ecc603e0..00000000 --- a/dist/hibernate4-maven-plugin-1.0.5/testapidocs/de/juplo/test/FileComparator.html +++ /dev/null @@ -1,263 +0,0 @@ - - - - - - -public class FileComparator
-extends java.lang.Object
-Constructor and Description | -
---|
FileComparator(java.io.File basedir) |
-
Modifier and Type | -Method and Description | -
---|---|
boolean |
-isEqual(java.lang.String expectedFile,
- java.lang.String foundFile) |
-
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.5/testapidocs/de/juplo/test/class-use/FileComparator.html b/dist/hibernate4-maven-plugin-1.0.5/testapidocs/de/juplo/test/class-use/FileComparator.html deleted file mode 100644 index 618a4bc8..00000000 --- a/dist/hibernate4-maven-plugin-1.0.5/testapidocs/de/juplo/test/class-use/FileComparator.html +++ /dev/null @@ -1,115 +0,0 @@ - - - - - - -Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.5/testapidocs/de/juplo/test/package-frame.html b/dist/hibernate4-maven-plugin-1.0.5/testapidocs/de/juplo/test/package-frame.html deleted file mode 100644 index 490f7b47..00000000 --- a/dist/hibernate4-maven-plugin-1.0.5/testapidocs/de/juplo/test/package-frame.html +++ /dev/null @@ -1,20 +0,0 @@ - - - - - - -Class | -Description | -
---|---|
FileComparator | -- |
Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.5/testapidocs/de/juplo/test/package-tree.html b/dist/hibernate4-maven-plugin-1.0.5/testapidocs/de/juplo/test/package-tree.html deleted file mode 100644 index b8f2c264..00000000 --- a/dist/hibernate4-maven-plugin-1.0.5/testapidocs/de/juplo/test/package-tree.html +++ /dev/null @@ -1,124 +0,0 @@ - - - - - - -Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.5/testapidocs/de/juplo/test/package-use.html b/dist/hibernate4-maven-plugin-1.0.5/testapidocs/de/juplo/test/package-use.html deleted file mode 100644 index 6e35f6de..00000000 --- a/dist/hibernate4-maven-plugin-1.0.5/testapidocs/de/juplo/test/package-use.html +++ /dev/null @@ -1,115 +0,0 @@ - - - - - - -Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.5/testapidocs/deprecated-list.html b/dist/hibernate4-maven-plugin-1.0.5/testapidocs/deprecated-list.html deleted file mode 100644 index 44fe67a5..00000000 --- a/dist/hibernate4-maven-plugin-1.0.5/testapidocs/deprecated-list.html +++ /dev/null @@ -1,115 +0,0 @@ - - - - - - -Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.5/testapidocs/help-doc.html b/dist/hibernate4-maven-plugin-1.0.5/testapidocs/help-doc.html deleted file mode 100644 index 79a5de9a..00000000 --- a/dist/hibernate4-maven-plugin-1.0.5/testapidocs/help-doc.html +++ /dev/null @@ -1,216 +0,0 @@ - - - - - - -Each package has a page that contains a list of its classes and interfaces, with a summary for each. This page can contain six categories:
-Each class, interface, nested class and nested interface has its own separate page. Each of these pages has three sections consisting of a class/interface description, summary tables, and detailed member descriptions:
-Each summary entry contains the first sentence from the detailed description for that item. The summary entries are alphabetical, while the detailed descriptions are in the order they appear in the source code. This preserves the logical groupings established by the programmer.
-Each annotation type has its own separate page with the following sections:
-Each enum has its own separate page with the following sections:
-Each documented package, class and interface has its own Use page. This page describes what packages, classes, methods, constructors and fields use any part of the given class or package. Given a class or interface A, its Use page includes subclasses of A, fields declared as A, methods that return A, and methods and constructors with parameters of type A. You can access this page by first going to the package, class or interface, then clicking on the "Use" link in the navigation bar.
-There is a Class Hierarchy page for all packages, plus a hierarchy for each package. Each hierarchy page contains a list of classes and a list of interfaces. The classes are organized by inheritance structure starting with java.lang.Object
. The interfaces do not inherit from java.lang.Object
.
The Deprecated API page lists all of the API that have been deprecated. A deprecated API is not recommended for use, generally due to improvements, and a replacement API is usually given. Deprecated APIs may be removed in future implementations.
-The Index contains an alphabetic list of all classes, interfaces, constructors, methods, and fields.
-These links take you to the next or previous class, interface, package, or related page.
-These links show and hide the HTML frames. All pages are available with or without frames.
-The All Classes link shows all classes and interfaces except non-static nested types.
-Each serializable or externalizable class has a description of its serialization fields and methods. This information is of interest to re-implementors, not to developers using the API. While there is no link in the navigation bar, you can get to this information by going to any serialized class and clicking "Serialized Form" in the "See also" section of the class description.
-The Constant Field Values page lists the static final fields and their values.
-Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.5/testapidocs/index-all.html b/dist/hibernate4-maven-plugin-1.0.5/testapidocs/index-all.html deleted file mode 100644 index 2fdaff4c..00000000 --- a/dist/hibernate4-maven-plugin-1.0.5/testapidocs/index-all.html +++ /dev/null @@ -1,138 +0,0 @@ - - - - - - -Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.5/testapidocs/index.html b/dist/hibernate4-maven-plugin-1.0.5/testapidocs/index.html deleted file mode 100644 index ae605f8b..00000000 --- a/dist/hibernate4-maven-plugin-1.0.5/testapidocs/index.html +++ /dev/null @@ -1,72 +0,0 @@ - - - - - - -This document is designed to be viewed using the frames feature. If you see this message, you are using a non-frame-capable web client. Link to Non-frame version.
-Copyright © 2014. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0.5/testapidocs/package-list b/dist/hibernate4-maven-plugin-1.0.5/testapidocs/package-list deleted file mode 100644 index 4774195e..00000000 --- a/dist/hibernate4-maven-plugin-1.0.5/testapidocs/package-list +++ /dev/null @@ -1 +0,0 @@ -de.juplo.test diff --git a/dist/hibernate4-maven-plugin-1.0.5/testapidocs/packages b/dist/hibernate4-maven-plugin-1.0.5/testapidocs/packages deleted file mode 100644 index 8fbea680..00000000 --- a/dist/hibernate4-maven-plugin-1.0.5/testapidocs/packages +++ /dev/null @@ -1 +0,0 @@ -de.juplo.test \ No newline at end of file diff --git a/dist/hibernate4-maven-plugin-1.0.5/testapidocs/resources/background.gif b/dist/hibernate4-maven-plugin-1.0.5/testapidocs/resources/background.gif deleted file mode 100644 index f471940f..00000000 Binary files a/dist/hibernate4-maven-plugin-1.0.5/testapidocs/resources/background.gif and /dev/null differ diff --git a/dist/hibernate4-maven-plugin-1.0.5/testapidocs/resources/tab.gif b/dist/hibernate4-maven-plugin-1.0.5/testapidocs/resources/tab.gif deleted file mode 100644 index 1a73a83b..00000000 Binary files a/dist/hibernate4-maven-plugin-1.0.5/testapidocs/resources/tab.gif and /dev/null differ diff --git a/dist/hibernate4-maven-plugin-1.0.5/testapidocs/resources/titlebar.gif b/dist/hibernate4-maven-plugin-1.0.5/testapidocs/resources/titlebar.gif deleted file mode 100644 index 17443b3e..00000000 Binary files a/dist/hibernate4-maven-plugin-1.0.5/testapidocs/resources/titlebar.gif and /dev/null differ diff --git a/dist/hibernate4-maven-plugin-1.0.5/testapidocs/resources/titlebar_end.gif b/dist/hibernate4-maven-plugin-1.0.5/testapidocs/resources/titlebar_end.gif deleted file mode 100644 index 3ad78d46..00000000 Binary files a/dist/hibernate4-maven-plugin-1.0.5/testapidocs/resources/titlebar_end.gif and /dev/null differ diff --git a/dist/hibernate4-maven-plugin-1.0.5/testapidocs/stylesheet.css b/dist/hibernate4-maven-plugin-1.0.5/testapidocs/stylesheet.css deleted file mode 100644 index 0aeaa97f..00000000 --- a/dist/hibernate4-maven-plugin-1.0.5/testapidocs/stylesheet.css +++ /dev/null @@ -1,474 +0,0 @@ -/* Javadoc style sheet */ -/* -Overall document style -*/ -body { - background-color:#ffffff; - color:#353833; - font-family:Arial, Helvetica, sans-serif; - font-size:76%; - margin:0; -} -a:link, a:visited { - text-decoration:none; - color:#4c6b87; -} -a:hover, a:focus { - text-decoration:none; - color:#bb7a2a; -} -a:active { - text-decoration:none; - color:#4c6b87; -} -a[name] { - color:#353833; -} -a[name]:hover { - text-decoration:none; - color:#353833; -} -pre { - font-size:1.3em; -} -h1 { - font-size:1.8em; -} -h2 { - font-size:1.5em; -} -h3 { - font-size:1.4em; -} -h4 { - font-size:1.3em; -} -h5 { - font-size:1.2em; -} -h6 { - font-size:1.1em; -} -ul { - list-style-type:disc; -} -code, tt { - font-size:1.2em; -} -dt code { - font-size:1.2em; -} -table tr td dt code { - font-size:1.2em; - vertical-align:top; -} -sup { - font-size:.6em; -} -/* -Document title and Copyright styles -*/ -.clear { - clear:both; - height:0px; - overflow:hidden; -} -.aboutLanguage { - float:right; - padding:0px 21px; - font-size:.8em; - z-index:200; - margin-top:-7px; -} -.legalCopy { - margin-left:.5em; -} -.bar a, .bar a:link, .bar a:visited, .bar a:active { - color:#FFFFFF; - text-decoration:none; -} -.bar a:hover, .bar a:focus { - color:#bb7a2a; -} -.tab { - background-color:#0066FF; - background-image:url(resources/titlebar.gif); - background-position:left top; - background-repeat:no-repeat; - color:#ffffff; - padding:8px; - width:5em; - font-weight:bold; -} -/* -Navigation bar styles -*/ -.bar { - background-image:url(resources/background.gif); - background-repeat:repeat-x; - color:#FFFFFF; - padding:.8em .5em .4em .8em; - height:auto;/*height:1.8em;*/ - font-size:1em; - margin:0; -} -.topNav { - background-image:url(resources/background.gif); - background-repeat:repeat-x; - color:#FFFFFF; - float:left; - padding:0; - width:100%; - clear:right; - height:2.8em; - padding-top:10px; - overflow:hidden; -} -.bottomNav { - margin-top:10px; - background-image:url(resources/background.gif); - background-repeat:repeat-x; - color:#FFFFFF; - float:left; - padding:0; - width:100%; - clear:right; - height:2.8em; - padding-top:10px; - overflow:hidden; -} -.subNav { - background-color:#dee3e9; - border-bottom:1px solid #9eadc0; - float:left; - width:100%; - overflow:hidden; -} -.subNav div { - clear:left; - float:left; - padding:0 0 5px 6px; -} -ul.navList, ul.subNavList { - float:left; - margin:0 25px 0 0; - padding:0; -} -ul.navList li{ - list-style:none; - float:left; - padding:3px 6px; -} -ul.subNavList li{ - list-style:none; - float:left; - font-size:90%; -} -.topNav a:link, .topNav a:active, .topNav a:visited, .bottomNav a:link, .bottomNav a:active, .bottomNav a:visited { - color:#FFFFFF; - text-decoration:none; -} -.topNav a:hover, .bottomNav a:hover { - text-decoration:none; - color:#bb7a2a; -} -.navBarCell1Rev { - background-image:url(resources/tab.gif); - background-color:#a88834; - color:#FFFFFF; - margin: auto 5px; - border:1px solid #c9aa44; -} -/* -Page header and footer styles -*/ -.header, .footer { - clear:both; - margin:0 20px; - padding:5px 0 0 0; -} -.indexHeader { - margin:10px; - position:relative; -} -.indexHeader h1 { - font-size:1.3em; -} -.title { - color:#2c4557; - margin:10px 0; -} -.subTitle { - margin:5px 0 0 0; -} -.header ul { - margin:0 0 25px 0; - padding:0; -} -.footer ul { - margin:20px 0 5px 0; -} -.header ul li, .footer ul li { - list-style:none; - font-size:1.2em; -} -/* -Heading styles -*/ -div.details ul.blockList ul.blockList ul.blockList li.blockList h4, div.details ul.blockList ul.blockList ul.blockListLast li.blockList h4 { - background-color:#dee3e9; - border-top:1px solid #9eadc0; - border-bottom:1px solid #9eadc0; - margin:0 0 6px -8px; - padding:2px 5px; -} -ul.blockList ul.blockList ul.blockList li.blockList h3 { - background-color:#dee3e9; - border-top:1px solid #9eadc0; - border-bottom:1px solid #9eadc0; - margin:0 0 6px -8px; - padding:2px 5px; -} -ul.blockList ul.blockList li.blockList h3 { - padding:0; - margin:15px 0; -} -ul.blockList li.blockList h2 { - padding:0px 0 20px 0; -} -/* -Page layout container styles -*/ -.contentContainer, .sourceContainer, .classUseContainer, .serializedFormContainer, .constantValuesContainer { - clear:both; - padding:10px 20px; - position:relative; -} -.indexContainer { - margin:10px; - position:relative; - font-size:1.0em; -} -.indexContainer h2 { - font-size:1.1em; - padding:0 0 3px 0; -} -.indexContainer ul { - margin:0; - padding:0; -} -.indexContainer ul li { - list-style:none; -} -.contentContainer .description dl dt, .contentContainer .details dl dt, .serializedFormContainer dl dt { - font-size:1.1em; - font-weight:bold; - margin:10px 0 0 0; - color:#4E4E4E; -} -.contentContainer .description dl dd, .contentContainer .details dl dd, .serializedFormContainer dl dd { - margin:10px 0 10px 20px; -} -.serializedFormContainer dl.nameValue dt { - margin-left:1px; - font-size:1.1em; - display:inline; - font-weight:bold; -} -.serializedFormContainer dl.nameValue dd { - margin:0 0 0 1px; - font-size:1.1em; - display:inline; -} -/* -List styles -*/ -ul.horizontal li { - display:inline; - font-size:0.9em; -} -ul.inheritance { - margin:0; - padding:0; -} -ul.inheritance li { - display:inline; - list-style:none; -} -ul.inheritance li ul.inheritance { - margin-left:15px; - padding-left:15px; - padding-top:1px; -} -ul.blockList, ul.blockListLast { - margin:10px 0 10px 0; - padding:0; -} -ul.blockList li.blockList, ul.blockListLast li.blockList { - list-style:none; - margin-bottom:25px; -} -ul.blockList ul.blockList li.blockList, ul.blockList ul.blockListLast li.blockList { - padding:0px 20px 5px 10px; - border:1px solid #9eadc0; - background-color:#f9f9f9; -} -ul.blockList ul.blockList ul.blockList li.blockList, ul.blockList ul.blockList ul.blockListLast li.blockList { - padding:0 0 5px 8px; - background-color:#ffffff; - border:1px solid #9eadc0; - border-top:none; -} -ul.blockList ul.blockList ul.blockList ul.blockList li.blockList { - margin-left:0; - padding-left:0; - padding-bottom:15px; - border:none; - border-bottom:1px solid #9eadc0; -} -ul.blockList ul.blockList ul.blockList ul.blockList li.blockListLast { - list-style:none; - border-bottom:none; - padding-bottom:0; -} -table tr td dl, table tr td dl dt, table tr td dl dd { - margin-top:0; - margin-bottom:1px; -} -/* -Table styles -*/ -.contentContainer table, .classUseContainer table, .constantValuesContainer table { - border-bottom:1px solid #9eadc0; - width:100%; -} -.contentContainer ul li table, .classUseContainer ul li table, .constantValuesContainer ul li table { - width:100%; -} -.contentContainer .description table, .contentContainer .details table { - border-bottom:none; -} -.contentContainer ul li table th.colOne, .contentContainer ul li table th.colFirst, .contentContainer ul li table th.colLast, .classUseContainer ul li table th, .constantValuesContainer ul li table th, .contentContainer ul li table td.colOne, .contentContainer ul li table td.colFirst, .contentContainer ul li table td.colLast, .classUseContainer ul li table td, .constantValuesContainer ul li table td{ - vertical-align:top; - padding-right:20px; -} -.contentContainer ul li table th.colLast, .classUseContainer ul li table th.colLast,.constantValuesContainer ul li table th.colLast, -.contentContainer ul li table td.colLast, .classUseContainer ul li table td.colLast,.constantValuesContainer ul li table td.colLast, -.contentContainer ul li table th.colOne, .classUseContainer ul li table th.colOne, -.contentContainer ul li table td.colOne, .classUseContainer ul li table td.colOne { - padding-right:3px; -} -.overviewSummary caption, .packageSummary caption, .contentContainer ul.blockList li.blockList caption, .summary caption, .classUseContainer caption, .constantValuesContainer caption { - position:relative; - text-align:left; - background-repeat:no-repeat; - color:#FFFFFF; - font-weight:bold; - clear:none; - overflow:hidden; - padding:0px; - margin:0px; -} -caption a:link, caption a:hover, caption a:active, caption a:visited { - color:#FFFFFF; -} -.overviewSummary caption span, .packageSummary caption span, .contentContainer ul.blockList li.blockList caption span, .summary caption span, .classUseContainer caption span, .constantValuesContainer caption span { - white-space:nowrap; - padding-top:8px; - padding-left:8px; - display:block; - float:left; - background-image:url(resources/titlebar.gif); - height:18px; -} -.overviewSummary .tabEnd, .packageSummary .tabEnd, .contentContainer ul.blockList li.blockList .tabEnd, .summary .tabEnd, .classUseContainer .tabEnd, .constantValuesContainer .tabEnd { - width:10px; - background-image:url(resources/titlebar_end.gif); - background-repeat:no-repeat; - background-position:top right; - position:relative; - float:left; -} -ul.blockList ul.blockList li.blockList table { - margin:0 0 12px 0px; - width:100%; -} -.tableSubHeadingColor { - background-color: #EEEEFF; -} -.altColor { - background-color:#eeeeef; -} -.rowColor { - background-color:#ffffff; -} -.overviewSummary td, .packageSummary td, .contentContainer ul.blockList li.blockList td, .summary td, .classUseContainer td, .constantValuesContainer td { - text-align:left; - padding:3px 3px 3px 7px; -} -th.colFirst, th.colLast, th.colOne, .constantValuesContainer th { - background:#dee3e9; - border-top:1px solid #9eadc0; - border-bottom:1px solid #9eadc0; - text-align:left; - padding:3px 3px 3px 7px; -} -td.colOne a:link, td.colOne a:active, td.colOne a:visited, td.colOne a:hover, td.colFirst a:link, td.colFirst a:active, td.colFirst a:visited, td.colFirst a:hover, td.colLast a:link, td.colLast a:active, td.colLast a:visited, td.colLast a:hover, .constantValuesContainer td a:link, .constantValuesContainer td a:active, .constantValuesContainer td a:visited, .constantValuesContainer td a:hover { - font-weight:bold; -} -td.colFirst, th.colFirst { - border-left:1px solid #9eadc0; - white-space:nowrap; -} -td.colLast, th.colLast { - border-right:1px solid #9eadc0; -} -td.colOne, th.colOne { - border-right:1px solid #9eadc0; - border-left:1px solid #9eadc0; -} -table.overviewSummary { - padding:0px; - margin-left:0px; -} -table.overviewSummary td.colFirst, table.overviewSummary th.colFirst, -table.overviewSummary td.colOne, table.overviewSummary th.colOne { - width:25%; - vertical-align:middle; -} -table.packageSummary td.colFirst, table.overviewSummary th.colFirst { - width:25%; - vertical-align:middle; -} -/* -Content styles -*/ -.description pre { - margin-top:0; -} -.deprecatedContent { - margin:0; - padding:10px 0; -} -.docSummary { - padding:0; -} -/* -Formatting effect styles -*/ -.sourceLineNo { - color:green; - padding:0 30px 0 0; -} -h1.hidden { - visibility:hidden; - overflow:hidden; - font-size:.9em; -} -.block { - display:block; - margin:3px 0 0 0; -} -.strong { - font-weight:bold; -} diff --git a/dist/hibernate4-maven-plugin-1.0.5/xref-test/allclasses-frame.html b/dist/hibernate4-maven-plugin-1.0.5/xref-test/allclasses-frame.html deleted file mode 100644 index 4c39da54..00000000 --- a/dist/hibernate4-maven-plugin-1.0.5/xref-test/allclasses-frame.html +++ /dev/null @@ -1,20 +0,0 @@ - - - - - -- -1 package de.juplo.test; -2 -3 import java.io.BufferedReader; -4 import java.io.File; -5 import java.io.FileNotFoundException; -6 import java.io.FileReader; -7 import java.io.IOException; -8 -9 -10 public class FileComparator -11 { -12 private final File basedir; -13 private BufferedReader expectedReader; -14 private BufferedReader foundReader; -15 -16 public FileComparator(File basedir) -17 { -18 this.basedir = basedir; -19 } -20 -21 public boolean isEqual(final String expectedFile, final String foundFile) -22 throws -23 FileNotFoundException, -24 IOException -25 { -26 File file; -27 String expected, found; -28 -29 file = new File(basedir, expectedFile); -30 expectedReader = new BufferedReader(new FileReader(file)); -31 -32 file = new File(basedir, foundFile); -33 foundReader = new BufferedReader(new FileReader(file)); -34 -35 -36 while ((expected = expectedReader.readLine()) != null) -37 { -38 found = foundReader.readLine(); -39 if (!expected.equals(found)) -40 { -41 System.err.println("Mismatch!"); -42 System.err.println("Expected: " + expected); -43 System.err.println("Found: " + found); -44 return false; -45 } -46 } -47 -48 if ((found = foundReader.readLine()) != null) -49 { -50 System.err.println("Found more content than expected!"); -51 System.err.println("Starting with: " + found); -52 return false; -53 } -54 -55 return true; -56 } -57 } --
Class Summary | -
---|
- FileComparator - | -
- You don't have frames. Go here -
- -Packages | -
---|
- de.juplo.test - | -
- -1 package de.juplo.plugins.hibernate4; -2 -3 /* -4 * Copyright 2001-2005 The Apache Software Foundation. -5 * -6 * Licensed under the Apache License, Version 2.0 (the "License"); -7 * you may not use this file except in compliance with the License. -8 * You may obtain a copy of the License at -9 * -10 * http://www.apache.org/licenses/LICENSE-2.0 -11 * -12 * Unless required by applicable law or agreed to in writing, software -13 * distributed under the License is distributed on an "AS IS" BASIS, -14 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -15 * See the License for the specific language governing permissions and -16 * limitations under the License. -17 */ -18 -19 import com.pyx4j.log4j.MavenLogAppender; -20 import java.io.File; -21 import java.io.FileInputStream; -22 import java.io.FileNotFoundException; -23 import java.io.FileOutputStream; -24 import java.io.IOException; -25 import java.io.InputStream; -26 import java.io.ObjectInputStream; -27 import java.io.ObjectOutputStream; -28 import java.math.BigInteger; -29 import java.net.URL; -30 import java.net.URLClassLoader; -31 import java.security.MessageDigest; -32 import java.security.NoSuchAlgorithmException; -33 import java.sql.Connection; -34 import java.sql.Driver; -35 import java.sql.DriverManager; -36 import java.sql.DriverPropertyInfo; -37 import java.sql.SQLException; -38 import java.sql.SQLFeatureNotSupportedException; -39 import java.util.Comparator; -40 import java.util.Enumeration; -41 import java.util.HashMap; -42 import java.util.HashSet; -43 import java.util.List; -44 import java.util.Map; -45 import java.util.Map.Entry; -46 import java.util.Properties; -47 import java.util.Set; -48 import java.util.TreeSet; -49 import java.util.logging.Logger; -50 import java.util.regex.Matcher; -51 import java.util.regex.Pattern; -52 import javax.persistence.Embeddable; -53 import javax.persistence.Entity; -54 import javax.persistence.MappedSuperclass; -55 import org.apache.maven.artifact.Artifact; -56 import org.apache.maven.model.Resource; -57 import org.apache.maven.plugin.AbstractMojo; -58 import org.apache.maven.plugin.MojoExecutionException; -59 import org.apache.maven.plugin.MojoFailureException; -60 import org.apache.maven.project.MavenProject; -61 import org.hibernate.cfg.NamingStrategy; -62 import org.hibernate.envers.configuration.spi.AuditConfiguration; -63 import org.hibernate.tool.hbm2ddl.SchemaExport; -64 import org.hibernate.tool.hbm2ddl.SchemaExport.Type; -65 import org.hibernate.tool.hbm2ddl.Target; -66 import org.scannotation.AnnotationDB; -67 -68 -69 /** -70 * Goal which extracts the hibernate-mapping-configuration and -71 * exports an according SQL-database-schema. -72 * -73 * @goal export -74 * @phase process-classes -75 * @threadSafe -76 * @requiresDependencyResolution runtime -77 */ -78 public class Hbm2DdlMojo extends AbstractMojo -79 { -80 public final static String EXPORT_SKIPPED_PROPERTY = "hibernate.export.skipped"; -81 -82 public final static String DRIVER_CLASS = "hibernate.connection.driver_class"; -83 public final static String URL = "hibernate.connection.url"; -84 public final static String USERNAME = "hibernate.connection.username"; -85 public final static String PASSWORD = "hibernate.connection.password"; -86 public final static String DIALECT = "hibernate.dialect"; -87 public final static String NAMING_STRATEGY="hibernate.ejb.naming_strategy"; -88 public final static String ENVERS = "hibernate.export.envers"; -89 -90 public final static String MD5S = "hibernate4-generatedschema.md5s"; -91 -92 private final static Pattern split = Pattern.compile("[^,\\s]+"); -93 -94 -95 /** -96 * The maven project. -97 * <p> -98 * Only needed internally. -99 * -100 * @parameter property="project" -101 * @required -102 * @readonly -103 */ -104 private MavenProject project; -105 -106 /** -107 * Build-directory. -108 * <p> -109 * Only needed internally. -110 * -111 * @parameter property="project.build.directory" -112 * @required -113 * @readonly -114 */ -115 private String buildDirectory; -116 -117 /** -118 * Classes-Directory to scan. -119 * <p> -120 * This parameter defaults to the maven build-output-directory for classes. -121 * Additionally, all dependencies are scanned for annotated classes. -122 * -123 * @parameter property="project.build.outputDirectory" -124 * @since 1.0 -125 */ -126 private String outputDirectory; -127 -128 /** -129 * Whether to scan test-classes too, or not. -130 * <p> -131 * If this parameter is set to <code>true</code> the test-classes of the -132 * artifact will be scanned for hibernate-annotated classes additionally. -133 * -134 * @parameter property="hibernate.export.scan_testclasses" default-value="false" -135 * @since 1.0.1 -136 */ -137 private boolean scanTestClasses; -138 -139 /** -140 * Dependency-Scopes, that should be scanned for annotated classes. -141 * <p> -142 * By default, only dependencies in the scope <code>compile</code> are -143 * scanned for annotated classes. Multiple scopes can be seperated by -144 * white space or commas. -145 * <p> -146 * If you do not want any dependencies to be scanned for annotated -147 * classes, set this parameter to <code>none</code>. -148 * <p> -149 * The plugin does not scan for annotated classes in transitive -150 * dependencies. If some of your annotated classes are hidden in a -151 * transitive dependency, you can simply add that dependency explicitly. -152 * -153 * @parameter property="hibernate.export.scan_dependencies" default-value="compile" -154 * @since 1.0.3 -155 */ -156 private String scanDependencies; -157 -158 /** -159 * Test-Classes-Directory to scan. -160 * <p> -161 * This parameter defaults to the maven build-output-directory for -162 * test-classes. -163 * <p> -164 * This parameter is only used, when <code>scanTestClasses</code> is set -165 * to <code>true</code>! -166 * -167 * @parameter property="project.build.testOutputDirectory" -168 * @since 1.0.2 -169 */ -170 private String testOutputDirectory; -171 -172 /** -173 * Skip execution -174 * <p> -175 * If set to <code>true</code>, the execution is skipped. -176 * <p> -177 * A skipped execution is signaled via the maven-property -178 * <code>${hibernate.export.skipped}</code>. -179 * <p> -180 * The execution is skipped automatically, if no modified or newly added -181 * annotated classes are found and the dialect was not changed. -182 * -183 * @parameter property="hibernate.skip" default-value="${maven.test.skip}" -184 * @since 1.0 -185 */ -186 private boolean skip; -187 -188 /** -189 * Force execution -190 * <p> -191 * Force execution, even if no modified or newly added annotated classes -192 * where found and the dialect was not changed. -193 * <p> -194 * <code>skip</code> takes precedence over <code>force</code>. -195 * -196 * @parameter property="hibernate.export.force" default-value="false" -197 * @since 1.0 -198 */ -199 private boolean force; -200 -201 /** -202 * SQL-Driver name. -203 * -204 * @parameter property="hibernate.connection.driver_class" -205 * @since 1.0 -206 */ -207 private String driverClassName; -208 -209 /** -210 * Database URL. -211 * -212 * @parameter property="hibernate.connection.url" -213 * @since 1.0 -214 */ -215 private String url; -216 -217 /** -218 * Database username -219 * -220 * @parameter property="hibernate.connection.username" -221 * @since 1.0 -222 */ -223 private String username; -224 -225 /** -226 * Database password -227 * -228 * @parameter property="hibernate.connection.password" -229 * @since 1.0 -230 */ -231 private String password; -232 -233 /** -234 * Hibernate dialect. -235 * -236 * @parameter property="hibernate.dialect" -237 * @since 1.0 -238 */ -239 private String hibernateDialect; -240 -241 /** -242 * Hibernate Naming Strategy -243 * -244 * @parameter property="hibernate.ejb.naming_strategy" -245 * @since 1.0.2 -246 */ -247 private String hibernateNamingStrategy; -248 -249 /** -250 * Path to Hibernate configuration file. -251 * -252 * @parameter default-value="${project.build.outputDirectory}/hibernate.properties" -253 * @since 1.0 -254 */ -255 private String hibernateProperties; -256 -257 /** -258 * List of Hibernate-Mapping-Files (XML). -259 * Multiple files can be separated with white-spaces and/or commas. -260 * -261 * @parameter property="hibernate.mapping" -262 * @since 1.0.2 -263 */ -264 private String hibernateMapping; -265 -266 /** -267 * Target of execution: -268 * <ul> -269 * <li><strong>NONE</strong> only export schema to SQL-script (forces execution, signals skip)</li> -270 * <li><strong>EXPORT</strong> create database (<strong>DEFAULT!</strong>). forces execution, signals skip)</li> -271 * <li><strong>SCRIPT</strong> export schema to SQL-script and print it to STDOUT</li> -272 * <li><strong>BOTH</strong></li> -273 * </ul> -274 * -275 * A database connection is only needed for EXPORT and BOTH, but a -276 * Hibernate-Dialect must always be chosen. -277 * -278 * @parameter property="hibernate.export.target" default-value="EXPORT" -279 * @since 1.0 -280 */ -281 private String target; -282 -283 /** -284 * Type of execution. -285 * <ul> -286 * <li><strong>NONE</strong> do nothing - just validate the configuration</li> -287 * <li><strong>CREATE</strong> create database-schema</li> -288 * <li><strong>DROP</strong> drop database-schema</li> -289 * <li><strong>BOTH</strong> (<strong>DEFAULT!</strong>)</li> -290 * </ul> -291 * -292 * If NONE is choosen, no databaseconnection is needed. -293 * -294 * @parameter property="hibernate.export.type" default-value="BOTH" -295 * @since 1.0 -296 */ -297 private String type; -298 -299 /** -300 * Output file. -301 * -302 * @parameter property="hibernate.export.schema.filename" default-value="${project.build.directory}/schema.sql" -303 * @since 1.0 -304 */ -305 private String outputFile; -306 -307 /** -308 * Delimiter in output-file. -309 * -310 * @parameter property="hibernate.export.schema.delimiter" default-value=";" -311 * @since 1.0 -312 */ -313 private String delimiter; -314 -315 /** -316 * Format output-file. -317 * -318 * @parameter property="hibernate.export.schema.format" default-value="true" -319 * @since 1.0 -320 */ -321 private boolean format; -322 -323 /** -324 * Generate envers schema for auditing tables. -325 * -326 * @parameter property="hibernate.export.envers" default-value="false" -327 * @since 1.0.3 -328 */ -329 private boolean envers; -330 -331 -332 @Override -333 public void execute() -334 throws -335 MojoFailureException, -336 MojoExecutionException -337 { -338 if (skip) -339 { -340 getLog().info("Execution of hibernate4-maven-plugin:export was skipped!"); -341 project.getProperties().setProperty(EXPORT_SKIPPED_PROPERTY, "true"); -342 return; -343 } -344 -345 Map<String,String> md5s; -346 boolean modified = false; -347 File saved = new File(buildDirectory + File.separator + MD5S); -348 -349 if (saved.isFile() && saved.length() > 0) -350 { -351 try -352 { -353 FileInputStream fis = new FileInputStream(saved); -354 ObjectInputStream ois = new ObjectInputStream(fis); -355 md5s = (HashMap<String,String>)ois.readObject(); -356 ois.close(); -357 } -358 catch (Exception e) -359 { -360 md5s = new HashMap<String,String>(); -361 getLog().warn("Cannot read timestamps from saved: " + e); -362 } -363 } -364 else -365 { -366 md5s = new HashMap<String,String>(); -367 try -368 { -369 saved.createNewFile(); -370 } -371 catch (IOException e) -372 { -373 getLog().debug("Cannot create file \"" + saved.getPath() + "\" for timestamps: " + e); -374 } -375 } -376 -377 ClassLoader classLoader = null; -378 try -379 { -380 getLog().debug("Creating ClassLoader for project-dependencies..."); -381 List<String> classpathFiles = project.getCompileClasspathElements(); -382 if (scanTestClasses) -383 classpathFiles.addAll(project.getTestClasspathElements()); -384 URL[] urls = new URL[classpathFiles.size()]; -385 for (int i = 0; i < classpathFiles.size(); ++i) -386 { -387 getLog().debug("Dependency: " + classpathFiles.get(i)); -388 urls[i] = new File(classpathFiles.get(i)).toURI().toURL(); -389 } -390 classLoader = new URLClassLoader(urls, getClass().getClassLoader()); -391 } -392 catch (Exception e) -393 { -394 getLog().error("Error while creating ClassLoader!", e); -395 throw new MojoExecutionException(e.getMessage()); -396 } -397 -398 Set<Class<?>> classes = -399 new TreeSet<Class<?>>( -400 new Comparator<Class<?>>() { -401 @Override -402 public int compare(Class<?> a, Class<?> b) -403 { -404 return a.getName().compareTo(b.getName()); -405 } -406 } -407 ); -408 -409 try -410 { -411 AnnotationDB db = new AnnotationDB(); -412 File dir = new File(outputDirectory); -413 if (dir.exists()) -414 { -415 getLog().info("Scanning directory " + outputDirectory + " for annotated classes..."); -416 URL dirUrl = dir.toURI().toURL(); -417 db.scanArchives(dirUrl); -418 } -419 if (scanTestClasses) -420 { -421 dir = new File(testOutputDirectory); -422 if (dir.exists()) -423 { -424 getLog().info("Scanning directory " + testOutputDirectory + " for annotated classes..."); -425 URL dirUrl = dir.toURI().toURL(); -426 db.scanArchives(dirUrl); -427 } -428 } -429 if (scanDependencies != null) -430 { -431 Matcher matcher = split.matcher(scanDependencies); -432 while (matcher.find()) -433 { -434 getLog().info("Scanning dependencies for scope " + matcher.group()); -435 for (Artifact artifact : project.getDependencyArtifacts()) -436 { -437 if (!artifact.getScope().equalsIgnoreCase(matcher.group())) -438 continue; -439 if (artifact.getFile() == null) -440 { -441 getLog().warn( -442 "Cannot scan dependency " + -443 artifact.getId() + -444 ": no JAR-file available!" -445 ); -446 continue; -447 } -448 getLog().info( -449 "Scanning dependency " + -450 artifact.getId() + -451 " for annotated classes..." -452 ); -453 db.scanArchives(artifact.getFile().toURI().toURL()); -454 } -455 } -456 } -457 -458 Set<String> classNames = new HashSet<String>(); -459 if (db.getAnnotationIndex().containsKey(Entity.class.getName())) -460 classNames.addAll(db.getAnnotationIndex().get(Entity.class.getName())); -461 if (db.getAnnotationIndex().containsKey(MappedSuperclass.class.getName())) -462 classNames.addAll(db.getAnnotationIndex().get(MappedSuperclass.class.getName())); -463 if (db.getAnnotationIndex().containsKey(Embeddable.class.getName())) -464 classNames.addAll(db.getAnnotationIndex().get(Embeddable.class.getName())); -465 -466 MessageDigest digest = java.security.MessageDigest.getInstance("MD5"); -467 for (String name : classNames) -468 { -469 Class<?> annotatedClass = classLoader.loadClass(name); -470 classes.add(annotatedClass); -471 String resourceName = annotatedClass.getName(); -472 resourceName = resourceName.substring(resourceName.lastIndexOf(".") + 1, resourceName.length()) + ".class"; -473 InputStream is = -474 annotatedClass -475 .getResourceAsStream(resourceName); -476 byte[] buffer = new byte[1024*4]; // copy data in 4MB-chunks -477 int i; -478 while((i = is.read(buffer)) > -1) -479 digest.update(buffer, 0, i); -480 is.close(); -481 byte[] bytes = digest.digest(); -482 BigInteger bi = new BigInteger(1, bytes); -483 String newMd5 = String.format("%0" + (bytes.length << 1) + "x", bi); -484 String oldMd5 = !md5s.containsKey(name) ? "" : md5s.get(name); -485 if (!newMd5.equals(oldMd5)) -486 { -487 getLog().debug("Found new or modified annotated class: " + name); -488 modified = true; -489 md5s.put(name, newMd5); -490 } -491 else -492 { -493 getLog().debug(oldMd5 + " -> class unchanged: " + name); -494 } -495 } -496 } -497 catch (ClassNotFoundException e) -498 { -499 getLog().error("Error while adding annotated classes!", e); -500 throw new MojoExecutionException(e.getMessage()); -501 } -502 catch (Exception e) -503 { -504 getLog().error("Error while scanning!", e); -505 throw new MojoFailureException(e.getMessage()); -506 } -507 -508 if (classes.isEmpty()) -509 { -510 if (hibernateMapping == null || hibernateMapping.isEmpty()) -511 throw new MojoFailureException("No annotated classes found in directory " + outputDirectory); -512 } -513 else -514 { -515 getLog().debug("Detected classes with mapping-annotations:"); -516 for (Class<?> annotatedClass : classes) -517 getLog().debug(" " + annotatedClass.getName()); -518 } -519 -520 -521 Properties properties = new Properties(); -522 -523 /** Try to read configuration from properties-file */ -524 try -525 { -526 File file = new File(hibernateProperties); -527 if (file.exists()) -528 { -529 getLog().info("Reading properties from file " + hibernateProperties + "..."); -530 properties.load(new FileInputStream(file)); -531 } -532 else -533 getLog().info("No hibernate-properties-file found! (Checked path: " + hibernateProperties + ")"); -534 } -535 catch (IOException e) -536 { -537 getLog().error("Error while reading properties!", e); -538 throw new MojoExecutionException(e.getMessage()); -539 } -540 -541 /** Overwrite values from properties-file or set, if given */ -542 if (driverClassName != null) -543 { -544 if (properties.containsKey(DRIVER_CLASS)) -545 getLog().debug( -546 "Overwriting property " + -547 DRIVER_CLASS + "=" + properties.getProperty(DRIVER_CLASS) + -548 " with the value " + driverClassName -549 ); -550 else -551 getLog().debug("Using the value " + driverClassName); -552 properties.setProperty(DRIVER_CLASS, driverClassName); -553 } -554 if (url != null) -555 { -556 if (properties.containsKey(URL)) -557 getLog().debug( -558 "Overwriting property " + -559 URL + "=" + properties.getProperty(URL) + -560 " with the value " + url -561 ); -562 else -563 getLog().debug("Using the value " + url); -564 properties.setProperty(URL, url); -565 } -566 if (username != null) -567 { -568 if (properties.containsKey(USERNAME)) -569 getLog().debug( -570 "Overwriting property " + -571 USERNAME + "=" + properties.getProperty(USERNAME) + -572 " with the value " + username -573 ); -574 else -575 getLog().debug("Using the value " + username); -576 properties.setProperty(USERNAME, username); -577 } -578 if (password != null) -579 { -580 if (properties.containsKey(PASSWORD)) -581 getLog().debug( -582 "Overwriting property " + -583 PASSWORD + "=" + properties.getProperty(PASSWORD) + -584 " with value " + password -585 ); -586 else -587 getLog().debug("Using value " + password + " for property " + PASSWORD); -588 properties.setProperty(PASSWORD, password); -589 } -590 if (hibernateDialect != null) -591 { -592 if (properties.containsKey(DIALECT)) -593 getLog().debug( -594 "Overwriting property " + -595 DIALECT + "=" + properties.getProperty(DIALECT) + -596 " with value " + hibernateDialect -597 ); -598 else -599 getLog().debug( -600 "Using value " + hibernateDialect + " for property " + DIALECT -601 ); -602 properties.setProperty(DIALECT, hibernateDialect); -603 } -604 else -605 { -606 hibernateDialect = properties.getProperty(DIALECT); -607 } -608 if ( hibernateNamingStrategy != null ) -609 { -610 if ( properties.contains(NAMING_STRATEGY)) -611 getLog().debug( -612 "Overwriting property " + -613 NAMING_STRATEGY + "=" + properties.getProperty(NAMING_STRATEGY) + -614 " with value " + hibernateNamingStrategy -615 ); -616 else -617 getLog().debug( -618 "Using value " + hibernateNamingStrategy + " for property " + -619 NAMING_STRATEGY -620 ); -621 properties.setProperty(NAMING_STRATEGY, hibernateNamingStrategy); -622 } -623 -624 /** The generated SQL varies with the dialect! */ -625 if (md5s.containsKey(DIALECT)) -626 { -627 String dialect = properties.getProperty(DIALECT); -628 if (md5s.get(DIALECT).equals(dialect)) -629 getLog().debug("SQL-dialect unchanged."); -630 else -631 { -632 modified = true; -633 if (dialect == null) -634 { -635 getLog().debug("SQL-dialect was unset."); -636 md5s.remove(DIALECT); -637 } -638 else -639 { -640 getLog().debug("SQL-dialect changed: " + dialect); -641 md5s.put(DIALECT, dialect); -642 } -643 } -644 } -645 else -646 { -647 String dialect = properties.getProperty(DIALECT); -648 if (dialect != null) -649 { -650 modified = true; -651 md5s.put(DIALECT, properties.getProperty(DIALECT)); -652 } -653 } -654 -655 /** The generated SQL varies with the envers-configuration */ -656 if (md5s.get(ENVERS) != null) -657 { -658 if (md5s.get(ENVERS).equals(Boolean.toString(envers))) -659 getLog().debug("Envers-Configuration unchanged. Enabled: " + envers); -660 else -661 { -662 getLog().debug("Envers-Configuration changed. Enabled: " + envers); -663 modified = true; -664 md5s.put(ENVERS, Boolean.toString(envers)); -665 } -666 } -667 else -668 { -669 modified = true; -670 md5s.put(ENVERS, Boolean.toString(envers)); -671 } -672 -673 if (properties.isEmpty()) -674 { -675 getLog().error("No properties set!"); -676 throw new MojoFailureException("Hibernate configuration is missing!"); -677 } -678 -679 final ValidationConfiguration config = new ValidationConfiguration(hibernateDialect); -680 -681 config.setProperties(properties); -682 -683 if ( properties.containsKey(NAMING_STRATEGY)) -684 { -685 String namingStrategy = properties.getProperty(NAMING_STRATEGY); -686 getLog().debug("Explicitly set NamingStrategy: " + namingStrategy); -687 try -688 { -689 @SuppressWarnings("unchecked") -690 Class<NamingStrategy> namingStrategyClass = (Class<NamingStrategy>) Class.forName(namingStrategy); -691 config.setNamingStrategy(namingStrategyClass.newInstance()); -692 } -693 catch (Exception e) -694 { -695 getLog().error("Error setting NamingStrategy", e); -696 throw new MojoExecutionException(e.getMessage()); -697 } -698 } -699 -700 ClassLoader contextClassLoader = Thread.currentThread().getContextClassLoader(); -701 Connection connection = null; -702 MavenLogAppender.startPluginLog(this); -703 try -704 { -705 /** -706 * Change class-loader of current thread, so that hibernate can -707 * see all dependencies! -708 */ -709 Thread.currentThread().setContextClassLoader(classLoader); -710 -711 getLog().debug("Adding annotated classes to hibernate-mapping-configuration..."); -712 // build annotated packages -713 Set<String> packages = new HashSet<String>(); -714 for (Class<?> annotatedClass : classes) -715 { -716 String packageName = annotatedClass.getPackage().getName(); -717 if (!packages.contains(packageName)) -718 { -719 getLog().debug("Add package " + packageName); -720 packages.add(packageName); -721 config.addPackage(packageName); -722 getLog().debug("type definintions" + config.getTypeDefs()); -723 } -724 getLog().debug("Class " + annotatedClass); -725 config.addAnnotatedClass(annotatedClass); -726 } -727 -728 if (hibernateMapping != null) -729 { -730 try -731 { -732 MessageDigest digest = java.security.MessageDigest.getInstance("MD5"); -733 for (String filename : hibernateMapping.split("[\\s,]+")) -734 { -735 // First try the filename as absolute/relative path -736 File file = new File(filename); -737 if (!file.exists()) -738 { -739 // If the file was not found, search for it in the resource-directories -740 for (Resource resource : project.getResources()) -741 { -742 file = new File(resource.getDirectory() + File.separator + filename); -743 if (file.exists()) -744 break; -745 } -746 } -747 if (file != null && file.exists()) -748 { -749 InputStream is = new FileInputStream(file); -750 byte[] buffer = new byte[1024*4]; // copy data in 4MB-chunks -751 int i; -752 while((i = is.read(buffer)) > -1) -753 digest.update(buffer, 0, i); -754 is.close(); -755 byte[] bytes = digest.digest(); -756 BigInteger bi = new BigInteger(1, bytes); -757 String newMd5 = String.format("%0" + (bytes.length << 1) + "x", bi); -758 String oldMd5 = !md5s.containsKey(filename) ? "" : md5s.get(filename); -759 if (!newMd5.equals(oldMd5)) -760 { -761 getLog().debug("Found new or modified mapping-file: " + filename); -762 modified = true; -763 md5s.put(filename, newMd5); -764 } -765 else -766 { -767 getLog().debug(oldMd5 + " -> mapping-file unchanged: " + filename); -768 } -769 getLog().debug("Adding mappings from XML-configurationfile: " + file); -770 config.addFile(file); -771 } -772 else -773 throw new MojoFailureException("File " + filename + " could not be found in any of the configured resource-directories!"); -774 } -775 } -776 catch (NoSuchAlgorithmException e) -777 { -778 throw new MojoFailureException("Cannot calculate MD5 sums!", e); -779 } -780 catch (FileNotFoundException e) -781 { -782 throw new MojoFailureException("Cannot calculate MD5 sums!", e); -783 } -784 catch (IOException e) -785 { -786 throw new MojoFailureException("Cannot calculate MD5 sums!", e); -787 } -788 } -789 -790 Target target = null; -791 try -792 { -793 target = Target.valueOf(this.target.toUpperCase()); -794 } -795 catch (IllegalArgumentException e) -796 { -797 getLog().error("Invalid value for configuration-option \"target\": " + this.target); -798 getLog().error("Valid values are: NONE, SCRIPT, EXPORT, BOTH"); -799 throw new MojoExecutionException("Invalid value for configuration-option \"target\""); -800 } -801 Type type = null; -802 try -803 { -804 type = Type.valueOf(this.type.toUpperCase()); -805 } -806 catch (IllegalArgumentException e) -807 { -808 getLog().error("Invalid value for configuration-option \"type\": " + this.type); -809 getLog().error("Valid values are: NONE, CREATE, DROP, BOTH"); -810 throw new MojoExecutionException("Invalid value for configuration-option \"type\""); -811 } -812 -813 if (target.equals(Target.SCRIPT) || target.equals(Target.NONE)) -814 { -815 project.getProperties().setProperty(EXPORT_SKIPPED_PROPERTY, "true"); -816 } -817 if ( -818 !modified -819 && !target.equals(Target.SCRIPT) -820 && !target.equals(Target.NONE) -821 && !force -822 ) -823 { -824 getLog().info("No modified annotated classes or mapping-files found and dialect unchanged."); -825 getLog().info("Skipping schema generation!"); -826 project.getProperties().setProperty(EXPORT_SKIPPED_PROPERTY, "true"); -827 return; -828 } -829 -830 getLog().info("Gathered hibernate-configuration (turn on debugging for details):"); -831 for (Entry<Object,Object> entry : properties.entrySet()) -832 getLog().info(" " + entry.getKey() + " = " + entry.getValue()); -833 -834 try -835 { -836 /** -837 * The connection must be established outside of hibernate, because -838 * hibernate does not use the context-classloader of the current -839 * thread and, hence, would not be able to resolve the driver-class! -840 */ -841 getLog().debug("Target: " + target + ", Type: " + type); -842 switch (target) -843 { -844 case EXPORT: -845 case BOTH: -846 switch (type) -847 { -848 case CREATE: -849 case DROP: -850 case BOTH: -851 Class driverClass = classLoader.loadClass(properties.getProperty(DRIVER_CLASS)); -852 getLog().debug("Registering JDBC-driver " + driverClass.getName()); -853 DriverManager.registerDriver(new DriverProxy((Driver)driverClass.newInstance())); -854 getLog().debug( -855 "Opening JDBC-connection to " -856 + properties.getProperty(URL) -857 + " as " -858 + properties.getProperty(USERNAME) -859 + " with password " -860 + properties.getProperty(PASSWORD) -861 ); -862 connection = DriverManager.getConnection( -863 properties.getProperty(URL), -864 properties.getProperty(USERNAME), -865 properties.getProperty(PASSWORD) -866 ); -867 } -868 } -869 } -870 catch (ClassNotFoundException e) -871 { -872 getLog().error("Dependency for driver-class " + properties.getProperty(DRIVER_CLASS) + " is missing!"); -873 throw new MojoExecutionException(e.getMessage()); -874 } -875 catch (Exception e) -876 { -877 getLog().error("Cannot establish connection to database!"); -878 Enumeration<Driver> drivers = DriverManager.getDrivers(); -879 if (!drivers.hasMoreElements()) -880 getLog().error("No drivers registered!"); -881 while (drivers.hasMoreElements()) -882 getLog().debug("Driver: " + drivers.nextElement()); -883 throw new MojoExecutionException(e.getMessage()); -884 } -885 -886 config.buildMappings(); -887 -888 if (envers) -889 { -890 getLog().info("Automatic auditing via hibernate-envers enabled!"); -891 AuditConfiguration.getFor(config); -892 } -893 -894 SchemaExport export = new SchemaExport(config, connection); -895 export.setDelimiter(delimiter); -896 export.setFormat(format); -897 -898 File outF = new File(outputFile); -899 -900 if (!outF.isAbsolute()) -901 { -902 // Interpret relative file path relative to build directory -903 outF = new File(buildDirectory, outputFile); -904 getLog().info("Adjusted relative path, resulting path is " + outF.getPath()); -905 } -906 -907 // Ensure that directory path for specified file exists -908 File outFileParentDir = outF.getParentFile(); -909 if (null != outFileParentDir && !outFileParentDir.exists()) -910 { -911 try -912 { -913 getLog().info("Creating directory path for output file:" + outFileParentDir.getPath()); -914 outFileParentDir.mkdirs(); -915 } -916 catch (Exception e) -917 { -918 getLog().error("Error creating directory path for output file: " + e.getLocalizedMessage()); -919 } -920 } -921 -922 export.setOutputFile(outF.getPath()); -923 export.execute(target, type); -924 -925 for (Object exception : export.getExceptions()) -926 getLog().debug(exception.toString()); -927 } -928 finally -929 { -930 /** Stop Log-Capturing */ -931 MavenLogAppender.endPluginLog(this); -932 -933 /** Restore the old class-loader (TODO: is this really necessary?) */ -934 Thread.currentThread().setContextClassLoader(contextClassLoader); -935 -936 /** Close the connection */ -937 try -938 { -939 if (connection != null) -940 connection.close(); -941 } -942 catch (SQLException e) -943 { -944 getLog().error("Error while closing connection: " + e.getMessage()); -945 } -946 } -947 -948 /** Write md5-sums for annotated classes to file */ -949 try -950 { -951 FileOutputStream fos = new FileOutputStream(saved); -952 ObjectOutputStream oos = new ObjectOutputStream(fos); -953 oos.writeObject(md5s); -954 oos.close(); -955 fos.close(); -956 } -957 catch (Exception e) -958 { -959 getLog().error("Cannot write md5-sums to file: " + e); -960 } -961 } -962 -963 /** -964 * Needed, because DriverManager won't pick up drivers, that were not -965 * loaded by the system-classloader! -966 * See: -967 * http://stackoverflow.com/questions/288828/how-to-use-a-jdbc-driver-fromodifiedm-an-arbitrary-location -968 */ -969 static final class DriverProxy implements Driver -970 { -971 private final Driver target; -972 -973 DriverProxy(Driver target) -974 { -975 if (target == null) -976 throw new NullPointerException(); -977 this.target = target; -978 } -979 -980 public java.sql.Driver getTarget() -981 { -982 return target; -983 } -984 -985 @Override -986 public boolean acceptsURL(String url) throws SQLException -987 { -988 return target.acceptsURL(url); -989 } -990 -991 @Override -992 public java.sql.Connection connect( -993 String url, -994 java.util.Properties info -995 ) -996 throws -997 SQLException -998 { -999 return target.connect(url, info); -1000 } -1001 -1002 @Override -1003 public int getMajorVersion() -1004 { -1005 return target.getMajorVersion(); -1006 } -1007 -1008 @Override -1009 public int getMinorVersion() -1010 { -1011 return target.getMinorVersion(); -1012 } -1013 -1014 @Override -1015 public DriverPropertyInfo[] getPropertyInfo( -1016 String url, -1017 Properties info -1018 ) -1019 throws -1020 SQLException -1021 { -1022 return target.getPropertyInfo(url, info); -1023 } -1024 -1025 @Override -1026 public boolean jdbcCompliant() -1027 { -1028 return target.jdbcCompliant(); -1029 } -1030 -1031 /** -1032 * This Method cannot be annotated with @Override, becaus the plugin -1033 * will not compile then under Java 1.6! -1034 */ -1035 public Logger getParentLogger() throws SQLFeatureNotSupportedException -1036 { -1037 throw new SQLFeatureNotSupportedException("Not supported, for backward-compatibility with Java 1.6"); -1038 } -1039 -1040 @Override -1041 public String toString() -1042 { -1043 return "Proxy: " + target; -1044 } -1045 -1046 @Override -1047 public int hashCode() -1048 { -1049 return target.hashCode(); -1050 } -1051 -1052 @Override -1053 public boolean equals(Object obj) -1054 { -1055 if (!(obj instanceof DriverProxy)) -1056 return false; -1057 DriverProxy other = (DriverProxy) obj; -1058 return this.target.equals(other.target); -1059 } -1060 } -1061 } --
- -1 package de.juplo.plugins.hibernate4; -2 -3 import org.apache.maven.plugin.AbstractMojo; -4 import org.apache.maven.plugin.MojoExecutionException; -5 -6 import org.w3c.dom.Document; -7 import org.w3c.dom.Element; -8 import org.w3c.dom.Node; -9 import org.w3c.dom.NodeList; -10 import org.xml.sax.SAXException; -11 -12 import javax.xml.parsers.DocumentBuilder; -13 import javax.xml.parsers.DocumentBuilderFactory; -14 import javax.xml.parsers.ParserConfigurationException; -15 import java.io.IOException; -16 import java.io.InputStream; -17 import java.util.ArrayList; -18 import java.util.Iterator; -19 import java.util.List; -20 -21 /** -22 * Display help information on hibernate4-maven-plugin.<br/> -23 * Call <code>mvn hibernate4:help -Ddetail=true -Dgoal=<goal-name></code> to display parameter details. -24 * @author -25 * @version -26 * @goal help -27 * @requiresProject false -28 * @threadSafe -29 */ -30 public class HelpMojo -31 extends AbstractMojo -32 { -33 /** -34 * If <code>true</code>, display all settable properties for each goal. -35 * -36 * @parameter property="detail" default-value="false" -37 */ -38 private boolean detail; -39 -40 /** -41 * The name of the goal for which to show help. If unspecified, all goals will be displayed. -42 * -43 * @parameter property="goal" -44 */ -45 private java.lang.String goal; -46 -47 /** -48 * The maximum length of a display line, should be positive. -49 * -50 * @parameter property="lineLength" default-value="80" -51 */ -52 private int lineLength; -53 -54 /** -55 * The number of spaces per indentation level, should be positive. -56 * -57 * @parameter property="indentSize" default-value="2" -58 */ -59 private int indentSize; -60 -61 // groupId/artifactId/plugin-help.xml -62 private static final String PLUGIN_HELP_PATH = "/META-INF/maven/de.juplo/hibernate4-maven-plugin/plugin-help.xml"; -63 -64 private Document build() -65 throws MojoExecutionException -66 { -67 getLog().debug( "load plugin-help.xml: " + PLUGIN_HELP_PATH ); -68 InputStream is = getClass().getResourceAsStream( PLUGIN_HELP_PATH ); -69 try -70 { -71 DocumentBuilderFactory dbFactory = DocumentBuilderFactory.newInstance(); -72 DocumentBuilder dBuilder = dbFactory.newDocumentBuilder(); -73 return dBuilder.parse( is ); -74 } -75 catch ( IOException e ) -76 { -77 throw new MojoExecutionException( e.getMessage(), e ); -78 } -79 catch ( ParserConfigurationException e ) -80 { -81 throw new MojoExecutionException( e.getMessage(), e ); -82 } -83 catch ( SAXException e ) -84 { -85 throw new MojoExecutionException( e.getMessage(), e ); -86 } -87 } -88 -89 /** -90 * {@inheritDoc} -91 */ -92 public void execute() -93 throws MojoExecutionException -94 { -95 if ( lineLength <= 0 ) -96 { -97 getLog().warn( "The parameter 'lineLength' should be positive, using '80' as default." ); -98 lineLength = 80; -99 } -100 if ( indentSize <= 0 ) -101 { -102 getLog().warn( "The parameter 'indentSize' should be positive, using '2' as default." ); -103 indentSize = 2; -104 } -105 -106 Document doc = build(); -107 -108 StringBuilder sb = new StringBuilder(); -109 Node plugin = getSingleChild( doc, "plugin" ); -110 -111 -112 String name = getValue( plugin, "name" ); -113 String version = getValue( plugin, "version" ); -114 String id = getValue( plugin, "groupId" ) + ":" + getValue( plugin, "artifactId" ) + ":" + version; -115 if ( isNotEmpty( name ) && !name.contains( id ) ) -116 { -117 append( sb, name + " " + version, 0 ); -118 } -119 else -120 { -121 if ( isNotEmpty( name ) ) -122 { -123 append( sb, name, 0 ); -124 } -125 else -126 { -127 append( sb, id, 0 ); -128 } -129 } -130 append( sb, getValue( plugin, "description" ), 1 ); -131 append( sb, "", 0 ); -132 -133 //<goalPrefix>plugin</goalPrefix> -134 String goalPrefix = getValue( plugin, "goalPrefix" ); -135 -136 Node mojos1 = getSingleChild( plugin, "mojos" ); -137 -138 List<Node> mojos = findNamedChild( mojos1, "mojo" ); -139 -140 if ( goal == null || goal.length() <= 0 ) -141 { -142 append( sb, "This plugin has " + mojos.size() + ( mojos.size() > 1 ? " goals:" : " goal:" ), 0 ); -143 append( sb, "", 0 ); -144 } -145 -146 for ( Node mojo : mojos ) -147 { -148 writeGoal( sb, goalPrefix, (Element) mojo ); -149 } -150 -151 if ( getLog().isInfoEnabled() ) -152 { -153 getLog().info( sb.toString() ); -154 } -155 } -156 -157 -158 private static boolean isNotEmpty( String string ) -159 { -160 return string != null && string.length() > 0; -161 } -162 -163 private String getValue( Node node, String elementName ) -164 throws MojoExecutionException -165 { -166 return getSingleChild( node, elementName ).getTextContent(); -167 } -168 -169 private Node getSingleChild( Node node, String elementName ) -170 throws MojoExecutionException -171 { -172 List<Node> namedChild = findNamedChild( node, elementName ); -173 if ( namedChild.isEmpty() ) -174 { -175 throw new MojoExecutionException( "Could not find " + elementName + " in plugin-help.xml" ); -176 } -177 if ( namedChild.size() > 1 ) -178 { -179 throw new MojoExecutionException( "Multiple " + elementName + " in plugin-help.xml" ); -180 } -181 return namedChild.get( 0 ); -182 } -183 -184 private List<Node> findNamedChild( Node node, String elementName ) -185 { -186 List<Node> result = new ArrayList<Node>(); -187 NodeList childNodes = node.getChildNodes(); -188 for ( int i = 0; i < childNodes.getLength(); i++ ) -189 { -190 Node item = childNodes.item( i ); -191 if ( elementName.equals( item.getNodeName() ) ) -192 { -193 result.add( item ); -194 } -195 } -196 return result; -197 } -198 -199 private Node findSingleChild( Node node, String elementName ) -200 throws MojoExecutionException -201 { -202 List<Node> elementsByTagName = findNamedChild( node, elementName ); -203 if ( elementsByTagName.isEmpty() ) -204 { -205 return null; -206 } -207 if ( elementsByTagName.size() > 1 ) -208 { -209 throw new MojoExecutionException( "Multiple " + elementName + "in plugin-help.xml" ); -210 } -211 return elementsByTagName.get( 0 ); -212 } -213 -214 private void writeGoal( StringBuilder sb, String goalPrefix, Element mojo ) -215 throws MojoExecutionException -216 { -217 String mojoGoal = getValue( mojo, "goal" ); -218 Node configurationElement = findSingleChild( mojo, "configuration" ); -219 Node description = findSingleChild( mojo, "description" ); -220 if ( goal == null || goal.length() <= 0 || mojoGoal.equals( goal ) ) -221 { -222 append( sb, goalPrefix + ":" + mojoGoal, 0 ); -223 Node deprecated = findSingleChild( mojo, "deprecated" ); -224 if ( ( deprecated != null ) && isNotEmpty( deprecated.getNodeValue() ) ) -225 { -226 append( sb, "Deprecated. " + deprecated, 1 ); -227 if ( detail && description != null ) -228 { -229 append( sb, "", 0 ); -230 append( sb, description.getTextContent(), 1 ); -231 } -232 } -233 else if (description != null ) -234 { -235 append( sb, description.getTextContent(), 1 ); -236 } -237 append( sb, "", 0 ); -238 -239 if ( detail ) -240 { -241 Node parametersNode = getSingleChild( mojo, "parameters" ); -242 List<Node> parameters = findNamedChild( parametersNode, "parameter" ); -243 append( sb, "Available parameters:", 1 ); -244 append( sb, "", 0 ); -245 -246 for ( Node parameter : parameters ) -247 { -248 writeParameter( sb, parameter, configurationElement ); -249 } -250 } -251 } -252 } -253 -254 private void writeParameter( StringBuilder sb, Node parameter, Node configurationElement ) -255 throws MojoExecutionException -256 { -257 String parameterName = getValue( parameter, "name" ); -258 String parameterDescription = getValue( parameter, "description" ); -259 -260 Node fieldConfigurationElement = findSingleChild( configurationElement, parameterName ); -261 -262 String parameterDefaultValue = ""; -263 if ( fieldConfigurationElement != null && fieldConfigurationElement.getNodeValue() != null ) -264 { -265 parameterDefaultValue = " (Default: " + ((Element)fieldConfigurationElement).getAttribute( "default-value" ) + ")"; -266 } -267 append( sb, parameterName + parameterDefaultValue, 2 ); -268 Node deprecated = findSingleChild( parameter, "deprecated" ); -269 if ( ( deprecated != null ) && isNotEmpty( deprecated.getNodeValue() ) ) -270 { -271 append( sb, "Deprecated. " + deprecated.getNodeValue(), 3 ); -272 append( sb, "", 0 ); -273 } -274 append( sb, parameterDescription, 3 ); -275 if ( "true".equals( getValue( parameter, "required" ) ) ) -276 { -277 append( sb, "Required: Yes", 3 ); -278 } -279 Node expression = findSingleChild( parameter, "expression" ); -280 if ( ( expression != null ) && isNotEmpty( expression.getNodeValue() ) ) -281 { -282 String property = getPropertyFromExpression( expression.getNodeValue() ); -283 append( sb, "User property: " + property, 3 ); -284 } -285 -286 append( sb, "", 0 ); -287 } -288 -289 /** -290 * <p>Repeat a String <code>n</code> times to form a new string.</p> -291 * -292 * @param str String to repeat -293 * @param repeat number of times to repeat str -294 * @return String with repeated String -295 * @throws NegativeArraySizeException if <code>repeat < 0</code> -296 * @throws NullPointerException if str is <code>null</code> -297 */ -298 private static String repeat( String str, int repeat ) -299 { -300 StringBuilder buffer = new StringBuilder( repeat * str.length() ); -301 -302 for ( int i = 0; i < repeat; i++ ) -303 { -304 buffer.append( str ); -305 } -306 -307 return buffer.toString(); -308 } -309 -310 /** -311 * Append a description to the buffer by respecting the indentSize and lineLength parameters. -312 * <b>Note</b>: The last character is always a new line. -313 * -314 * @param sb The buffer to append the description, not <code>null</code>. -315 * @param description The description, not <code>null</code>. -316 * @param indent The base indentation level of each line, must not be negative. -317 */ -318 private void append( StringBuilder sb, String description, int indent ) -319 { -320 for ( String line : toLines( description, indent, indentSize, lineLength ) ) -321 { -322 sb.append( line ).append( '\n' ); -323 } -324 } -325 -326 /** -327 * Splits the specified text into lines of convenient display length. -328 * -329 * @param text The text to split into lines, must not be <code>null</code>. -330 * @param indent The base indentation level of each line, must not be negative. -331 * @param indentSize The size of each indentation, must not be negative. -332 * @param lineLength The length of the line, must not be negative. -333 * @return The sequence of display lines, never <code>null</code>. -334 * @throws NegativeArraySizeException if <code>indent < 0</code> -335 */ -336 private static List<String> toLines( String text, int indent, int indentSize, int lineLength ) -337 { -338 List<String> lines = new ArrayList<String>(); -339 -340 String ind = repeat( "\t", indent ); -341 -342 String[] plainLines = text.split( "(\r\n)|(\r)|(\n)" ); -343 -344 for ( String plainLine : plainLines ) -345 { -346 toLines( lines, ind + plainLine, indentSize, lineLength ); -347 } -348 -349 return lines; -350 } -351 -352 /** -353 * Adds the specified line to the output sequence, performing line wrapping if necessary. -354 * -355 * @param lines The sequence of display lines, must not be <code>null</code>. -356 * @param line The line to add, must not be <code>null</code>. -357 * @param indentSize The size of each indentation, must not be negative. -358 * @param lineLength The length of the line, must not be negative. -359 */ -360 private static void toLines( List<String> lines, String line, int indentSize, int lineLength ) -361 { -362 int lineIndent = getIndentLevel( line ); -363 StringBuilder buf = new StringBuilder( 256 ); -364 -365 String[] tokens = line.split( " +" ); -366 -367 for ( String token : tokens ) -368 { -369 if ( buf.length() > 0 ) -370 { -371 if ( buf.length() + token.length() >= lineLength ) -372 { -373 lines.add( buf.toString() ); -374 buf.setLength( 0 ); -375 buf.append( repeat( " ", lineIndent * indentSize ) ); -376 } -377 else -378 { -379 buf.append( ' ' ); -380 } -381 } -382 -383 for ( int j = 0; j < token.length(); j++ ) -384 { -385 char c = token.charAt( j ); -386 if ( c == '\t' ) -387 { -388 buf.append( repeat( " ", indentSize - buf.length() % indentSize ) ); -389 } -390 else if ( c == '\u00A0' ) -391 { -392 buf.append( ' ' ); -393 } -394 else -395 { -396 buf.append( c ); -397 } -398 } -399 } -400 lines.add( buf.toString() ); -401 } -402 -403 /** -404 * Gets the indentation level of the specified line. -405 * -406 * @param line The line whose indentation level should be retrieved, must not be <code>null</code>. -407 * @return The indentation level of the line. -408 */ -409 private static int getIndentLevel( String line ) -410 { -411 int level = 0; -412 for ( int i = 0; i < line.length() && line.charAt( i ) == '\t'; i++ ) -413 { -414 level++; -415 } -416 for ( int i = level + 1; i <= level + 4 && i < line.length(); i++ ) -417 { -418 if ( line.charAt( i ) == '\t' ) -419 { -420 level++; -421 break; -422 } -423 } -424 return level; -425 } -426 -427 private String getPropertyFromExpression( String expression ) -428 { -429 if ( expression != null && expression.startsWith( "${" ) && expression.endsWith( "}" ) -430 && !expression.substring( 2 ).contains( "${" ) ) -431 { -432 // expression="${xxx}" -> property="xxx" -433 return expression.substring( 2, expression.length() - 1 ); -434 } -435 // no property can be extracted -436 return null; -437 } -438 } --
- -1 package de.juplo.plugins.hibernate4; -2 -3 import javax.validation.Validation; -4 -5 import org.hibernate.cfg.Configuration; -6 import org.hibernate.cfg.beanvalidation.TypeSafeActivatorAccessor; -7 import org.hibernate.dialect.Dialect; -8 import org.hibernate.metamodel.source.MappingException; -9 -10 -11 /** -12 * This integration is usually performed by BeanValidationIntegrator. -13 * Unfortunately, that integration will only be activated upon -14 * initialization of the ServiceRegistry, which initializes -15 * DatasourceConnectionProviderImpl, which looks up the datasource, -16 * which requires a JNDI context ... -17 * We therefore reimplement the relevant parts of BeanValidatorIntegrator. -18 * Since that must occur after secondPassCompile(), which is invoked by -19 * Configuration.generateSchemaCreationScript, which is invoked by -20 * SchemaExport, some fancy subclassing is needed to invoke the integration -21 * at the right time. -22 * @author Mark Robinson <mark@mrobinson.ca> -23 * @author Frank Schimmel <frank.schimmel@cm4all.com> -24 */ -25 public class ValidationConfiguration extends Configuration -26 { -27 private static final long serialVersionUID = 1L; -28 -29 private Class<Dialect> dialectClass; -30 -31 public ValidationConfiguration(final String dialectClass) -32 { -33 try { -34 this.dialectClass = (Class<Dialect>) Class.forName(dialectClass); -35 } catch (ClassNotFoundException e) { -36 throw new RuntimeException(e); -37 } -38 } -39 -40 @Override -41 protected void secondPassCompile() throws MappingException -42 { -43 super.secondPassCompile(); -44 -45 try -46 { -47 TypeSafeActivatorAccessor.applyRelationalConstraints( -48 Validation.buildDefaultValidatorFactory(), -49 classes.values(), -50 getProperties(), -51 dialectClass.newInstance() -52 ); -53 } -54 catch (Exception e) -55 { -56 throw new RuntimeException(e); -57 } -58 } -59 -60 public String getTypeDefs() -61 { -62 return typeDefs.entrySet().toString(); -63 } -64 } --
Class Summary | -
---|
- DriverProxy - | -
- Hbm2DdlMojo - | -
- HelpMojo - | -
- ValidationConfiguration - | -
- You don't have frames. Go here -
- -- -1 package org.hibernate.cfg.beanvalidation; -2 -3 /** -4 * This class enables access to the public methods of {@link TypeSafeActivator} -5 * which itself is visible in the package only. -6 * -7 * @author Frank Schimmel <frank.schimmel@cm4all.com> -8 */ -9 public class TypeSafeActivatorAccessor extends TypeSafeActivator { -10 // Empty: just makes public methods accessible. -11 } --
Class Summary | -
---|
- TypeSafeActivatorAccessor - | -
Packages | -
---|
- de.juplo.plugins.hibernate4 - | -
- org.hibernate.cfg.beanvalidation - | -
Modifier and Type | -Constant Field | -Value | -
---|---|---|
-
-public static final String |
-DIALECT |
-"hibernate.dialect" |
-
-
-public static final String |
-DRIVER_CLASS |
-"hibernate.connection.driver_class" |
-
-
-public static final String |
-PASSWORD |
-"hibernate.connection.password" |
-
-
-public static final String |
-URL |
-"hibernate.connection.url" |
-
-
-public static final String |
-USERNAME |
-"hibernate.connection.username" |
-
Copyright © 2012. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0/apidocs/de/juplo/plugins/hibernate4/Hbm2DdlMojo.html b/dist/hibernate4-maven-plugin-1.0/apidocs/de/juplo/plugins/hibernate4/Hbm2DdlMojo.html deleted file mode 100644 index a51c189e..00000000 --- a/dist/hibernate4-maven-plugin-1.0/apidocs/de/juplo/plugins/hibernate4/Hbm2DdlMojo.html +++ /dev/null @@ -1,379 +0,0 @@ - - - - - - -public class Hbm2DdlMojo
-extends org.apache.maven.plugin.AbstractMojo
-Modifier and Type | -Field and Description | -
---|---|
static String |
-DIALECT |
-
static String |
-DRIVER_CLASS |
-
static String |
-PASSWORD |
-
static String |
-URL |
-
static String |
-USERNAME |
-
ROLE
Constructor and Description | -
---|
Hbm2DdlMojo() |
-
public static final String DRIVER_CLASS-
public static final String URL-
public static final String USERNAME-
public static final String PASSWORD-
public static final String DIALECT-
Copyright © 2012. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0/apidocs/de/juplo/plugins/hibernate4/class-use/Hbm2DdlMojo.html b/dist/hibernate4-maven-plugin-1.0/apidocs/de/juplo/plugins/hibernate4/class-use/Hbm2DdlMojo.html deleted file mode 100644 index 7aff3978..00000000 --- a/dist/hibernate4-maven-plugin-1.0/apidocs/de/juplo/plugins/hibernate4/class-use/Hbm2DdlMojo.html +++ /dev/null @@ -1,115 +0,0 @@ - - - - - - -Copyright © 2012. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0/apidocs/de/juplo/plugins/hibernate4/package-frame.html b/dist/hibernate4-maven-plugin-1.0/apidocs/de/juplo/plugins/hibernate4/package-frame.html deleted file mode 100644 index 69956a3b..00000000 --- a/dist/hibernate4-maven-plugin-1.0/apidocs/de/juplo/plugins/hibernate4/package-frame.html +++ /dev/null @@ -1,20 +0,0 @@ - - - - - - -Class | -Description | -
---|---|
Hbm2DdlMojo | -
- Goal which extracts the hibernate-mapping-configuration and
- exports an according SQL-database-schema.
- |
-
Copyright © 2012. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0/apidocs/de/juplo/plugins/hibernate4/package-tree.html b/dist/hibernate4-maven-plugin-1.0/apidocs/de/juplo/plugins/hibernate4/package-tree.html deleted file mode 100644 index 3ecb64d9..00000000 --- a/dist/hibernate4-maven-plugin-1.0/apidocs/de/juplo/plugins/hibernate4/package-tree.html +++ /dev/null @@ -1,128 +0,0 @@ - - - - - - -Copyright © 2012. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0/apidocs/de/juplo/plugins/hibernate4/package-use.html b/dist/hibernate4-maven-plugin-1.0/apidocs/de/juplo/plugins/hibernate4/package-use.html deleted file mode 100644 index 083ef028..00000000 --- a/dist/hibernate4-maven-plugin-1.0/apidocs/de/juplo/plugins/hibernate4/package-use.html +++ /dev/null @@ -1,115 +0,0 @@ - - - - - - -Copyright © 2012. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0/apidocs/deprecated-list.html b/dist/hibernate4-maven-plugin-1.0/apidocs/deprecated-list.html deleted file mode 100644 index fb684d7e..00000000 --- a/dist/hibernate4-maven-plugin-1.0/apidocs/deprecated-list.html +++ /dev/null @@ -1,115 +0,0 @@ - - - - - - -Copyright © 2012. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0/apidocs/help-doc.html b/dist/hibernate4-maven-plugin-1.0/apidocs/help-doc.html deleted file mode 100644 index e44996d1..00000000 --- a/dist/hibernate4-maven-plugin-1.0/apidocs/help-doc.html +++ /dev/null @@ -1,216 +0,0 @@ - - - - - - -Each package has a page that contains a list of its classes and interfaces, with a summary for each. This page can contain six categories:
-Each class, interface, nested class and nested interface has its own separate page. Each of these pages has three sections consisting of a class/interface description, summary tables, and detailed member descriptions:
-Each summary entry contains the first sentence from the detailed description for that item. The summary entries are alphabetical, while the detailed descriptions are in the order they appear in the source code. This preserves the logical groupings established by the programmer.
-Each annotation type has its own separate page with the following sections:
-Each enum has its own separate page with the following sections:
-Each documented package, class and interface has its own Use page. This page describes what packages, classes, methods, constructors and fields use any part of the given class or package. Given a class or interface A, its Use page includes subclasses of A, fields declared as A, methods that return A, and methods and constructors with parameters of type A. You can access this page by first going to the package, class or interface, then clicking on the "Use" link in the navigation bar.
-There is a Class Hierarchy page for all packages, plus a hierarchy for each package. Each hierarchy page contains a list of classes and a list of interfaces. The classes are organized by inheritance structure starting with java.lang.Object
. The interfaces do not inherit from java.lang.Object
.
The Deprecated API page lists all of the API that have been deprecated. A deprecated API is not recommended for use, generally due to improvements, and a replacement API is usually given. Deprecated APIs may be removed in future implementations.
-The Index contains an alphabetic list of all classes, interfaces, constructors, methods, and fields.
-These links take you to the next or previous class, interface, package, or related page.
-These links show and hide the HTML frames. All pages are available with or without frames.
-The All Classes link shows all classes and interfaces except non-static nested types.
-Each serializable or externalizable class has a description of its serialization fields and methods. This information is of interest to re-implementors, not to developers using the API. While there is no link in the navigation bar, you can get to this information by going to any serialized class and clicking "Serialized Form" in the "See also" section of the class description.
-The Constant Field Values page lists the static final fields and their values.
-Copyright © 2012. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0/apidocs/index-all.html b/dist/hibernate4-maven-plugin-1.0/apidocs/index-all.html deleted file mode 100644 index e9c571f8..00000000 --- a/dist/hibernate4-maven-plugin-1.0/apidocs/index-all.html +++ /dev/null @@ -1,163 +0,0 @@ - - - - - - -Copyright © 2012. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0/apidocs/index.html b/dist/hibernate4-maven-plugin-1.0/apidocs/index.html deleted file mode 100644 index a4299e02..00000000 --- a/dist/hibernate4-maven-plugin-1.0/apidocs/index.html +++ /dev/null @@ -1,31 +0,0 @@ - - - - - - -This document is designed to be viewed using the frames feature. If you see this message, you are using a non-frame-capable web client. Link to Non-frame version.
-Copyright © 2012. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.0/apidocs/package-list b/dist/hibernate4-maven-plugin-1.0/apidocs/package-list deleted file mode 100644 index 05307714..00000000 --- a/dist/hibernate4-maven-plugin-1.0/apidocs/package-list +++ /dev/null @@ -1 +0,0 @@ -de.juplo.plugins.hibernate4 diff --git a/dist/hibernate4-maven-plugin-1.0/apidocs/packages b/dist/hibernate4-maven-plugin-1.0/apidocs/packages deleted file mode 100644 index c4b51407..00000000 --- a/dist/hibernate4-maven-plugin-1.0/apidocs/packages +++ /dev/null @@ -1 +0,0 @@ -de.juplo.plugins.hibernate4 \ No newline at end of file diff --git a/dist/hibernate4-maven-plugin-1.0/apidocs/resources/background.gif b/dist/hibernate4-maven-plugin-1.0/apidocs/resources/background.gif deleted file mode 100644 index f471940f..00000000 Binary files a/dist/hibernate4-maven-plugin-1.0/apidocs/resources/background.gif and /dev/null differ diff --git a/dist/hibernate4-maven-plugin-1.0/apidocs/resources/inherit.gif b/dist/hibernate4-maven-plugin-1.0/apidocs/resources/inherit.gif deleted file mode 100644 index c814867a..00000000 Binary files a/dist/hibernate4-maven-plugin-1.0/apidocs/resources/inherit.gif and /dev/null differ diff --git a/dist/hibernate4-maven-plugin-1.0/apidocs/resources/tab.gif b/dist/hibernate4-maven-plugin-1.0/apidocs/resources/tab.gif deleted file mode 100644 index 1a73a83b..00000000 Binary files a/dist/hibernate4-maven-plugin-1.0/apidocs/resources/tab.gif and /dev/null differ diff --git a/dist/hibernate4-maven-plugin-1.0/apidocs/resources/titlebar.gif b/dist/hibernate4-maven-plugin-1.0/apidocs/resources/titlebar.gif deleted file mode 100644 index 17443b3e..00000000 Binary files a/dist/hibernate4-maven-plugin-1.0/apidocs/resources/titlebar.gif and /dev/null differ diff --git a/dist/hibernate4-maven-plugin-1.0/apidocs/resources/titlebar_end.gif b/dist/hibernate4-maven-plugin-1.0/apidocs/resources/titlebar_end.gif deleted file mode 100644 index 3ad78d46..00000000 Binary files a/dist/hibernate4-maven-plugin-1.0/apidocs/resources/titlebar_end.gif and /dev/null differ diff --git a/dist/hibernate4-maven-plugin-1.0/apidocs/stylesheet.css b/dist/hibernate4-maven-plugin-1.0/apidocs/stylesheet.css deleted file mode 100644 index 0aeaa97f..00000000 --- a/dist/hibernate4-maven-plugin-1.0/apidocs/stylesheet.css +++ /dev/null @@ -1,474 +0,0 @@ -/* Javadoc style sheet */ -/* -Overall document style -*/ -body { - background-color:#ffffff; - color:#353833; - font-family:Arial, Helvetica, sans-serif; - font-size:76%; - margin:0; -} -a:link, a:visited { - text-decoration:none; - color:#4c6b87; -} -a:hover, a:focus { - text-decoration:none; - color:#bb7a2a; -} -a:active { - text-decoration:none; - color:#4c6b87; -} -a[name] { - color:#353833; -} -a[name]:hover { - text-decoration:none; - color:#353833; -} -pre { - font-size:1.3em; -} -h1 { - font-size:1.8em; -} -h2 { - font-size:1.5em; -} -h3 { - font-size:1.4em; -} -h4 { - font-size:1.3em; -} -h5 { - font-size:1.2em; -} -h6 { - font-size:1.1em; -} -ul { - list-style-type:disc; -} -code, tt { - font-size:1.2em; -} -dt code { - font-size:1.2em; -} -table tr td dt code { - font-size:1.2em; - vertical-align:top; -} -sup { - font-size:.6em; -} -/* -Document title and Copyright styles -*/ -.clear { - clear:both; - height:0px; - overflow:hidden; -} -.aboutLanguage { - float:right; - padding:0px 21px; - font-size:.8em; - z-index:200; - margin-top:-7px; -} -.legalCopy { - margin-left:.5em; -} -.bar a, .bar a:link, .bar a:visited, .bar a:active { - color:#FFFFFF; - text-decoration:none; -} -.bar a:hover, .bar a:focus { - color:#bb7a2a; -} -.tab { - background-color:#0066FF; - background-image:url(resources/titlebar.gif); - background-position:left top; - background-repeat:no-repeat; - color:#ffffff; - padding:8px; - width:5em; - font-weight:bold; -} -/* -Navigation bar styles -*/ -.bar { - background-image:url(resources/background.gif); - background-repeat:repeat-x; - color:#FFFFFF; - padding:.8em .5em .4em .8em; - height:auto;/*height:1.8em;*/ - font-size:1em; - margin:0; -} -.topNav { - background-image:url(resources/background.gif); - background-repeat:repeat-x; - color:#FFFFFF; - float:left; - padding:0; - width:100%; - clear:right; - height:2.8em; - padding-top:10px; - overflow:hidden; -} -.bottomNav { - margin-top:10px; - background-image:url(resources/background.gif); - background-repeat:repeat-x; - color:#FFFFFF; - float:left; - padding:0; - width:100%; - clear:right; - height:2.8em; - padding-top:10px; - overflow:hidden; -} -.subNav { - background-color:#dee3e9; - border-bottom:1px solid #9eadc0; - float:left; - width:100%; - overflow:hidden; -} -.subNav div { - clear:left; - float:left; - padding:0 0 5px 6px; -} -ul.navList, ul.subNavList { - float:left; - margin:0 25px 0 0; - padding:0; -} -ul.navList li{ - list-style:none; - float:left; - padding:3px 6px; -} -ul.subNavList li{ - list-style:none; - float:left; - font-size:90%; -} -.topNav a:link, .topNav a:active, .topNav a:visited, .bottomNav a:link, .bottomNav a:active, .bottomNav a:visited { - color:#FFFFFF; - text-decoration:none; -} -.topNav a:hover, .bottomNav a:hover { - text-decoration:none; - color:#bb7a2a; -} -.navBarCell1Rev { - background-image:url(resources/tab.gif); - background-color:#a88834; - color:#FFFFFF; - margin: auto 5px; - border:1px solid #c9aa44; -} -/* -Page header and footer styles -*/ -.header, .footer { - clear:both; - margin:0 20px; - padding:5px 0 0 0; -} -.indexHeader { - margin:10px; - position:relative; -} -.indexHeader h1 { - font-size:1.3em; -} -.title { - color:#2c4557; - margin:10px 0; -} -.subTitle { - margin:5px 0 0 0; -} -.header ul { - margin:0 0 25px 0; - padding:0; -} -.footer ul { - margin:20px 0 5px 0; -} -.header ul li, .footer ul li { - list-style:none; - font-size:1.2em; -} -/* -Heading styles -*/ -div.details ul.blockList ul.blockList ul.blockList li.blockList h4, div.details ul.blockList ul.blockList ul.blockListLast li.blockList h4 { - background-color:#dee3e9; - border-top:1px solid #9eadc0; - border-bottom:1px solid #9eadc0; - margin:0 0 6px -8px; - padding:2px 5px; -} -ul.blockList ul.blockList ul.blockList li.blockList h3 { - background-color:#dee3e9; - border-top:1px solid #9eadc0; - border-bottom:1px solid #9eadc0; - margin:0 0 6px -8px; - padding:2px 5px; -} -ul.blockList ul.blockList li.blockList h3 { - padding:0; - margin:15px 0; -} -ul.blockList li.blockList h2 { - padding:0px 0 20px 0; -} -/* -Page layout container styles -*/ -.contentContainer, .sourceContainer, .classUseContainer, .serializedFormContainer, .constantValuesContainer { - clear:both; - padding:10px 20px; - position:relative; -} -.indexContainer { - margin:10px; - position:relative; - font-size:1.0em; -} -.indexContainer h2 { - font-size:1.1em; - padding:0 0 3px 0; -} -.indexContainer ul { - margin:0; - padding:0; -} -.indexContainer ul li { - list-style:none; -} -.contentContainer .description dl dt, .contentContainer .details dl dt, .serializedFormContainer dl dt { - font-size:1.1em; - font-weight:bold; - margin:10px 0 0 0; - color:#4E4E4E; -} -.contentContainer .description dl dd, .contentContainer .details dl dd, .serializedFormContainer dl dd { - margin:10px 0 10px 20px; -} -.serializedFormContainer dl.nameValue dt { - margin-left:1px; - font-size:1.1em; - display:inline; - font-weight:bold; -} -.serializedFormContainer dl.nameValue dd { - margin:0 0 0 1px; - font-size:1.1em; - display:inline; -} -/* -List styles -*/ -ul.horizontal li { - display:inline; - font-size:0.9em; -} -ul.inheritance { - margin:0; - padding:0; -} -ul.inheritance li { - display:inline; - list-style:none; -} -ul.inheritance li ul.inheritance { - margin-left:15px; - padding-left:15px; - padding-top:1px; -} -ul.blockList, ul.blockListLast { - margin:10px 0 10px 0; - padding:0; -} -ul.blockList li.blockList, ul.blockListLast li.blockList { - list-style:none; - margin-bottom:25px; -} -ul.blockList ul.blockList li.blockList, ul.blockList ul.blockListLast li.blockList { - padding:0px 20px 5px 10px; - border:1px solid #9eadc0; - background-color:#f9f9f9; -} -ul.blockList ul.blockList ul.blockList li.blockList, ul.blockList ul.blockList ul.blockListLast li.blockList { - padding:0 0 5px 8px; - background-color:#ffffff; - border:1px solid #9eadc0; - border-top:none; -} -ul.blockList ul.blockList ul.blockList ul.blockList li.blockList { - margin-left:0; - padding-left:0; - padding-bottom:15px; - border:none; - border-bottom:1px solid #9eadc0; -} -ul.blockList ul.blockList ul.blockList ul.blockList li.blockListLast { - list-style:none; - border-bottom:none; - padding-bottom:0; -} -table tr td dl, table tr td dl dt, table tr td dl dd { - margin-top:0; - margin-bottom:1px; -} -/* -Table styles -*/ -.contentContainer table, .classUseContainer table, .constantValuesContainer table { - border-bottom:1px solid #9eadc0; - width:100%; -} -.contentContainer ul li table, .classUseContainer ul li table, .constantValuesContainer ul li table { - width:100%; -} -.contentContainer .description table, .contentContainer .details table { - border-bottom:none; -} -.contentContainer ul li table th.colOne, .contentContainer ul li table th.colFirst, .contentContainer ul li table th.colLast, .classUseContainer ul li table th, .constantValuesContainer ul li table th, .contentContainer ul li table td.colOne, .contentContainer ul li table td.colFirst, .contentContainer ul li table td.colLast, .classUseContainer ul li table td, .constantValuesContainer ul li table td{ - vertical-align:top; - padding-right:20px; -} -.contentContainer ul li table th.colLast, .classUseContainer ul li table th.colLast,.constantValuesContainer ul li table th.colLast, -.contentContainer ul li table td.colLast, .classUseContainer ul li table td.colLast,.constantValuesContainer ul li table td.colLast, -.contentContainer ul li table th.colOne, .classUseContainer ul li table th.colOne, -.contentContainer ul li table td.colOne, .classUseContainer ul li table td.colOne { - padding-right:3px; -} -.overviewSummary caption, .packageSummary caption, .contentContainer ul.blockList li.blockList caption, .summary caption, .classUseContainer caption, .constantValuesContainer caption { - position:relative; - text-align:left; - background-repeat:no-repeat; - color:#FFFFFF; - font-weight:bold; - clear:none; - overflow:hidden; - padding:0px; - margin:0px; -} -caption a:link, caption a:hover, caption a:active, caption a:visited { - color:#FFFFFF; -} -.overviewSummary caption span, .packageSummary caption span, .contentContainer ul.blockList li.blockList caption span, .summary caption span, .classUseContainer caption span, .constantValuesContainer caption span { - white-space:nowrap; - padding-top:8px; - padding-left:8px; - display:block; - float:left; - background-image:url(resources/titlebar.gif); - height:18px; -} -.overviewSummary .tabEnd, .packageSummary .tabEnd, .contentContainer ul.blockList li.blockList .tabEnd, .summary .tabEnd, .classUseContainer .tabEnd, .constantValuesContainer .tabEnd { - width:10px; - background-image:url(resources/titlebar_end.gif); - background-repeat:no-repeat; - background-position:top right; - position:relative; - float:left; -} -ul.blockList ul.blockList li.blockList table { - margin:0 0 12px 0px; - width:100%; -} -.tableSubHeadingColor { - background-color: #EEEEFF; -} -.altColor { - background-color:#eeeeef; -} -.rowColor { - background-color:#ffffff; -} -.overviewSummary td, .packageSummary td, .contentContainer ul.blockList li.blockList td, .summary td, .classUseContainer td, .constantValuesContainer td { - text-align:left; - padding:3px 3px 3px 7px; -} -th.colFirst, th.colLast, th.colOne, .constantValuesContainer th { - background:#dee3e9; - border-top:1px solid #9eadc0; - border-bottom:1px solid #9eadc0; - text-align:left; - padding:3px 3px 3px 7px; -} -td.colOne a:link, td.colOne a:active, td.colOne a:visited, td.colOne a:hover, td.colFirst a:link, td.colFirst a:active, td.colFirst a:visited, td.colFirst a:hover, td.colLast a:link, td.colLast a:active, td.colLast a:visited, td.colLast a:hover, .constantValuesContainer td a:link, .constantValuesContainer td a:active, .constantValuesContainer td a:visited, .constantValuesContainer td a:hover { - font-weight:bold; -} -td.colFirst, th.colFirst { - border-left:1px solid #9eadc0; - white-space:nowrap; -} -td.colLast, th.colLast { - border-right:1px solid #9eadc0; -} -td.colOne, th.colOne { - border-right:1px solid #9eadc0; - border-left:1px solid #9eadc0; -} -table.overviewSummary { - padding:0px; - margin-left:0px; -} -table.overviewSummary td.colFirst, table.overviewSummary th.colFirst, -table.overviewSummary td.colOne, table.overviewSummary th.colOne { - width:25%; - vertical-align:middle; -} -table.packageSummary td.colFirst, table.overviewSummary th.colFirst { - width:25%; - vertical-align:middle; -} -/* -Content styles -*/ -.description pre { - margin-top:0; -} -.deprecatedContent { - margin:0; - padding:10px 0; -} -.docSummary { - padding:0; -} -/* -Formatting effect styles -*/ -.sourceLineNo { - color:green; - padding:0 30px 0 0; -} -h1.hidden { - visibility:hidden; - overflow:hidden; - font-size:.9em; -} -.block { - display:block; - margin:3px 0 0 0; -} -.strong { - font-weight:bold; -} diff --git a/dist/hibernate4-maven-plugin-1.0/cpd.html b/dist/hibernate4-maven-plugin-1.0/cpd.html deleted file mode 100644 index 918bd15a..00000000 --- a/dist/hibernate4-maven-plugin-1.0/cpd.html +++ /dev/null @@ -1,107 +0,0 @@ - - - - - -The following document contains the results of PMD's CPD 4.3.
The following is a list of compile dependencies for this project. These dependencies are required to compile and run the application:
GroupId | ArtifactId | Version | Type |
---|---|---|---|
com.pyx4j | maven-plugin-log4j | 1.0.1 | jar |
net.sf.scannotation | scannotation | 1.0.2 | jar |
org.apache.maven | maven-core | 3.0.4 | jar |
org.apache.maven | maven-plugin-api | 3.0.4 | jar |
org.hibernate | hibernate-core | 4.1.8.Final | jar |
The following is a list of transitive dependencies for this project. Transitive dependencies are the dependencies of the project dependencies.
The following is a list of compile dependencies for this project. These dependencies are required to compile and run the application:
GroupId | ArtifactId | Version | Classifier | Type |
---|---|---|---|---|
antlr | antlr | 2.7.7 | - | jar |
dom4j | dom4j | 1.6.1 | - | jar |
javassist | javassist | 3.6.0.GA | - | jar |
log4j | log4j | 1.2.14 | - | jar |
org.apache.maven | maven-aether-provider | 3.0.4 | - | jar |
org.apache.maven | maven-artifact | 3.0.4 | - | jar |
org.apache.maven | maven-model | 3.0.4 | - | jar |
org.apache.maven | maven-model-builder | 3.0.4 | - | jar |
org.apache.maven | maven-repository-metadata | 3.0.4 | - | jar |
org.apache.maven | maven-settings | 3.0.4 | - | jar |
org.apache.maven | maven-settings-builder | 3.0.4 | - | jar |
org.codehaus.plexus | plexus-classworlds | 2.4 | - | jar |
org.codehaus.plexus | plexus-component-annotations | 1.5.5 | - | jar |
org.codehaus.plexus | plexus-interpolation | 1.14 | - | jar |
org.hibernate.common | hibernate-commons-annotations | 4.0.1.Final | - | jar |
org.hibernate.javax.persistence | hibernate-jpa-2.0-api | 1.0.1.Final | - | jar |
org.javassist | javassist | 3.15.0-GA | - | jar |
org.jboss.logging | jboss-logging | 3.1.0.GA | - | jar |
org.jboss.spec.javax.transaction | jboss-transaction-api_1.1_spec | 1.0.0.Final | - | jar |
org.sonatype.aether | aether-api | 1.13.1 | - | jar |
org.sonatype.aether | aether-impl | 1.13.1 | - | jar |
org.sonatype.aether | aether-spi | 1.13.1 | - | jar |
org.sonatype.aether | aether-util | 1.13.1 | - | jar |
org.sonatype.plexus | plexus-cipher | 1.4 | - | jar |
org.sonatype.plexus | plexus-sec-dispatcher | 1.3 | - | jar |
org.sonatype.sisu | sisu-guava | 0.9.9 | - | jar |
org.sonatype.sisu | sisu-guice | 3.1.0 | no_aop | jar |
org.sonatype.sisu | sisu-inject-bean | 2.3.0 | - | jar |
org.sonatype.sisu | sisu-inject-plexus | 2.3.0 | - | jar |
de.juplo:hibernate4-maven-plugin:maven-plugin:1.0
org.apache.maven:maven-core:jar:3.0.4 (compile)
org.apache.maven:maven-model:jar:3.0.4 (compile)
org.apache.maven:maven-settings:jar:3.0.4 (compile)
org.apache.maven:maven-settings-builder:jar:3.0.4 (compile)
org.codehaus.plexus:plexus-interpolation:jar:1.14 (compile)
org.codehaus.plexus:plexus-component-annotations:jar:1.5.5 (compile)
org.apache.maven:maven-settings:jar:3.0.4 (compile)
org.sonatype.plexus:plexus-sec-dispatcher:jar:1.3 (compile)
org.apache.maven:maven-repository-metadata:jar:3.0.4 (compile)
org.apache.maven:maven-artifact:jar:3.0.4 (compile)
org.apache.maven:maven-plugin-api:jar:3.0.4 (compile)
org.apache.maven:maven-model-builder:jar:3.0.4 (compile)
org.codehaus.plexus:plexus-interpolation:jar:1.14 (compile)
org.codehaus.plexus:plexus-component-annotations:jar:1.5.5 (compile)
org.apache.maven:maven-model:jar:3.0.4 (compile)
org.apache.maven:maven-aether-provider:jar:3.0.4 (compile)
org.apache.maven:maven-model:jar:3.0.4 (compile)
org.apache.maven:maven-model-builder:jar:3.0.4 (compile)
org.apache.maven:maven-repository-metadata:jar:3.0.4 (compile)
org.sonatype.aether:aether-api:jar:1.13.1 (compile)
org.sonatype.aether:aether-spi:jar:1.13.1 (compile)
org.sonatype.aether:aether-api:jar:1.13.1 (compile)
org.sonatype.aether:aether-util:jar:1.13.1 (compile)
org.sonatype.aether:aether-impl:jar:1.13.1 (compile)
org.codehaus.plexus:plexus-component-annotations:jar:1.5.5 (compile)
org.sonatype.aether:aether-impl:jar:1.13.1 (compile)
org.sonatype.aether:aether-api:jar:1.13.1 (compile)
org.sonatype.aether:aether-spi:jar:1.13.1 (compile)
org.sonatype.aether:aether-util:jar:1.13.1 (compile)
org.sonatype.aether:aether-api:jar:1.13.1 (compile)
org.sonatype.aether:aether-util:jar:1.13.1 (compile)
org.sonatype.aether:aether-api:jar:1.13.1 (compile)
org.sonatype.sisu:sisu-inject-plexus:jar:2.3.0 (compile)
org.codehaus.plexus:plexus-component-annotations:jar:1.5.5 (compile)
org.codehaus.plexus:plexus-classworlds:jar:2.4 (compile)
org.sonatype.sisu:sisu-inject-bean:jar:2.3.0 (compile)
org.sonatype.sisu:sisu-guice:jar:no_aop:3.1.0 (compile)
org.sonatype.sisu:sisu-guava:jar:0.9.9 (compile)
org.codehaus.plexus:plexus-interpolation:jar:1.14 (compile)
org.codehaus.plexus:plexus-classworlds:jar:2.4 (compile)
org.codehaus.plexus:plexus-component-annotations:jar:1.5.5 (compile)
org.sonatype.plexus:plexus-sec-dispatcher:jar:1.3 (compile)
org.sonatype.plexus:plexus-cipher:jar:1.4 (compile)
org.apache.maven:maven-plugin-api:jar:3.0.4 (compile)
org.apache.maven:maven-model:jar:3.0.4 (compile)
org.apache.maven:maven-artifact:jar:3.0.4 (compile)
org.sonatype.sisu:sisu-inject-plexus:jar:2.3.0 (compile)
org.hibernate:hibernate-core:jar:4.1.8.Final (compile)
antlr:antlr:jar:2.7.7 (compile)
org.jboss.logging:jboss-logging:jar:3.1.0.GA (compile)
org.jboss.spec.javax.transaction:jboss-transaction-api_1.1_spec:jar:1.0.0.Final (compile)
dom4j:dom4j:jar:1.6.1 (compile)
org.hibernate.javax.persistence:hibernate-jpa-2.0-api:jar:1.0.1.Final (compile)
org.javassist:javassist:jar:3.15.0-GA (compile)
org.hibernate.common:hibernate-commons-annotations:jar:4.0.1.Final (compile)
net.sf.scannotation:scannotation:jar:1.0.2 (compile)
javassist:javassist:jar:3.6.0.GA (compile)
com.pyx4j:maven-plugin-log4j:jar:1.0.1 (compile)
log4j:log4j:jar:1.2.14 (compile)
Unamed: JPA 2.0 API
Apache Public License 2.0: Plexus Cipher: encryption/decryption Component, Plexus Security Dispatcher Component
GNU LESSER GENERAL PUBLIC LICENSE: Hibernate Commons Annotations
Unknown: Unnamed - javassist:javassist:jar:3.6.0.GA, dom4j
LGPL 2.1: Javassist
MPL 1.1: Javassist
The Apache Software License, Version 2.0: Hibernate 4 Maven Plugin, Log4j, Maven Aether Provider, Maven Artifact, Maven Core, Maven Model, Maven Model Builder, Maven Plugin API, Maven Repository Metadata Model, Maven Settings, Maven Settings Builder, Plexus :: Component Annotations, Plexus Classworlds, Plexus Interpolation API, Sisu Guava - Core Library, Sisu Guice - Core Library, Sisu-Inject-Bean : Aggregate OSGi bundle, maven-plugin-log4j
GNU Lesser General Public License: A Hibernate Core Module
GNU Lesser General Public License, version 2.1: JBoss Logging 3
lgpl: Transaction 1.1 API
Apache License V2.0: scannotation
BSD License: AntLR Parser Generator
Eclipse Public License, Version 1.0: Aether :: API, Aether :: Implementation, Aether :: SPI, Aether :: Utilities, Sisu-Inject-Bean : Aggregate OSGi bundle, Sisu-Inject-Plexus : Aggregate OSGi bundle
Apache License 2.0: Javassist
Filename | Size | Entries | Classes | Packages | JDK Rev | Debug |
---|---|---|---|---|---|---|
antlr-2.7.7.jar | 434.85 kB | 239 | 224 | 12 | 1.2 | debug |
maven-plugin-log4j-1.0.1.jar | 3.64 kB | 12 | 1 | 1 | 1.4 | debug |
dom4j-1.6.1.jar | 306.54 kB | 208 | 190 | 14 | 1.3 | debug |
javassist-3.6.0.GA.jar | 529.53 kB | 323 | 305 | 16 | 1.2 | debug |
log4j-1.2.14.jar | 358.83 kB | 288 | 256 | 19 | 1.1 | debug |
scannotation-1.0.2.jar | 18.04 kB | 23 | 13 | 2 | 1.5 | debug |
maven-aether-provider-3.0.4.jar | 55.17 kB | 40 | 23 | 1 | 1.5 | debug |
maven-artifact-3.0.4.jar | 50.87 kB | 57 | 32 | 11 | 1.5 | debug |
maven-core-3.0.4.jar | 545.94 kB | 428 | 350 | 43 | 1.5 | debug |
maven-model-3.0.4.jar | 159.72 kB | 67 | 50 | 3 | 1.5 | debug |
maven-model-builder-3.0.4.jar | 147.06 kB | 142 | 109 | 16 | 1.5 | debug |
maven-plugin-api-3.0.4.jar | 48.16 kB | 46 | 25 | 6 | 1.5 | debug |
maven-repository-metadata-3.0.4.jar | 29.37 kB | 25 | 7 | 2 | 1.5 | debug |
maven-settings-3.0.4.jar | 45.57 kB | 33 | 17 | 2 | 1.5 | debug |
maven-settings-builder-3.0.4.jar | 40.41 kB | 53 | 32 | 5 | 1.5 | debug |
plexus-classworlds-2.4.jar | 45.96 kB | 52 | 37 | 5 | 1.4 | debug |
plexus-component-annotations-1.5.5.jar | 4.11 kB | 15 | 3 | 1 | 1.5 | release |
plexus-interpolation-1.14.jar | 59.64 kB | 60 | 44 | 6 | 1.4 | debug |
hibernate-core-4.1.8.Final.jar | 4.29 MB | 3,104 | 2,899 | 166 | 1.6 | debug |
hibernate-commons-annotations-4.0.1.Final.jar | 79.37 kB | 82 | 64 | 7 | 1.6 | debug |
hibernate-jpa-2.0-api-1.0.1.Final.jar | 100.25 kB | 190 | 176 | 4 | 1.5 | debug |
javassist-3.15.0-GA.jar | 633.06 kB | 391 | 367 | 17 | 1.4 | debug |
jboss-logging-3.1.0.GA.jar | 59.34 kB | 55 | 43 | 1 | 1.6 | debug |
jboss-transaction-api_1.1_spec-1.0.0.Final.jar | 10.95 kB | 28 | 18 | 2 | 1.5 | debug |
aether-api-1.13.1.jar | 87.56 kB | 116 | 96 | 11 | 1.5 | debug |
aether-impl-1.13.1.jar | 127.10 kB | 87 | 73 | 2 | 1.5 | debug |
aether-spi-1.13.1.jar | 15.07 kB | 33 | 17 | 5 | 1.5 | debug |
aether-util-1.13.1.jar | 126.98 kB | 116 | 92 | 14 | 1.5 | debug |
plexus-cipher-1.4.jar | 13.18 kB | 20 | 6 | 1 | 1.4 | debug |
plexus-sec-dispatcher-1.3.jar | 27.89 kB | 31 | 13 | 3 | 1.4 | debug |
sisu-guava-0.9.9.jar | 1.44 MB | 1,183 | 1,163 | 10 | 1.5 | debug |
sisu-guice-3.1.0-no_aop.jar | 349.05 kB | 310 | 295 | 8 | 1.5 | debug |
sisu-inject-bean-2.3.0.jar | 282.29 kB | 256 | 224 | 15 | 1.5 | debug |
sisu-inject-plexus-2.3.0.jar | 199.64 kB | 207 | 163 | 27 | 1.5 | debug |
Total | Size | Entries | Classes | Packages | JDK Rev | Debug |
34 | 10.60 MB | 8,320 | 7,427 | 458 | 1.6 | 33 |
compile: 34 | compile: 10.60 MB | compile: 8,320 | compile: 7,427 | compile: 458 | - | compile: 33 |
Repo ID | URL | Release | Snapshot |
---|---|---|---|
apache.snapshots | http://repository.apache.org/snapshots | - | Yes |
sonatype-nexus-snapshots | https://oss.sonatype.org/content/repositories/snapshots | - | Yes |
central | http://repo1.maven.org/maven2 | Yes | - |
Repository locations for each of the Dependencies.
The plugin was designed with two main goals in mind:
To achieve the first goal, the convention-over-configuration paradigma was applied and the plugin was stuffed with usefull logging-messages. So, if in doubt, just turn on the Debug-Output with the mvn -X ....
To achieve the second goal, the precedence in which the configuration locations are consulted was layouted in a way that makes it possible, to prevent overwrites of the wrong database by accident.
The most simple way to configure the plugin is, to put all the hibernate-configuration in a hibernate.properties-file on your classpath. Put the file in the resources-folder. Maven will put it in the class-folder of your webapp, where it will be picked up by this plugin as well as by Hibernate 4.
Doing so, the only additionally configuration needed, to activat the plugin is the following entry in the plugins-section of your pom.xml:
<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.0</version> - <executions> - <execution> - <goals> - <goal>export</goal> - </goals> - </execution> - </executions> -</plugin>
But be aware, that in this case the database-url, that is build in the application is the same that is used while testing, where the database is droped and recreated by the plugin. So, you should never fire up this configuration on your production system, or your database might be erased!
Hence, you should specify a different url for testing like in the following snippet:
<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.0</version> - <executions> - <execution> - <goals> - <goal>export</goal> - </goals> - </execution> - </executions> - <configuration> - <url><![CDATA[jdbc:mysql://localhost/test-db]]></url> - </configuration> -</plugin>
Configuration properties, that are set in the configuration-section of the plugin-configuration cannnot be overwritten elsewere (for details see Configuration-Method-Precedence). You never can overwrite them by accident when specifying a property on the commandline or in your settings.xml.
Alternatively, it is possible, to configure the plugin via maven-properties. Each relevant configuration-option has a corresponding maven-property (for a full list see the Documentation of the export-Mojo). These are named after the Hibernate JDBC Properties:
So, instead of writing the hibernate-configuration in the properties-file, like above, you could put it in the properties-section of your pom.xml.
Thogether with the plugin-definition from above, the following would be a complete configuration (again, the database-url was overwritten in the plugin-configuration, to be sure to have a separate database for testing):
<properties> - <hibernate.connection.driver_class>org.hsqldb.jdbcDriver</hibernate.connection.driver_class> - <hibernate.dialect>org.hibernate.dialect.HSQLDialect</hibernate.dialect> - <hibernate.connection.url><![CDATA[jdbc:hsqldb:res:org.my.path.production_db]]></hibernate.connection.url> - <hibernate.connection.username>sa</hibernate.connection.username> - <hibernate.connection.password></hibernate.connection.password> -</properties> - -... - -<plugins> - - ... - - <plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.0</version> - <executions> - <execution> - <goals> - <goal>export</goal> - </goals> - </execution> - </executions> - <configuration> - <url><![CDATA[jdbc:hsqldb:target/db/testdb;shutdown=true]]></url> - </configuration> - </plugin> - -<plugins>
A third way for configuring the plugin is the plugin-configuration. The relevant configuration-parameters are:
The equivalent of the configuration from the last section would look like this:
<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.0</version> - <executions> - <execution> - <goals> - <goal>export</goal> - </goals> - </execution> - </executions> - <configuration> - <driverClassName>org.hsqldb.jdbcDriver</driverClassName> - <hibernateDialect>org.hibernate.dialect.HSQLDialect</hibernateDialect> - <url><![CDATA[jdbc:hsqldb:target/db/fotos;shutdown=true]]></url> - <username>sa</username> - <password></password> - </configuration> -</plugin>
There are some seldom used parameters, that can only be configured throug this method:
For explanations, see the Documentation of the export-Mojo.
The configuration is gathered in a fix order:
If you are in doubt about where a configuration-value comes from, run maven with the Debug-Output enabled: mvn -X hibernate4:export and be aware, that maven-properties can be overwitten on the command-line, in your ~/.m2/settings.xml and in a profile.
The plugin-configuration comes last and overwrites everything else. That way, you can be sure, that a configuration-value, that is specified in the plugin-configuration will never be overwritten by any other configuration-method.
If you realy need to overwrite plugin-configuration-values with maven-properties, you can use maven-properties in the plugin-configuration:
<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.0</version> - <executions> - <execution> - <goals> - <goal>export</goal> - </goals> - </execution> - </executions> - <configuration> - <password>${my-password-property}</password> - </configuration> -</plugin>
If you are new to hibernate4-maven-plugin, in many cases, the Configuration-Method-Precedence may be the source of configuration errors. To solve this problem, you should run maven with the debugging output enabled. For example, by executing:
mvn -X compile hibernate4:export
(The compile might be necessary, because hibernate4-maven-plugin has to scan the compiled classes for annotations!)
Unlike the majority of the maven-plugins, hibernate4-maven-plugin was designed to give a good many hints, when debugging is enabled. Because, if you do not know, what went wrong, you can't fix it!
But be warned: hibernate4-maven-plugin tends to be very chatty ;)
One regular problem is the scope of the jdbc-driver-dependency. It is very unlikely, that this dependency is needed at compile-time. So a tidy maven-developer would usually scope it for runtime.
But this will break the execution of the hibernate4-maven-plugin. Since it will not be able to see the needed dependency, it will fail with an error-message like:
[INFO] Gathered hibernate-configuration (turn on debugging for details): -[INFO] hibernate.connection.username = sa -[INFO] hibernate.connection.password = -[INFO] hibernate.dialect = org.hibernate.dialect.HSQLDialect -[INFO] hibernate.connection.url = jdbc:hsqldb:/home/kai/mmf/target/mmf;shutdown=true -[INFO] hibernate.connection.driver_class = org.hsqldb.jdbcDriver -[ERROR] Dependency for driver-class org.hsqldb.jdbcDriver is missing! -[INFO] ------------------------------------------------------------------------ -[ERROR] BUILD ERROR -[INFO] ------------------------------------------------------------------------ -[INFO] org.hsqldb.jdbcDriver -[INFO] ------------------------------------------------------------------------ -[INFO] For more information, run Maven with the -e switch -[INFO] ------------------------------------------------------------------------ -[INFO] Total time: 2 seconds -[INFO] Finished at: Thu Nov 29 11:31:14 CET 2012 -[INFO] Final Memory: 32M/342M -[INFO] ------------------------------------------------------------------------
A quick workaround for this error would be, to delete the runtime-constraint for the jdbc-driver-dependency.
A much cleaner way is, to (additionally) ad the dependency, to the plugin-definition:
<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.0</version> - <executions> - <execution> - <goals> - <goal>export</goal> - </goals> - </execution> - </executions> - <dependencies> - <dependency> - <groupId>org.hsqldb</groupId> - <artifactId>hsqldb</artifactId> - <version>2.2.8</version> - </dependency> - </dependencies> -</plugin>
This is also the best way, if you use a different jdbc-driver for testing, than in production. Because otherwise, this dependency will unnecessarily bloat the runtime-dependencies of your project.
Full name:
-de.juplo:hibernate4-maven-plugin:1.0:export
-Description:
-Attributes:
-Name | -Type | -Since | -Description | -
---|---|---|---|
delimiter | -String | -- | -Delimiter in output-file. Default value is: ;. |
-
driverClassName | -String | -- | -SQL-Driver name. User property is: hibernate.connection.driver_class. |
-
format | -boolean | -- | -Format output-file. Default value is: true. |
-
hibernateDialect | -String | -- | -Hibernate dialect. User property is: hibernate.dialect. |
-
hibernateProperties | -String | -- | -Hibernate configuration file. Default value is: ${project.build.outputDirectory}/hibernate.properties. |
-
outputDirectory | -String | -- | -Directories to scan. User property is: project.build.outputDirectory. |
-
outputFile | -String | -- | -Output file. Default value is: ${project.build.outputDirectory}/schema.sql. |
-
password | -String | -- | -Database password User property is: hibernate.connection.password. |
-
skip | -boolean | -- | -Skip execution User property is: maven.test.skip. |
-
target | -String | -- | -Target of execution:
-
Default value is: EXPORT. |
-
type | -String | -- | -Type of export.
-
Default value is: BOTH. |
-
url | -String | -- | -Database URL. User property is: hibernate.connection.url. |
-
username | -String | -- | -Database username User property is: hibernate.connection.username. |
-
skip:
-type:
-url:
-hibernate4-maven-plugin is a plugin for generating a database-schema from your Hibernate-4-Mappings and create or update your database accordingly.
The plugin was designed to be easy and safe to use, because it must not never, never happen, that you blow away your production database when firering a maven-build of your webapp on your production-machine! For more information about the insiration to write this tiny plugin, read our blog-article about the hibernate4-maven-plugin.
Configuration for notifying developers/users when a build is unsuccessful, including user information and notification mode.
Type | Address | Configuration |
---|---|---|
kai@juplo.de | - |
Typically the licenses listed for the project are that of the project itself, and not of dependencies.
A business-friendly OSS license
- Apache License - Version 2.0, January 2004 - http://www.apache.org/licenses/ - - TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION - - 1. Definitions. - - "License" shall mean the terms and conditions for use, reproduction, - and distribution as defined by Sections 1 through 9 of this document. - - "Licensor" shall mean the copyright owner or entity authorized by - the copyright owner that is granting the License. - - "Legal Entity" shall mean the union of the acting entity and all - other entities that control, are controlled by, or are under common - control with that entity. For the purposes of this definition, - "control" means (i) the power, direct or indirect, to cause the - direction or management of such entity, whether by contract or - otherwise, or (ii) ownership of fifty percent (50%) or more of the - outstanding shares, or (iii) beneficial ownership of such entity. - - "You" (or "Your") shall mean an individual or Legal Entity - exercising permissions granted by this License. - - "Source" form shall mean the preferred form for making modifications, - including but not limited to software source code, documentation - source, and configuration files. - - "Object" form shall mean any form resulting from mechanical - transformation or translation of a Source form, including but - not limited to compiled object code, generated documentation, - and conversions to other media types. - - "Work" shall mean the work of authorship, whether in Source or - Object form, made available under the License, as indicated by a - copyright notice that is included in or attached to the work - (an example is provided in the Appendix below). - - "Derivative Works" shall mean any work, whether in Source or Object - form, that is based on (or derived from) the Work and for which the - editorial revisions, annotations, elaborations, or other modifications - represent, as a whole, an original work of authorship. For the purposes - of this License, Derivative Works shall not include works that remain - separable from, or merely link (or bind by name) to the interfaces of, - the Work and Derivative Works thereof. - - "Contribution" shall mean any work of authorship, including - the original version of the Work and any modifications or additions - to that Work or Derivative Works thereof, that is intentionally - submitted to Licensor for inclusion in the Work by the copyright owner - or by an individual or Legal Entity authorized to submit on behalf of - the copyright owner. For the purposes of this definition, "submitted" - means any form of electronic, verbal, or written communication sent - to the Licensor or its representatives, including but not limited to - communication on electronic mailing lists, source code control systems, - and issue tracking systems that are managed by, or on behalf of, the - Licensor for the purpose of discussing and improving the Work, but - excluding communication that is conspicuously marked or otherwise - designated in writing by the copyright owner as "Not a Contribution." - - "Contributor" shall mean Licensor and any individual or Legal Entity - on behalf of whom a Contribution has been received by Licensor and - subsequently incorporated within the Work. - - 2. Grant of Copyright License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - copyright license to reproduce, prepare Derivative Works of, - publicly display, publicly perform, sublicense, and distribute the - Work and such Derivative Works in Source or Object form. - - 3. Grant of Patent License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - (except as stated in this section) patent license to make, have made, - use, offer to sell, sell, import, and otherwise transfer the Work, - where such license applies only to those patent claims licensable - by such Contributor that are necessarily infringed by their - Contribution(s) alone or by combination of their Contribution(s) - with the Work to which such Contribution(s) was submitted. If You - institute patent litigation against any entity (including a - cross-claim or counterclaim in a lawsuit) alleging that the Work - or a Contribution incorporated within the Work constitutes direct - or contributory patent infringement, then any patent licenses - granted to You under this License for that Work shall terminate - as of the date such litigation is filed. - - 4. Redistribution. You may reproduce and distribute copies of the - Work or Derivative Works thereof in any medium, with or without - modifications, and in Source or Object form, provided that You - meet the following conditions: - - (a) You must give any other recipients of the Work or - Derivative Works a copy of this License; and - - (b) You must cause any modified files to carry prominent notices - stating that You changed the files; and - - (c) You must retain, in the Source form of any Derivative Works - that You distribute, all copyright, patent, trademark, and - attribution notices from the Source form of the Work, - excluding those notices that do not pertain to any part of - the Derivative Works; and - - (d) If the Work includes a "NOTICE" text file as part of its - distribution, then any Derivative Works that You distribute must - include a readable copy of the attribution notices contained - within such NOTICE file, excluding those notices that do not - pertain to any part of the Derivative Works, in at least one - of the following places: within a NOTICE text file distributed - as part of the Derivative Works; within the Source form or - documentation, if provided along with the Derivative Works; or, - within a display generated by the Derivative Works, if and - wherever such third-party notices normally appear. The contents - of the NOTICE file are for informational purposes only and - do not modify the License. You may add Your own attribution - notices within Derivative Works that You distribute, alongside - or as an addendum to the NOTICE text from the Work, provided - that such additional attribution notices cannot be construed - as modifying the License. - - You may add Your own copyright statement to Your modifications and - may provide additional or different license terms and conditions - for use, reproduction, or distribution of Your modifications, or - for any such Derivative Works as a whole, provided Your use, - reproduction, and distribution of the Work otherwise complies with - the conditions stated in this License. - - 5. Submission of Contributions. Unless You explicitly state otherwise, - any Contribution intentionally submitted for inclusion in the Work - by You to the Licensor shall be under the terms and conditions of - this License, without any additional terms or conditions. - Notwithstanding the above, nothing herein shall supersede or modify - the terms of any separate license agreement you may have executed - with Licensor regarding such Contributions. - - 6. Trademarks. This License does not grant permission to use the trade - names, trademarks, service marks, or product names of the Licensor, - except as required for reasonable and customary use in describing the - origin of the Work and reproducing the content of the NOTICE file. - - 7. Disclaimer of Warranty. Unless required by applicable law or - agreed to in writing, Licensor provides the Work (and each - Contributor provides its Contributions) on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or - implied, including, without limitation, any warranties or conditions - of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A - PARTICULAR PURPOSE. You are solely responsible for determining the - appropriateness of using or redistributing the Work and assume any - risks associated with Your exercise of permissions under this License. - - 8. Limitation of Liability. In no event and under no legal theory, - whether in tort (including negligence), contract, or otherwise, - unless required by applicable law (such as deliberate and grossly - negligent acts) or agreed to in writing, shall any Contributor be - liable to You for damages, including any direct, indirect, special, - incidental, or consequential damages of any character arising as a - result of this License or out of the use or inability to use the - Work (including but not limited to damages for loss of goodwill, - work stoppage, computer failure or malfunction, or any and all - other commercial damages or losses), even if such Contributor - has been advised of the possibility of such damages. - - 9. Accepting Warranty or Additional Liability. While redistributing - the Work or Derivative Works thereof, You may choose to offer, - and charge a fee for, acceptance of support, warranty, indemnity, - or other liability obligations and/or rights consistent with this - License. However, in accepting such obligations, You may act only - on Your own behalf and on Your sole responsibility, not on behalf - of any other Contributor, and only if You agree to indemnify, - defend, and hold each Contributor harmless for any liability - incurred by, or claims asserted against, such Contributor by reason - of your accepting any such warranty or additional liability. - - END OF TERMS AND CONDITIONS - - APPENDIX: How to apply the Apache License to your work. - - To apply the Apache License to your work, attach the following - boilerplate notice, with the fields enclosed by brackets "[]" - replaced with your own identifying information. (Don't include - the brackets!) The text should be enclosed in the appropriate - comment syntax for the file format. We also recommend that a - file or class name and description of purpose be included on the - same "printed page" as the copyright notice for easier - identification within third-party archives. - - Copyright [yyyy] [name of copyright owner] - - Licensed under the Apache License, Version 2.0 (the "License"); - you may not use this file except in compliance with the License. - You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. -
Goals available for this plugin:
Goal | Description |
---|---|
hibernate4:export | Goal which extracts the hibernate-mapping-configuration and exports -an according SQL-database-schema. |
The following specifies the minimum requirements to run this Maven plugin:
Maven | 2.0.6 |
JDK | 1.6 |
Memory | No minimum requirement. |
Disk Space | No minimum requirement. |
You should specify the version in your project's plugin configuration:
<project> - ... - <build> - <!-- To define the plugin version in your parent POM --> - <pluginManagement> - <plugins> - <plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.0</version> - </plugin> - ... - </plugins> - </pluginManagement> - <!-- To use the plugin goals in your POM or parent POM --> - <plugins> - <plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.0</version> - </plugin> - ... - </plugins> - </build> - ... -</project> -
For more information, see "Guide to Configuring Plug-ins"
GroupId | ArtifactId | Version |
---|---|---|
org.apache.maven.plugins | maven-antrun-plugin | 1.6 |
org.apache.maven.plugins | maven-assembly-plugin | 2.2-beta-4 |
org.apache.maven.plugins | maven-clean-plugin | 2.3 |
org.apache.maven.plugins | maven-compiler-plugin | 2.0.2 |
org.apache.maven.plugins | maven-dependency-plugin | 2.1 |
org.apache.maven.plugins | maven-deploy-plugin | 2.4 |
org.apache.maven.plugins | maven-ear-plugin | 2.3.2 |
org.apache.maven.plugins | maven-ejb-plugin | 2.2 |
org.apache.maven.plugins | maven-install-plugin | 2.3 |
org.apache.maven.plugins | maven-jar-plugin | 2.2 |
org.apache.maven.plugins | maven-javadoc-plugin | 2.6.1 |
org.apache.maven.plugins | maven-plugin-plugin | 2.8 |
org.apache.maven.plugins | maven-rar-plugin | 2.2 |
org.apache.maven.plugins | maven-release-plugin | 2.1 |
org.apache.maven.plugins | maven-resources-plugin | 2.3 |
org.apache.maven.plugins | maven-site-plugin | 2.1 |
org.apache.maven.plugins | maven-source-plugin | 2.0.4 |
org.apache.maven.plugins | maven-surefire-plugin | 2.10 |
org.apache.maven.plugins | maven-war-plugin | 2.1.1 |
GroupId | ArtifactId | Version |
---|---|---|
org.apache.maven.plugins | maven-compiler-plugin | 2.0.2 |
org.apache.maven.plugins | maven-dependency-plugin | 2.1 |
org.apache.maven.plugins | maven-enforcer-plugin | 1.0 |
org.apache.maven.plugins | maven-gpg-plugin | 1.1 |
org.apache.maven.plugins | maven-javadoc-plugin | 2.7 |
org.apache.maven.plugins | maven-resources-plugin | 2.3 |
org.apache.maven.plugins | scp://people.apache.org/www/maven.apache.org/scm/maven-scm-plugin | 1.7 |
org.apache.maven.plugins | maven-source-plugin | 2.1.2 |
GroupId | ArtifactId | Version |
---|---|---|
org.apache.maven.plugins | maven-changes-plugin | 2.7.1 |
org.apache.maven.plugins | maven-javadoc-plugin | 2.7 |
org.apache.maven.plugins | maven-jxr-plugin | 2.3 |
org.apache.maven.plugins | maven-plugin-plugin | 3.2 |
org.apache.maven.plugins | maven-pmd-plugin | 2.7.1 |
org.apache.maven.plugins | maven-site-plugin | 2.1 |
The following document contains the results of PMD 4.3.
This document provides an overview of the various documents and links that are part of this project's general information. All of this content is automatically generated by Maven on behalf of the project.
Document | Description |
---|---|
About | Plugin for generating a database-schema from Hibernate-4-Mapping-Annotations |
Continuous Integration | This is a link to the definitions of all continuous integration processes that builds and tests code on a frequent, regular basis. |
Dependencies | This document lists the project's dependencies and provides information on each dependency. |
Issue Tracking | This is a link to the issue management system for this project. Issues (bugs, features, change requests) can be created and queried using this link. |
Mailing Lists | This document provides subscription and archive information for this project's mailing lists. |
Plugin Management | This document lists the plugins that are defined through pluginManagement. |
Project License | This is a link to the definitions of project licenses. |
Project Plugins | This document lists the build plugins and the report plugins used by this project. |
Project Summary | This document lists other related information of this project |
Project Team | This document provides information on the members of this project. These are the individuals who have contributed to the project in one form or another. |
Source Repository | This is a link to the online source repository that can be viewed via a web browser. |
This document provides an overview of the various reports that are automatically generated by Maven . Each report is briefly described below.
Document | Description |
---|---|
CPD Report | Duplicate code detection. |
JavaDocs | JavaDoc API documentation. |
Plugin Documentation | This report provides goals and parameters documentation of a plugin. |
PMD Report | Verification of coding rules. |
Source Xref | HTML based, cross-reference version of Java source code. |
Field | Value |
---|---|
Name | Hibernate 4 Maven Plugin |
Description | Plugin for generating a database-schema from Hibernate-4-Mapping-Annotations |
Homepage | http://juplo.de/hibernate4-maven-plugin |
Refer to the documentation of the SCM used for more information about anonymously check out. The connection url is:
git:http://juplo.de/git/hibernate4-maven-plugin
A successful project requires many people to play many roles. Some members write code or documentation, while others are valuable as testers, submitting patches and suggestions.
The team is comprised of Members and Contributors. Members have direct access to the source of a project and actively evolve the code-base. Contributors improve the project through submission of patches and suggestions to the Members. The number of Contributors to the project is unbounded. Get involved today. All contributions to the project are greatly appreciated.
The following is a list of developers with commit privileges that have directly contributed to the project in one way or another.
Id | Name | |
---|---|---|
kai | Kai Moritz | kai@juplo.de |
- -1 package de.juplo.plugins.hibernate4; -2 -3 /* -4 * Copyright 2001-2005 The Apache Software Foundation. -5 * -6 * Licensed under the Apache License, Version 2.0 (the "License"); -7 * you may not use this file except in compliance with the License. -8 * You may obtain a copy of the License at -9 * -10 * http://www.apache.org/licenses/LICENSE-2.0 -11 * -12 * Unless required by applicable law or agreed to in writing, software -13 * distributed under the License is distributed on an "AS IS" BASIS, -14 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -15 * See the License for the specific language governing permissions and -16 * limitations under the License. -17 */ -18 -19 import com.pyx4j.log4j.MavenLogAppender; -20 import java.io.File; -21 import java.io.FileInputStream; -22 import java.io.IOException; -23 import java.net.URL; -24 import java.net.URLClassLoader; -25 import java.sql.Connection; -26 import java.sql.Driver; -27 import java.sql.DriverManager; -28 import java.sql.DriverPropertyInfo; -29 import java.sql.SQLException; -30 import java.sql.SQLFeatureNotSupportedException; -31 import java.util.Enumeration; -32 import java.util.HashSet; -33 import java.util.List; -34 import java.util.Map.Entry; -35 import java.util.Properties; -36 import java.util.Set; -37 import java.util.logging.Logger; -38 import javax.persistence.Embeddable; -39 import javax.persistence.Entity; -40 import javax.persistence.MappedSuperclass; -41 import org.apache.maven.plugin.AbstractMojo; -42 import org.apache.maven.plugin.MojoExecutionException; -43 import org.apache.maven.plugin.MojoFailureException; -44 import org.apache.maven.project.MavenProject; -45 import org.hibernate.cfg.Configuration; -46 import org.hibernate.tool.hbm2ddl.SchemaExport; -47 import org.hibernate.tool.hbm2ddl.SchemaExport.Type; -48 import org.hibernate.tool.hbm2ddl.Target; -49 import org.scannotation.AnnotationDB; -50 -51 -52 /** -53 * Goal which extracts the hibernate-mapping-configuration and -54 * exports an according SQL-database-schema. -55 * -56 * @goal export -57 * @phase process-classes -58 * @threadSafe -59 * @requiresDependencyResolution runtime -60 */ -61 public class Hbm2DdlMojo extends AbstractMojo -62 { -63 public final static String DRIVER_CLASS = "hibernate.connection.driver_class"; -64 public final static String URL = "hibernate.connection.url"; -65 public final static String USERNAME = "hibernate.connection.username"; -66 public final static String PASSWORD = "hibernate.connection.password"; -67 public final static String DIALECT = "hibernate.dialect"; -68 -69 -70 /** -71 * The project whose project files to create. -72 * -73 * @parameter expression="${project}" -74 * @required -75 * @readonly -76 */ -77 private MavenProject project; -78 -79 /** -80 * Directories to scan. -81 * -82 * @parameter expression="${project.build.outputDirectory}" -83 */ -84 private String outputDirectory; -85 -86 /** -87 * Skip execution -88 * -89 * @parameter expression="${maven.test.skip}" -90 */ -91 private boolean skip; -92 -93 /** -94 * SQL-Driver name. -95 * -96 * @parameter expression="${hibernate.connection.driver_class} -97 */ -98 private String driverClassName; -99 -100 /** -101 * Database URL. -102 * -103 * @parameter expression="${hibernate.connection.url}" -104 */ -105 private String url; -106 -107 /** -108 * Database username -109 * -110 * @parameter expression="${hibernate.connection.username}" -111 */ -112 private String username; -113 -114 /** -115 * Database password -116 * -117 * @parameter expression="${hibernate.connection.password}" -118 */ -119 private String password; -120 -121 /** -122 * Hibernate dialect. -123 * -124 * @parameter expression="${hibernate.dialect}" -125 */ -126 private String hibernateDialect; -127 -128 /** -129 * Hibernate configuration file. -130 * -131 * @parameter default-value="${project.build.outputDirectory}/hibernate.properties" -132 */ -133 private String hibernateProperties; -134 -135 /** -136 * Target of execution: -137 * <ul> -138 * <li><strong>NONE</strong> do nothing - just validate the configuration</li> -139 * <li><strong>EXPORT</strong> create database <strong>(DEFAULT!)</strong></li> -140 * <li><strong>SCRIPT</strong> export schema to SQL-script</li> -141 * <li><strong>BOTH</strong></li> -142 * </ul> -143 * @parameter default-value="EXPORT" -144 */ -145 private String target; -146 -147 /** -148 * Type of export. -149 * <ul> -150 * <li><strong>NONE</strong> do nothing - just validate the configuration</li> -151 * <li><strong>CREATE</strong> create database-schema</li> -152 * <li><strong>DROP</strong> drop database-schema</li> -153 * <li><strong>BOTH</strong> <strong>(DEFAULT!)</strong></li> -154 * </ul> -155 * @parameter default-value="BOTH" -156 */ -157 private String type; -158 -159 /** -160 * Output file. -161 * -162 * @parameter default-value="${project.build.outputDirectory}/schema.sql" -163 */ -164 private String outputFile; -165 -166 /** -167 * Delimiter in output-file. -168 * -169 * @parameter default-value=";" -170 */ -171 private String delimiter; -172 -173 /** -174 * Format output-file. -175 * -176 * @parameter default-value="true" -177 */ -178 private boolean format; -179 -180 -181 @Override -182 public void execute() -183 throws -184 MojoFailureException, -185 MojoExecutionException -186 { -187 if (skip) -188 { -189 getLog().info("Exectuion of hibernate4-maven-plugin:export was skipped!"); -190 return; -191 } -192 -193 File dir = new File(outputDirectory); -194 if (!dir.exists()) -195 throw new MojoExecutionException("Cannot scan for annotated classes in " + outputDirectory + ": directory does not exist!"); -196 -197 -198 Set<String> classes = new HashSet<String>(); -199 try -200 { -201 AnnotationDB db = new AnnotationDB(); -202 getLog().info("Scanning directory " + outputDirectory + " for annotated classes..."); -203 URL dirUrl = dir.toURI().toURL(); -204 db.scanArchives(dirUrl); -205 if (db.getAnnotationIndex().containsKey(Entity.class.getName())) -206 classes.addAll(db.getAnnotationIndex().get(Entity.class.getName())); -207 if (db.getAnnotationIndex().containsKey(MappedSuperclass.class.getName())) -208 classes.addAll(db.getAnnotationIndex().get(MappedSuperclass.class.getName())); -209 if (db.getAnnotationIndex().containsKey(Embeddable.class.getName())) -210 classes.addAll(db.getAnnotationIndex().get(Embeddable.class.getName())); -211 } -212 catch (IOException e) -213 { -214 getLog().error("Error while scanning!", e); -215 throw new MojoFailureException(e.getMessage()); -216 } -217 if (classes.isEmpty()) -218 throw new MojoFailureException("No annotated classes found in directory " + outputDirectory); -219 -220 Properties properties = new Properties(); -221 -222 /** Try to read configuration from properties-file */ -223 try -224 { -225 File file = new File(hibernateProperties); -226 if (file.exists()) -227 { -228 getLog().info("Reading properties from file " + hibernateProperties + "..."); -229 properties.load(new FileInputStream(file)); -230 } -231 else -232 getLog().info("No hibernate-properties-file found! Checked path: " + hibernateProperties); -233 } -234 catch (IOException e) -235 { -236 getLog().error("Error while reading properties!", e); -237 throw new MojoExecutionException(e.getMessage()); -238 } -239 -240 /** Overwrite values from propertie-file or set, if given */ -241 if (driverClassName != null) -242 { -243 if (properties.containsKey(DRIVER_CLASS)) -244 getLog().debug( -245 "Overwriting property " + -246 DRIVER_CLASS + "=" + properties.getProperty(DRIVER_CLASS) + -247 " with the value " + driverClassName + -248 " from the plugin-configuration-parameter driverClassName!" -249 ); -250 else -251 getLog().debug( -252 "Using the value " + driverClassName + -253 " from the plugin-configuration-parameter driverClassName!" -254 ); -255 properties.setProperty(DRIVER_CLASS, driverClassName); -256 } -257 if (url != null) -258 { -259 if (properties.containsKey(URL)) -260 getLog().debug( -261 "Overwriting property " + -262 URL + "=" + properties.getProperty(URL) + -263 " with the value " + url + -264 " from the plugin-configuration-parameter url!" -265 ); -266 else -267 getLog().debug( -268 "Using the value " + url + -269 " from the plugin-configuration-parameter url!" -270 ); -271 properties.setProperty(URL, url); -272 } -273 if (username != null) -274 { -275 if (properties.containsKey(USERNAME)) -276 getLog().debug( -277 "Overwriting property " + -278 USERNAME + "=" + properties.getProperty(USERNAME) + -279 " with the value " + username + -280 " from the plugin-configuration-parameter username!" -281 ); -282 else -283 getLog().debug( -284 "Using the value " + username + -285 " from the plugin-configuration-parameter username!" -286 ); -287 properties.setProperty(USERNAME, username); -288 } -289 if (password != null) -290 { -291 if (properties.containsKey(PASSWORD)) -292 getLog().debug( -293 "Overwriting property " + -294 PASSWORD + "=" + properties.getProperty(PASSWORD) + -295 " with the value " + password + -296 " from the plugin-configuration-parameter password!" -297 ); -298 else -299 getLog().debug( -300 "Using the value " + password + -301 " from the plugin-configuration-parameter password!" -302 ); -303 properties.setProperty(PASSWORD, password); -304 } -305 if (hibernateDialect != null) -306 { -307 if (properties.containsKey(DIALECT)) -308 getLog().debug( -309 "Overwriting property " + -310 DIALECT + "=" + properties.getProperty(DIALECT) + -311 " with the value " + hibernateDialect + -312 " from the plugin-configuration-parameter hibernateDialect!" -313 ); -314 else -315 getLog().debug( -316 "Using the value " + hibernateDialect + -317 " from the plugin-configuration-parameter hibernateDialect!" -318 ); -319 properties.setProperty(DIALECT, hibernateDialect); -320 } -321 -322 getLog().info("Gathered hibernate-configuration (turn on debugging for details):"); -323 if (properties.isEmpty()) -324 { -325 getLog().error("No properties set!"); -326 throw new MojoFailureException("Hibernate-Configuration is missing!"); -327 } -328 for (Entry<Object,Object> entry : properties.entrySet()) -329 getLog().info(" " + entry.getKey() + " = " + entry.getValue()); -330 -331 ClassLoader classLoader = null; -332 try -333 { -334 getLog().debug("Creating ClassLoader for project-dependencies..."); -335 List<String> classpathFiles = project.getCompileClasspathElements(); -336 URL[] urls = new URL[classpathFiles.size()]; -337 for (int i = 0; i < classpathFiles.size(); ++i) -338 { -339 getLog().debug("Dependency: " + classpathFiles.get(i)); -340 urls[i] = new File(classpathFiles.get(i)).toURI().toURL(); -341 } -342 classLoader = new URLClassLoader(urls, getClass().getClassLoader()); -343 } -344 catch (Exception e) -345 { -346 getLog().error("Error while creating ClassLoader!", e); -347 throw new MojoExecutionException(e.getMessage()); -348 } -349 -350 Configuration config = new Configuration(); -351 config.setProperties(properties); -352 try -353 { -354 getLog().debug("Adding annotated classes to hibernate-mapping-configuration..."); -355 for (String annotatedClass : classes) -356 { -357 getLog().debug("Class " + annotatedClass); -358 config.addAnnotatedClass(classLoader.loadClass(annotatedClass)); -359 } -360 } -361 catch (ClassNotFoundException e) -362 { -363 getLog().error("Error while adding annotated classes!", e); -364 throw new MojoExecutionException(e.getMessage()); -365 } -366 -367 Target target = null; -368 try -369 { -370 target = Target.valueOf(this.target); -371 } -372 catch (IllegalArgumentException e) -373 { -374 getLog().error("Invalid value for configuration-option \"target\": " + this.target); -375 getLog().error("Valid values are: NONE, SCRIPT, EXPORT, BOTH"); -376 throw new MojoExecutionException("Invalid value for configuration-option \"target\""); -377 } -378 Type type = null; -379 try -380 { -381 type = Type.valueOf(this.type); -382 } -383 catch (IllegalArgumentException e) -384 { -385 getLog().error("Invalid value for configuration-option \"type\": " + this.type); -386 getLog().error("Valid values are: NONE, CREATE, DROP, BOTH"); -387 throw new MojoExecutionException("Invalid value for configuration-option \"type\""); -388 } -389 -390 Connection connection = null; -391 try -392 { -393 /** -394 * The connection must be established outside of hibernate, because -395 * hibernate does not use the context-classloader of the current -396 * thread and, hence, would not be able to resolve the driver-class! -397 */ -398 switch (target) -399 { -400 case EXPORT: -401 case BOTH: -402 switch (type) -403 { -404 case CREATE: -405 case DROP: -406 case BOTH: -407 Class driverClass = classLoader.loadClass(driverClassName); -408 getLog().debug("Registering JDBC-driver " + driverClass.getName()); -409 DriverManager.registerDriver(new DriverProxy((Driver)driverClass.newInstance())); -410 getLog().debug("Opening JDBC-connection to " + url + " as " + username + " with password " + password); -411 connection = DriverManager.getConnection(url, username, password); -412 } -413 } -414 } -415 catch (ClassNotFoundException e) -416 { -417 getLog().error("Dependency for driver-class " + driverClassName + " is missing!"); -418 throw new MojoExecutionException(e.getMessage()); -419 } -420 catch (Exception e) -421 { -422 getLog().error("Cannot establish connection to database!"); -423 Enumeration<Driver> drivers = DriverManager.getDrivers(); -424 if (!drivers.hasMoreElements()) -425 getLog().error("No drivers registered!"); -426 while (drivers.hasMoreElements()) -427 getLog().debug("Driver: " + drivers.nextElement()); -428 throw new MojoExecutionException(e.getMessage()); -429 } -430 -431 ClassLoader contextClassLoader = Thread.currentThread().getContextClassLoader(); -432 MavenLogAppender.startPluginLog(this); -433 try -434 { -435 /** -436 * Change class-loader of current thread, so that hibernate can -437 * see all dependencies! -438 */ -439 Thread.currentThread().setContextClassLoader(classLoader); -440 -441 SchemaExport export = new SchemaExport(config, connection); -442 export.setOutputFile(outputFile); -443 export.setDelimiter(delimiter); -444 export.setFormat(format); -445 export.execute(target, type); -446 -447 for (Object exception : export.getExceptions()) -448 getLog().debug(exception.toString()); -449 } -450 finally -451 { -452 /** Stop Log-Capturing */ -453 MavenLogAppender.endPluginLog(this); -454 -455 /** Restore the old class-loader (TODO: is this really necessary?) */ -456 Thread.currentThread().setContextClassLoader(contextClassLoader); -457 -458 /** Close the connection */ -459 try -460 { -461 connection.close(); -462 } -463 catch (SQLException e) -464 { -465 getLog().error("Error while closing connection: " + e.getMessage()); -466 } -467 } -468 } -469 -470 /** -471 * Needed, because DriverManager won't pick up drivers, that were not -472 * loaded by the system-classloader! -473 * See: -474 * http://stackoverflow.com/questions/288828/how-to-use-a-jdbc-driver-from-an-arbitrary-location -475 */ -476 static final class DriverProxy implements Driver -477 { -478 private final Driver target; -479 -480 DriverProxy(Driver target) -481 { -482 if (target == null) -483 throw new NullPointerException(); -484 this.target = target; -485 } -486 -487 public java.sql.Driver getTarget() -488 { -489 return target; -490 } -491 -492 @Override -493 public boolean acceptsURL(String url) throws SQLException -494 { -495 return target.acceptsURL(url); -496 } -497 -498 @Override -499 public java.sql.Connection connect( -500 String url, -501 java.util.Properties info -502 ) -503 throws -504 SQLException -505 { -506 return target.connect(url, info); -507 } -508 -509 @Override -510 public int getMajorVersion() -511 { -512 return target.getMajorVersion(); -513 } -514 -515 @Override -516 public int getMinorVersion() -517 { -518 return target.getMinorVersion(); -519 } -520 -521 @Override -522 public DriverPropertyInfo[] getPropertyInfo( -523 String url, -524 Properties info -525 ) -526 throws -527 SQLException -528 { -529 return target.getPropertyInfo(url, info); -530 } -531 -532 @Override -533 public boolean jdbcCompliant() -534 { -535 return target.jdbcCompliant(); -536 } -537 -538 /** -539 * This Method cannot be annotated with @Override, becaus the plugin -540 * will not compile then under Java 1.6! -541 */ -542 public Logger getParentLogger() throws SQLFeatureNotSupportedException -543 { -544 throw new SQLFeatureNotSupportedException("Not supported, for backward-compatibility with Java 1.6"); -545 } -546 -547 @Override -548 public String toString() -549 { -550 return "Proxy: " + target; -551 } -552 -553 @Override -554 public int hashCode() -555 { -556 return target.hashCode(); -557 } -558 -559 @Override -560 public boolean equals(Object obj) -561 { -562 if (!(obj instanceof DriverProxy)) -563 return false; -564 DriverProxy other = (DriverProxy) obj; -565 return this.target.equals(other.target); -566 } -567 } -568 } --
Class Summary | -
---|
- DriverProxy - | -
- Hbm2DdlMojo - | -
- You don't have frames. Go here -
- -Packages | -
---|
- de.juplo.plugins.hibernate4 - | -
Modifier and Type | -Constant Field | -Value | -
---|---|---|
-
-public static final String |
-DIALECT |
-"hibernate.dialect" |
-
-
-public static final String |
-DRIVER_CLASS |
-"hibernate.connection.driver_class" |
-
-
-public static final String |
-ENVERS |
-"hibernate.export.envers" |
-
-
-public static final String |
-EXPORT_SKIPPED_PROPERTY |
-"hibernate.export.skipped" |
-
-
-public static final String |
-JPA_DRIVER |
-"javax.persistence.jdbc.driver" |
-
-
-public static final String |
-JPA_PASSWORD |
-"javax.persistence.jdbc.password" |
-
-
-public static final String |
-JPA_URL |
-"javax.persistence.jdbc.url" |
-
-
-public static final String |
-JPA_USERNAME |
-"javax.persistence.jdbc.user" |
-
-
-public static final String |
-MD5S |
-"hibernate4-generatedschema.md5s" |
-
-
-public static final String |
-NAMING_STRATEGY |
-"hibernate.ejb.naming_strategy" |
-
-
-public static final String |
-PASSWORD |
-"hibernate.connection.password" |
-
-
-public static final String |
-URL |
-"hibernate.connection.url" |
-
-
-public static final String |
-USERNAME |
-"hibernate.connection.username" |
-
Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.0/apidocs/de/juplo/plugins/hibernate4/Hbm2DdlMojo.html b/dist/hibernate4-maven-plugin-1.1.0/apidocs/de/juplo/plugins/hibernate4/Hbm2DdlMojo.html deleted file mode 100644 index 13f20288..00000000 --- a/dist/hibernate4-maven-plugin-1.1.0/apidocs/de/juplo/plugins/hibernate4/Hbm2DdlMojo.html +++ /dev/null @@ -1,493 +0,0 @@ - - - - - - -public class Hbm2DdlMojo
-extends org.apache.maven.plugin.AbstractMojo
-Modifier and Type | -Field and Description | -
---|---|
static String |
-DIALECT |
-
static String |
-DRIVER_CLASS |
-
static String |
-ENVERS |
-
static String |
-EXPORT_SKIPPED_PROPERTY |
-
static String |
-JPA_DRIVER |
-
static String |
-JPA_PASSWORD |
-
static String |
-JPA_URL |
-
static String |
-JPA_USERNAME |
-
static String |
-MD5S |
-
static String |
-NAMING_STRATEGY |
-
static String |
-PASSWORD |
-
static String |
-URL |
-
static String |
-USERNAME |
-
ROLE
Constructor and Description | -
---|
Hbm2DdlMojo() |
-
public static final String EXPORT_SKIPPED_PROPERTY-
public static final String DRIVER_CLASS-
public static final String URL-
public static final String USERNAME-
public static final String PASSWORD-
public static final String DIALECT-
public static final String NAMING_STRATEGY-
public static final String ENVERS-
public static final String JPA_DRIVER-
public static final String JPA_URL-
public static final String JPA_USERNAME-
public static final String JPA_PASSWORD-
public static final String MD5S-
Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.0/apidocs/de/juplo/plugins/hibernate4/HelpMojo.html b/dist/hibernate4-maven-plugin-1.1.0/apidocs/de/juplo/plugins/hibernate4/HelpMojo.html deleted file mode 100644 index 732a9793..00000000 --- a/dist/hibernate4-maven-plugin-1.1.0/apidocs/de/juplo/plugins/hibernate4/HelpMojo.html +++ /dev/null @@ -1,296 +0,0 @@ - - - - - - -public class HelpMojo
-extends org.apache.maven.plugin.AbstractMojo
-mvn hibernate4:help -Ddetail=true -Dgoal=<goal-name>
to display parameter details.ROLE
Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.0/apidocs/de/juplo/plugins/hibernate4/ValidationConfiguration.html b/dist/hibernate4-maven-plugin-1.1.0/apidocs/de/juplo/plugins/hibernate4/ValidationConfiguration.html deleted file mode 100644 index f6b308e2..00000000 --- a/dist/hibernate4-maven-plugin-1.1.0/apidocs/de/juplo/plugins/hibernate4/ValidationConfiguration.html +++ /dev/null @@ -1,336 +0,0 @@ - - - - - - -public class ValidationConfiguration
-extends org.hibernate.cfg.Configuration
-org.hibernate.cfg.Configuration.MappingsImpl, org.hibernate.cfg.Configuration.MetadataSourceQueue
ARTEFACT_PROCESSING_ORDER, auxiliaryDatabaseObjects, classes, collections, columnNameBindingPerTable, DEFAULT_ARTEFACT_PROCESSING_ORDER, DEFAULT_CACHE_CONCURRENCY_STRATEGY, extendsQueue, fetchProfiles, filterDefinitions, imports, metadataSourceQueue, namedEntityGraphMap, namedProcedureCallMap, namedQueries, namedSqlQueries, propertyReferences, secondPasses, settingsFactory, sqlFunctions, sqlResultSetMappings, tableNameBinding, tables, typeDefs, USE_NEW_ID_GENERATOR_MAPPINGS, xmlHelper
Constructor and Description | -
---|
ValidationConfiguration() |
-
Modifier and Type | -Method and Description | -
---|---|
String |
-getTypeDefs() |
-
protected void |
-secondPassCompile() |
-
add, addAnnotatedClass, addAttributeConverter, addAttributeConverter, addAttributeConverter, addAttributeConverter, addAttributeConverter, addAuxiliaryDatabaseObject, addCacheableFile, addCacheableFile, addCacheableFileStrictly, addClass, addDirectory, addDocument, addFetchProfile, addFile, addFile, addFilterDefinition, addInputStream, addJar, addPackage, addProperties, addResource, addResource, addSqlFunction, addURL, addXML, buildMapping, buildMappings, buildSessionFactory, buildSessionFactory, buildSettings, buildSettings, configure, configure, configure, configure, configure, createMappings, doConfigure, doConfigure, findPossibleExtends, generateDropSchemaScript, generateSchemaCreationScript, generateSchemaUpdateScript, generateSchemaUpdateScriptList, getClassMapping, getClassMappings, getCollectionMapping, getCollectionMappings, getConfigurationInputStream, getCurrentTenantIdentifierResolver, getEntityNotFoundDelegate, getEntityResolver, getEntityTuplizerFactory, getFilterDefinitions, getIdentifierGeneratorFactory, getImports, getInterceptor, getJaccPermissionDeclarations, getMappedSuperclassMappings, getMappedSuperclassMappingsCopy, getNamedEntityGraphs, getNamedProcedureCallMap, getNamedQueries, getNamedSQLQueries, getNamingStrategy, getNamingStrategyDelegator, getProperties, getProperty, getReflectionManager, getSessionFactoryObserver, getSqlFunctions, getSqlResultSetMappings, getTableMappings, getTypeResolver, iterateFetchProfiles, iterateGenerators, mergeProperties, registerTypeContributor, registerTypeOverride, registerTypeOverride, registerTypeOverride, reset, secondPassCompileForeignKeys, setCacheConcurrencyStrategy, setCacheConcurrencyStrategy, setCacheConcurrencyStrategy, setCollectionCacheConcurrencyStrategy, setCollectionCacheConcurrencyStrategy, setCurrentTenantIdentifierResolver, setEntityNotFoundDelegate, setEntityResolver, setInterceptor, setNamingStrategy, setNamingStrategyDelegator, setPrecedence, setProperties, setProperty, setSessionFactoryObserver, validateSchema
public ValidationConfiguration()-
protected void secondPassCompile() - throws org.hibernate.metamodel.source.MappingException-
secondPassCompile
in class org.hibernate.cfg.Configuration
org.hibernate.metamodel.source.MappingException
public String getTypeDefs()-
Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.0/apidocs/de/juplo/plugins/hibernate4/class-use/Hbm2DdlMojo.html b/dist/hibernate4-maven-plugin-1.1.0/apidocs/de/juplo/plugins/hibernate4/class-use/Hbm2DdlMojo.html deleted file mode 100644 index fdbafbb2..00000000 --- a/dist/hibernate4-maven-plugin-1.1.0/apidocs/de/juplo/plugins/hibernate4/class-use/Hbm2DdlMojo.html +++ /dev/null @@ -1,117 +0,0 @@ - - - - - - -Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.0/apidocs/de/juplo/plugins/hibernate4/class-use/HelpMojo.html b/dist/hibernate4-maven-plugin-1.1.0/apidocs/de/juplo/plugins/hibernate4/class-use/HelpMojo.html deleted file mode 100644 index d074d5a9..00000000 --- a/dist/hibernate4-maven-plugin-1.1.0/apidocs/de/juplo/plugins/hibernate4/class-use/HelpMojo.html +++ /dev/null @@ -1,117 +0,0 @@ - - - - - - -Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.0/apidocs/de/juplo/plugins/hibernate4/class-use/ValidationConfiguration.html b/dist/hibernate4-maven-plugin-1.1.0/apidocs/de/juplo/plugins/hibernate4/class-use/ValidationConfiguration.html deleted file mode 100644 index cf55289a..00000000 --- a/dist/hibernate4-maven-plugin-1.1.0/apidocs/de/juplo/plugins/hibernate4/class-use/ValidationConfiguration.html +++ /dev/null @@ -1,117 +0,0 @@ - - - - - - -Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.0/apidocs/de/juplo/plugins/hibernate4/package-frame.html b/dist/hibernate4-maven-plugin-1.1.0/apidocs/de/juplo/plugins/hibernate4/package-frame.html deleted file mode 100644 index bb0bfca8..00000000 --- a/dist/hibernate4-maven-plugin-1.1.0/apidocs/de/juplo/plugins/hibernate4/package-frame.html +++ /dev/null @@ -1,22 +0,0 @@ - - - - - - -Class | -Description | -
---|---|
Hbm2DdlMojo | -
- Goal which extracts the hibernate-mapping-configuration and
- exports an according SQL-database-schema.
- |
-
HelpMojo | -
- Display help information on hibernate4-maven-plugin.
- |
-
ValidationConfiguration | -
- This integration is usually performed by BeanValidationIntegrator.
- |
-
Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.0/apidocs/de/juplo/plugins/hibernate4/package-tree.html b/dist/hibernate4-maven-plugin-1.1.0/apidocs/de/juplo/plugins/hibernate4/package-tree.html deleted file mode 100644 index 231a7ebc..00000000 --- a/dist/hibernate4-maven-plugin-1.1.0/apidocs/de/juplo/plugins/hibernate4/package-tree.html +++ /dev/null @@ -1,140 +0,0 @@ - - - - - - -Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.0/apidocs/de/juplo/plugins/hibernate4/package-use.html b/dist/hibernate4-maven-plugin-1.1.0/apidocs/de/juplo/plugins/hibernate4/package-use.html deleted file mode 100644 index 7a8f5c09..00000000 --- a/dist/hibernate4-maven-plugin-1.1.0/apidocs/de/juplo/plugins/hibernate4/package-use.html +++ /dev/null @@ -1,117 +0,0 @@ - - - - - - -Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.0/apidocs/deprecated-list.html b/dist/hibernate4-maven-plugin-1.1.0/apidocs/deprecated-list.html deleted file mode 100644 index 259e24e5..00000000 --- a/dist/hibernate4-maven-plugin-1.1.0/apidocs/deprecated-list.html +++ /dev/null @@ -1,117 +0,0 @@ - - - - - - -Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.0/apidocs/help-doc.html b/dist/hibernate4-maven-plugin-1.1.0/apidocs/help-doc.html deleted file mode 100644 index 88083e88..00000000 --- a/dist/hibernate4-maven-plugin-1.1.0/apidocs/help-doc.html +++ /dev/null @@ -1,222 +0,0 @@ - - - - - - -The Overview page is the front page of this API document and provides a list of all packages with a summary for each. This page can also contain an overall description of the set of packages.
-Each package has a page that contains a list of its classes and interfaces, with a summary for each. This page can contain six categories:
-Each class, interface, nested class and nested interface has its own separate page. Each of these pages has three sections consisting of a class/interface description, summary tables, and detailed member descriptions:
-Each summary entry contains the first sentence from the detailed description for that item. The summary entries are alphabetical, while the detailed descriptions are in the order they appear in the source code. This preserves the logical groupings established by the programmer.
-Each annotation type has its own separate page with the following sections:
-Each enum has its own separate page with the following sections:
-Each documented package, class and interface has its own Use page. This page describes what packages, classes, methods, constructors and fields use any part of the given class or package. Given a class or interface A, its Use page includes subclasses of A, fields declared as A, methods that return A, and methods and constructors with parameters of type A. You can access this page by first going to the package, class or interface, then clicking on the "Use" link in the navigation bar.
-There is a Class Hierarchy page for all packages, plus a hierarchy for each package. Each hierarchy page contains a list of classes and a list of interfaces. The classes are organized by inheritance structure starting with java.lang.Object
. The interfaces do not inherit from java.lang.Object
.
The Deprecated API page lists all of the API that have been deprecated. A deprecated API is not recommended for use, generally due to improvements, and a replacement API is usually given. Deprecated APIs may be removed in future implementations.
-The Index contains an alphabetic list of all classes, interfaces, constructors, methods, and fields.
-These links take you to the next or previous class, interface, package, or related page.
-These links show and hide the HTML frames. All pages are available with or without frames.
-The All Classes link shows all classes and interfaces except non-static nested types.
-Each serializable or externalizable class has a description of its serialization fields and methods. This information is of interest to re-implementors, not to developers using the API. While there is no link in the navigation bar, you can get to this information by going to any serialized class and clicking "Serialized Form" in the "See also" section of the class description.
-The Constant Field Values page lists the static final fields and their values.
-Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.0/apidocs/index-all.html b/dist/hibernate4-maven-plugin-1.1.0/apidocs/index-all.html deleted file mode 100644 index c63b6ce0..00000000 --- a/dist/hibernate4-maven-plugin-1.1.0/apidocs/index-all.html +++ /dev/null @@ -1,255 +0,0 @@ - - - - - - -TypeSafeActivator
- which itself is visible in the package only.Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.0/apidocs/index.html b/dist/hibernate4-maven-plugin-1.1.0/apidocs/index.html deleted file mode 100644 index 26f15f76..00000000 --- a/dist/hibernate4-maven-plugin-1.1.0/apidocs/index.html +++ /dev/null @@ -1,75 +0,0 @@ - - - - - - -This document is designed to be viewed using the frames feature. If you see this message, you are using a non-frame-capable web client. Link to Non-frame version.
-public class TypeSafeActivatorAccessor -extends Object-
TypeSafeActivator
- which itself is visible in the package only.Constructor and Description | -
---|
TypeSafeActivatorAccessor() |
-
Modifier and Type | -Method and Description | -
---|---|
static void |
-activate(org.hibernate.cfg.beanvalidation.ActivationContext arg0) |
-
static void |
-applyCallbackListeners(javax.validation.ValidatorFactory arg0,
- org.hibernate.cfg.beanvalidation.ActivationContext arg1) |
-
static void |
-applyRelationalConstraints(javax.validation.ValidatorFactory arg0,
- Collection<org.hibernate.mapping.PersistentClass> arg1,
- Properties arg2,
- org.hibernate.dialect.Dialect arg3) |
-
static void |
-validateSuppliedFactory(Object arg0) |
-
public TypeSafeActivatorAccessor()-
public static void validateSuppliedFactory(Object arg0)-
public static void activate(org.hibernate.cfg.beanvalidation.ActivationContext arg0)-
public static void applyCallbackListeners(javax.validation.ValidatorFactory arg0, - org.hibernate.cfg.beanvalidation.ActivationContext arg1)-
public static void applyRelationalConstraints(javax.validation.ValidatorFactory arg0, - Collection<org.hibernate.mapping.PersistentClass> arg1, - Properties arg2, - org.hibernate.dialect.Dialect arg3)-
Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.0/apidocs/org/hibernate/cfg/beanvalidation/class-use/TypeSafeActivatorAccessor.html b/dist/hibernate4-maven-plugin-1.1.0/apidocs/org/hibernate/cfg/beanvalidation/class-use/TypeSafeActivatorAccessor.html deleted file mode 100644 index c50ac840..00000000 --- a/dist/hibernate4-maven-plugin-1.1.0/apidocs/org/hibernate/cfg/beanvalidation/class-use/TypeSafeActivatorAccessor.html +++ /dev/null @@ -1,117 +0,0 @@ - - - - - - -Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.0/apidocs/org/hibernate/cfg/beanvalidation/package-frame.html b/dist/hibernate4-maven-plugin-1.1.0/apidocs/org/hibernate/cfg/beanvalidation/package-frame.html deleted file mode 100644 index e12853e1..00000000 --- a/dist/hibernate4-maven-plugin-1.1.0/apidocs/org/hibernate/cfg/beanvalidation/package-frame.html +++ /dev/null @@ -1,20 +0,0 @@ - - - - - - -Class | -Description | -
---|---|
TypeSafeActivatorAccessor | -
- This class enables access to the public methods of
-TypeSafeActivator
- which itself is visible in the package only. |
-
Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.0/apidocs/org/hibernate/cfg/beanvalidation/package-tree.html b/dist/hibernate4-maven-plugin-1.1.0/apidocs/org/hibernate/cfg/beanvalidation/package-tree.html deleted file mode 100644 index 68adb2ed..00000000 --- a/dist/hibernate4-maven-plugin-1.1.0/apidocs/org/hibernate/cfg/beanvalidation/package-tree.html +++ /dev/null @@ -1,130 +0,0 @@ - - - - - - -Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.0/apidocs/org/hibernate/cfg/beanvalidation/package-use.html b/dist/hibernate4-maven-plugin-1.1.0/apidocs/org/hibernate/cfg/beanvalidation/package-use.html deleted file mode 100644 index 244ac61f..00000000 --- a/dist/hibernate4-maven-plugin-1.1.0/apidocs/org/hibernate/cfg/beanvalidation/package-use.html +++ /dev/null @@ -1,117 +0,0 @@ - - - - - - -Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.0/apidocs/overview-frame.html b/dist/hibernate4-maven-plugin-1.1.0/apidocs/overview-frame.html deleted file mode 100644 index 5a2f8715..00000000 --- a/dist/hibernate4-maven-plugin-1.1.0/apidocs/overview-frame.html +++ /dev/null @@ -1,22 +0,0 @@ - - - - - - -- - diff --git a/dist/hibernate4-maven-plugin-1.1.0/apidocs/overview-summary.html b/dist/hibernate4-maven-plugin-1.1.0/apidocs/overview-summary.html deleted file mode 100644 index 42e33d55..00000000 --- a/dist/hibernate4-maven-plugin-1.1.0/apidocs/overview-summary.html +++ /dev/null @@ -1,135 +0,0 @@ - - - - - - -
Package | -Description | -
---|---|
de.juplo.plugins.hibernate4 | -- |
org.hibernate.cfg.beanvalidation | -- |
Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.0/apidocs/overview-tree.html b/dist/hibernate4-maven-plugin-1.1.0/apidocs/overview-tree.html deleted file mode 100644 index aeca534d..00000000 --- a/dist/hibernate4-maven-plugin-1.1.0/apidocs/overview-tree.html +++ /dev/null @@ -1,142 +0,0 @@ - - - - - - -Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.0/apidocs/package-list b/dist/hibernate4-maven-plugin-1.1.0/apidocs/package-list deleted file mode 100644 index b80422d3..00000000 --- a/dist/hibernate4-maven-plugin-1.1.0/apidocs/package-list +++ /dev/null @@ -1,2 +0,0 @@ -de.juplo.plugins.hibernate4 -org.hibernate.cfg.beanvalidation diff --git a/dist/hibernate4-maven-plugin-1.1.0/apidocs/packages b/dist/hibernate4-maven-plugin-1.1.0/apidocs/packages deleted file mode 100644 index ad55515c..00000000 --- a/dist/hibernate4-maven-plugin-1.1.0/apidocs/packages +++ /dev/null @@ -1,2 +0,0 @@ -de.juplo.plugins.hibernate4 -org.hibernate.cfg.beanvalidation \ No newline at end of file diff --git a/dist/hibernate4-maven-plugin-1.1.0/apidocs/resources/background.gif b/dist/hibernate4-maven-plugin-1.1.0/apidocs/resources/background.gif deleted file mode 100644 index f471940f..00000000 Binary files a/dist/hibernate4-maven-plugin-1.1.0/apidocs/resources/background.gif and /dev/null differ diff --git a/dist/hibernate4-maven-plugin-1.1.0/apidocs/resources/tab.gif b/dist/hibernate4-maven-plugin-1.1.0/apidocs/resources/tab.gif deleted file mode 100644 index 1a73a83b..00000000 Binary files a/dist/hibernate4-maven-plugin-1.1.0/apidocs/resources/tab.gif and /dev/null differ diff --git a/dist/hibernate4-maven-plugin-1.1.0/apidocs/resources/titlebar.gif b/dist/hibernate4-maven-plugin-1.1.0/apidocs/resources/titlebar.gif deleted file mode 100644 index 17443b3e..00000000 Binary files a/dist/hibernate4-maven-plugin-1.1.0/apidocs/resources/titlebar.gif and /dev/null differ diff --git a/dist/hibernate4-maven-plugin-1.1.0/apidocs/resources/titlebar_end.gif b/dist/hibernate4-maven-plugin-1.1.0/apidocs/resources/titlebar_end.gif deleted file mode 100644 index 3ad78d46..00000000 Binary files a/dist/hibernate4-maven-plugin-1.1.0/apidocs/resources/titlebar_end.gif and /dev/null differ diff --git a/dist/hibernate4-maven-plugin-1.1.0/apidocs/serialized-form.html b/dist/hibernate4-maven-plugin-1.1.0/apidocs/serialized-form.html deleted file mode 100644 index b9a71e37..00000000 --- a/dist/hibernate4-maven-plugin-1.1.0/apidocs/serialized-form.html +++ /dev/null @@ -1,174 +0,0 @@ - - - - - - -javax.validation.ValidatorFactory factory-
ConcurrentHashMap<K,V> associationsPerEntityPersister-
org.hibernate.cfg.beanvalidation.GroupsPerOperation groupsPerOperation-
boolean initialized-
Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.0/apidocs/stylesheet.css b/dist/hibernate4-maven-plugin-1.1.0/apidocs/stylesheet.css deleted file mode 100644 index 0aeaa97f..00000000 --- a/dist/hibernate4-maven-plugin-1.1.0/apidocs/stylesheet.css +++ /dev/null @@ -1,474 +0,0 @@ -/* Javadoc style sheet */ -/* -Overall document style -*/ -body { - background-color:#ffffff; - color:#353833; - font-family:Arial, Helvetica, sans-serif; - font-size:76%; - margin:0; -} -a:link, a:visited { - text-decoration:none; - color:#4c6b87; -} -a:hover, a:focus { - text-decoration:none; - color:#bb7a2a; -} -a:active { - text-decoration:none; - color:#4c6b87; -} -a[name] { - color:#353833; -} -a[name]:hover { - text-decoration:none; - color:#353833; -} -pre { - font-size:1.3em; -} -h1 { - font-size:1.8em; -} -h2 { - font-size:1.5em; -} -h3 { - font-size:1.4em; -} -h4 { - font-size:1.3em; -} -h5 { - font-size:1.2em; -} -h6 { - font-size:1.1em; -} -ul { - list-style-type:disc; -} -code, tt { - font-size:1.2em; -} -dt code { - font-size:1.2em; -} -table tr td dt code { - font-size:1.2em; - vertical-align:top; -} -sup { - font-size:.6em; -} -/* -Document title and Copyright styles -*/ -.clear { - clear:both; - height:0px; - overflow:hidden; -} -.aboutLanguage { - float:right; - padding:0px 21px; - font-size:.8em; - z-index:200; - margin-top:-7px; -} -.legalCopy { - margin-left:.5em; -} -.bar a, .bar a:link, .bar a:visited, .bar a:active { - color:#FFFFFF; - text-decoration:none; -} -.bar a:hover, .bar a:focus { - color:#bb7a2a; -} -.tab { - background-color:#0066FF; - background-image:url(resources/titlebar.gif); - background-position:left top; - background-repeat:no-repeat; - color:#ffffff; - padding:8px; - width:5em; - font-weight:bold; -} -/* -Navigation bar styles -*/ -.bar { - background-image:url(resources/background.gif); - background-repeat:repeat-x; - color:#FFFFFF; - padding:.8em .5em .4em .8em; - height:auto;/*height:1.8em;*/ - font-size:1em; - margin:0; -} -.topNav { - background-image:url(resources/background.gif); - background-repeat:repeat-x; - color:#FFFFFF; - float:left; - padding:0; - width:100%; - clear:right; - height:2.8em; - padding-top:10px; - overflow:hidden; -} -.bottomNav { - margin-top:10px; - background-image:url(resources/background.gif); - background-repeat:repeat-x; - color:#FFFFFF; - float:left; - padding:0; - width:100%; - clear:right; - height:2.8em; - padding-top:10px; - overflow:hidden; -} -.subNav { - background-color:#dee3e9; - border-bottom:1px solid #9eadc0; - float:left; - width:100%; - overflow:hidden; -} -.subNav div { - clear:left; - float:left; - padding:0 0 5px 6px; -} -ul.navList, ul.subNavList { - float:left; - margin:0 25px 0 0; - padding:0; -} -ul.navList li{ - list-style:none; - float:left; - padding:3px 6px; -} -ul.subNavList li{ - list-style:none; - float:left; - font-size:90%; -} -.topNav a:link, .topNav a:active, .topNav a:visited, .bottomNav a:link, .bottomNav a:active, .bottomNav a:visited { - color:#FFFFFF; - text-decoration:none; -} -.topNav a:hover, .bottomNav a:hover { - text-decoration:none; - color:#bb7a2a; -} -.navBarCell1Rev { - background-image:url(resources/tab.gif); - background-color:#a88834; - color:#FFFFFF; - margin: auto 5px; - border:1px solid #c9aa44; -} -/* -Page header and footer styles -*/ -.header, .footer { - clear:both; - margin:0 20px; - padding:5px 0 0 0; -} -.indexHeader { - margin:10px; - position:relative; -} -.indexHeader h1 { - font-size:1.3em; -} -.title { - color:#2c4557; - margin:10px 0; -} -.subTitle { - margin:5px 0 0 0; -} -.header ul { - margin:0 0 25px 0; - padding:0; -} -.footer ul { - margin:20px 0 5px 0; -} -.header ul li, .footer ul li { - list-style:none; - font-size:1.2em; -} -/* -Heading styles -*/ -div.details ul.blockList ul.blockList ul.blockList li.blockList h4, div.details ul.blockList ul.blockList ul.blockListLast li.blockList h4 { - background-color:#dee3e9; - border-top:1px solid #9eadc0; - border-bottom:1px solid #9eadc0; - margin:0 0 6px -8px; - padding:2px 5px; -} -ul.blockList ul.blockList ul.blockList li.blockList h3 { - background-color:#dee3e9; - border-top:1px solid #9eadc0; - border-bottom:1px solid #9eadc0; - margin:0 0 6px -8px; - padding:2px 5px; -} -ul.blockList ul.blockList li.blockList h3 { - padding:0; - margin:15px 0; -} -ul.blockList li.blockList h2 { - padding:0px 0 20px 0; -} -/* -Page layout container styles -*/ -.contentContainer, .sourceContainer, .classUseContainer, .serializedFormContainer, .constantValuesContainer { - clear:both; - padding:10px 20px; - position:relative; -} -.indexContainer { - margin:10px; - position:relative; - font-size:1.0em; -} -.indexContainer h2 { - font-size:1.1em; - padding:0 0 3px 0; -} -.indexContainer ul { - margin:0; - padding:0; -} -.indexContainer ul li { - list-style:none; -} -.contentContainer .description dl dt, .contentContainer .details dl dt, .serializedFormContainer dl dt { - font-size:1.1em; - font-weight:bold; - margin:10px 0 0 0; - color:#4E4E4E; -} -.contentContainer .description dl dd, .contentContainer .details dl dd, .serializedFormContainer dl dd { - margin:10px 0 10px 20px; -} -.serializedFormContainer dl.nameValue dt { - margin-left:1px; - font-size:1.1em; - display:inline; - font-weight:bold; -} -.serializedFormContainer dl.nameValue dd { - margin:0 0 0 1px; - font-size:1.1em; - display:inline; -} -/* -List styles -*/ -ul.horizontal li { - display:inline; - font-size:0.9em; -} -ul.inheritance { - margin:0; - padding:0; -} -ul.inheritance li { - display:inline; - list-style:none; -} -ul.inheritance li ul.inheritance { - margin-left:15px; - padding-left:15px; - padding-top:1px; -} -ul.blockList, ul.blockListLast { - margin:10px 0 10px 0; - padding:0; -} -ul.blockList li.blockList, ul.blockListLast li.blockList { - list-style:none; - margin-bottom:25px; -} -ul.blockList ul.blockList li.blockList, ul.blockList ul.blockListLast li.blockList { - padding:0px 20px 5px 10px; - border:1px solid #9eadc0; - background-color:#f9f9f9; -} -ul.blockList ul.blockList ul.blockList li.blockList, ul.blockList ul.blockList ul.blockListLast li.blockList { - padding:0 0 5px 8px; - background-color:#ffffff; - border:1px solid #9eadc0; - border-top:none; -} -ul.blockList ul.blockList ul.blockList ul.blockList li.blockList { - margin-left:0; - padding-left:0; - padding-bottom:15px; - border:none; - border-bottom:1px solid #9eadc0; -} -ul.blockList ul.blockList ul.blockList ul.blockList li.blockListLast { - list-style:none; - border-bottom:none; - padding-bottom:0; -} -table tr td dl, table tr td dl dt, table tr td dl dd { - margin-top:0; - margin-bottom:1px; -} -/* -Table styles -*/ -.contentContainer table, .classUseContainer table, .constantValuesContainer table { - border-bottom:1px solid #9eadc0; - width:100%; -} -.contentContainer ul li table, .classUseContainer ul li table, .constantValuesContainer ul li table { - width:100%; -} -.contentContainer .description table, .contentContainer .details table { - border-bottom:none; -} -.contentContainer ul li table th.colOne, .contentContainer ul li table th.colFirst, .contentContainer ul li table th.colLast, .classUseContainer ul li table th, .constantValuesContainer ul li table th, .contentContainer ul li table td.colOne, .contentContainer ul li table td.colFirst, .contentContainer ul li table td.colLast, .classUseContainer ul li table td, .constantValuesContainer ul li table td{ - vertical-align:top; - padding-right:20px; -} -.contentContainer ul li table th.colLast, .classUseContainer ul li table th.colLast,.constantValuesContainer ul li table th.colLast, -.contentContainer ul li table td.colLast, .classUseContainer ul li table td.colLast,.constantValuesContainer ul li table td.colLast, -.contentContainer ul li table th.colOne, .classUseContainer ul li table th.colOne, -.contentContainer ul li table td.colOne, .classUseContainer ul li table td.colOne { - padding-right:3px; -} -.overviewSummary caption, .packageSummary caption, .contentContainer ul.blockList li.blockList caption, .summary caption, .classUseContainer caption, .constantValuesContainer caption { - position:relative; - text-align:left; - background-repeat:no-repeat; - color:#FFFFFF; - font-weight:bold; - clear:none; - overflow:hidden; - padding:0px; - margin:0px; -} -caption a:link, caption a:hover, caption a:active, caption a:visited { - color:#FFFFFF; -} -.overviewSummary caption span, .packageSummary caption span, .contentContainer ul.blockList li.blockList caption span, .summary caption span, .classUseContainer caption span, .constantValuesContainer caption span { - white-space:nowrap; - padding-top:8px; - padding-left:8px; - display:block; - float:left; - background-image:url(resources/titlebar.gif); - height:18px; -} -.overviewSummary .tabEnd, .packageSummary .tabEnd, .contentContainer ul.blockList li.blockList .tabEnd, .summary .tabEnd, .classUseContainer .tabEnd, .constantValuesContainer .tabEnd { - width:10px; - background-image:url(resources/titlebar_end.gif); - background-repeat:no-repeat; - background-position:top right; - position:relative; - float:left; -} -ul.blockList ul.blockList li.blockList table { - margin:0 0 12px 0px; - width:100%; -} -.tableSubHeadingColor { - background-color: #EEEEFF; -} -.altColor { - background-color:#eeeeef; -} -.rowColor { - background-color:#ffffff; -} -.overviewSummary td, .packageSummary td, .contentContainer ul.blockList li.blockList td, .summary td, .classUseContainer td, .constantValuesContainer td { - text-align:left; - padding:3px 3px 3px 7px; -} -th.colFirst, th.colLast, th.colOne, .constantValuesContainer th { - background:#dee3e9; - border-top:1px solid #9eadc0; - border-bottom:1px solid #9eadc0; - text-align:left; - padding:3px 3px 3px 7px; -} -td.colOne a:link, td.colOne a:active, td.colOne a:visited, td.colOne a:hover, td.colFirst a:link, td.colFirst a:active, td.colFirst a:visited, td.colFirst a:hover, td.colLast a:link, td.colLast a:active, td.colLast a:visited, td.colLast a:hover, .constantValuesContainer td a:link, .constantValuesContainer td a:active, .constantValuesContainer td a:visited, .constantValuesContainer td a:hover { - font-weight:bold; -} -td.colFirst, th.colFirst { - border-left:1px solid #9eadc0; - white-space:nowrap; -} -td.colLast, th.colLast { - border-right:1px solid #9eadc0; -} -td.colOne, th.colOne { - border-right:1px solid #9eadc0; - border-left:1px solid #9eadc0; -} -table.overviewSummary { - padding:0px; - margin-left:0px; -} -table.overviewSummary td.colFirst, table.overviewSummary th.colFirst, -table.overviewSummary td.colOne, table.overviewSummary th.colOne { - width:25%; - vertical-align:middle; -} -table.packageSummary td.colFirst, table.overviewSummary th.colFirst { - width:25%; - vertical-align:middle; -} -/* -Content styles -*/ -.description pre { - margin-top:0; -} -.deprecatedContent { - margin:0; - padding:10px 0; -} -.docSummary { - padding:0; -} -/* -Formatting effect styles -*/ -.sourceLineNo { - color:green; - padding:0 30px 0 0; -} -h1.hidden { - visibility:hidden; - overflow:hidden; - font-size:.9em; -} -.block { - display:block; - margin:3px 0 0 0; -} -.strong { - font-weight:bold; -} diff --git a/dist/hibernate4-maven-plugin-1.1.0/configuration.html b/dist/hibernate4-maven-plugin-1.1.0/configuration.html deleted file mode 100644 index 0a3acd2d..00000000 --- a/dist/hibernate4-maven-plugin-1.1.0/configuration.html +++ /dev/null @@ -1,386 +0,0 @@ - - - - - - - - -- The most simple way to configure the plugin is, to put all the - hibernate-configuration in a hibernate.properties-file on your - classpath. Put the file in the resources-folder. Maven will put - it in the class-folder of your webapp, where it will be picked up - by this plugin as well as by Hibernate 4. -
- -- Doing so, the only additionally configuration needed, to activat the plugin - is the following entry in the plugins-section of your pom.xml: -
- --<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.1.0</version> - <executions> - <execution> - <goals> - <goal>export</goal> - </goals> - </execution> - </executions> -</plugin>
- But be aware, that in this case the database-url, that is - build in the application is the same that is used while testing, where - the database is droped and recreated by the plugin. - Because of that, - - you should never fire up this configuration on your production - system, or your database might be erased! - -
- -- A better approach is, to specify a different url for testing like in the - following snippet: -
- --<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.1.0</version> - <executions> - <execution> - <goals> - <goal>export</goal> - </goals> - </execution> - </executions> - <configuration> - <url><![CDATA[jdbc:mysql://localhost/test-db]]></url> - </configuration> -</plugin>
- Configuration properties, that are set in the configuration-section - of the plugin-configuration cannnot be overwritten elsewere (for details - see Configuration-Method-Precedence). - You never can overwrite them by accident when specifying a property on - the commandline or in your settings.xml. -
-- Alternatively, it is possible, to configure the plugin via maven-properties. - Each relevant configuration-option has a corresponding maven-property - (for a full list see the Documentation of the export-Mojo). - These are named after the - Hibernate JDBC Properties: -
- -- So, instead of writing the hibernate-configuration in the properties-file, - like above, you could put it in the properties-section of your - pom.xml. -
- -- Thogether with the plugin-definition from above, the following would - be a complete configuration (again, the database-url was overwritten in - the plugin-configuration, to be sure to have a separate database for - testing): -
- --<properties> - <hibernate.connection.driver_class>org.hsqldb.jdbcDriver</hibernate.connection.driver_class> - <hibernate.dialect>org.hibernate.dialect.HSQLDialect</hibernate.dialect> - <hibernate.connection.url><![CDATA[jdbc:hsqldb:res:org.my.path.production_db]]></hibernate.connection.url> - <hibernate.connection.username>sa</hibernate.connection.username> - <hibernate.connection.password></hibernate.connection.password> -</properties> - -... - -<plugins> - - ... - - <plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.1.0</version> - <executions> - <execution> - <goals> - <goal>export</goal> - </goals> - </execution> - </executions> - <configuration> - <url><![CDATA[jdbc:hsqldb:target/db/testdb;shutdown=true]]></url> - </configuration> - </plugin> - -<plugins>
- A third way for configuring the plugin is the plugin-configuration. - The relevant configuration-parameters are: -
- -- The equivalent of the configuration from the last section would look - like this: -
- --<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.1.0</version> - <executions> - <execution> - <goals> - <goal>export</goal> - </goals> - </execution> - </executions> - <configuration> - <driverClassName>org.hsqldb.jdbcDriver</driverClassName> - <hibernateDialect>org.hibernate.dialect.HSQLDialect</hibernateDialect> - <url><![CDATA[jdbc:hsqldb:target/db/fotos;shutdown=true]]></url> - <username>sa</username> - <password></password> - </configuration> -</plugin>
- The parameter hibernateProperties (name of the hibernate-properties-file - to use, defaults to hibernate.properties) can only be configured through - this approach. -
- -- For more explanations, see the - Documentation of the export-Mojo. -
-- The configuration is gathered in a fix order: -
- -- If you are in doubt about where a configuration-value comes from, run - maven with the debug-output enabled: mvn -X hibernate4:export - and be aware, that maven-properties can be overwitten on the command-line, - in your ~/.m2/settings.xml and in a profile. -
- -- The plugin-configuration comes last and overwrites everything else. - That way, you can be sure, that a configuration-value, that is - specified in the plugin-configuration will never be overwritten by any - other configuration-method. -
- -- If you need to overwrite plugin-configuration-values with - maven-properties, you can use maven-properties in the plugin-configuration: -
- --<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.1.0</version> - <executions> - <execution> - <goals> - <goal>export</goal> - </goals> - </execution> - </executions> - <configuration> - <password>${my-password-property}</password> - </configuration> -</plugin>
- If you are new to hibernate4-maven-plugin, in many cases, the - {Configuration-Method-Precedence} may be the source of configuration - errors. - To solve this problem, you should run maven with the debugging output - enabled. - For example, by executing: -
- --mvn -X compile hibernate4:export
- (The compile might be necessary, because hibernate4-maven-plugin - has to scan the compiled classes for annotations!) -
- -- Unlike the majority of the maven-plugins, hibernate4-maven-plugin was - designed to give a good many hints, when debugging is enabled. - Because, if you do not know, what went wrong, you can't fix it! -
- -- But be warned: hibernate4-maven-plugin tends to be very chatty ;) -
- - -The following is a list of compile dependencies for this project. These dependencies are required to compile and run the application:
-GroupId | -ArtifactId | -Version | -Type | -License |
---|---|---|---|---|
com.pyx4j | -maven-plugin-log4j | -1.0.1 | -jar | -The Apache Software License, Version 2.0 |
de.juplo | -scannotation | -1.0.4 | -jar | -- |
javax.el | -javax.el-api | -3.0.0 | -jar | -CDDL + GPLv2 with classpath exception |
org.apache.maven | -maven-core | -3.3.3 | -jar | -Apache License, Version 2.0 |
org.apache.maven | -maven-plugin-api | -3.3.3 | -jar | -Apache License, Version 2.0 |
org.hibernate | -hibernate-core | -4.3.9.Final | -jar | -GNU Lesser General Public License |
org.hibernate | -hibernate-envers | -4.3.9.Final | -jar | -GNU Lesser General Public License |
org.hibernate | -hibernate-validator | -5.1.3.Final | -jar | -Apache License, Version 2.0 |
The following is a list of transitive dependencies for this project. Transitive dependencies are the dependencies of the project dependencies.
-The following is a list of compile dependencies for this project. These dependencies are required to compile and run the application:
-Apache Public License 2.0: Plexus Cipher: encryption/decryption Component, Plexus Security Dispatcher Component
-Apache License, version 2.0: JBoss Logging 3
-CDDL + GPLv2 with classpath exception: Expression Language 3.0 API
-Public Domain: AOP alliance, JBoss Logging I18n Annotations
-Unknown: dom4j, scannotation
-Common Development and Distribution License: Java Transaction API
-LGPL 2.1: Javassist
-Apache License, Version 2.0: CDI APIs, Hibernate Validator Engine, Maven Aether Provider, Maven Artifact, Maven Builder Support, Maven Core, Maven Model, Maven Model Builder, Maven Plugin API, Maven Repository Metadata Model, Maven Settings, Maven Settings Builder
-MPL 1.1: Javassist
-GNU General Public License, Version 2 with the Classpath Exception: Java Transaction API
-COMMON DEVELOPMENT AND DISTRIBUTION LICENSE (CDDL) Version 1.0: JSR-250 Common Annotations for the JavaTM Platform
-The Apache Software License, Version 2.0: Bean Validation API, ClassMate, Guava: Google Core Libraries for Java, Hibernate 4 Maven Plugin, Log4j, Plexus :: Component Annotations, Plexus Classworlds, Plexus Interpolation API, Sisu Guice - Core Library, XML Commons External Components XML APIs, javax.inject, maven-plugin-log4j
-GNU Lesser General Public License: Core Hibernate O/RM functionality, Entity versioning support, Hibernate Commons Annotations, Hibernate JPA Support
-Eclipse Public License (EPL), Version 1.0: Java Persistence API, Version 2.1
-BSD License: AntLR Parser Generator
-AL 2.0: Java Annotation Indexer
-Apache License 2.0: Javassist
-Eclipse Public License, Version 1.0: Aether API, Aether Implementation, Aether SPI, Aether Utilities, org.eclipse.sisu.inject, org.eclipse.sisu.plexus
-Eclipse Distribution License (EDL), Version 1.0: Java Persistence API, Version 2.1
Filename | -Size | -Entries | -Classes | -Packages | -JDK Rev | -Debug |
---|---|---|---|---|---|---|
antlr-2.7.7.jar | -434.85 kB | -239 | -224 | -12 | -1.2 | -debug |
aopalliance-1.0.jar | -4.36 kB | -15 | -9 | -2 | -1.3 | -debug |
classmate-1.0.0.jar | -58.87 kB | -51 | -36 | -4 | -1.6 | -debug |
guava-18.0.jar | -2.15 MB | -1,719 | -1,690 | -17 | -1.6 | -debug |
maven-plugin-log4j-1.0.1.jar | -3.64 kB | -12 | -1 | -1 | -1.4 | -debug |
scannotation-1.0.4.jar | -19.79 kB | -23 | -13 | -2 | -1.6 | -debug |
dom4j-1.6.1.jar | -306.54 kB | -208 | -190 | -14 | -1.3 | -debug |
jsr250-api-1.0.jar | -5.71 kB | -16 | -11 | -2 | -1.5 | -debug |
javax.el-api-3.0.0.jar | -71.35 kB | -57 | -46 | -1 | -1.6 | -debug |
cdi-api-1.0.jar | -43.86 kB | -92 | -75 | -7 | -1.5 | -debug |
javax.inject-1.jar | -2.44 kB | -8 | -6 | -1 | -1.5 | -release |
validation-api-1.1.0.Final.jar | -62.28 kB | -122 | -106 | -8 | -1.6 | -debug |
log4j-1.2.14.jar | -358.83 kB | -288 | -256 | -19 | -1.1 | -debug |
maven-aether-provider-3.3.3.jar | -64.79 kB | -43 | -26 | -1 | -1.6 | -debug |
maven-artifact-3.3.3.jar | -53.80 kB | -57 | -32 | -11 | -1.6 | -debug |
maven-builder-support-3.3.3.jar | -14.61 kB | -24 | -10 | -1 | -1.6 | -debug |
maven-core-3.3.3.jar | -617.07 kB | -489 | -390 | -56 | -1.6 | -debug |
maven-model-3.3.3.jar | -157.05 kB | -67 | -50 | -3 | -1.6 | -debug |
maven-model-builder-3.3.3.jar | -172.28 kB | -154 | -121 | -16 | -1.6 | -debug |
maven-plugin-api-3.3.3.jar | -45.02 kB | -46 | -25 | -6 | -1.6 | -debug |
maven-repository-metadata-3.3.3.jar | -25.35 kB | -25 | -7 | -2 | -1.6 | -debug |
maven-settings-3.3.3.jar | -42.02 kB | -33 | -17 | -2 | -1.6 | -debug |
maven-settings-builder-3.3.3.jar | -42.14 kB | -53 | -32 | -5 | -1.6 | -debug |
plexus-classworlds-2.5.2.jar | -51.45 kB | -52 | -37 | -5 | -1.6 | -debug |
plexus-component-annotations-1.5.5.jar | -4.11 kB | -15 | -3 | -1 | -1.5 | -release |
plexus-interpolation-1.21.jar | -60.99 kB | -60 | -44 | -6 | -1.5 | -debug |
aether-api-1.0.2.v20150114.jar | -133.13 kB | -149 | -128 | -11 | -1.5 | -debug |
aether-impl-1.0.2.v20150114.jar | -168.94 kB | -114 | -96 | -4 | -1.5 | -debug |
aether-spi-1.0.2.v20150114.jar | -29.99 kB | -54 | -34 | -8 | -1.5 | -debug |
aether-util-1.0.2.v20150114.jar | -143.43 kB | -126 | -101 | -13 | -1.5 | -debug |
org.eclipse.sisu.inject-0.3.0.jar | -366.47 kB | -287 | -269 | -9 | -1.6 | -debug |
org.eclipse.sisu.plexus-0.3.0.jar | -200.59 kB | -196 | -164 | -20 | -1.6 | -debug |
hibernate-core-4.3.9.Final.jar | -5.03 MB | -3,712 | -3,463 | -201 | -1.6 | -debug |
hibernate-entitymanager-4.3.9.Final.jar | -632.39 kB | -486 | -443 | -27 | -1.6 | -debug |
hibernate-envers-4.3.9.Final.jar | -417.62 kB | -311 | -259 | -38 | -1.6 | -debug |
hibernate-validator-5.1.3.Final.jar | -619.40 kB | -483 | -410 | -41 | -1.6 | -debug |
hibernate-commons-annotations-4.0.5.Final.jar | -73.56 kB | -79 | -67 | -7 | -1.6 | -debug |
hibernate-jpa-2.1-api-1.0.0.Final.jar | -110.71 kB | -207 | -200 | -4 | -1.6 | -debug |
javassist-3.18.1-GA.jar | -697.46 kB | -414 | -390 | -17 | -1.6 | -debug |
jandex-1.1.0.Final.jar | -74.76 kB | -55 | -44 | -1 | -1.6 | -debug |
jboss-logging-3.1.3.GA.jar | -55.84 kB | -57 | -45 | -1 | -1.6 | -debug |
jboss-logging-annotations-1.2.0.Beta1.jar | -11.29 kB | -28 | -16 | -1 | -1.6 | -debug |
jboss-transaction-api_1.2_spec-1.0.0.Final.jar | -27.07 kB | -35 | -22 | -2 | -1.6 | -debug |
plexus-cipher-1.4.jar | -13.18 kB | -20 | -6 | -1 | -1.4 | -debug |
plexus-sec-dispatcher-1.3.jar | -27.89 kB | -31 | -13 | -3 | -1.4 | -debug |
sisu-guice-3.2.5-no_aop.jar | -390.30 kB | -331 | -316 | -8 | -1.6 | -debug |
xml-apis-1.0.b2.jar | -106.76 kB | -217 | -184 | -17 | -1.2 | -release |
Total | -Size | -Entries | -Classes | -Packages | -JDK Rev | -Debug |
47 | -14.04 MB | -11,360 | -10,127 | -639 | -1.6 | -44 |
compile: 47 | -compile: 14.04 MB | -compile: 11,360 | -compile: 10,127 | -compile: 639 | -- | -compile: 44 |
Repo ID | -URL | -Release | -Snapshot |
---|---|---|---|
plexus.snapshots | -https://oss.sonatype.org/content/repositories/plexus-snapshots | -- | -Yes |
apache.snapshots | -http://repository.apache.org/snapshots | -- | -Yes |
sonatype-nexus-snapshots | -https://oss.sonatype.org/content/repositories/snapshots | -- | -Yes |
snapshots.jboss.org | -http://snapshots.jboss.org/maven2 | -- | -Yes |
oss.sonatype.org/jboss-snapshots | -http://oss.sonatype.org/content/repositories/jboss-snapshots | -- | -Yes |
central | -http://repo.maven.apache.org/maven2 | -Yes | -- |
repository.jboss.org | -http://repository.jboss.org/maven2 | -Yes | -- |
jvnet-nexus-snapshots | -https://maven.java.net/content/repositories/snapshots | -- | -Yes |
Repository locations for each of the Dependencies.
-<dependency> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.1.0</version> - <type>maven-plugin</type> -</dependency>
<dependency org="de.juplo" name="hibernate4-maven-plugin" rev="1.1.0"> - <artifact name="hibernate4-maven-plugin" type="maven-plugin" /> -</dependency>
The following is the distribution management information used by this project.
- -Full name:
- -de.juplo:hibernate4-maven-plugin:1.1.0:export
- -Description:
- -Attributes:
- -Name | - -Type | - -Since | - -Description | -
---|---|---|---|
delimiter | - -String | - -1.0 | - -Delimiter in output-file. Default value is: ;. User property is: hibernate.export.schema.delimiter. |
-
driverClassName | - -String | - -1.0 | - -SQL-Driver name. User property is: hibernate.connection.driver_class. |
-
envers | - -boolean | - -1.0.3 | - -Generate envers schema for auditing tables. Default value is: true. User property is: hibernate.export.envers. |
-
force | - -boolean | - -1.0 | - -Force execution
-
- Force execution, even if no modified or newly added annotated -classes where found and the dialect was not changed. - -skip takes precedence over force. Default value is: false. User property is: hibernate.export.force. |
-
format | - -boolean | - -1.0 | - -Format output-file. Default value is: true. User property is: hibernate.export.schema.format. |
-
hibernateConfig | - -String | - -1.1.0 | - -Path to Hibernate configuration file (.cfg.xml). Settings in this
-file will overwrite settings in the properties file. If this
-parameter is not set the plugin will try to load the configuration
-from a file hibernate.cfg.xml on the classpath. The
-test-classpath takes precedence. |
-
hibernateDialect | - -String | - -1.0 | - -Hibernate dialect. User property is: hibernate.dialect. |
-
hibernateMapping | - -String | - -1.0.2 | - -List of Hibernate-Mapping-Files (XML). Multiple files can be
-separated with white-spaces and/or commas. User property is: hibernate.mapping. |
-
hibernateNamingStrategy | - -String | - -1.0.2 | - -Hibernate Naming Strategy User property is: hibernate.ejb.naming_strategy. |
-
hibernateProperties | - -String | - -1.0 | - -Path to Hibernate properties file. If this parameter is not set the
-plugin will try to load the configuration from a file
-hibernate.properties on the classpath. The
-test-classpath takes precedence. |
-
outputDirectory | - -String | - -1.0 | - -Classes-Directory to scan.
-
- This parameter defaults to the maven build-output-directory for -classes. Additionally, all dependencies are scanned for annotated -classes. User property is: project.build.outputDirectory. |
-
outputFile | - -String | - -1.0 | - -Output file. Default value is: ${project.build.directory}/schema.sql. User property is: hibernate.export.schema.filename. |
-
password | - -String | - -1.0 | - -Database password User property is: hibernate.connection.password. |
-
persistenceUnit | - -String | - -1.1.0 | - -Name of the persistence-unit. If there is only one persistence-unit
-available, that unit will be used automatically. Settings in this
-file will overwrite settings in the properties or the configuration
-file. |
-
scanDependencies | - -String | - -1.0.3 | - -Dependency-Scopes, that should be scanned for annotated classes.
-
- By default, only dependencies in the scope compile -are scanned for annotated classes. Multiple scopes can be seperated -by white space or commas. - -If you do not want any dependencies to be scanned for annotated -classes, set this parameter to none. - -The plugin does not scan for annotated classes in transitive -dependencies. If some of your annotated classes are hidden in a -transitive dependency, you can simply add that dependency -explicitly. Default value is: compile. User property is: hibernate.export.scan_dependencies. |
-
scanTestClasses | - -boolean | - -1.0.1 | - -Whether to scan test-classes too, or not.
-
- If this parameter is set to true the test-classes -of the artifact will be scanned for hibernate-annotated classes -additionally. Default value is: false. User property is: hibernate.export.scan_testclasses. |
-
skip | - -boolean | - -1.0 | - -Skip execution
-
- If set to true, the execution is skipped. - -A skipped execution is signaled via the maven-property -${hibernate.export.skipped}. - -The execution is skipped automatically, if no modified or newly -added annotated classes are found and the dialect was not -changed. Default value is: ${maven.test.skip}. User property is: hibernate.skip. |
-
target | - -String | - -1.0 | - -Target of execution:
-
-
Default value is: EXPORT. User property is: hibernate.export.target. |
-
testOutputDirectory | - -String | - -1.0.2 | - -Test-Classes-Directory to scan.
-
- This parameter defaults to the maven build-output-directory for -test-classes. - -This parameter is only used, when scanTestClasses -is set to true! User property is: project.build.testOutputDirectory. |
-
type | - -String | - -1.0 | - -Type of execution.
-
-
Default value is: BOTH. User property is: hibernate.export.type. |
-
url | - -String | - -1.0 | - -Database URL. User property is: hibernate.connection.url. |
-
username | - -String | - -1.0 | - -Database username User property is: hibernate.connection.username. |
-
Force execution, even if no modified or newly added annotated -classes where found and the dialect was not changed.
- -skip takes precedence over force.
This parameter defaults to the maven build-output-directory for -classes. Additionally, all dependencies are scanned for annotated -classes.
By default, only dependencies in the scope compile -are scanned for annotated classes. Multiple scopes can be seperated -by white space or commas.
- -If you do not want any dependencies to be scanned for annotated -classes, set this parameter to none.
- -The plugin does not scan for annotated classes in transitive -dependencies. If some of your annotated classes are hidden in a -transitive dependency, you can simply add that dependency -explicitly.
If this parameter is set to true the test-classes -of the artifact will be scanned for hibernate-annotated classes -additionally.
skip:
- -If set to true, the execution is skipped.
- -A skipped execution is signaled via the maven-property -${hibernate.export.skipped}.
- -The execution is skipped automatically, if no modified or newly -added annotated classes are found and the dialect was not -changed.
This parameter defaults to the maven build-output-directory for -test-classes.
- -This parameter is only used, when scanTestClasses -is set to true!
type:
- -url:
- -- The hibernate4-maven-plugin computes MD5-sums for all found annotated - classes and stores them together with the generated schema. - If no classes were changed or added and the dialect wasn't changed too, it - automatically skips the configured schema-export, to speed up the development - cycle. -
- -- The plugin signals, that the execution was skipped by setting the maven - property $\{hibernate.export.skipped\} to true. - This may be helpful, because other plugins like - dbunit-plugin - may fail, when the execution is skipped. -
- -- If you need the hibernate4-maven-plugin to <never skip execution automatically>, - you can force it to do so, if you set the parameter force to - true: -
- --<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.1.0</version> - <configuration> - <force>true</force> - </configuration> -</plugin>
- Or you may specify -Dhibernate.export.force=true at the command line, - if you want to force hibernate4-maven-plugin only once. -
- - -Full name:
- -de.juplo:hibernate4-maven-plugin:1.1.0:help
- -Description:
- -Attributes:
- -Name | - -Type | - -Since | - -Description | -
---|---|---|---|
detail | - -boolean | - -- | - -If true, display all settable properties for each
-goal. Default value is: false. User property is: detail. |
-
goal | - -String | - -- | - -The name of the goal for which to show help. If unspecified, all
-goals will be displayed. User property is: goal. |
-
indentSize | - -int | - -- | - -The number of spaces per indentation level, should be positive. Default value is: 2. User property is: indentSize. |
-
lineLength | - -int | - -- | - -The maximum length of a display line, should be positive. Default value is: 80. User property is: lineLength. |
-
goal:
- -- The hibernate4-maven-plugin is a plugin for generating a database-schema - from your Hibernate-4-Mappings and create or update your database - accordingly. - Its main usage is to automatically create and populate a test-database - for unit-tests in cooperation with the - dbunit-maven-plugin. -
- -- The plugin was designed with three main goals in mind: -
- -- To achieve the first goal, the convention-over-configuration paradigma - was applied and the plugin was stuffed with usefull logging-messages. - So, if in doubt, just turn on the debugging output with the mvn -X .... -
- -- To achieve the second goal, the precedence in which the configuration - locations are consulted was layouted in a way that makes it possible, to - prevent overwrites of the wrong database by accident. -
- -- Last but not least, in order to not slow down the development cycle, the - hibernate4-maven-plugin only executes the schema-export, if the mapping - or the dialect changes (or if you force it to do so). -
- -- For more information about the inspiration to write this tiny plugin, - read our blog-article about the hibernate4-maven-plugin. -
-Configuration for notifying developers/users when a build is unsuccessful, including user information and notification mode.
-Type | -Address | -Configuration |
---|---|---|
kai@juplo.de | -- |
- Please send your bug-reports, questions or feature-requests directly - to the developer. -
- - -Typically the licenses listed for the project are that of the project itself, and not of dependencies.
A business-friendly OSS license
-- Apache License - Version 2.0, January 2004 - http://www.apache.org/licenses/ - - TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION - - 1. Definitions. - - "License" shall mean the terms and conditions for use, reproduction, - and distribution as defined by Sections 1 through 9 of this document. - - "Licensor" shall mean the copyright owner or entity authorized by - the copyright owner that is granting the License. - - "Legal Entity" shall mean the union of the acting entity and all - other entities that control, are controlled by, or are under common - control with that entity. For the purposes of this definition, - "control" means (i) the power, direct or indirect, to cause the - direction or management of such entity, whether by contract or - otherwise, or (ii) ownership of fifty percent (50%) or more of the - outstanding shares, or (iii) beneficial ownership of such entity. - - "You" (or "Your") shall mean an individual or Legal Entity - exercising permissions granted by this License. - - "Source" form shall mean the preferred form for making modifications, - including but not limited to software source code, documentation - source, and configuration files. - - "Object" form shall mean any form resulting from mechanical - transformation or translation of a Source form, including but - not limited to compiled object code, generated documentation, - and conversions to other media types. - - "Work" shall mean the work of authorship, whether in Source or - Object form, made available under the License, as indicated by a - copyright notice that is included in or attached to the work - (an example is provided in the Appendix below). - - "Derivative Works" shall mean any work, whether in Source or Object - form, that is based on (or derived from) the Work and for which the - editorial revisions, annotations, elaborations, or other modifications - represent, as a whole, an original work of authorship. For the purposes - of this License, Derivative Works shall not include works that remain - separable from, or merely link (or bind by name) to the interfaces of, - the Work and Derivative Works thereof. - - "Contribution" shall mean any work of authorship, including - the original version of the Work and any modifications or additions - to that Work or Derivative Works thereof, that is intentionally - submitted to Licensor for inclusion in the Work by the copyright owner - or by an individual or Legal Entity authorized to submit on behalf of - the copyright owner. For the purposes of this definition, "submitted" - means any form of electronic, verbal, or written communication sent - to the Licensor or its representatives, including but not limited to - communication on electronic mailing lists, source code control systems, - and issue tracking systems that are managed by, or on behalf of, the - Licensor for the purpose of discussing and improving the Work, but - excluding communication that is conspicuously marked or otherwise - designated in writing by the copyright owner as "Not a Contribution." - - "Contributor" shall mean Licensor and any individual or Legal Entity - on behalf of whom a Contribution has been received by Licensor and - subsequently incorporated within the Work. - - 2. Grant of Copyright License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - copyright license to reproduce, prepare Derivative Works of, - publicly display, publicly perform, sublicense, and distribute the - Work and such Derivative Works in Source or Object form. - - 3. Grant of Patent License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - (except as stated in this section) patent license to make, have made, - use, offer to sell, sell, import, and otherwise transfer the Work, - where such license applies only to those patent claims licensable - by such Contributor that are necessarily infringed by their - Contribution(s) alone or by combination of their Contribution(s) - with the Work to which such Contribution(s) was submitted. If You - institute patent litigation against any entity (including a - cross-claim or counterclaim in a lawsuit) alleging that the Work - or a Contribution incorporated within the Work constitutes direct - or contributory patent infringement, then any patent licenses - granted to You under this License for that Work shall terminate - as of the date such litigation is filed. - - 4. Redistribution. You may reproduce and distribute copies of the - Work or Derivative Works thereof in any medium, with or without - modifications, and in Source or Object form, provided that You - meet the following conditions: - - (a) You must give any other recipients of the Work or - Derivative Works a copy of this License; and - - (b) You must cause any modified files to carry prominent notices - stating that You changed the files; and - - (c) You must retain, in the Source form of any Derivative Works - that You distribute, all copyright, patent, trademark, and - attribution notices from the Source form of the Work, - excluding those notices that do not pertain to any part of - the Derivative Works; and - - (d) If the Work includes a "NOTICE" text file as part of its - distribution, then any Derivative Works that You distribute must - include a readable copy of the attribution notices contained - within such NOTICE file, excluding those notices that do not - pertain to any part of the Derivative Works, in at least one - of the following places: within a NOTICE text file distributed - as part of the Derivative Works; within the Source form or - documentation, if provided along with the Derivative Works; or, - within a display generated by the Derivative Works, if and - wherever such third-party notices normally appear. The contents - of the NOTICE file are for informational purposes only and - do not modify the License. You may add Your own attribution - notices within Derivative Works that You distribute, alongside - or as an addendum to the NOTICE text from the Work, provided - that such additional attribution notices cannot be construed - as modifying the License. - - You may add Your own copyright statement to Your modifications and - may provide additional or different license terms and conditions - for use, reproduction, or distribution of Your modifications, or - for any such Derivative Works as a whole, provided Your use, - reproduction, and distribution of the Work otherwise complies with - the conditions stated in this License. - - 5. Submission of Contributions. Unless You explicitly state otherwise, - any Contribution intentionally submitted for inclusion in the Work - by You to the Licensor shall be under the terms and conditions of - this License, without any additional terms or conditions. - Notwithstanding the above, nothing herein shall supersede or modify - the terms of any separate license agreement you may have executed - with Licensor regarding such Contributions. - - 6. Trademarks. This License does not grant permission to use the trade - names, trademarks, service marks, or product names of the Licensor, - except as required for reasonable and customary use in describing the - origin of the Work and reproducing the content of the NOTICE file. - - 7. Disclaimer of Warranty. Unless required by applicable law or - agreed to in writing, Licensor provides the Work (and each - Contributor provides its Contributions) on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or - implied, including, without limitation, any warranties or conditions - of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A - PARTICULAR PURPOSE. You are solely responsible for determining the - appropriateness of using or redistributing the Work and assume any - risks associated with Your exercise of permissions under this License. - - 8. Limitation of Liability. In no event and under no legal theory, - whether in tort (including negligence), contract, or otherwise, - unless required by applicable law (such as deliberate and grossly - negligent acts) or agreed to in writing, shall any Contributor be - liable to You for damages, including any direct, indirect, special, - incidental, or consequential damages of any character arising as a - result of this License or out of the use or inability to use the - Work (including but not limited to damages for loss of goodwill, - work stoppage, computer failure or malfunction, or any and all - other commercial damages or losses), even if such Contributor - has been advised of the possibility of such damages. - - 9. Accepting Warranty or Additional Liability. While redistributing - the Work or Derivative Works thereof, You may choose to offer, - and charge a fee for, acceptance of support, warranty, indemnity, - or other liability obligations and/or rights consistent with this - License. However, in accepting such obligations, You may act only - on Your own behalf and on Your sole responsibility, not on behalf - of any other Contributor, and only if You agree to indemnify, - defend, and hold each Contributor harmless for any liability - incurred by, or claims asserted against, such Contributor by reason - of your accepting any such warranty or additional liability. - - END OF TERMS AND CONDITIONS - - APPENDIX: How to apply the Apache License to your work. - - To apply the Apache License to your work, attach the following - boilerplate notice, with the fields enclosed by brackets "[]" - replaced with your own identifying information. (Don't include - the brackets!) The text should be enclosed in the appropriate - comment syntax for the file format. We also recommend that a - file or class name and description of purpose be included on the - same "printed page" as the copyright notice for easier - identification within third-party archives. - - Copyright [yyyy] [name of copyright owner] - - Licensed under the Apache License, Version 2.0 (the "License"); - you may not use this file except in compliance with the License. - You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. -
- Please send your bug-reports, questions or feature-requests directly - to the developer. -
- - -- hibernate4-maven-plugin by default scans dependencies in the scope - compile. You can configure it to scan dependencies in other - scopes as well. But it scans only direct dependencies. Transitive - dependencies are not scanned for annotated classes. If some of your - annotated classes are hidden in a transitive dependency, you can simply - add that dependency explicitly. -
-- The default-configuration uses the EXPORT-target of the SchemaExport-Tool. - If you do not need to create a database with the evaluated schema, you can - use the NONE- or the SCRIPT-target. - This can be achieved with the command-line parameter - -Dhibernate.export.target=SCRIPT or with the following configuration: -
- --<configuration> - <target>SCRIPT</target> -</configuration>
- But even when no database is to be created, hibernate always needs to know - the dialect. Hence, the plugin will fail if this parameter is missing! -
-- One regular problem is the scope of the jdbc-driver-dependency. - It is very unlikely, that this dependency is needed at compile-time. - So a tidy maven-developer would usually scope it for runtime. -
- -- But this will break the execution of the hibernate4-maven-plugin. - Since it will not be able to see the needed dependency, it will fail with - an error-message like: -
- --[INFO] Gathered hibernate-configuration (turn on debugging for details): -[INFO] hibernate.connection.username = sa -[INFO] hibernate.connection.password = -[INFO] hibernate.dialect = org.hibernate.dialect.HSQLDialect -[INFO] hibernate.connection.url = jdbc:hsqldb:/home/kai/mmf/target/mmf;shutdown=true -[INFO] hibernate.connection.driver_class = org.hsqldb.jdbcDriver -[ERROR] Dependency for driver-class org.hsqldb.jdbcDriver is missing! -[INFO] ------------------------------------------------------------------------ -[ERROR] BUILD ERROR -[INFO] ------------------------------------------------------------------------ -[INFO] org.hsqldb.jdbcDriver -[INFO] ------------------------------------------------------------------------ -[INFO] For more information, run Maven with the -e switch -[INFO] ------------------------------------------------------------------------ -[INFO] Total time: 2 seconds -[INFO] Finished at: Thu Nov 29 11:31:14 CET 2012 -[INFO] Final Memory: 32M/342M -[INFO] ------------------------------------------------------------------------
- A quick workaround for this error would be, to delete the runtime-constraint - for the jdbc-driver-dependency. -
- -- A much cleaner way is, to (additionally) ad the dependency, to the - plugin-definition: -
- --<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.1.0</version> - <executions> - <execution> - <goals> - <goal>export</goal> - </goals> - </execution> - </executions> - <dependencies> - <dependency> - <groupId>org.hsqldb</groupId> - <artifactId>hsqldb</artifactId> - <version>2.2.8</version> - </dependency> - </dependencies> -</plugin>
- This is also the best way, if you use a different jdbc-driver for - testing, than in production. - Because otherwise, this dependency will unnecessarily bloat the - runtime-dependencies of your project. -
-- If hibernate4-maven-plugin skips its excecution, this may lead to errors in - other plugins. - For example, when importing sample-data in the automatically created database - with the help of the dbunit-plugin, - the CLEAN_INSERT-operation may fail because of foreign-key-constraints, - if the database was not recreated, because the hibernate4-maven-plugin has - skipped its excecution. -
- -- A quick fix to this problem is, to force - hibernate4-maven-plugin to export the schema every time it is running. - But to recreate the database on every testrun may noticeable slow down your - development cycle, if you have to wait for slow IO. -
- -- To circumvent this problem, hibernate4-maven-plugin signals a skipped - excecution by setting the maven property $\{hibernate.export.skipped\} to - true. - You can configure other plugins to react on this signal. - For example, the dbunit-plugin can be configured to skip its excecution, if - hibernate4-maven-plugin was skipped like this: -
- --<plugin> - <groupId>org.codehaus.mojo</groupId> - <artifactId>dbunit-maven-plugin</artifactId> - <configuration> - <skip>${hibernate.export.skipped}</skip> - </configuration> -</plugin>
- If one manually drops the database or removes the hsqldb-files, it will not - be recreated by the hibernate4-maven-plugin, because it cannot detect, that - the database needs to be recreated. - This happens, because the plugin will not recreate the database if neither - the configuration nor the annotated classes have changed, because an - unnecessary drop-create-cycle might take a long time. The plugin will - report that like this: -
- --[INFO] No modified annotated classes found and dialect unchanged. -[INFO] Skipping schema generation!
- If one always uses mvn clean for cleanup, this will not happen. - Otherwise the recreation must be forced: -
- --mvn hibernate4:export -Dhibernate.export.force=true
- The hibernate4-maven-plugin automatically skips its execution, when - maven.test.skip is set to true. If you need it to be always - executed, you can configure that explicitly like this: -
- --<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - ... - <configuration> - <skip>false</skip> - </configuration> -</plugin>
- Background-information for this design-decission can be found on the extra - page To skip or not to skip: that is the question... -
-- If you do not want your dependencies to be scanned for hibernate annotations, - you can pass -Dhibernate.export.scan_dependencies=none to maven - or set scanDependencies to none in the configuration - of the plugin like this: -
- --<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - ... - <configuration> - <scanDependencies>none</scanDependencies> - </configuration> -</plugin>
- If you are working under Windows and get the error-message - No annotated classes found in directory C:\projects\X Y Z\path-to-project\target\classes, - but you are really sure, that there are annotated classes in that - directory, you are expiriencing a bug, in the scannotation-library, that - was closed in version 1.1.0 of the hibernate-maven-plugin. -
- -- - You should consider to upgrade to that version of the plugin. - -
-Goals available for this plugin:
-Goal | -Description |
---|---|
hibernate4:export | -Goal which extracts the hibernate-mapping-configuration and exports -an according SQL-database-schema. |
hibernate4:help | -Display help information on hibernate4-maven-plugin. -Call mvn hibernate4:help -Ddetail=true
--Dgoal=<goal-name> to display parameter details. |
The following specifies the minimum requirements to run this Maven plugin:
-Maven | -2.0.6 |
JDK | -1.6 |
Memory | -No minimum requirement. |
Disk Space | -No minimum requirement. |
You should specify the version in your project's plugin configuration:
-<project> - ... - <build> - <!-- To define the plugin version in your parent POM --> - <pluginManagement> - <plugins> - <plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.1.0</version> - </plugin> - ... - </plugins> - </pluginManagement> - <!-- To use the plugin goals in your POM or parent POM --> - <plugins> - <plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.1.0</version> - </plugin> - ... - </plugins> - </build> - ... -</project> -
For more information, see "Guide to Configuring Plug-ins"
GroupId | -ArtifactId | -Version |
---|---|---|
org.apache.maven.plugins | -maven-antrun-plugin | -1.3 |
org.apache.maven.plugins | -maven-assembly-plugin | -2.2-beta-5 |
org.apache.maven.plugins | -maven-dependency-plugin | -2.1 |
org.apache.maven.plugins | -maven-release-plugin | -2.1 |
org.apache.maven.plugins | -maven-site-plugin | -3.4 |
GroupId | -ArtifactId | -Version |
---|---|---|
org.apache.maven.plugins | -maven-clean-plugin | -2.5 |
org.apache.maven.plugins | -maven-compiler-plugin | -3.3 |
org.apache.maven.plugins | -maven-dependency-plugin | -2.10 |
org.apache.maven.plugins | -maven-deploy-plugin | -2.7 |
org.apache.maven.plugins | -maven-enforcer-plugin | -1.2 |
org.apache.maven.plugins | -maven-install-plugin | -2.3 |
org.apache.maven.plugins | -maven-invoker-plugin | -1.10 |
org.apache.maven.plugins | -maven-jar-plugin | -2.2 |
org.apache.maven.plugins | -maven-javadoc-plugin | -2.7 |
org.apache.maven.plugins | -maven-plugin-plugin | -3.4 |
org.apache.maven.plugins | -maven-resources-plugin | -2.7 |
org.apache.maven.plugins | -maven-scm-plugin | -1.9.4 |
org.apache.maven.plugins | -maven-site-plugin | -3.4 |
org.apache.maven.plugins | -maven-source-plugin | -2.1.2 |
org.apache.maven.plugins | -maven-surefire-plugin | -2.10 |
GroupId | -ArtifactId | -Version |
---|---|---|
org.apache.maven.plugins | -maven-changes-plugin | -2.11 |
org.apache.maven.plugins | -maven-javadoc-plugin | -2.7 |
org.apache.maven.plugins | -maven-jxr-plugin | -2.5 |
org.apache.maven.plugins | -maven-plugin-plugin | -3.4 |
org.apache.maven.plugins | -maven-pmd-plugin | -3.4 |
The following document contains the results of PMD 5.2.3.
Violation | -Line |
---|---|
Unnecessary use of fully qualified name 'java.security.MessageDigest.getInstance' due to existing import 'java.security.MessageDigest' | -527 |
Unnecessary use of fully qualified name 'java.security.MessageDigest.getInstance' due to existing import 'java.security.MessageDigest' | -876 |
Avoid using a branching statement as the last in a loop. | -1141 |
Unnecessary use of fully qualified name 'java.sql.Driver' due to existing import 'java.sql.Driver' | -1226 |
Unnecessary use of fully qualified name 'java.util.Properties' due to existing import 'java.util.Properties' | -1240 |
This document provides an overview of the various documents and links that are part of this project's general information. All of this content is automatically generated by Maven on behalf of the project.
-Document | -Description |
---|---|
About | -Plugin for generating a database-schema from Hibernate-4-Mapping-Annotations |
Plugin Management | -This document lists the plugins that are defined through pluginManagement. |
Distribution Management | -This document provides informations on the distribution management of this project. |
Dependency Information | -This document describes how to to include this project as a dependency using various dependency management tools. |
Source Repository | -This is a link to the online source repository that can be viewed via a web browser. |
Mailing Lists | -This document provides subscription and archive information for this project's mailing lists. |
Issue Tracking | -This is a link to the issue management system for this project. Issues (bugs, features, change requests) can be created and queried using this link. |
Continuous Integration | -This is a link to the definitions of all continuous integration processes that builds and tests code on a frequent, regular basis. |
Project Plugins | -This document lists the build plugins and the report plugins used by this project. |
Project License | -This is a link to the definitions of project licenses. |
Project Team | -This document provides information on the members of this project. These are the individuals who have contributed to the project in one form or another. |
Project Summary | -This document lists other related information of this project |
Dependencies | -This document lists the project's dependencies and provides information on each dependency. |
This document provides an overview of the various reports that are automatically generated by Maven . Each report is briefly described below.
-Document | -Description |
---|---|
Test JavaDocs | -Test JavaDoc API documentation. |
JavaDocs | -JavaDoc API documentation. |
Source Xref | -HTML based, cross-reference version of Java source code. |
Test Source Xref | -HTML based, cross-reference version of Java test source code. |
PMD | -Verification of coding rules. |
Plugin Documentation | -This report provides goals and parameters documentation of a plugin. |
Field | -Value |
---|---|
Name | -Hibernate 4 Maven Plugin |
Description | -Plugin for generating a database-schema from Hibernate-4-Mapping-Annotations |
Homepage | -http://juplo.de/hibernate4-maven-plugin |
- In most use-cases, the hibernate4-maven-plugin is used to create a - test-database automatically. In this use-cases, it is very likely, that it - will result in mistakes/errors, if the goal is executed, when the tests - are skipped. - For example, one might manually overwrite the database-url with the url of - the production-database, in order to run other tests, like starting a - local webserver with the - jetty-maven-plugin. - If the export-goal would be executed in such a scenario, it might erase the - hole production-database, which is not very desireable. -
- -- Because of this, the configuration-parameter skip defaults to the value - of the proptery maven.test.skip. This way, the execution of the - hibernate4-maven-plugin is skipped automatically, when the tests are - skipped. Think of it as a build-in security-belt. -
- -- If you do not like that, because you need the plugin to always execute the - export-goal, even if the tests are skipped you can configure that explicitly, - by setting the configuration-parameter skip to false: -
- --<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - ... - <configuration> - <skip>false</skip> - </configuration> -</plugin>
- Or, if you want the export-goal to be executed by default and to be skipped - if you say so, you can bind the value of the configuration-parameter - skip to a custom property. For example: -
- --<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - ... - <configuration> - <skip>${foo.bar}</skip> - </configuration> -</plugin>
- This way, the export-goal would be skipped, if you set the property - foo.bar to true. For example, if you specify -Dfoo.bar=true - on the command-line. -
- - -This project uses GIT to manage its source code. Instructions on GIT use can be found at http://git-scm.com/documentation.
The source can be checked out anonymously from GIT with this command (See http://git-scm.com/docs/git-clone):
-$ git clone http://juplo.de/git/hibernate4-maven-plugin
Only project developers can access the GIT tree via this method (See http://git-scm.com/docs/git-clone).
-$ git clone ssh://juplo.de/var/lib/git/juplo/hibernate4-maven-plugin
A successful project requires many people to play many roles. Some members write code or documentation, while others are valuable as testers, submitting patches and suggestions.
-The team is comprised of Members and Contributors. Members have direct access to the source of a project and actively evolve the code-base. Contributors improve the project through submission of patches and suggestions to the Members. The number of Contributors to the project is unbounded. Get involved today. All contributions to the project are greatly appreciated.
-The following is a list of developers with commit privileges that have directly contributed to the project in one way or another.
-Image | -Id | -Name | -|
---|---|---|---|
- | kai | -Kai Moritz | -kai@juplo.de |
The following additional people have contributed to this project through the way of suggestions, patches or documentation.
-Image | -Name | -|
---|---|---|
- | Adriano Machado | -adriano.m.machado@hotmail.com |
- | Lorenzo Nicora | -lorenzo.nicora@nicus.it |
- | Eduard Szente | -eduard.szente@gmail.com |
- | Stephen Johnson | -stejohns@redhat.com |
- | Victor Tatai | -vtatai@gmail.com |
- | Erik-Berndt Scheper | -erik.berndt.scheper@gmail.com |
- | Guido Wimmel | -Wimmel.Guido@swm.de |
- | Joel Johnson | -mrjoel@lixil.net |
- | Paul K. Moore | -paulkmoore@gmail.com |
- | Mark Robinson | -mark@mrobinson.ca |
- | Claus Graf | -clausgraf@gmail.com |
- | Joachim Van der Auwera | -joachim@progs.be |
- | Andreas Kuhtz | -andreas.kuhtz@gmail.com |
Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.0/testapidocs/de/juplo/test/FileComparator.html b/dist/hibernate4-maven-plugin-1.1.0/testapidocs/de/juplo/test/FileComparator.html deleted file mode 100644 index 72a209d8..00000000 --- a/dist/hibernate4-maven-plugin-1.1.0/testapidocs/de/juplo/test/FileComparator.html +++ /dev/null @@ -1,263 +0,0 @@ - - - - - - -public class FileComparator -extends Object-
Constructor and Description | -
---|
FileComparator(File basedir) |
-
public boolean isEqual(String expectedFile, - String foundFile) - throws FileNotFoundException, - IOException-
FileNotFoundException
IOException
Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.0/testapidocs/de/juplo/test/class-use/FileComparator.html b/dist/hibernate4-maven-plugin-1.1.0/testapidocs/de/juplo/test/class-use/FileComparator.html deleted file mode 100644 index 57ecc3f2..00000000 --- a/dist/hibernate4-maven-plugin-1.1.0/testapidocs/de/juplo/test/class-use/FileComparator.html +++ /dev/null @@ -1,115 +0,0 @@ - - - - - - -Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.0/testapidocs/de/juplo/test/package-frame.html b/dist/hibernate4-maven-plugin-1.1.0/testapidocs/de/juplo/test/package-frame.html deleted file mode 100644 index db9ad2f5..00000000 --- a/dist/hibernate4-maven-plugin-1.1.0/testapidocs/de/juplo/test/package-frame.html +++ /dev/null @@ -1,20 +0,0 @@ - - - - - - -Class | -Description | -
---|---|
FileComparator | -- |
Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.0/testapidocs/de/juplo/test/package-tree.html b/dist/hibernate4-maven-plugin-1.1.0/testapidocs/de/juplo/test/package-tree.html deleted file mode 100644 index 9063bb00..00000000 --- a/dist/hibernate4-maven-plugin-1.1.0/testapidocs/de/juplo/test/package-tree.html +++ /dev/null @@ -1,124 +0,0 @@ - - - - - - -Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.0/testapidocs/de/juplo/test/package-use.html b/dist/hibernate4-maven-plugin-1.1.0/testapidocs/de/juplo/test/package-use.html deleted file mode 100644 index 33483b86..00000000 --- a/dist/hibernate4-maven-plugin-1.1.0/testapidocs/de/juplo/test/package-use.html +++ /dev/null @@ -1,115 +0,0 @@ - - - - - - -Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.0/testapidocs/deprecated-list.html b/dist/hibernate4-maven-plugin-1.1.0/testapidocs/deprecated-list.html deleted file mode 100644 index 9d7cfe05..00000000 --- a/dist/hibernate4-maven-plugin-1.1.0/testapidocs/deprecated-list.html +++ /dev/null @@ -1,115 +0,0 @@ - - - - - - -Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.0/testapidocs/help-doc.html b/dist/hibernate4-maven-plugin-1.1.0/testapidocs/help-doc.html deleted file mode 100644 index e77a4c12..00000000 --- a/dist/hibernate4-maven-plugin-1.1.0/testapidocs/help-doc.html +++ /dev/null @@ -1,216 +0,0 @@ - - - - - - -Each package has a page that contains a list of its classes and interfaces, with a summary for each. This page can contain six categories:
-Each class, interface, nested class and nested interface has its own separate page. Each of these pages has three sections consisting of a class/interface description, summary tables, and detailed member descriptions:
-Each summary entry contains the first sentence from the detailed description for that item. The summary entries are alphabetical, while the detailed descriptions are in the order they appear in the source code. This preserves the logical groupings established by the programmer.
-Each annotation type has its own separate page with the following sections:
-Each enum has its own separate page with the following sections:
-Each documented package, class and interface has its own Use page. This page describes what packages, classes, methods, constructors and fields use any part of the given class or package. Given a class or interface A, its Use page includes subclasses of A, fields declared as A, methods that return A, and methods and constructors with parameters of type A. You can access this page by first going to the package, class or interface, then clicking on the "Use" link in the navigation bar.
-There is a Class Hierarchy page for all packages, plus a hierarchy for each package. Each hierarchy page contains a list of classes and a list of interfaces. The classes are organized by inheritance structure starting with java.lang.Object
. The interfaces do not inherit from java.lang.Object
.
The Deprecated API page lists all of the API that have been deprecated. A deprecated API is not recommended for use, generally due to improvements, and a replacement API is usually given. Deprecated APIs may be removed in future implementations.
-The Index contains an alphabetic list of all classes, interfaces, constructors, methods, and fields.
-These links take you to the next or previous class, interface, package, or related page.
-These links show and hide the HTML frames. All pages are available with or without frames.
-The All Classes link shows all classes and interfaces except non-static nested types.
-Each serializable or externalizable class has a description of its serialization fields and methods. This information is of interest to re-implementors, not to developers using the API. While there is no link in the navigation bar, you can get to this information by going to any serialized class and clicking "Serialized Form" in the "See also" section of the class description.
-The Constant Field Values page lists the static final fields and their values.
-Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.0/testapidocs/index-all.html b/dist/hibernate4-maven-plugin-1.1.0/testapidocs/index-all.html deleted file mode 100644 index 7cdd40f8..00000000 --- a/dist/hibernate4-maven-plugin-1.1.0/testapidocs/index-all.html +++ /dev/null @@ -1,138 +0,0 @@ - - - - - - -Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.0/testapidocs/index.html b/dist/hibernate4-maven-plugin-1.1.0/testapidocs/index.html deleted file mode 100644 index 99d7e465..00000000 --- a/dist/hibernate4-maven-plugin-1.1.0/testapidocs/index.html +++ /dev/null @@ -1,72 +0,0 @@ - - - - - - -This document is designed to be viewed using the frames feature. If you see this message, you are using a non-frame-capable web client. Link to Non-frame version.
-Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.0/testapidocs/package-list b/dist/hibernate4-maven-plugin-1.1.0/testapidocs/package-list deleted file mode 100644 index 4774195e..00000000 --- a/dist/hibernate4-maven-plugin-1.1.0/testapidocs/package-list +++ /dev/null @@ -1 +0,0 @@ -de.juplo.test diff --git a/dist/hibernate4-maven-plugin-1.1.0/testapidocs/packages b/dist/hibernate4-maven-plugin-1.1.0/testapidocs/packages deleted file mode 100644 index 8fbea680..00000000 --- a/dist/hibernate4-maven-plugin-1.1.0/testapidocs/packages +++ /dev/null @@ -1 +0,0 @@ -de.juplo.test \ No newline at end of file diff --git a/dist/hibernate4-maven-plugin-1.1.0/testapidocs/resources/background.gif b/dist/hibernate4-maven-plugin-1.1.0/testapidocs/resources/background.gif deleted file mode 100644 index f471940f..00000000 Binary files a/dist/hibernate4-maven-plugin-1.1.0/testapidocs/resources/background.gif and /dev/null differ diff --git a/dist/hibernate4-maven-plugin-1.1.0/testapidocs/resources/tab.gif b/dist/hibernate4-maven-plugin-1.1.0/testapidocs/resources/tab.gif deleted file mode 100644 index 1a73a83b..00000000 Binary files a/dist/hibernate4-maven-plugin-1.1.0/testapidocs/resources/tab.gif and /dev/null differ diff --git a/dist/hibernate4-maven-plugin-1.1.0/testapidocs/resources/titlebar.gif b/dist/hibernate4-maven-plugin-1.1.0/testapidocs/resources/titlebar.gif deleted file mode 100644 index 17443b3e..00000000 Binary files a/dist/hibernate4-maven-plugin-1.1.0/testapidocs/resources/titlebar.gif and /dev/null differ diff --git a/dist/hibernate4-maven-plugin-1.1.0/testapidocs/resources/titlebar_end.gif b/dist/hibernate4-maven-plugin-1.1.0/testapidocs/resources/titlebar_end.gif deleted file mode 100644 index 3ad78d46..00000000 Binary files a/dist/hibernate4-maven-plugin-1.1.0/testapidocs/resources/titlebar_end.gif and /dev/null differ diff --git a/dist/hibernate4-maven-plugin-1.1.0/testapidocs/stylesheet.css b/dist/hibernate4-maven-plugin-1.1.0/testapidocs/stylesheet.css deleted file mode 100644 index 0aeaa97f..00000000 --- a/dist/hibernate4-maven-plugin-1.1.0/testapidocs/stylesheet.css +++ /dev/null @@ -1,474 +0,0 @@ -/* Javadoc style sheet */ -/* -Overall document style -*/ -body { - background-color:#ffffff; - color:#353833; - font-family:Arial, Helvetica, sans-serif; - font-size:76%; - margin:0; -} -a:link, a:visited { - text-decoration:none; - color:#4c6b87; -} -a:hover, a:focus { - text-decoration:none; - color:#bb7a2a; -} -a:active { - text-decoration:none; - color:#4c6b87; -} -a[name] { - color:#353833; -} -a[name]:hover { - text-decoration:none; - color:#353833; -} -pre { - font-size:1.3em; -} -h1 { - font-size:1.8em; -} -h2 { - font-size:1.5em; -} -h3 { - font-size:1.4em; -} -h4 { - font-size:1.3em; -} -h5 { - font-size:1.2em; -} -h6 { - font-size:1.1em; -} -ul { - list-style-type:disc; -} -code, tt { - font-size:1.2em; -} -dt code { - font-size:1.2em; -} -table tr td dt code { - font-size:1.2em; - vertical-align:top; -} -sup { - font-size:.6em; -} -/* -Document title and Copyright styles -*/ -.clear { - clear:both; - height:0px; - overflow:hidden; -} -.aboutLanguage { - float:right; - padding:0px 21px; - font-size:.8em; - z-index:200; - margin-top:-7px; -} -.legalCopy { - margin-left:.5em; -} -.bar a, .bar a:link, .bar a:visited, .bar a:active { - color:#FFFFFF; - text-decoration:none; -} -.bar a:hover, .bar a:focus { - color:#bb7a2a; -} -.tab { - background-color:#0066FF; - background-image:url(resources/titlebar.gif); - background-position:left top; - background-repeat:no-repeat; - color:#ffffff; - padding:8px; - width:5em; - font-weight:bold; -} -/* -Navigation bar styles -*/ -.bar { - background-image:url(resources/background.gif); - background-repeat:repeat-x; - color:#FFFFFF; - padding:.8em .5em .4em .8em; - height:auto;/*height:1.8em;*/ - font-size:1em; - margin:0; -} -.topNav { - background-image:url(resources/background.gif); - background-repeat:repeat-x; - color:#FFFFFF; - float:left; - padding:0; - width:100%; - clear:right; - height:2.8em; - padding-top:10px; - overflow:hidden; -} -.bottomNav { - margin-top:10px; - background-image:url(resources/background.gif); - background-repeat:repeat-x; - color:#FFFFFF; - float:left; - padding:0; - width:100%; - clear:right; - height:2.8em; - padding-top:10px; - overflow:hidden; -} -.subNav { - background-color:#dee3e9; - border-bottom:1px solid #9eadc0; - float:left; - width:100%; - overflow:hidden; -} -.subNav div { - clear:left; - float:left; - padding:0 0 5px 6px; -} -ul.navList, ul.subNavList { - float:left; - margin:0 25px 0 0; - padding:0; -} -ul.navList li{ - list-style:none; - float:left; - padding:3px 6px; -} -ul.subNavList li{ - list-style:none; - float:left; - font-size:90%; -} -.topNav a:link, .topNav a:active, .topNav a:visited, .bottomNav a:link, .bottomNav a:active, .bottomNav a:visited { - color:#FFFFFF; - text-decoration:none; -} -.topNav a:hover, .bottomNav a:hover { - text-decoration:none; - color:#bb7a2a; -} -.navBarCell1Rev { - background-image:url(resources/tab.gif); - background-color:#a88834; - color:#FFFFFF; - margin: auto 5px; - border:1px solid #c9aa44; -} -/* -Page header and footer styles -*/ -.header, .footer { - clear:both; - margin:0 20px; - padding:5px 0 0 0; -} -.indexHeader { - margin:10px; - position:relative; -} -.indexHeader h1 { - font-size:1.3em; -} -.title { - color:#2c4557; - margin:10px 0; -} -.subTitle { - margin:5px 0 0 0; -} -.header ul { - margin:0 0 25px 0; - padding:0; -} -.footer ul { - margin:20px 0 5px 0; -} -.header ul li, .footer ul li { - list-style:none; - font-size:1.2em; -} -/* -Heading styles -*/ -div.details ul.blockList ul.blockList ul.blockList li.blockList h4, div.details ul.blockList ul.blockList ul.blockListLast li.blockList h4 { - background-color:#dee3e9; - border-top:1px solid #9eadc0; - border-bottom:1px solid #9eadc0; - margin:0 0 6px -8px; - padding:2px 5px; -} -ul.blockList ul.blockList ul.blockList li.blockList h3 { - background-color:#dee3e9; - border-top:1px solid #9eadc0; - border-bottom:1px solid #9eadc0; - margin:0 0 6px -8px; - padding:2px 5px; -} -ul.blockList ul.blockList li.blockList h3 { - padding:0; - margin:15px 0; -} -ul.blockList li.blockList h2 { - padding:0px 0 20px 0; -} -/* -Page layout container styles -*/ -.contentContainer, .sourceContainer, .classUseContainer, .serializedFormContainer, .constantValuesContainer { - clear:both; - padding:10px 20px; - position:relative; -} -.indexContainer { - margin:10px; - position:relative; - font-size:1.0em; -} -.indexContainer h2 { - font-size:1.1em; - padding:0 0 3px 0; -} -.indexContainer ul { - margin:0; - padding:0; -} -.indexContainer ul li { - list-style:none; -} -.contentContainer .description dl dt, .contentContainer .details dl dt, .serializedFormContainer dl dt { - font-size:1.1em; - font-weight:bold; - margin:10px 0 0 0; - color:#4E4E4E; -} -.contentContainer .description dl dd, .contentContainer .details dl dd, .serializedFormContainer dl dd { - margin:10px 0 10px 20px; -} -.serializedFormContainer dl.nameValue dt { - margin-left:1px; - font-size:1.1em; - display:inline; - font-weight:bold; -} -.serializedFormContainer dl.nameValue dd { - margin:0 0 0 1px; - font-size:1.1em; - display:inline; -} -/* -List styles -*/ -ul.horizontal li { - display:inline; - font-size:0.9em; -} -ul.inheritance { - margin:0; - padding:0; -} -ul.inheritance li { - display:inline; - list-style:none; -} -ul.inheritance li ul.inheritance { - margin-left:15px; - padding-left:15px; - padding-top:1px; -} -ul.blockList, ul.blockListLast { - margin:10px 0 10px 0; - padding:0; -} -ul.blockList li.blockList, ul.blockListLast li.blockList { - list-style:none; - margin-bottom:25px; -} -ul.blockList ul.blockList li.blockList, ul.blockList ul.blockListLast li.blockList { - padding:0px 20px 5px 10px; - border:1px solid #9eadc0; - background-color:#f9f9f9; -} -ul.blockList ul.blockList ul.blockList li.blockList, ul.blockList ul.blockList ul.blockListLast li.blockList { - padding:0 0 5px 8px; - background-color:#ffffff; - border:1px solid #9eadc0; - border-top:none; -} -ul.blockList ul.blockList ul.blockList ul.blockList li.blockList { - margin-left:0; - padding-left:0; - padding-bottom:15px; - border:none; - border-bottom:1px solid #9eadc0; -} -ul.blockList ul.blockList ul.blockList ul.blockList li.blockListLast { - list-style:none; - border-bottom:none; - padding-bottom:0; -} -table tr td dl, table tr td dl dt, table tr td dl dd { - margin-top:0; - margin-bottom:1px; -} -/* -Table styles -*/ -.contentContainer table, .classUseContainer table, .constantValuesContainer table { - border-bottom:1px solid #9eadc0; - width:100%; -} -.contentContainer ul li table, .classUseContainer ul li table, .constantValuesContainer ul li table { - width:100%; -} -.contentContainer .description table, .contentContainer .details table { - border-bottom:none; -} -.contentContainer ul li table th.colOne, .contentContainer ul li table th.colFirst, .contentContainer ul li table th.colLast, .classUseContainer ul li table th, .constantValuesContainer ul li table th, .contentContainer ul li table td.colOne, .contentContainer ul li table td.colFirst, .contentContainer ul li table td.colLast, .classUseContainer ul li table td, .constantValuesContainer ul li table td{ - vertical-align:top; - padding-right:20px; -} -.contentContainer ul li table th.colLast, .classUseContainer ul li table th.colLast,.constantValuesContainer ul li table th.colLast, -.contentContainer ul li table td.colLast, .classUseContainer ul li table td.colLast,.constantValuesContainer ul li table td.colLast, -.contentContainer ul li table th.colOne, .classUseContainer ul li table th.colOne, -.contentContainer ul li table td.colOne, .classUseContainer ul li table td.colOne { - padding-right:3px; -} -.overviewSummary caption, .packageSummary caption, .contentContainer ul.blockList li.blockList caption, .summary caption, .classUseContainer caption, .constantValuesContainer caption { - position:relative; - text-align:left; - background-repeat:no-repeat; - color:#FFFFFF; - font-weight:bold; - clear:none; - overflow:hidden; - padding:0px; - margin:0px; -} -caption a:link, caption a:hover, caption a:active, caption a:visited { - color:#FFFFFF; -} -.overviewSummary caption span, .packageSummary caption span, .contentContainer ul.blockList li.blockList caption span, .summary caption span, .classUseContainer caption span, .constantValuesContainer caption span { - white-space:nowrap; - padding-top:8px; - padding-left:8px; - display:block; - float:left; - background-image:url(resources/titlebar.gif); - height:18px; -} -.overviewSummary .tabEnd, .packageSummary .tabEnd, .contentContainer ul.blockList li.blockList .tabEnd, .summary .tabEnd, .classUseContainer .tabEnd, .constantValuesContainer .tabEnd { - width:10px; - background-image:url(resources/titlebar_end.gif); - background-repeat:no-repeat; - background-position:top right; - position:relative; - float:left; -} -ul.blockList ul.blockList li.blockList table { - margin:0 0 12px 0px; - width:100%; -} -.tableSubHeadingColor { - background-color: #EEEEFF; -} -.altColor { - background-color:#eeeeef; -} -.rowColor { - background-color:#ffffff; -} -.overviewSummary td, .packageSummary td, .contentContainer ul.blockList li.blockList td, .summary td, .classUseContainer td, .constantValuesContainer td { - text-align:left; - padding:3px 3px 3px 7px; -} -th.colFirst, th.colLast, th.colOne, .constantValuesContainer th { - background:#dee3e9; - border-top:1px solid #9eadc0; - border-bottom:1px solid #9eadc0; - text-align:left; - padding:3px 3px 3px 7px; -} -td.colOne a:link, td.colOne a:active, td.colOne a:visited, td.colOne a:hover, td.colFirst a:link, td.colFirst a:active, td.colFirst a:visited, td.colFirst a:hover, td.colLast a:link, td.colLast a:active, td.colLast a:visited, td.colLast a:hover, .constantValuesContainer td a:link, .constantValuesContainer td a:active, .constantValuesContainer td a:visited, .constantValuesContainer td a:hover { - font-weight:bold; -} -td.colFirst, th.colFirst { - border-left:1px solid #9eadc0; - white-space:nowrap; -} -td.colLast, th.colLast { - border-right:1px solid #9eadc0; -} -td.colOne, th.colOne { - border-right:1px solid #9eadc0; - border-left:1px solid #9eadc0; -} -table.overviewSummary { - padding:0px; - margin-left:0px; -} -table.overviewSummary td.colFirst, table.overviewSummary th.colFirst, -table.overviewSummary td.colOne, table.overviewSummary th.colOne { - width:25%; - vertical-align:middle; -} -table.packageSummary td.colFirst, table.overviewSummary th.colFirst { - width:25%; - vertical-align:middle; -} -/* -Content styles -*/ -.description pre { - margin-top:0; -} -.deprecatedContent { - margin:0; - padding:10px 0; -} -.docSummary { - padding:0; -} -/* -Formatting effect styles -*/ -.sourceLineNo { - color:green; - padding:0 30px 0 0; -} -h1.hidden { - visibility:hidden; - overflow:hidden; - font-size:.9em; -} -.block { - display:block; - margin:3px 0 0 0; -} -.strong { - font-weight:bold; -} diff --git a/dist/hibernate4-maven-plugin-1.1.0/xref-test/allclasses-frame.html b/dist/hibernate4-maven-plugin-1.1.0/xref-test/allclasses-frame.html deleted file mode 100644 index 8253aebb..00000000 --- a/dist/hibernate4-maven-plugin-1.1.0/xref-test/allclasses-frame.html +++ /dev/null @@ -1,20 +0,0 @@ - - - - - --1 package de.juplo.test; -2 -3 import java.io.BufferedReader; -4 import java.io.File; -5 import java.io.FileNotFoundException; -6 import java.io.FileReader; -7 import java.io.IOException; -8 -9 -10 public class FileComparator -11 { -12 private final File basedir; -13 private BufferedReader expectedReader; -14 private BufferedReader foundReader; -15 -16 public FileComparator(File basedir) -17 { -18 this.basedir = basedir; -19 } -20 -21 public boolean isEqual(final String expectedFile, final String foundFile) -22 throws -23 FileNotFoundException, -24 IOException -25 { -26 File file; -27 String expected, found; -28 -29 file = new File(basedir, expectedFile); -30 expectedReader = new BufferedReader(new FileReader(file)); -31 -32 file = new File(basedir, foundFile); -33 foundReader = new BufferedReader(new FileReader(file)); -34 -35 -36 while ((expected = expectedReader.readLine()) != null) -37 { -38 found = foundReader.readLine(); -39 if (!expected.equals(found)) -40 { -41 System.err.println("Mismatch!"); -42 System.err.println("Expected: " + expected); -43 System.err.println("Found: " + found); -44 return false; -45 } -46 } -47 -48 if ((found = foundReader.readLine()) != null) -49 { -50 System.err.println("Found more content than expected!"); -51 System.err.println("Starting with: " + found); -52 return false; -53 } -54 -55 return true; -56 } -57 } --
Class Summary | -
---|
- FileComparator - | -
- You don't have frames. Go here -
- -Packages | -
---|
- de.juplo.test - | -
-1 package de.juplo.plugins.hibernate4; -2 -3 /* -4 * Copyright 2001-2005 The Apache Software Foundation. -5 * -6 * Licensed under the Apache License, Version 2.0 (the "License"); -7 * you may not use this file except in compliance with the License. -8 * You may obtain a copy of the License at -9 * -10 * http://www.apache.org/licenses/LICENSE-2.0 -11 * -12 * Unless required by applicable law or agreed to in writing, software -13 * distributed under the License is distributed on an "AS IS" BASIS, -14 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -15 * See the License for the specific language governing permissions and -16 * limitations under the License. -17 */ -18 -19 import com.pyx4j.log4j.MavenLogAppender; -20 import java.io.File; -21 import java.io.FileInputStream; -22 import java.io.FileNotFoundException; -23 import java.io.FileOutputStream; -24 import java.io.IOException; -25 import java.io.InputStream; -26 import java.io.ObjectInputStream; -27 import java.io.ObjectOutputStream; -28 import java.math.BigInteger; -29 import java.net.URL; -30 import java.net.URLClassLoader; -31 import java.security.MessageDigest; -32 import java.security.NoSuchAlgorithmException; -33 import java.sql.Driver; -34 import java.sql.DriverPropertyInfo; -35 import java.sql.SQLException; -36 import java.sql.SQLFeatureNotSupportedException; -37 import java.util.Collections; -38 import java.util.Comparator; -39 import java.util.HashMap; -40 import java.util.HashSet; -41 import java.util.LinkedHashSet; -42 import java.util.LinkedList; -43 import java.util.List; -44 import java.util.Map; -45 import java.util.Map.Entry; -46 import java.util.Properties; -47 import java.util.Set; -48 import java.util.TreeSet; -49 import java.util.logging.Logger; -50 import java.util.regex.Matcher; -51 import java.util.regex.Pattern; -52 import javax.persistence.Embeddable; -53 import javax.persistence.Entity; -54 import javax.persistence.MappedSuperclass; -55 import javax.persistence.spi.PersistenceUnitTransactionType; -56 import org.apache.maven.artifact.Artifact; -57 import org.apache.maven.model.Resource; -58 import org.apache.maven.plugin.AbstractMojo; -59 import org.apache.maven.plugin.MojoExecutionException; -60 import org.apache.maven.plugin.MojoFailureException; -61 import org.apache.maven.project.MavenProject; -62 import org.hibernate.boot.registry.StandardServiceRegistryBuilder; -63 import org.hibernate.boot.registry.classloading.spi.ClassLoaderService; -64 import org.hibernate.boot.registry.classloading.spi.ClassLoadingException; -65 import org.hibernate.boot.registry.internal.StandardServiceRegistryImpl; -66 import org.hibernate.cfg.Environment; -67 import org.hibernate.cfg.NamingStrategy; -68 import org.hibernate.envers.configuration.spi.AuditConfiguration; -69 import org.hibernate.internal.util.config.ConfigurationHelper; -70 import org.hibernate.jpa.boot.internal.ParsedPersistenceXmlDescriptor; -71 import org.hibernate.jpa.boot.internal.PersistenceXmlParser; -72 import org.hibernate.jpa.boot.spi.ProviderChecker; -73 import org.hibernate.tool.hbm2ddl.SchemaExport; -74 import org.hibernate.tool.hbm2ddl.SchemaExport.Type; -75 import org.hibernate.tool.hbm2ddl.Target; -76 import org.scannotation.AnnotationDB; -77 -78 -79 /** -80 * Goal which extracts the hibernate-mapping-configuration and -81 * exports an according SQL-database-schema. -82 * -83 * @goal export -84 * @phase process-classes -85 * @threadSafe -86 * @requiresDependencyResolution runtime -87 */ -88 public class Hbm2DdlMojo extends AbstractMojo -89 { -90 public final static String EXPORT_SKIPPED_PROPERTY = "hibernate.export.skipped"; -91 -92 public final static String DRIVER_CLASS = "hibernate.connection.driver_class"; -93 public final static String URL = "hibernate.connection.url"; -94 public final static String USERNAME = "hibernate.connection.username"; -95 public final static String PASSWORD = "hibernate.connection.password"; -96 public final static String DIALECT = "hibernate.dialect"; -97 public final static String NAMING_STRATEGY="hibernate.ejb.naming_strategy"; -98 public final static String ENVERS = "hibernate.export.envers"; -99 -100 public final static String JPA_DRIVER = "javax.persistence.jdbc.driver"; -101 public final static String JPA_URL = "javax.persistence.jdbc.url"; -102 public final static String JPA_USERNAME = "javax.persistence.jdbc.user"; -103 public final static String JPA_PASSWORD = "javax.persistence.jdbc.password"; -104 -105 public final static String MD5S = "hibernate4-generatedschema.md5s"; -106 -107 private final static Pattern split = Pattern.compile("[^,\\s]+"); -108 -109 -110 /** -111 * The maven project. -112 * <p> -113 * Only needed internally. -114 * -115 * @parameter property="project" -116 * @required -117 * @readonly -118 */ -119 private MavenProject project; -120 -121 /** -122 * Build-directory. -123 * <p> -124 * Only needed internally. -125 * -126 * @parameter property="project.build.directory" -127 * @required -128 * @readonly -129 */ -130 private String buildDirectory; -131 -132 /** -133 * Classes-Directory to scan. -134 * <p> -135 * This parameter defaults to the maven build-output-directory for classes. -136 * Additionally, all dependencies are scanned for annotated classes. -137 * -138 * @parameter property="project.build.outputDirectory" -139 * @since 1.0 -140 */ -141 private String outputDirectory; -142 -143 /** -144 * Whether to scan test-classes too, or not. -145 * <p> -146 * If this parameter is set to <code>true</code> the test-classes of the -147 * artifact will be scanned for hibernate-annotated classes additionally. -148 * -149 * @parameter property="hibernate.export.scan_testclasses" default-value="false" -150 * @since 1.0.1 -151 */ -152 private boolean scanTestClasses; -153 -154 /** -155 * Dependency-Scopes, that should be scanned for annotated classes. -156 * <p> -157 * By default, only dependencies in the scope <code>compile</code> are -158 * scanned for annotated classes. Multiple scopes can be seperated by -159 * white space or commas. -160 * <p> -161 * If you do not want any dependencies to be scanned for annotated -162 * classes, set this parameter to <code>none</code>. -163 * <p> -164 * The plugin does not scan for annotated classes in transitive -165 * dependencies. If some of your annotated classes are hidden in a -166 * transitive dependency, you can simply add that dependency explicitly. -167 * -168 * @parameter property="hibernate.export.scan_dependencies" default-value="compile" -169 * @since 1.0.3 -170 */ -171 private String scanDependencies; -172 -173 /** -174 * Test-Classes-Directory to scan. -175 * <p> -176 * This parameter defaults to the maven build-output-directory for -177 * test-classes. -178 * <p> -179 * This parameter is only used, when <code>scanTestClasses</code> is set -180 * to <code>true</code>! -181 * -182 * @parameter property="project.build.testOutputDirectory" -183 * @since 1.0.2 -184 */ -185 private String testOutputDirectory; -186 -187 /** -188 * Skip execution -189 * <p> -190 * If set to <code>true</code>, the execution is skipped. -191 * <p> -192 * A skipped execution is signaled via the maven-property -193 * <code>${hibernate.export.skipped}</code>. -194 * <p> -195 * The execution is skipped automatically, if no modified or newly added -196 * annotated classes are found and the dialect was not changed. -197 * -198 * @parameter property="hibernate.skip" default-value="${maven.test.skip}" -199 * @since 1.0 -200 */ -201 private boolean skip; -202 -203 /** -204 * Force execution -205 * <p> -206 * Force execution, even if no modified or newly added annotated classes -207 * where found and the dialect was not changed. -208 * <p> -209 * <code>skip</code> takes precedence over <code>force</code>. -210 * -211 * @parameter property="hibernate.export.force" default-value="false" -212 * @since 1.0 -213 */ -214 private boolean force; -215 -216 /** -217 * SQL-Driver name. -218 * -219 * @parameter property="hibernate.connection.driver_class" -220 * @since 1.0 -221 */ -222 private String driverClassName; -223 -224 /** -225 * Database URL. -226 * -227 * @parameter property="hibernate.connection.url" -228 * @since 1.0 -229 */ -230 private String url; -231 -232 /** -233 * Database username -234 * -235 * @parameter property="hibernate.connection.username" -236 * @since 1.0 -237 */ -238 private String username; -239 -240 /** -241 * Database password -242 * -243 * @parameter property="hibernate.connection.password" -244 * @since 1.0 -245 */ -246 private String password; -247 -248 /** -249 * Hibernate dialect. -250 * -251 * @parameter property="hibernate.dialect" -252 * @since 1.0 -253 */ -254 private String hibernateDialect; -255 -256 /** -257 * Hibernate Naming Strategy -258 * -259 * @parameter property="hibernate.ejb.naming_strategy" -260 * @since 1.0.2 -261 */ -262 private String hibernateNamingStrategy; -263 -264 /** -265 * Path to Hibernate properties file. -266 * If this parameter is not set the plugin will try to load the configuration -267 * from a file <code>hibernate.properties</code> on the classpath. The -268 * test-classpath takes precedence. -269 * -270 * @parameter -271 * @since 1.0 -272 */ -273 private String hibernateProperties; -274 -275 /** -276 * Path to Hibernate configuration file (.cfg.xml). -277 * Settings in this file will overwrite settings in the properties file. -278 * If this parameter is not set the plugin will try to load the configuration -279 * from a file <code>hibernate.cfg.xml</code> on the classpath. The -280 * test-classpath takes precedence. -281 * -282 * @parameter -283 * @since 1.1.0 -284 */ -285 private String hibernateConfig; -286 -287 /** -288 * Name of the persistence-unit. -289 * If there is only one persistence-unit available, that unit will be used -290 * automatically. -291 * Settings in this file will overwrite settings in the properties or the -292 * configuration file. -293 * -294 * @parameter -295 * @since 1.1.0 -296 */ -297 private String persistenceUnit; -298 -299 /** -300 * List of Hibernate-Mapping-Files (XML). -301 * Multiple files can be separated with white-spaces and/or commas. -302 * -303 * @parameter property="hibernate.mapping" -304 * @since 1.0.2 -305 */ -306 private String hibernateMapping; -307 -308 /** -309 * Target of execution: -310 * <ul> -311 * <li><strong>NONE</strong> only export schema to SQL-script (forces execution, signals skip)</li> -312 * <li><strong>EXPORT</strong> create database (<strong>DEFAULT!</strong>). forces execution, signals skip)</li> -313 * <li><strong>SCRIPT</strong> export schema to SQL-script and print it to STDOUT</li> -314 * <li><strong>BOTH</strong></li> -315 * </ul> -316 * -317 * A database connection is only needed for EXPORT and BOTH, but a -318 * Hibernate-Dialect must always be chosen. -319 * -320 * @parameter property="hibernate.export.target" default-value="EXPORT" -321 * @since 1.0 -322 */ -323 private String target; -324 -325 /** -326 * Type of execution. -327 * <ul> -328 * <li><strong>NONE</strong> do nothing - just validate the configuration</li> -329 * <li><strong>CREATE</strong> create database-schema</li> -330 * <li><strong>DROP</strong> drop database-schema</li> -331 * <li><strong>BOTH</strong> (<strong>DEFAULT!</strong>)</li> -332 * </ul> -333 * -334 * If NONE is choosen, no databaseconnection is needed. -335 * -336 * @parameter property="hibernate.export.type" default-value="BOTH" -337 * @since 1.0 -338 */ -339 private String type; -340 -341 /** -342 * Output file. -343 * -344 * @parameter property="hibernate.export.schema.filename" default-value="${project.build.directory}/schema.sql" -345 * @since 1.0 -346 */ -347 private String outputFile; -348 -349 /** -350 * Delimiter in output-file. -351 * -352 * @parameter property="hibernate.export.schema.delimiter" default-value=";" -353 * @since 1.0 -354 */ -355 private String delimiter; -356 -357 /** -358 * Format output-file. -359 * -360 * @parameter property="hibernate.export.schema.format" default-value="true" -361 * @since 1.0 -362 */ -363 private boolean format; -364 -365 /** -366 * Generate envers schema for auditing tables. -367 * -368 * @parameter property="hibernate.export.envers" default-value="true" -369 * @since 1.0.3 -370 */ -371 private boolean envers; -372 -373 -374 @Override -375 public void execute() -376 throws -377 MojoFailureException, -378 MojoExecutionException -379 { -380 if (skip) -381 { -382 getLog().info("Execution of hibernate4-maven-plugin:export was skipped!"); -383 project.getProperties().setProperty(EXPORT_SKIPPED_PROPERTY, "true"); -384 return; -385 } -386 -387 Map<String,String> md5s; -388 boolean modified = false; -389 File saved = new File(buildDirectory + File.separator + MD5S); -390 -391 if (saved.isFile() && saved.length() > 0) -392 { -393 try -394 { -395 FileInputStream fis = new FileInputStream(saved); -396 ObjectInputStream ois = new ObjectInputStream(fis); -397 md5s = (HashMap<String,String>)ois.readObject(); -398 ois.close(); -399 } -400 catch (Exception e) -401 { -402 md5s = new HashMap<String,String>(); -403 getLog().warn("Cannot read timestamps from saved: " + e); -404 } -405 } -406 else -407 { -408 md5s = new HashMap<String,String>(); -409 try -410 { -411 saved.createNewFile(); -412 } -413 catch (IOException e) -414 { -415 getLog().debug("Cannot create file \"" + saved.getPath() + "\" for timestamps: " + e); -416 } -417 } -418 -419 URLClassLoader classLoader = null; -420 try -421 { -422 getLog().debug("Creating ClassLoader for project-dependencies..."); -423 List<String> classpathFiles = project.getCompileClasspathElements(); -424 if (scanTestClasses) -425 classpathFiles.addAll(project.getTestClasspathElements()); -426 List<URL> urls = new LinkedList<URL>(); -427 File file; -428 file = new File(testOutputDirectory); -429 if (!file.exists()) -430 { -431 getLog().info("creating test-output-directory: " + testOutputDirectory); -432 file.mkdirs(); -433 } -434 urls.add(file.toURI().toURL()); -435 file = new File(outputDirectory); -436 if (!file.exists()) -437 { -438 getLog().info("creating output-directory: " + outputDirectory); -439 file.mkdirs(); -440 } -441 urls.add(file.toURI().toURL()); -442 for (String pathElement : classpathFiles) -443 { -444 getLog().debug("Dependency: " + pathElement); -445 urls.add(new File(pathElement).toURI().toURL()); -446 } -447 classLoader = -448 new URLClassLoader( -449 urls.toArray(new URL[urls.size()]), -450 getClass().getClassLoader() -451 ); -452 } -453 catch (Exception e) -454 { -455 getLog().error("Error while creating ClassLoader!", e); -456 throw new MojoExecutionException(e.getMessage()); -457 } -458 -459 Set<Class<?>> classes = -460 new TreeSet<Class<?>>( -461 new Comparator<Class<?>>() { -462 @Override -463 public int compare(Class<?> a, Class<?> b) -464 { -465 return a.getName().compareTo(b.getName()); -466 } -467 } -468 ); -469 -470 try -471 { -472 AnnotationDB db = new AnnotationDB(); -473 File dir = new File(outputDirectory); -474 if (dir.exists()) -475 { -476 getLog().info("Scanning directory " + outputDirectory + " for annotated classes..."); -477 URL dirUrl = dir.toURI().toURL(); -478 db.scanArchives(dirUrl); -479 } -480 if (scanTestClasses) -481 { -482 dir = new File(testOutputDirectory); -483 if (dir.exists()) -484 { -485 getLog().info("Scanning directory " + testOutputDirectory + " for annotated classes..."); -486 URL dirUrl = dir.toURI().toURL(); -487 db.scanArchives(dirUrl); -488 } -489 } -490 if (scanDependencies != null) -491 { -492 Matcher matcher = split.matcher(scanDependencies); -493 while (matcher.find()) -494 { -495 getLog().info("Scanning dependencies for scope " + matcher.group()); -496 for (Artifact artifact : project.getDependencyArtifacts()) -497 { -498 if (!artifact.getScope().equalsIgnoreCase(matcher.group())) -499 continue; -500 if (artifact.getFile() == null) -501 { -502 getLog().warn( -503 "Cannot scan dependency " + -504 artifact.getId() + -505 ": no JAR-file available!" -506 ); -507 continue; -508 } -509 getLog().info( -510 "Scanning dependency " + -511 artifact.getId() + -512 " for annotated classes..." -513 ); -514 db.scanArchives(artifact.getFile().toURI().toURL()); -515 } -516 } -517 } -518 -519 Set<String> classNames = new HashSet<String>(); -520 if (db.getAnnotationIndex().containsKey(Entity.class.getName())) -521 classNames.addAll(db.getAnnotationIndex().get(Entity.class.getName())); -522 if (db.getAnnotationIndex().containsKey(MappedSuperclass.class.getName())) -523 classNames.addAll(db.getAnnotationIndex().get(MappedSuperclass.class.getName())); -524 if (db.getAnnotationIndex().containsKey(Embeddable.class.getName())) -525 classNames.addAll(db.getAnnotationIndex().get(Embeddable.class.getName())); -526 -527 MessageDigest digest = java.security.MessageDigest.getInstance("MD5"); -528 for (String name : classNames) -529 { -530 Class<?> annotatedClass = classLoader.loadClass(name); -531 classes.add(annotatedClass); -532 String resourceName = annotatedClass.getName(); -533 resourceName = resourceName.substring(resourceName.lastIndexOf(".") + 1, resourceName.length()) + ".class"; -534 InputStream is = -535 annotatedClass -536 .getResourceAsStream(resourceName); -537 byte[] buffer = new byte[1024*4]; // copy data in 4MB-chunks -538 int i; -539 while((i = is.read(buffer)) > -1) -540 digest.update(buffer, 0, i); -541 is.close(); -542 byte[] bytes = digest.digest(); -543 BigInteger bi = new BigInteger(1, bytes); -544 String newMd5 = String.format("%0" + (bytes.length << 1) + "x", bi); -545 String oldMd5 = !md5s.containsKey(name) ? "" : md5s.get(name); -546 if (!newMd5.equals(oldMd5)) -547 { -548 getLog().debug("Found new or modified annotated class: " + name); -549 modified = true; -550 md5s.put(name, newMd5); -551 } -552 else -553 { -554 getLog().debug(oldMd5 + " -> class unchanged: " + name); -555 } -556 } -557 } -558 catch (ClassNotFoundException e) -559 { -560 getLog().error("Error while adding annotated classes!", e); -561 throw new MojoExecutionException(e.getMessage()); -562 } -563 catch (Exception e) -564 { -565 getLog().error("Error while scanning!", e); -566 throw new MojoFailureException(e.getMessage()); -567 } -568 -569 -570 ValidationConfiguration config = new ValidationConfiguration(); -571 // Clear unused system-properties -572 config.setProperties(new Properties()); -573 -574 -575 ClassLoader contextClassLoader = Thread.currentThread().getContextClassLoader(); -576 StandardServiceRegistryImpl registry = null; -577 MavenLogAppender.startPluginLog(this); -578 -579 try -580 { -581 /** -582 * Change class-loader of current thread, so that hibernate can -583 * see all dependencies! -584 */ -585 Thread.currentThread().setContextClassLoader(classLoader); -586 -587 -588 /** Try to read configuration from properties-file */ -589 try -590 { -591 if (hibernateProperties == null) -592 { -593 URL url = classLoader.findResource("hibernate.properties"); -594 if (url == null) -595 { -596 getLog().info("No hibernate.properties on the classpath!"); -597 } -598 else -599 { -600 getLog().info("Reading settings from hibernate.properties on the classpath."); -601 Properties properties = new Properties(); -602 properties.load(url.openStream()); -603 config.setProperties(properties); -604 } -605 } -606 else -607 { -608 File file = new File(hibernateProperties); -609 if (file.exists()) -610 { -611 getLog().info("Reading settings from file " + hibernateProperties + "..."); -612 Properties properties = new Properties(); -613 properties.load(new FileInputStream(file)); -614 config.setProperties(properties); -615 } -616 else -617 getLog().info("No hibernate-properties-file found! (Checked path: " + hibernateProperties + ")"); -618 } -619 } -620 catch (IOException e) -621 { -622 getLog().error("Error while reading properties!", e); -623 throw new MojoExecutionException(e.getMessage()); -624 } -625 -626 /** Try to read configuration from configuration-file */ -627 try -628 { -629 if (hibernateConfig == null) -630 { -631 URL url = classLoader.findResource("hibernate.cfg.xml"); -632 if (url == null) -633 { -634 getLog().info("No hibernate.cfg.xml on the classpath!"); -635 } -636 else -637 { -638 getLog().info("Reading settings from hibernate.cfg.xml on the classpath."); -639 config.configure(url); -640 } -641 } -642 else -643 { -644 File file = new File(hibernateConfig); -645 if (file.exists()) -646 { -647 getLog().info("Reading configuration from file " + hibernateConfig + "..."); -648 config.configure(file); -649 } -650 else -651 getLog().info("No hibernate-configuration-file found! (Checked path: " + hibernateConfig + ")"); -652 } -653 } -654 catch (Exception e) -655 { -656 getLog().error("Error while reading configuration!", e); -657 throw new MojoExecutionException(e.getMessage()); -658 } -659 -660 ParsedPersistenceXmlDescriptor persistenceUnitDescriptor = -661 getPersistenceUnitDescriptor( -662 persistenceUnit, -663 config.getProperties(), -664 new MavenProjectClassLoaderService(classLoader) -665 ); -666 if (persistenceUnitDescriptor != null) -667 config.setProperties(persistenceUnitDescriptor.getProperties()); -668 -669 -670 /** Overwrite values from properties-file or set, if given */ -671 -672 if (driverClassName != null) -673 { -674 if (config.getProperties().containsKey(DRIVER_CLASS)) -675 getLog().debug( -676 "Overwriting property " + -677 DRIVER_CLASS + "=" + config.getProperty(DRIVER_CLASS) + -678 " with the value " + driverClassName -679 ); -680 else -681 getLog().debug("Using the value " + driverClassName); -682 config.setProperty(DRIVER_CLASS, driverClassName); -683 } -684 if (config.getProperty(DRIVER_CLASS) == null) -685 { -686 String driver = config.getProperty(JPA_DRIVER); -687 if (driver != null) -688 { -689 getLog().info( -690 DRIVER_CLASS + -691 " is not set. Borrow setting from " + -692 JPA_DRIVER + -693 ": " + -694 driver); -695 config.setProperty(DRIVER_CLASS, driver); -696 } -697 } -698 -699 if (url != null) -700 { -701 if (config.getProperties().containsKey(URL)) -702 getLog().debug( -703 "Overwriting property " + -704 URL + "=" + config.getProperty(URL) + -705 " with the value " + url -706 ); -707 else -708 getLog().debug("Using the value " + url); -709 config.setProperty(URL, url); -710 } -711 if (config.getProperty(URL) == null) -712 { -713 String url = config.getProperty(JPA_URL); -714 if (url != null) -715 { -716 getLog().info( -717 URL + -718 " is not set. Borrow setting from " + -719 JPA_URL + -720 ": " + -721 url); -722 config.setProperty(URL, url); -723 } -724 } -725 -726 if (username != null) -727 { -728 if (config.getProperties().containsKey(USERNAME)) -729 getLog().debug( -730 "Overwriting property " + -731 USERNAME + "=" + config.getProperty(USERNAME) + -732 " with the value " + username -733 ); -734 else -735 getLog().debug("Using the value " + username); -736 config.setProperty(USERNAME, username); -737 } -738 if (config.getProperty(USERNAME) == null) -739 { -740 String username = config.getProperty(JPA_USERNAME); -741 if (username != null) -742 { -743 getLog().info( -744 USERNAME + -745 " is not set. Borrow setting from " + -746 JPA_USERNAME + -747 ": " + -748 username); -749 config.setProperty(USERNAME, username); -750 } -751 } -752 -753 if (password != null) -754 { -755 if (config.getProperties().containsKey(PASSWORD)) -756 getLog().debug( -757 "Overwriting property " + -758 PASSWORD + "=" + config.getProperty(PASSWORD) + -759 " with value " + password -760 ); -761 else -762 getLog().debug("Using value " + password + " for property " + PASSWORD); -763 config.setProperty(PASSWORD, password); -764 } -765 if (config.getProperty(PASSWORD) == null) -766 { -767 String password = config.getProperty(JPA_PASSWORD); -768 if (password != null) -769 { -770 getLog().info( -771 PASSWORD + -772 " is not set. Borrow setting from " + -773 JPA_PASSWORD + -774 ": " + -775 password); -776 config.setProperty(PASSWORD, password); -777 } -778 } -779 -780 if (hibernateDialect != null) -781 { -782 if (config.getProperties().containsKey(DIALECT)) -783 getLog().debug( -784 "Overwriting property " + -785 DIALECT + "=" + config.getProperty(DIALECT) + -786 " with value " + hibernateDialect -787 ); -788 else -789 getLog().debug( -790 "Using value " + hibernateDialect + " for property " + DIALECT -791 ); -792 config.setProperty(DIALECT, hibernateDialect); -793 } -794 -795 if ( hibernateNamingStrategy != null ) -796 { -797 if ( config.getProperties().contains(NAMING_STRATEGY)) -798 getLog().debug( -799 "Overwriting property " + -800 NAMING_STRATEGY + "=" + config.getProperty(NAMING_STRATEGY) + -801 " with value " + hibernateNamingStrategy -802 ); -803 else -804 getLog().debug( -805 "Using value " + hibernateNamingStrategy + " for property " + -806 NAMING_STRATEGY -807 ); -808 config.setProperty(NAMING_STRATEGY, hibernateNamingStrategy); -809 } -810 -811 /** The generated SQL varies with the dialect! */ -812 if (md5s.containsKey(DIALECT)) -813 { -814 String dialect = config.getProperty(DIALECT); -815 if (md5s.get(DIALECT).equals(dialect)) -816 getLog().debug("SQL-dialect unchanged."); -817 else -818 { -819 modified = true; -820 if (dialect == null) -821 { -822 getLog().debug("SQL-dialect was unset."); -823 md5s.remove(DIALECT); -824 } -825 else -826 { -827 getLog().debug("SQL-dialect changed: " + dialect); -828 md5s.put(DIALECT, dialect); -829 } -830 } -831 } -832 else -833 { -834 String dialect = config.getProperty(DIALECT); -835 if (dialect != null) -836 { -837 modified = true; -838 md5s.put(DIALECT, config.getProperty(DIALECT)); -839 } -840 } -841 -842 /** The generated SQL varies with the envers-configuration */ -843 if (md5s.get(ENVERS) != null) -844 { -845 if (md5s.get(ENVERS).equals(Boolean.toString(envers))) -846 getLog().debug("Envers-Configuration unchanged. Enabled: " + envers); -847 else -848 { -849 getLog().debug("Envers-Configuration changed. Enabled: " + envers); -850 modified = true; -851 md5s.put(ENVERS, Boolean.toString(envers)); -852 } -853 } -854 else -855 { -856 modified = true; -857 md5s.put(ENVERS, Boolean.toString(envers)); -858 } -859 -860 if (config.getProperties().isEmpty()) -861 { -862 getLog().error("No properties set!"); -863 throw new MojoFailureException("Hibernate configuration is missing!"); -864 } -865 -866 getLog().info("Gathered hibernate-configuration (turn on debugging for details):"); -867 for (Entry<Object,Object> entry : config.getProperties().entrySet()) -868 getLog().info(" " + entry.getKey() + " = " + entry.getValue()); -869 -870 -871 getLog().debug("Adding explicitly configured mappings..."); -872 if (hibernateMapping != null) -873 { -874 try -875 { -876 MessageDigest digest = java.security.MessageDigest.getInstance("MD5"); -877 for (String filename : hibernateMapping.split("[\\s,]+")) -878 { -879 // First try the filename as absolute/relative path -880 File file = new File(filename); -881 if (!file.exists()) -882 { -883 // If the file was not found, search for it in the resource-directories -884 for (Resource resource : project.getResources()) -885 { -886 file = new File(resource.getDirectory() + File.separator + filename); -887 if (file.exists()) -888 break; -889 } -890 } -891 if (file != null && file.exists()) -892 { -893 InputStream is = new FileInputStream(file); -894 byte[] buffer = new byte[1024*4]; // copy data in 4MB-chunks -895 int i; -896 while((i = is.read(buffer)) > -1) -897 digest.update(buffer, 0, i); -898 is.close(); -899 byte[] bytes = digest.digest(); -900 BigInteger bi = new BigInteger(1, bytes); -901 String newMd5 = String.format("%0" + (bytes.length << 1) + "x", bi); -902 String oldMd5 = !md5s.containsKey(filename) ? "" : md5s.get(filename); -903 if (!newMd5.equals(oldMd5)) -904 { -905 getLog().debug("Found new or modified mapping-file: " + filename); -906 modified = true; -907 md5s.put(filename, newMd5); -908 } -909 else -910 { -911 getLog().debug(oldMd5 + " -> mapping-file unchanged: " + filename); -912 } -913 getLog().debug("Adding mappings from XML-configurationfile: " + file); -914 config.addFile(file); -915 } -916 else -917 throw new MojoFailureException("File " + filename + " could not be found in any of the configured resource-directories!"); -918 } -919 } -920 catch (NoSuchAlgorithmException e) -921 { -922 throw new MojoFailureException("Cannot calculate MD5 sums!", e); -923 } -924 catch (FileNotFoundException e) -925 { -926 throw new MojoFailureException("Cannot calculate MD5 sums!", e); -927 } -928 catch (IOException e) -929 { -930 throw new MojoFailureException("Cannot calculate MD5 sums!", e); -931 } -932 } -933 -934 getLog().debug("Adding annotated classes to hibernate-mapping-configuration..."); -935 // build annotated packages -936 Set<String> packages = new HashSet<String>(); -937 for (Class<?> annotatedClass : classes) -938 { -939 String packageName = annotatedClass.getPackage().getName(); -940 if (!packages.contains(packageName)) -941 { -942 getLog().debug("Add package " + packageName); -943 packages.add(packageName); -944 config.addPackage(packageName); -945 getLog().debug("type definintions" + config.getTypeDefs()); -946 } -947 getLog().debug("Class " + annotatedClass); -948 config.addAnnotatedClass(annotatedClass); -949 } -950 -951 Target target = null; -952 try -953 { -954 target = Target.valueOf(this.target.toUpperCase()); -955 } -956 catch (IllegalArgumentException e) -957 { -958 getLog().error("Invalid value for configuration-option \"target\": " + this.target); -959 getLog().error("Valid values are: NONE, SCRIPT, EXPORT, BOTH"); -960 throw new MojoExecutionException("Invalid value for configuration-option \"target\""); -961 } -962 Type type = null; -963 try -964 { -965 type = Type.valueOf(this.type.toUpperCase()); -966 } -967 catch (IllegalArgumentException e) -968 { -969 getLog().error("Invalid value for configuration-option \"type\": " + this.type); -970 getLog().error("Valid values are: NONE, CREATE, DROP, BOTH"); -971 throw new MojoExecutionException("Invalid value for configuration-option \"type\""); -972 } -973 -974 -975 if (config.getProperty(DIALECT) == null) -976 throw new MojoFailureException("hibernate-dialect must be set!"); -977 -978 -979 if (target.equals(Target.SCRIPT) || target.equals(Target.NONE)) -980 { -981 project.getProperties().setProperty(EXPORT_SKIPPED_PROPERTY, "true"); -982 } -983 if ( -984 !modified -985 && !target.equals(Target.SCRIPT) -986 && !target.equals(Target.NONE) -987 && !force -988 ) -989 { -990 getLog().info("No modified annotated classes or mapping-files found and dialect unchanged."); -991 getLog().info("Skipping schema generation!"); -992 project.getProperties().setProperty(EXPORT_SKIPPED_PROPERTY, "true"); -993 return; -994 } -995 -996 -997 if ( config.getProperties().containsKey(NAMING_STRATEGY)) -998 { -999 String namingStrategy = config.getProperty(NAMING_STRATEGY); -1000 getLog().debug("Explicitly set NamingStrategy: " + namingStrategy); -1001 try -1002 { -1003 @SuppressWarnings("unchecked") -1004 Class<NamingStrategy> namingStrategyClass = (Class<NamingStrategy>) Class.forName(namingStrategy); -1005 config.setNamingStrategy(namingStrategyClass.newInstance()); -1006 } -1007 catch (Exception e) -1008 { -1009 getLog().error("Error setting NamingStrategy", e); -1010 throw new MojoExecutionException(e.getMessage()); -1011 } -1012 } -1013 -1014 -1015 Environment.verifyProperties(config.getProperties()); -1016 ConfigurationHelper.resolvePlaceHolders(config.getProperties()); -1017 registry = -1018 (StandardServiceRegistryImpl) -1019 new StandardServiceRegistryBuilder() -1020 .applySettings(config.getProperties()) -1021 .build(); -1022 -1023 config.buildMappings(); -1024 -1025 if (envers) -1026 { -1027 getLog().info("Automatic auditing via hibernate-envers enabled!"); -1028 AuditConfiguration.getFor(config); -1029 } -1030 -1031 SchemaExport export = new SchemaExport(registry, config); -1032 export.setDelimiter(delimiter); -1033 export.setFormat(format); -1034 -1035 File outF = new File(outputFile); -1036 -1037 if (!outF.isAbsolute()) -1038 { -1039 // Interpret relative file path relative to build directory -1040 outF = new File(buildDirectory, outputFile); -1041 getLog().info("Adjusted relative path, resulting path is " + outF.getPath()); -1042 } -1043 -1044 // Ensure that directory path for specified file exists -1045 File outFileParentDir = outF.getParentFile(); -1046 if (null != outFileParentDir && !outFileParentDir.exists()) -1047 { -1048 try -1049 { -1050 getLog().info("Creating directory path for output file:" + outFileParentDir.getPath()); -1051 outFileParentDir.mkdirs(); -1052 } -1053 catch (Exception e) -1054 { -1055 getLog().error("Error creating directory path for output file: " + e.getLocalizedMessage()); -1056 } -1057 } -1058 -1059 export.setOutputFile(outF.getPath()); -1060 export.execute(target, type); -1061 -1062 for (Object exception : export.getExceptions()) -1063 getLog().debug(exception.toString()); -1064 } -1065 finally -1066 { -1067 /** Stop Log-Capturing */ -1068 MavenLogAppender.endPluginLog(this); -1069 -1070 /** Restore the old class-loader (TODO: is this really necessary?) */ -1071 Thread.currentThread().setContextClassLoader(contextClassLoader); -1072 -1073 if (registry != null) -1074 registry.destroy(); -1075 } -1076 -1077 /** Write md5-sums for annotated classes to file */ -1078 try -1079 { -1080 FileOutputStream fos = new FileOutputStream(saved); -1081 ObjectOutputStream oos = new ObjectOutputStream(fos); -1082 oos.writeObject(md5s); -1083 oos.close(); -1084 fos.close(); -1085 } -1086 catch (Exception e) -1087 { -1088 getLog().error("Cannot write md5-sums to file: " + e); -1089 } -1090 } -1091 -1092 private ParsedPersistenceXmlDescriptor getPersistenceUnitDescriptor( -1093 String name, -1094 Properties properties, -1095 ClassLoaderService loader -1096 ) -1097 throws -1098 MojoFailureException -1099 { -1100 PersistenceXmlParser parser = -1101 new PersistenceXmlParser( -1102 loader, -1103 PersistenceUnitTransactionType.RESOURCE_LOCAL -1104 ); -1105 -1106 List<ParsedPersistenceXmlDescriptor> units = parser.doResolve(properties); -1107 -1108 if (name == null) -1109 { -1110 switch (units.size()) -1111 { -1112 case 0: -1113 getLog().info("Found no META-INF/persistence.xml."); -1114 return null; -1115 case 1: -1116 getLog().info("Using persistence-unit " + units.get(0).getName()); -1117 return units.get(0); -1118 default: -1119 getLog().warn("No name provided and multiple persistence units found:"); -1120 for (ParsedPersistenceXmlDescriptor unit : units) -1121 getLog().warn(" - " + unit.getName()); -1122 return null; -1123 } -1124 -1125 } -1126 -1127 for (ParsedPersistenceXmlDescriptor unit : units) -1128 { -1129 getLog().debug("Found persistence-unit " + unit.getName()); -1130 if (!unit.getName().equals(name)) -1131 continue; -1132 -1133 // See if we (Hibernate) are the persistence provider -1134 if (!ProviderChecker.isProvider(unit, properties)) -1135 { -1136 getLog().debug("Wrong provider: " + unit.getProviderClassName()); -1137 continue; -1138 } -1139 -1140 getLog().info("Using persistence-unit " + unit.getName()); -1141 return unit; -1142 } -1143 -1144 throw new MojoFailureException("Could not find persistence-unit " + name); -1145 } -1146 -1147 -1148 static final class MavenProjectClassLoaderService implements ClassLoaderService -1149 { -1150 final private ClassLoader loader; -1151 -1152 -1153 public MavenProjectClassLoaderService(ClassLoader loader) -1154 { -1155 this.loader = loader; -1156 } -1157 -1158 -1159 @Override -1160 public <T> Class<T> classForName(String name) -1161 { -1162 try -1163 { -1164 return (Class<T>)loader.loadClass(name); -1165 } -1166 catch (ClassNotFoundException e) -1167 { -1168 throw new ClassLoadingException( "Unable to load class [" + name + "]", e ); -1169 } -1170 } -1171 -1172 @Override -1173 public URL locateResource(String name) -1174 { -1175 return loader.getResource(name); -1176 } -1177 -1178 @Override -1179 public InputStream locateResourceStream(String name) -1180 { -1181 return loader.getResourceAsStream(name); -1182 } -1183 -1184 @Override -1185 public List<URL> locateResources(String name) -1186 { -1187 try -1188 { -1189 return Collections.list(loader.getResources(name)); -1190 } -1191 catch (IOException e) -1192 { -1193 return Collections.EMPTY_LIST; -1194 } -1195 } -1196 -1197 @Override -1198 public <S> LinkedHashSet<S> loadJavaServices(Class<S> serviceContract) -1199 { -1200 throw new UnsupportedOperationException("Not supported yet."); //To change body of generated methods, choose Tools | Templates. -1201 } -1202 -1203 @Override -1204 public void stop() { } -1205 -1206 } -1207 -1208 -1209 /** -1210 * Needed, because DriverManager won't pick up drivers, that were not -1211 * loaded by the system-classloader! -1212 * See: -1213 * http://stackoverflow.com/questions/288828/how-to-use-a-jdbc-driver-fromodifiedm-an-arbitrary-location -1214 */ -1215 static final class DriverProxy implements Driver -1216 { -1217 private final Driver target; -1218 -1219 DriverProxy(Driver target) -1220 { -1221 if (target == null) -1222 throw new NullPointerException(); -1223 this.target = target; -1224 } -1225 -1226 public java.sql.Driver getTarget() -1227 { -1228 return target; -1229 } -1230 -1231 @Override -1232 public boolean acceptsURL(String url) throws SQLException -1233 { -1234 return target.acceptsURL(url); -1235 } -1236 -1237 @Override -1238 public java.sql.Connection connect( -1239 String url, -1240 java.util.Properties info -1241 ) -1242 throws -1243 SQLException -1244 { -1245 return target.connect(url, info); -1246 } -1247 -1248 @Override -1249 public int getMajorVersion() -1250 { -1251 return target.getMajorVersion(); -1252 } -1253 -1254 @Override -1255 public int getMinorVersion() -1256 { -1257 return target.getMinorVersion(); -1258 } -1259 -1260 @Override -1261 public DriverPropertyInfo[] getPropertyInfo( -1262 String url, -1263 Properties info -1264 ) -1265 throws -1266 SQLException -1267 { -1268 return target.getPropertyInfo(url, info); -1269 } -1270 -1271 @Override -1272 public boolean jdbcCompliant() -1273 { -1274 return target.jdbcCompliant(); -1275 } -1276 -1277 /** -1278 * This Method cannot be annotated with @Override, becaus the plugin -1279 * will not compile then under Java 1.6! -1280 */ -1281 public Logger getParentLogger() throws SQLFeatureNotSupportedException -1282 { -1283 throw new SQLFeatureNotSupportedException("Not supported, for backward-compatibility with Java 1.6"); -1284 } -1285 -1286 @Override -1287 public String toString() -1288 { -1289 return "Proxy: " + target; -1290 } -1291 -1292 @Override -1293 public int hashCode() -1294 { -1295 return target.hashCode(); -1296 } -1297 -1298 @Override -1299 public boolean equals(Object obj) -1300 { -1301 if (!(obj instanceof DriverProxy)) -1302 return false; -1303 DriverProxy other = (DriverProxy) obj; -1304 return this.target.equals(other.target); -1305 } -1306 } -1307 } --
-1 -2 package de.juplo.plugins.hibernate4; -3 -4 import org.apache.maven.plugin.AbstractMojo; -5 import org.apache.maven.plugin.MojoExecutionException; -6 -7 import org.w3c.dom.Document; -8 import org.w3c.dom.Element; -9 import org.w3c.dom.Node; -10 import org.w3c.dom.NodeList; -11 import org.xml.sax.SAXException; -12 -13 import javax.xml.parsers.DocumentBuilder; -14 import javax.xml.parsers.DocumentBuilderFactory; -15 import javax.xml.parsers.ParserConfigurationException; -16 import java.io.IOException; -17 import java.io.InputStream; -18 import java.util.ArrayList; -19 import java.util.List; -20 -21 /** -22 * Display help information on hibernate4-maven-plugin.<br> -23 * Call <code>mvn hibernate4:help -Ddetail=true -Dgoal=<goal-name></code> to display parameter details. -24 * @author maven-plugin-tools -25 * @goal help -26 * @requiresProject false -27 * @threadSafe -28 */ -29 public class HelpMojo -30 extends AbstractMojo -31 { -32 /** -33 * If <code>true</code>, display all settable properties for each goal. -34 * -35 * @parameter property="detail" default-value="false" -36 */ -37 private boolean detail; -38 -39 /** -40 * The name of the goal for which to show help. If unspecified, all goals will be displayed. -41 * -42 * @parameter property="goal" -43 */ -44 private java.lang.String goal; -45 -46 /** -47 * The maximum length of a display line, should be positive. -48 * -49 * @parameter property="lineLength" default-value="80" -50 */ -51 private int lineLength; -52 -53 /** -54 * The number of spaces per indentation level, should be positive. -55 * -56 * @parameter property="indentSize" default-value="2" -57 */ -58 private int indentSize; -59 -60 // groupId/artifactId/plugin-help.xml -61 private static final String PLUGIN_HELP_PATH = -62 "/META-INF/maven/de.juplo/hibernate4-maven-plugin/plugin-help.xml"; -63 -64 private static final int DEFAULT_LINE_LENGTH = 80; -65 -66 private Document build() -67 throws MojoExecutionException -68 { -69 getLog().debug( "load plugin-help.xml: " + PLUGIN_HELP_PATH ); -70 InputStream is = null; -71 try -72 { -73 is = getClass().getResourceAsStream( PLUGIN_HELP_PATH ); -74 DocumentBuilderFactory dbFactory = DocumentBuilderFactory.newInstance(); -75 DocumentBuilder dBuilder = dbFactory.newDocumentBuilder(); -76 return dBuilder.parse( is ); -77 } -78 catch ( IOException e ) -79 { -80 throw new MojoExecutionException( e.getMessage(), e ); -81 } -82 catch ( ParserConfigurationException e ) -83 { -84 throw new MojoExecutionException( e.getMessage(), e ); -85 } -86 catch ( SAXException e ) -87 { -88 throw new MojoExecutionException( e.getMessage(), e ); -89 } -90 finally -91 { -92 if ( is != null ) -93 { -94 try -95 { -96 is.close(); -97 } -98 catch ( IOException e ) -99 { -100 throw new MojoExecutionException( e.getMessage(), e ); -101 } -102 } -103 } -104 } -105 -106 /** -107 * {@inheritDoc} -108 */ -109 public void execute() -110 throws MojoExecutionException -111 { -112 if ( lineLength <= 0 ) -113 { -114 getLog().warn( "The parameter 'lineLength' should be positive, using '80' as default." ); -115 lineLength = DEFAULT_LINE_LENGTH; -116 } -117 if ( indentSize <= 0 ) -118 { -119 getLog().warn( "The parameter 'indentSize' should be positive, using '2' as default." ); -120 indentSize = 2; -121 } -122 -123 Document doc = build(); -124 -125 StringBuilder sb = new StringBuilder(); -126 Node plugin = getSingleChild( doc, "plugin" ); -127 -128 -129 String name = getValue( plugin, "name" ); -130 String version = getValue( plugin, "version" ); -131 String id = getValue( plugin, "groupId" ) + ":" + getValue( plugin, "artifactId" ) + ":" + version; -132 if ( isNotEmpty( name ) && !name.contains( id ) ) -133 { -134 append( sb, name + " " + version, 0 ); -135 } -136 else -137 { -138 if ( isNotEmpty( name ) ) -139 { -140 append( sb, name, 0 ); -141 } -142 else -143 { -144 append( sb, id, 0 ); -145 } -146 } -147 append( sb, getValue( plugin, "description" ), 1 ); -148 append( sb, "", 0 ); -149 -150 //<goalPrefix>plugin</goalPrefix> -151 String goalPrefix = getValue( plugin, "goalPrefix" ); -152 -153 Node mojos1 = getSingleChild( plugin, "mojos" ); -154 -155 List<Node> mojos = findNamedChild( mojos1, "mojo" ); -156 -157 if ( goal == null || goal.length() <= 0 ) -158 { -159 append( sb, "This plugin has " + mojos.size() + ( mojos.size() > 1 ? " goals:" : " goal:" ), 0 ); -160 append( sb, "", 0 ); -161 } -162 -163 for ( Node mojo : mojos ) -164 { -165 writeGoal( sb, goalPrefix, (Element) mojo ); -166 } -167 -168 if ( getLog().isInfoEnabled() ) -169 { -170 getLog().info( sb.toString() ); -171 } -172 } -173 -174 -175 private static boolean isNotEmpty( String string ) -176 { -177 return string != null && string.length() > 0; -178 } -179 -180 private String getValue( Node node, String elementName ) -181 throws MojoExecutionException -182 { -183 return getSingleChild( node, elementName ).getTextContent(); -184 } -185 -186 private Node getSingleChild( Node node, String elementName ) -187 throws MojoExecutionException -188 { -189 List<Node> namedChild = findNamedChild( node, elementName ); -190 if ( namedChild.isEmpty() ) -191 { -192 throw new MojoExecutionException( "Could not find " + elementName + " in plugin-help.xml" ); -193 } -194 if ( namedChild.size() > 1 ) -195 { -196 throw new MojoExecutionException( "Multiple " + elementName + " in plugin-help.xml" ); -197 } -198 return namedChild.get( 0 ); -199 } -200 -201 private List<Node> findNamedChild( Node node, String elementName ) -202 { -203 List<Node> result = new ArrayList<Node>(); -204 NodeList childNodes = node.getChildNodes(); -205 for ( int i = 0; i < childNodes.getLength(); i++ ) -206 { -207 Node item = childNodes.item( i ); -208 if ( elementName.equals( item.getNodeName() ) ) -209 { -210 result.add( item ); -211 } -212 } -213 return result; -214 } -215 -216 private Node findSingleChild( Node node, String elementName ) -217 throws MojoExecutionException -218 { -219 List<Node> elementsByTagName = findNamedChild( node, elementName ); -220 if ( elementsByTagName.isEmpty() ) -221 { -222 return null; -223 } -224 if ( elementsByTagName.size() > 1 ) -225 { -226 throw new MojoExecutionException( "Multiple " + elementName + "in plugin-help.xml" ); -227 } -228 return elementsByTagName.get( 0 ); -229 } -230 -231 private void writeGoal( StringBuilder sb, String goalPrefix, Element mojo ) -232 throws MojoExecutionException -233 { -234 String mojoGoal = getValue( mojo, "goal" ); -235 Node configurationElement = findSingleChild( mojo, "configuration" ); -236 Node description = findSingleChild( mojo, "description" ); -237 if ( goal == null || goal.length() <= 0 || mojoGoal.equals( goal ) ) -238 { -239 append( sb, goalPrefix + ":" + mojoGoal, 0 ); -240 Node deprecated = findSingleChild( mojo, "deprecated" ); -241 if ( ( deprecated != null ) && isNotEmpty( deprecated.getTextContent() ) ) -242 { -243 append( sb, "Deprecated. " + deprecated.getTextContent(), 1 ); -244 if ( detail && description != null ) -245 { -246 append( sb, "", 0 ); -247 append( sb, description.getTextContent(), 1 ); -248 } -249 } -250 else if ( description != null ) -251 { -252 append( sb, description.getTextContent(), 1 ); -253 } -254 append( sb, "", 0 ); -255 -256 if ( detail ) -257 { -258 Node parametersNode = getSingleChild( mojo, "parameters" ); -259 List<Node> parameters = findNamedChild( parametersNode, "parameter" ); -260 append( sb, "Available parameters:", 1 ); -261 append( sb, "", 0 ); -262 -263 for ( Node parameter : parameters ) -264 { -265 writeParameter( sb, parameter, configurationElement ); -266 } -267 } -268 } -269 } -270 -271 private void writeParameter( StringBuilder sb, Node parameter, Node configurationElement ) -272 throws MojoExecutionException -273 { -274 String parameterName = getValue( parameter, "name" ); -275 String parameterDescription = getValue( parameter, "description" ); -276 -277 Element fieldConfigurationElement = (Element) findSingleChild( configurationElement, parameterName ); -278 -279 String parameterDefaultValue = ""; -280 if ( fieldConfigurationElement != null && fieldConfigurationElement.hasAttribute( "default-value" ) ) -281 { -282 parameterDefaultValue = " (Default: " + fieldConfigurationElement.getAttribute( "default-value" ) + ")"; -283 } -284 append( sb, parameterName + parameterDefaultValue, 2 ); -285 Node deprecated = findSingleChild( parameter, "deprecated" ); -286 if ( ( deprecated != null ) && isNotEmpty( deprecated.getTextContent() ) ) -287 { -288 append( sb, "Deprecated. " + deprecated.getTextContent(), 3 ); -289 append( sb, "", 0 ); -290 } -291 append( sb, parameterDescription, 3 ); -292 if ( "true".equals( getValue( parameter, "required" ) ) ) -293 { -294 append( sb, "Required: Yes", 3 ); -295 } -296 if ( ( fieldConfigurationElement != null ) && isNotEmpty( fieldConfigurationElement.getTextContent() ) ) -297 { -298 String property = getPropertyFromExpression( fieldConfigurationElement.getTextContent() ); -299 append( sb, "User property: " + property, 3 ); -300 } -301 -302 append( sb, "", 0 ); -303 } -304 -305 /** -306 * <p>Repeat a String <code>n</code> times to form a new string.</p> -307 * -308 * @param str String to repeat -309 * @param repeat number of times to repeat str -310 * @return String with repeated String -311 * @throws NegativeArraySizeException if <code>repeat < 0</code> -312 * @throws NullPointerException if str is <code>null</code> -313 */ -314 private static String repeat( String str, int repeat ) -315 { -316 StringBuilder buffer = new StringBuilder( repeat * str.length() ); -317 -318 for ( int i = 0; i < repeat; i++ ) -319 { -320 buffer.append( str ); -321 } -322 -323 return buffer.toString(); -324 } -325 -326 /** -327 * Append a description to the buffer by respecting the indentSize and lineLength parameters. -328 * <b>Note</b>: The last character is always a new line. -329 * -330 * @param sb The buffer to append the description, not <code>null</code>. -331 * @param description The description, not <code>null</code>. -332 * @param indent The base indentation level of each line, must not be negative. -333 */ -334 private void append( StringBuilder sb, String description, int indent ) -335 { -336 for ( String line : toLines( description, indent, indentSize, lineLength ) ) -337 { -338 sb.append( line ).append( '\n' ); -339 } -340 } -341 -342 /** -343 * Splits the specified text into lines of convenient display length. -344 * -345 * @param text The text to split into lines, must not be <code>null</code>. -346 * @param indent The base indentation level of each line, must not be negative. -347 * @param indentSize The size of each indentation, must not be negative. -348 * @param lineLength The length of the line, must not be negative. -349 * @return The sequence of display lines, never <code>null</code>. -350 * @throws NegativeArraySizeException if <code>indent < 0</code> -351 */ -352 private static List<String> toLines( String text, int indent, int indentSize, int lineLength ) -353 { -354 List<String> lines = new ArrayList<String>(); -355 -356 String ind = repeat( "\t", indent ); -357 -358 String[] plainLines = text.split( "(\r\n)|(\r)|(\n)" ); -359 -360 for ( String plainLine : plainLines ) -361 { -362 toLines( lines, ind + plainLine, indentSize, lineLength ); -363 } -364 -365 return lines; -366 } -367 -368 /** -369 * Adds the specified line to the output sequence, performing line wrapping if necessary. -370 * -371 * @param lines The sequence of display lines, must not be <code>null</code>. -372 * @param line The line to add, must not be <code>null</code>. -373 * @param indentSize The size of each indentation, must not be negative. -374 * @param lineLength The length of the line, must not be negative. -375 */ -376 private static void toLines( List<String> lines, String line, int indentSize, int lineLength ) -377 { -378 int lineIndent = getIndentLevel( line ); -379 StringBuilder buf = new StringBuilder( 256 ); -380 -381 String[] tokens = line.split( " +" ); -382 -383 for ( String token : tokens ) -384 { -385 if ( buf.length() > 0 ) -386 { -387 if ( buf.length() + token.length() >= lineLength ) -388 { -389 lines.add( buf.toString() ); -390 buf.setLength( 0 ); -391 buf.append( repeat( " ", lineIndent * indentSize ) ); -392 } -393 else -394 { -395 buf.append( ' ' ); -396 } -397 } -398 -399 for ( int j = 0; j < token.length(); j++ ) -400 { -401 char c = token.charAt( j ); -402 if ( c == '\t' ) -403 { -404 buf.append( repeat( " ", indentSize - buf.length() % indentSize ) ); -405 } -406 else if ( c == '\u00A0' ) -407 { -408 buf.append( ' ' ); -409 } -410 else -411 { -412 buf.append( c ); -413 } -414 } -415 } -416 lines.add( buf.toString() ); -417 } -418 -419 /** -420 * Gets the indentation level of the specified line. -421 * -422 * @param line The line whose indentation level should be retrieved, must not be <code>null</code>. -423 * @return The indentation level of the line. -424 */ -425 private static int getIndentLevel( String line ) -426 { -427 int level = 0; -428 for ( int i = 0; i < line.length() && line.charAt( i ) == '\t'; i++ ) -429 { -430 level++; -431 } -432 for ( int i = level + 1; i <= level + 4 && i < line.length(); i++ ) -433 { -434 if ( line.charAt( i ) == '\t' ) -435 { -436 level++; -437 break; -438 } -439 } -440 return level; -441 } -442 -443 private String getPropertyFromExpression( String expression ) -444 { -445 if ( expression != null && expression.startsWith( "${" ) && expression.endsWith( "}" ) -446 && !expression.substring( 2 ).contains( "${" ) ) -447 { -448 // expression="${xxx}" -> property="xxx" -449 return expression.substring( 2, expression.length() - 1 ); -450 } -451 // no property can be extracted -452 return null; -453 } -454 } --
-1 package de.juplo.plugins.hibernate4; -2 -3 import javax.validation.Validation; -4 -5 import org.hibernate.cfg.Configuration; -6 import org.hibernate.cfg.beanvalidation.TypeSafeActivatorAccessor; -7 import org.hibernate.dialect.Dialect; -8 import org.hibernate.metamodel.source.MappingException; -9 -10 -11 /** -12 * This integration is usually performed by BeanValidationIntegrator. -13 * Unfortunately, that integration will only be activated upon -14 * initialization of the ServiceRegistry, which initializes -15 * DatasourceConnectionProviderImpl, which looks up the datasource, -16 * which requires a JNDI context ... -17 * We therefore reimplement the relevant parts of BeanValidatorIntegrator. -18 * Since that must occur after secondPassCompile(), which is invoked by -19 * Configuration.generateSchemaCreationScript, which is invoked by -20 * SchemaExport, some fancy subclassing is needed to invoke the integration -21 * at the right time. -22 * @author Mark Robinson <mark@mrobinson.ca> -23 * @author Frank Schimmel <frank.schimmel@cm4all.com> -24 */ -25 public class ValidationConfiguration extends Configuration -26 { -27 private static final long serialVersionUID = 1L; -28 -29 -30 @Override -31 protected void secondPassCompile() throws MappingException -32 { -33 super.secondPassCompile(); -34 -35 try -36 { -37 TypeSafeActivatorAccessor.applyRelationalConstraints( -38 Validation.buildDefaultValidatorFactory(), -39 classes.values(), -40 getProperties(), -41 ((Class<Dialect>)Class.forName(getProperty(Hbm2DdlMojo.DIALECT))).newInstance() -42 ); -43 } -44 catch (Exception e) -45 { -46 throw new RuntimeException(e); -47 } -48 } -49 -50 public String getTypeDefs() -51 { -52 return typeDefs.entrySet().toString(); -53 } -54 } --
Class Summary | -
---|
- DriverProxy - | -
- Hbm2DdlMojo - | -
- HelpMojo - | -
- MavenProjectClassLoaderService - | -
- ValidationConfiguration - | -
- You don't have frames. Go here -
- --1 package org.hibernate.cfg.beanvalidation; -2 -3 /** -4 * This class enables access to the public methods of {@link TypeSafeActivator} -5 * which itself is visible in the package only. -6 * -7 * @author Frank Schimmel <frank.schimmel@cm4all.com> -8 */ -9 public class TypeSafeActivatorAccessor extends TypeSafeActivator { -10 // Empty: just makes public methods accessible. -11 } --
Class Summary | -
---|
- TypeSafeActivatorAccessor - | -
Packages | -
---|
- de.juplo.plugins.hibernate4 - | -
- org.hibernate.cfg.beanvalidation - | -
Modifier and Type | -Constant Field | -Value | -
---|---|---|
-
-public static final String |
-DIALECT |
-"hibernate.dialect" |
-
-
-public static final String |
-DRIVER_CLASS |
-"hibernate.connection.driver_class" |
-
-
-public static final String |
-ENVERS |
-"hibernate.export.envers" |
-
-
-public static final String |
-EXPORT_SKIPPED_PROPERTY |
-"hibernate.export.skipped" |
-
-
-public static final String |
-JPA_DRIVER |
-"javax.persistence.jdbc.driver" |
-
-
-public static final String |
-JPA_PASSWORD |
-"javax.persistence.jdbc.password" |
-
-
-public static final String |
-JPA_URL |
-"javax.persistence.jdbc.url" |
-
-
-public static final String |
-JPA_USERNAME |
-"javax.persistence.jdbc.user" |
-
-
-public static final String |
-MD5S |
-"hibernate4-generatedschema.md5s" |
-
-
-public static final String |
-NAMING_STRATEGY |
-"hibernate.ejb.naming_strategy" |
-
-
-public static final String |
-PASSWORD |
-"hibernate.connection.password" |
-
-
-public static final String |
-URL |
-"hibernate.connection.url" |
-
-
-public static final String |
-USERNAME |
-"hibernate.connection.username" |
-
Copyright © 2016. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.1/apidocs/de/juplo/plugins/hibernate4/Hbm2DdlMojo.html b/dist/hibernate4-maven-plugin-1.1.1/apidocs/de/juplo/plugins/hibernate4/Hbm2DdlMojo.html deleted file mode 100644 index 3b6a32a8..00000000 --- a/dist/hibernate4-maven-plugin-1.1.1/apidocs/de/juplo/plugins/hibernate4/Hbm2DdlMojo.html +++ /dev/null @@ -1,549 +0,0 @@ - - - - - - -public class Hbm2DdlMojo
-extends org.apache.maven.plugin.AbstractMojo
-Modifier and Type | -Field and Description | -
---|---|
static String |
-DIALECT |
-
static String |
-DRIVER_CLASS |
-
static String |
-ENVERS |
-
static String |
-EXPORT_SKIPPED_PROPERTY |
-
static String |
-JPA_DRIVER |
-
static String |
-JPA_PASSWORD |
-
static String |
-JPA_URL |
-
static String |
-JPA_USERNAME |
-
static String |
-MD5S |
-
static String |
-NAMING_STRATEGY |
-
static String |
-PASSWORD |
-
static String |
-URL |
-
static String |
-USERNAME |
-
ROLE
Constructor and Description | -
---|
Hbm2DdlMojo() |
-
Modifier and Type | -Method and Description | -
---|---|
void |
-execute() |
-
getLog, getPluginContext, setLog, setPluginContext
public static final String EXPORT_SKIPPED_PROPERTY-
public static final String DRIVER_CLASS-
public static final String URL-
public static final String USERNAME-
public static final String PASSWORD-
public static final String DIALECT-
public static final String NAMING_STRATEGY-
public static final String ENVERS-
public static final String JPA_DRIVER-
public static final String JPA_URL-
public static final String JPA_USERNAME-
public static final String JPA_PASSWORD-
public static final String MD5S-
Copyright © 2016. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.1/apidocs/de/juplo/plugins/hibernate4/HelpMojo.html b/dist/hibernate4-maven-plugin-1.1.1/apidocs/de/juplo/plugins/hibernate4/HelpMojo.html deleted file mode 100644 index e9b35a85..00000000 --- a/dist/hibernate4-maven-plugin-1.1.1/apidocs/de/juplo/plugins/hibernate4/HelpMojo.html +++ /dev/null @@ -1,315 +0,0 @@ - - - - - - -public class HelpMojo
-extends org.apache.maven.plugin.AbstractMojo
-mvn hibernate4:help -Ddetail=true -Dgoal=<goal-name>
to display parameter details.ROLE
Modifier and Type | -Method and Description | -
---|---|
void |
-execute() |
-
getLog, getPluginContext, setLog, setPluginContext
Copyright © 2016. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.1/apidocs/de/juplo/plugins/hibernate4/ValidationConfiguration.html b/dist/hibernate4-maven-plugin-1.1.1/apidocs/de/juplo/plugins/hibernate4/ValidationConfiguration.html deleted file mode 100644 index 4c8c49f9..00000000 --- a/dist/hibernate4-maven-plugin-1.1.1/apidocs/de/juplo/plugins/hibernate4/ValidationConfiguration.html +++ /dev/null @@ -1,355 +0,0 @@ - - - - - - -public class ValidationConfiguration
-extends org.hibernate.cfg.Configuration
-org.hibernate.cfg.Configuration.MappingsImpl, org.hibernate.cfg.Configuration.MetadataSourceQueue
ARTEFACT_PROCESSING_ORDER, auxiliaryDatabaseObjects, classes, collections, columnNameBindingPerTable, DEFAULT_ARTEFACT_PROCESSING_ORDER, DEFAULT_CACHE_CONCURRENCY_STRATEGY, extendsQueue, fetchProfiles, filterDefinitions, imports, metadataSourceQueue, namedEntityGraphMap, namedProcedureCallMap, namedQueries, namedSqlQueries, propertyReferences, secondPasses, settingsFactory, sqlFunctions, sqlResultSetMappings, tableNameBinding, tables, typeDefs, USE_NEW_ID_GENERATOR_MAPPINGS, xmlHelper
Constructor and Description | -
---|
ValidationConfiguration() |
-
Modifier and Type | -Method and Description | -
---|---|
String |
-getTypeDefs() |
-
protected void |
-secondPassCompile() |
-
add, addAnnotatedClass, addAttributeConverter, addAttributeConverter, addAttributeConverter, addAttributeConverter, addAttributeConverter, addAuxiliaryDatabaseObject, addCacheableFile, addCacheableFile, addCacheableFileStrictly, addClass, addDirectory, addDocument, addFetchProfile, addFile, addFile, addFilterDefinition, addInputStream, addJar, addPackage, addProperties, addResource, addResource, addSqlFunction, addURL, addXML, buildMapping, buildMappings, buildSessionFactory, buildSessionFactory, buildSettings, buildSettings, configure, configure, configure, configure, configure, createMappings, doConfigure, doConfigure, findPossibleExtends, generateDropSchemaScript, generateSchemaCreationScript, generateSchemaUpdateScript, generateSchemaUpdateScriptList, getClassMapping, getClassMappings, getCollectionMapping, getCollectionMappings, getConfigurationInputStream, getCurrentTenantIdentifierResolver, getEntityNotFoundDelegate, getEntityResolver, getEntityTuplizerFactory, getFilterDefinitions, getIdentifierGeneratorFactory, getImports, getInterceptor, getJaccPermissionDeclarations, getMappedSuperclassMappings, getMappedSuperclassMappingsCopy, getNamedEntityGraphs, getNamedProcedureCallMap, getNamedQueries, getNamedSQLQueries, getNamingStrategy, getNamingStrategyDelegator, getProperties, getProperty, getReflectionManager, getSessionFactoryObserver, getSqlFunctions, getSqlResultSetMappings, getTableMappings, getTypeResolver, iterateFetchProfiles, iterateGenerators, mergeProperties, registerTypeContributor, registerTypeOverride, registerTypeOverride, registerTypeOverride, reset, secondPassCompileForeignKeys, setCacheConcurrencyStrategy, setCacheConcurrencyStrategy, setCacheConcurrencyStrategy, setCollectionCacheConcurrencyStrategy, setCollectionCacheConcurrencyStrategy, setCurrentTenantIdentifierResolver, setEntityNotFoundDelegate, setEntityResolver, setInterceptor, setNamingStrategy, setNamingStrategyDelegator, setPrecedence, setProperties, setProperty, setSessionFactoryObserver, validateSchema
public ValidationConfiguration()-
protected void secondPassCompile() - throws org.hibernate.metamodel.source.MappingException-
secondPassCompile
in class org.hibernate.cfg.Configuration
org.hibernate.metamodel.source.MappingException
public String getTypeDefs()-
Copyright © 2016. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.1/apidocs/de/juplo/plugins/hibernate4/class-use/Hbm2DdlMojo.html b/dist/hibernate4-maven-plugin-1.1.1/apidocs/de/juplo/plugins/hibernate4/class-use/Hbm2DdlMojo.html deleted file mode 100644 index ef969a65..00000000 --- a/dist/hibernate4-maven-plugin-1.1.1/apidocs/de/juplo/plugins/hibernate4/class-use/Hbm2DdlMojo.html +++ /dev/null @@ -1,126 +0,0 @@ - - - - - - -Copyright © 2016. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.1/apidocs/de/juplo/plugins/hibernate4/class-use/HelpMojo.html b/dist/hibernate4-maven-plugin-1.1.1/apidocs/de/juplo/plugins/hibernate4/class-use/HelpMojo.html deleted file mode 100644 index f99091fe..00000000 --- a/dist/hibernate4-maven-plugin-1.1.1/apidocs/de/juplo/plugins/hibernate4/class-use/HelpMojo.html +++ /dev/null @@ -1,126 +0,0 @@ - - - - - - -Copyright © 2016. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.1/apidocs/de/juplo/plugins/hibernate4/class-use/ValidationConfiguration.html b/dist/hibernate4-maven-plugin-1.1.1/apidocs/de/juplo/plugins/hibernate4/class-use/ValidationConfiguration.html deleted file mode 100644 index 66a3c9c9..00000000 --- a/dist/hibernate4-maven-plugin-1.1.1/apidocs/de/juplo/plugins/hibernate4/class-use/ValidationConfiguration.html +++ /dev/null @@ -1,126 +0,0 @@ - - - - - - -Copyright © 2016. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.1/apidocs/de/juplo/plugins/hibernate4/package-frame.html b/dist/hibernate4-maven-plugin-1.1.1/apidocs/de/juplo/plugins/hibernate4/package-frame.html deleted file mode 100644 index 8611c70a..00000000 --- a/dist/hibernate4-maven-plugin-1.1.1/apidocs/de/juplo/plugins/hibernate4/package-frame.html +++ /dev/null @@ -1,23 +0,0 @@ - - - - - - -Class | -Description | -
---|---|
Hbm2DdlMojo | -
- Goal which extracts the hibernate-mapping-configuration and
- exports an according SQL-database-schema.
- |
-
HelpMojo | -
- Display help information on hibernate4-maven-plugin.
- |
-
ValidationConfiguration | -
- This integration is usually performed by BeanValidationIntegrator.
- |
-
Copyright © 2016. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.1/apidocs/de/juplo/plugins/hibernate4/package-tree.html b/dist/hibernate4-maven-plugin-1.1.1/apidocs/de/juplo/plugins/hibernate4/package-tree.html deleted file mode 100644 index 5e185eec..00000000 --- a/dist/hibernate4-maven-plugin-1.1.1/apidocs/de/juplo/plugins/hibernate4/package-tree.html +++ /dev/null @@ -1,149 +0,0 @@ - - - - - - -Copyright © 2016. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.1/apidocs/de/juplo/plugins/hibernate4/package-use.html b/dist/hibernate4-maven-plugin-1.1.1/apidocs/de/juplo/plugins/hibernate4/package-use.html deleted file mode 100644 index f625b0ec..00000000 --- a/dist/hibernate4-maven-plugin-1.1.1/apidocs/de/juplo/plugins/hibernate4/package-use.html +++ /dev/null @@ -1,126 +0,0 @@ - - - - - - -Copyright © 2016. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.1/apidocs/deprecated-list.html b/dist/hibernate4-maven-plugin-1.1.1/apidocs/deprecated-list.html deleted file mode 100644 index 74afba63..00000000 --- a/dist/hibernate4-maven-plugin-1.1.1/apidocs/deprecated-list.html +++ /dev/null @@ -1,126 +0,0 @@ - - - - - - -Copyright © 2016. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.1/apidocs/help-doc.html b/dist/hibernate4-maven-plugin-1.1.1/apidocs/help-doc.html deleted file mode 100644 index ff4110d1..00000000 --- a/dist/hibernate4-maven-plugin-1.1.1/apidocs/help-doc.html +++ /dev/null @@ -1,231 +0,0 @@ - - - - - - -The Overview page is the front page of this API document and provides a list of all packages with a summary for each. This page can also contain an overall description of the set of packages.
-Each package has a page that contains a list of its classes and interfaces, with a summary for each. This page can contain six categories:
-Each class, interface, nested class and nested interface has its own separate page. Each of these pages has three sections consisting of a class/interface description, summary tables, and detailed member descriptions:
-Each summary entry contains the first sentence from the detailed description for that item. The summary entries are alphabetical, while the detailed descriptions are in the order they appear in the source code. This preserves the logical groupings established by the programmer.
-Each annotation type has its own separate page with the following sections:
-Each enum has its own separate page with the following sections:
-Each documented package, class and interface has its own Use page. This page describes what packages, classes, methods, constructors and fields use any part of the given class or package. Given a class or interface A, its Use page includes subclasses of A, fields declared as A, methods that return A, and methods and constructors with parameters of type A. You can access this page by first going to the package, class or interface, then clicking on the "Use" link in the navigation bar.
-There is a Class Hierarchy page for all packages, plus a hierarchy for each package. Each hierarchy page contains a list of classes and a list of interfaces. The classes are organized by inheritance structure starting with java.lang.Object
. The interfaces do not inherit from java.lang.Object
.
The Deprecated API page lists all of the API that have been deprecated. A deprecated API is not recommended for use, generally due to improvements, and a replacement API is usually given. Deprecated APIs may be removed in future implementations.
-The Index contains an alphabetic list of all classes, interfaces, constructors, methods, and fields.
-These links take you to the next or previous class, interface, package, or related page.
-These links show and hide the HTML frames. All pages are available with or without frames.
-The All Classes link shows all classes and interfaces except non-static nested types.
-Each serializable or externalizable class has a description of its serialization fields and methods. This information is of interest to re-implementors, not to developers using the API. While there is no link in the navigation bar, you can get to this information by going to any serialized class and clicking "Serialized Form" in the "See also" section of the class description.
-The Constant Field Values page lists the static final fields and their values.
-Copyright © 2016. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.1/apidocs/index-all.html b/dist/hibernate4-maven-plugin-1.1.1/apidocs/index-all.html deleted file mode 100644 index be505a5c..00000000 --- a/dist/hibernate4-maven-plugin-1.1.1/apidocs/index-all.html +++ /dev/null @@ -1,264 +0,0 @@ - - - - - - -TypeSafeActivator
- which itself is visible in the package only.Copyright © 2016. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.1/apidocs/index.html b/dist/hibernate4-maven-plugin-1.1.1/apidocs/index.html deleted file mode 100644 index 78275ddb..00000000 --- a/dist/hibernate4-maven-plugin-1.1.1/apidocs/index.html +++ /dev/null @@ -1,76 +0,0 @@ - - - - - - -This document is designed to be viewed using the frames feature. If you see this message, you are using a non-frame-capable web client. Link to Non-frame version.
-public class TypeSafeActivatorAccessor -extends Object-
TypeSafeActivator
- which itself is visible in the package only.Constructor and Description | -
---|
TypeSafeActivatorAccessor() |
-
Modifier and Type | -Method and Description | -
---|---|
static void |
-activate(org.hibernate.cfg.beanvalidation.ActivationContext arg0) |
-
static void |
-applyCallbackListeners(javax.validation.ValidatorFactory arg0,
- org.hibernate.cfg.beanvalidation.ActivationContext arg1) |
-
static void |
-applyRelationalConstraints(javax.validation.ValidatorFactory arg0,
- Collection<org.hibernate.mapping.PersistentClass> arg1,
- Properties arg2,
- org.hibernate.dialect.Dialect arg3) |
-
static void |
-validateSuppliedFactory(Object arg0) |
-
public TypeSafeActivatorAccessor()-
public static void validateSuppliedFactory(Object arg0)-
public static void activate(org.hibernate.cfg.beanvalidation.ActivationContext arg0)-
public static void applyCallbackListeners(javax.validation.ValidatorFactory arg0, - org.hibernate.cfg.beanvalidation.ActivationContext arg1)-
public static void applyRelationalConstraints(javax.validation.ValidatorFactory arg0, - Collection<org.hibernate.mapping.PersistentClass> arg1, - Properties arg2, - org.hibernate.dialect.Dialect arg3)-
Copyright © 2016. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.1/apidocs/org/hibernate/cfg/beanvalidation/class-use/TypeSafeActivatorAccessor.html b/dist/hibernate4-maven-plugin-1.1.1/apidocs/org/hibernate/cfg/beanvalidation/class-use/TypeSafeActivatorAccessor.html deleted file mode 100644 index a7c77ff1..00000000 --- a/dist/hibernate4-maven-plugin-1.1.1/apidocs/org/hibernate/cfg/beanvalidation/class-use/TypeSafeActivatorAccessor.html +++ /dev/null @@ -1,126 +0,0 @@ - - - - - - -Copyright © 2016. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.1/apidocs/org/hibernate/cfg/beanvalidation/package-frame.html b/dist/hibernate4-maven-plugin-1.1.1/apidocs/org/hibernate/cfg/beanvalidation/package-frame.html deleted file mode 100644 index 3f0a447c..00000000 --- a/dist/hibernate4-maven-plugin-1.1.1/apidocs/org/hibernate/cfg/beanvalidation/package-frame.html +++ /dev/null @@ -1,21 +0,0 @@ - - - - - - -Class | -Description | -
---|---|
TypeSafeActivatorAccessor | -
- This class enables access to the public methods of
-TypeSafeActivator
- which itself is visible in the package only. |
-
Copyright © 2016. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.1/apidocs/org/hibernate/cfg/beanvalidation/package-tree.html b/dist/hibernate4-maven-plugin-1.1.1/apidocs/org/hibernate/cfg/beanvalidation/package-tree.html deleted file mode 100644 index 7fc27358..00000000 --- a/dist/hibernate4-maven-plugin-1.1.1/apidocs/org/hibernate/cfg/beanvalidation/package-tree.html +++ /dev/null @@ -1,139 +0,0 @@ - - - - - - -Copyright © 2016. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.1/apidocs/org/hibernate/cfg/beanvalidation/package-use.html b/dist/hibernate4-maven-plugin-1.1.1/apidocs/org/hibernate/cfg/beanvalidation/package-use.html deleted file mode 100644 index 10bbe73f..00000000 --- a/dist/hibernate4-maven-plugin-1.1.1/apidocs/org/hibernate/cfg/beanvalidation/package-use.html +++ /dev/null @@ -1,126 +0,0 @@ - - - - - - -Copyright © 2016. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.1/apidocs/overview-frame.html b/dist/hibernate4-maven-plugin-1.1.1/apidocs/overview-frame.html deleted file mode 100644 index fcfaf3ad..00000000 --- a/dist/hibernate4-maven-plugin-1.1.1/apidocs/overview-frame.html +++ /dev/null @@ -1,23 +0,0 @@ - - - - - - -- - diff --git a/dist/hibernate4-maven-plugin-1.1.1/apidocs/overview-summary.html b/dist/hibernate4-maven-plugin-1.1.1/apidocs/overview-summary.html deleted file mode 100644 index 18d60a95..00000000 --- a/dist/hibernate4-maven-plugin-1.1.1/apidocs/overview-summary.html +++ /dev/null @@ -1,144 +0,0 @@ - - - - - - -
Package | -Description | -
---|---|
de.juplo.plugins.hibernate4 | -- |
org.hibernate.cfg.beanvalidation | -- |
Copyright © 2016. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.1/apidocs/overview-tree.html b/dist/hibernate4-maven-plugin-1.1.1/apidocs/overview-tree.html deleted file mode 100644 index c0036bd7..00000000 --- a/dist/hibernate4-maven-plugin-1.1.1/apidocs/overview-tree.html +++ /dev/null @@ -1,151 +0,0 @@ - - - - - - -Copyright © 2016. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.1/apidocs/package-list b/dist/hibernate4-maven-plugin-1.1.1/apidocs/package-list deleted file mode 100644 index b80422d3..00000000 --- a/dist/hibernate4-maven-plugin-1.1.1/apidocs/package-list +++ /dev/null @@ -1,2 +0,0 @@ -de.juplo.plugins.hibernate4 -org.hibernate.cfg.beanvalidation diff --git a/dist/hibernate4-maven-plugin-1.1.1/apidocs/packages b/dist/hibernate4-maven-plugin-1.1.1/apidocs/packages deleted file mode 100644 index 6adc7ae5..00000000 --- a/dist/hibernate4-maven-plugin-1.1.1/apidocs/packages +++ /dev/null @@ -1,2 +0,0 @@ -org.hibernate.cfg.beanvalidation -de.juplo.plugins.hibernate4 \ No newline at end of file diff --git a/dist/hibernate4-maven-plugin-1.1.1/apidocs/script.js b/dist/hibernate4-maven-plugin-1.1.1/apidocs/script.js deleted file mode 100644 index b3463569..00000000 --- a/dist/hibernate4-maven-plugin-1.1.1/apidocs/script.js +++ /dev/null @@ -1,30 +0,0 @@ -function show(type) -{ - count = 0; - for (var key in methods) { - var row = document.getElementById(key); - if ((methods[key] & type) != 0) { - row.style.display = ''; - row.className = (count++ % 2) ? rowColor : altColor; - } - else - row.style.display = 'none'; - } - updateTabs(type); -} - -function updateTabs(type) -{ - for (var value in tabs) { - var sNode = document.getElementById(tabs[value][0]); - var spanNode = sNode.firstChild; - if (value == type) { - sNode.className = activeTableTab; - spanNode.innerHTML = tabs[value][1]; - } - else { - sNode.className = tableTab; - spanNode.innerHTML = "" + tabs[value][1] + ""; - } - } -} diff --git a/dist/hibernate4-maven-plugin-1.1.1/apidocs/serialized-form.html b/dist/hibernate4-maven-plugin-1.1.1/apidocs/serialized-form.html deleted file mode 100644 index 3f59362c..00000000 --- a/dist/hibernate4-maven-plugin-1.1.1/apidocs/serialized-form.html +++ /dev/null @@ -1,181 +0,0 @@ - - - - - - -javax.validation.ValidatorFactory factory-
ConcurrentHashMap<K,V> associationsPerEntityPersister-
org.hibernate.cfg.beanvalidation.GroupsPerOperation groupsPerOperation-
boolean initialized-
Copyright © 2016. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.1/apidocs/stylesheet.css b/dist/hibernate4-maven-plugin-1.1.1/apidocs/stylesheet.css deleted file mode 100644 index 98055b22..00000000 --- a/dist/hibernate4-maven-plugin-1.1.1/apidocs/stylesheet.css +++ /dev/null @@ -1,574 +0,0 @@ -/* Javadoc style sheet */ -/* -Overall document style -*/ - -@import url('resources/fonts/dejavu.css'); - -body { - background-color:#ffffff; - color:#353833; - font-family:'DejaVu Sans', Arial, Helvetica, sans-serif; - font-size:14px; - margin:0; -} -a:link, a:visited { - text-decoration:none; - color:#4A6782; -} -a:hover, a:focus { - text-decoration:none; - color:#bb7a2a; -} -a:active { - text-decoration:none; - color:#4A6782; -} -a[name] { - color:#353833; -} -a[name]:hover { - text-decoration:none; - color:#353833; -} -pre { - font-family:'DejaVu Sans Mono', monospace; - font-size:14px; -} -h1 { - font-size:20px; -} -h2 { - font-size:18px; -} -h3 { - font-size:16px; - font-style:italic; -} -h4 { - font-size:13px; -} -h5 { - font-size:12px; -} -h6 { - font-size:11px; -} -ul { - list-style-type:disc; -} -code, tt { - font-family:'DejaVu Sans Mono', monospace; - font-size:14px; - padding-top:4px; - margin-top:8px; - line-height:1.4em; -} -dt code { - font-family:'DejaVu Sans Mono', monospace; - font-size:14px; - padding-top:4px; -} -table tr td dt code { - font-family:'DejaVu Sans Mono', monospace; - font-size:14px; - vertical-align:top; - padding-top:4px; -} -sup { - font-size:8px; -} -/* -Document title and Copyright styles -*/ -.clear { - clear:both; - height:0px; - overflow:hidden; -} -.aboutLanguage { - float:right; - padding:0px 21px; - font-size:11px; - z-index:200; - margin-top:-9px; -} -.legalCopy { - margin-left:.5em; -} -.bar a, .bar a:link, .bar a:visited, .bar a:active { - color:#FFFFFF; - text-decoration:none; -} -.bar a:hover, .bar a:focus { - color:#bb7a2a; -} -.tab { - background-color:#0066FF; - color:#ffffff; - padding:8px; - width:5em; - font-weight:bold; -} -/* -Navigation bar styles -*/ -.bar { - background-color:#4D7A97; - color:#FFFFFF; - padding:.8em .5em .4em .8em; - height:auto;/*height:1.8em;*/ - font-size:11px; - margin:0; -} -.topNav { - background-color:#4D7A97; - color:#FFFFFF; - float:left; - padding:0; - width:100%; - clear:right; - height:2.8em; - padding-top:10px; - overflow:hidden; - font-size:12px; -} -.bottomNav { - margin-top:10px; - background-color:#4D7A97; - color:#FFFFFF; - float:left; - padding:0; - width:100%; - clear:right; - height:2.8em; - padding-top:10px; - overflow:hidden; - font-size:12px; -} -.subNav { - background-color:#dee3e9; - float:left; - width:100%; - overflow:hidden; - font-size:12px; -} -.subNav div { - clear:left; - float:left; - padding:0 0 5px 6px; - text-transform:uppercase; -} -ul.navList, ul.subNavList { - float:left; - margin:0 25px 0 0; - padding:0; -} -ul.navList li{ - list-style:none; - float:left; - padding: 5px 6px; - text-transform:uppercase; -} -ul.subNavList li{ - list-style:none; - float:left; -} -.topNav a:link, .topNav a:active, .topNav a:visited, .bottomNav a:link, .bottomNav a:active, .bottomNav a:visited { - color:#FFFFFF; - text-decoration:none; - text-transform:uppercase; -} -.topNav a:hover, .bottomNav a:hover { - text-decoration:none; - color:#bb7a2a; - text-transform:uppercase; -} -.navBarCell1Rev { - background-color:#F8981D; - color:#253441; - margin: auto 5px; -} -.skipNav { - position:absolute; - top:auto; - left:-9999px; - overflow:hidden; -} -/* -Page header and footer styles -*/ -.header, .footer { - clear:both; - margin:0 20px; - padding:5px 0 0 0; -} -.indexHeader { - margin:10px; - position:relative; -} -.indexHeader span{ - margin-right:15px; -} -.indexHeader h1 { - font-size:13px; -} -.title { - color:#2c4557; - margin:10px 0; -} -.subTitle { - margin:5px 0 0 0; -} -.header ul { - margin:0 0 15px 0; - padding:0; -} -.footer ul { - margin:20px 0 5px 0; -} -.header ul li, .footer ul li { - list-style:none; - font-size:13px; -} -/* -Heading styles -*/ -div.details ul.blockList ul.blockList ul.blockList li.blockList h4, div.details ul.blockList ul.blockList ul.blockListLast li.blockList h4 { - background-color:#dee3e9; - border:1px solid #d0d9e0; - margin:0 0 6px -8px; - padding:7px 5px; -} -ul.blockList ul.blockList ul.blockList li.blockList h3 { - background-color:#dee3e9; - border:1px solid #d0d9e0; - margin:0 0 6px -8px; - padding:7px 5px; -} -ul.blockList ul.blockList li.blockList h3 { - padding:0; - margin:15px 0; -} -ul.blockList li.blockList h2 { - padding:0px 0 20px 0; -} -/* -Page layout container styles -*/ -.contentContainer, .sourceContainer, .classUseContainer, .serializedFormContainer, .constantValuesContainer { - clear:both; - padding:10px 20px; - position:relative; -} -.indexContainer { - margin:10px; - position:relative; - font-size:12px; -} -.indexContainer h2 { - font-size:13px; - padding:0 0 3px 0; -} -.indexContainer ul { - margin:0; - padding:0; -} -.indexContainer ul li { - list-style:none; - padding-top:2px; -} -.contentContainer .description dl dt, .contentContainer .details dl dt, .serializedFormContainer dl dt { - font-size:12px; - font-weight:bold; - margin:10px 0 0 0; - color:#4E4E4E; -} -.contentContainer .description dl dd, .contentContainer .details dl dd, .serializedFormContainer dl dd { - margin:5px 0 10px 0px; - font-size:14px; - font-family:'DejaVu Sans Mono',monospace; -} -.serializedFormContainer dl.nameValue dt { - margin-left:1px; - font-size:1.1em; - display:inline; - font-weight:bold; -} -.serializedFormContainer dl.nameValue dd { - margin:0 0 0 1px; - font-size:1.1em; - display:inline; -} -/* -List styles -*/ -ul.horizontal li { - display:inline; - font-size:0.9em; -} -ul.inheritance { - margin:0; - padding:0; -} -ul.inheritance li { - display:inline; - list-style:none; -} -ul.inheritance li ul.inheritance { - margin-left:15px; - padding-left:15px; - padding-top:1px; -} -ul.blockList, ul.blockListLast { - margin:10px 0 10px 0; - padding:0; -} -ul.blockList li.blockList, ul.blockListLast li.blockList { - list-style:none; - margin-bottom:15px; - line-height:1.4; -} -ul.blockList ul.blockList li.blockList, ul.blockList ul.blockListLast li.blockList { - padding:0px 20px 5px 10px; - border:1px solid #ededed; - background-color:#f8f8f8; -} -ul.blockList ul.blockList ul.blockList li.blockList, ul.blockList ul.blockList ul.blockListLast li.blockList { - padding:0 0 5px 8px; - background-color:#ffffff; - border:none; -} -ul.blockList ul.blockList ul.blockList ul.blockList li.blockList { - margin-left:0; - padding-left:0; - padding-bottom:15px; - border:none; -} -ul.blockList ul.blockList ul.blockList ul.blockList li.blockListLast { - list-style:none; - border-bottom:none; - padding-bottom:0; -} -table tr td dl, table tr td dl dt, table tr td dl dd { - margin-top:0; - margin-bottom:1px; -} -/* -Table styles -*/ -.overviewSummary, .memberSummary, .typeSummary, .useSummary, .constantsSummary, .deprecatedSummary { - width:100%; - border-left:1px solid #EEE; - border-right:1px solid #EEE; - border-bottom:1px solid #EEE; -} -.overviewSummary, .memberSummary { - padding:0px; -} -.overviewSummary caption, .memberSummary caption, .typeSummary caption, -.useSummary caption, .constantsSummary caption, .deprecatedSummary caption { - position:relative; - text-align:left; - background-repeat:no-repeat; - color:#253441; - font-weight:bold; - clear:none; - overflow:hidden; - padding:0px; - padding-top:10px; - padding-left:1px; - margin:0px; - white-space:pre; -} -.overviewSummary caption a:link, .memberSummary caption a:link, .typeSummary caption a:link, -.useSummary caption a:link, .constantsSummary caption a:link, .deprecatedSummary caption a:link, -.overviewSummary caption a:hover, .memberSummary caption a:hover, .typeSummary caption a:hover, -.useSummary caption a:hover, .constantsSummary caption a:hover, .deprecatedSummary caption a:hover, -.overviewSummary caption a:active, .memberSummary caption a:active, .typeSummary caption a:active, -.useSummary caption a:active, .constantsSummary caption a:active, .deprecatedSummary caption a:active, -.overviewSummary caption a:visited, .memberSummary caption a:visited, .typeSummary caption a:visited, -.useSummary caption a:visited, .constantsSummary caption a:visited, .deprecatedSummary caption a:visited { - color:#FFFFFF; -} -.overviewSummary caption span, .memberSummary caption span, .typeSummary caption span, -.useSummary caption span, .constantsSummary caption span, .deprecatedSummary caption span { - white-space:nowrap; - padding-top:5px; - padding-left:12px; - padding-right:12px; - padding-bottom:7px; - display:inline-block; - float:left; - background-color:#F8981D; - border: none; - height:16px; -} -.memberSummary caption span.activeTableTab span { - white-space:nowrap; - padding-top:5px; - padding-left:12px; - padding-right:12px; - margin-right:3px; - display:inline-block; - float:left; - background-color:#F8981D; - height:16px; -} -.memberSummary caption span.tableTab span { - white-space:nowrap; - padding-top:5px; - padding-left:12px; - padding-right:12px; - margin-right:3px; - display:inline-block; - float:left; - background-color:#4D7A97; - height:16px; -} -.memberSummary caption span.tableTab, .memberSummary caption span.activeTableTab { - padding-top:0px; - padding-left:0px; - padding-right:0px; - background-image:none; - float:none; - display:inline; -} -.overviewSummary .tabEnd, .memberSummary .tabEnd, .typeSummary .tabEnd, -.useSummary .tabEnd, .constantsSummary .tabEnd, .deprecatedSummary .tabEnd { - display:none; - width:5px; - position:relative; - float:left; - background-color:#F8981D; -} -.memberSummary .activeTableTab .tabEnd { - display:none; - width:5px; - margin-right:3px; - position:relative; - float:left; - background-color:#F8981D; -} -.memberSummary .tableTab .tabEnd { - display:none; - width:5px; - margin-right:3px; - position:relative; - background-color:#4D7A97; - float:left; - -} -.overviewSummary td, .memberSummary td, .typeSummary td, -.useSummary td, .constantsSummary td, .deprecatedSummary td { - text-align:left; - padding:0px 0px 12px 10px; -} -th.colOne, th.colFirst, th.colLast, .useSummary th, .constantsSummary th, -td.colOne, td.colFirst, td.colLast, .useSummary td, .constantsSummary td{ - vertical-align:top; - padding-right:0px; - padding-top:8px; - padding-bottom:3px; -} -th.colFirst, th.colLast, th.colOne, .constantsSummary th { - background:#dee3e9; - text-align:left; - padding:8px 3px 3px 7px; -} -td.colFirst, th.colFirst { - white-space:nowrap; - font-size:13px; -} -td.colLast, th.colLast { - font-size:13px; -} -td.colOne, th.colOne { - font-size:13px; -} -.overviewSummary td.colFirst, .overviewSummary th.colFirst, -.useSummary td.colFirst, .useSummary th.colFirst, -.overviewSummary td.colOne, .overviewSummary th.colOne, -.memberSummary td.colFirst, .memberSummary th.colFirst, -.memberSummary td.colOne, .memberSummary th.colOne, -.typeSummary td.colFirst{ - width:25%; - vertical-align:top; -} -td.colOne a:link, td.colOne a:active, td.colOne a:visited, td.colOne a:hover, td.colFirst a:link, td.colFirst a:active, td.colFirst a:visited, td.colFirst a:hover, td.colLast a:link, td.colLast a:active, td.colLast a:visited, td.colLast a:hover, .constantValuesContainer td a:link, .constantValuesContainer td a:active, .constantValuesContainer td a:visited, .constantValuesContainer td a:hover { - font-weight:bold; -} -.tableSubHeadingColor { - background-color:#EEEEFF; -} -.altColor { - background-color:#FFFFFF; -} -.rowColor { - background-color:#EEEEEF; -} -/* -Content styles -*/ -.description pre { - margin-top:0; -} -.deprecatedContent { - margin:0; - padding:10px 0; -} -.docSummary { - padding:0; -} - -ul.blockList ul.blockList ul.blockList li.blockList h3 { - font-style:normal; -} - -div.block { - font-size:14px; - font-family:'DejaVu Serif', Georgia, "Times New Roman", Times, serif; -} - -td.colLast div { - padding-top:0px; -} - - -td.colLast a { - padding-bottom:3px; -} -/* -Formatting effect styles -*/ -.sourceLineNo { - color:green; - padding:0 30px 0 0; -} -h1.hidden { - visibility:hidden; - overflow:hidden; - font-size:10px; -} -.block { - display:block; - margin:3px 10px 2px 0px; - color:#474747; -} -.deprecatedLabel, .descfrmTypeLabel, .memberNameLabel, .memberNameLink, -.overrideSpecifyLabel, .packageHierarchyLabel, .paramLabel, .returnLabel, -.seeLabel, .simpleTagLabel, .throwsLabel, .typeNameLabel, .typeNameLink { - font-weight:bold; -} -.deprecationComment, .emphasizedPhrase, .interfaceName { - font-style:italic; -} - -div.block div.block span.deprecationComment, div.block div.block span.emphasizedPhrase, -div.block div.block span.interfaceName { - font-style:normal; -} - -div.contentContainer ul.blockList li.blockList h2{ - padding-bottom:0px; -} diff --git a/dist/hibernate4-maven-plugin-1.1.1/configuration.html b/dist/hibernate4-maven-plugin-1.1.1/configuration.html deleted file mode 100644 index 546dc3f5..00000000 --- a/dist/hibernate4-maven-plugin-1.1.1/configuration.html +++ /dev/null @@ -1,666 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - --
- -- The most simple way to configure the plugin is, to put all the - hibernate-configuration in a hibernate.properties-file on your - classpath. Put the file in the resources-folder. Maven will put - it in the class-folder of your webapp, where it will be picked up - by this plugin as well as by Hibernate 4. -
- -- Doing so, the only additionally configuration needed, to activat the plugin - is the following entry in the plugins-section of your pom.xml: -
- --<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.1.1</version> - <executions> - <execution> - <goals> - <goal>export</goal> - </goals> - </execution> - </executions> -</plugin>
- But be aware, that in this case the database-url, that is - build in the application is the same that is used while testing, where - the database is droped and recreated by the plugin. - Because of that, - - you should never fire up this configuration on your production - system, or your database might be erased! - -
- -- A better approach is, to specify a different url for testing like in the - following snippet: -
- --<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.1.1</version> - <executions> - <execution> - <goals> - <goal>export</goal> - </goals> - </execution> - </executions> - <configuration> - <url><![CDATA[jdbc:mysql://localhost/test-db]]></url> - </configuration> -</plugin>
- Configuration properties, that are set in the configuration-section - of the plugin-configuration cannnot be overwritten elsewere (for details - see Configuration-Method-Precedence). - You never can overwrite them by accident when specifying a property on - the commandline or in your settings.xml. -
-- Alternatively, it is possible, to configure the plugin via maven-properties. - Each relevant configuration-option has a corresponding maven-property - (for a full list see the Documentation of the export-Mojo). - These are named after the - Hibernate JDBC Properties: -
- -- So, instead of writing the hibernate-configuration in the properties-file, - like above, you could put it in the properties-section of your - pom.xml. -
- -- Thogether with the plugin-definition from above, the following would - be a complete configuration (again, the database-url was overwritten in - the plugin-configuration, to be sure to have a separate database for - testing): -
- --<properties> - <hibernate.connection.driver_class>org.hsqldb.jdbcDriver</hibernate.connection.driver_class> - <hibernate.dialect>org.hibernate.dialect.HSQLDialect</hibernate.dialect> - <hibernate.connection.url><![CDATA[jdbc:hsqldb:res:org.my.path.production_db]]></hibernate.connection.url> - <hibernate.connection.username>sa</hibernate.connection.username> - <hibernate.connection.password></hibernate.connection.password> -</properties> - -... - -<plugins> - - ... - - <plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.1.1</version> - <executions> - <execution> - <goals> - <goal>export</goal> - </goals> - </execution> - </executions> - <configuration> - <url><![CDATA[jdbc:hsqldb:target/db/testdb;shutdown=true]]></url> - </configuration> - </plugin> - -<plugins>
- A third way for configuring the plugin is the plugin-configuration. - The relevant configuration-parameters are: -
- -- The equivalent of the configuration from the last section would look - like this: -
- --<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.1.1</version> - <executions> - <execution> - <goals> - <goal>export</goal> - </goals> - </execution> - </executions> - <configuration> - <driverClassName>org.hsqldb.jdbcDriver</driverClassName> - <hibernateDialect>org.hibernate.dialect.HSQLDialect</hibernateDialect> - <url><![CDATA[jdbc:hsqldb:target/db/fotos;shutdown=true]]></url> - <username>sa</username> - <password></password> - </configuration> -</plugin>
- The parameter hibernateProperties (name of the hibernate-properties-file - to use, defaults to hibernate.properties) can only be configured through - this approach. -
- -- For more explanations, see the - Documentation of the export-Mojo. -
-- The configuration is gathered in a fix order: -
- -- If you are in doubt about where a configuration-value comes from, run - maven with the debug-output enabled: mvn -X hibernate4:export - and be aware, that maven-properties can be overwitten on the command-line, - in your ~/.m2/settings.xml and in a profile. -
- -- The plugin-configuration comes last and overwrites everything else. - That way, you can be sure, that a configuration-value, that is - specified in the plugin-configuration will never be overwritten by any - other configuration-method. -
- -- If you need to overwrite plugin-configuration-values with - maven-properties, you can use maven-properties in the plugin-configuration: -
- --<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.1.1</version> - <executions> - <execution> - <goals> - <goal>export</goal> - </goals> - </execution> - </executions> - <configuration> - <password>${my-password-property}</password> - </configuration> -</plugin>
-
-
- -- If you are new to hibernate4-maven-plugin, in many cases, the - {Configuration-Method-Precedence} may be the source of configuration - errors. - To solve this problem, you should run maven with the debugging output - enabled. - For example, by executing: -
- --mvn -X compile hibernate4:export
- (The compile might be necessary, because hibernate4-maven-plugin - has to scan the compiled classes for annotations!) -
- -- Unlike the majority of the maven-plugins, hibernate4-maven-plugin was - designed to give a good many hints, when debugging is enabled. - Because, if you do not know, what went wrong, you can't fix it! -
- -- But be warned: hibernate4-maven-plugin tends to be very chatty ;) -
- - --
-
- -The following is a list of compile dependencies for this project. These dependencies are required to compile and run the application:
-GroupId | -ArtifactId | -Version | -Type | -Licenses |
---|---|---|---|---|
com.pyx4j | -maven-plugin-log4j | -1.0.1 | -jar | -The Apache Software License, Version 2.0 |
de.juplo | -scannotation | -1.0.4 | -jar | -- |
javax.el | -javax.el-api | -3.0.0 | -jar | -CDDL + GPLv2 with classpath exception |
org.apache.maven | -maven-core | -3.3.3 | -jar | -Apache License, Version 2.0 |
org.apache.maven | -maven-plugin-api | -3.3.3 | -jar | -Apache License, Version 2.0 |
org.hibernate | -hibernate-core | -4.3.9.Final | -jar | -GNU Lesser General Public License |
org.hibernate | -hibernate-envers | -4.3.9.Final | -jar | -GNU Lesser General Public License |
org.hibernate | -hibernate-validator | -5.1.3.Final | -jar | -Apache License, Version 2.0 |
The following is a list of transitive dependencies for this project. Transitive dependencies are the dependencies of the project dependencies.
-The following is a list of compile dependencies for this project. These dependencies are required to compile and run the application:
-Apache License, version 2.0: JBoss Logging 3
-Eclipse Public License (EPL), Version 1.0: Java Persistence API, Version 2.1
-Apache Public License 2.0: Plexus Cipher: encryption/decryption Component, Plexus Security Dispatcher Component
-Common Development and Distribution License: Java Transaction API
-Public Domain: AOP alliance, JBoss Logging I18n Annotations
-GNU Lesser General Public License: Core Hibernate O/RM functionality, Entity versioning support, Hibernate Commons Annotations, Hibernate JPA Support
-Eclipse Distribution License (EDL), Version 1.0: Java Persistence API, Version 2.1
-Eclipse Public License, Version 1.0: Aether API, Aether Implementation, Aether SPI, Aether Utilities, org.eclipse.sisu.inject, org.eclipse.sisu.plexus
-Unknown: dom4j, scannotation
-Apache License 2.0: Javassist
-BSD License: AntLR Parser Generator
-AL 2.0: Java Annotation Indexer
-Apache License, Version 2.0: CDI APIs, Hibernate Validator Engine, Maven Aether Provider, Maven Artifact, Maven Builder Support, Maven Core, Maven Model, Maven Model Builder, Maven Plugin API, Maven Repository Metadata Model, Maven Settings, Maven Settings Builder
-COMMON DEVELOPMENT AND DISTRIBUTION LICENSE (CDDL) Version 1.0: JSR-250 Common Annotations for the JavaTM Platform
-LGPL 2.1: Javassist
-CDDL + GPLv2 with classpath exception: Expression Language 3.0 API
-GNU General Public License, Version 2 with the Classpath Exception: Java Transaction API
-MPL 1.1: Javassist
-The Apache Software License, Version 2.0: Bean Validation API, ClassMate, Guava: Google Core Libraries for Java, Hibernate 4 Maven Plugin, Log4j, Plexus :: Component Annotations, Plexus Classworlds, Plexus Interpolation API, Sisu Guice - Core Library, XML Commons External Components XML APIs, javax.inject, maven-plugin-log4j
Filename | -Size | -Entries | -Classes | -Packages | -Java Version | -Debug Information |
---|---|---|---|---|---|---|
antlr-2.7.7.jar | -445.3 kB | -239 | -224 | -12 | -1.2 | -Yes |
aopalliance-1.0.jar | -4.5 kB | -15 | -9 | -2 | -1.3 | -Yes |
classmate-1.0.0.jar | -60.3 kB | -51 | -36 | -4 | -1.6 | -Yes |
guava-18.0.jar | -2.3 MB | -1719 | -1690 | -17 | -1.6 | -Yes |
maven-plugin-log4j-1.0.1.jar | -3.7 kB | -12 | -1 | -1 | -1.4 | -Yes |
scannotation-1.0.4.jar | -20.3 kB | -23 | -13 | -2 | -1.6 | -Yes |
dom4j-1.6.1.jar | -313.9 kB | -208 | -190 | -14 | -1.3 | -Yes |
jsr250-api-1.0.jar | -5.8 kB | -16 | -11 | -2 | -1.5 | -Yes |
javax.el-api-3.0.0.jar | -73.1 kB | -57 | -46 | -1 | -1.7 | -Yes |
cdi-api-1.0.jar | -44.9 kB | -92 | -75 | -7 | -1.5 | -Yes |
javax.inject-1.jar | -2.5 kB | -8 | -6 | -1 | -1.5 | -No |
validation-api-1.1.0.Final.jar | -63.8 kB | -122 | -106 | -8 | -1.6 | -Yes |
log4j-1.2.14.jar | -367.4 kB | -288 | -256 | -19 | -1.1 | -Yes |
maven-aether-provider-3.3.3.jar | -66.3 kB | -43 | -26 | -1 | -1.7 | -Yes |
maven-artifact-3.3.3.jar | -55.1 kB | -57 | -32 | -11 | -1.7 | -Yes |
maven-builder-support-3.3.3.jar | -15 kB | -24 | -10 | -1 | -1.7 | -Yes |
maven-core-3.3.3.jar | -631.9 kB | -489 | -390 | -56 | -1.7 | -Yes |
maven-model-3.3.3.jar | -160.8 kB | -67 | -50 | -3 | -1.7 | -Yes |
maven-model-builder-3.3.3.jar | -176.4 kB | -154 | -121 | -16 | -1.7 | -Yes |
maven-plugin-api-3.3.3.jar | -46.1 kB | -46 | -25 | -6 | -1.7 | -Yes |
maven-repository-metadata-3.3.3.jar | -26 kB | -25 | -7 | -2 | -1.7 | -Yes |
maven-settings-3.3.3.jar | -43 kB | -33 | -17 | -2 | -1.7 | -Yes |
maven-settings-builder-3.3.3.jar | -43.2 kB | -53 | -32 | -5 | -1.7 | -Yes |
plexus-classworlds-2.5.2.jar | -52.7 kB | -52 | -37 | -5 | -1.6 | -Yes |
plexus-component-annotations-1.5.5.jar | -4.2 kB | -15 | -3 | -1 | -1.5 | -No |
plexus-interpolation-1.21.jar | -62.5 kB | -60 | -44 | -6 | -1.5 | -Yes |
aether-api-1.0.2.v20150114.jar | -136.3 kB | -149 | -128 | -11 | -1.5 | -Yes |
aether-impl-1.0.2.v20150114.jar | -173 kB | -114 | -96 | -4 | -1.5 | -Yes |
aether-spi-1.0.2.v20150114.jar | -30.7 kB | -54 | -34 | -8 | -1.5 | -Yes |
aether-util-1.0.2.v20150114.jar | -146.9 kB | -126 | -101 | -13 | -1.5 | -Yes |
org.eclipse.sisu.inject-0.3.0.jar | -375.3 kB | -287 | -269 | -9 | -1.6 | -Yes |
org.eclipse.sisu.plexus-0.3.0.jar | -205.4 kB | -196 | -164 | -20 | -1.6 | -Yes |
hibernate-core-4.3.9.Final.jar | -5.3 MB | -3712 | -3463 | -201 | -1.6 | -Yes |
hibernate-entitymanager-4.3.9.Final.jar | -647.6 kB | -486 | -443 | -27 | -1.6 | -Yes |
hibernate-envers-4.3.9.Final.jar | -427.6 kB | -311 | -259 | -38 | -1.6 | -Yes |
hibernate-validator-5.1.3.Final.jar | -634.3 kB | -483 | -410 | -41 | -1.6 | -Yes |
hibernate-commons-annotations-4.0.5.Final.jar | -75.3 kB | -79 | -67 | -7 | -1.6 | -Yes |
hibernate-jpa-2.1-api-1.0.0.Final.jar | -113.4 kB | -207 | -200 | -4 | -1.6 | -Yes |
javassist-3.18.1-GA.jar | -714.2 kB | -414 | -390 | -17 | -1.6 | -Yes |
jandex-1.1.0.Final.jar | -76.6 kB | -55 | -44 | -1 | -1.6 | -Yes |
jboss-logging-3.1.3.GA.jar | -57.2 kB | -57 | -45 | -1 | -1.6 | -Yes |
jboss-logging-annotations-1.2.0.Beta1.jar | -11.6 kB | -28 | -16 | -1 | -1.6 | -Yes |
jboss-transaction-api_1.2_spec-1.0.0.Final.jar | -27.7 kB | -35 | -22 | -2 | -1.6 | -Yes |
plexus-cipher-1.4.jar | -13.5 kB | -20 | -6 | -1 | -1.4 | -Yes |
plexus-sec-dispatcher-1.3.jar | -28.6 kB | -31 | -13 | -3 | -1.4 | -Yes |
sisu-guice-3.2.5-no_aop.jar | -399.7 kB | -331 | -316 | -8 | -1.6 | -Yes |
xml-apis-1.0.b2.jar | -109.3 kB | -217 | -184 | -17 | -1.2 | -No |
Total | -Size | -Entries | -Classes | -Packages | -Java Version | -Debug Information |
47 | -14.7 MB | -11360 | -10127 | -639 | -1.7 | -44 |
compile: 47 | -compile: 14.7 MB | -compile: 11360 | -compile: 10127 | -compile: 639 | -- | -compile: 44 |
Repo ID | -URL | -Release | -Snapshot |
---|---|---|---|
plexus.snapshots | -https://oss.sonatype.org/content/repositories/plexus-snapshots | -No | -Yes |
central | -http://repo.maven.apache.org/maven2 | -Yes | -No |
snapshots.jboss.org | -http://snapshots.jboss.org/maven2 | -No | -Yes |
sonatype-nexus-snapshots | -https://oss.sonatype.org/content/repositories/snapshots | -No | -Yes |
oss.sonatype.org/jboss-snapshots | -http://oss.sonatype.org/content/repositories/jboss-snapshots | -No | -Yes |
jvnet-nexus-snapshots | -https://maven.java.net/content/repositories/snapshots | -No | -Yes |
repository.jboss.org | -http://repository.jboss.org/maven2 | -Yes | -No |
apache.snapshots | -http://repository.apache.org/snapshots | -No | -Yes |
Repository locations for each of the Dependencies.
--
-
- -<dependency> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.1.1</version> - <type>maven-plugin</type> -</dependency>
<dependency org="de.juplo" name="hibernate4-maven-plugin" rev="1.1.1"> - <artifact name="hibernate4-maven-plugin" type="maven-plugin" /> -</dependency>
-
-
- -The following is the distribution management information used by this project.
- --
-
- -Full name:
- -de.juplo:hibernate4-maven-plugin:1.1.1:export
- -Description:
- -Attributes:
- -Name | - -Type | - -Since | - -Description | -
---|---|---|---|
delimiter | - -String | - -1.0 | - -Delimiter in output-file. Default value is: ;. User property is: hibernate.export.schema.delimiter. |
-
driverClassName | - -String | - -1.0 | - -SQL-Driver name. User property is: hibernate.connection.driver_class. |
-
envers | - -boolean | - -1.0.3 | - -Generate envers schema for auditing tables. Default value is: true. User property is: hibernate.export.envers. |
-
force | - -boolean | - -1.0 | - -Force execution
-
- Force execution, even if no modified or newly added annotated -classes where found and the dialect was not changed. - -skip takes precedence over force. Default value is: false. User property is: hibernate.export.force. |
-
format | - -boolean | - -1.0 | - -Format output-file. Default value is: true. User property is: hibernate.export.schema.format. |
-
hibernateConfig | - -String | - -1.1.0 | - -Path to Hibernate configuration file (.cfg.xml). Settings in this
-file will overwrite settings in the properties file. If this
-parameter is not set the plugin will try to load the configuration
-from a file hibernate.cfg.xml on the classpath. The
-test-classpath takes precedence. |
-
hibernateDialect | - -String | - -1.0 | - -Hibernate dialect. User property is: hibernate.dialect. |
-
hibernateMapping | - -String | - -1.0.2 | - -List of Hibernate-Mapping-Files (XML). Multiple files can be
-separated with white-spaces and/or commas. User property is: hibernate.mapping. |
-
hibernateNamingStrategy | - -String | - -1.0.2 | - -Hibernate Naming Strategy User property is: hibernate.ejb.naming_strategy. |
-
hibernateProperties | - -String | - -1.0 | - -Path to Hibernate properties file. If this parameter is not set the
-plugin will try to load the configuration from a file
-hibernate.properties on the classpath. The
-test-classpath takes precedence. |
-
outputDirectory | - -String | - -1.0 | - -Classes-Directory to scan.
-
- This parameter defaults to the maven build-output-directory for -classes. Additionally, all dependencies are scanned for annotated -classes. User property is: project.build.outputDirectory. |
-
outputFile | - -String | - -1.0 | - -Output file. Default value is: ${project.build.directory}/schema.sql. User property is: hibernate.export.schema.filename. |
-
password | - -String | - -1.0 | - -Database password User property is: hibernate.connection.password. |
-
persistenceUnit | - -String | - -1.1.0 | - -Name of the persistence-unit. If there is only one persistence-unit
-available, that unit will be used automatically. Settings in this
-file will overwrite settings in the properties or the configuration
-file. |
-
scanDependencies | - -String | - -1.0.3 | - -Dependency-Scopes, that should be scanned for annotated classes.
-
- By default, only dependencies in the scope compile -are scanned for annotated classes. Multiple scopes can be seperated -by white space or commas. - -If you do not want any dependencies to be scanned for annotated -classes, set this parameter to none. - -The plugin does not scan for annotated classes in transitive -dependencies. If some of your annotated classes are hidden in a -transitive dependency, you can simply add that dependency -explicitly. Default value is: compile. User property is: hibernate.export.scan_dependencies. |
-
scanTestClasses | - -boolean | - -1.0.1 | - -Whether to scan test-classes too, or not.
-
- If this parameter is set to true the test-classes -of the artifact will be scanned for hibernate-annotated classes -additionally. Default value is: false. User property is: hibernate.export.scan_testclasses. |
-
skip | - -boolean | - -1.0 | - -Skip execution
-
- If set to true, the execution is skipped. - -A skipped execution is signaled via the maven-property -${hibernate.export.skipped}. - -The execution is skipped automatically, if no modified or newly -added annotated classes are found and the dialect was not -changed. Default value is: ${maven.test.skip}. User property is: hibernate.skip. |
-
target | - -String | - -1.0 | - -Target of execution:
-
-
Default value is: EXPORT. User property is: hibernate.export.target. |
-
testOutputDirectory | - -String | - -1.0.2 | - -Test-Classes-Directory to scan.
-
- This parameter defaults to the maven build-output-directory for -test-classes. - -This parameter is only used, when scanTestClasses -is set to true! User property is: project.build.testOutputDirectory. |
-
type | - -String | - -1.0 | - -Type of execution.
-
-
Default value is: BOTH. User property is: hibernate.export.type. |
-
url | - -String | - -1.0 | - -Database URL. User property is: hibernate.connection.url. |
-
username | - -String | - -1.0 | - -Database username User property is: hibernate.connection.username. |
-
Force execution, even if no modified or newly added annotated -classes where found and the dialect was not changed.
- -skip takes precedence over force.
This parameter defaults to the maven build-output-directory for -classes. Additionally, all dependencies are scanned for annotated -classes.
By default, only dependencies in the scope compile -are scanned for annotated classes. Multiple scopes can be seperated -by white space or commas.
- -If you do not want any dependencies to be scanned for annotated -classes, set this parameter to none.
- -The plugin does not scan for annotated classes in transitive -dependencies. If some of your annotated classes are hidden in a -transitive dependency, you can simply add that dependency -explicitly.
If this parameter is set to true the test-classes -of the artifact will be scanned for hibernate-annotated classes -additionally.
skip:
- -If set to true, the execution is skipped.
- -A skipped execution is signaled via the maven-property -${hibernate.export.skipped}.
- -The execution is skipped automatically, if no modified or newly -added annotated classes are found and the dialect was not -changed.
This parameter defaults to the maven build-output-directory for -test-classes.
- -This parameter is only used, when scanTestClasses -is set to true!
type:
- -url:
- --
-
- -- The hibernate4-maven-plugin computes MD5-sums for all found annotated - classes and stores them together with the generated schema. - If no classes were changed or added and the dialect wasn't changed too, it - automatically skips the configured schema-export, to speed up the development - cycle. -
- -- The plugin signals, that the execution was skipped by setting the maven - property $\{hibernate.export.skipped\} to true. - This may be helpful, because other plugins like - dbunit-plugin - may fail, when the execution is skipped. -
- -- If you need the hibernate4-maven-plugin to <never skip execution automatically>, - you can force it to do so, if you set the parameter force to - true: -
- --<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.1.1</version> - <configuration> - <force>true</force> - </configuration> -</plugin>
- Or you may specify -Dhibernate.export.force=true at the command line, - if you want to force hibernate4-maven-plugin only once. -
- - --
-
Full name:
- -de.juplo:hibernate4-maven-plugin:1.1.1:help
- -Description:
- -Attributes:
- -Name | - -Type | - -Since | - -Description | -
---|---|---|---|
detail | - -boolean | - -- | - -If true, display all settable properties for each
-goal. Default value is: false. User property is: detail. |
-
goal | - -String | - -- | - -The name of the goal for which to show help. If unspecified, all
-goals will be displayed. User property is: goal. |
-
indentSize | - -int | - -- | - -The number of spaces per indentation level, should be positive. Default value is: 2. User property is: indentSize. |
-
lineLength | - -int | - -- | - -The maximum length of a display line, should be positive. Default value is: 80. User property is: lineLength. |
-
goal:
- --
-
- -- The hibernate4-maven-plugin is a plugin for generating a database-schema - from your Hibernate-4-Mappings and create or update your database - accordingly. - Its main usage is to automatically create and populate a test-database - for unit-tests in cooperation with the - dbunit-maven-plugin. -
- -- The plugin was designed with three main goals in mind: -
- -- To achieve the first goal, the convention-over-configuration paradigma - was applied and the plugin was stuffed with usefull logging-messages. - So, if in doubt, just turn on the debugging output with the mvn -X .... -
- -- To achieve the second goal, the precedence in which the configuration - locations are consulted was layouted in a way that makes it possible, to - prevent overwrites of the wrong database by accident. -
- -- Last but not least, in order to not slow down the development cycle, the - hibernate4-maven-plugin only executes the schema-export, if the mapping - or the dialect changes (or if you force it to do so). -
- -- For more information about the inspiration to write this tiny plugin, - read our blog-article about the hibernate4-maven-plugin. -
--
-
- -Configuration for notifying developers/users when a build is unsuccessful, including user information and notification mode.
-Type | -Address | -Configuration |
---|---|---|
kai@juplo.de | -- |
-
-
- Please send your bug-reports, questions or feature-requests directly - to the developer. -
- - --
-
- -Typically the licenses listed for the project are that of the project itself, and not of dependencies.
A business-friendly OSS license
-- Apache License - Version 2.0, January 2004 - http://www.apache.org/licenses/ - - TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION - - 1. Definitions. - - "License" shall mean the terms and conditions for use, reproduction, - and distribution as defined by Sections 1 through 9 of this document. - - "Licensor" shall mean the copyright owner or entity authorized by - the copyright owner that is granting the License. - - "Legal Entity" shall mean the union of the acting entity and all - other entities that control, are controlled by, or are under common - control with that entity. For the purposes of this definition, - "control" means (i) the power, direct or indirect, to cause the - direction or management of such entity, whether by contract or - otherwise, or (ii) ownership of fifty percent (50%) or more of the - outstanding shares, or (iii) beneficial ownership of such entity. - - "You" (or "Your") shall mean an individual or Legal Entity - exercising permissions granted by this License. - - "Source" form shall mean the preferred form for making modifications, - including but not limited to software source code, documentation - source, and configuration files. - - "Object" form shall mean any form resulting from mechanical - transformation or translation of a Source form, including but - not limited to compiled object code, generated documentation, - and conversions to other media types. - - "Work" shall mean the work of authorship, whether in Source or - Object form, made available under the License, as indicated by a - copyright notice that is included in or attached to the work - (an example is provided in the Appendix below). - - "Derivative Works" shall mean any work, whether in Source or Object - form, that is based on (or derived from) the Work and for which the - editorial revisions, annotations, elaborations, or other modifications - represent, as a whole, an original work of authorship. For the purposes - of this License, Derivative Works shall not include works that remain - separable from, or merely link (or bind by name) to the interfaces of, - the Work and Derivative Works thereof. - - "Contribution" shall mean any work of authorship, including - the original version of the Work and any modifications or additions - to that Work or Derivative Works thereof, that is intentionally - submitted to Licensor for inclusion in the Work by the copyright owner - or by an individual or Legal Entity authorized to submit on behalf of - the copyright owner. For the purposes of this definition, "submitted" - means any form of electronic, verbal, or written communication sent - to the Licensor or its representatives, including but not limited to - communication on electronic mailing lists, source code control systems, - and issue tracking systems that are managed by, or on behalf of, the - Licensor for the purpose of discussing and improving the Work, but - excluding communication that is conspicuously marked or otherwise - designated in writing by the copyright owner as "Not a Contribution." - - "Contributor" shall mean Licensor and any individual or Legal Entity - on behalf of whom a Contribution has been received by Licensor and - subsequently incorporated within the Work. - - 2. Grant of Copyright License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - copyright license to reproduce, prepare Derivative Works of, - publicly display, publicly perform, sublicense, and distribute the - Work and such Derivative Works in Source or Object form. - - 3. Grant of Patent License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - (except as stated in this section) patent license to make, have made, - use, offer to sell, sell, import, and otherwise transfer the Work, - where such license applies only to those patent claims licensable - by such Contributor that are necessarily infringed by their - Contribution(s) alone or by combination of their Contribution(s) - with the Work to which such Contribution(s) was submitted. If You - institute patent litigation against any entity (including a - cross-claim or counterclaim in a lawsuit) alleging that the Work - or a Contribution incorporated within the Work constitutes direct - or contributory patent infringement, then any patent licenses - granted to You under this License for that Work shall terminate - as of the date such litigation is filed. - - 4. Redistribution. You may reproduce and distribute copies of the - Work or Derivative Works thereof in any medium, with or without - modifications, and in Source or Object form, provided that You - meet the following conditions: - - (a) You must give any other recipients of the Work or - Derivative Works a copy of this License; and - - (b) You must cause any modified files to carry prominent notices - stating that You changed the files; and - - (c) You must retain, in the Source form of any Derivative Works - that You distribute, all copyright, patent, trademark, and - attribution notices from the Source form of the Work, - excluding those notices that do not pertain to any part of - the Derivative Works; and - - (d) If the Work includes a "NOTICE" text file as part of its - distribution, then any Derivative Works that You distribute must - include a readable copy of the attribution notices contained - within such NOTICE file, excluding those notices that do not - pertain to any part of the Derivative Works, in at least one - of the following places: within a NOTICE text file distributed - as part of the Derivative Works; within the Source form or - documentation, if provided along with the Derivative Works; or, - within a display generated by the Derivative Works, if and - wherever such third-party notices normally appear. The contents - of the NOTICE file are for informational purposes only and - do not modify the License. You may add Your own attribution - notices within Derivative Works that You distribute, alongside - or as an addendum to the NOTICE text from the Work, provided - that such additional attribution notices cannot be construed - as modifying the License. - - You may add Your own copyright statement to Your modifications and - may provide additional or different license terms and conditions - for use, reproduction, or distribution of Your modifications, or - for any such Derivative Works as a whole, provided Your use, - reproduction, and distribution of the Work otherwise complies with - the conditions stated in this License. - - 5. Submission of Contributions. Unless You explicitly state otherwise, - any Contribution intentionally submitted for inclusion in the Work - by You to the Licensor shall be under the terms and conditions of - this License, without any additional terms or conditions. - Notwithstanding the above, nothing herein shall supersede or modify - the terms of any separate license agreement you may have executed - with Licensor regarding such Contributions. - - 6. Trademarks. This License does not grant permission to use the trade - names, trademarks, service marks, or product names of the Licensor, - except as required for reasonable and customary use in describing the - origin of the Work and reproducing the content of the NOTICE file. - - 7. Disclaimer of Warranty. Unless required by applicable law or - agreed to in writing, Licensor provides the Work (and each - Contributor provides its Contributions) on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or - implied, including, without limitation, any warranties or conditions - of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A - PARTICULAR PURPOSE. You are solely responsible for determining the - appropriateness of using or redistributing the Work and assume any - risks associated with Your exercise of permissions under this License. - - 8. Limitation of Liability. In no event and under no legal theory, - whether in tort (including negligence), contract, or otherwise, - unless required by applicable law (such as deliberate and grossly - negligent acts) or agreed to in writing, shall any Contributor be - liable to You for damages, including any direct, indirect, special, - incidental, or consequential damages of any character arising as a - result of this License or out of the use or inability to use the - Work (including but not limited to damages for loss of goodwill, - work stoppage, computer failure or malfunction, or any and all - other commercial damages or losses), even if such Contributor - has been advised of the possibility of such damages. - - 9. Accepting Warranty or Additional Liability. While redistributing - the Work or Derivative Works thereof, You may choose to offer, - and charge a fee for, acceptance of support, warranty, indemnity, - or other liability obligations and/or rights consistent with this - License. However, in accepting such obligations, You may act only - on Your own behalf and on Your sole responsibility, not on behalf - of any other Contributor, and only if You agree to indemnify, - defend, and hold each Contributor harmless for any liability - incurred by, or claims asserted against, such Contributor by reason - of your accepting any such warranty or additional liability. - - END OF TERMS AND CONDITIONS - - APPENDIX: How to apply the Apache License to your work. - - To apply the Apache License to your work, attach the following - boilerplate notice, with the fields enclosed by brackets "[]" - replaced with your own identifying information. (Don't include - the brackets!) The text should be enclosed in the appropriate - comment syntax for the file format. We also recommend that a - file or class name and description of purpose be included on the - same "printed page" as the copyright notice for easier - identification within third-party archives. - - Copyright [yyyy] [name of copyright owner] - - Licensed under the Apache License, Version 2.0 (the "License"); - you may not use this file except in compliance with the License. - You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. -
-
-
- Please send your bug-reports, questions or feature-requests directly - to the developer. -
- - --
-
- -- hibernate4-maven-plugin by default scans dependencies in the scope - compile. You can configure it to scan dependencies in other - scopes as well. But it scans only direct dependencies. Transitive - dependencies are not scanned for annotated classes. If some of your - annotated classes are hidden in a transitive dependency, you can simply - add that dependency explicitly. -
-- The default-configuration uses the EXPORT-target of the SchemaExport-Tool. - If you do not need to create a database with the evaluated schema, you can - use the NONE- or the SCRIPT-target. - This can be achieved with the command-line parameter - -Dhibernate.export.target=SCRIPT or with the following configuration: -
- --<configuration> - <target>SCRIPT</target> -</configuration>
- But even when no database is to be created, hibernate always needs to know - the dialect. Hence, the plugin will fail if this parameter is missing! -
-- One regular problem is the scope of the jdbc-driver-dependency. - It is very unlikely, that this dependency is needed at compile-time. - So a tidy maven-developer would usually scope it for runtime. -
- -- But this will break the execution of the hibernate4-maven-plugin. - Since it will not be able to see the needed dependency, it will fail with - an error-message like: -
- --[INFO] Gathered hibernate-configuration (turn on debugging for details): -[INFO] hibernate.connection.username = sa -[INFO] hibernate.connection.password = -[INFO] hibernate.dialect = org.hibernate.dialect.HSQLDialect -[INFO] hibernate.connection.url = jdbc:hsqldb:/home/kai/mmf/target/mmf;shutdown=true -[INFO] hibernate.connection.driver_class = org.hsqldb.jdbcDriver -[ERROR] Dependency for driver-class org.hsqldb.jdbcDriver is missing! -[INFO] ------------------------------------------------------------------------ -[ERROR] BUILD ERROR -[INFO] ------------------------------------------------------------------------ -[INFO] org.hsqldb.jdbcDriver -[INFO] ------------------------------------------------------------------------ -[INFO] For more information, run Maven with the -e switch -[INFO] ------------------------------------------------------------------------ -[INFO] Total time: 2 seconds -[INFO] Finished at: Thu Nov 29 11:31:14 CET 2012 -[INFO] Final Memory: 32M/342M -[INFO] ------------------------------------------------------------------------
- A quick workaround for this error would be, to delete the runtime-constraint - for the jdbc-driver-dependency. -
- -- A much cleaner way is, to (additionally) ad the dependency, to the - plugin-definition: -
- --<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.1.1</version> - <executions> - <execution> - <goals> - <goal>export</goal> - </goals> - </execution> - </executions> - <dependencies> - <dependency> - <groupId>org.hsqldb</groupId> - <artifactId>hsqldb</artifactId> - <version>2.2.8</version> - </dependency> - </dependencies> -</plugin>
- This is also the best way, if you use a different jdbc-driver for - testing, than in production. - Because otherwise, this dependency will unnecessarily bloat the - runtime-dependencies of your project. -
-- If hibernate4-maven-plugin skips its excecution, this may lead to errors in - other plugins. - For example, when importing sample-data in the automatically created database - with the help of the dbunit-plugin, - the CLEAN_INSERT-operation may fail because of foreign-key-constraints, - if the database was not recreated, because the hibernate4-maven-plugin has - skipped its excecution. -
- -- A quick fix to this problem is, to force - hibernate4-maven-plugin to export the schema every time it is running. - But to recreate the database on every testrun may noticeable slow down your - development cycle, if you have to wait for slow IO. -
- -- To circumvent this problem, hibernate4-maven-plugin signals a skipped - excecution by setting the maven property $\{hibernate.export.skipped\} to - true. - You can configure other plugins to react on this signal. - For example, the dbunit-plugin can be configured to skip its excecution, if - hibernate4-maven-plugin was skipped like this: -
- --<plugin> - <groupId>org.codehaus.mojo</groupId> - <artifactId>dbunit-maven-plugin</artifactId> - <configuration> - <skip>${hibernate.export.skipped}</skip> - </configuration> -</plugin>
- If one manually drops the database or removes the hsqldb-files, it will not - be recreated by the hibernate4-maven-plugin, because it cannot detect, that - the database needs to be recreated. - This happens, because the plugin will not recreate the database if neither - the configuration nor the annotated classes have changed, because an - unnecessary drop-create-cycle might take a long time. The plugin will - report that like this: -
- --[INFO] No modified annotated classes found and dialect unchanged. -[INFO] Skipping schema generation!
- If one always uses mvn clean for cleanup, this will not happen. - Otherwise the recreation must be forced: -
- --mvn hibernate4:export -Dhibernate.export.force=true
- The hibernate4-maven-plugin automatically skips its execution, when - maven.test.skip is set to true. If you need it to be always - executed, you can configure that explicitly like this: -
- --<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - ... - <configuration> - <skip>false</skip> - </configuration> -</plugin>
- Background-information for this design-decission can be found on the extra - page To skip or not to skip: that is the question... -
-- If you do not want your dependencies to be scanned for hibernate annotations, - you can pass -Dhibernate.export.scan_dependencies=none to maven - or set scanDependencies to none in the configuration - of the plugin like this: -
- --<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - ... - <configuration> - <scanDependencies>none</scanDependencies> - </configuration> -</plugin>
- If you are working under Windows and get the error-message - No annotated classes found in directory C:\projects\X Y Z\path-to-project\target\classes, - but you are really sure, that there are annotated classes in that - directory, you are expiriencing a bug, in the scannotation-library, that - was closed in version 1.1.0 of the hibernate-maven-plugin. -
- -- - You should consider to upgrade to that version of the plugin. - -
--
-
- -Goals available for this plugin:
-Goal | -Description |
---|---|
hibernate4:export | -Goal which extracts the hibernate-mapping-configuration and exports -an according SQL-database-schema. |
hibernate4:help | -Display help information on hibernate4-maven-plugin. -Call mvn hibernate4:help -Ddetail=true
--Dgoal=<goal-name> to display parameter details. |
The following specifies the minimum requirements to run this Maven plugin:
-Maven | -2.0.6 |
JDK | -1.6 |
Memory | -No minimum requirement. |
Disk Space | -No minimum requirement. |
You should specify the version in your project's plugin configuration:
-<project> - ... - <build> - <!-- To define the plugin version in your parent POM --> - <pluginManagement> - <plugins> - <plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.1.1</version> - </plugin> - ... - </plugins> - </pluginManagement> - <!-- To use the plugin goals in your POM or parent POM --> - <plugins> - <plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - <version>1.1.1</version> - </plugin> - ... - </plugins> - </build> - ... -</project> -
For more information, see "Guide to Configuring Plug-ins"
-
-
- -GroupId | -ArtifactId | -Version |
---|---|---|
org.apache.maven.plugins | -maven-antrun-plugin | -1.3 |
org.apache.maven.plugins | -maven-assembly-plugin | -2.2-beta-5 |
org.apache.maven.plugins | -maven-dependency-plugin | -2.1 |
org.apache.maven.plugins | -maven-release-plugin | -2.1 |
org.apache.maven.plugins | -maven-site-plugin | -3.4 |
-
-
- -GroupId | -ArtifactId | -Version |
---|---|---|
org.apache.maven.plugins | -maven-clean-plugin | -2.5 |
org.apache.maven.plugins | -maven-compiler-plugin | -3.3 |
org.apache.maven.plugins | -maven-dependency-plugin | -2.10 |
org.apache.maven.plugins | -maven-deploy-plugin | -2.7 |
org.apache.maven.plugins | -maven-enforcer-plugin | -1.2 |
org.apache.maven.plugins | -maven-install-plugin | -2.3 |
org.apache.maven.plugins | -maven-invoker-plugin | -1.10 |
org.apache.maven.plugins | -maven-jar-plugin | -2.2 |
org.apache.maven.plugins | -maven-javadoc-plugin | -2.7 |
org.apache.maven.plugins | -maven-plugin-plugin | -3.4 |
org.apache.maven.plugins | -maven-resources-plugin | -2.7 |
org.apache.maven.plugins | -maven-scm-plugin | -1.9.4 |
org.apache.maven.plugins | -maven-site-plugin | -3.4 |
org.apache.maven.plugins | -maven-source-plugin | -2.1.2 |
org.apache.maven.plugins | -maven-surefire-plugin | -2.10 |
GroupId | -ArtifactId | -Version |
---|---|---|
org.apache.maven.plugins | -maven-changes-plugin | -2.11 |
org.apache.maven.plugins | -maven-javadoc-plugin | -2.7 |
org.apache.maven.plugins | -maven-jxr-plugin | -2.5 |
org.apache.maven.plugins | -maven-plugin-plugin | -3.4 |
org.apache.maven.plugins | -maven-pmd-plugin | -3.4 |
-
-
- -The following document contains the results of PMD 5.2.3.
Violation | -Line |
---|---|
Unnecessary use of fully qualified name 'java.security.MessageDigest.getInstance' due to existing import 'java.security.MessageDigest' | -527 |
Unnecessary use of fully qualified name 'java.security.MessageDigest.getInstance' due to existing import 'java.security.MessageDigest' | -876 |
Avoid using a branching statement as the last in a loop. | -1153 |
Unnecessary use of fully qualified name 'java.sql.Driver' due to existing import 'java.sql.Driver' | -1238 |
Unnecessary use of fully qualified name 'java.util.Properties' due to existing import 'java.util.Properties' | -1252 |
-
-
- -This document provides an overview of the various documents and links that are part of this project's general information. All of this content is automatically generated by Maven on behalf of the project.
-Document | -Description |
---|---|
CI Management | -This is a link to the definitions of all continuous integration processes that builds and tests code on a frequent, regular basis. |
Dependencies | -This document lists the project's dependencies and provides information on each dependency. |
Dependency Information | -This document describes how to to include this project as a dependency using various dependency management tools. |
Distribution Management | -This document provides informations on the distribution management of this project. |
About | -Plugin for generating a database-schema from Hibernate-4-Mapping-Annotations |
Licenses | -This document lists the project license(s). |
Plugin Management | -This document lists the plugins that are defined through pluginManagement. |
Plugins | -This document lists the build plugins and the report plugins used by this project. |
Team | -This document provides information on the members of this project. These are the individuals who have contributed to the project in one form or another. |
Source Code Management | -This document lists ways to access the online source repository. |
Summary | -This document lists other related information of this project |
-
-
- -This document provides an overview of the various reports that are automatically generated by Maven . Each report is briefly described below.
-Document | -Description |
---|---|
Test JavaDocs | -Test JavaDoc API documentation. |
JavaDocs | -JavaDoc API documentation. |
Source Xref | -HTML based, cross-reference version of Java source code. |
Test Source Xref | -HTML based, cross-reference version of Java test source code. |
PMD | -Verification of coding rules. |
Plugin Documentation | -This report provides goals and parameters documentation of a plugin. |
-
-
- -Field | -Value |
---|---|
Name | -Hibernate 4 Maven Plugin |
Description | -Plugin for generating a database-schema from Hibernate-4-Mapping-Annotations |
Homepage | -http://juplo.de/hibernate4-maven-plugin |
-
-
- -- In most use-cases, the hibernate4-maven-plugin is used to create a - test-database automatically. In this use-cases, it is very likely, that it - will result in mistakes/errors, if the goal is executed, when the tests - are skipped. - For example, one might manually overwrite the database-url with the url of - the production-database, in order to run other tests, like starting a - local webserver with the - jetty-maven-plugin. - If the export-goal would be executed in such a scenario, it might erase the - hole production-database, which is not very desireable. -
- -- Because of this, the configuration-parameter skip defaults to the value - of the proptery maven.test.skip. This way, the execution of the - hibernate4-maven-plugin is skipped automatically, when the tests are - skipped. Think of it as a build-in security-belt. -
- -- If you do not like that, because you need the plugin to always execute the - export-goal, even if the tests are skipped you can configure that explicitly, - by setting the configuration-parameter skip to false: -
- --<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - ... - <configuration> - <skip>false</skip> - </configuration> -</plugin>
- Or, if you want the export-goal to be executed by default and to be skipped - if you say so, you can bind the value of the configuration-parameter - skip to a custom property. For example: -
- --<plugin> - <groupId>de.juplo</groupId> - <artifactId>hibernate4-maven-plugin</artifactId> - ... - <configuration> - <skip>${foo.bar}</skip> - </configuration> -</plugin>
- This way, the export-goal would be skipped, if you set the property - foo.bar to true. For example, if you specify -Dfoo.bar=true - on the command-line. -
- - --
-
- -This project uses Git to manage its source code. Instructions on Git use can be found at http://git-scm.com/documentation.
The source can be checked out anonymously from Git with this command (See http://git-scm.com/docs/git-clone):
-$ git clone http://juplo.de/git/hibernate4-maven-plugin
Only project developers can access the Git tree via this method (See http://git-scm.com/docs/git-clone).
-$ git clone ssh://juplo.de/var/lib/git/juplo/hibernate4-maven-plugin
-
-
- -A successful project requires many people to play many roles. Some members write code or documentation, while others are valuable as testers, submitting patches and suggestions.
-The project team is comprised of Members and Contributors. Members have direct access to the source of a project and actively evolve the code-base. Contributors improve the project through submission of patches and suggestions to the Members. The number of Contributors to the project is unbounded. Get involved today. All contributions to the project are greatly appreciated.
-The following is a list of developers with commit privileges that have directly contributed to the project in one way or another.
-Image | -Id | -Name | -|
---|---|---|---|
- | kai | -Kai Moritz | -kai@juplo.de |
The following additional people have contributed to this project through the way of suggestions, patches or documentation.
-Image | -Name | -|
---|---|---|
- | Adriano Machado | -adriano.m.machado@hotmail.com |
- | Lorenzo Nicora | -lorenzo.nicora@nicus.it |
- | Eduard Szente | -eduard.szente@gmail.com |
- | Stephen Johnson | -stejohns@redhat.com |
- | Victor Tatai | -vtatai@gmail.com |
- | Erik-Berndt Scheper | -erik.berndt.scheper@gmail.com |
- | Guido Wimmel | -Wimmel.Guido@swm.de |
- | Joel Johnson | -mrjoel@lixil.net |
- | Paul K. Moore | -paulkmoore@gmail.com |
- | Mark Robinson | -mark@mrobinson.ca |
- | Claus Graf | -clausgraf@gmail.com |
- | Joachim Van der Auwera | -joachim@progs.be |
- | Andreas Kuhtz | -andreas.kuhtz@gmail.com |
- | Casey Link | -casey@outskirtslabs.com |
-
Copyright © 2016. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.1/testapidocs/de/juplo/test/FileComparator.html b/dist/hibernate4-maven-plugin-1.1.1/testapidocs/de/juplo/test/FileComparator.html deleted file mode 100644 index cbc8abf3..00000000 --- a/dist/hibernate4-maven-plugin-1.1.1/testapidocs/de/juplo/test/FileComparator.html +++ /dev/null @@ -1,280 +0,0 @@ - - - - - - -public class FileComparator -extends Object-
Constructor and Description | -
---|
FileComparator(File basedir) |
-
Modifier and Type | -Method and Description | -
---|---|
boolean |
-isEqual(String expectedFile,
- String foundFile) |
-
public boolean isEqual(String expectedFile, - String foundFile) - throws FileNotFoundException, - IOException-
FileNotFoundException
IOException
Copyright © 2016. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.1/testapidocs/de/juplo/test/class-use/FileComparator.html b/dist/hibernate4-maven-plugin-1.1.1/testapidocs/de/juplo/test/class-use/FileComparator.html deleted file mode 100644 index bcb60598..00000000 --- a/dist/hibernate4-maven-plugin-1.1.1/testapidocs/de/juplo/test/class-use/FileComparator.html +++ /dev/null @@ -1,124 +0,0 @@ - - - - - - -Copyright © 2016. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.1/testapidocs/de/juplo/test/package-frame.html b/dist/hibernate4-maven-plugin-1.1.1/testapidocs/de/juplo/test/package-frame.html deleted file mode 100644 index 90fd3154..00000000 --- a/dist/hibernate4-maven-plugin-1.1.1/testapidocs/de/juplo/test/package-frame.html +++ /dev/null @@ -1,21 +0,0 @@ - - - - - - -Class | -Description | -
---|---|
FileComparator | -- |
Copyright © 2016. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.1/testapidocs/de/juplo/test/package-tree.html b/dist/hibernate4-maven-plugin-1.1.1/testapidocs/de/juplo/test/package-tree.html deleted file mode 100644 index 5f4a8eec..00000000 --- a/dist/hibernate4-maven-plugin-1.1.1/testapidocs/de/juplo/test/package-tree.html +++ /dev/null @@ -1,133 +0,0 @@ - - - - - - -Copyright © 2016. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.1/testapidocs/de/juplo/test/package-use.html b/dist/hibernate4-maven-plugin-1.1.1/testapidocs/de/juplo/test/package-use.html deleted file mode 100644 index 2a7430e2..00000000 --- a/dist/hibernate4-maven-plugin-1.1.1/testapidocs/de/juplo/test/package-use.html +++ /dev/null @@ -1,124 +0,0 @@ - - - - - - -Copyright © 2016. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.1/testapidocs/deprecated-list.html b/dist/hibernate4-maven-plugin-1.1.1/testapidocs/deprecated-list.html deleted file mode 100644 index ce76baa4..00000000 --- a/dist/hibernate4-maven-plugin-1.1.1/testapidocs/deprecated-list.html +++ /dev/null @@ -1,124 +0,0 @@ - - - - - - -Copyright © 2016. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.1/testapidocs/help-doc.html b/dist/hibernate4-maven-plugin-1.1.1/testapidocs/help-doc.html deleted file mode 100644 index f5c9ee07..00000000 --- a/dist/hibernate4-maven-plugin-1.1.1/testapidocs/help-doc.html +++ /dev/null @@ -1,225 +0,0 @@ - - - - - - -Each package has a page that contains a list of its classes and interfaces, with a summary for each. This page can contain six categories:
-Each class, interface, nested class and nested interface has its own separate page. Each of these pages has three sections consisting of a class/interface description, summary tables, and detailed member descriptions:
-Each summary entry contains the first sentence from the detailed description for that item. The summary entries are alphabetical, while the detailed descriptions are in the order they appear in the source code. This preserves the logical groupings established by the programmer.
-Each annotation type has its own separate page with the following sections:
-Each enum has its own separate page with the following sections:
-Each documented package, class and interface has its own Use page. This page describes what packages, classes, methods, constructors and fields use any part of the given class or package. Given a class or interface A, its Use page includes subclasses of A, fields declared as A, methods that return A, and methods and constructors with parameters of type A. You can access this page by first going to the package, class or interface, then clicking on the "Use" link in the navigation bar.
-There is a Class Hierarchy page for all packages, plus a hierarchy for each package. Each hierarchy page contains a list of classes and a list of interfaces. The classes are organized by inheritance structure starting with java.lang.Object
. The interfaces do not inherit from java.lang.Object
.
The Deprecated API page lists all of the API that have been deprecated. A deprecated API is not recommended for use, generally due to improvements, and a replacement API is usually given. Deprecated APIs may be removed in future implementations.
-The Index contains an alphabetic list of all classes, interfaces, constructors, methods, and fields.
-These links take you to the next or previous class, interface, package, or related page.
-These links show and hide the HTML frames. All pages are available with or without frames.
-The All Classes link shows all classes and interfaces except non-static nested types.
-Each serializable or externalizable class has a description of its serialization fields and methods. This information is of interest to re-implementors, not to developers using the API. While there is no link in the navigation bar, you can get to this information by going to any serialized class and clicking "Serialized Form" in the "See also" section of the class description.
-The Constant Field Values page lists the static final fields and their values.
-Copyright © 2016. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.1/testapidocs/index-all.html b/dist/hibernate4-maven-plugin-1.1.1/testapidocs/index-all.html deleted file mode 100644 index b5c6085f..00000000 --- a/dist/hibernate4-maven-plugin-1.1.1/testapidocs/index-all.html +++ /dev/null @@ -1,147 +0,0 @@ - - - - - - -Copyright © 2016. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.1/testapidocs/index.html b/dist/hibernate4-maven-plugin-1.1.1/testapidocs/index.html deleted file mode 100644 index 240c2677..00000000 --- a/dist/hibernate4-maven-plugin-1.1.1/testapidocs/index.html +++ /dev/null @@ -1,73 +0,0 @@ - - - - - - -This document is designed to be viewed using the frames feature. If you see this message, you are using a non-frame-capable web client. Link to Non-frame version.
-Copyright © 2016. All Rights Reserved.
- - diff --git a/dist/hibernate4-maven-plugin-1.1.1/testapidocs/package-list b/dist/hibernate4-maven-plugin-1.1.1/testapidocs/package-list deleted file mode 100644 index 4774195e..00000000 --- a/dist/hibernate4-maven-plugin-1.1.1/testapidocs/package-list +++ /dev/null @@ -1 +0,0 @@ -de.juplo.test diff --git a/dist/hibernate4-maven-plugin-1.1.1/testapidocs/packages b/dist/hibernate4-maven-plugin-1.1.1/testapidocs/packages deleted file mode 100644 index 8fbea680..00000000 --- a/dist/hibernate4-maven-plugin-1.1.1/testapidocs/packages +++ /dev/null @@ -1 +0,0 @@ -de.juplo.test \ No newline at end of file diff --git a/dist/hibernate4-maven-plugin-1.1.1/testapidocs/script.js b/dist/hibernate4-maven-plugin-1.1.1/testapidocs/script.js deleted file mode 100644 index b3463569..00000000 --- a/dist/hibernate4-maven-plugin-1.1.1/testapidocs/script.js +++ /dev/null @@ -1,30 +0,0 @@ -function show(type) -{ - count = 0; - for (var key in methods) { - var row = document.getElementById(key); - if ((methods[key] & type) != 0) { - row.style.display = ''; - row.className = (count++ % 2) ? rowColor : altColor; - } - else - row.style.display = 'none'; - } - updateTabs(type); -} - -function updateTabs(type) -{ - for (var value in tabs) { - var sNode = document.getElementById(tabs[value][0]); - var spanNode = sNode.firstChild; - if (value == type) { - sNode.className = activeTableTab; - spanNode.innerHTML = tabs[value][1]; - } - else { - sNode.className = tableTab; - spanNode.innerHTML = "" + tabs[value][1] + ""; - } - } -} diff --git a/dist/hibernate4-maven-plugin-1.1.1/testapidocs/stylesheet.css b/dist/hibernate4-maven-plugin-1.1.1/testapidocs/stylesheet.css deleted file mode 100644 index 98055b22..00000000 --- a/dist/hibernate4-maven-plugin-1.1.1/testapidocs/stylesheet.css +++ /dev/null @@ -1,574 +0,0 @@ -/* Javadoc style sheet */ -/* -Overall document style -*/ - -@import url('resources/fonts/dejavu.css'); - -body { - background-color:#ffffff; - color:#353833; - font-family:'DejaVu Sans', Arial, Helvetica, sans-serif; - font-size:14px; - margin:0; -} -a:link, a:visited { - text-decoration:none; - color:#4A6782; -} -a:hover, a:focus { - text-decoration:none; - color:#bb7a2a; -} -a:active { - text-decoration:none; - color:#4A6782; -} -a[name] { - color:#353833; -} -a[name]:hover { - text-decoration:none; - color:#353833; -} -pre { - font-family:'DejaVu Sans Mono', monospace; - font-size:14px; -} -h1 { - font-size:20px; -} -h2 { - font-size:18px; -} -h3 { - font-size:16px; - font-style:italic; -} -h4 { - font-size:13px; -} -h5 { - font-size:12px; -} -h6 { - font-size:11px; -} -ul { - list-style-type:disc; -} -code, tt { - font-family:'DejaVu Sans Mono', monospace; - font-size:14px; - padding-top:4px; - margin-top:8px; - line-height:1.4em; -} -dt code { - font-family:'DejaVu Sans Mono', monospace; - font-size:14px; - padding-top:4px; -} -table tr td dt code { - font-family:'DejaVu Sans Mono', monospace; - font-size:14px; - vertical-align:top; - padding-top:4px; -} -sup { - font-size:8px; -} -/* -Document title and Copyright styles -*/ -.clear { - clear:both; - height:0px; - overflow:hidden; -} -.aboutLanguage { - float:right; - padding:0px 21px; - font-size:11px; - z-index:200; - margin-top:-9px; -} -.legalCopy { - margin-left:.5em; -} -.bar a, .bar a:link, .bar a:visited, .bar a:active { - color:#FFFFFF; - text-decoration:none; -} -.bar a:hover, .bar a:focus { - color:#bb7a2a; -} -.tab { - background-color:#0066FF; - color:#ffffff; - padding:8px; - width:5em; - font-weight:bold; -} -/* -Navigation bar styles -*/ -.bar { - background-color:#4D7A97; - color:#FFFFFF; - padding:.8em .5em .4em .8em; - height:auto;/*height:1.8em;*/ - font-size:11px; - margin:0; -} -.topNav { - background-color:#4D7A97; - color:#FFFFFF; - float:left; - padding:0; - width:100%; - clear:right; - height:2.8em; - padding-top:10px; - overflow:hidden; - font-size:12px; -} -.bottomNav { - margin-top:10px; - background-color:#4D7A97; - color:#FFFFFF; - float:left; - padding:0; - width:100%; - clear:right; - height:2.8em; - padding-top:10px; - overflow:hidden; - font-size:12px; -} -.subNav { - background-color:#dee3e9; - float:left; - width:100%; - overflow:hidden; - font-size:12px; -} -.subNav div { - clear:left; - float:left; - padding:0 0 5px 6px; - text-transform:uppercase; -} -ul.navList, ul.subNavList { - float:left; - margin:0 25px 0 0; - padding:0; -} -ul.navList li{ - list-style:none; - float:left; - padding: 5px 6px; - text-transform:uppercase; -} -ul.subNavList li{ - list-style:none; - float:left; -} -.topNav a:link, .topNav a:active, .topNav a:visited, .bottomNav a:link, .bottomNav a:active, .bottomNav a:visited { - color:#FFFFFF; - text-decoration:none; - text-transform:uppercase; -} -.topNav a:hover, .bottomNav a:hover { - text-decoration:none; - color:#bb7a2a; - text-transform:uppercase; -} -.navBarCell1Rev { - background-color:#F8981D; - color:#253441; - margin: auto 5px; -} -.skipNav { - position:absolute; - top:auto; - left:-9999px; - overflow:hidden; -} -/* -Page header and footer styles -*/ -.header, .footer { - clear:both; - margin:0 20px; - padding:5px 0 0 0; -} -.indexHeader { - margin:10px; - position:relative; -} -.indexHeader span{ - margin-right:15px; -} -.indexHeader h1 { - font-size:13px; -} -.title { - color:#2c4557; - margin:10px 0; -} -.subTitle { - margin:5px 0 0 0; -} -.header ul { - margin:0 0 15px 0; - padding:0; -} -.footer ul { - margin:20px 0 5px 0; -} -.header ul li, .footer ul li { - list-style:none; - font-size:13px; -} -/* -Heading styles -*/ -div.details ul.blockList ul.blockList ul.blockList li.blockList h4, div.details ul.blockList ul.blockList ul.blockListLast li.blockList h4 { - background-color:#dee3e9; - border:1px solid #d0d9e0; - margin:0 0 6px -8px; - padding:7px 5px; -} -ul.blockList ul.blockList ul.blockList li.blockList h3 { - background-color:#dee3e9; - border:1px solid #d0d9e0; - margin:0 0 6px -8px; - padding:7px 5px; -} -ul.blockList ul.blockList li.blockList h3 { - padding:0; - margin:15px 0; -} -ul.blockList li.blockList h2 { - padding:0px 0 20px 0; -} -/* -Page layout container styles -*/ -.contentContainer, .sourceContainer, .classUseContainer, .serializedFormContainer, .constantValuesContainer { - clear:both; - padding:10px 20px; - position:relative; -} -.indexContainer { - margin:10px; - position:relative; - font-size:12px; -} -.indexContainer h2 { - font-size:13px; - padding:0 0 3px 0; -} -.indexContainer ul { - margin:0; - padding:0; -} -.indexContainer ul li { - list-style:none; - padding-top:2px; -} -.contentContainer .description dl dt, .contentContainer .details dl dt, .serializedFormContainer dl dt { - font-size:12px; - font-weight:bold; - margin:10px 0 0 0; - color:#4E4E4E; -} -.contentContainer .description dl dd, .contentContainer .details dl dd, .serializedFormContainer dl dd { - margin:5px 0 10px 0px; - font-size:14px; - font-family:'DejaVu Sans Mono',monospace; -} -.serializedFormContainer dl.nameValue dt { - margin-left:1px; - font-size:1.1em; - display:inline; - font-weight:bold; -} -.serializedFormContainer dl.nameValue dd { - margin:0 0 0 1px; - font-size:1.1em; - display:inline; -} -/* -List styles -*/ -ul.horizontal li { - display:inline; - font-size:0.9em; -} -ul.inheritance { - margin:0; - padding:0; -} -ul.inheritance li { - display:inline; - list-style:none; -} -ul.inheritance li ul.inheritance { - margin-left:15px; - padding-left:15px; - padding-top:1px; -} -ul.blockList, ul.blockListLast { - margin:10px 0 10px 0; - padding:0; -} -ul.blockList li.blockList, ul.blockListLast li.blockList { - list-style:none; - margin-bottom:15px; - line-height:1.4; -} -ul.blockList ul.blockList li.blockList, ul.blockList ul.blockListLast li.blockList { - padding:0px 20px 5px 10px; - border:1px solid #ededed; - background-color:#f8f8f8; -} -ul.blockList ul.blockList ul.blockList li.blockList, ul.blockList ul.blockList ul.blockListLast li.blockList { - padding:0 0 5px 8px; - background-color:#ffffff; - border:none; -} -ul.blockList ul.blockList ul.blockList ul.blockList li.blockList { - margin-left:0; - padding-left:0; - padding-bottom:15px; - border:none; -} -ul.blockList ul.blockList ul.blockList ul.blockList li.blockListLast { - list-style:none; - border-bottom:none; - padding-bottom:0; -} -table tr td dl, table tr td dl dt, table tr td dl dd { - margin-top:0; - margin-bottom:1px; -} -/* -Table styles -*/ -.overviewSummary, .memberSummary, .typeSummary, .useSummary, .constantsSummary, .deprecatedSummary { - width:100%; - border-left:1px solid #EEE; - border-right:1px solid #EEE; - border-bottom:1px solid #EEE; -} -.overviewSummary, .memberSummary { - padding:0px; -} -.overviewSummary caption, .memberSummary caption, .typeSummary caption, -.useSummary caption, .constantsSummary caption, .deprecatedSummary caption { - position:relative; - text-align:left; - background-repeat:no-repeat; - color:#253441; - font-weight:bold; - clear:none; - overflow:hidden; - padding:0px; - padding-top:10px; - padding-left:1px; - margin:0px; - white-space:pre; -} -.overviewSummary caption a:link, .memberSummary caption a:link, .typeSummary caption a:link, -.useSummary caption a:link, .constantsSummary caption a:link, .deprecatedSummary caption a:link, -.overviewSummary caption a:hover, .memberSummary caption a:hover, .typeSummary caption a:hover, -.useSummary caption a:hover, .constantsSummary caption a:hover, .deprecatedSummary caption a:hover, -.overviewSummary caption a:active, .memberSummary caption a:active, .typeSummary caption a:active, -.useSummary caption a:active, .constantsSummary caption a:active, .deprecatedSummary caption a:active, -.overviewSummary caption a:visited, .memberSummary caption a:visited, .typeSummary caption a:visited, -.useSummary caption a:visited, .constantsSummary caption a:visited, .deprecatedSummary caption a:visited { - color:#FFFFFF; -} -.overviewSummary caption span, .memberSummary caption span, .typeSummary caption span, -.useSummary caption span, .constantsSummary caption span, .deprecatedSummary caption span { - white-space:nowrap; - padding-top:5px; - padding-left:12px; - padding-right:12px; - padding-bottom:7px; - display:inline-block; - float:left; - background-color:#F8981D; - border: none; - height:16px; -} -.memberSummary caption span.activeTableTab span { - white-space:nowrap; - padding-top:5px; - padding-left:12px; - padding-right:12px; - margin-right:3px; - display:inline-block; - float:left; - background-color:#F8981D; - height:16px; -} -.memberSummary caption span.tableTab span { - white-space:nowrap; - padding-top:5px; - padding-left:12px; - padding-right:12px; - margin-right:3px; - display:inline-block; - float:left; - background-color:#4D7A97; - height:16px; -} -.memberSummary caption span.tableTab, .memberSummary caption span.activeTableTab { - padding-top:0px; - padding-left:0px; - padding-right:0px; - background-image:none; - float:none; - display:inline; -} -.overviewSummary .tabEnd, .memberSummary .tabEnd, .typeSummary .tabEnd, -.useSummary .tabEnd, .constantsSummary .tabEnd, .deprecatedSummary .tabEnd { - display:none; - width:5px; - position:relative; - float:left; - background-color:#F8981D; -} -.memberSummary .activeTableTab .tabEnd { - display:none; - width:5px; - margin-right:3px; - position:relative; - float:left; - background-color:#F8981D; -} -.memberSummary .tableTab .tabEnd { - display:none; - width:5px; - margin-right:3px; - position:relative; - background-color:#4D7A97; - float:left; - -} -.overviewSummary td, .memberSummary td, .typeSummary td, -.useSummary td, .constantsSummary td, .deprecatedSummary td { - text-align:left; - padding:0px 0px 12px 10px; -} -th.colOne, th.colFirst, th.colLast, .useSummary th, .constantsSummary th, -td.colOne, td.colFirst, td.colLast, .useSummary td, .constantsSummary td{ - vertical-align:top; - padding-right:0px; - padding-top:8px; - padding-bottom:3px; -} -th.colFirst, th.colLast, th.colOne, .constantsSummary th { - background:#dee3e9; - text-align:left; - padding:8px 3px 3px 7px; -} -td.colFirst, th.colFirst { - white-space:nowrap; - font-size:13px; -} -td.colLast, th.colLast { - font-size:13px; -} -td.colOne, th.colOne { - font-size:13px; -} -.overviewSummary td.colFirst, .overviewSummary th.colFirst, -.useSummary td.colFirst, .useSummary th.colFirst, -.overviewSummary td.colOne, .overviewSummary th.colOne, -.memberSummary td.colFirst, .memberSummary th.colFirst, -.memberSummary td.colOne, .memberSummary th.colOne, -.typeSummary td.colFirst{ - width:25%; - vertical-align:top; -} -td.colOne a:link, td.colOne a:active, td.colOne a:visited, td.colOne a:hover, td.colFirst a:link, td.colFirst a:active, td.colFirst a:visited, td.colFirst a:hover, td.colLast a:link, td.colLast a:active, td.colLast a:visited, td.colLast a:hover, .constantValuesContainer td a:link, .constantValuesContainer td a:active, .constantValuesContainer td a:visited, .constantValuesContainer td a:hover { - font-weight:bold; -} -.tableSubHeadingColor { - background-color:#EEEEFF; -} -.altColor { - background-color:#FFFFFF; -} -.rowColor { - background-color:#EEEEEF; -} -/* -Content styles -*/ -.description pre { - margin-top:0; -} -.deprecatedContent { - margin:0; - padding:10px 0; -} -.docSummary { - padding:0; -} - -ul.blockList ul.blockList ul.blockList li.blockList h3 { - font-style:normal; -} - -div.block { - font-size:14px; - font-family:'DejaVu Serif', Georgia, "Times New Roman", Times, serif; -} - -td.colLast div { - padding-top:0px; -} - - -td.colLast a { - padding-bottom:3px; -} -/* -Formatting effect styles -*/ -.sourceLineNo { - color:green; - padding:0 30px 0 0; -} -h1.hidden { - visibility:hidden; - overflow:hidden; - font-size:10px; -} -.block { - display:block; - margin:3px 10px 2px 0px; - color:#474747; -} -.deprecatedLabel, .descfrmTypeLabel, .memberNameLabel, .memberNameLink, -.overrideSpecifyLabel, .packageHierarchyLabel, .paramLabel, .returnLabel, -.seeLabel, .simpleTagLabel, .throwsLabel, .typeNameLabel, .typeNameLink { - font-weight:bold; -} -.deprecationComment, .emphasizedPhrase, .interfaceName { - font-style:italic; -} - -div.block div.block span.deprecationComment, div.block div.block span.emphasizedPhrase, -div.block div.block span.interfaceName { - font-style:normal; -} - -div.contentContainer ul.blockList li.blockList h2{ - padding-bottom:0px; -} diff --git a/dist/hibernate4-maven-plugin-1.1.1/xref-test/allclasses-frame.html b/dist/hibernate4-maven-plugin-1.1.1/xref-test/allclasses-frame.html deleted file mode 100644 index 8253aebb..00000000 --- a/dist/hibernate4-maven-plugin-1.1.1/xref-test/allclasses-frame.html +++ /dev/null @@ -1,20 +0,0 @@ - - - - - --1 package de.juplo.test; -2 -3 import java.io.BufferedReader; -4 import java.io.File; -5 import java.io.FileNotFoundException; -6 import java.io.FileReader; -7 import java.io.IOException; -8 -9 -10 public class FileComparator -11 { -12 private final File basedir; -13 private BufferedReader expectedReader; -14 private BufferedReader foundReader; -15 -16 public FileComparator(File basedir) -17 { -18 this.basedir = basedir; -19 } -20 -21 public boolean isEqual(final String expectedFile, final String foundFile) -22 throws -23 FileNotFoundException, -24 IOException -25 { -26 File file; -27 String expected, found; -28 -29 file = new File(basedir, expectedFile); -30 expectedReader = new BufferedReader(new FileReader(file)); -31 -32 file = new File(basedir, foundFile); -33 foundReader = new BufferedReader(new FileReader(file)); -34 -35 -36 while ((expected = expectedReader.readLine()) != null) -37 { -38 found = foundReader.readLine(); -39 if (!expected.equals(found)) -40 { -41 System.err.println("Mismatch!"); -42 System.err.println("Expected: " + expected); -43 System.err.println("Found: " + found); -44 return false; -45 } -46 } -47 -48 if ((found = foundReader.readLine()) != null) -49 { -50 System.err.println("Found more content than expected!"); -51 System.err.println("Starting with: " + found); -52 return false; -53 } -54 -55 return true; -56 } -57 } --
Class Summary | -
---|
- FileComparator - | -
- You don't have frames. Go here -
- -Packages | -
---|
- de.juplo.test - | -
-1 package de.juplo.plugins.hibernate4; -2 -3 /* -4 * Copyright 2001-2005 The Apache Software Foundation. -5 * -6 * Licensed under the Apache License, Version 2.0 (the "License"); -7 * you may not use this file except in compliance with the License. -8 * You may obtain a copy of the License at -9 * -10 * http://www.apache.org/licenses/LICENSE-2.0 -11 * -12 * Unless required by applicable law or agreed to in writing, software -13 * distributed under the License is distributed on an "AS IS" BASIS, -14 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -15 * See the License for the specific language governing permissions and -16 * limitations under the License. -17 */ -18 -19 import com.pyx4j.log4j.MavenLogAppender; -20 import java.io.File; -21 import java.io.FileInputStream; -22 import java.io.FileNotFoundException; -23 import java.io.FileOutputStream; -24 import java.io.IOException; -25 import java.io.InputStream; -26 import java.io.ObjectInputStream; -27 import java.io.ObjectOutputStream; -28 import java.math.BigInteger; -29 import java.net.URL; -30 import java.net.URLClassLoader; -31 import java.security.MessageDigest; -32 import java.security.NoSuchAlgorithmException; -33 import java.sql.Driver; -34 import java.sql.DriverPropertyInfo; -35 import java.sql.SQLException; -36 import java.sql.SQLFeatureNotSupportedException; -37 import java.util.Collections; -38 import java.util.Comparator; -39 import java.util.HashMap; -40 import java.util.HashSet; -41 import java.util.LinkedHashSet; -42 import java.util.LinkedList; -43 import java.util.List; -44 import java.util.Map; -45 import java.util.Map.Entry; -46 import java.util.Properties; -47 import java.util.Set; -48 import java.util.TreeSet; -49 import java.util.logging.Logger; -50 import java.util.regex.Matcher; -51 import java.util.regex.Pattern; -52 import javax.persistence.Embeddable; -53 import javax.persistence.Entity; -54 import javax.persistence.MappedSuperclass; -55 import javax.persistence.spi.PersistenceUnitTransactionType; -56 import org.apache.maven.artifact.Artifact; -57 import org.apache.maven.model.Resource; -58 import org.apache.maven.plugin.AbstractMojo; -59 import org.apache.maven.plugin.MojoExecutionException; -60 import org.apache.maven.plugin.MojoFailureException; -61 import org.apache.maven.project.MavenProject; -62 import org.hibernate.boot.registry.StandardServiceRegistryBuilder; -63 import org.hibernate.boot.registry.classloading.spi.ClassLoaderService; -64 import org.hibernate.boot.registry.classloading.spi.ClassLoadingException; -65 import org.hibernate.boot.registry.internal.StandardServiceRegistryImpl; -66 import org.hibernate.cfg.Environment; -67 import org.hibernate.cfg.NamingStrategy; -68 import org.hibernate.envers.configuration.spi.AuditConfiguration; -69 import org.hibernate.internal.util.config.ConfigurationHelper; -70 import org.hibernate.jpa.boot.internal.ParsedPersistenceXmlDescriptor; -71 import org.hibernate.jpa.boot.internal.PersistenceXmlParser; -72 import org.hibernate.jpa.boot.spi.ProviderChecker; -73 import org.hibernate.tool.hbm2ddl.SchemaExport; -74 import org.hibernate.tool.hbm2ddl.SchemaExport.Type; -75 import org.hibernate.tool.hbm2ddl.Target; -76 import org.scannotation.AnnotationDB; -77 -78 -79 /** -80 * Goal which extracts the hibernate-mapping-configuration and -81 * exports an according SQL-database-schema. -82 * -83 * @goal export -84 * @phase process-classes -85 * @threadSafe -86 * @requiresDependencyResolution runtime -87 */ -88 public class Hbm2DdlMojo extends AbstractMojo -89 { -90 public final static String EXPORT_SKIPPED_PROPERTY = "hibernate.export.skipped"; -91 -92 public final static String DRIVER_CLASS = "hibernate.connection.driver_class"; -93 public final static String URL = "hibernate.connection.url"; -94 public final static String USERNAME = "hibernate.connection.username"; -95 public final static String PASSWORD = "hibernate.connection.password"; -96 public final static String DIALECT = "hibernate.dialect"; -97 public final static String NAMING_STRATEGY="hibernate.ejb.naming_strategy"; -98 public final static String ENVERS = "hibernate.export.envers"; -99 -100 public final static String JPA_DRIVER = "javax.persistence.jdbc.driver"; -101 public final static String JPA_URL = "javax.persistence.jdbc.url"; -102 public final static String JPA_USERNAME = "javax.persistence.jdbc.user"; -103 public final static String JPA_PASSWORD = "javax.persistence.jdbc.password"; -104 -105 public final static String MD5S = "hibernate4-generatedschema.md5s"; -106 -107 private final static Pattern split = Pattern.compile("[^,\\s]+"); -108 -109 -110 /** -111 * The maven project. -112 * <p> -113 * Only needed internally. -114 * -115 * @parameter property="project" -116 * @required -117 * @readonly -118 */ -119 private MavenProject project; -120 -121 /** -122 * Build-directory. -123 * <p> -124 * Only needed internally. -125 * -126 * @parameter property="project.build.directory" -127 * @required -128 * @readonly -129 */ -130 private String buildDirectory; -131 -132 /** -133 * Classes-Directory to scan. -134 * <p> -135 * This parameter defaults to the maven build-output-directory for classes. -136 * Additionally, all dependencies are scanned for annotated classes. -137 * -138 * @parameter property="project.build.outputDirectory" -139 * @since 1.0 -140 */ -141 private String outputDirectory; -142 -143 /** -144 * Whether to scan test-classes too, or not. -145 * <p> -146 * If this parameter is set to <code>true</code> the test-classes of the -147 * artifact will be scanned for hibernate-annotated classes additionally. -148 * -149 * @parameter property="hibernate.export.scan_testclasses" default-value="false" -150 * @since 1.0.1 -151 */ -152 private boolean scanTestClasses; -153 -154 /** -155 * Dependency-Scopes, that should be scanned for annotated classes. -156 * <p> -157 * By default, only dependencies in the scope <code>compile</code> are -158 * scanned for annotated classes. Multiple scopes can be seperated by -159 * white space or commas. -160 * <p> -161 * If you do not want any dependencies to be scanned for annotated -162 * classes, set this parameter to <code>none</code>. -163 * <p> -164 * The plugin does not scan for annotated classes in transitive -165 * dependencies. If some of your annotated classes are hidden in a -166 * transitive dependency, you can simply add that dependency explicitly. -167 * -168 * @parameter property="hibernate.export.scan_dependencies" default-value="compile" -169 * @since 1.0.3 -170 */ -171 private String scanDependencies; -172 -173 /** -174 * Test-Classes-Directory to scan. -175 * <p> -176 * This parameter defaults to the maven build-output-directory for -177 * test-classes. -178 * <p> -179 * This parameter is only used, when <code>scanTestClasses</code> is set -180 * to <code>true</code>! -181 * -182 * @parameter property="project.build.testOutputDirectory" -183 * @since 1.0.2 -184 */ -185 private String testOutputDirectory; -186 -187 /** -188 * Skip execution -189 * <p> -190 * If set to <code>true</code>, the execution is skipped. -191 * <p> -192 * A skipped execution is signaled via the maven-property -193 * <code>${hibernate.export.skipped}</code>. -194 * <p> -195 * The execution is skipped automatically, if no modified or newly added -196 * annotated classes are found and the dialect was not changed. -197 * -198 * @parameter property="hibernate.skip" default-value="${maven.test.skip}" -199 * @since 1.0 -200 */ -201 private boolean skip; -202 -203 /** -204 * Force execution -205 * <p> -206 * Force execution, even if no modified or newly added annotated classes -207 * where found and the dialect was not changed. -208 * <p> -209 * <code>skip</code> takes precedence over <code>force</code>. -210 * -211 * @parameter property="hibernate.export.force" default-value="false" -212 * @since 1.0 -213 */ -214 private boolean force; -215 -216 /** -217 * SQL-Driver name. -218 * -219 * @parameter property="hibernate.connection.driver_class" -220 * @since 1.0 -221 */ -222 private String driverClassName; -223 -224 /** -225 * Database URL. -226 * -227 * @parameter property="hibernate.connection.url" -228 * @since 1.0 -229 */ -230 private String url; -231 -232 /** -233 * Database username -234 * -235 * @parameter property="hibernate.connection.username" -236 * @since 1.0 -237 */ -238 private String username; -239 -240 /** -241 * Database password -242 * -243 * @parameter property="hibernate.connection.password" -244 * @since 1.0 -245 */ -246 private String password; -247 -248 /** -249 * Hibernate dialect. -250 * -251 * @parameter property="hibernate.dialect" -252 * @since 1.0 -253 */ -254 private String hibernateDialect; -255 -256 /** -257 * Hibernate Naming Strategy -258 * -259 * @parameter property="hibernate.ejb.naming_strategy" -260 * @since 1.0.2 -261 */ -262 private String hibernateNamingStrategy; -263 -264 /** -265 * Path to Hibernate properties file. -266 * If this parameter is not set the plugin will try to load the configuration -267 * from a file <code>hibernate.properties</code> on the classpath. The -268 * test-classpath takes precedence. -269 * -270 * @parameter -271 * @since 1.0 -272 */ -273 private String hibernateProperties; -274 -275 /** -276 * Path to Hibernate configuration file (.cfg.xml). -277 * Settings in this file will overwrite settings in the properties file. -278 * If this parameter is not set the plugin will try to load the configuration -279 * from a file <code>hibernate.cfg.xml</code> on the classpath. The -280 * test-classpath takes precedence. -281 * -282 * @parameter -283 * @since 1.1.0 -284 */ -285 private String hibernateConfig; -286 -287 /** -288 * Name of the persistence-unit. -289 * If there is only one persistence-unit available, that unit will be used -290 * automatically. -291 * Settings in this file will overwrite settings in the properties or the -292 * configuration file. -293 * -294 * @parameter -295 * @since 1.1.0 -296 */ -297 private String persistenceUnit; -298 -299 /** -300 * List of Hibernate-Mapping-Files (XML). -301 * Multiple files can be separated with white-spaces and/or commas. -302 * -303 * @parameter property="hibernate.mapping" -304 * @since 1.0.2 -305 */ -306 private String hibernateMapping; -307 -308 /** -309 * Target of execution: -310 * <ul> -311 * <li><strong>NONE</strong> only export schema to SQL-script (forces execution, signals skip)</li> -312 * <li><strong>EXPORT</strong> create database (<strong>DEFAULT!</strong>). forces execution, signals skip)</li> -313 * <li><strong>SCRIPT</strong> export schema to SQL-script and print it to STDOUT</li> -314 * <li><strong>BOTH</strong></li> -315 * </ul> -316 * -317 * A database connection is only needed for EXPORT and BOTH, but a -318 * Hibernate-Dialect must always be chosen. -319 * -320 * @parameter property="hibernate.export.target" default-value="EXPORT" -321 * @since 1.0 -322 */ -323 private String target; -324 -325 /** -326 * Type of execution. -327 * <ul> -328 * <li><strong>NONE</strong> do nothing - just validate the configuration</li> -329 * <li><strong>CREATE</strong> create database-schema</li> -330 * <li><strong>DROP</strong> drop database-schema</li> -331 * <li><strong>BOTH</strong> (<strong>DEFAULT!</strong>)</li> -332 * </ul> -333 * -334 * If NONE is choosen, no databaseconnection is needed. -335 * -336 * @parameter property="hibernate.export.type" default-value="BOTH" -337 * @since 1.0 -338 */ -339 private String type; -340 -341 /** -342 * Output file. -343 * -344 * @parameter property="hibernate.export.schema.filename" default-value="${project.build.directory}/schema.sql" -345 * @since 1.0 -346 */ -347 private String outputFile; -348 -349 /** -350 * Delimiter in output-file. -351 * -352 * @parameter property="hibernate.export.schema.delimiter" default-value=";" -353 * @since 1.0 -354 */ -355 private String delimiter; -356 -357 /** -358 * Format output-file. -359 * -360 * @parameter property="hibernate.export.schema.format" default-value="true" -361 * @since 1.0 -362 */ -363 private boolean format; -364 -365 /** -366 * Generate envers schema for auditing tables. -367 * -368 * @parameter property="hibernate.export.envers" default-value="true" -369 * @since 1.0.3 -370 */ -371 private boolean envers; -372 -373 -374 @Override -375 public void execute() -376 throws -377 MojoFailureException, -378 MojoExecutionException -379 { -380 if (skip) -381 { -382 getLog().info("Execution of hibernate4-maven-plugin:export was skipped!"); -383 project.getProperties().setProperty(EXPORT_SKIPPED_PROPERTY, "true"); -384 return; -385 } -386 -387 Map<String,String> md5s; -388 boolean modified = false; -389 File saved = new File(buildDirectory + File.separator + MD5S); -390 -391 if (saved.isFile() && saved.length() > 0) -392 { -393 try -394 { -395 FileInputStream fis = new FileInputStream(saved); -396 ObjectInputStream ois = new ObjectInputStream(fis); -397 md5s = (HashMap<String,String>)ois.readObject(); -398 ois.close(); -399 } -400 catch (Exception e) -401 { -402 md5s = new HashMap<String,String>(); -403 getLog().warn("Cannot read timestamps from saved: " + e); -404 } -405 } -406 else -407 { -408 md5s = new HashMap<String,String>(); -409 try -410 { -411 saved.createNewFile(); -412 } -413 catch (IOException e) -414 { -415 getLog().debug("Cannot create file \"" + saved.getPath() + "\" for timestamps: " + e); -416 } -417 } -418 -419 URLClassLoader classLoader = null; -420 try -421 { -422 getLog().debug("Creating ClassLoader for project-dependencies..."); -423 List<String> classpathFiles = project.getCompileClasspathElements(); -424 if (scanTestClasses) -425 classpathFiles.addAll(project.getTestClasspathElements()); -426 List<URL> urls = new LinkedList<URL>(); -427 File file; -428 file = new File(testOutputDirectory); -429 if (!file.exists()) -430 { -431 getLog().info("creating test-output-directory: " + testOutputDirectory); -432 file.mkdirs(); -433 } -434 urls.add(file.toURI().toURL()); -435 file = new File(outputDirectory); -436 if (!file.exists()) -437 { -438 getLog().info("creating output-directory: " + outputDirectory); -439 file.mkdirs(); -440 } -441 urls.add(file.toURI().toURL()); -442 for (String pathElement : classpathFiles) -443 { -444 getLog().debug("Dependency: " + pathElement); -445 urls.add(new File(pathElement).toURI().toURL()); -446 } -447 classLoader = -448 new URLClassLoader( -449 urls.toArray(new URL[urls.size()]), -450 getClass().getClassLoader() -451 ); -452 } -453 catch (Exception e) -454 { -455 getLog().error("Error while creating ClassLoader!", e); -456 throw new MojoExecutionException(e.getMessage()); -457 } -458 -459 Set<Class<?>> classes = -460 new TreeSet<Class<?>>( -461 new Comparator<Class<?>>() { -462 @Override -463 public int compare(Class<?> a, Class<?> b) -464 { -465 return a.getName().compareTo(b.getName()); -466 } -467 } -468 ); -469 -470 try -471 { -472 AnnotationDB db = new AnnotationDB(); -473 File dir = new File(outputDirectory); -474 if (dir.exists()) -475 { -476 getLog().info("Scanning directory " + outputDirectory + " for annotated classes..."); -477 URL dirUrl = dir.toURI().toURL(); -478 db.scanArchives(dirUrl); -479 } -480 if (scanTestClasses) -481 { -482 dir = new File(testOutputDirectory); -483 if (dir.exists()) -484 { -485 getLog().info("Scanning directory " + testOutputDirectory + " for annotated classes..."); -486 URL dirUrl = dir.toURI().toURL(); -487 db.scanArchives(dirUrl); -488 } -489 } -490 if (scanDependencies != null) -491 { -492 Matcher matcher = split.matcher(scanDependencies); -493 while (matcher.find()) -494 { -495 getLog().info("Scanning dependencies for scope " + matcher.group()); -496 for (Artifact artifact : project.getDependencyArtifacts()) -497 { -498 if (!artifact.getScope().equalsIgnoreCase(matcher.group())) -499 continue; -500 if (artifact.getFile() == null) -501 { -502 getLog().warn( -503 "Cannot scan dependency " + -504 artifact.getId() + -505 ": no JAR-file available!" -506 ); -507 continue; -508 } -509 getLog().info( -510 "Scanning dependency " + -511 artifact.getId() + -512 " for annotated classes..." -513 ); -514 db.scanArchives(artifact.getFile().toURI().toURL()); -515 } -516 } -517 } -518 -519 Set<String> classNames = new HashSet<String>(); -520 if (db.getAnnotationIndex().containsKey(Entity.class.getName())) -521 classNames.addAll(db.getAnnotationIndex().get(Entity.class.getName())); -522 if (db.getAnnotationIndex().containsKey(MappedSuperclass.class.getName())) -523 classNames.addAll(db.getAnnotationIndex().get(MappedSuperclass.class.getName())); -524 if (db.getAnnotationIndex().containsKey(Embeddable.class.getName())) -525 classNames.addAll(db.getAnnotationIndex().get(Embeddable.class.getName())); -526 -527 MessageDigest digest = java.security.MessageDigest.getInstance("MD5"); -528 for (String name : classNames) -529 { -530 Class<?> annotatedClass = classLoader.loadClass(name); -531 classes.add(annotatedClass); -532 String resourceName = annotatedClass.getName(); -533 resourceName = resourceName.substring(resourceName.lastIndexOf(".") + 1, resourceName.length()) + ".class"; -534 InputStream is = -535 annotatedClass -536 .getResourceAsStream(resourceName); -537 byte[] buffer = new byte[1024*4]; // copy data in 4MB-chunks -538 int i; -539 while((i = is.read(buffer)) > -1) -540 digest.update(buffer, 0, i); -541 is.close(); -542 byte[] bytes = digest.digest(); -543 BigInteger bi = new BigInteger(1, bytes); -544 String newMd5 = String.format("%0" + (bytes.length << 1) + "x", bi); -545 String oldMd5 = !md5s.containsKey(name) ? "" : md5s.get(name); -546 if (!newMd5.equals(oldMd5)) -547 { -548 getLog().debug("Found new or modified annotated class: " + name); -549 modified = true; -550 md5s.put(name, newMd5); -551 } -552 else -553 { -554 getLog().debug(oldMd5 + " -> class unchanged: " + name); -555 } -556 } -557 } -558 catch (ClassNotFoundException e) -559 { -560 getLog().error("Error while adding annotated classes!", e); -561 throw new MojoExecutionException(e.getMessage()); -562 } -563 catch (Exception e) -564 { -565 getLog().error("Error while scanning!", e); -566 throw new MojoFailureException(e.getMessage()); -567 } -568 -569 -570 ValidationConfiguration config = new ValidationConfiguration(); -571 // Clear unused system-properties -572 config.setProperties(new Properties()); -573 -574 -575 ClassLoader contextClassLoader = Thread.currentThread().getContextClassLoader(); -576 StandardServiceRegistryImpl registry = null; -577 MavenLogAppender.startPluginLog(this); -578 -579 try -580 { -581 /** -582 * Change class-loader of current thread, so that hibernate can -583 * see all dependencies! -584 */ -585 Thread.currentThread().setContextClassLoader(classLoader); -586 -587 -588 /** Try to read configuration from properties-file */ -589 try -590 { -591 if (hibernateProperties == null) -592 { -593 URL url = classLoader.findResource("hibernate.properties"); -594 if (url == null) -595 { -596 getLog().info("No hibernate.properties on the classpath!"); -597 } -598 else -599 { -600 getLog().info("Reading settings from hibernate.properties on the classpath."); -601 Properties properties = new Properties(); -602 properties.load(url.openStream()); -603 config.setProperties(properties); -604 } -605 } -606 else -607 { -608 File file = new File(hibernateProperties); -609 if (file.exists()) -610 { -611 getLog().info("Reading settings from file " + hibernateProperties + "..."); -612 Properties properties = new Properties(); -613 properties.load(new FileInputStream(file)); -614 config.setProperties(properties); -615 } -616 else -617 getLog().info("No hibernate-properties-file found! (Checked path: " + hibernateProperties + ")"); -618 } -619 } -620 catch (IOException e) -621 { -622 getLog().error("Error while reading properties!", e); -623 throw new MojoExecutionException(e.getMessage()); -624 } -625 -626 /** Try to read configuration from configuration-file */ -627 try -628 { -629 if (hibernateConfig == null) -630 { -631 URL url = classLoader.findResource("hibernate.cfg.xml"); -632 if (url == null) -633 { -634 getLog().info("No hibernate.cfg.xml on the classpath!"); -635 } -636 else -637 { -638 getLog().info("Reading settings from hibernate.cfg.xml on the classpath."); -639 config.configure(url); -640 } -641 } -642 else -643 { -644 File file = new File(hibernateConfig); -645 if (file.exists()) -646 { -647 getLog().info("Reading configuration from file " + hibernateConfig + "..."); -648 config.configure(file); -649 } -650 else -651 getLog().info("No hibernate-configuration-file found! (Checked path: " + hibernateConfig + ")"); -652 } -653 } -654 catch (Exception e) -655 { -656 getLog().error("Error while reading configuration!", e); -657 throw new MojoExecutionException(e.getMessage()); -658 } -659 -660 ParsedPersistenceXmlDescriptor persistenceUnitDescriptor = -661 getPersistenceUnitDescriptor( -662 persistenceUnit, -663 config.getProperties(), -664 new MavenProjectClassLoaderService(classLoader) -665 ); -666 if (persistenceUnitDescriptor != null) -667 config.setProperties(persistenceUnitDescriptor.getProperties()); -668 -669 -670 /** Overwrite values from properties-file or set, if given */ -671 -672 if (driverClassName != null) -673 { -674 if (config.getProperties().containsKey(DRIVER_CLASS)) -675 getLog().debug( -676 "Overwriting property " + -677 DRIVER_CLASS + "=" + config.getProperty(DRIVER_CLASS) + -678 " with the value " + driverClassName -679 ); -680 else -681 getLog().debug("Using the value " + driverClassName); -682 config.setProperty(DRIVER_CLASS, driverClassName); -683 } -684 if (config.getProperty(DRIVER_CLASS) == null) -685 { -686 String driver = config.getProperty(JPA_DRIVER); -687 if (driver != null) -688 { -689 getLog().info( -690 DRIVER_CLASS + -691 " is not set. Borrow setting from " + -692 JPA_DRIVER + -693 ": " + -694 driver); -695 config.setProperty(DRIVER_CLASS, driver); -696 } -697 } -698 -699 if (url != null) -700 { -701 if (config.getProperties().containsKey(URL)) -702 getLog().debug( -703 "Overwriting property " + -704 URL + "=" + config.getProperty(URL) + -705 " with the value " + url -706 ); -707 else -708 getLog().debug("Using the value " + url); -709 config.setProperty(URL, url); -710 } -711 if (config.getProperty(URL) == null) -712 { -713 String url = config.getProperty(JPA_URL); -714 if (url != null) -715 { -716 getLog().info( -717 URL + -718 " is not set. Borrow setting from " + -719 JPA_URL + -720 ": " + -721 url); -722 config.setProperty(URL, url); -723 } -724 } -725 -726 if (username != null) -727 { -728 if (config.getProperties().containsKey(USERNAME)) -729 getLog().debug( -730 "Overwriting property " + -731 USERNAME + "=" + config.getProperty(USERNAME) + -732 " with the value " + username -733 ); -734 else -735 getLog().debug("Using the value " + username); -736 config.setProperty(USERNAME, username); -737 } -738 if (config.getProperty(USERNAME) == null) -739 { -740 String username = config.getProperty(JPA_USERNAME); -741 if (username != null) -742 { -743 getLog().info( -744 USERNAME + -745 " is not set. Borrow setting from " + -746 JPA_USERNAME + -747 ": " + -748 username); -749 config.setProperty(USERNAME, username); -750 } -751 } -752 -753 if (password != null) -754 { -755 if (config.getProperties().containsKey(PASSWORD)) -756 getLog().debug( -757 "Overwriting property " + -758 PASSWORD + "=" + config.getProperty(PASSWORD) + -759 " with value " + password -760 ); -761 else -762 getLog().debug("Using value " + password + " for property " + PASSWORD); -763 config.setProperty(PASSWORD, password); -764 } -765 if (config.getProperty(PASSWORD) == null) -766 { -767 String password = config.getProperty(JPA_PASSWORD); -768 if (password != null) -769 { -770 getLog().info( -771 PASSWORD + -772 " is not set. Borrow setting from " + -773 JPA_PASSWORD + -774 ": " + -775 password); -776 config.setProperty(PASSWORD, password); -777 } -778 } -779 -780 if (hibernateDialect != null) -781 { -782 if (config.getProperties().containsKey(DIALECT)) -783 getLog().debug( -784 "Overwriting property " + -785 DIALECT + "=" + config.getProperty(DIALECT) + -786 " with value " + hibernateDialect -787 ); -788 else -789 getLog().debug( -790 "Using value " + hibernateDialect + " for property " + DIALECT -791 ); -792 config.setProperty(DIALECT, hibernateDialect); -793 } -794 -795 if ( hibernateNamingStrategy != null ) -796 { -797 if ( config.getProperties().contains(NAMING_STRATEGY)) -798 getLog().debug( -799 "Overwriting property " + -800 NAMING_STRATEGY + "=" + config.getProperty(NAMING_STRATEGY) + -801 " with value " + hibernateNamingStrategy -802 ); -803 else -804 getLog().debug( -805 "Using value " + hibernateNamingStrategy + " for property " + -806 NAMING_STRATEGY -807 ); -808 config.setProperty(NAMING_STRATEGY, hibernateNamingStrategy); -809 } -810 -811 /** The generated SQL varies with the dialect! */ -812 if (md5s.containsKey(DIALECT)) -813 { -814 String dialect = config.getProperty(DIALECT); -815 if (md5s.get(DIALECT).equals(dialect)) -816 getLog().debug("SQL-dialect unchanged."); -817 else -818 { -819 modified = true; -820 if (dialect == null) -821 { -822 getLog().debug("SQL-dialect was unset."); -823 md5s.remove(DIALECT); -824 } -825 else -826 { -827 getLog().debug("SQL-dialect changed: " + dialect); -828 md5s.put(DIALECT, dialect); -829 } -830 } -831 } -832 else -833 { -834 String dialect = config.getProperty(DIALECT); -835 if (dialect != null) -836 { -837 modified = true; -838 md5s.put(DIALECT, config.getProperty(DIALECT)); -839 } -840 } -841 -842 /** The generated SQL varies with the envers-configuration */ -843 if (md5s.get(ENVERS) != null) -844 { -845 if (md5s.get(ENVERS).equals(Boolean.toString(envers))) -846 getLog().debug("Envers-Configuration unchanged. Enabled: " + envers); -847 else -848 { -849 getLog().debug("Envers-Configuration changed. Enabled: " + envers); -850 modified = true; -851 md5s.put(ENVERS, Boolean.toString(envers)); -852 } -853 } -854 else -855 { -856 modified = true; -857 md5s.put(ENVERS, Boolean.toString(envers)); -858 } -859 -860 if (config.getProperties().isEmpty()) -861 { -862 getLog().error("No properties set!"); -863 throw new MojoFailureException("Hibernate configuration is missing!"); -864 } -865 -866 getLog().info("Gathered hibernate-configuration (turn on debugging for details):"); -867 for (Entry<Object,Object> entry : config.getProperties().entrySet()) -868 getLog().info(" " + entry.getKey() + " = " + entry.getValue()); -869 -870 -871 getLog().debug("Adding explicitly configured mappings..."); -872 if (hibernateMapping != null) -873 { -874 try -875 { -876 MessageDigest digest = java.security.MessageDigest.getInstance("MD5"); -877 for (String filename : hibernateMapping.split("[\\s,]+")) -878 { -879 // First try the filename as absolute/relative path -880 File file = new File(filename); -881 if (!file.exists()) -882 { -883 // If the file was not found, search for it in the resource-directories -884 for (Resource resource : project.getResources()) -885 { -886 file = new File(resource.getDirectory() + File.separator + filename); -887 if (file.exists()) -888 break; -889 } -890 } -891 if (file != null && file.exists()) -892 { -893 InputStream is = new FileInputStream(file); -894 byte[] buffer = new byte[1024*4]; // copy data in 4MB-chunks -895 int i; -896 while((i = is.read(buffer)) > -1) -897 digest.update(buffer, 0, i); -898 is.close(); -899 byte[] bytes = digest.digest(); -900 BigInteger bi = new BigInteger(1, bytes); -901 String newMd5 = String.format("%0" + (bytes.length << 1) + "x", bi); -902 String oldMd5 = !md5s.containsKey(filename) ? "" : md5s.get(filename); -903 if (!newMd5.equals(oldMd5)) -904 { -905 getLog().debug("Found new or modified mapping-file: " + filename); -906 modified = true; -907 md5s.put(filename, newMd5); -908 } -909 else -910 { -911 getLog().debug(oldMd5 + " -> mapping-file unchanged: " + filename); -912 } -913 getLog().debug("Adding mappings from XML-configurationfile: " + file); -914 config.addFile(file); -915 } -916 else -917 throw new MojoFailureException("File " + filename + " could not be found in any of the configured resource-directories!"); -918 } -919 } -920 catch (NoSuchAlgorithmException e) -921 { -922 throw new MojoFailureException("Cannot calculate MD5 sums!", e); -923 } -924 catch (FileNotFoundException e) -925 { -926 throw new MojoFailureException("Cannot calculate MD5 sums!", e); -927 } -928 catch (IOException e) -929 { -930 throw new MojoFailureException("Cannot calculate MD5 sums!", e); -931 } -932 } -933 -934 getLog().debug("Adding annotated classes to hibernate-mapping-configuration..."); -935 // build annotated packages -936 Set<String> packages = new HashSet<String>(); -937 for (Class<?> annotatedClass : classes) -938 { -939 String packageName = annotatedClass.getPackage().getName(); -940 if (!packages.contains(packageName)) -941 { -942 getLog().debug("Add package " + packageName); -943 packages.add(packageName); -944 config.addPackage(packageName); -945 getLog().debug("type definintions" + config.getTypeDefs()); -946 } -947 getLog().debug("Class " + annotatedClass); -948 config.addAnnotatedClass(annotatedClass); -949 } -950 -951 Target target = null; -952 try -953 { -954 target = Target.valueOf(this.target.toUpperCase()); -955 } -956 catch (IllegalArgumentException e) -957 { -958 getLog().error("Invalid value for configuration-option \"target\": " + this.target); -959 getLog().error("Valid values are: NONE, SCRIPT, EXPORT, BOTH"); -960 throw new MojoExecutionException("Invalid value for configuration-option \"target\""); -961 } -962 Type type = null; -963 try -964 { -965 type = Type.valueOf(this.type.toUpperCase()); -966 } -967 catch (IllegalArgumentException e) -968 { -969 getLog().error("Invalid value for configuration-option \"type\": " + this.type); -970 getLog().error("Valid values are: NONE, CREATE, DROP, BOTH"); -971 throw new MojoExecutionException("Invalid value for configuration-option \"type\""); -972 } -973 -974 -975 if (config.getProperty(DIALECT) == null) -976 throw new MojoFailureException("hibernate-dialect must be set!"); -977 -978 -979 if (target.equals(Target.SCRIPT) || target.equals(Target.NONE)) -980 { -981 project.getProperties().setProperty(EXPORT_SKIPPED_PROPERTY, "true"); -982 } -983 if ( -984 !modified -985 && !target.equals(Target.SCRIPT) -986 && !target.equals(Target.NONE) -987 && !force -988 ) -989 { -990 getLog().info("No modified annotated classes or mapping-files found and dialect unchanged."); -991 getLog().info("Skipping schema generation!"); -992 project.getProperties().setProperty(EXPORT_SKIPPED_PROPERTY, "true"); -993 return; -994 } -995 -996 -997 if ( config.getProperties().containsKey(NAMING_STRATEGY)) -998 { -999 String namingStrategy = config.getProperty(NAMING_STRATEGY); -1000 getLog().debug("Explicitly set NamingStrategy: " + namingStrategy); -1001 try -1002 { -1003 List runtimeClasspathElements = project.getRuntimeClasspathElements(); -1004 URL[] runtimeUrls = new URL[runtimeClasspathElements.size()]; -1005 for (int i = 0; i < runtimeClasspathElements.size(); i++) -1006 { -1007 String element = (String) runtimeClasspathElements.get(i); -1008 runtimeUrls[i] = new File(element).toURI().toURL(); -1009 } -1010 URLClassLoader newLoader = new URLClassLoader( -1011 runtimeUrls, -1012 Thread.currentThread().getContextClassLoader() -1013 ); -1014 @SuppressWarnings("unchecked") -1015 Class<NamingStrategy> namingStrategyClass = -1016 (Class<NamingStrategy>) newLoader.loadClass(namingStrategy); -1017 config.setNamingStrategy(namingStrategyClass.newInstance()); -1018 } -1019 catch (Exception e) -1020 { -1021 getLog().error("Error setting NamingStrategy", e); -1022 throw new MojoExecutionException(e.getMessage()); -1023 } -1024 } -1025 -1026 -1027 Environment.verifyProperties(config.getProperties()); -1028 ConfigurationHelper.resolvePlaceHolders(config.getProperties()); -1029 registry = -1030 (StandardServiceRegistryImpl) -1031 new StandardServiceRegistryBuilder() -1032 .applySettings(config.getProperties()) -1033 .build(); -1034 -1035 config.buildMappings(); -1036 -1037 if (envers) -1038 { -1039 getLog().info("Automatic auditing via hibernate-envers enabled!"); -1040 AuditConfiguration.getFor(config); -1041 } -1042 -1043 SchemaExport export = new SchemaExport(registry, config); -1044 export.setDelimiter(delimiter); -1045 export.setFormat(format); -1046 -1047 File outF = new File(outputFile); -1048 -1049 if (!outF.isAbsolute()) -1050 { -1051 // Interpret relative file path relative to build directory -1052 outF = new File(buildDirectory, outputFile); -1053 getLog().info("Adjusted relative path, resulting path is " + outF.getPath()); -1054 } -1055 -1056 // Ensure that directory path for specified file exists -1057 File outFileParentDir = outF.getParentFile(); -1058 if (null != outFileParentDir && !outFileParentDir.exists()) -1059 { -1060 try -1061 { -1062 getLog().info("Creating directory path for output file:" + outFileParentDir.getPath()); -1063 outFileParentDir.mkdirs(); -1064 } -1065 catch (Exception e) -1066 { -1067 getLog().error("Error creating directory path for output file: " + e.getLocalizedMessage()); -1068 } -1069 } -1070 -1071 export.setOutputFile(outF.getPath()); -1072 export.execute(target, type); -1073 -1074 for (Object exception : export.getExceptions()) -1075 getLog().debug(exception.toString()); -1076 } -1077 finally -1078 { -1079 /** Stop Log-Capturing */ -1080 MavenLogAppender.endPluginLog(this); -1081 -1082 /** Restore the old class-loader (TODO: is this really necessary?) */ -1083 Thread.currentThread().setContextClassLoader(contextClassLoader); -1084 -1085 if (registry != null) -1086 registry.destroy(); -1087 } -1088 -1089 /** Write md5-sums for annotated classes to file */ -1090 try -1091 { -1092 FileOutputStream fos = new FileOutputStream(saved); -1093 ObjectOutputStream oos = new ObjectOutputStream(fos); -1094 oos.writeObject(md5s); -1095 oos.close(); -1096 fos.close(); -1097 } -1098 catch (Exception e) -1099 { -1100 getLog().error("Cannot write md5-sums to file: " + e); -1101 } -1102 } -1103 -1104 private ParsedPersistenceXmlDescriptor getPersistenceUnitDescriptor( -1105 String name, -1106 Properties properties, -1107 ClassLoaderService loader -1108 ) -1109 throws -1110 MojoFailureException -1111 { -1112 PersistenceXmlParser parser = -1113 new PersistenceXmlParser( -1114 loader, -1115 PersistenceUnitTransactionType.RESOURCE_LOCAL -1116 ); -1117 -1118 List<ParsedPersistenceXmlDescriptor> units = parser.doResolve(properties); -1119 -1120 if (name == null) -1121 { -1122 switch (units.size()) -1123 { -1124 case 0: -1125 getLog().info("Found no META-INF/persistence.xml."); -1126 return null; -1127 case 1: -1128 getLog().info("Using persistence-unit " + units.get(0).getName()); -1129 return units.get(0); -1130 default: -1131 getLog().warn("No name provided and multiple persistence units found:"); -1132 for (ParsedPersistenceXmlDescriptor unit : units) -1133 getLog().warn(" - " + unit.getName()); -1134 return null; -1135 } -1136 -1137 } -1138 -1139 for (ParsedPersistenceXmlDescriptor unit : units) -1140 { -1141 getLog().debug("Found persistence-unit " + unit.getName()); -1142 if (!unit.getName().equals(name)) -1143 continue; -1144 -1145 // See if we (Hibernate) are the persistence provider -1146 if (!ProviderChecker.isProvider(unit, properties)) -1147 { -1148 getLog().debug("Wrong provider: " + unit.getProviderClassName()); -1149 continue; -1150 } -1151 -1152 getLog().info("Using persistence-unit " + unit.getName()); -1153 return unit; -1154 } -1155 -1156 throw new MojoFailureException("Could not find persistence-unit " + name); -1157 } -1158 -1159 -1160 static final class MavenProjectClassLoaderService implements ClassLoaderService -1161 { -1162 final private ClassLoader loader; -1163 -1164 -1165 public MavenProjectClassLoaderService(ClassLoader loader) -1166 { -1167 this.loader = loader; -1168 } -1169 -1170 -1171 @Override -1172 public <T> Class<T> classForName(String name) -1173 { -1174 try -1175 { -1176 return (Class<T>)loader.loadClass(name); -1177 } -1178 catch (ClassNotFoundException e) -1179 { -1180 throw new ClassLoadingException( "Unable to load class [" + name + "]", e ); -1181 } -1182 } -1183 -1184 @Override -1185 public URL locateResource(String name) -1186 { -1187 return loader.getResource(name); -1188 } -1189 -1190 @Override -1191 public InputStream locateResourceStream(String name) -1192 { -1193 return loader.getResourceAsStream(name); -1194 } -1195 -1196 @Override -1197 public List<URL> locateResources(String name) -1198 { -1199 try -1200 { -1201 return Collections.list(loader.getResources(name)); -1202 } -1203 catch (IOException e) -1204 { -1205 return Collections.EMPTY_LIST; -1206 } -1207 } -1208 -1209 @Override -1210 public <S> LinkedHashSet<S> loadJavaServices(Class<S> serviceContract) -1211 { -1212 throw new UnsupportedOperationException("Not supported yet."); //To change body of generated methods, choose Tools | Templates. -1213 } -1214 -1215 @Override -1216 public void stop() { } -1217 -1218 } -1219 -1220 -1221 /** -1222 * Needed, because DriverManager won't pick up drivers, that were not -1223 * loaded by the system-classloader! -1224 * See: -1225 * http://stackoverflow.com/questions/288828/how-to-use-a-jdbc-driver-fromodifiedm-an-arbitrary-location -1226 */ -1227 static final class DriverProxy implements Driver -1228 { -1229 private final Driver target; -1230 -1231 DriverProxy(Driver target) -1232 { -1233 if (target == null) -1234 throw new NullPointerException(); -1235 this.target = target; -1236 } -1237 -1238 public java.sql.Driver getTarget() -1239 { -1240 return target; -1241 } -1242 -1243 @Override -1244 public boolean acceptsURL(String url) throws SQLException -1245 { -1246 return target.acceptsURL(url); -1247 } -1248 -1249 @Override -1250 public java.sql.Connection connect( -1251 String url, -1252 java.util.Properties info -1253 ) -1254 throws -1255 SQLException -1256 { -1257 return target.connect(url, info); -1258 } -1259 -1260 @Override -1261 public int getMajorVersion() -1262 { -1263 return target.getMajorVersion(); -1264 } -1265 -1266 @Override -1267 public int getMinorVersion() -1268 { -1269 return target.getMinorVersion(); -1270 } -1271 -1272 @Override -1273 public DriverPropertyInfo[] getPropertyInfo( -1274 String url, -1275 Properties info -1276 ) -1277 throws -1278 SQLException -1279 { -1280 return target.getPropertyInfo(url, info); -1281 } -1282 -1283 @Override -1284 public boolean jdbcCompliant() -1285 { -1286 return target.jdbcCompliant(); -1287 } -1288 -1289 /** -1290 * This Method cannot be annotated with @Override, becaus the plugin -1291 * will not compile then under Java 1.6! -1292 */ -1293 public Logger getParentLogger() throws SQLFeatureNotSupportedException -1294 { -1295 throw new SQLFeatureNotSupportedException("Not supported, for backward-compatibility with Java 1.6"); -1296 } -1297 -1298 @Override -1299 public String toString() -1300 { -1301 return "Proxy: " + target; -1302 } -1303 -1304 @Override -1305 public int hashCode() -1306 { -1307 return target.hashCode(); -1308 } -1309 -1310 @Override -1311 public boolean equals(Object obj) -1312 { -1313 if (!(obj instanceof DriverProxy)) -1314 return false; -1315 DriverProxy other = (DriverProxy) obj; -1316 return this.target.equals(other.target); -1317 } -1318 } -1319 } --
-1 -2 package de.juplo.plugins.hibernate4; -3 -4 import org.apache.maven.plugin.AbstractMojo; -5 import org.apache.maven.plugin.MojoExecutionException; -6 -7 import org.w3c.dom.Document; -8 import org.w3c.dom.Element; -9 import org.w3c.dom.Node; -10 import org.w3c.dom.NodeList; -11 import org.xml.sax.SAXException; -12 -13 import javax.xml.parsers.DocumentBuilder; -14 import javax.xml.parsers.DocumentBuilderFactory; -15 import javax.xml.parsers.ParserConfigurationException; -16 import java.io.IOException; -17 import java.io.InputStream; -18 import java.util.ArrayList; -19 import java.util.List; -20 -21 /** -22 * Display help information on hibernate4-maven-plugin.<br> -23 * Call <code>mvn hibernate4:help -Ddetail=true -Dgoal=<goal-name></code> to display parameter details. -24 * @author maven-plugin-tools -25 * @goal help -26 * @requiresProject false -27 * @threadSafe -28 */ -29 public class HelpMojo -30 extends AbstractMojo -31 { -32 /** -33 * If <code>true</code>, display all settable properties for each goal. -34 * -35 * @parameter property="detail" default-value="false" -36 */ -37 private boolean detail; -38 -39 /** -40 * The name of the goal for which to show help. If unspecified, all goals will be displayed. -41 * -42 * @parameter property="goal" -43 */ -44 private java.lang.String goal; -45 -46 /** -47 * The maximum length of a display line, should be positive. -48 * -49 * @parameter property="lineLength" default-value="80" -50 */ -51 private int lineLength; -52 -53 /** -54 * The number of spaces per indentation level, should be positive. -55 * -56 * @parameter property="indentSize" default-value="2" -57 */ -58 private int indentSize; -59 -60 // groupId/artifactId/plugin-help.xml -61 private static final String PLUGIN_HELP_PATH = -62 "/META-INF/maven/de.juplo/hibernate4-maven-plugin/plugin-help.xml"; -63 -64 private static final int DEFAULT_LINE_LENGTH = 80; -65 -66 private Document build() -67 throws MojoExecutionException -68 { -69 getLog().debug( "load plugin-help.xml: " + PLUGIN_HELP_PATH ); -70 InputStream is = null; -71 try -72 { -73 is = getClass().getResourceAsStream( PLUGIN_HELP_PATH ); -74 DocumentBuilderFactory dbFactory = DocumentBuilderFactory.newInstance(); -75 DocumentBuilder dBuilder = dbFactory.newDocumentBuilder(); -76 return dBuilder.parse( is ); -77 } -78 catch ( IOException e ) -79 { -80 throw new MojoExecutionException( e.getMessage(), e ); -81 } -82 catch ( ParserConfigurationException e ) -83 { -84 throw new MojoExecutionException( e.getMessage(), e ); -85 } -86 catch ( SAXException e ) -87 { -88 throw new MojoExecutionException( e.getMessage(), e ); -89 } -90 finally -91 { -92 if ( is != null ) -93 { -94 try -95 { -96 is.close(); -97 } -98 catch ( IOException e ) -99 { -100 throw new MojoExecutionException( e.getMessage(), e ); -101 } -102 } -103 } -104 } -105 -106 /** -107 * {@inheritDoc} -108 */ -109 public void execute() -110 throws MojoExecutionException -111 { -112 if ( lineLength <= 0 ) -113 { -114 getLog().warn( "The parameter 'lineLength' should be positive, using '80' as default." ); -115 lineLength = DEFAULT_LINE_LENGTH; -116 } -117 if ( indentSize <= 0 ) -118 { -119 getLog().warn( "The parameter 'indentSize' should be positive, using '2' as default." ); -120 indentSize = 2; -121 } -122 -123 Document doc = build(); -124 -125 StringBuilder sb = new StringBuilder(); -126 Node plugin = getSingleChild( doc, "plugin" ); -127 -128 -129 String name = getValue( plugin, "name" ); -130 String version = getValue( plugin, "version" ); -131 String id = getValue( plugin, "groupId" ) + ":" + getValue( plugin, "artifactId" ) + ":" + version; -132 if ( isNotEmpty( name ) && !name.contains( id ) ) -133 { -134 append( sb, name + " " + version, 0 ); -135 } -136 else -137 { -138 if ( isNotEmpty( name ) ) -139 { -140 append( sb, name, 0 ); -141 } -142 else -143 { -144 append( sb, id, 0 ); -145 } -146 } -147 append( sb, getValue( plugin, "description" ), 1 ); -148 append( sb, "", 0 ); -149 -150 //<goalPrefix>plugin</goalPrefix> -151 String goalPrefix = getValue( plugin, "goalPrefix" ); -152 -153 Node mojos1 = getSingleChild( plugin, "mojos" ); -154 -155 List<Node> mojos = findNamedChild( mojos1, "mojo" ); -156 -157 if ( goal == null || goal.length() <= 0 ) -158 { -159 append( sb, "This plugin has " + mojos.size() + ( mojos.size() > 1 ? " goals:" : " goal:" ), 0 ); -160 append( sb, "", 0 ); -161 } -162 -163 for ( Node mojo : mojos ) -164 { -165 writeGoal( sb, goalPrefix, (Element) mojo ); -166 } -167 -168 if ( getLog().isInfoEnabled() ) -169 { -170 getLog().info( sb.toString() ); -171 } -172 } -173 -174 -175 private static boolean isNotEmpty( String string ) -176 { -177 return string != null && string.length() > 0; -178 } -179 -180 private String getValue( Node node, String elementName ) -181 throws MojoExecutionException -182 { -183 return getSingleChild( node, elementName ).getTextContent(); -184 } -185 -186 private Node getSingleChild( Node node, String elementName ) -187 throws MojoExecutionException -188 { -189 List<Node> namedChild = findNamedChild( node, elementName ); -190 if ( namedChild.isEmpty() ) -191 { -192 throw new MojoExecutionException( "Could not find " + elementName + " in plugin-help.xml" ); -193 } -194 if ( namedChild.size() > 1 ) -195 { -196 throw new MojoExecutionException( "Multiple " + elementName + " in plugin-help.xml" ); -197 } -198 return namedChild.get( 0 ); -199 } -200 -201 private List<Node> findNamedChild( Node node, String elementName ) -202 { -203 List<Node> result = new ArrayList<Node>(); -204 NodeList childNodes = node.getChildNodes(); -205 for ( int i = 0; i < childNodes.getLength(); i++ ) -206 { -207 Node item = childNodes.item( i ); -208 if ( elementName.equals( item.getNodeName() ) ) -209 { -210 result.add( item ); -211 } -212 } -213 return result; -214 } -215 -216 private Node findSingleChild( Node node, String elementName ) -217 throws MojoExecutionException -218 { -219 List<Node> elementsByTagName = findNamedChild( node, elementName ); -220 if ( elementsByTagName.isEmpty() ) -221 { -222 return null; -223 } -224 if ( elementsByTagName.size() > 1 ) -225 { -226 throw new MojoExecutionException( "Multiple " + elementName + "in plugin-help.xml" ); -227 } -228 return elementsByTagName.get( 0 ); -229 } -230 -231 private void writeGoal( StringBuilder sb, String goalPrefix, Element mojo ) -232 throws MojoExecutionException -233 { -234 String mojoGoal = getValue( mojo, "goal" ); -235 Node configurationElement = findSingleChild( mojo, "configuration" ); -236 Node description = findSingleChild( mojo, "description" ); -237 if ( goal == null || goal.length() <= 0 || mojoGoal.equals( goal ) ) -238 { -239 append( sb, goalPrefix + ":" + mojoGoal, 0 ); -240 Node deprecated = findSingleChild( mojo, "deprecated" ); -241 if ( ( deprecated != null ) && isNotEmpty( deprecated.getTextContent() ) ) -242 { -243 append( sb, "Deprecated. " + deprecated.getTextContent(), 1 ); -244 if ( detail && description != null ) -245 { -246 append( sb, "", 0 ); -247 append( sb, description.getTextContent(), 1 ); -248 } -249 } -250 else if ( description != null ) -251 { -252 append( sb, description.getTextContent(), 1 ); -253 } -254 append( sb, "", 0 ); -255 -256 if ( detail ) -257 { -258 Node parametersNode = getSingleChild( mojo, "parameters" ); -259 List<Node> parameters = findNamedChild( parametersNode, "parameter" ); -260 append( sb, "Available parameters:", 1 ); -261 append( sb, "", 0 ); -262 -263 for ( Node parameter : parameters ) -264 { -265 writeParameter( sb, parameter, configurationElement ); -266 } -267 } -268 } -269 } -270 -271 private void writeParameter( StringBuilder sb, Node parameter, Node configurationElement ) -272 throws MojoExecutionException -273 { -274 String parameterName = getValue( parameter, "name" ); -275 String parameterDescription = getValue( parameter, "description" ); -276 -277 Element fieldConfigurationElement = (Element) findSingleChild( configurationElement, parameterName ); -278 -279 String parameterDefaultValue = ""; -280 if ( fieldConfigurationElement != null && fieldConfigurationElement.hasAttribute( "default-value" ) ) -281 { -282 parameterDefaultValue = " (Default: " + fieldConfigurationElement.getAttribute( "default-value" ) + ")"; -283 } -284 append( sb, parameterName + parameterDefaultValue, 2 ); -285 Node deprecated = findSingleChild( parameter, "deprecated" ); -286 if ( ( deprecated != null ) && isNotEmpty( deprecated.getTextContent() ) ) -287 { -288 append( sb, "Deprecated. " + deprecated.getTextContent(), 3 ); -289 append( sb, "", 0 ); -290 } -291 append( sb, parameterDescription, 3 ); -292 if ( "true".equals( getValue( parameter, "required" ) ) ) -293 { -294 append( sb, "Required: Yes", 3 ); -295 } -296 if ( ( fieldConfigurationElement != null ) && isNotEmpty( fieldConfigurationElement.getTextContent() ) ) -297 { -298 String property = getPropertyFromExpression( fieldConfigurationElement.getTextContent() ); -299 append( sb, "User property: " + property, 3 ); -300 } -301 -302 append( sb, "", 0 ); -303 } -304 -305 /** -306 * <p>Repeat a String <code>n</code> times to form a new string.</p> -307 * -308 * @param str String to repeat -309 * @param repeat number of times to repeat str -310 * @return String with repeated String -311 * @throws NegativeArraySizeException if <code>repeat < 0</code> -312 * @throws NullPointerException if str is <code>null</code> -313 */ -314 private static String repeat( String str, int repeat ) -315 { -316 StringBuilder buffer = new StringBuilder( repeat * str.length() ); -317 -318 for ( int i = 0; i < repeat; i++ ) -319 { -320 buffer.append( str ); -321 } -322 -323 return buffer.toString(); -324 } -325 -326 /** -327 * Append a description to the buffer by respecting the indentSize and lineLength parameters. -328 * <b>Note</b>: The last character is always a new line. -329 * -330 * @param sb The buffer to append the description, not <code>null</code>. -331 * @param description The description, not <code>null</code>. -332 * @param indent The base indentation level of each line, must not be negative. -333 */ -334 private void append( StringBuilder sb, String description, int indent ) -335 { -336 for ( String line : toLines( description, indent, indentSize, lineLength ) ) -337 { -338 sb.append( line ).append( '\n' ); -339 } -340 } -341 -342 /** -343 * Splits the specified text into lines of convenient display length. -344 * -345 * @param text The text to split into lines, must not be <code>null</code>. -346 * @param indent The base indentation level of each line, must not be negative. -347 * @param indentSize The size of each indentation, must not be negative. -348 * @param lineLength The length of the line, must not be negative. -349 * @return The sequence of display lines, never <code>null</code>. -350 * @throws NegativeArraySizeException if <code>indent < 0</code> -351 */ -352 private static List<String> toLines( String text, int indent, int indentSize, int lineLength ) -353 { -354 List<String> lines = new ArrayList<String>(); -355 -356 String ind = repeat( "\t", indent ); -357 -358 String[] plainLines = text.split( "(\r\n)|(\r)|(\n)" ); -359 -360 for ( String plainLine : plainLines ) -361 { -362 toLines( lines, ind + plainLine, indentSize, lineLength ); -363 } -364 -365 return lines; -366 } -367 -368 /** -369 * Adds the specified line to the output sequence, performing line wrapping if necessary. -370 * -371 * @param lines The sequence of display lines, must not be <code>null</code>. -372 * @param line The line to add, must not be <code>null</code>. -373 * @param indentSize The size of each indentation, must not be negative. -374 * @param lineLength The length of the line, must not be negative. -375 */ -376 private static void toLines( List<String> lines, String line, int indentSize, int lineLength ) -377 { -378 int lineIndent = getIndentLevel( line ); -379 StringBuilder buf = new StringBuilder( 256 ); -380 -381 String[] tokens = line.split( " +" ); -382 -383 for ( String token : tokens ) -384 { -385 if ( buf.length() > 0 ) -386 { -387 if ( buf.length() + token.length() >= lineLength ) -388 { -389 lines.add( buf.toString() ); -390 buf.setLength( 0 ); -391 buf.append( repeat( " ", lineIndent * indentSize ) ); -392 } -393 else -394 { -395 buf.append( ' ' ); -396 } -397 } -398 -399 for ( int j = 0; j < token.length(); j++ ) -400 { -401 char c = token.charAt( j ); -402 if ( c == '\t' ) -403 { -404 buf.append( repeat( " ", indentSize - buf.length() % indentSize ) ); -405 } -406 else if ( c == '\u00A0' ) -407 { -408 buf.append( ' ' ); -409 } -410 else -411 { -412 buf.append( c ); -413 } -414 } -415 } -416 lines.add( buf.toString() ); -417 } -418 -419 /** -420 * Gets the indentation level of the specified line. -421 * -422 * @param line The line whose indentation level should be retrieved, must not be <code>null</code>. -423 * @return The indentation level of the line. -424 */ -425 private static int getIndentLevel( String line ) -426 { -427 int level = 0; -428 for ( int i = 0; i < line.length() && line.charAt( i ) == '\t'; i++ ) -429 { -430 level++; -431 } -432 for ( int i = level + 1; i <= level + 4 && i < line.length(); i++ ) -433 { -434 if ( line.charAt( i ) == '\t' ) -435 { -436 level++; -437 break; -438 } -439 } -440 return level; -441 } -442 -443 private String getPropertyFromExpression( String expression ) -444 { -445 if ( expression != null && expression.startsWith( "${" ) && expression.endsWith( "}" ) -446 && !expression.substring( 2 ).contains( "${" ) ) -447 { -448 // expression="${xxx}" -> property="xxx" -449 return expression.substring( 2, expression.length() - 1 ); -450 } -451 // no property can be extracted -452 return null; -453 } -454 } --
-1 package de.juplo.plugins.hibernate4; -2 -3 import javax.validation.Validation; -4 -5 import org.hibernate.cfg.Configuration; -6 import org.hibernate.cfg.beanvalidation.TypeSafeActivatorAccessor; -7 import org.hibernate.dialect.Dialect; -8 import org.hibernate.metamodel.source.MappingException; -9 -10 -11 /** -12 * This integration is usually performed by BeanValidationIntegrator. -13 * Unfortunately, that integration will only be activated upon -14 * initialization of the ServiceRegistry, which initializes -15 * DatasourceConnectionProviderImpl, which looks up the datasource, -16 * which requires a JNDI context ... -17 * We therefore reimplement the relevant parts of BeanValidatorIntegrator. -18 * Since that must occur after secondPassCompile(), which is invoked by -19 * Configuration.generateSchemaCreationScript, which is invoked by -20 * SchemaExport, some fancy subclassing is needed to invoke the integration -21 * at the right time. -22 * @author Mark Robinson <mark@mrobinson.ca> -23 * @author Frank Schimmel <frank.schimmel@cm4all.com> -24 */ -25 public class ValidationConfiguration extends Configuration -26 { -27 private static final long serialVersionUID = 1L; -28 -29 -30 @Override -31 protected void secondPassCompile() throws MappingException -32 { -33 super.secondPassCompile(); -34 -35 try -36 { -37 TypeSafeActivatorAccessor.applyRelationalConstraints( -38 Validation.buildDefaultValidatorFactory(), -39 classes.values(), -40 getProperties(), -41 ((Class<Dialect>)Class.forName(getProperty(Hbm2DdlMojo.DIALECT))).newInstance() -42 ); -43 } -44 catch (Exception e) -45 { -46 throw new RuntimeException(e); -47 } -48 } -49 -50 public String getTypeDefs() -51 { -52 return typeDefs.entrySet().toString(); -53 } -54 } --
Class Summary | -
---|
- DriverProxy - | -
- Hbm2DdlMojo - | -
- HelpMojo - | -
- MavenProjectClassLoaderService - | -
- ValidationConfiguration - | -
- You don't have frames. Go here -
- --1 package org.hibernate.cfg.beanvalidation; -2 -3 /** -4 * This class enables access to the public methods of {@link TypeSafeActivator} -5 * which itself is visible in the package only. -6 * -7 * @author Frank Schimmel <frank.schimmel@cm4all.com> -8 */ -9 public class TypeSafeActivatorAccessor extends TypeSafeActivator { -10 // Empty: just makes public methods accessible. -11 } --
Class Summary | -
---|
- TypeSafeActivatorAccessor - | -
Packages | -
---|
- de.juplo.plugins.hibernate4 - | -
- org.hibernate.cfg.beanvalidation - | -
Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/apidocs/deprecated-list.html b/dist/scannotation-1.0.4/apidocs/deprecated-list.html deleted file mode 100644 index 3c0ff0c6..00000000 --- a/dist/scannotation-1.0.4/apidocs/deprecated-list.html +++ /dev/null @@ -1,117 +0,0 @@ - - - - - - -Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/apidocs/help-doc.html b/dist/scannotation-1.0.4/apidocs/help-doc.html deleted file mode 100644 index 3c496718..00000000 --- a/dist/scannotation-1.0.4/apidocs/help-doc.html +++ /dev/null @@ -1,222 +0,0 @@ - - - - - - -The Overview page is the front page of this API document and provides a list of all packages with a summary for each. This page can also contain an overall description of the set of packages.
-Each package has a page that contains a list of its classes and interfaces, with a summary for each. This page can contain six categories:
-Each class, interface, nested class and nested interface has its own separate page. Each of these pages has three sections consisting of a class/interface description, summary tables, and detailed member descriptions:
-Each summary entry contains the first sentence from the detailed description for that item. The summary entries are alphabetical, while the detailed descriptions are in the order they appear in the source code. This preserves the logical groupings established by the programmer.
-Each annotation type has its own separate page with the following sections:
-Each enum has its own separate page with the following sections:
-Each documented package, class and interface has its own Use page. This page describes what packages, classes, methods, constructors and fields use any part of the given class or package. Given a class or interface A, its Use page includes subclasses of A, fields declared as A, methods that return A, and methods and constructors with parameters of type A. You can access this page by first going to the package, class or interface, then clicking on the "Use" link in the navigation bar.
-There is a Class Hierarchy page for all packages, plus a hierarchy for each package. Each hierarchy page contains a list of classes and a list of interfaces. The classes are organized by inheritance structure starting with java.lang.Object
. The interfaces do not inherit from java.lang.Object
.
The Deprecated API page lists all of the API that have been deprecated. A deprecated API is not recommended for use, generally due to improvements, and a replacement API is usually given. Deprecated APIs may be removed in future implementations.
-The Index contains an alphabetic list of all classes, interfaces, constructors, methods, and fields.
-These links take you to the next or previous class, interface, package, or related page.
-These links show and hide the HTML frames. All pages are available with or without frames.
-The All Classes link shows all classes and interfaces except non-static nested types.
-Each serializable or externalizable class has a description of its serialization fields and methods. This information is of interest to re-implementors, not to developers using the API. While there is no link in the navigation bar, you can get to this information by going to any serialized class and clicking "Serialized Form" in the "See also" section of the class description.
-The Constant Field Values page lists the static final fields and their values.
-Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/apidocs/index-all.html b/dist/scannotation-1.0.4/apidocs/index-all.html deleted file mode 100644 index 915a7e3e..00000000 --- a/dist/scannotation-1.0.4/apidocs/index-all.html +++ /dev/null @@ -1,438 +0,0 @@ - - - - - - -Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/apidocs/index.html b/dist/scannotation-1.0.4/apidocs/index.html deleted file mode 100644 index ad7a3697..00000000 --- a/dist/scannotation-1.0.4/apidocs/index.html +++ /dev/null @@ -1,75 +0,0 @@ - - - - - - -This document is designed to be viewed using the frames feature. If you see this message, you are using a non-frame-capable web client. Link to Non-frame version.
-public class AnnotationDB.CrossReferenceException -extends Exception-
Constructor and Description | -
---|
AnnotationDB.CrossReferenceException(Set<String> unresolved) |
-
Modifier and Type | -Method and Description | -
---|---|
Set<String> |
-getUnresolved() |
-
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/apidocs/org/scannotation/AnnotationDB.html b/dist/scannotation-1.0.4/apidocs/org/scannotation/AnnotationDB.html deleted file mode 100644 index 93a2e777..00000000 --- a/dist/scannotation-1.0.4/apidocs/org/scannotation/AnnotationDB.html +++ /dev/null @@ -1,792 +0,0 @@ - - - - - - -public class AnnotationDB -extends Object -implements Serializable-
Modifier and Type | -Class and Description | -
---|---|
class |
-AnnotationDB.CrossReferenceException |
-
Modifier and Type | -Field and Description | -
---|---|
protected Map<String,Set<String>> |
-annotationIndex |
-
protected Map<String,Set<String>> |
-classIndex |
-
protected boolean |
-ignoreBadURLs |
-
protected String[] |
-ignoredPackages |
-
protected Map<String,Set<String>> |
-implementsIndex |
-
protected boolean |
-scanClassAnnotations |
-
protected boolean |
-scanFieldAnnotations |
-
protected boolean |
-scanMethodAnnotations |
-
protected String[] |
-scanPackages |
-
protected boolean |
-scanParameterAnnotations |
-
Constructor and Description | -
---|
AnnotationDB() |
-
Modifier and Type | -Method and Description | -
---|---|
void |
-addIgnoredPackages(String... ignored) |
-
void |
-crossReferenceImplementedInterfaces()
-Sometimes you want to see if a particular class implements an interface with certain annotations
- After you have loaded all your classpaths with the scanArchive() method, call this method to cross reference
- a class's implemented interfaces.
- |
-
void |
-crossReferenceMetaAnnotations()
-This method will cross reference annotations in the annotation index with any meta-annotations that they have
- and create additional entries as needed.
- |
-
Map<String,Set<String>> |
-getAnnotationIndex()
-returns a map keyed by the fully qualified string name of a annotation class.
- |
-
Map<String,Set<String>> |
-getClassIndex()
-returns a map keyed by the list of classes scanned.
- |
-
String[] |
-getIgnoredPackages() |
-
String[] |
-getScanPackages() |
-
void |
-outputAnnotationIndex(PrintWriter writer)
-Prints out annotationIndex
- |
-
protected void |
-populate(javassist.bytecode.annotation.Annotation[] annotations,
- String className) |
-
void |
-scanArchives(URL... urls)
-Scan a url that represents an "archive" this is a classpath directory or jar file
- |
-
protected void |
-scanClass(javassist.bytecode.ClassFile cf) |
-
void |
-scanClass(InputStream bits)
-Parse a .class file for annotations
- |
-
protected void |
-scanFields(javassist.bytecode.ClassFile cf) |
-
protected void |
-scanMethods(javassist.bytecode.ClassFile cf)
-Scanns both the method and its parameters for annotations.
- |
-
void |
-setIgnoreBadURLs(boolean ignoreBadURLs)
-Whether or not you want AnnotationDB to ignore bad URLs passed to scanArchives.
- |
-
void |
-setIgnoredPackages(String[] ignoredPackages)
-Override/overwrite any ignored packages
- |
-
void |
-setScanClassAnnotations(boolean scanClassAnnotations)
-Whether or not you want AnnotationDB to scan for class level annotations
- |
-
void |
-setScanFieldAnnotations(boolean scanFieldAnnotations)
-Whether or not you want AnnotationDB to scan for parameter level annotations
- |
-
void |
-setScanMethodAnnotations(boolean scanMethodAnnotations)
-Wheter or not you want AnnotationDB to scan for method level annotations
- |
-
void |
-setScanPackages(String[] scanPackages)
-Set explicit packages to scan.
- |
-
void |
-setScanParameterAnnotations(boolean scanParameterAnnotations)
-Whether or not you want AnnotationDB to scan for parameter level annotations
- |
-
protected transient boolean scanClassAnnotations-
protected transient boolean scanMethodAnnotations-
protected transient boolean scanParameterAnnotations-
protected transient boolean scanFieldAnnotations-
protected transient String[] ignoredPackages-
protected transient String[] scanPackages-
protected transient boolean ignoreBadURLs-
public String[] getScanPackages()-
public void setScanPackages(String[] scanPackages)-
scanPackages
- packages to scan or nullpublic String[] getIgnoredPackages()-
public void setIgnoredPackages(String[] ignoredPackages)-
ignoredPackages
- cannot be nullpublic void addIgnoredPackages(String... ignored)-
public void crossReferenceMetaAnnotations() - throws AnnotationDB.CrossReferenceException-
AnnotationDB.CrossReferenceException
public void crossReferenceImplementedInterfaces() - throws AnnotationDB.CrossReferenceException-
AnnotationDB.CrossReferenceException
- an Exception thrown if referenced interfaces haven't been scannedpublic Map<String,Set<String>> getAnnotationIndex()-
public Map<String,Set<String>> getClassIndex()-
public void setScanClassAnnotations(boolean scanClassAnnotations)-
scanClassAnnotations
- public void setScanMethodAnnotations(boolean scanMethodAnnotations)-
scanMethodAnnotations
- public void setScanParameterAnnotations(boolean scanParameterAnnotations)-
scanParameterAnnotations
- public void setScanFieldAnnotations(boolean scanFieldAnnotations)-
scanFieldAnnotations
- public void setIgnoreBadURLs(boolean ignoreBadURLs)-
ignoreBadURLs
- public void scanArchives(URL... urls) - throws IOException-
urls
- variable list of URLs to scan as archivesIOException
public void scanClass(InputStream bits) - throws IOException-
bits
- input stream pointing to .class file bitsIOException
protected void scanClass(javassist.bytecode.ClassFile cf)-
protected void scanMethods(javassist.bytecode.ClassFile cf)-
cf
- protected void scanFields(javassist.bytecode.ClassFile cf)-
protected void populate(javassist.bytecode.annotation.Annotation[] annotations, - String className)-
public void outputAnnotationIndex(PrintWriter writer)-
writer
- Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/apidocs/org/scannotation/ClasspathUrlFinder.html b/dist/scannotation-1.0.4/apidocs/org/scannotation/ClasspathUrlFinder.html deleted file mode 100644 index 7f7f40c5..00000000 --- a/dist/scannotation-1.0.4/apidocs/org/scannotation/ClasspathUrlFinder.html +++ /dev/null @@ -1,387 +0,0 @@ - - - - - - -public class ClasspathUrlFinder -extends Object-
Constructor and Description | -
---|
ClasspathUrlFinder() |
-
Modifier and Type | -Method and Description | -
---|---|
static URL |
-findClassBase(Class clazz)
-Find the classpath for the particular class
- |
-
static URL[] |
-findClassPaths()
-Uses the java.class.path system property to obtain a list of URLs that represent the CLASSPATH
- |
-
static URL[] |
-findClassPaths(String... paths)
-Uses the java.class.path system property to obtain a list of URLs that represent the CLASSPATH
-
- paths is used as a filter to only include paths that have the specific relative file within it
- |
-
static URL |
-findResourceBase(String baseResource)
-Find the classpath URL for a specific classpath resource.
- |
-
static URL |
-findResourceBase(String baseResource,
- ClassLoader loader)
-Find the classpath URL for a specific classpath resource.
- |
-
static URL[] |
-findResourceBases(String baseResource)
-Find the classpath URLs for a specific classpath resource.
- |
-
static URL[] |
-findResourceBases(String baseResource,
- ClassLoader loader)
-Find the classpath URLs for a specific classpath resource.
- |
-
public static URL[] findResourceBases(String baseResource, - ClassLoader loader)-
baseResource
- public static URL[] findResourceBases(String baseResource)-
baseResource
- public static URL findResourceBase(String baseResource)-
baseResource
- public static URL findResourceBase(String baseResource, - ClassLoader loader)-
baseResource
- loader
- public static URL findClassBase(Class clazz)-
clazz
- public static URL[] findClassPaths()-
public static URL[] findClassPaths(String... paths)-
paths
- comma list of files that should exist in a particular pathCopyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/apidocs/org/scannotation/WarUrlFinder.html b/dist/scannotation-1.0.4/apidocs/org/scannotation/WarUrlFinder.html deleted file mode 100644 index c2f34297..00000000 --- a/dist/scannotation-1.0.4/apidocs/org/scannotation/WarUrlFinder.html +++ /dev/null @@ -1,308 +0,0 @@ - - - - - - -public class WarUrlFinder -extends Object-
Constructor and Description | -
---|
WarUrlFinder() |
-
Modifier and Type | -Method and Description | -
---|---|
static URL |
-findWebInfClassesPath(javax.servlet.ServletContext servletContext)
-Find the URL pointing to "/WEB-INF/classes" This method may not work in conjunction with IteratorFactory
- if your servlet container does not extract the /WEB-INF/classes into a real file-based directory
- |
-
static URL |
-findWebInfClassesPath(javax.servlet.ServletContextEvent servletContextEvent) |
-
static URL[] |
-findWebInfLibClasspaths(javax.servlet.ServletContext servletContext) |
-
static URL[] |
-findWebInfLibClasspaths(javax.servlet.ServletContextEvent servletContextEvent) |
-
public static URL[] findWebInfLibClasspaths(javax.servlet.ServletContextEvent servletContextEvent)-
public static URL[] findWebInfLibClasspaths(javax.servlet.ServletContext servletContext)-
public static URL findWebInfClassesPath(javax.servlet.ServletContextEvent servletContextEvent)-
public static URL findWebInfClassesPath(javax.servlet.ServletContext servletContext)-
servletContext
- Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/DirectoryIteratorFactory.html b/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/DirectoryIteratorFactory.html deleted file mode 100644 index 8a0f28c5..00000000 --- a/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/DirectoryIteratorFactory.html +++ /dev/null @@ -1,221 +0,0 @@ - - - - - - -public interface DirectoryIteratorFactory
-Modifier and Type | -Method and Description | -
---|---|
StreamIterator |
-create(URL url,
- Filter filter) |
-
StreamIterator create(URL url, - Filter filter) - throws IOException-
IOException
Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/FileIterator.html b/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/FileIterator.html deleted file mode 100644 index 078fd96e..00000000 --- a/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/FileIterator.html +++ /dev/null @@ -1,340 +0,0 @@ - - - - - - -public class FileIterator -extends Object -implements StreamIterator-
Constructor and Description | -
---|
FileIterator(File file,
- Filter filter) |
-
Modifier and Type | -Method and Description | -
---|---|
void |
-close()
-Cleanup any open resources of the iterator
- |
-
protected static void |
-create(List list,
- File dir,
- Filter filter) |
-
protected static void |
-create(List list,
- File dir,
- Filter filter,
- String prefix) |
-
InputStream |
-next()
-User is resposible for closing the InputStream returned
- |
-
protected static void create(List list, - File dir, - Filter filter) - throws Exception-
Exception
protected static void create(List list, - File dir, - Filter filter, - String prefix) - throws Exception-
Exception
public InputStream next()-
StreamIterator
next
in interface StreamIterator
public void close()-
StreamIterator
close
in interface StreamIterator
Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/FileProtocolIteratorFactory.html b/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/FileProtocolIteratorFactory.html deleted file mode 100644 index e30238cf..00000000 --- a/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/FileProtocolIteratorFactory.html +++ /dev/null @@ -1,275 +0,0 @@ - - - - - - -public class FileProtocolIteratorFactory -extends Object -implements DirectoryIteratorFactory-
Constructor and Description | -
---|
FileProtocolIteratorFactory() |
-
public FileProtocolIteratorFactory()-
public StreamIterator create(URL url, - Filter filter) - throws IOException-
create
in interface DirectoryIteratorFactory
IOException
Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/Filter.html b/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/Filter.html deleted file mode 100644 index 42d35ca0..00000000 --- a/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/Filter.html +++ /dev/null @@ -1,212 +0,0 @@ - - - - - - -public interface Filter
-Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/InputStreamWrapper.html b/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/InputStreamWrapper.html deleted file mode 100644 index 05542127..00000000 --- a/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/InputStreamWrapper.html +++ /dev/null @@ -1,434 +0,0 @@ - - - - - - -public class InputStreamWrapper -extends InputStream-
Constructor and Description | -
---|
InputStreamWrapper(InputStream delegate) |
-
Modifier and Type | -Method and Description | -
---|---|
int |
-available() |
-
void |
-close() |
-
void |
-mark(int i) |
-
boolean |
-markSupported() |
-
int |
-read() |
-
int |
-read(byte[] bytes) |
-
int |
-read(byte[] bytes,
- int i,
- int i1) |
-
void |
-reset() |
-
long |
-skip(long l) |
-
public InputStreamWrapper(InputStream delegate)-
public int read() - throws IOException-
read
in class InputStream
IOException
public int read(byte[] bytes) - throws IOException-
read
in class InputStream
IOException
public int read(byte[] bytes, - int i, - int i1) - throws IOException-
read
in class InputStream
IOException
public long skip(long l) - throws IOException-
skip
in class InputStream
IOException
public int available() - throws IOException-
available
in class InputStream
IOException
public void close() - throws IOException-
close
in interface Closeable
close
in interface AutoCloseable
close
in class InputStream
IOException
public void mark(int i)-
mark
in class InputStream
public void reset() - throws IOException-
reset
in class InputStream
IOException
public boolean markSupported()-
markSupported
in class InputStream
Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/IteratorFactory.html b/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/IteratorFactory.html deleted file mode 100644 index 44cbe572..00000000 --- a/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/IteratorFactory.html +++ /dev/null @@ -1,267 +0,0 @@ - - - - - - -public class IteratorFactory -extends Object-
Constructor and Description | -
---|
IteratorFactory() |
-
public static StreamIterator create(URL url, - Filter filter) - throws IOException-
IOException
Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/JarIterator.html b/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/JarIterator.html deleted file mode 100644 index 10cc918b..00000000 --- a/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/JarIterator.html +++ /dev/null @@ -1,318 +0,0 @@ - - - - - - -public class JarIterator -extends Object -implements StreamIterator-
Constructor and Description | -
---|
JarIterator(File file,
- Filter filter) |
-
JarIterator(InputStream is,
- Filter filter) |
-
Modifier and Type | -Method and Description | -
---|---|
void |
-close()
-Cleanup any open resources of the iterator
- |
-
InputStream |
-next()
-User is resposible for closing the InputStream returned
- |
-
public JarIterator(File file, - Filter filter) - throws IOException-
IOException
public JarIterator(InputStream is, - Filter filter) - throws IOException-
IOException
public InputStream next()-
StreamIterator
next
in interface StreamIterator
public void close()-
StreamIterator
close
in interface StreamIterator
Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/StreamIterator.html b/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/StreamIterator.html deleted file mode 100644 index 07689ee2..00000000 --- a/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/StreamIterator.html +++ /dev/null @@ -1,237 +0,0 @@ - - - - - - -public interface StreamIterator
-Modifier and Type | -Method and Description | -
---|---|
void |
-close()
-Cleanup any open resources of the iterator
- |
-
InputStream |
-next()
-User is resposible for closing the InputStream returned
- |
-
InputStream next()-
void close()-
Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/class-use/DirectoryIteratorFactory.html b/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/class-use/DirectoryIteratorFactory.html deleted file mode 100644 index 9c93f3bc..00000000 --- a/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/class-use/DirectoryIteratorFactory.html +++ /dev/null @@ -1,157 +0,0 @@ - - - - - - -Package | -Description | -
---|---|
org.scannotation.archiveiterator | -- |
Modifier and Type | -Class and Description | -
---|---|
class |
-FileProtocolIteratorFactory |
-
Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/class-use/FileIterator.html b/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/class-use/FileIterator.html deleted file mode 100644 index fa843736..00000000 --- a/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/class-use/FileIterator.html +++ /dev/null @@ -1,117 +0,0 @@ - - - - - - -Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/class-use/FileProtocolIteratorFactory.html b/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/class-use/FileProtocolIteratorFactory.html deleted file mode 100644 index f4faf8c5..00000000 --- a/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/class-use/FileProtocolIteratorFactory.html +++ /dev/null @@ -1,117 +0,0 @@ - - - - - - -Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/class-use/Filter.html b/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/class-use/Filter.html deleted file mode 100644 index 9a99be73..00000000 --- a/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/class-use/Filter.html +++ /dev/null @@ -1,201 +0,0 @@ - - - - - - -Package | -Description | -
---|---|
org.scannotation.archiveiterator | -- |
Modifier and Type | -Method and Description | -
---|---|
protected static void |
-FileIterator.create(List list,
- File dir,
- Filter filter) |
-
protected static void |
-FileIterator.create(List list,
- File dir,
- Filter filter,
- String prefix) |
-
StreamIterator |
-FileProtocolIteratorFactory.create(URL url,
- Filter filter) |
-
static StreamIterator |
-IteratorFactory.create(URL url,
- Filter filter) |
-
StreamIterator |
-DirectoryIteratorFactory.create(URL url,
- Filter filter) |
-
Constructor and Description | -
---|
FileIterator(File file,
- Filter filter) |
-
JarIterator(File file,
- Filter filter) |
-
JarIterator(InputStream is,
- Filter filter) |
-
Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/class-use/InputStreamWrapper.html b/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/class-use/InputStreamWrapper.html deleted file mode 100644 index 3ffedd87..00000000 --- a/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/class-use/InputStreamWrapper.html +++ /dev/null @@ -1,117 +0,0 @@ - - - - - - -Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/class-use/IteratorFactory.html b/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/class-use/IteratorFactory.html deleted file mode 100644 index c8e5cfad..00000000 --- a/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/class-use/IteratorFactory.html +++ /dev/null @@ -1,117 +0,0 @@ - - - - - - -Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/class-use/JarIterator.html b/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/class-use/JarIterator.html deleted file mode 100644 index ddbcb453..00000000 --- a/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/class-use/JarIterator.html +++ /dev/null @@ -1,117 +0,0 @@ - - - - - - -Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/class-use/StreamIterator.html b/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/class-use/StreamIterator.html deleted file mode 100644 index 1fc290d3..00000000 --- a/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/class-use/StreamIterator.html +++ /dev/null @@ -1,185 +0,0 @@ - - - - - - -Package | -Description | -
---|---|
org.scannotation.archiveiterator | -- |
Modifier and Type | -Class and Description | -
---|---|
class |
-FileIterator |
-
class |
-JarIterator |
-
Modifier and Type | -Method and Description | -
---|---|
StreamIterator |
-FileProtocolIteratorFactory.create(URL url,
- Filter filter) |
-
static StreamIterator |
-IteratorFactory.create(URL url,
- Filter filter) |
-
StreamIterator |
-DirectoryIteratorFactory.create(URL url,
- Filter filter) |
-
Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/package-frame.html b/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/package-frame.html deleted file mode 100644 index 18e6a3dd..00000000 --- a/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/package-frame.html +++ /dev/null @@ -1,30 +0,0 @@ - - - - - - -Interface | -Description | -
---|---|
DirectoryIteratorFactory | -- |
Filter | -- |
StreamIterator | -
- Simpler iterator than java.util.iterator.
- |
-
Class | -Description | -
---|---|
FileIterator | -- |
FileProtocolIteratorFactory | -- |
InputStreamWrapper | -
- Delegate to everything but close().
- |
-
IteratorFactory | -- |
JarIterator | -- |
Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/package-tree.html b/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/package-tree.html deleted file mode 100644 index c06e1367..00000000 --- a/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/package-tree.html +++ /dev/null @@ -1,144 +0,0 @@ - - - - - - -Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/package-use.html b/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/package-use.html deleted file mode 100644 index 97870ae1..00000000 --- a/dist/scannotation-1.0.4/apidocs/org/scannotation/archiveiterator/package-use.html +++ /dev/null @@ -1,158 +0,0 @@ - - - - - - -Package | -Description | -
---|---|
org.scannotation.archiveiterator | -- |
Class and Description | -
---|
DirectoryIteratorFactory | -
Filter | -
StreamIterator
- Simpler iterator than java.util.iterator.
- |
-
Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/apidocs/org/scannotation/class-use/AnnotationDB.CrossReferenceException.html b/dist/scannotation-1.0.4/apidocs/org/scannotation/class-use/AnnotationDB.CrossReferenceException.html deleted file mode 100644 index 85ee8fd6..00000000 --- a/dist/scannotation-1.0.4/apidocs/org/scannotation/class-use/AnnotationDB.CrossReferenceException.html +++ /dev/null @@ -1,168 +0,0 @@ - - - - - - -Package | -Description | -
---|---|
org.scannotation | -- |
Modifier and Type | -Method and Description | -
---|---|
void |
-AnnotationDB.crossReferenceImplementedInterfaces()
-Sometimes you want to see if a particular class implements an interface with certain annotations
- After you have loaded all your classpaths with the scanArchive() method, call this method to cross reference
- a class's implemented interfaces.
- |
-
void |
-AnnotationDB.crossReferenceMetaAnnotations()
-This method will cross reference annotations in the annotation index with any meta-annotations that they have
- and create additional entries as needed.
- |
-
Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/apidocs/org/scannotation/class-use/AnnotationDB.html b/dist/scannotation-1.0.4/apidocs/org/scannotation/class-use/AnnotationDB.html deleted file mode 100644 index 324fbb51..00000000 --- a/dist/scannotation-1.0.4/apidocs/org/scannotation/class-use/AnnotationDB.html +++ /dev/null @@ -1,117 +0,0 @@ - - - - - - -Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/apidocs/org/scannotation/class-use/ClasspathUrlFinder.html b/dist/scannotation-1.0.4/apidocs/org/scannotation/class-use/ClasspathUrlFinder.html deleted file mode 100644 index 903265e0..00000000 --- a/dist/scannotation-1.0.4/apidocs/org/scannotation/class-use/ClasspathUrlFinder.html +++ /dev/null @@ -1,117 +0,0 @@ - - - - - - -Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/apidocs/org/scannotation/class-use/WarUrlFinder.html b/dist/scannotation-1.0.4/apidocs/org/scannotation/class-use/WarUrlFinder.html deleted file mode 100644 index 6a0ff378..00000000 --- a/dist/scannotation-1.0.4/apidocs/org/scannotation/class-use/WarUrlFinder.html +++ /dev/null @@ -1,117 +0,0 @@ - - - - - - -Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/apidocs/org/scannotation/package-frame.html b/dist/scannotation-1.0.4/apidocs/org/scannotation/package-frame.html deleted file mode 100644 index b4130170..00000000 --- a/dist/scannotation-1.0.4/apidocs/org/scannotation/package-frame.html +++ /dev/null @@ -1,22 +0,0 @@ - - - - - - -Class | -Description | -
---|---|
AnnotationDB | -
- The class allows you to scan an arbitrary set of "archives" for .class files.
- |
-
ClasspathUrlFinder | -
- Various functions to locate URLs to scan
- |
-
WarUrlFinder | -- |
Exception | -Description | -
---|
Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/apidocs/org/scannotation/package-tree.html b/dist/scannotation-1.0.4/apidocs/org/scannotation/package-tree.html deleted file mode 100644 index 74c994d3..00000000 --- a/dist/scannotation-1.0.4/apidocs/org/scannotation/package-tree.html +++ /dev/null @@ -1,141 +0,0 @@ - - - - - - -Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/apidocs/org/scannotation/package-use.html b/dist/scannotation-1.0.4/apidocs/org/scannotation/package-use.html deleted file mode 100644 index e8834f45..00000000 --- a/dist/scannotation-1.0.4/apidocs/org/scannotation/package-use.html +++ /dev/null @@ -1,150 +0,0 @@ - - - - - - -Package | -Description | -
---|---|
org.scannotation | -- |
Class and Description | -
---|
AnnotationDB.CrossReferenceException | -
Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/apidocs/overview-frame.html b/dist/scannotation-1.0.4/apidocs/overview-frame.html deleted file mode 100644 index 604d7062..00000000 --- a/dist/scannotation-1.0.4/apidocs/overview-frame.html +++ /dev/null @@ -1,22 +0,0 @@ - - - - - - -- - diff --git a/dist/scannotation-1.0.4/apidocs/overview-summary.html b/dist/scannotation-1.0.4/apidocs/overview-summary.html deleted file mode 100644 index a00b8e06..00000000 --- a/dist/scannotation-1.0.4/apidocs/overview-summary.html +++ /dev/null @@ -1,135 +0,0 @@ - - - - - - -
Package | -Description | -
---|---|
org.scannotation | -- |
org.scannotation.archiveiterator | -- |
Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/apidocs/overview-tree.html b/dist/scannotation-1.0.4/apidocs/overview-tree.html deleted file mode 100644 index 7cb550d5..00000000 --- a/dist/scannotation-1.0.4/apidocs/overview-tree.html +++ /dev/null @@ -1,157 +0,0 @@ - - - - - - -Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/apidocs/package-list b/dist/scannotation-1.0.4/apidocs/package-list deleted file mode 100644 index 993afc24..00000000 --- a/dist/scannotation-1.0.4/apidocs/package-list +++ /dev/null @@ -1,2 +0,0 @@ -org.scannotation -org.scannotation.archiveiterator diff --git a/dist/scannotation-1.0.4/apidocs/packages b/dist/scannotation-1.0.4/apidocs/packages deleted file mode 100644 index aa099e10..00000000 --- a/dist/scannotation-1.0.4/apidocs/packages +++ /dev/null @@ -1,2 +0,0 @@ -org.scannotation -org.scannotation.archiveiterator \ No newline at end of file diff --git a/dist/scannotation-1.0.4/apidocs/resources/background.gif b/dist/scannotation-1.0.4/apidocs/resources/background.gif deleted file mode 100644 index f471940f..00000000 Binary files a/dist/scannotation-1.0.4/apidocs/resources/background.gif and /dev/null differ diff --git a/dist/scannotation-1.0.4/apidocs/resources/tab.gif b/dist/scannotation-1.0.4/apidocs/resources/tab.gif deleted file mode 100644 index 1a73a83b..00000000 Binary files a/dist/scannotation-1.0.4/apidocs/resources/tab.gif and /dev/null differ diff --git a/dist/scannotation-1.0.4/apidocs/resources/titlebar.gif b/dist/scannotation-1.0.4/apidocs/resources/titlebar.gif deleted file mode 100644 index 17443b3e..00000000 Binary files a/dist/scannotation-1.0.4/apidocs/resources/titlebar.gif and /dev/null differ diff --git a/dist/scannotation-1.0.4/apidocs/resources/titlebar_end.gif b/dist/scannotation-1.0.4/apidocs/resources/titlebar_end.gif deleted file mode 100644 index 3ad78d46..00000000 Binary files a/dist/scannotation-1.0.4/apidocs/resources/titlebar_end.gif and /dev/null differ diff --git a/dist/scannotation-1.0.4/apidocs/serialized-form.html b/dist/scannotation-1.0.4/apidocs/serialized-form.html deleted file mode 100644 index 26a875ca..00000000 --- a/dist/scannotation-1.0.4/apidocs/serialized-form.html +++ /dev/null @@ -1,169 +0,0 @@ - - - - - - -Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/apidocs/stylesheet.css b/dist/scannotation-1.0.4/apidocs/stylesheet.css deleted file mode 100644 index 0aeaa97f..00000000 --- a/dist/scannotation-1.0.4/apidocs/stylesheet.css +++ /dev/null @@ -1,474 +0,0 @@ -/* Javadoc style sheet */ -/* -Overall document style -*/ -body { - background-color:#ffffff; - color:#353833; - font-family:Arial, Helvetica, sans-serif; - font-size:76%; - margin:0; -} -a:link, a:visited { - text-decoration:none; - color:#4c6b87; -} -a:hover, a:focus { - text-decoration:none; - color:#bb7a2a; -} -a:active { - text-decoration:none; - color:#4c6b87; -} -a[name] { - color:#353833; -} -a[name]:hover { - text-decoration:none; - color:#353833; -} -pre { - font-size:1.3em; -} -h1 { - font-size:1.8em; -} -h2 { - font-size:1.5em; -} -h3 { - font-size:1.4em; -} -h4 { - font-size:1.3em; -} -h5 { - font-size:1.2em; -} -h6 { - font-size:1.1em; -} -ul { - list-style-type:disc; -} -code, tt { - font-size:1.2em; -} -dt code { - font-size:1.2em; -} -table tr td dt code { - font-size:1.2em; - vertical-align:top; -} -sup { - font-size:.6em; -} -/* -Document title and Copyright styles -*/ -.clear { - clear:both; - height:0px; - overflow:hidden; -} -.aboutLanguage { - float:right; - padding:0px 21px; - font-size:.8em; - z-index:200; - margin-top:-7px; -} -.legalCopy { - margin-left:.5em; -} -.bar a, .bar a:link, .bar a:visited, .bar a:active { - color:#FFFFFF; - text-decoration:none; -} -.bar a:hover, .bar a:focus { - color:#bb7a2a; -} -.tab { - background-color:#0066FF; - background-image:url(resources/titlebar.gif); - background-position:left top; - background-repeat:no-repeat; - color:#ffffff; - padding:8px; - width:5em; - font-weight:bold; -} -/* -Navigation bar styles -*/ -.bar { - background-image:url(resources/background.gif); - background-repeat:repeat-x; - color:#FFFFFF; - padding:.8em .5em .4em .8em; - height:auto;/*height:1.8em;*/ - font-size:1em; - margin:0; -} -.topNav { - background-image:url(resources/background.gif); - background-repeat:repeat-x; - color:#FFFFFF; - float:left; - padding:0; - width:100%; - clear:right; - height:2.8em; - padding-top:10px; - overflow:hidden; -} -.bottomNav { - margin-top:10px; - background-image:url(resources/background.gif); - background-repeat:repeat-x; - color:#FFFFFF; - float:left; - padding:0; - width:100%; - clear:right; - height:2.8em; - padding-top:10px; - overflow:hidden; -} -.subNav { - background-color:#dee3e9; - border-bottom:1px solid #9eadc0; - float:left; - width:100%; - overflow:hidden; -} -.subNav div { - clear:left; - float:left; - padding:0 0 5px 6px; -} -ul.navList, ul.subNavList { - float:left; - margin:0 25px 0 0; - padding:0; -} -ul.navList li{ - list-style:none; - float:left; - padding:3px 6px; -} -ul.subNavList li{ - list-style:none; - float:left; - font-size:90%; -} -.topNav a:link, .topNav a:active, .topNav a:visited, .bottomNav a:link, .bottomNav a:active, .bottomNav a:visited { - color:#FFFFFF; - text-decoration:none; -} -.topNav a:hover, .bottomNav a:hover { - text-decoration:none; - color:#bb7a2a; -} -.navBarCell1Rev { - background-image:url(resources/tab.gif); - background-color:#a88834; - color:#FFFFFF; - margin: auto 5px; - border:1px solid #c9aa44; -} -/* -Page header and footer styles -*/ -.header, .footer { - clear:both; - margin:0 20px; - padding:5px 0 0 0; -} -.indexHeader { - margin:10px; - position:relative; -} -.indexHeader h1 { - font-size:1.3em; -} -.title { - color:#2c4557; - margin:10px 0; -} -.subTitle { - margin:5px 0 0 0; -} -.header ul { - margin:0 0 25px 0; - padding:0; -} -.footer ul { - margin:20px 0 5px 0; -} -.header ul li, .footer ul li { - list-style:none; - font-size:1.2em; -} -/* -Heading styles -*/ -div.details ul.blockList ul.blockList ul.blockList li.blockList h4, div.details ul.blockList ul.blockList ul.blockListLast li.blockList h4 { - background-color:#dee3e9; - border-top:1px solid #9eadc0; - border-bottom:1px solid #9eadc0; - margin:0 0 6px -8px; - padding:2px 5px; -} -ul.blockList ul.blockList ul.blockList li.blockList h3 { - background-color:#dee3e9; - border-top:1px solid #9eadc0; - border-bottom:1px solid #9eadc0; - margin:0 0 6px -8px; - padding:2px 5px; -} -ul.blockList ul.blockList li.blockList h3 { - padding:0; - margin:15px 0; -} -ul.blockList li.blockList h2 { - padding:0px 0 20px 0; -} -/* -Page layout container styles -*/ -.contentContainer, .sourceContainer, .classUseContainer, .serializedFormContainer, .constantValuesContainer { - clear:both; - padding:10px 20px; - position:relative; -} -.indexContainer { - margin:10px; - position:relative; - font-size:1.0em; -} -.indexContainer h2 { - font-size:1.1em; - padding:0 0 3px 0; -} -.indexContainer ul { - margin:0; - padding:0; -} -.indexContainer ul li { - list-style:none; -} -.contentContainer .description dl dt, .contentContainer .details dl dt, .serializedFormContainer dl dt { - font-size:1.1em; - font-weight:bold; - margin:10px 0 0 0; - color:#4E4E4E; -} -.contentContainer .description dl dd, .contentContainer .details dl dd, .serializedFormContainer dl dd { - margin:10px 0 10px 20px; -} -.serializedFormContainer dl.nameValue dt { - margin-left:1px; - font-size:1.1em; - display:inline; - font-weight:bold; -} -.serializedFormContainer dl.nameValue dd { - margin:0 0 0 1px; - font-size:1.1em; - display:inline; -} -/* -List styles -*/ -ul.horizontal li { - display:inline; - font-size:0.9em; -} -ul.inheritance { - margin:0; - padding:0; -} -ul.inheritance li { - display:inline; - list-style:none; -} -ul.inheritance li ul.inheritance { - margin-left:15px; - padding-left:15px; - padding-top:1px; -} -ul.blockList, ul.blockListLast { - margin:10px 0 10px 0; - padding:0; -} -ul.blockList li.blockList, ul.blockListLast li.blockList { - list-style:none; - margin-bottom:25px; -} -ul.blockList ul.blockList li.blockList, ul.blockList ul.blockListLast li.blockList { - padding:0px 20px 5px 10px; - border:1px solid #9eadc0; - background-color:#f9f9f9; -} -ul.blockList ul.blockList ul.blockList li.blockList, ul.blockList ul.blockList ul.blockListLast li.blockList { - padding:0 0 5px 8px; - background-color:#ffffff; - border:1px solid #9eadc0; - border-top:none; -} -ul.blockList ul.blockList ul.blockList ul.blockList li.blockList { - margin-left:0; - padding-left:0; - padding-bottom:15px; - border:none; - border-bottom:1px solid #9eadc0; -} -ul.blockList ul.blockList ul.blockList ul.blockList li.blockListLast { - list-style:none; - border-bottom:none; - padding-bottom:0; -} -table tr td dl, table tr td dl dt, table tr td dl dd { - margin-top:0; - margin-bottom:1px; -} -/* -Table styles -*/ -.contentContainer table, .classUseContainer table, .constantValuesContainer table { - border-bottom:1px solid #9eadc0; - width:100%; -} -.contentContainer ul li table, .classUseContainer ul li table, .constantValuesContainer ul li table { - width:100%; -} -.contentContainer .description table, .contentContainer .details table { - border-bottom:none; -} -.contentContainer ul li table th.colOne, .contentContainer ul li table th.colFirst, .contentContainer ul li table th.colLast, .classUseContainer ul li table th, .constantValuesContainer ul li table th, .contentContainer ul li table td.colOne, .contentContainer ul li table td.colFirst, .contentContainer ul li table td.colLast, .classUseContainer ul li table td, .constantValuesContainer ul li table td{ - vertical-align:top; - padding-right:20px; -} -.contentContainer ul li table th.colLast, .classUseContainer ul li table th.colLast,.constantValuesContainer ul li table th.colLast, -.contentContainer ul li table td.colLast, .classUseContainer ul li table td.colLast,.constantValuesContainer ul li table td.colLast, -.contentContainer ul li table th.colOne, .classUseContainer ul li table th.colOne, -.contentContainer ul li table td.colOne, .classUseContainer ul li table td.colOne { - padding-right:3px; -} -.overviewSummary caption, .packageSummary caption, .contentContainer ul.blockList li.blockList caption, .summary caption, .classUseContainer caption, .constantValuesContainer caption { - position:relative; - text-align:left; - background-repeat:no-repeat; - color:#FFFFFF; - font-weight:bold; - clear:none; - overflow:hidden; - padding:0px; - margin:0px; -} -caption a:link, caption a:hover, caption a:active, caption a:visited { - color:#FFFFFF; -} -.overviewSummary caption span, .packageSummary caption span, .contentContainer ul.blockList li.blockList caption span, .summary caption span, .classUseContainer caption span, .constantValuesContainer caption span { - white-space:nowrap; - padding-top:8px; - padding-left:8px; - display:block; - float:left; - background-image:url(resources/titlebar.gif); - height:18px; -} -.overviewSummary .tabEnd, .packageSummary .tabEnd, .contentContainer ul.blockList li.blockList .tabEnd, .summary .tabEnd, .classUseContainer .tabEnd, .constantValuesContainer .tabEnd { - width:10px; - background-image:url(resources/titlebar_end.gif); - background-repeat:no-repeat; - background-position:top right; - position:relative; - float:left; -} -ul.blockList ul.blockList li.blockList table { - margin:0 0 12px 0px; - width:100%; -} -.tableSubHeadingColor { - background-color: #EEEEFF; -} -.altColor { - background-color:#eeeeef; -} -.rowColor { - background-color:#ffffff; -} -.overviewSummary td, .packageSummary td, .contentContainer ul.blockList li.blockList td, .summary td, .classUseContainer td, .constantValuesContainer td { - text-align:left; - padding:3px 3px 3px 7px; -} -th.colFirst, th.colLast, th.colOne, .constantValuesContainer th { - background:#dee3e9; - border-top:1px solid #9eadc0; - border-bottom:1px solid #9eadc0; - text-align:left; - padding:3px 3px 3px 7px; -} -td.colOne a:link, td.colOne a:active, td.colOne a:visited, td.colOne a:hover, td.colFirst a:link, td.colFirst a:active, td.colFirst a:visited, td.colFirst a:hover, td.colLast a:link, td.colLast a:active, td.colLast a:visited, td.colLast a:hover, .constantValuesContainer td a:link, .constantValuesContainer td a:active, .constantValuesContainer td a:visited, .constantValuesContainer td a:hover { - font-weight:bold; -} -td.colFirst, th.colFirst { - border-left:1px solid #9eadc0; - white-space:nowrap; -} -td.colLast, th.colLast { - border-right:1px solid #9eadc0; -} -td.colOne, th.colOne { - border-right:1px solid #9eadc0; - border-left:1px solid #9eadc0; -} -table.overviewSummary { - padding:0px; - margin-left:0px; -} -table.overviewSummary td.colFirst, table.overviewSummary th.colFirst, -table.overviewSummary td.colOne, table.overviewSummary th.colOne { - width:25%; - vertical-align:middle; -} -table.packageSummary td.colFirst, table.overviewSummary th.colFirst { - width:25%; - vertical-align:middle; -} -/* -Content styles -*/ -.description pre { - margin-top:0; -} -.deprecatedContent { - margin:0; - padding:10px 0; -} -.docSummary { - padding:0; -} -/* -Formatting effect styles -*/ -.sourceLineNo { - color:green; - padding:0 30px 0 0; -} -h1.hidden { - visibility:hidden; - overflow:hidden; - font-size:.9em; -} -.block { - display:block; - margin:3px 0 0 0; -} -.strong { - font-weight:bold; -} diff --git a/dist/scannotation-1.0.4/css/site.css b/dist/scannotation-1.0.4/css/site.css deleted file mode 100644 index 055e7e28..00000000 --- a/dist/scannotation-1.0.4/css/site.css +++ /dev/null @@ -1 +0,0 @@ -/* You can override this file with your own styles */ \ No newline at end of file diff --git a/dist/scannotation-1.0.4/dependencies.html b/dist/scannotation-1.0.4/dependencies.html deleted file mode 100644 index 07fbe7d6..00000000 --- a/dist/scannotation-1.0.4/dependencies.html +++ /dev/null @@ -1,982 +0,0 @@ - - - - - - - - -The following is a list of compile dependencies for this project. These dependencies are required to compile and run the application:
-GroupId | -ArtifactId | -Version | -Type | -License |
---|---|---|---|---|
org.javassist | -javassist | -3.19.0-GA | -jar | -MPL 1.1-LGPL 2.1-Apache License 2.0 |
The following is a list of test dependencies for this project. These dependencies are only required to compile and run unit tests for the application:
-GroupId | -ArtifactId | -Version | -Type | -License |
---|---|---|---|---|
junit | -junit | -4.0 | -jar | -- |
org.resteasy | -titan-cruise | -1.0 | -jar | -- |
The following is a list of transitive dependencies for this project. Transitive dependencies are the dependencies of the project dependencies.
-The following is a list of test dependencies for this project. These dependencies are only required to compile and run unit tests for the application:
-GroupId | -ArtifactId | -Version | -Type | -License |
---|---|---|---|---|
antlr | -antlr | -2.7.7 | -jar | -BSD License |
apache-httpclient | -commons-httpclient | -2.0.2 | -jar | -- |
apache-slide | -webdavlib | -2.0 | -jar | -- |
apache-xerces | -xml-apis | -2.7.1 | -jar | -- |
asm | -asm | -1.5.3 | -jar | -- |
cglib | -cglib | -2.1_3 | -jar | -- |
commons-collections | -commons-collections | -3.2 | -jar | -/LICENSE.txt |
commons-logging | -commons-logging | -1.1.0.jboss | -jar | -- |
dom4j | -dom4j | -1.6.1 | -jar | -- |
hibernate | -hibernate3 | -3.2.4.SP1 | -jar | -- |
hibernate-annotations | -hibernate-annotations | -3.3.0.GA | -jar | -- |
hibernate-commons-annotations | -hibernate-commons-annotations | -3.0.0.GA | -jar | -- |
hibernate-entitymanager | -hibernate-entitymanager | -3.3.1.GA | -jar | -- |
hsqldb | -hsqldb | -1.8.0.2 | -jar | -hsqldb |
javassist | -javassist | -3.6.0.GA | -jar | -- |
javax.persistence | -persistence-api | -1.0 | -jar | -Common Development and Distribution License (CDDL) v1.0 |
javax.transaction | -jta | -1.1 | -jar | -- |
jboss | -jboss-common-core | -2.2.0.GA | -jar | -- |
jboss | -jboss-common-logging-spi | -2.0.4.GA | -jar | -- |
oswego-concurrent | -concurrent | -1.3.4 | -jar | -- |
xml-apis | -xml-apis | -1.0.b2 | -jar | -The Apache Software License, Version 2.0 |
Unknown: Java Transaction API, asm, cglib, commons-httpclient, commons-logging, concurrent, dom4j, hibernate-annotations, hibernate-commons-annotations, hibernate-entitymanager, hibernate3, javassist, jboss-common-core, jboss-common-logging-spi, junit, scannotation, servlet-api, titan-cruise, webdavlib, xml-apis
-BSD License: AntLR Parser Generator
-LGPL 2.1: Javassist
-Apache License 2.0: Javassist
-MPL 1.1: Javassist
-hsqldb: hsqldb
-The Apache Software License, Version 2.0: Collections, XML Commons External Components XML APIs
-Common Development and Distribution License (CDDL) v1.0: Enterprise JavaBeans (EJB) 3.0
Filename | -Size | -Entries | -Classes | -Packages | -JDK Rev | -Debug |
---|---|---|---|---|---|---|
antlr-2.7.7.jar | -434.85 kB | -239 | -224 | -12 | -1.2 | -debug |
commons-httpclient-2.0.2.jar | -220.09 kB | -125 | -112 | -7 | -1.1 | -debug |
webdavlib-2.0.jar | -128.81 kB | -81 | -71 | -4 | -1.2 | -debug |
xml-apis-2.7.1.jar | -189.65 kB | -341 | -301 | -25 | -1.1 | -release |
asm-1.5.3.jar | -25.74 kB | -19 | -14 | -1 | -1.2 | -release |
cglib-2.1_3.jar | -275.72 kB | -243 | -228 | -8 | -1.2 | -debug |
commons-collections-3.2.jar | -557.87 kB | -477 | -458 | -12 | -1.1 | -debug |
commons-logging-1.1.0.jboss.jar | -54.12 kB | -33 | -24 | -2 | -1.1 | -debug |
dom4j-1.6.1.jar | -306.54 kB | -208 | -190 | -14 | -1.3 | -debug |
hibernate3-3.2.4.SP1.jar | -2.17 MB | -1,427 | -1,343 | -78 | -1.4 | -debug |
hibernate-annotations-3.3.0.GA.jar | -258.92 kB | -154 | -142 | -7 | -1.5 | -debug |
hibernate-commons-annotations-3.0.0.GA.jar | -64.87 kB | -68 | -57 | -6 | -1.5 | -debug |
hibernate-entitymanager-3.3.1.GA.jar | -113.81 kB | -92 | -77 | -8 | -1.5 | -debug |
hsqldb-1.8.0.2.jar | -615.71 kB | -339 | -300 | -13 | -1.2 | -release |
javassist-3.6.0.GA.jar | -529.53 kB | -323 | -305 | -16 | -1.2 | -debug |
persistence-api-1.0.jar | -50.93 kB | -97 | -91 | -2 | -1.5 | -debug |
servlet-api-2.5.jar | -102.65 kB | -68 | -42 | -2 | -1.5 | -debug |
jta-1.1.jar | -14.72 kB | -24 | -18 | -2 | -1.3 | -debug |
jboss-common-core-2.2.0.GA.jar | -409.71 kB | -376 | -338 | -28 | -1.5 | -debug |
jboss-common-logging-spi-2.0.4.GA.jar | -7.04 kB | -14 | -4 | -1 | -1.5 | -debug |
junit-4.0.jar | -103.13 kB | -119 | -92 | -11 | -1.5 | -debug |
javassist-3.19.0-GA.jar | -731.93 kB | -422 | -398 | -17 | -1.6 | -debug |
titan-cruise-1.0.jar | -47.25 kB | -43 | -31 | -2 | -1.5 | -debug |
concurrent-1.3.4.jar | -166.40 kB | -151 | -143 | -1 | -1.2 | -debug |
xml-apis-1.0.b2.jar | -106.76 kB | -217 | -184 | -17 | -1.2 | -release |
Total | -Size | -Entries | -Classes | -Packages | -JDK Rev | -Debug |
25 | -7.56 MB | -5,700 | -5,187 | -296 | -1.6 | -21 |
compile: 1 | -compile: 731.93 kB | -compile: 422 | -compile: 398 | -compile: 17 | -- | -compile: 1 |
test: 23 | -test: 6.74 MB | -test: 5,210 | -test: 4,747 | -test: 277 | -- | -test: 19 |
provided: 1 | -provided: 102.65 kB | -provided: 68 | -provided: 42 | -provided: 2 | -- | -provided: 1 |
Repo ID | -URL | -Release | -Snapshot |
---|---|---|---|
sonatype-nexus-snapshots | -https://oss.sonatype.org/content/repositories/snapshots | -- | -Yes |
jboss | -http://repository.jboss.org/maven2 | -Yes | -Yes |
central | -http://repo.maven.apache.org/maven2 | -Yes | -- |
Repository locations for each of the Dependencies.
-<dependency> - <groupId>de.juplo</groupId> - <artifactId>scannotation</artifactId> - <version>1.0.4</version> -</dependency>
The following is the distribution management information used by this project.
- -Configuration for notifying developers/users when a build is unsuccessful, including user information and notification mode.
-Type | -Address | -Configuration |
---|---|---|
kai@juplo.de | -- |
GroupId | -ArtifactId | -Version |
---|---|---|
org.apache.maven.plugins | -maven-antrun-plugin | -1.3 |
org.apache.maven.plugins | -maven-assembly-plugin | -2.2-beta-5 |
org.apache.maven.plugins | -maven-dependency-plugin | -2.1 |
org.apache.maven.plugins | -maven-release-plugin | -2.1 |
org.apache.maven.plugins | -maven-site-plugin | -3.4 |
GroupId | -ArtifactId | -Version |
---|---|---|
org.apache.maven.plugins | -maven-clean-plugin | -2.5 |
org.apache.maven.plugins | -maven-compiler-plugin | -3.3 |
org.apache.maven.plugins | -maven-deploy-plugin | -2.7 |
org.apache.maven.plugins | -maven-enforcer-plugin | -1.2 |
org.apache.maven.plugins | -maven-gpg-plugin | -1.1 |
org.apache.maven.plugins | -maven-install-plugin | -2.3 |
org.apache.maven.plugins | -maven-jar-plugin | -2.2 |
org.apache.maven.plugins | -maven-javadoc-plugin | -2.7 |
org.apache.maven.plugins | -maven-resources-plugin | -2.3 |
org.apache.maven.plugins | -maven-site-plugin | -3.4 |
org.apache.maven.plugins | -maven-source-plugin | -2.1.2 |
org.apache.maven.plugins | -maven-surefire-plugin | -2.10 |
GroupId | -ArtifactId | -Version |
---|---|---|
org.apache.maven.plugins | -maven-javadoc-plugin | -2.7 |
This document provides an overview of the various documents and links that are part of this project's general information. All of this content is automatically generated by Maven on behalf of the project.
-Document | -Description |
---|---|
About | -Sonatype helps open source projects to set up Maven repositories on https://oss.sonatype.org/ |
Plugin Management | -This document lists the plugins that are defined through pluginManagement. |
Distribution Management | -This document provides informations on the distribution management of this project. |
Dependency Information | -This document describes how to to include this project as a dependency using various dependency management tools. |
Source Repository | -This is a link to the online source repository that can be viewed via a web browser. |
Mailing Lists | -This document provides subscription and archive information for this project's mailing lists. |
Issue Tracking | -This is a link to the issue management system for this project. Issues (bugs, features, change requests) can be created and queried using this link. |
Continuous Integration | -This is a link to the definitions of all continuous integration processes that builds and tests code on a frequent, regular basis. |
Project Plugins | -This document lists the build plugins and the report plugins used by this project. |
Project License | -This is a link to the definitions of project licenses. |
Project Team | -This document provides information on the members of this project. These are the individuals who have contributed to the project in one form or another. |
Project Summary | -This document lists other related information of this project |
Dependencies | -This document lists the project's dependencies and provides information on each dependency. |
This document provides an overview of the various reports that are automatically generated by Maven . Each report is briefly described below.
-Document | -Description |
---|---|
Test JavaDocs | -Test JavaDoc API documentation. |
JavaDocs | -JavaDoc API documentation. |
Field | -Value |
---|---|
Name | -scannotation |
Description | -Sonatype helps open source projects to set up Maven repositories on https://oss.sonatype.org/ |
Homepage | -http://juplo.de/scannotation |
This project uses GIT to manage its source code. Instructions on GIT use can be found at http://git-scm.com/documentation.
The source can be checked out anonymously from GIT with this command (See http://git-scm.com/docs/git-clone):
-$ git clone http://juplo.de/git/scannotation
Only project developers can access the GIT tree via this method (See http://git-scm.com/docs/git-clone).
-$ git clone ssh://juplo.de/var/lib/git/juplo/scannotation
A successful project requires many people to play many roles. Some members write code or documentation, while others are valuable as testers, submitting patches and suggestions.
-The team is comprised of Members and Contributors. Members have direct access to the source of a project and actively evolve the code-base. Contributors improve the project through submission of patches and suggestions to the Members. The number of Contributors to the project is unbounded. Get involved today. All contributions to the project are greatly appreciated.
-The following is a list of developers with commit privileges that have directly contributed to the project in one way or another.
-Image | -Id | -Name | -URL | |
---|---|---|---|---|
- | patriot1burke | -Bill Burke | -- | -http://sourceforge.net/u/patriot1burke/profile/ |
- | tjordahl | -Tom Jordahl | -- | -http://sourceforge.net/u/tjordahl/profile/ |
- | kai | -Kai Moritz | -kai@juplo.de | -- |
Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/testapidocs/deprecated-list.html b/dist/scannotation-1.0.4/testapidocs/deprecated-list.html deleted file mode 100644 index 43f40b35..00000000 --- a/dist/scannotation-1.0.4/testapidocs/deprecated-list.html +++ /dev/null @@ -1,115 +0,0 @@ - - - - - - -Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/testapidocs/help-doc.html b/dist/scannotation-1.0.4/testapidocs/help-doc.html deleted file mode 100644 index 7df8d159..00000000 --- a/dist/scannotation-1.0.4/testapidocs/help-doc.html +++ /dev/null @@ -1,216 +0,0 @@ - - - - - - -Each package has a page that contains a list of its classes and interfaces, with a summary for each. This page can contain six categories:
-Each class, interface, nested class and nested interface has its own separate page. Each of these pages has three sections consisting of a class/interface description, summary tables, and detailed member descriptions:
-Each summary entry contains the first sentence from the detailed description for that item. The summary entries are alphabetical, while the detailed descriptions are in the order they appear in the source code. This preserves the logical groupings established by the programmer.
-Each annotation type has its own separate page with the following sections:
-Each enum has its own separate page with the following sections:
-Each documented package, class and interface has its own Use page. This page describes what packages, classes, methods, constructors and fields use any part of the given class or package. Given a class or interface A, its Use page includes subclasses of A, fields declared as A, methods that return A, and methods and constructors with parameters of type A. You can access this page by first going to the package, class or interface, then clicking on the "Use" link in the navigation bar.
-There is a Class Hierarchy page for all packages, plus a hierarchy for each package. Each hierarchy page contains a list of classes and a list of interfaces. The classes are organized by inheritance structure starting with java.lang.Object
. The interfaces do not inherit from java.lang.Object
.
The Deprecated API page lists all of the API that have been deprecated. A deprecated API is not recommended for use, generally due to improvements, and a replacement API is usually given. Deprecated APIs may be removed in future implementations.
-The Index contains an alphabetic list of all classes, interfaces, constructors, methods, and fields.
-These links take you to the next or previous class, interface, package, or related page.
-These links show and hide the HTML frames. All pages are available with or without frames.
-The All Classes link shows all classes and interfaces except non-static nested types.
-Each serializable or externalizable class has a description of its serialization fields and methods. This information is of interest to re-implementors, not to developers using the API. While there is no link in the navigation bar, you can get to this information by going to any serialized class and clicking "Serialized Form" in the "See also" section of the class description.
-The Constant Field Values page lists the static final fields and their values.
-Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/testapidocs/index-all.html b/dist/scannotation-1.0.4/testapidocs/index-all.html deleted file mode 100644 index 3d70517f..00000000 --- a/dist/scannotation-1.0.4/testapidocs/index-all.html +++ /dev/null @@ -1,200 +0,0 @@ - - - - - - -Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/testapidocs/index.html b/dist/scannotation-1.0.4/testapidocs/index.html deleted file mode 100644 index d3542831..00000000 --- a/dist/scannotation-1.0.4/testapidocs/index.html +++ /dev/null @@ -1,72 +0,0 @@ - - - - - - -This document is designed to be viewed using the frames feature. If you see this message, you are using a non-frame-capable web client. Link to Non-frame version.
-public @interface AnnotationWithMetaAnnotation
-Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/testapidocs/org/scannotation/test/ClassWithFieldAnnotation.html b/dist/scannotation-1.0.4/testapidocs/org/scannotation/test/ClassWithFieldAnnotation.html deleted file mode 100644 index 3b5dd570..00000000 --- a/dist/scannotation-1.0.4/testapidocs/org/scannotation/test/ClassWithFieldAnnotation.html +++ /dev/null @@ -1,232 +0,0 @@ - - - - - - -public class ClassWithFieldAnnotation -extends Object-
Constructor and Description | -
---|
ClassWithFieldAnnotation() |
-
Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/testapidocs/org/scannotation/test/CrossRef.html b/dist/scannotation-1.0.4/testapidocs/org/scannotation/test/CrossRef.html deleted file mode 100644 index 0f36e397..00000000 --- a/dist/scannotation-1.0.4/testapidocs/org/scannotation/test/CrossRef.html +++ /dev/null @@ -1,269 +0,0 @@ - - - - - - -public class CrossRef -extends Object -implements InterfaceWithParameterAnnotations-
Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/testapidocs/org/scannotation/test/CrossRefMetaAnnotaiton.html b/dist/scannotation-1.0.4/testapidocs/org/scannotation/test/CrossRefMetaAnnotaiton.html deleted file mode 100644 index d6a7e025..00000000 --- a/dist/scannotation-1.0.4/testapidocs/org/scannotation/test/CrossRefMetaAnnotaiton.html +++ /dev/null @@ -1,232 +0,0 @@ - - - - - - -public class CrossRefMetaAnnotaiton -extends Object-
Constructor and Description | -
---|
CrossRefMetaAnnotaiton() |
-
Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/testapidocs/org/scannotation/test/InterfaceWithParameterAnnotations.html b/dist/scannotation-1.0.4/testapidocs/org/scannotation/test/InterfaceWithParameterAnnotations.html deleted file mode 100644 index 1dc1c79a..00000000 --- a/dist/scannotation-1.0.4/testapidocs/org/scannotation/test/InterfaceWithParameterAnnotations.html +++ /dev/null @@ -1,214 +0,0 @@ - - - - - - -public interface InterfaceWithParameterAnnotations
-Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/testapidocs/org/scannotation/test/MetaAnnotation.html b/dist/scannotation-1.0.4/testapidocs/org/scannotation/test/MetaAnnotation.html deleted file mode 100644 index 6817be06..00000000 --- a/dist/scannotation-1.0.4/testapidocs/org/scannotation/test/MetaAnnotation.html +++ /dev/null @@ -1,154 +0,0 @@ - - - - - - -public @interface MetaAnnotation
-Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/testapidocs/org/scannotation/test/SimpleAnnotation.html b/dist/scannotation-1.0.4/testapidocs/org/scannotation/test/SimpleAnnotation.html deleted file mode 100644 index 9888cdbb..00000000 --- a/dist/scannotation-1.0.4/testapidocs/org/scannotation/test/SimpleAnnotation.html +++ /dev/null @@ -1,155 +0,0 @@ - - - - - - -@Retention(value=RUNTIME) -public @interface SimpleAnnotation-
Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/testapidocs/org/scannotation/test/TestSmoke.html b/dist/scannotation-1.0.4/testapidocs/org/scannotation/test/TestSmoke.html deleted file mode 100644 index 635f5169..00000000 --- a/dist/scannotation-1.0.4/testapidocs/org/scannotation/test/TestSmoke.html +++ /dev/null @@ -1,327 +0,0 @@ - - - - - - -public class TestSmoke -extends Object-
Modifier and Type | -Method and Description | -
---|---|
void |
-testCrossRef() |
-
void |
-testCrossRefMetaAnnotations() |
-
void |
-testFieldParameter() |
-
void |
-testFindClasspaths() |
-
void |
-testFindClasspaths2() |
-
Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/testapidocs/org/scannotation/test/class-use/AnnotationWithMetaAnnotation.html b/dist/scannotation-1.0.4/testapidocs/org/scannotation/test/class-use/AnnotationWithMetaAnnotation.html deleted file mode 100644 index 449863fd..00000000 --- a/dist/scannotation-1.0.4/testapidocs/org/scannotation/test/class-use/AnnotationWithMetaAnnotation.html +++ /dev/null @@ -1,140 +0,0 @@ - - - - - - -Modifier and Type | -Class and Description | -
---|---|
class |
-CrossRefMetaAnnotaiton |
-
Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/testapidocs/org/scannotation/test/class-use/ClassWithFieldAnnotation.html b/dist/scannotation-1.0.4/testapidocs/org/scannotation/test/class-use/ClassWithFieldAnnotation.html deleted file mode 100644 index 029ad03f..00000000 --- a/dist/scannotation-1.0.4/testapidocs/org/scannotation/test/class-use/ClassWithFieldAnnotation.html +++ /dev/null @@ -1,115 +0,0 @@ - - - - - - -Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/testapidocs/org/scannotation/test/class-use/CrossRef.html b/dist/scannotation-1.0.4/testapidocs/org/scannotation/test/class-use/CrossRef.html deleted file mode 100644 index 2c46aebb..00000000 --- a/dist/scannotation-1.0.4/testapidocs/org/scannotation/test/class-use/CrossRef.html +++ /dev/null @@ -1,115 +0,0 @@ - - - - - - -Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/testapidocs/org/scannotation/test/class-use/CrossRefMetaAnnotaiton.html b/dist/scannotation-1.0.4/testapidocs/org/scannotation/test/class-use/CrossRefMetaAnnotaiton.html deleted file mode 100644 index 28a86244..00000000 --- a/dist/scannotation-1.0.4/testapidocs/org/scannotation/test/class-use/CrossRefMetaAnnotaiton.html +++ /dev/null @@ -1,115 +0,0 @@ - - - - - - -Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/testapidocs/org/scannotation/test/class-use/InterfaceWithParameterAnnotations.html b/dist/scannotation-1.0.4/testapidocs/org/scannotation/test/class-use/InterfaceWithParameterAnnotations.html deleted file mode 100644 index 3068296e..00000000 --- a/dist/scannotation-1.0.4/testapidocs/org/scannotation/test/class-use/InterfaceWithParameterAnnotations.html +++ /dev/null @@ -1,140 +0,0 @@ - - - - - - -Modifier and Type | -Class and Description | -
---|---|
class |
-CrossRef |
-
Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/testapidocs/org/scannotation/test/class-use/MetaAnnotation.html b/dist/scannotation-1.0.4/testapidocs/org/scannotation/test/class-use/MetaAnnotation.html deleted file mode 100644 index 5ff09b2f..00000000 --- a/dist/scannotation-1.0.4/testapidocs/org/scannotation/test/class-use/MetaAnnotation.html +++ /dev/null @@ -1,140 +0,0 @@ - - - - - - -Modifier and Type | -Class and Description | -
---|---|
interface |
-AnnotationWithMetaAnnotation |
-
Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/testapidocs/org/scannotation/test/class-use/SimpleAnnotation.html b/dist/scannotation-1.0.4/testapidocs/org/scannotation/test/class-use/SimpleAnnotation.html deleted file mode 100644 index be2d15ab..00000000 --- a/dist/scannotation-1.0.4/testapidocs/org/scannotation/test/class-use/SimpleAnnotation.html +++ /dev/null @@ -1,140 +0,0 @@ - - - - - - -Modifier and Type | -Method and Description | -
---|---|
void |
-InterfaceWithParameterAnnotations.junk(int param) |
-
Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/testapidocs/org/scannotation/test/class-use/TestSmoke.html b/dist/scannotation-1.0.4/testapidocs/org/scannotation/test/class-use/TestSmoke.html deleted file mode 100644 index ce479426..00000000 --- a/dist/scannotation-1.0.4/testapidocs/org/scannotation/test/class-use/TestSmoke.html +++ /dev/null @@ -1,115 +0,0 @@ - - - - - - -Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/testapidocs/org/scannotation/test/package-frame.html b/dist/scannotation-1.0.4/testapidocs/org/scannotation/test/package-frame.html deleted file mode 100644 index a8861d8a..00000000 --- a/dist/scannotation-1.0.4/testapidocs/org/scannotation/test/package-frame.html +++ /dev/null @@ -1,33 +0,0 @@ - - - - - - -Interface | -Description | -
---|---|
InterfaceWithParameterAnnotations | -- |
Class | -Description | -
---|---|
ClassWithFieldAnnotation | -- |
CrossRef | -- |
CrossRefMetaAnnotaiton | -- |
TestSmoke | -- |
Annotation Type | -Description | -
---|---|
AnnotationWithMetaAnnotation | -- |
MetaAnnotation | -- |
SimpleAnnotation | -- |
Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/testapidocs/org/scannotation/test/package-tree.html b/dist/scannotation-1.0.4/testapidocs/org/scannotation/test/package-tree.html deleted file mode 100644 index 035a42d4..00000000 --- a/dist/scannotation-1.0.4/testapidocs/org/scannotation/test/package-tree.html +++ /dev/null @@ -1,137 +0,0 @@ - - - - - - -Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/testapidocs/org/scannotation/test/package-use.html b/dist/scannotation-1.0.4/testapidocs/org/scannotation/test/package-use.html deleted file mode 100644 index 8ad4b3c1..00000000 --- a/dist/scannotation-1.0.4/testapidocs/org/scannotation/test/package-use.html +++ /dev/null @@ -1,142 +0,0 @@ - - - - - - -Class and Description | -
---|
AnnotationWithMetaAnnotation | -
InterfaceWithParameterAnnotations | -
MetaAnnotation | -
SimpleAnnotation | -
Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/testapidocs/overview-tree.html b/dist/scannotation-1.0.4/testapidocs/overview-tree.html deleted file mode 100644 index cb3c5cc8..00000000 --- a/dist/scannotation-1.0.4/testapidocs/overview-tree.html +++ /dev/null @@ -1,141 +0,0 @@ - - - - - - -Copyright © 2015. All Rights Reserved.
- - diff --git a/dist/scannotation-1.0.4/testapidocs/package-list b/dist/scannotation-1.0.4/testapidocs/package-list deleted file mode 100644 index 44d8ebee..00000000 --- a/dist/scannotation-1.0.4/testapidocs/package-list +++ /dev/null @@ -1 +0,0 @@ -org.scannotation.test diff --git a/dist/scannotation-1.0.4/testapidocs/packages b/dist/scannotation-1.0.4/testapidocs/packages deleted file mode 100644 index e5be0d35..00000000 --- a/dist/scannotation-1.0.4/testapidocs/packages +++ /dev/null @@ -1 +0,0 @@ -org.scannotation.test \ No newline at end of file diff --git a/dist/scannotation-1.0.4/testapidocs/resources/background.gif b/dist/scannotation-1.0.4/testapidocs/resources/background.gif deleted file mode 100644 index f471940f..00000000 Binary files a/dist/scannotation-1.0.4/testapidocs/resources/background.gif and /dev/null differ diff --git a/dist/scannotation-1.0.4/testapidocs/resources/tab.gif b/dist/scannotation-1.0.4/testapidocs/resources/tab.gif deleted file mode 100644 index 1a73a83b..00000000 Binary files a/dist/scannotation-1.0.4/testapidocs/resources/tab.gif and /dev/null differ diff --git a/dist/scannotation-1.0.4/testapidocs/resources/titlebar.gif b/dist/scannotation-1.0.4/testapidocs/resources/titlebar.gif deleted file mode 100644 index 17443b3e..00000000 Binary files a/dist/scannotation-1.0.4/testapidocs/resources/titlebar.gif and /dev/null differ diff --git a/dist/scannotation-1.0.4/testapidocs/resources/titlebar_end.gif b/dist/scannotation-1.0.4/testapidocs/resources/titlebar_end.gif deleted file mode 100644 index 3ad78d46..00000000 Binary files a/dist/scannotation-1.0.4/testapidocs/resources/titlebar_end.gif and /dev/null differ diff --git a/dist/scannotation-1.0.4/testapidocs/stylesheet.css b/dist/scannotation-1.0.4/testapidocs/stylesheet.css deleted file mode 100644 index 0aeaa97f..00000000 --- a/dist/scannotation-1.0.4/testapidocs/stylesheet.css +++ /dev/null @@ -1,474 +0,0 @@ -/* Javadoc style sheet */ -/* -Overall document style -*/ -body { - background-color:#ffffff; - color:#353833; - font-family:Arial, Helvetica, sans-serif; - font-size:76%; - margin:0; -} -a:link, a:visited { - text-decoration:none; - color:#4c6b87; -} -a:hover, a:focus { - text-decoration:none; - color:#bb7a2a; -} -a:active { - text-decoration:none; - color:#4c6b87; -} -a[name] { - color:#353833; -} -a[name]:hover { - text-decoration:none; - color:#353833; -} -pre { - font-size:1.3em; -} -h1 { - font-size:1.8em; -} -h2 { - font-size:1.5em; -} -h3 { - font-size:1.4em; -} -h4 { - font-size:1.3em; -} -h5 { - font-size:1.2em; -} -h6 { - font-size:1.1em; -} -ul { - list-style-type:disc; -} -code, tt { - font-size:1.2em; -} -dt code { - font-size:1.2em; -} -table tr td dt code { - font-size:1.2em; - vertical-align:top; -} -sup { - font-size:.6em; -} -/* -Document title and Copyright styles -*/ -.clear { - clear:both; - height:0px; - overflow:hidden; -} -.aboutLanguage { - float:right; - padding:0px 21px; - font-size:.8em; - z-index:200; - margin-top:-7px; -} -.legalCopy { - margin-left:.5em; -} -.bar a, .bar a:link, .bar a:visited, .bar a:active { - color:#FFFFFF; - text-decoration:none; -} -.bar a:hover, .bar a:focus { - color:#bb7a2a; -} -.tab { - background-color:#0066FF; - background-image:url(resources/titlebar.gif); - background-position:left top; - background-repeat:no-repeat; - color:#ffffff; - padding:8px; - width:5em; - font-weight:bold; -} -/* -Navigation bar styles -*/ -.bar { - background-image:url(resources/background.gif); - background-repeat:repeat-x; - color:#FFFFFF; - padding:.8em .5em .4em .8em; - height:auto;/*height:1.8em;*/ - font-size:1em; - margin:0; -} -.topNav { - background-image:url(resources/background.gif); - background-repeat:repeat-x; - color:#FFFFFF; - float:left; - padding:0; - width:100%; - clear:right; - height:2.8em; - padding-top:10px; - overflow:hidden; -} -.bottomNav { - margin-top:10px; - background-image:url(resources/background.gif); - background-repeat:repeat-x; - color:#FFFFFF; - float:left; - padding:0; - width:100%; - clear:right; - height:2.8em; - padding-top:10px; - overflow:hidden; -} -.subNav { - background-color:#dee3e9; - border-bottom:1px solid #9eadc0; - float:left; - width:100%; - overflow:hidden; -} -.subNav div { - clear:left; - float:left; - padding:0 0 5px 6px; -} -ul.navList, ul.subNavList { - float:left; - margin:0 25px 0 0; - padding:0; -} -ul.navList li{ - list-style:none; - float:left; - padding:3px 6px; -} -ul.subNavList li{ - list-style:none; - float:left; - font-size:90%; -} -.topNav a:link, .topNav a:active, .topNav a:visited, .bottomNav a:link, .bottomNav a:active, .bottomNav a:visited { - color:#FFFFFF; - text-decoration:none; -} -.topNav a:hover, .bottomNav a:hover { - text-decoration:none; - color:#bb7a2a; -} -.navBarCell1Rev { - background-image:url(resources/tab.gif); - background-color:#a88834; - color:#FFFFFF; - margin: auto 5px; - border:1px solid #c9aa44; -} -/* -Page header and footer styles -*/ -.header, .footer { - clear:both; - margin:0 20px; - padding:5px 0 0 0; -} -.indexHeader { - margin:10px; - position:relative; -} -.indexHeader h1 { - font-size:1.3em; -} -.title { - color:#2c4557; - margin:10px 0; -} -.subTitle { - margin:5px 0 0 0; -} -.header ul { - margin:0 0 25px 0; - padding:0; -} -.footer ul { - margin:20px 0 5px 0; -} -.header ul li, .footer ul li { - list-style:none; - font-size:1.2em; -} -/* -Heading styles -*/ -div.details ul.blockList ul.blockList ul.blockList li.blockList h4, div.details ul.blockList ul.blockList ul.blockListLast li.blockList h4 { - background-color:#dee3e9; - border-top:1px solid #9eadc0; - border-bottom:1px solid #9eadc0; - margin:0 0 6px -8px; - padding:2px 5px; -} -ul.blockList ul.blockList ul.blockList li.blockList h3 { - background-color:#dee3e9; - border-top:1px solid #9eadc0; - border-bottom:1px solid #9eadc0; - margin:0 0 6px -8px; - padding:2px 5px; -} -ul.blockList ul.blockList li.blockList h3 { - padding:0; - margin:15px 0; -} -ul.blockList li.blockList h2 { - padding:0px 0 20px 0; -} -/* -Page layout container styles -*/ -.contentContainer, .sourceContainer, .classUseContainer, .serializedFormContainer, .constantValuesContainer { - clear:both; - padding:10px 20px; - position:relative; -} -.indexContainer { - margin:10px; - position:relative; - font-size:1.0em; -} -.indexContainer h2 { - font-size:1.1em; - padding:0 0 3px 0; -} -.indexContainer ul { - margin:0; - padding:0; -} -.indexContainer ul li { - list-style:none; -} -.contentContainer .description dl dt, .contentContainer .details dl dt, .serializedFormContainer dl dt { - font-size:1.1em; - font-weight:bold; - margin:10px 0 0 0; - color:#4E4E4E; -} -.contentContainer .description dl dd, .contentContainer .details dl dd, .serializedFormContainer dl dd { - margin:10px 0 10px 20px; -} -.serializedFormContainer dl.nameValue dt { - margin-left:1px; - font-size:1.1em; - display:inline; - font-weight:bold; -} -.serializedFormContainer dl.nameValue dd { - margin:0 0 0 1px; - font-size:1.1em; - display:inline; -} -/* -List styles -*/ -ul.horizontal li { - display:inline; - font-size:0.9em; -} -ul.inheritance { - margin:0; - padding:0; -} -ul.inheritance li { - display:inline; - list-style:none; -} -ul.inheritance li ul.inheritance { - margin-left:15px; - padding-left:15px; - padding-top:1px; -} -ul.blockList, ul.blockListLast { - margin:10px 0 10px 0; - padding:0; -} -ul.blockList li.blockList, ul.blockListLast li.blockList { - list-style:none; - margin-bottom:25px; -} -ul.blockList ul.blockList li.blockList, ul.blockList ul.blockListLast li.blockList { - padding:0px 20px 5px 10px; - border:1px solid #9eadc0; - background-color:#f9f9f9; -} -ul.blockList ul.blockList ul.blockList li.blockList, ul.blockList ul.blockList ul.blockListLast li.blockList { - padding:0 0 5px 8px; - background-color:#ffffff; - border:1px solid #9eadc0; - border-top:none; -} -ul.blockList ul.blockList ul.blockList ul.blockList li.blockList { - margin-left:0; - padding-left:0; - padding-bottom:15px; - border:none; - border-bottom:1px solid #9eadc0; -} -ul.blockList ul.blockList ul.blockList ul.blockList li.blockListLast { - list-style:none; - border-bottom:none; - padding-bottom:0; -} -table tr td dl, table tr td dl dt, table tr td dl dd { - margin-top:0; - margin-bottom:1px; -} -/* -Table styles -*/ -.contentContainer table, .classUseContainer table, .constantValuesContainer table { - border-bottom:1px solid #9eadc0; - width:100%; -} -.contentContainer ul li table, .classUseContainer ul li table, .constantValuesContainer ul li table { - width:100%; -} -.contentContainer .description table, .contentContainer .details table { - border-bottom:none; -} -.contentContainer ul li table th.colOne, .contentContainer ul li table th.colFirst, .contentContainer ul li table th.colLast, .classUseContainer ul li table th, .constantValuesContainer ul li table th, .contentContainer ul li table td.colOne, .contentContainer ul li table td.colFirst, .contentContainer ul li table td.colLast, .classUseContainer ul li table td, .constantValuesContainer ul li table td{ - vertical-align:top; - padding-right:20px; -} -.contentContainer ul li table th.colLast, .classUseContainer ul li table th.colLast,.constantValuesContainer ul li table th.colLast, -.contentContainer ul li table td.colLast, .classUseContainer ul li table td.colLast,.constantValuesContainer ul li table td.colLast, -.contentContainer ul li table th.colOne, .classUseContainer ul li table th.colOne, -.contentContainer ul li table td.colOne, .classUseContainer ul li table td.colOne { - padding-right:3px; -} -.overviewSummary caption, .packageSummary caption, .contentContainer ul.blockList li.blockList caption, .summary caption, .classUseContainer caption, .constantValuesContainer caption { - position:relative; - text-align:left; - background-repeat:no-repeat; - color:#FFFFFF; - font-weight:bold; - clear:none; - overflow:hidden; - padding:0px; - margin:0px; -} -caption a:link, caption a:hover, caption a:active, caption a:visited { - color:#FFFFFF; -} -.overviewSummary caption span, .packageSummary caption span, .contentContainer ul.blockList li.blockList caption span, .summary caption span, .classUseContainer caption span, .constantValuesContainer caption span { - white-space:nowrap; - padding-top:8px; - padding-left:8px; - display:block; - float:left; - background-image:url(resources/titlebar.gif); - height:18px; -} -.overviewSummary .tabEnd, .packageSummary .tabEnd, .contentContainer ul.blockList li.blockList .tabEnd, .summary .tabEnd, .classUseContainer .tabEnd, .constantValuesContainer .tabEnd { - width:10px; - background-image:url(resources/titlebar_end.gif); - background-repeat:no-repeat; - background-position:top right; - position:relative; - float:left; -} -ul.blockList ul.blockList li.blockList table { - margin:0 0 12px 0px; - width:100%; -} -.tableSubHeadingColor { - background-color: #EEEEFF; -} -.altColor { - background-color:#eeeeef; -} -.rowColor { - background-color:#ffffff; -} -.overviewSummary td, .packageSummary td, .contentContainer ul.blockList li.blockList td, .summary td, .classUseContainer td, .constantValuesContainer td { - text-align:left; - padding:3px 3px 3px 7px; -} -th.colFirst, th.colLast, th.colOne, .constantValuesContainer th { - background:#dee3e9; - border-top:1px solid #9eadc0; - border-bottom:1px solid #9eadc0; - text-align:left; - padding:3px 3px 3px 7px; -} -td.colOne a:link, td.colOne a:active, td.colOne a:visited, td.colOne a:hover, td.colFirst a:link, td.colFirst a:active, td.colFirst a:visited, td.colFirst a:hover, td.colLast a:link, td.colLast a:active, td.colLast a:visited, td.colLast a:hover, .constantValuesContainer td a:link, .constantValuesContainer td a:active, .constantValuesContainer td a:visited, .constantValuesContainer td a:hover { - font-weight:bold; -} -td.colFirst, th.colFirst { - border-left:1px solid #9eadc0; - white-space:nowrap; -} -td.colLast, th.colLast { - border-right:1px solid #9eadc0; -} -td.colOne, th.colOne { - border-right:1px solid #9eadc0; - border-left:1px solid #9eadc0; -} -table.overviewSummary { - padding:0px; - margin-left:0px; -} -table.overviewSummary td.colFirst, table.overviewSummary th.colFirst, -table.overviewSummary td.colOne, table.overviewSummary th.colOne { - width:25%; - vertical-align:middle; -} -table.packageSummary td.colFirst, table.overviewSummary th.colFirst { - width:25%; - vertical-align:middle; -} -/* -Content styles -*/ -.description pre { - margin-top:0; -} -.deprecatedContent { - margin:0; - padding:10px 0; -} -.docSummary { - padding:0; -} -/* -Formatting effect styles -*/ -.sourceLineNo { - color:green; - padding:0 30px 0 0; -} -h1.hidden { - visibility:hidden; - overflow:hidden; - font-size:.9em; -} -.block { - display:block; - margin:3px 0 0 0; -} -.strong { - font-weight:bold; -} diff --git a/dist/sitemap.json b/dist/sitemap.json index 8b9ac943..e97ceff8 100644 --- a/dist/sitemap.json +++ b/dist/sitemap.json @@ -1,13 +1,11 @@ { - "_sections": { - "blog": "/blog/", - "projects": "/projects.html", - "about": "/about.html" - }, "_titles": { "/index.html": "Home", "/blog/": "Blog", "/projects.html": "Projects", + "/projects/hibernate-maven-plugin/2.1.2-SNAPSHOT/index.html": "Hibernate Maven Plugin", + "/projects/http-resources/2.0.0/index.html": "HTTP resources", + "/projects/maven-thymeleaf-skin/1.1.0/index.html": "Maven Thymeleaf Skin", "/about.html": "About", "/expertise.html": "Expertise", "/references.html": "References", @@ -22,9 +20,16 @@ "/templates/error.html": "5xx-Template" }, "_childs": { + "/index.html": [ + "/blog/", + "/projects.html", + "/about.html" + ], "/blog/": [], "/projects.html": [ - "/hibernate-maven-plugin/2.1.2-SNAPSHOT/index.html" + "/projects/hibernate-maven-plugin/2.1.2-SNAPSHOT/index.html", + "/projects/http-resources/2.0.0/index.html", + "/projects/maven-thymeleaf-skin/1.1.0/index.html" ], "/about.html": [ "/expertise.html", @@ -32,8 +37,6 @@ "/impressum.html", "/contact.html" ], - "/expertise.html": [], - "/references.html": [], "/impressum.html": [ "/agb.html", "/haftung-inhalte.html", @@ -43,55 +46,90 @@ ] }, "_crumbs": { + "/index.html": [ + "/index.html" + ], + "/projects.html": [ + "/index.html", + "/projects.html" + ], + "/projects/hibernate-maven-plugin/2.1.2-SNAPSHOT/index.html": [ + "/index.html", + "/projects.html", + "/projects/hibernate-maven-plugin/2.1.2-SNAPSHOT/index.html" + ], + "/projects/http-resources/2.0.0/index.html": [ + "/index.html", + "/projects.html", + "/projects/http-resources/2.0.0/index.html" + ], + "/projects/maven-thymeleaf-skin/1.1.0/index.html": [ + "/index.html", + "/projects.html", + "/projects/maven-thymeleaf-skin/1.1.0/index.html" + ], "/about.html": [ + "/index.html", "/about.html" ], "/expertise.html": [ + "/index.html", "/about.html", "/expertise.html" ], "/references.html": [ + "/index.html", "/about.html", "/references.html" ], "/impressum.html": [ + "/index.html", "/about.html", "/impressum.html" ], "/contact.html": [ + "/index.html", "/about.html", "/contact.html" ], "/agb.html": [ + "/index.html", "/about.html", "/impressum.html", "/agb.html" ], "/haftung-inhalte.html": [ + "/index.html", "/about.html", "/impressum.html", "/haftung-inhalte.html" ], "/haftung-links.html": [ + "/index.html", "/about.html", "/impressum.html", "/haftung-links.html" ], "/urheberrechte.html": [ + "/index.html", "/about.html", "/impressum.html", "/urheberrechte.html" ], "/datenschutz.html": [ + "/index.html", "/about.html", "/impressum.html", "/datenschutz.html" ], "/templates/404.html": [ + "/index.html", "/templates/404.html" ], "/templates/error.html": [ + "/index.html", "/templates/error.html" ] - } + }, + "_canonical": {} } diff --git a/dist/templates/404.html b/dist/templates/404.html deleted file mode 100644 index 5f977e93..00000000 --- a/dist/templates/404.html +++ /dev/null @@ -1,43 +0,0 @@ - - - -We do not know, where you are.
-And we do not know, why you are here.
-But we can tell you: WE ARE SORRY!
-Really.
-We do not know, what happend.
-But we can tell you: WE ARE SORRY!
-Really.
-+ Lorem ipsum dolor + sit amet, + consectetur adipisicing elit, sed do eiusmod tempor incididunt ut + labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud + exercitation + ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute + irure dolor in reprehenderit in voluptate velit esse cillum dolore + eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non + proident, sunt in culpa qui officia deserunt mollit anim id est + laborum. +
++ Lorem ipsum dolor sit amet, consectetur adipisicing elit, + sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. + Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris + nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in + reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla + pariatur. Excepteur sint occaecat cupidatat non proident, sunt in + culpa qui officia deserunt mollit anim id est laborum. +
++ Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do + eiusmod tempor incididunt ut labore et dolore magna aliqua. + Ut enim ad minim veniam, quis nostrud exercitation + ullamco laboris nisi ut aliquip ex ea commodo consequat. + Duis aute irure dolor in reprehenderit in voluptate velit esse + cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat + cupidatat non proident, sunt in culpa qui officia deserunt mollit + anim id est laborum. +
+bulma
+ node-sass
to compile your own Sass file
+ postcss-cli
and autoprefixer
to add support for older browsers
+ babel-cli
,
+ babel-preset-env
+ and
+ babel-preset-es2015-ie
+ for compiling ES6 JavaScript files
+
+ Apart from package.json
, the following files are included:
+
.babelrc
configuration file for Babel
+ .gitignore
common Git ignored files
+ index.html
this HTML5 file
+ _sass/main.scss
a basic SCSS file that imports Bulma and explains how to customize your styles, and compiles to css/main.css
+ _javascript/main.js
an ES6 JavaScript that compiles to lib/main.js
+ + To see if your setup works, follow these steps: +
+
+ Move to this directory:
+
+
cd bulma-start
+
+
+ Install all dependencies:
+
+
npm install
+
+
+ Start the CSS and JS watchers:
+
+
npm start
+
+
+ Edit _sass/main.scss
by adding the following rule at the end of the file:
+
+
html { + background-color: $green; + }+ +
+ The page background should turn green! +
+
+ You're ready to create your own designs with Bulma. Just edit or duplicate this page, or simply create a new one!
+
+ For example, this page is only built with the following Bulma elements:
+
Type | +CSS class | +
---|---|
Columns | +
+ columns
+ column
+ |
+
Layout | +
+ section
+ container
+ footer
+ |
+
Elements | +
+ button
+ content
+ title
+ subtitle
+ |
+
Form | +
+ field
+ control
+ |
+
Helpers | +
+ has-text-centered
+ has-text-weight-semibold
+ |
+
+ If you want to learn more, follow these links: +
+