Class NodeRefresher

  • All Implemented Interfaces:
    Runnable

    public class NodeRefresher
    extends AbstractNodeTask
    The class that is in charge of doing the LDAP searches required to update a node: search the local entry, detect if it has children, retrieve the attributes required to render the node, etc.
    • Method Detail

      • getLocalEntry

        public SearchResultEntry getLocalEntry()
        Returns the local entry the refresher is handling.
        Returns:
        the local entry the refresher is handling.
      • getRemoteEntry

        public SearchResultEntry getRemoteEntry()
        Returns the remote entry for the node. It will be null if the entry is not a referral.
        Returns:
        the remote entry for the node.
      • getRemoteUrl

        public LDAPURL getRemoteUrl()
        Returns the URL of the remote entry. It will be null if the entry is not a referral.
        Returns:
        the URL of the remote entry.
      • isLeafNode

        public boolean isLeafNode()
        Tells whether the node is a leaf or not.
        Returns:
        true if the node is a leaf and false otherwise.
      • getChildEntries

        public List<SearchResultEntry> getChildEntries()
        Returns the child entries of the node.
        Returns:
        the child entries of the node.
      • isDifferential

        public boolean isDifferential()
        Returns whether this refresher object is working on differential mode or not.
        Returns:
        true if the refresher is working on differential mode and false otherwise.
      • getException

        public Exception getException()
        Returns the exception that occurred during the processing. It returns null if no exception occurred.
        Returns:
        the exception that occurred during the processing.
      • getExceptionArg

        public Object getExceptionArg()
        Returns the argument of the exception that occurred during the processing. It returns null if no exception occurred or if the exception has no arguments.
        Returns:
        the argument exception that occurred during the processing.
      • getDisplayedEntry

        public SearchResultEntry getDisplayedEntry()
        Returns the displayed entry in the browser. This depends on the visualization options in the BrowserController.
        Returns:
        the remote entry if the entry is a referral and the BrowserController is following referrals and the local entry otherwise.
      • getDisplayedUrl

        public LDAPURL getDisplayedUrl()
        Returns the LDAP URL of the displayed entry in the browser. This depends on the visualization options in the BrowserController.
        Returns:
        the remote entry LDAP URL if the entry is a referral and the BrowserController is following referrals and the local entry LDAP URL otherwise.
      • isInFinalState

        public boolean isInFinalState()
        Returns whether the refresh is over or not.
        Returns:
        true if the refresh is over and false otherwise.
      • run

        public void run()
        The method that actually does the refresh.
        Specified by:
        run in interface Runnable
        Specified by:
        run in class AbstractNodeTask