01: /*
02: * Licensed to the Apache Software Foundation (ASF) under one or more
03: * contributor license agreements. See the NOTICE file distributed with
04: * this work for additional information regarding copyright ownership.
05: * The ASF licenses this file to You under the Apache License, Version 2.0
06: * (the "License"); you may not use this file except in compliance with
07: * the License. You may obtain a copy of the License at
08: *
09: * 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.catalina.deploy;
19:
20: import java.io.Serializable;
21:
22: /**
23: * Representation of an application resource reference, as represented in
24: * an <code><res-env-refy></code> element in the deployment descriptor.
25: *
26: * @author Craig R. McClanahan
27: * @author Peter Rossbach (pero@apache.org)
28: * @version $Revision: 467222 $ $Date: 2006-10-24 05:17:11 +0200 (mar., 24 oct. 2006) $
29: */
30:
31: public class ContextResourceEnvRef extends ResourceBase implements
32: Serializable {
33:
34: // ------------------------------------------------------------- Properties
35:
36: /**
37: * Does this environment entry allow overrides by the application
38: * deployment descriptor?
39: */
40: private boolean override = true;
41:
42: public boolean getOverride() {
43: return (this .override);
44: }
45:
46: public void setOverride(boolean override) {
47: this .override = override;
48: }
49:
50: // --------------------------------------------------------- Public Methods
51:
52: /**
53: * Return a String representation of this object.
54: */
55: public String toString() {
56:
57: StringBuffer sb = new StringBuffer("ContextResourceEnvRef[");
58: sb.append("name=");
59: sb.append(getName());
60: if (getType() != null) {
61: sb.append(", type=");
62: sb.append(getType());
63: }
64: sb.append(", override=");
65: sb.append(override);
66: sb.append("]");
67: return (sb.toString());
68:
69: }
70:
71: }
|