001: /**
002: * Licensed to the Apache Software Foundation (ASF) under one or more
003: * contributor license agreements. See the NOTICE file distributed with
004: * this work for additional information regarding copyright ownership.
005: * The ASF licenses this file to You under the Apache License, Version 2.0
006: * (the "License"); you may not use this file except in compliance with
007: * the License. You may obtain a copy of the License at
008: *
009: * http://www.apache.org/licenses/LICENSE-2.0
010: *
011: * Unless required by applicable law or agreed to in writing, software
012: * distributed under the License is distributed on an "AS IS" BASIS,
013: * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
014: * See the License for the specific language governing permissions and
015: * limitations under the License.
016: */package org.apache.openejb.jee;
017:
018: import javax.xml.bind.annotation.XmlAccessType;
019: import javax.xml.bind.annotation.XmlAccessorType;
020: import javax.xml.bind.annotation.XmlAttribute;
021: import javax.xml.bind.annotation.XmlElement;
022: import javax.xml.bind.annotation.XmlID;
023: import javax.xml.bind.annotation.XmlTransient;
024: import javax.xml.bind.annotation.XmlType;
025: import javax.xml.bind.annotation.adapters.CollapsedStringAdapter;
026: import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter;
027: import java.util.Collection;
028: import java.util.Map;
029:
030: /**
031: * The webservice-description element defines a WSDL document file
032: * and the set of Port components associated with the WSDL ports
033: * defined in the WSDL document. There may be multiple
034: * webservice-descriptions defined within a module.
035: * <p/>
036: * All WSDL file ports must have a corresponding port-component element
037: * defined.
038: * <p/>
039: * Used in: webservices
040: */
041: @XmlAccessorType(XmlAccessType.FIELD)
042: @XmlType(name="webservice-descriptionType",propOrder={"description","displayName","icon","webserviceDescriptionName","wsdlFile","jaxrpcMappingFile","portComponent"})
043: public class WebserviceDescription implements Keyable<String> {
044: protected String description;
045: @XmlElement(name="display-name")
046: protected String displayName;
047: protected Icon icon;
048: @XmlElement(name="webservice-description-name",required=true)
049: protected String webserviceDescriptionName;
050: @XmlElement(name="wsdl-file")
051: protected String wsdlFile;
052: @XmlElement(name="jaxrpc-mapping-file")
053: protected String jaxrpcMappingFile;
054: @XmlTransient
055: protected JavaWsdlMapping jaxrpcMapping;
056: @XmlElement(name="port-component",required=true)
057: protected KeyedCollection<String, PortComponent> portComponent;
058: @XmlAttribute
059: @XmlJavaTypeAdapter(CollapsedStringAdapter.class)
060: @XmlID
061: protected String id;
062:
063: public String getKey() {
064: return webserviceDescriptionName;
065: }
066:
067: public String getDescription() {
068: return description;
069: }
070:
071: public void setDescription(String value) {
072: this .description = value;
073: }
074:
075: public String getDisplayName() {
076: return displayName;
077: }
078:
079: public void setDisplayName(String value) {
080: this .displayName = value;
081: }
082:
083: public Icon getIcon() {
084: return icon;
085: }
086:
087: public void setIcon(Icon value) {
088: this .icon = value;
089: }
090:
091: public String getWebserviceDescriptionName() {
092: return webserviceDescriptionName;
093: }
094:
095: public void setWebserviceDescriptionName(String value) {
096: this .webserviceDescriptionName = value;
097: }
098:
099: public String getWsdlFile() {
100: return wsdlFile;
101: }
102:
103: public void setWsdlFile(String value) {
104: this .wsdlFile = value;
105: }
106:
107: public String getJaxrpcMappingFile() {
108: return jaxrpcMappingFile;
109: }
110:
111: public void setJaxrpcMappingFile(String value) {
112: this .jaxrpcMappingFile = value;
113: }
114:
115: public JavaWsdlMapping getJaxrpcMapping() {
116: return jaxrpcMapping;
117: }
118:
119: public void setJaxrpcMapping(JavaWsdlMapping jaxrpcMapping) {
120: this .jaxrpcMapping = jaxrpcMapping;
121: }
122:
123: public Collection<PortComponent> getPortComponent() {
124: if (portComponent == null) {
125: portComponent = new KeyedCollection<String, PortComponent>();
126: }
127: return this .portComponent;
128: }
129:
130: public Map<String, PortComponent> getPortComponentMap() {
131: if (portComponent == null) {
132: portComponent = new KeyedCollection<String, PortComponent>();
133: }
134: return this .portComponent.toMap();
135: }
136:
137: public String getId() {
138: return id;
139: }
140:
141: public void setId(String value) {
142: this.id = value;
143: }
144: }
|