01: /*
02: * BindingOperationImpl.java
03: *
04: * Created on September 24, 2006, 5:27 PM
05: *
06: * To change this template, choose Tools | Template Manager
07: * and open the template in the editor.
08: */
09:
10: package org.netbeans.modules.e2e.wsdl;
11:
12: import java.util.ArrayList;
13: import java.util.Collections;
14: import java.util.HashMap;
15: import java.util.List;
16: import java.util.Map;
17: import org.netbeans.modules.e2e.api.wsdl.BindingFault;
18: import org.netbeans.modules.e2e.api.wsdl.BindingInput;
19: import org.netbeans.modules.e2e.api.wsdl.BindingOperation;
20: import org.netbeans.modules.e2e.api.wsdl.BindingOutput;
21: import org.netbeans.modules.e2e.api.wsdl.extensions.ExtensibilityElement;
22:
23: /**
24: *
25: * @author Michal Skvor
26: */
27: public class BindingOperationImpl implements BindingOperation {
28:
29: private String name;
30: private BindingInput bindingInput;
31: private BindingOutput bindingOutput;
32: private Map<String, BindingFault> bindingFaults;
33:
34: private List<ExtensibilityElement> extensibilityElements;
35:
36: /** Creates a new instance of BindingOperationImpl */
37: public BindingOperationImpl(String name) {
38: this .name = name;
39: bindingFaults = new HashMap();
40: extensibilityElements = new ArrayList();
41: }
42:
43: public void setName(String name) {
44: this .name = name;
45: }
46:
47: public String getName() {
48: return name;
49: }
50:
51: public void setBindingInput(BindingInput bindingInput) {
52: this .bindingInput = bindingInput;
53: }
54:
55: public BindingInput getBindingInput() {
56: return bindingInput;
57: }
58:
59: public void setBindingOutput(BindingOutput bindingOutput) {
60: this .bindingOutput = bindingOutput;
61: }
62:
63: public BindingOutput getBindingOutput() {
64: return bindingOutput;
65: }
66:
67: public void addBindingFault(BindingFault bindingFault) {
68: bindingFaults.put(bindingFault.getName(), bindingFault);
69: }
70:
71: public BindingFault getBindingFault(String name) {
72: return bindingFaults.get(name);
73: }
74:
75: public List<BindingFault> getBindingFaults() {
76: return Collections.unmodifiableList(new ArrayList(bindingFaults
77: .values()));
78: }
79:
80: public void addExtensibilityElement(
81: ExtensibilityElement extensibilityElement) {
82: extensibilityElements.add(extensibilityElement);
83: }
84:
85: public List<ExtensibilityElement> getExtensibilityElements() {
86: return Collections.unmodifiableList(extensibilityElements);
87: }
88: }
|