Package org.jitterbit.integration.data.entity

Examples of org.jitterbit.integration.data.entity.Source


    private void checkTransformation(OperationPipeline pipeline) {
        TransformationPipelineBrowser browser = new TransformationPipelineBrowser(pipeline);
        Transformation tx = browser.getTransformation();
        if (tx != null) {
            if (tx.isXmlSourceEdi()) {
                Source s = browser.getSource();
                applyPluginToSourceOrTarget(s);
            }
            if (tx.isXmlTargetEdi()) {
                Target t = browser.getTarget();
                applyPluginToSourceOrTarget(t);
View Full Code Here


    private void checkWebServiceCall(OperationPipeline pipeline) {
        WebServicePipelineBrowser browser = new WebServicePipelineBrowser(pipeline);
        Transformation request = browser.getRequest();
        if (request != null && request.isXmlSourceEdi()) {
            Source s = browser.getSource();
            applyPluginToSourceOrTarget(s);
        }
        Transformation response = browser.getResponse();
        if (response != null && response.isXmlTargetEdi()) {
            Target t = browser.getTarget();
View Full Code Here

        }
        return nextPageCache.get(new CacheKey(location, manualModeSwitch.isSelected()));
    }

    private WizardPage createNewNextPage(DatabaseLocation location) {
        Source source = getSelectedEntity();
        boolean selected = manualModeSwitch.isSelected();
        WizardPage next;
        if (selected) {
            next = new ManualSqlStatementPage(getWizard(), source, location);
            transferManualSqlStatementIfNeeded((ManualSqlStatementPage) next);
        } else {
            DatabaseTableSelectionPage tableSelectionPage = new DatabaseTableSelectionPage(
                            getWizard(), location, source.getID(), null, SourceTarget.Source, singleTableOnly);
            tableSelectionPage.setUpdateSourceTableAvailable(updateSourceTableAvailable);
            next = tableSelectionPage;
        }
        nextPageCache.put(new CacheKey(location, selected), next);
        return next;
View Full Code Here

        return next;
    }

    @Override
    public void applyTo(DatabaseStructure s) {
        Source source = getSelectedEntity();
        if (source != null) {
            // This cast is safe because we have filtered out all non-database sources:
            DatabaseLocation loc = (DatabaseLocation) source.getLocation();
            s.setDbLocation(loc);
            s.setSourceId(source.getID());
        } else {
            // This will never happen because a source must have been
            // specified before the wizard could leave this page.
            throw new RuntimeException("Tried to complete a database structure wizard without a DB source. " +
                    "This is a bug.");
View Full Code Here

     * <code>Transformation</code> and the <code>Target</code> (which is auto-completed by the
     * wizard before this call).
     */
    public void doAdditionalConfiguration(OperationPipeline pipeline) {
        SourcePages sourcePages = (SourcePages) getSourcePages();
        Source source = sourcePages.getSource();
        TransformationPipelineBrowser browser = new TransformationPipelineBrowser(pipeline);
        browser.setSource(source);
    }
View Full Code Here

     * wizard before this call).
     */
    @SuppressWarnings("unchecked")
    public void doAdditionalConfiguration(OperationPipeline pipeline) {
        XmlPageChain<Source> sourcePages = (XmlPageChain<Source>) getSourcePages();
        Source source = sourcePages.getLocation();
        TransformationPipelineBrowser browser = new TransformationPipelineBrowser(pipeline);
        browser.setSource(source);
    }
View Full Code Here

    private Dependencies deps;
   
    @Before
    public void setup() {
        op = new Operation("op");
        source = new Source("source");
        tf = new Transformation("tf");
        target = new Target("target");
        script = new Script("script");
        opCalledFromScript = new Operation("opCalledFromScript");
        deps = new Dependencies();
View Full Code Here

            return getPreconfiguredSourceTypeMessage(in);
        }
    }

    private DataStructureType getSourceTypeFromPreconfiguredSource() {
        Source source = getPreconfiguredSource();
        return getDataStructureTypeFromLocatable(source);
    }
View Full Code Here

    public void ensureCopyWorks() {
        User torgil = new User("Torgil");
        User bahamas = new User("Bahamas");
        Permissions fullAccess = Permissions.fullControl();
        Permissions readOnly = new Permissions(EnumSet.of(Permission.READ), null);
        Source original = new Source("S1");
        Source copy = new Source("S2");
        UserMap map = new UserMap();
        map.put(original.getID(), torgil.getId(), fullAccess);
        map.put(original.getID(), bahamas.getId(), readOnly);
        map.setClean();
        map.copy(original.getID(), copy.getID());
        assertTrue(map.isDirty());
        assertEquals(fullAccess, map.get(copy.getID(), torgil.getId()));
        assertEquals(readOnly, map.get(copy.getID(), bahamas.getId()));
        // Ensure changing permissions on original does not affect copy:
        map.put(original.getID(), torgil.getId(), readOnly);
        assertEquals(fullAccess, map.get(copy.getID(), torgil.getId()));
    }
View Full Code Here

    @Test
    public void ensureAutomaticDeployWorks() {
        ByPassedDeployPrompt adaptee = new ByPassedDeployPrompt();
        BooleanPreference pref = createPreference(true);
        PreferenceCheckingDeployPrompt prompt = new PreferenceCheckingDeployPrompt(adaptee, pref);
        List<Source> dirty = Arrays.asList(new Source("S"));
        assertTrue(prompt.prompt(null, dirty));
        assertEquals(dirty, prompt.getDirtyItemsToDeploy());
        adaptee.ensureNotCalled();
    }
View Full Code Here

TOP

Related Classes of org.jitterbit.integration.data.entity.Source

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.