本文整理汇总了Java中org.springframework.ws.client.core.WebServiceOperations类的典型用法代码示例。如果您正苦于以下问题:Java WebServiceOperations类的具体用法?Java WebServiceOperations怎么用?Java WebServiceOperations使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
WebServiceOperations类属于org.springframework.ws.client.core包,在下文中一共展示了WebServiceOperations类的8个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: example
import org.springframework.ws.client.core.WebServiceOperations; //导入依赖的package包/类
@Test
public void example()
{
Calc calc = new Calc();
WebServiceOperations wsTemplate = createMock(WebServiceOperations.class);
calc.setWsTemplate(wsTemplate);
expect(wsTemplate.marshalSendAndReceive(is(message("xml/request2.xml")))).andReturn(response("xml/response1.xml", PlusResponse.class));
replay(wsTemplate);
assertEquals(3, calc.plus(1, 2));
verify(wsTemplate);
}
示例2: exampleInvalid
import org.springframework.ws.client.core.WebServiceOperations; //导入依赖的package包/类
@Test(expected=AssertionError.class)
public void exampleInvalid()
{
Calc calc = new Calc();
WebServiceOperations wsTemplate = createMock(WebServiceOperations.class);
calc.setWsTemplate(wsTemplate);
expect(wsTemplate.marshalSendAndReceive(is(message("xml/valid-message.xml")))).andReturn(response("xml/response1.xml", PlusResponse.class));
replay(wsTemplate);
calc.plus(1, 2);
}
示例3: getWebServiceOperations
import org.springframework.ws.client.core.WebServiceOperations; //导入依赖的package包/类
public WebServiceOperations getWebServiceOperations() {
return webServiceOperations;
}
示例4: setWebServiceOperations
import org.springframework.ws.client.core.WebServiceOperations; //导入依赖的package包/类
public void setWebServiceOperations(WebServiceOperations webServiceOperations) {
this.webServiceOperations = webServiceOperations;
}
示例5: getWsTemplate
import org.springframework.ws.client.core.WebServiceOperations; //导入依赖的package包/类
public WebServiceOperations getWsTemplate() {
return wsTemplate;
}
示例6: setWsTemplate
import org.springframework.ws.client.core.WebServiceOperations; //导入依赖的package包/类
public void setWsTemplate(WebServiceOperations wsTemplate) {
this.wsTemplate = wsTemplate;
}
示例7: setUpMocks
import org.springframework.ws.client.core.WebServiceOperations; //导入依赖的package包/类
@Before
public void setUpMocks() throws Exception {
airlineClient = new AirlineClient();
webServiceTemplate = mock(WebServiceOperations.class);
airlineClient.setWsTemplate(webServiceTemplate);
}
示例8: setUpMocks
import org.springframework.ws.client.core.WebServiceOperations; //导入依赖的package包/类
@Before
public void setUpMocks() throws Exception {
airlineClient = new AirlineClient();
webServiceTemplate = createMock(WebServiceOperations.class);
airlineClient.setWsTemplate(webServiceTemplate);
}