Search in sources :

Example 1 with MAPAggregator

use of org.apache.cxf.ws.addressing.MAPAggregator in project cxf by apache.

the class RMInInterceptorTest method testOrdering.

@Test
public void testOrdering() {
    control.replay();
    Phase p = new Phase(Phase.PRE_LOGICAL, 1);
    SortedSet<Phase> phases = new TreeSet<Phase>();
    phases.add(p);
    PhaseInterceptorChain chain = new PhaseInterceptorChain(phases);
    MAPAggregator map = new MAPAggregator();
    RMInInterceptor rmi = new RMInInterceptor();
    chain.add(rmi);
    chain.add(map);
    Iterator<Interceptor<? extends Message>> it = chain.iterator();
    assertSame("Unexpected order.", rmi, it.next());
    assertSame("Unexpected order.", map, it.next());
}
Also used : PhaseInterceptorChain(org.apache.cxf.phase.PhaseInterceptorChain) Phase(org.apache.cxf.phase.Phase) Message(org.apache.cxf.message.Message) TreeSet(java.util.TreeSet) MAPAggregator(org.apache.cxf.ws.addressing.MAPAggregator) Interceptor(org.apache.cxf.interceptor.Interceptor) Test(org.junit.Test)

Example 2 with MAPAggregator

use of org.apache.cxf.ws.addressing.MAPAggregator in project cxf by apache.

the class FailoverAddressOverrideTest method enableWSAForCurrentEndpoint.

protected void enableWSAForCurrentEndpoint() {
    Endpoint provider = ClientProxy.getClient(greeter).getEndpoint();
    mapAggregator = new MAPAggregator();
    mapCodec = MAPCodec.getInstance(ClientProxy.getClient(greeter).getBus());
    provider.getInInterceptors().add(mapAggregator);
    provider.getInInterceptors().add(mapCodec);
    provider.getOutInterceptors().add(mapAggregator);
    provider.getOutInterceptors().add(mapCodec);
    provider.getInFaultInterceptors().add(mapAggregator);
    provider.getInFaultInterceptors().add(mapCodec);
    provider.getOutFaultInterceptors().add(mapAggregator);
    provider.getOutFaultInterceptors().add(mapCodec);
}
Also used : Endpoint(org.apache.cxf.endpoint.Endpoint) MAPAggregator(org.apache.cxf.ws.addressing.MAPAggregator)

Example 3 with MAPAggregator

use of org.apache.cxf.ws.addressing.MAPAggregator in project cxf by apache.

the class FailoverTest method enableWSAForCurrentEndpoint.

protected void enableWSAForCurrentEndpoint() {
    Endpoint provider = ClientProxy.getClient(greeter).getEndpoint();
    mapAggregator = new MAPAggregator();
    mapCodec = MAPCodec.getInstance(ClientProxy.getClient(greeter).getBus());
    provider.getInInterceptors().add(mapAggregator);
    provider.getInInterceptors().add(mapCodec);
    provider.getOutInterceptors().add(mapAggregator);
    provider.getOutInterceptors().add(mapCodec);
    provider.getInFaultInterceptors().add(mapAggregator);
    provider.getInFaultInterceptors().add(mapCodec);
    provider.getOutFaultInterceptors().add(mapAggregator);
    provider.getOutFaultInterceptors().add(mapCodec);
}
Also used : Endpoint(org.apache.cxf.endpoint.Endpoint) MAPAggregator(org.apache.cxf.ws.addressing.MAPAggregator)

Aggregations

MAPAggregator (org.apache.cxf.ws.addressing.MAPAggregator)3 Endpoint (org.apache.cxf.endpoint.Endpoint)2 TreeSet (java.util.TreeSet)1 Interceptor (org.apache.cxf.interceptor.Interceptor)1 Message (org.apache.cxf.message.Message)1 Phase (org.apache.cxf.phase.Phase)1 PhaseInterceptorChain (org.apache.cxf.phase.PhaseInterceptorChain)1 Test (org.junit.Test)1