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.wls;
017:
018: import java.util.ArrayList;
019: import java.util.List;
020: import javax.xml.bind.JAXBElement;
021: import javax.xml.bind.annotation.XmlAccessType;
022: import javax.xml.bind.annotation.XmlAccessorType;
023: import javax.xml.bind.annotation.XmlAttribute;
024: import javax.xml.bind.annotation.XmlElement;
025: import javax.xml.bind.annotation.XmlElementRef;
026: import javax.xml.bind.annotation.XmlID;
027: import javax.xml.bind.annotation.XmlType;
028: import javax.xml.bind.annotation.adapters.CollapsedStringAdapter;
029: import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter;
030:
031: /**
032: * <p>Java class for security-role-assignment complex type.
033: *
034: * <p>The following schema fragment specifies the expected content contained within this class.
035: *
036: * <pre>
037: * <complexType name="security-role-assignment">
038: * <complexContent>
039: * <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
040: * <sequence>
041: * <element name="role-name" type="{http://www.w3.org/2001/XMLSchema}string"/>
042: * <choice>
043: * <element name="principal-name" type="{http://www.w3.org/2001/XMLSchema}NMTOKEN" maxOccurs="unbounded"/>
044: * <element name="externally-defined" type="{http://www.bea.com/ns/weblogic/90}empty"/>
045: * </choice>
046: * </sequence>
047: * <attribute name="id" type="{http://www.w3.org/2001/XMLSchema}ID" />
048: * </restriction>
049: * </complexContent>
050: * </complexType>
051: * </pre>
052: *
053: *
054: */
055: @XmlAccessorType(XmlAccessType.FIELD)
056: @XmlType(name="security-role-assignment",propOrder={"roleName","principalName","externallyDefined"})
057: public class SecurityRoleAssignment {
058:
059: @XmlElement(name="role-name",required=true)
060: protected String roleName;
061: @XmlElementRef(name="principal-name",namespace="http://www.bea.com/ns/weblogic/90",type=JAXBElement.class)
062: protected List<JAXBElement<String>> principalName;
063: @XmlElement(name="externally-defined")
064: protected Empty externallyDefined;
065: @XmlAttribute
066: @XmlJavaTypeAdapter(CollapsedStringAdapter.class)
067: @XmlID
068: protected String id;
069:
070: /**
071: * Gets the value of the roleName property.
072: *
073: * @return
074: * possible object is
075: * {@link String }
076: *
077: */
078: public String getRoleName() {
079: return roleName;
080: }
081:
082: /**
083: * Sets the value of the roleName property.
084: *
085: * @param value
086: * allowed object is
087: * {@link String }
088: *
089: */
090: public void setRoleName(String value) {
091: this .roleName = value;
092: }
093:
094: /**
095: * Gets the value of the principalName property.
096: *
097: * <p>
098: * This accessor method returns a reference to the live list,
099: * not a snapshot. Therefore any modification you make to the
100: * returned list will be present inside the JAXB object.
101: * This is why there is not a <CODE>set</CODE> method for the principalName property.
102: *
103: * <p>
104: * For example, to add a new item, do as follows:
105: * <pre>
106: * getPrincipalName().add(newItem);
107: * </pre>
108: *
109: *
110: * <p>
111: * Objects of the following type(s) are allowed in the list
112: * {@link JAXBElement }{@code <}{@link String }{@code >}
113: *
114: *
115: */
116: public List<JAXBElement<String>> getPrincipalName() {
117: if (principalName == null) {
118: principalName = new ArrayList<JAXBElement<String>>();
119: }
120: return this .principalName;
121: }
122:
123: /**
124: * Gets the value of the externallyDefined property.
125: *
126: * @return
127: * possible object is
128: * {@link Empty }
129: *
130: */
131: public Empty getExternallyDefined() {
132: return externallyDefined;
133: }
134:
135: /**
136: * Sets the value of the externallyDefined property.
137: *
138: * @param value
139: * allowed object is
140: * {@link Empty }
141: *
142: */
143: public void setExternallyDefined(Empty value) {
144: this .externallyDefined = value;
145: }
146:
147: /**
148: * Gets the value of the id property.
149: *
150: * @return
151: * possible object is
152: * {@link String }
153: *
154: */
155: public String getId() {
156: return id;
157: }
158:
159: /**
160: * Sets the value of the id property.
161: *
162: * @param value
163: * allowed object is
164: * {@link String }
165: *
166: */
167: public void setId(String value) {
168: this.id = value;
169: }
170:
171: }
|