Package org.apache.camel.model

Examples of org.apache.camel.model.RoutingSlipDefinition


    private RoutingSlipDefinitionRenderer() {
        // Utility class, no public or protected default constructor
    }   

    public static void render(StringBuilder buffer, ProcessorDefinition processor) {
        RoutingSlipDefinition routingSlip = (RoutingSlipDefinition)processor;
        buffer.append(".").append(routingSlip.getShortName()).append("(\"").append(routingSlip.getHeaderName())
            .append("\", \"").append(routingSlip.getUriDelimiter()).append("\")");
    }
View Full Code Here


    private RoutingSlipDefinitionRenderer() {
        // Utility class, no public or protected default constructor
    }   

    public static void render(StringBuilder buffer, ProcessorDefinition<?> processor) {
        RoutingSlipDefinition routingSlip = (RoutingSlipDefinition)processor;
        buffer.append(".").append(routingSlip.getShortName()).append("(\"").append(routingSlip.getHeaderName()).append("\", \"").append(routingSlip.getUriDelimiter())
            .append("\")");
    }
View Full Code Here

    }

    @SuppressWarnings("rawtypes")
    @Override
    public ProcessorDefinition createCamelDefinition() {
        RoutingSlipDefinition answer = new RoutingSlipDefinition();

        answer.setInheritErrorHandler(toXmlPropertyValue(PROPERTY_INHERITERRORHANDLER, Objects.<Boolean>getField(this, "inheritErrorHandler")));
        answer.setExpression(toXmlPropertyValue(PROPERTY_EXPRESSION, this.getExpression()));
        answer.setUriDelimiter(toXmlPropertyValue(PROPERTY_URIDELIMITER, this.getUriDelimiter()));
        answer.setIgnoreInvalidEndpoints(toXmlPropertyValue(PROPERTY_IGNOREINVALIDENDPOINTS, this.getIgnoreInvalidEndpoints()));
        answer.setCacheSize(toXmlPropertyValue(PROPERTY_CACHESIZE, this.getCacheSize()));

        super.savePropertiesToCamelDefinition(answer);
        return answer;
    }
View Full Code Here

    @Override
    protected void loadPropertiesFromCamelDefinition(ProcessorDefinition processor) {
        super.loadPropertiesFromCamelDefinition(processor);

        if (processor instanceof RoutingSlipDefinition) {
            RoutingSlipDefinition node = (RoutingSlipDefinition) processor;

            this.setInheritErrorHandler(Objects.<Boolean>getField(node, "inheritErrorHandler"));
            this.setExpression(node.getExpression());
            this.setUriDelimiter(node.getUriDelimiter());
            this.setIgnoreInvalidEndpoints(node.getIgnoreInvalidEndpoints());
            this.setCacheSize(node.getCacheSize());
        } else {
            throw new IllegalArgumentException("ProcessorDefinition not an instanceof RoutingSlipDefinition. Was " + processor.getClass().getName());
        }
    }
View Full Code Here

TOP

Related Classes of org.apache.camel.model.RoutingSlipDefinition

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.