KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > sape > carbon > services > security > management > LazyLoadGroup


1 /*
2  * The contents of this file are subject to the Sapient Public License
3  * Version 1.0 (the "License"); you may not use this file except in compliance
4  * with the License. You may obtain a copy of the License at
5  * http://carbon.sf.net/License.html.
6  *
7  * Software distributed under the License is distributed on an "AS IS" basis,
8  * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for
9  * the specific language governing rights and limitations under the License.
10  *
11  * The Original Code is The Carbon Component Framework.
12  *
13  * The Initial Developer of the Original Code is Sapient Corporation
14  *
15  * Copyright (C) 2003 Sapient Corporation. All Rights Reserved.
16  */

17
18 package org.sape.carbon.services.security.management;
19
20 import java.security.acl.Group JavaDoc;
21 import java.util.Set JavaDoc;
22
23 /**
24  * Class for lazy loading of a group object.
25  *
26  * @author $Author: dvoet $ $Date: 2003/05/05 21:21:35 $
27  * @version $Revision: 1.4 $
28  *
29  * @since carbon 1.2
30  */

31 public interface LazyLoadGroup extends Group JavaDoc {
32     /**
33      * Sets the members object.
34      *
35      * <p>
36      * This allows for two-phase loaded where the object is created and
37      * then the members object is set after creation. This is not a
38      * generic setter method. After the members have been set once
39      * (either during construction or through this method), calling this
40      * method will throw an error.
41      * </p>
42      *
43      * <p>
44      * This method can be tested through calls to <code>isLoaded()</code>.
45      * If <code>isLoaded()</code> returns false, this method can be
46      * safely called.
47      * </p>
48      *
49      * @param members a set of members for this group object.
50      *
51      * @throws IllegalStateException indicates this method was called
52      * after the members have been loaded.
53      */

54     void setMembers(Set JavaDoc members);
55
56     /**
57      * Returns if this object is fully loaded.
58      *
59      * <p>
60      * It is possible to construct this object without passing in a set of
61      * members and then set the members once later. This is meant to
62      * allow for the case where the member list contains a cycle, and
63      * therefore it is impossible to load all child members before
64      * creating this one.
65      * </p>
66      *
67      * @return if this object is fully loaded
68      */

69     boolean isLoaded();
70 }
71
Popular Tags