01: /**
02: * Licensed to the Apache Software Foundation (ASF) under one or more
03: * contributor license agreements. See the NOTICE file distributed with
04: * this work for additional information regarding copyright ownership.
05: * The ASF licenses this file to You under the Apache License, Version 2.0
06: * (the "License"); you may not use this file except in compliance with
07: * the License. You may obtain a copy of the License at
08: *
09: * http://www.apache.org/licenses/LICENSE-2.0
10: *
11: * Unless required by applicable law or agreed to in writing, software
12: * distributed under the License is distributed on an "AS IS" BASIS,
13: * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14: * See the License for the specific language governing permissions and
15: * limitations under the License.
16: */package org.apache.openejb.jee;
17:
18: import javax.xml.bind.annotation.XmlAccessType;
19: import javax.xml.bind.annotation.XmlAccessorType;
20: import javax.xml.bind.annotation.XmlAttribute;
21: import javax.xml.bind.annotation.XmlElement;
22: import javax.xml.bind.annotation.XmlID;
23: import javax.xml.bind.annotation.XmlType;
24: import javax.xml.bind.annotation.adapters.CollapsedStringAdapter;
25: import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter;
26: import java.util.ArrayList;
27: import java.util.List;
28:
29: /**
30: * The licenseType specifies licensing requirements for the
31: * resource adapter module. This type specifies whether a
32: * license is required to deploy and use this resource adapter,
33: * and an optional description of the licensing terms
34: * (examples: duration of license, number of connection
35: * restrictions). It is used by the license element.
36: */
37: @XmlAccessorType(XmlAccessType.FIELD)
38: @XmlType(name="licenseType",propOrder={"description","licenseRequired"})
39: public class License {
40:
41: protected List<Text> description;
42: @XmlElement(name="license-required")
43: protected boolean licenseRequired;
44: @XmlAttribute
45: @XmlJavaTypeAdapter(CollapsedStringAdapter.class)
46: @XmlID
47: protected String id;
48:
49: public List<Text> getDescription() {
50: if (description == null) {
51: description = new ArrayList<Text>();
52: }
53: return this .description;
54: }
55:
56: /**
57: * Gets the value of the licenseRequired property.
58: */
59: public boolean isLicenseRequired() {
60: return licenseRequired;
61: }
62:
63: /**
64: * Sets the value of the licenseRequired property.
65: */
66: public void setLicenseRequired(boolean value) {
67: this .licenseRequired = value;
68: }
69:
70: public String getId() {
71: return id;
72: }
73:
74: public void setId(String value) {
75: this.id = value;
76: }
77:
78: }
|