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.oejb2;
017:
018: import java.util.ArrayList;
019: import java.util.List;
020: import javax.xml.bind.annotation.XmlAccessType;
021: import javax.xml.bind.annotation.XmlAccessorType;
022: import javax.xml.bind.annotation.XmlElement;
023: import javax.xml.bind.annotation.XmlType;
024:
025: /**
026: * <p>Java class for persistence-context-refType complex type.
027: *
028: * <p>The following schema fragment specifies the expected content contained within this class.
029: *
030: * <pre>
031: * <complexType name="persistence-context-refType">
032: * <complexContent>
033: * <extension base="{http://geronimo.apache.org/xml/ns/naming-1.2}abstract-naming-entryType">
034: * <sequence>
035: * <element name="persistence-context-ref-name" type="{http://www.w3.org/2001/XMLSchema}string"/>
036: * <choice>
037: * <element name="persistence-unit-name" type="{http://www.w3.org/2001/XMLSchema}string"/>
038: * <element name="pattern" type="{http://geronimo.apache.org/xml/ns/naming-1.2}patternType"/>
039: * </choice>
040: * <element name="persistence-context-type" type="{http://geronimo.apache.org/xml/ns/naming-1.2}persistence-context-typeType" minOccurs="0"/>
041: * <element name="property" type="{http://geronimo.apache.org/xml/ns/naming-1.2}propertyType" maxOccurs="unbounded" minOccurs="0"/>
042: * </sequence>
043: * </extension>
044: * </complexContent>
045: * </complexType>
046: * </pre>
047: *
048: *
049: */
050: @XmlAccessorType(XmlAccessType.FIELD)
051: @XmlType(name="persistence-context-refType",namespace="http://geronimo.apache.org/xml/ns/naming-1.2",propOrder={"persistenceContextRefName","persistenceUnitName","pattern","persistenceContextType","property"})
052: public class PersistenceContextRefType extends AbstractNamingEntryType {
053:
054: @XmlElement(name="persistence-context-ref-name",required=true)
055: protected String persistenceContextRefName;
056: @XmlElement(name="persistence-unit-name")
057: protected String persistenceUnitName;
058: protected PatternType pattern;
059: @XmlElement(name="persistence-context-type")
060: protected PersistenceContextTypeType persistenceContextType;
061: protected List<PropertyType> property;
062:
063: /**
064: * Gets the value of the persistenceContextRefName property.
065: *
066: * @return
067: * possible object is
068: * {@link String }
069: *
070: */
071: public String getPersistenceContextRefName() {
072: return persistenceContextRefName;
073: }
074:
075: /**
076: * Sets the value of the persistenceContextRefName property.
077: *
078: * @param value
079: * allowed object is
080: * {@link String }
081: *
082: */
083: public void setPersistenceContextRefName(String value) {
084: this .persistenceContextRefName = value;
085: }
086:
087: /**
088: * Gets the value of the persistenceUnitName property.
089: *
090: * @return
091: * possible object is
092: * {@link String }
093: *
094: */
095: public String getPersistenceUnitName() {
096: return persistenceUnitName;
097: }
098:
099: /**
100: * Sets the value of the persistenceUnitName property.
101: *
102: * @param value
103: * allowed object is
104: * {@link String }
105: *
106: */
107: public void setPersistenceUnitName(String value) {
108: this .persistenceUnitName = value;
109: }
110:
111: /**
112: * Gets the value of the pattern property.
113: *
114: * @return
115: * possible object is
116: * {@link PatternType }
117: *
118: */
119: public PatternType getPattern() {
120: return pattern;
121: }
122:
123: /**
124: * Sets the value of the pattern property.
125: *
126: * @param value
127: * allowed object is
128: * {@link PatternType }
129: *
130: */
131: public void setPattern(PatternType value) {
132: this .pattern = value;
133: }
134:
135: /**
136: * Gets the value of the persistenceContextType property.
137: *
138: * @return
139: * possible object is
140: * {@link PersistenceContextTypeType }
141: *
142: */
143: public PersistenceContextTypeType getPersistenceContextType() {
144: return persistenceContextType;
145: }
146:
147: /**
148: * Sets the value of the persistenceContextType property.
149: *
150: * @param value
151: * allowed object is
152: * {@link PersistenceContextTypeType }
153: *
154: */
155: public void setPersistenceContextType(
156: PersistenceContextTypeType value) {
157: this .persistenceContextType = value;
158: }
159:
160: /**
161: * Gets the value of the property property.
162: *
163: * <p>
164: * This accessor method returns a reference to the live list,
165: * not a snapshot. Therefore any modification you make to the
166: * returned list will be present inside the JAXB object.
167: * This is why there is not a <CODE>set</CODE> method for the property property.
168: *
169: * <p>
170: * For example, to add a new item, do as follows:
171: * <pre>
172: * getProperty().add(newItem);
173: * </pre>
174: *
175: *
176: * <p>
177: * Objects of the following type(s) are allowed in the list
178: * {@link PropertyType }
179: *
180: *
181: */
182: public List<PropertyType> getProperty() {
183: if (property == null) {
184: property = new ArrayList<PropertyType>();
185: }
186: return this.property;
187: }
188:
189: }
|