e.g. Calendar Search Help
You must enter a value before pressing Search
tomcat

Class: org.apache.catalina.deploy.ContextEjb   ©

 OK to copy?
001 /*
002  * Copyright 1999,2004 The Apache Software Foundation.
003  * 
004  * Licensed under the Apache License, Version 2.0 (the "License");
005  * you may not use this file except in compliance with the License.
006  * You may obtain a copy of the License at
007  * 
008  *      http://www.apache.org/licenses/LICENSE-2.0
009  * 
010  * Unless required by applicable law or agreed to in writing, software
011  * distributed under the License is distributed on an "AS IS" BASIS,
012  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
013  * See the License for the specific language governing permissions and
014  * limitations under the License.
015  */
016 
017 
018 package org.apache.catalina.deploy;
019 
020 import java.io.Serializable;
021 import java.util.Iterator;
022 import java.util.HashMap;
023 
024 
025 /**
026  * Representation of an EJB resource reference for a web application, as
027  * represented in a <code>&lt;ejb-ref&gt;</code> element in the
028  * deployment descriptor.
029  *
030  * @author Craig R. McClanahan
031  * @version $Revision: 1.5 $ $Date: 2004/07/26 16:04:02 $
032  */
033 
034 public class ContextEjb implements Serializable {
035 
036 
037     // ------------------------------------------------------------- Properties
038 
039 
040     /**
041      * The description of this EJB.
042      */
043     private String description = null;
044 
045     public String getDescription() {
046         return (this.description);
047     }
048 
049     public void setDescription(String description) {
050         this.description = description;
051     }
052 
053 
054     /**
055      * The name of the EJB home implementation class.
056      */
057     private String home = null;
058 
059     public String getHome() {
060         return (this.home);
061     }
062 
063     public void setHome(String home) {
064         this.home = home;
065     }
066 
067 
068     /**
069      * The link to a J2EE EJB definition.
070      */
071     private String link = null;
072 
073     public String getLink() {
074         return (this.link);
075     }
076 
077     public void setLink(String link) {
078         this.link = link;
079     }
080 
081 
082     /**
083      * The name of this EJB.
084      */
085     private String name = null;
086 
087     public String getName() {
088         return (this.name);
089     }
090 
091     public void setName(String name) {
092         this.name = name;
093     }
094 
095 
096     /**
097      * The name of the EJB remote implementation class.
098      */
099     private String remote = null;
100 
101     public String getRemote() {
102         return (this.remote);
103     }
104 
105     public void setRemote(String remote) {
106         this.remote = remote;
107     }
108 
109 
110     /**
111      * The name of the EJB bean implementation class.
112      */
113     private String type = null;
114 
115     public String getType() {
116         return (this.type);
117     }
118 
119     public void setType(String type) {
120         this.type = type;
121     }
122 
123 
124     /**
125      * Holder for our configured properties.
126      */
127     private HashMap properties = new HashMap();
128 
129     /**
130      * Return a configured property.
131      */
132     public Object getProperty(String name) {
133         return properties.get(name);
134     }
135 
136     /**
137      * Set a configured property.
138      */
139     public void setProperty(String name, Object value) {
140         properties.put(name, value);
141     }
142 
143     /** 
144      * remove a configured property.
145      */
146     public void removeProperty(String name) {
147         properties.remove(name);
148     }
149 
150     /**
151      * List properties.
152      */
153     public Iterator listProperties() {
Rate154         return properties.keySet().iterator();
155     }
156     
157     
158     // --------------------------------------------------------- Public Methods
159 
160 
161     /**
162      * Return a String representation of this object.
163      */
164     public String toString() {
165 
166         StringBuffer sb = new StringBuffer("ContextEjb[");
167         sb.append("name=");
168         sb.append(name);
169         if (description != null) {
170             sb.append(", description=");
171             sb.append(description);
172         }
173         if (type != null) {
174             sb.append(", type=");
175             sb.append(type);
176         }
177         if (home != null) {
178             sb.append(", home=");
179             sb.append(home);
180         }
181         if (remote != null) {
182             sb.append(", remote=");
183             sb.append(remote);
184         }
185         if (link != null) {
186             sb.append(", link=");
187             sb.append(link);
188         }
189         sb.append("]");
190         return (sb.toString());
191 
192     }
193 
194 
195     // -------------------------------------------------------- Package Methods
196 
197 
198     /**
199      * The NamingResources with which we are associated (if any).
200      */
201     protected NamingResources resources = null;
202 
203     public NamingResources getNamingResources() {
204         return (this.resources);
205     }
206 
207     void setNamingResources(NamingResources resources) {
208         this.resources = resources;
209     }
210 
211 
212 }

            
All Examples in File:
Example
Line
Rating (found
useful by...)
154 0% of 0