Examples of DriverDescriptor


Examples of org.jitterbit.integration.database.driver.DriverDescriptor

        DriverDescriptor driver = OdbcDriverDescriptorFactory.createDescriptor("Postgresql", quotes);
        persist(driver, ODBC_FILE);
    }

    private void testPersistJdbc() throws Exception {
        DriverDescriptor driver = new JdbcDriverDescriptor("Postgresql", "jdbc:postgresql://%s/%s",
                        "org.postgresql.Driver", new BeginEndQuote("\""));
        persist(driver, JDBC_FILE);
    }
View Full Code Here

Examples of org.jitterbit.integration.database.driver.DriverDescriptor

        XmlPersistor p = XmlPersistor.load(file);
        restore(p);
    }

    private void restore(Persistor p) {
        DriverDescriptor driver = DriverDescriptorPersistor.restore(p);
        driver.accept(new ConsoleWriter());
    }
View Full Code Here

Examples of org.jitterbit.integration.database.driver.DriverDescriptor

    }

    @Override
    public void testDatabase(Source src, DatabaseLocation dbLoc, DatabaseConnectionCallback callback) {
        try {
            DriverDescriptor driver = dbLoc.getDriver();
            if (driver instanceof JdbcDriverDescriptor) {
                testJdbcSource(src, dbLoc, callback);
            } else {
                testOdbcSource(src, dbLoc, callback);
            }
View Full Code Here

Examples of org.jitterbit.integration.database.driver.DriverDescriptor

    }

    @Override
    public void testDatabase(Target tgt, DatabaseLocation dbLoc, DatabaseConnectionCallback callback) {
        try {
            DriverDescriptor driver = dbLoc.getDriver();
            if (driver instanceof JdbcDriverDescriptor) {
                testJdbcTarget(tgt, dbLoc, callback);
            } else {
                testOdbcTarget(tgt, dbLoc, callback);
            }
View Full Code Here

Examples of org.jitterbit.integration.database.driver.DriverDescriptor

        return isInformix(dbStruct) && !dbStruct.hasManualSqlStatement() && !dbStruct.getIncludeRowIdInInformixTables();
    }

    private boolean isInformix(DatabaseStructure dbStruct) {
        ConnectionParams params = dbStruct.getConnectionParameters();
        DriverDescriptor driver = params.getDriver();
        return InformixUtils.isInformix(driver);
    }
View Full Code Here

Examples of org.jitterbit.integration.database.driver.DriverDescriptor

        int type = persistor.getInteger(TYPE);
        String name = persistor.getString(NAME);
        String beginQuote = persistor.getString(BEGIN_QUOTE);
        String endQuote = persistor.getString(END_QUOTE);
        BeginEndQuote quotes = BeginEndQuote.fromStrings(beginQuote, endQuote);
        DriverDescriptor driver = null;
        if (type == ODBC_TYPE) {
            driver = OdbcDriverDescriptorFactory.createDescriptor(name, quotes);
        } else if (type == JDBC_TYPE) {
            driver = new JdbcDriverDesriptorBuilder()
                .name(name)
View Full Code Here

Examples of org.jitterbit.integration.database.driver.DriverDescriptor

    private Collection<DriverDescriptor> readFromFile(File file) throws IOException {
        Collection<DriverDescriptor> drivers = Sets.newHashSet();
        try {
            XmlPersistor persistor = XmlPersistor.load(file);
            for (Persistor driverPersistor : persistor.getChildren("Driver")) {
                DriverDescriptor driver = DriverDescriptorPersistor.restore(driverPersistor);
                drivers.add(driver);
            }
        } catch (SAXException ex) {
            oldFormatFile(file, ex);
        }
View Full Code Here

Examples of org.jitterbit.integration.database.driver.DriverDescriptor

    private class DriverSelectionListener implements SelectionListener {

        @Override
        public void selectionChanged(SelectionChangedEvent evt) {
            DriverDescriptor selected = getSelectedDriver();
            for (DriverSelectorViewListener lst : listeners) {
                lst.driverSelectionChanged(selected);
            }
        }
View Full Code Here

Examples of org.jitterbit.integration.database.driver.DriverDescriptor

            useOkAndCancel();
        }

        @Override
        protected void onOk() {
            DriverDescriptor selected = view.getSelectedDriver();
            if (selected != null) {
                callback.handle(selected);
            }
            super.onOk();
        }
View Full Code Here

Examples of org.jitterbit.integration.database.driver.DriverDescriptor

        handlePreConnectionError(st, message, title);
    }

    private boolean checkAutomaticMode(SourceTarget st) {
        try {
            DriverDescriptor driver = dbLocation.getDriver();
            assert (driver != null);
            ConnectionParams params = dbLocation.getConnectionParams();
            driver.checkConnectionParams(params);
            return true;
        } catch (InvalidConnectionParamsException ex) {
            handlePreConnectionError(st, ex);
            return false;
        }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.