Package org.jitterbit.integration.data.entity

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


        }

        @Override
        public void setValue(IntegrationEntity dataObject, String value) {
            FieldDelimiter delimiter = FieldDelimiter.fromString(value);
            TextDocument doc = (TextDocument) dataObject;
            doc.setDelimiter(delimiter);
        }
View Full Code Here


            doc.setDelimiter(delimiter);
        }

        @Override
        public String getValue(IntegrationEntity dataObject) {
            TextDocument doc = (TextDocument) dataObject;
            FieldDelimiter delimiter = doc.getDelimiter();
            return (delimiter != null) ? delimiter.toEscapedString() : null;
        }
View Full Code Here

        }

        @Override
        public StringList getValue(IntegrationEntity dataObject) {
            StringList list = new StringList();
            TextDocument doc = (TextDocument) dataObject;
            TextStructure struct = doc.getDataStructure();
            if (struct instanceof ComplexTextStructure) {
                for (Segment s : ((ComplexTextStructure) struct)) {
                    list.add(s.getName());
                }
            }
View Full Code Here

        }

        @Override
        public StringList getValue(IntegrationEntity dataObject) {
            StringList list = new StringList();
            TextDocument doc = (TextDocument) dataObject;
            TextStructure struct = doc.getDataStructure();
            if (struct instanceof ComplexTextStructure) {
                for (Segment s : ((ComplexTextStructure) struct)) {
                    collectFields(s, list);
                }
            } else if (struct instanceof SimpleTextStructure) {
View Full Code Here

            return delegate.hasPreviousPage(page);
        }

        @Override
        public void applyTo(Transformation tf) throws WizardPageException {
            TextDocument doc = delegate.getSelectedDocument();
            if (doc != null) {
                DataStructure structure = doc.getDataStructure();
                tf.setInputStructure(structure);
                tf.setSourceTextDocumentId(doc.getID());
            } else {
                // This will happen if the user deletes the text document before completing the wizard
                throw new WizardPageException(delegate.getFirstPage(), "Must select a text document");
            }
        }
View Full Code Here

            return delegate.hasPreviousPage(page);
        }

        @Override
        public void applyTo(Transformation tf) throws WizardPageException {
            TextDocument doc = delegate.getSelectedDocument();
            if (doc != null) {
                DataStructure structure = doc.getDataStructure();
                tf.setOutputStructure(structure);
                tf.setTargetTextDocumentId(doc.getID());
            } else {
                // This will happen if the user deletes the text document before completing the wizard
                throw new WizardPageException(delegate.getFirstPage(), "Must select a text document");
            }
        }
View Full Code Here

    private void onSameSourceAndTargetDocument(TransformationDocumentLinkFactory linkFactory) {
        EntityLink link = linkFactory.getInputAndOutputLink();
        if (link != null) {
            collectedLinks.add(link);
            TextDocument doc = (TextDocument) link.getMainObject();
            inputStructure = doc.getDataStructure();
            outputStructure = doc.getDataStructure();
        }
    }
View Full Code Here

    private void collectSourceDocumentLink(TransformationDocumentLinkFactory linkFactory) {
        EntityLink link = linkFactory.getInputLink();
        if (link != null) {
            collectedLinks.add(link);
            TextDocument doc = (TextDocument) link.getMainObject();
            inputStructure = doc.getDataStructure();
        }
    }
View Full Code Here

    private void collectTargetDocumentLink(TransformationDocumentLinkFactory linkFactory) {
        EntityLink link = linkFactory.getOutputLink();
        if (link != null) {
            collectedLinks.add(link);
            TextDocument doc = (TextDocument) link.getMainObject();
            outputStructure = doc.getDataStructure();
        }
    }
View Full Code Here

    }

    public EntityLink getInputLink() {
        TextDocumentId docId = transformation.getSourceTextDocumentId();
        if (docId != null) {
            TextDocument doc = dataLookup.getEntity(docId, TextDocument.class);
            if (doc != null) {
                return new StrongEntityLink(doc, transformation);
            }
            LinkUtils.logMissingLink(transformation, EntityType.Document, docId);
        }
View Full Code Here

TOP

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

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.