Interface BrowsePublisher

All Known Implementing Classes:
RootBrowsePublisher, RootBrowsePublisher.RecursiveBrowsePublisher

public interface BrowsePublisher
Receives the results of a browse: nodes, a continuation point for paging, and recursive child publishers.
  • Method Details

    • isCanceled

      boolean isCanceled()
      Returns whether the browse has been canceled.
      Returns:
      true if it has.
    • getResultCount

      int getResultCount()
      Returns the number of results added so far.
      Returns:
      the result count.
    • setContinuationPoint

      void setContinuationPoint(String continuationPoint)
      Sets the continuation point, an identifier for the current position that lets a later call resume the browse.
      Parameters:
      continuationPoint - the identifier of the current position.
    • setTotalResultsAvailable

      void setTotalResultsAvailable(int totalResultsAvailable)
      Sets the total number of results in the complete result set, regardless of paging limits.
      Parameters:
      totalResultsAvailable - the total result count.
    • newNode

      BrowsePublisher.NodeBuilder newNode(String typeId, String name)
      Starts a node. Call BrowsePublisher.NodeBuilder.add() to publish it.
      Parameters:
      typeId - the node's type id.
      name - the node's name.
      Returns:
      a builder for the node.
    • recurse

      BrowsePublisher recurse()
      Returns a publisher for browsing deeper, for recursive browses.
      Returns:
      the publisher for the next level.
    • recurse

      Returns a publisher for browsing deeper from a given path.
      Parameters:
      path - the path to browse from.
      Returns:
      the publisher for the next level.