| | |
| | | public class BrowserController |
| | | implements TreeExpansionListener, ReferralAuthenticationListener |
| | | { |
| | | /** |
| | | * The mask used to display the number of ACIs or not. |
| | | */ |
| | | /** The mask used to display the number of ACIs or not. */ |
| | | private static final int DISPLAY_ACI_COUNT = 0x01; |
| | | |
| | | /** |
| | | * The list of attributes that are used to sort the entries (if the sorting |
| | | * option is used). |
| | | */ |
| | | /** The list of attributes that are used to sort the entries (if the sorting option is used). */ |
| | | private static final String[] SORT_ATTRIBUTES = |
| | | { "cn", "givenname", "o", "ou", "sn", "uid" }; |
| | | |
| | |
| | | */ |
| | | private static final String RDN_ATTRIBUTE = "rdn attribute"; |
| | | |
| | | /** |
| | | * The filter used to retrieve all the entries. |
| | | */ |
| | | /** The filter used to retrieve all the entries. */ |
| | | public static final String ALL_OBJECTS_FILTER = |
| | | "(|(objectClass=*)(objectClass=ldapsubentry))"; |
| | | |
| | |
| | | startRefreshNode(node, null, false); |
| | | } |
| | | |
| | | /** |
| | | * Notify this controller that authentication data have changed in the |
| | | * connection pool. |
| | | */ |
| | | /** Notify this controller that authentication data have changed in the connection pool. */ |
| | | @Override |
| | | public void notifyAuthDataChanged() { |
| | | notifyAuthDataChanged(null); |
| | |
| | | startRefreshNode(node, null, true); |
| | | } |
| | | |
| | | /** |
| | | * Stop the current refreshing. |
| | | * Nodes being expanded are collapsed. |
| | | */ |
| | | /** Stop the current refreshing. Nodes being expanded are collapsed. */ |
| | | private void stopRefresh() { |
| | | stopRefreshNode(rootNode); |
| | | // TODO: refresh must be stopped in a clean state. |
| | |
| | | * are not invoked directly by the task classes: they are |
| | | * invoked using SwingUtilities.invokeAndWait() (each of the |
| | | * methods XXX() below has a matching wrapper invokeXXX()). |
| | | * |
| | | */ |
| | | |
| | | /** |
| | |
| | | updateNodeRendering(node, task.getDisplayedEntry()); |
| | | nodeChanged = true; |
| | | if (node.isLeaf()) { |
| | | /* We didn't detect any child: remove the previously existing |
| | | * ones */ |
| | | /* We didn't detect any child: remove the previously existing ones */ |
| | | removeAllChildNodes(node, false /* Remove suffixes */); |
| | | } |
| | | } |
| | |
| | | |
| | | |
| | | |
| | | /** |
| | | * Collection utilities |
| | | */ |
| | | /** Collection utilities. */ |
| | | /** |
| | | * Returns an array of integer from a Collection of Integer objects. |
| | | * @param v the Collection of Integer objects. |
| | |
| | | } |
| | | |
| | | |
| | | /** |
| | | * The default implementation of the BrowserNodeInfo interface. |
| | | */ |
| | | /** The default implementation of the BrowserNodeInfo interface. */ |
| | | private class BrowserNodeInfoImpl implements BrowserNodeInfo |
| | | { |
| | | private BasicNode node; |