Examples of DataFormat


Examples of org.apache.camel.spi.DataFormat

        this.lazyLoad = lazyLoad;
    }

    @Override
    protected DataFormat createDataFormat(RouteContext routeContext) {
        DataFormat csvFormat = super.createDataFormat(routeContext);

        if (ObjectHelper.isNotEmpty(configRef)) {
            Object config = CamelContextHelper.mandatoryLookup(routeContext.getCamelContext(), configRef);
            setProperty(routeContext.getCamelContext(), csvFormat, "config", config);
        }
View Full Code Here

Examples of org.apache.camel.spi.DataFormat

    public void setDataFormatResolver(DataFormatResolver dataFormatResolver) {
        this.dataFormatResolver = dataFormatResolver;
    }

    public DataFormat resolveDataFormat(String name) {
        DataFormat answer = dataFormatResolver.resolveDataFormat(name, this);

        // inject CamelContext if aware
        if (answer != null && answer instanceof CamelContextAware) {
            ((CamelContextAware) answer).setCamelContext(this);
        }
View Full Code Here

Examples of org.apache.camel.spi.DataFormat

    public void setDataFormatResolver(DataFormatResolver dataFormatResolver) {
        this.dataFormatResolver = dataFormatResolver;
    }

    public DataFormat resolveDataFormat(String name) {
        DataFormat answer = dataFormatResolver.resolveDataFormat(name, this);

        // inject CamelContext if aware
        if (answer != null && answer instanceof CamelContextAware) {
            ((CamelContextAware) answer).setCamelContext(this);
        }
View Full Code Here

Examples of org.apache.camel.spi.DataFormat

        this.dataFormatType = dataFormatType;
    }

    @Override
    public Processor createProcessor(RouteContext routeContext) {
        DataFormat dataFormat = DataFormatType.getDataFormat(routeContext, getDataFormatType(), ref);
        return new UnmarshalProcessor(dataFormat);
    }
View Full Code Here

Examples of org.apache.camel.spi.DataFormat

        this.dataFormatType = dataFormatType;
    }

    @Override
    public Processor createProcessor(RouteContext routeContext) {
        DataFormat dataFormat = DataFormatType.getDataFormat(routeContext, getDataFormatType(), ref);
        return new MarshalProcessor(dataFormat);
    }
View Full Code Here

Examples of org.apache.camel.spi.DataFormat

        this.dataFormatType = dataFormatType;
    }

    @Override
    public Processor createProcessor(RouteContext routeContext) {
        DataFormat dataFormat = DataFormatType.getDataFormat(routeContext, getDataFormatType(), ref);
        return new UnmarshalProcessor(dataFormat);
    }
View Full Code Here

Examples of org.apache.camel.spi.DataFormat

    }

    public static DataFormat getDataFormat(RouteContext routeContext, DataFormatType type, String ref) {
        if (type == null) {
            notNull(ref, "ref or dataFormatType");
            DataFormat dataFormat = routeContext.lookup(ref, DataFormat.class);
           
            if (dataFormat == null) {
                dataFormat = routeContext.getDataFormat(ref);
            }
           
View Full Code Here

Examples of org.apache.camel.spi.DataFormat

    @Override
    protected RouteBuilder createRouteBuilder() throws Exception {
        return new RouteBuilder() {
            public void configure() throws Exception {
                // START SNIPPET: e1
                DataFormat hl7 = new HL7DataFormat();
                // we setup or HL7 listener on port 8888 (using the hl7codec) and in sync mode so we can return a response
                from("mina:tcp://localhost:8888?sync=true&codec=hl7codec")
                    // we use the HL7 data format to unmarshal from HL7 stream to the HAPI Message model
                    // this ensures that the camel message has been enriched with hl7 specific headers to
                    // make the routing much easier (see below)
View Full Code Here

Examples of org.apache.camel.spi.DataFormat

        this.dataFormatType = dataFormatType;
    }

    @Override
    public Processor createProcessor(RouteContext routeContext) {
        DataFormat dataFormat = DataFormatType.getDataFormat(routeContext, getDataFormatType(), ref);
        return new MarshalProcessor(dataFormat);
    }
View Full Code Here

Examples of org.apache.camel.spi.DataFormat

    protected RouteBuilder createRouteBuilder() {
        return new RouteBuilder() {
            public void configure() {

                DataFormat jaxb = new JaxbDataFormat("org.apache.camel.example");

                from("direct:start").
                        marshal(jaxb).
                        to("direct:marshalled");
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.