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: */
017:
018: package org.apache.catalina.deploy;
019:
020: import java.io.Serializable;
021:
022: /**
023: * Representation of a local EJB resource reference for a web application, as
024: * represented in a <code><ejb-local-ref></code> element in the
025: * deployment descriptor.
026: *
027: * @author Craig R. McClanahan
028: * @author Peter Rossbach (pero@apache.org)
029: * @version $Revision: 467222 $ $Date: 2006-10-24 05:17:11 +0200 (mar., 24 oct. 2006) $
030: */
031:
032: public class ContextLocalEjb extends ResourceBase implements
033: Serializable {
034:
035: // ------------------------------------------------------------- Properties
036:
037: /**
038: * The name of the EJB home implementation class.
039: */
040: private String home = null;
041:
042: public String getHome() {
043: return (this .home);
044: }
045:
046: public void setHome(String home) {
047: this .home = home;
048: }
049:
050: /**
051: * The link to a J2EE EJB definition.
052: */
053: private String link = null;
054:
055: public String getLink() {
056: return (this .link);
057: }
058:
059: public void setLink(String link) {
060: this .link = link;
061: }
062:
063: /**
064: * The name of the EJB local implementation class.
065: */
066: private String local = null;
067:
068: public String getLocal() {
069: return (this .local);
070: }
071:
072: public void setLocal(String local) {
073: this .local = local;
074: }
075:
076: // --------------------------------------------------------- Public Methods
077:
078: /**
079: * Return a String representation of this object.
080: */
081: public String toString() {
082:
083: StringBuffer sb = new StringBuffer("ContextLocalEjb[");
084: sb.append("name=");
085: sb.append(getName());
086: if (getDescription() != null) {
087: sb.append(", description=");
088: sb.append(getDescription());
089: }
090: if (getType() != null) {
091: sb.append(", type=");
092: sb.append(getType());
093: }
094: if (home != null) {
095: sb.append(", home=");
096: sb.append(home);
097: }
098: if (link != null) {
099: sb.append(", link=");
100: sb.append(link);
101: }
102: if (local != null) {
103: sb.append(", local=");
104: sb.append(local);
105: }
106: sb.append("]");
107: return (sb.toString());
108:
109: }
110: }
|