01: /*
02: * soapUI, copyright (C) 2004-2007 eviware.com
03: *
04: * soapUI is free software; you can redistribute it and/or modify it under the
05: * terms of version 2.1 of the GNU Lesser General Public License as published by
06: * the Free Software Foundation.
07: *
08: * soapUI is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without
09: * even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
10: * See the GNU Lesser General Public License for more details at gnu.org.
11: */
12:
13: package com.eviware.soapui.impl.wsdl.panels.mockoperation;
14:
15: import com.eviware.soapui.impl.wsdl.WsdlOperation;
16: import com.eviware.soapui.impl.wsdl.mock.WsdlMockResponse;
17: import com.eviware.soapui.impl.wsdl.submit.WsdlMessageExchange;
18: import com.eviware.soapui.model.iface.Attachment;
19: import com.eviware.soapui.support.types.StringToStringMap;
20:
21: /**
22: * WsdlMessageExchange for a WsdlMockResponse, required for validations
23: *
24: * @author ole.matzura
25: */
26:
27: public class WsdlMockResponseMessageExchange extends
28: WsdlMessageExchange {
29: private final WsdlMockResponse mockResponse;
30:
31: public WsdlMockResponseMessageExchange(WsdlMockResponse mockResponse) {
32: this .mockResponse = mockResponse;
33: }
34:
35: public Attachment[] getRequestAttachments() {
36: return null;
37: }
38:
39: public String getRequestContent() {
40: return null;
41: }
42:
43: public StringToStringMap getRequestHeaders() {
44: return null;
45: }
46:
47: public Attachment[] getResponseAttachments() {
48: return mockResponse.getAttachments();
49: }
50:
51: public String getResponseContent() {
52: return mockResponse.getResponseContent();
53: }
54:
55: public StringToStringMap getResponseHeaders() {
56: return mockResponse.getResponseHeaders();
57: }
58:
59: public WsdlOperation getOperation() {
60: return mockResponse.getMockOperation().getOperation();
61: }
62:
63: public long getTimeTaken() {
64: return 0;
65: }
66:
67: public long getTimestamp() {
68: return 0;
69: }
70: }
|