Save This Page
Home » openejb-3.1.2-src » org.apache » openejb » jee » jba » [javadoc | source]
    1   /**
    2    * Licensed to the Apache Software Foundation (ASF) under one or more
    3    * contributor license agreements.  See the NOTICE file distributed with
    4    * this work for additional information regarding copyright ownership.
    5    * The ASF licenses this file to You under the Apache License, Version 2.0
    6    * (the "License"); you may not use this file except in compliance with
    7    * the License.  You may obtain a copy of the License at
    8    *
    9    *     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    */
   17   
   18   package org.apache.openejb.jee.jba;
   19   
   20   import java.util.ArrayList;
   21   import java.util.List;
   22   import javax.xml.bind.annotation.XmlAccessType;
   23   import javax.xml.bind.annotation.XmlAccessorType;
   24   import javax.xml.bind.annotation.XmlElement;
   25   import javax.xml.bind.annotation.XmlRootElement;
   26   import javax.xml.bind.annotation.XmlType;
   27   
   28   
   29   /**
   30    * 
   31    */
   32   @XmlAccessorType(XmlAccessType.FIELD)
   33   @XmlType(name = "", propOrder = {
   34       "roleName",
   35       "principalName"
   36   })
   37   @XmlRootElement(name = "security-role")
   38   public class SecurityRole {
   39   
   40       @XmlElement(name = "role-name", required = true)
   41       protected String roleName;
   42       @XmlElement(name = "principal-name", required = true)
   43       protected List<PrincipalName> principalName;
   44   
   45       /**
   46        * Gets the value of the roleName property.
   47        * 
   48        * @return
   49        *     possible object is
   50        *     {@link String }
   51        *     
   52        */
   53       public String getRoleName() {
   54           return roleName;
   55       }
   56   
   57       /**
   58        * Sets the value of the roleName property.
   59        * 
   60        * @param value
   61        *     allowed object is
   62        *     {@link String }
   63        *     
   64        */
   65       public void setRoleName(String value) {
   66           this.roleName = value;
   67       }
   68   
   69       /**
   70        * Gets the value of the principalName property.
   71        * 
   72        * <p>
   73        * This accessor method returns a reference to the live list,
   74        * not a snapshot. Therefore any modification you make to the
   75        * returned list will be present inside the JAXB object.
   76        * This is why there is not a <CODE>set</CODE> method for the principalName property.
   77        * 
   78        * <p>
   79        * For example, to add a new item, do as follows:
   80        * <pre>
   81        *    getPrincipalName().add(newItem);
   82        * </pre>
   83        * 
   84        * 
   85        * <p>
   86        * Objects of the following type(s) are allowed in the list
   87        * {@link PrincipalName }
   88        * 
   89        * 
   90        */
   91       public List<PrincipalName> getPrincipalName() {
   92           if (principalName == null) {
   93               principalName = new ArrayList<PrincipalName>();
   94           }
   95           return this.principalName;
   96       }
   97   
   98   }

Save This Page
Home » openejb-3.1.2-src » org.apache » openejb » jee » jba » [javadoc | source]