Code example for SearchControls

Methods: setReturningAttributes

0
     * 
     * @param attrs An array of attribute names identifying the attributes that 
     *             will be returned. Can be null. 
     */ 
    public void setReturningAttributes(String[] attrs) {
        searchControls.setReturningAttributes(attrs);
    } 
 
    public String toString() {
        StringBuilder sb = new StringBuilder();
 
        sb.append("[ searchFilter: '").append(searchFilter).append("', ");
        sb.append("searchBase: '").append(searchBase).append("'");
        sb.append(", scope: ")
          .append(searchControls.getSearchScope() == SearchControls.SUBTREE_SCOPE ? "subtree" : "single-level, ");
        sb.append(", searchTimeLimit: ").append(searchControls.getTimeLimit());
        sb.append(", derefLinkFlag: ").append(searchControls.getDerefLinkFlag()).append(" ]");
        return sb.toString();
    } 
} 
Connect your IDE to all the code out there  Get Codota for Java