queryAccess (Database - Java™)
Returns a person's, group's, or server's current access level to a database.
Defined in
Syntax
public int queryAccess(String name)
throws NotesException
Parameters
String name
The name of the person, group, or server. For a hierarchical name, the full name must be specified but can be in abbreviated format.
Return value
int
The current access level, which is one of the following:
- ACL.LEVEL_AUTHOR
- ACL.LEVEL_DEPOSITOR
- ACL.LEVEL_DESIGNER
- ACL.LEVEL_EDITOR
- ACL.LEVEL_MANAGER
- ACL.LEVEL_NOACCESS
- ACL.LEVEL_READER
Usage
If the name$ you specify is listed explicitly in the ACL, then queryAccess returns the access level for that ACL entry and does not check the groups.
If the name$ you specify is not listed explicitly in the ACL, queryAccess checks if the name$ is a member of a group in the Primary Address Book known to the computer on which the script is running. On a local workstation, that address book is the Personal Address Book. On a server, that address book is the Domino® Directory. If the queryAccess method finds name$ in one or more groups, then it returns the highest access level among those groups.
If the name$ you specify is not listed in the ACL either individually or as part of a group, queryAccess returns the default access level for the ACL.