1 package de.webman.sync; 2 3 import java.util.List; 4 5 6 /** 7 * Classes implementing this type can be used as an adaptor to (external) 8 * access control systems (like ldap, etc.) 9 * 10 * @author <a HREF="mailto:gregor@webman.de">Gregor Klinke</a> 11 * @version $Revision: 1.2 $ 12 **/ 13 public interface ACLAdaptor 14 { 15 /* $Id: ACLAdaptor.java,v 1.2 2002/04/12 14:56:01 gregor Exp $ */ 16 17 /** 18 * returns a list of all users known to the adaptor, which are in a 19 * scope interesting to webman. 20 * @return a list of all users, never <code>null</code>, but probably 21 * empty. The elements are of type {@link de.webman.sync.User} 22 * @throws SyncException bread and cheese 23 **/ 24 List getAllUsers() throws SyncException; 25 26 /** 27 * returns a list of all changed users known to the adaptor, which are in 28 * a scope interesting to webman. Changed users are those, which has a 29 * "dirty" flag set (but this detailed is application dependend). 30 * 31 * @return a list of all changed users, never <code>null</code>, but 32 * probably empty. The elements are of type {@link de.webman.sync.User} 33 * @throws SyncException bread and cheese 34 **/ 35 List getChangedUsers() throws SyncException; 36 37 38 /** 39 * returns a list of all workers, which has to be called in the given 40 * order by the synchronization system. The synchronization system is 41 * free to call the workers not at once but stretched of time, but not 42 * concurrently. This is to avoid sleep locks from update cycles. 43 **/ 44 List getWorkers(); 45 46 /** 47 * changes the dirty state for a given user 48 * @param user the user to set the dirty flag for 49 * @param value the value to set 50 * @throws SyncException if anything during changing the flag fails 51 **/ 52 void setDirtyFlagForUser(User user, boolean value) throws SyncException; 53 54 } 55