|
Holger's Java API |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.antelmann.db.UserFilter
public class UserFilter
a simple user filter that conveniently allows to define acceptance based on rights
| Field Summary |
|---|
| Fields inherited from interface com.antelmann.util.Filter |
|---|
EXCLUDE_ALL_FILTER, INCLUDE_ALL_FILTER |
| Constructor Summary | |
|---|---|
UserFilter()
|
|
UserFilter(boolean onlyEnabled,
Object... requiredRights)
|
|
| Method Summary | |
|---|---|
boolean |
accept(User user)
returns true only if the given entry is accepted by this filter |
UserFilter |
add(Object... optionalRequiredRights)
|
UserFilter |
addDisjunctRights(Object... rights)
for a user to pass this filter, only one of the given rights must be accessible |
boolean |
addOptionalRights(Object... rights)
all of the given rights must be accessible by the user to pass this filter. |
void |
checkAccess(User user)
convenience method that throws an exception if this filter doesn't accept the given user |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public UserFilter()
public UserFilter(boolean onlyEnabled,
Object... requiredRights)
| Method Detail |
|---|
public UserFilter addDisjunctRights(Object... rights)
addOptionalRights(Object...)public UserFilter add(Object... optionalRequiredRights)
addOptionalRights(Object...)public boolean addOptionalRights(Object... rights)
public void checkAccess(User user)
throws SecurityException
SecurityException - if this filter doesn't accept the given userpublic boolean accept(User user)
Filter
accept in interface Filter<User>
|
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||