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: package org.apache.cocoon.components.source.helpers;
18:
19: /**
20: * This class represents a source permission for groups
21: *
22: * @author <a href="mailto:stephan@apache.org">Stephan Michels</a>
23: * @version CVS $Id: GroupSourcePermission.java 433543 2006-08-22 06:22:54Z crossley $
24: */
25: public class GroupSourcePermission extends AbstractSourcePermission {
26:
27: private String group;
28:
29: /**
30: * Creates a new permission
31: *
32: * @param group Group of the permission
33: * @param privilege Privilege of the permission
34: * @param inheritable If the permission is inheritable
35: * @param negative If the permission is negative
36: */
37: public GroupSourcePermission(String group, String privilege,
38: boolean inheritable, boolean negative) {
39:
40: this .group = group;
41: setPrivilege(privilege);
42: setInheritable(inheritable);
43: setNegative(negative);
44: }
45:
46: /**
47: * Sets the group of users for the permission
48: *
49: * @param group Group of users
50: */
51: public void setGroup(String group) {
52: this .group = group;
53: }
54:
55: /**
56: * Returns the group of users for the permission
57: *
58: * @return Group of users
59: */
60: public String getGroup() {
61: return this.group;
62: }
63: }
|