Save This Page
Home » openejb-3.1.2-src » org.apache » openejb » jee » [javadoc | source]
    1   /**
    2    *
    3    * Licensed to the Apache Software Foundation (ASF) under one or more
    4    * contributor license agreements.  See the NOTICE file distributed with
    5    * this work for additional information regarding copyright ownership.
    6    * The ASF licenses this file to You under the Apache License, Version 2.0
    7    * (the "License"); you may not use this file except in compliance with
    8    * the License.  You may obtain a copy of the License at
    9    *
   10    *     http://www.apache.org/licenses/LICENSE-2.0
   11    *
   12    *  Unless required by applicable law or agreed to in writing, software
   13    *  distributed under the License is distributed on an "AS IS" BASIS,
   14    *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
   15    *  See the License for the specific language governing permissions and
   16    *  limitations under the License.
   17    */
   18   
   19   package org.apache.openejb.jee;
   20   
   21   import javax.xml.bind.annotation.XmlAccessType;
   22   import javax.xml.bind.annotation.XmlAccessorType;
   23   import javax.xml.bind.annotation.XmlAttribute;
   24   import javax.xml.bind.annotation.XmlElement;
   25   import javax.xml.bind.annotation.XmlID;
   26   import javax.xml.bind.annotation.XmlType;
   27   import javax.xml.bind.annotation.adapters.CollapsedStringAdapter;
   28   import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter;
   29   
   30   
   31   /**
   32    * The icon type contains small-icon and large-icon elements
   33    * that specify the file names for small and large GIF, JPEG,
   34    * or PNG icon images used to represent the parent element in a
   35    * GUI tool.
   36    * <p/>
   37    * The xml:lang attribute defines the language that the
   38    * icon file names are provided in. Its value is "en" (English)
   39    * by default.
   40    */
   41   @XmlAccessorType(XmlAccessType.FIELD)
   42   @XmlType(name = "iconType", propOrder = {
   43           "smallIcon",
   44           "largeIcon"
   45           })
   46   public class Icon implements Keyable<String> {
   47   
   48       @XmlElement(name = "small-icon")
   49       protected String smallIcon;
   50       @XmlElement(name = "large-icon")
   51       protected String largeIcon;
   52       @XmlAttribute
   53       @XmlJavaTypeAdapter(CollapsedStringAdapter.class)
   54       @XmlID
   55       protected String id;
   56       @XmlAttribute(namespace = "http://www.w3.org/XML/1998/namespace")
   57       protected String lang = "en";
   58   
   59       public String getSmallIcon() {
   60           return smallIcon;
   61       }
   62   
   63       public void setSmallIcon(String value) {
   64           this.smallIcon = value;
   65       }
   66   
   67       public String getLargeIcon() {
   68           return largeIcon;
   69       }
   70   
   71       public void setLargeIcon(String value) {
   72           this.largeIcon = value;
   73       }
   74   
   75       public String getId() {
   76           return id;
   77       }
   78   
   79       public void setId(String value) {
   80           this.id = value;
   81       }
   82   
   83       public String getLang() {
   84           return lang;
   85       }
   86   
   87       public void setLang(String value) {
   88           this.lang = value;
   89       }
   90   
   91       public String getKey() {
   92           return getLang();
   93       }
   94   }

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