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: /**
21: * <p>Representation of a security role reference for a web application, as
22: * represented in a <code><security-role-ref></code> element
23: * in the deployment descriptor.</p>
24: *
25: * @author Mark Thomas
26: * @version $Revision: 550263 $ $Date: 2007-06-24 19:28:45 +0200 (dim., 24 juin 2007) $
27: * @since Tomcat 5.5
28: */
29:
30: public class SecurityRoleRef {
31:
32: // ------------------------------------------------------------- Properties
33:
34: /**
35: * The (required) role name.
36: */
37: private String name = null;
38:
39: public String getName() {
40: return (this .name);
41: }
42:
43: public void setName(String name) {
44: this .name = name;
45: }
46:
47: /**
48: * The optional role link.
49: */
50: private String link = null;
51:
52: public String getLink() {
53: return (this .link);
54: }
55:
56: public void setLink(String link) {
57: this .link = link;
58: }
59:
60: // --------------------------------------------------------- Public Methods
61:
62: /**
63: * Return a String representation of this object.
64: */
65: public String toString() {
66:
67: StringBuffer sb = new StringBuffer("SecurityRoleRef[");
68: sb.append("name=");
69: sb.append(name);
70: if (link != null) {
71: sb.append(", link=");
72: sb.append(link);
73: }
74: sb.append("]");
75: return (sb.toString());
76:
77: }
78:
79: }
|