当前位置: 首页>>代码示例>>Java>>正文


Java TransportOutDescription.setSender方法代码示例

本文整理汇总了Java中org.apache.axis2.description.TransportOutDescription.setSender方法的典型用法代码示例。如果您正苦于以下问题:Java TransportOutDescription.setSender方法的具体用法?Java TransportOutDescription.setSender怎么用?Java TransportOutDescription.setSender使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在org.apache.axis2.description.TransportOutDescription的用法示例。


在下文中一共展示了TransportOutDescription.setSender方法的10个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: getClientCfgCtx

import org.apache.axis2.description.TransportOutDescription; //导入方法依赖的package包/类
public ConfigurationContext getClientCfgCtx() throws Exception {
    ConfigurationContext cfgCtx =
        ConfigurationContextFactory.createConfigurationContext(new CustomAxisConfigurator());
    AxisConfiguration axisCfg = cfgCtx.getAxisConfiguration();
    axisCfg.engageModule("addressing");

    TransportInDescription trpInDesc = new TransportInDescription("udp");
    trpInDesc.setReceiver(new UDPListener());
    axisCfg.addTransportIn(trpInDesc);
    
    TransportOutDescription trpOutDesc = new TransportOutDescription("udp");
    trpOutDesc.setSender(new UDPSender());
    axisCfg.addTransportOut(trpOutDesc);
    
    return cfgCtx;
}
 
开发者ID:wso2,项目名称:wso2-axis2-transports,代码行数:17,代码来源:UDPTest.java

示例2: UtilsUDPServer

import org.apache.axis2.description.TransportOutDescription; //导入方法依赖的package包/类
public UtilsUDPServer() throws Exception {
    TransportInDescription trpInDesc = new TransportInDescription("udp");
    trpInDesc.setReceiver(new UDPListener());
    TransportOutDescription trpOutDesc = new TransportOutDescription("udp");
    trpOutDesc.setSender(new UDPSender());
    addTransport(trpInDesc, trpOutDesc);
    enableAddressing();
    
    List<Parameter> params = new LinkedList<Parameter>();
    params.add(new Parameter(UDPConstants.PORT_KEY, 3333));
    params.add(new Parameter(UDPConstants.CONTENT_TYPE_KEY, "text/xml+soap"));
    deployEchoService("EchoService", params);
}
 
开发者ID:wso2,项目名称:wso2-axis2-transports,代码行数:14,代码来源:UtilsUDPServer.java

示例3: createTransportOutDescription

import org.apache.axis2.description.TransportOutDescription; //导入方法依赖的package包/类
public TransportOutDescription createTransportOutDescription() throws Exception {
    TransportOutDescription trpOutDesc = new TransportOutDescription(MailConstants.TRANSPORT_NAME);
    trpOutDesc.setSender(new MailTransportSender());
    trpOutDesc.addParameter(new Parameter(MailConstants.TRANSPORT_MAIL_DEBUG, "true"));
    for (Map.Entry<String,String> prop : getOutProperties().entrySet()) {
        trpOutDesc.addParameter(new Parameter(prop.getKey(), prop.getValue()));
    }
    return trpOutDesc;
}
 
开发者ID:wso2,项目名称:wso2-axis2-transports,代码行数:10,代码来源:MailTestEnvironment.java

示例4: createTransportOutDescription

import org.apache.axis2.description.TransportOutDescription; //导入方法依赖的package包/类
public TransportOutDescription createTransportOutDescription() throws Exception {
    TransportOutDescription trpOutDesc = new TransportOutDescription(JMSSender.TRANSPORT_NAME);
    if (cfOnSender) {
        setupTransport(trpOutDesc);
    }
    trpOutDesc.setSender(new JMSSender());
    return trpOutDesc;
}
 
开发者ID:wso2,项目名称:wso2-axis2-transports,代码行数:9,代码来源:JMSTransportDescriptionFactory.java

示例5: setUp

import org.apache.axis2.description.TransportOutDescription; //导入方法依赖的package包/类
protected void setUp() throws Exception {
        // Configuration - server side
        serverCtx = ConfigurationContextFactory.
                createConfigurationContextFromFileSystem(null);
        serverConfig = serverCtx.getAxisConfiguration();
        LocalTransportReceiver.CONFIG_CONTEXT = new ConfigurationContext(serverConfig);
        LocalTransportReceiver.CONFIG_CONTEXT.setServicePath("services");
        LocalTransportReceiver.CONFIG_CONTEXT.setContextRoot("local:/");
        TransportOutDescription tOut = new TransportOutDescription(Constants.TRANSPORT_LOCAL);
        tOut.setSender(new LocalTransportSender());
        serverConfig.addTransportOut(tOut);

//        addInPhases(serverConfig.getInFlowPhases());
//        DispatchPhase dp = (DispatchPhase)serverConfig.getInFlowPhases().get(1);
//        dp.addHandler(new AddressingBasedDispatcher());
//
//        addInPhases(serverConfig.getInFaultFlowPhases());
//
//        addOutPhases(serverConfig.getOutFlowPhases());
//        addOutPhases(serverConfig.getOutFaultFlowPhases());

        ///////////////////////////////////////////////////////////////////////
        // Set up raw message receivers for OMElement based tests

        serverConfig.addMessageReceiver(WSDL2Constants.MEP_URI_IN_ONLY,
                                        new RawXMLINOnlyMessageReceiver());
        serverConfig.addMessageReceiver(WSDL2Constants.MEP_URI_IN_OUT,
                                        new RawXMLINOutMessageReceiver());
        serverConfig.addMessageReceiver(WSDL2Constants.MEP_URI_ROBUST_IN_ONLY,
                                        new RawXMLINOutMessageReceiver());

        ///////////////////////////////////////////////////////////////////////
        // And client side
        clientCtx = ConfigurationContextFactory.createConfigurationContextFromFileSystem(null);
    }
 
开发者ID:wso2,项目名称:wso2-axis2,代码行数:36,代码来源:LocalTestCase.java

示例6: getOptions

import org.apache.axis2.description.TransportOutDescription; //导入方法依赖的package包/类
/**
 * Get an Options object initialized with the right transport info, defaulting to SOAP 1.2
 *
 * @return pre-initialized Options object
 */
protected Options getOptions() {
    TransportOutDescription td = new TransportOutDescription("local");
    td.setSender(sender);

    Options opts = new Options();
    opts.setTransportOut(td);
    opts.setSoapVersionURI(SOAP12Constants.SOAP_ENVELOPE_NAMESPACE_URI);
    return opts;
}
 
开发者ID:wso2,项目名称:wso2-axis2,代码行数:15,代码来源:LocalTestCase.java

示例7: EnginePausingTest

import org.apache.axis2.description.TransportOutDescription; //导入方法依赖的package包/类
public EnginePausingTest(String arg0) {
    super(arg0);
    executedHandlers = new ArrayList();
    AxisConfiguration engineRegistry = new AxisConfiguration();
    configContext = new ConfigurationContext(engineRegistry);
    configContext.setServicePath(Constants.DEFAULT_SERVICES_PATH);
    configContext.setContextRoot("axis2");
    transportOut = new TransportOutDescription("null");
    transportOut.setSender(new CommonsHTTPTransportSender());
    transportIn = new TransportInDescription("null");

}
 
开发者ID:wso2,项目名称:wso2-axis2,代码行数:13,代码来源:EnginePausingTest.java

示例8: setSender

import org.apache.axis2.description.TransportOutDescription; //导入方法依赖的package包/类
private static void setSender(TransportOutDescription transportOutDescription)
{
	if (transportOutDescription!=null)
	{
		transportOutDescription.setSender(new MockTransportSender());
	}
}
 
开发者ID:lukas-krecan,项目名称:smock,代码行数:8,代码来源:SmockClient.java

示例9: createTransportOutDescription

import org.apache.axis2.description.TransportOutDescription; //导入方法依赖的package包/类
public TransportOutDescription createTransportOutDescription() throws Exception {
    TransportOutDescription trpOutDesc = new TransportOutDescription(name);
    trpOutDesc.setSender(senderClass.newInstance());
    return trpOutDesc;
}
 
开发者ID:wso2,项目名称:wso2-axis2-transports,代码行数:6,代码来源:SimpleTransportDescriptionFactory.java

示例10: setUp

import org.apache.axis2.description.TransportOutDescription; //导入方法依赖的package包/类
protected void setUp() throws Exception {

        AxisConfiguration engineRegistry = new AxisConfiguration();
        configContext = new ConfigurationContext(engineRegistry);

        TransportOutDescription transport = new TransportOutDescription("null");
        transport.setSender(new CommonsHTTPTransportSender());

        TransportInDescription transportIn = new TransportInDescription("null");
        AxisOperation axisOp = new InOutAxisOperation(operationName);

        AxisService service = new AxisService(serviceName.getLocalPart());
        axisOp.setMessageReceiver(new MessageReceiver() {
            public void receive(MessageContext messageCtx) throws AxisFault {
                // TODO Auto-generated method stub

            }
        });
        engineRegistry.addService(service);
        service.addOperation(axisOp);

        mc = configContext.createMessageContext();
        mc.setTransportIn(transportIn);
        mc.setTransportOut(transport);

        ServiceGroupContext sgc = configContext.createServiceGroupContext(
                service.getAxisServiceGroup());
        ServiceContext sc = sgc.getServiceContext(service);

        OperationContext opContext = sc.createOperationContext(axisOp);

        mc.setOperationContext(opContext);
        mc.setTransportOut(transport);
        mc.setProperty(MessageContext.TRANSPORT_OUT, System.out);
        mc.setServerSide(true);
        SOAPFactory omFac = OMAbstractFactory.getSOAP11Factory();
        mc.setEnvelope(omFac.getDefaultEnvelope());


        mc.setWSAAction(operationName.getLocalPart());
        mc.setSoapAction(operationName.getLocalPart());
        System.out.flush();
    }
 
开发者ID:wso2,项目名称:wso2-axis2,代码行数:44,代码来源:EngineWithoutPhaseResolvingTest.java


注:本文中的org.apache.axis2.description.TransportOutDescription.setSender方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。