java Programming Glossary: searchresult
How to use an output parameter in Java? http://stackoverflow.com/questions/2824910/how-to-use-an-output-parameter-in-java would be best. For this problem I recommend an immutable SearchResult type like this to encapsulate the boolean and String search.. the boolean and String search results public class SearchResult public final String name public final boolean isFound public.. final String name public final boolean isFound public SearchResult String name boolean isFound this.name name this.isFound isFound..
Java LDAP - Determine if user in a given group? http://stackoverflow.com/questions/570466/java-ldap-determine-if-user-in-a-given-group ctx new InitialDirContext env userName is SAMAccountName SearchResult sr executeSearchSingleResult ctx SearchControls.SUBTREE_SCOPE.. Loop through the search results while ns.hasMoreElements SearchResult sr SearchResult ns.next Make sure we're looking at correct.. search results while ns.hasMoreElements SearchResult sr SearchResult ns.next Make sure we're looking at correct distinguishedName..
|