public class JniBasedUnixGroupsNetgroupMapping extends JniBasedUnixGroupsMapping
GroupMappingServiceProvider
that invokes libC calls to get the group
memberships of a given user.构造器和说明 |
---|
JniBasedUnixGroupsNetgroupMapping() |
限定符和类型 | 方法和说明 |
---|---|
void |
cacheGroupsAdd(List<String> groups)
Caches the group user information
|
void |
cacheGroupsRefresh()
Refresh the cache of groups and user mapping
|
List<String> |
getGroups(String user)
Gets unix groups and netgroups for the user.
|
protected List<String> |
getUsersForNetgroup(String netgroup)
Calls JNI function to get users for a netgroup, since C functions
are not reentrant we need to make this synchronized (see
documentation for setnetgrent, getnetgrent and endnetgrent)
|
public List<String> getGroups(String user) throws IOException
getGroups
在类中 JniBasedUnixGroupsMapping
user
- User's nameIOException
public void cacheGroupsRefresh() throws IOException
cacheGroupsRefresh
在类中 JniBasedUnixGroupsMapping
IOException
public void cacheGroupsAdd(List<String> groups) throws IOException
cacheGroupsAdd
在类中 JniBasedUnixGroupsMapping
groups
- list of groups to add to cacheIOException
Copyright © 2009 The Apache Software Foundation