Package org.codehaus.mojo.hibernate3.configuration

Examples of org.codehaus.mojo.hibernate3.configuration.ComponentConfiguration


     * @noinspection unchecked
     */
    protected Exporter configureExporter(Exporter exporter) throws MojoExecutionException {
        String implementation = getComponentProperty("implementation", getComponent().getImplementation());

        ComponentConfiguration componentConfiguration = getComponentConfiguration(implementation);
        getLog().debug("using " + componentConfiguration.getName() + " task.");

        Properties properties = new Properties();
        properties.putAll(componentProperties);

        exporter.setProperties(properties);
        exporter.setConfiguration(componentConfiguration.getConfiguration(this));
        exporter.setOutputDirectory(new File(getComponent().getOutputDirectory()));

        return exporter;
    }
View Full Code Here


     * @throws MojoExecutionException if there is an error finding the ConfigurationTask
     * @noinspection ForLoopReplaceableByForEach
     */
    protected ComponentConfiguration getComponentConfiguration(String name) throws MojoExecutionException {
        for (Iterator<ComponentConfiguration> it = componentConfigurations.iterator(); it.hasNext();) {
            ComponentConfiguration componentConfiguration = it.next();
            if (componentConfiguration.getName().equals(name)) {
                return componentConfiguration;
            }
        }
        throw new MojoExecutionException("Could not get ConfigurationTask.");
    }
View Full Code Here

    protected Exporter configureExporter(Exporter exporter)
            throws MojoExecutionException {
        String implementation = getComponentProperty("implementation",
                getComponent().getImplementation());

        ComponentConfiguration componentConfiguration = getComponentConfiguration(implementation);
        getLog().debug("using " + componentConfiguration.getName() + " task.");

        Properties properties = new Properties();
        properties.putAll(componentProperties);

        exporter.setProperties(properties);
        exporter
                .setConfiguration(componentConfiguration.getConfiguration(this));
        exporter.setOutputDirectory(new File(getComponent()
                .getOutputDirectory()));

        return exporter;
    }
View Full Code Here

     */
    protected ComponentConfiguration getComponentConfiguration(String name)
            throws MojoExecutionException {
        for (Iterator<ComponentConfiguration> it = componentConfigurations
                .iterator(); it.hasNext();) {
            ComponentConfiguration componentConfiguration = it.next();
            if (componentConfiguration.getName().equals(name)) {
                return componentConfiguration;
            }
        }
        throw new MojoExecutionException("Could not get ConfigurationTask.");
    }
View Full Code Here

TOP

Related Classes of org.codehaus.mojo.hibernate3.configuration.ComponentConfiguration

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.