Package org.apache.synapse.endpoints

Examples of org.apache.synapse.endpoints.IndirectEndpoint


    }

    protected Endpoint createEndpoint(OMElement epConfig, boolean anonymousEndpoint,
                                      Properties properties) {

        IndirectEndpoint indirectEndpoint = new IndirectEndpoint();
        String ref = epConfig.getAttributeValue(new QName("key"));
        String name = epConfig.getAttributeValue(new QName("name"));
        if (name != null) {
            indirectEndpoint.setName(name);
        }
        indirectEndpoint.setKey(ref);

        // process the parameters
        processProperties(indirectEndpoint, epConfig);

        return indirectEndpoint;
View Full Code Here


        }

        fac = OMAbstractFactory.getOMFactory();
        OMElement endpointElement = fac.createOMElement("endpoint", SynapseConstants.SYNAPSE_OMNAMESPACE);

        IndirectEndpoint indirectEndpoint = (IndirectEndpoint) endpoint;
        String ref = indirectEndpoint.getKey();
        if (ref != null) {
            endpointElement.addAttribute("key", ref, null);
        }

        // serialize the parameters
View Full Code Here

        log.error(msg, e);
        throw new AxisFault(msg, e);
    }

    public Endpoint getEndpoint(String name){
        IndirectEndpoint iep = new IndirectEndpoint();
        iep.setKey(name);
        return iep;
    }
View Full Code Here

        LoadbalanceEndpoint lb = new LoadbalanceEndpoint();
        lb.setName("lb");
        lb.setDefinition(new EndpointDefinition());

        IndirectEndpoint child1 = new IndirectEndpoint();
        child1.setKey(endpoint1.getName());
        IndirectEndpoint child2 = new IndirectEndpoint();
        child2.setKey(endpoint2.getName());
        Endpoint child3 = createEndpoint("baz");

        List<Endpoint> children = new ArrayList<Endpoint>();
        children.add(child1);
        children.add(child2);
        children.add(child3);
        lb.setChildren(children);

        synapseConfig.addEndpoint(lb.getName(), lb);
        assertDependency(ConfigurationObject.TYPE_ENDPOINT, child1.getKey(), lb.getName());
        assertDependency(ConfigurationObject.TYPE_ENDPOINT, child2.getKey(), lb.getName());
        assertNoDependency(ConfigurationObject.TYPE_ENDPOINT, child3.getName());
    }
View Full Code Here

        }

        SendMediator sendMediator = (SendMediator) m;
        Endpoint endpoint = sendMediator.getEndpoint();
        if (endpoint instanceof IndirectEndpoint) {
            IndirectEndpoint indirect = (IndirectEndpoint) endpoint;
            List<ConfigurationObject> providers = new ArrayList<ConfigurationObject>();
            providers.add(new ConfigurationObject(ConfigurationObject.TYPE_ENDPOINT,
                    indirect.getKey()));
            return providers;
        }
        return null;
    }
View Full Code Here

            addProvider(new ConfigurationObject(ConfigurationObject.TYPE_SEQUENCE,
                    target.getSequenceRef()), providers);
        }

        if (target.getEndpoint() != null && target.getEndpoint() instanceof IndirectEndpoint) {
            IndirectEndpoint indirectEndpoint = (IndirectEndpoint) target.getEndpoint();
            addProvider(new ConfigurationObject(ConfigurationObject.TYPE_ENDPOINT,
                    indirectEndpoint.getKey()), providers);
        }

        if (target.getSequence() != null) {
            DependencyResolver resolver = DependencyResolverFactory.getInstance().
                    getResolver(target.getSequence());
View Full Code Here

        }

        fac = OMAbstractFactory.getOMFactory();
        OMElement endpointElement = fac.createOMElement("endpoint", Constants.SYNAPSE_OMNAMESPACE);

        IndirectEndpoint indirectEndpoint = (IndirectEndpoint) endpoint;
        String ref = indirectEndpoint.getKey();
        if (ref != null) {
            endpointElement.addAttribute("key", ref, null);
        }

        return endpointElement;
View Full Code Here

        }

        fac = OMAbstractFactory.getOMFactory();
        OMElement endpointElement = fac.createOMElement("endpoint", SynapseConstants.SYNAPSE_OMNAMESPACE);

        IndirectEndpoint indirectEndpoint = (IndirectEndpoint) endpoint;
        String ref = indirectEndpoint.getKey();
        if (ref != null) {
            endpointElement.addAttribute("key", ref, null);
        }

        return endpointElement;
View Full Code Here

        return instance;
    }

    public Endpoint createEndpoint(OMElement epConfig, boolean anonymousEndpoint) {

        IndirectEndpoint indirectEndpoint = new IndirectEndpoint();
        String ref = epConfig.getAttributeValue(new QName("key"));
        indirectEndpoint.setKey(ref);
        return indirectEndpoint;
    }
View Full Code Here

        }

        fac = OMAbstractFactory.getOMFactory();
        OMElement endpointElement = fac.createOMElement("endpoint", SynapseConstants.SYNAPSE_OMNAMESPACE);

        IndirectEndpoint indirectEndpoint = (IndirectEndpoint) endpoint;
        String ref = indirectEndpoint.getKey();
        if (ref != null) {
            endpointElement.addAttribute("key", ref, null);
        }

        return endpointElement;
View Full Code Here

TOP

Related Classes of org.apache.synapse.endpoints.IndirectEndpoint

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.