Package org.apache.cayenne.tools.configuration

Examples of org.apache.cayenne.tools.configuration.ToolsModule


        tempMap.encodeAsXML(new XMLEncoder(writer));
        writer.close();
        assertTrue(out.isFile());

        Log log = mock(Log.class);
        Injector i = DIBootstrap.createInjector(new ToolsModule(log), new DbImportModule());

        DbImportAction action = i.getInstance(DbImportAction.class);

        DbImportParameters parameters = new DbImportParameters();
        parameters.setDataMapFile(out);
View Full Code Here


                dropTables, dropPK, createTables, createPK, createFK), Project.MSG_VERBOSE);

        validateAttributes();

        ClassLoader loader = null;
        Injector injector = DIBootstrap.createInjector(new ToolsModule(logger));
        try {
            loader = Thread.currentThread().getContextClassLoader();
            Thread.currentThread().setContextClassLoader(DbGeneratorTask.class.getClassLoader());

            // Load the data map and run the db generator.
View Full Code Here

        initMeaningfulPkTables();

        validateAttributes();

        Log logger = new AntLogger(this);
        Injector injector = DIBootstrap.createInjector(new ToolsModule(logger), new DbImportModule());

        try {
            injector.getInstance(DbImportAction.class).execute(parameters);
        } catch (final Exception ex) {
            final Throwable th = Util.unwindException(ex);
View Full Code Here

    private boolean createFK;

    public void execute() throws MojoExecutionException, MojoFailureException {

        Log logger = new MavenLogger(this);
        Injector injector = DIBootstrap.createInjector(new ToolsModule(logger));
        AdhocObjectFactory objectFactory = injector.getInstance(AdhocObjectFactory.class);

        logger.info(String.format("connection settings - [driver: %s, url: %s, username: %s]", driver, url, username));

        logger.info(String.format(
View Full Code Here

    public void execute() throws MojoExecutionException, MojoFailureException {

        Log logger = new MavenLogger(this);

        DbImportParameters parameters = toParameters();
        Injector injector = DIBootstrap.createInjector(new ToolsModule(logger), new DbImportModule());

        try {
            injector.getInstance(DbImportAction.class).execute(parameters);
        } catch (Exception ex) {
            Throwable th = Util.unwindException(ex);
View Full Code Here

TOP

Related Classes of org.apache.cayenne.tools.configuration.ToolsModule

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.