Class RootBrowsePublisher
java.lang.Object
com.inductiveautomation.historian.gateway.api.query.browsing.RootBrowsePublisher
- All Implemented Interfaces:
BrowsePublisher
The RootBrowsePublisher class is responsible for publishing browsing results
starting from a specified root path. It implements the BrowsePublisher interface
and provides capability for managing results and handling nodes in the browsing
hierarchy.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionprotected static classprotected classNested classes/interfaces inherited from interface com.inductiveautomation.historian.gateway.api.query.browsing.BrowsePublisher
BrowsePublisher.NodeBuilder -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voidaddResult(BasicResult result) voidcancel()intRetrieves the current count of results that have been added.booleanDetermines whether the browsing operation has been canceled.Creates a new node builder with the specified type ID and name.recurse()Creates and returns a newBrowsePublisherinstance to continue browsing deeper into the hierarchical structure.voidsetContinuationPoint(String continuationPoint) Updates the continuation point for the browsing operation.voidsetTotalResultsAvailable(int totalResultsAvailable) Sets the total number of results that should be available for browsing.
-
Constructor Details
-
RootBrowsePublisher
-
-
Method Details
-
getResults
-
isCanceled
public boolean isCanceled()Description copied from interface:BrowsePublisherDetermines whether the browsing operation has been canceled.- Specified by:
isCanceledin interfaceBrowsePublisher- Returns:
- true if the browsing operation has been canceled, false otherwise.
-
cancel
public void cancel() -
getResultCount
public int getResultCount()Description copied from interface:BrowsePublisherRetrieves the current count of results that have been added.- Specified by:
getResultCountin interfaceBrowsePublisher- Returns:
- the total number of results currently stored.
-
setTotalResultsAvailable
public void setTotalResultsAvailable(int totalResultsAvailable) Description copied from interface:BrowsePublisherSets the total number of results that should be available for browsing. This value is primarily used for pagination when implementing result size limits and managing continuation points.- Specified by:
setTotalResultsAvailablein interfaceBrowsePublisher- Parameters:
totalResultsAvailable- The total count of results that exist in the complete result set regardless of any pagination constraints
-
setContinuationPoint
Description copied from interface:BrowsePublisherUpdates the continuation point for the browsing operation. The continuation point is used to track the current position within a paginated or hierarchical browsing structure, enabling continuation or resumption of browsing from a specific state.- Specified by:
setContinuationPointin interfaceBrowsePublisher- Parameters:
continuationPoint- the new continuation point to set, typically a string identifier representing the current position or state.
-
addResult
-
newNode
Description copied from interface:BrowsePublisherCreates a new node builder with the specified type ID and name. The resultingBrowsePublisher.NodeBuildercan be used to define various properties for the node before adding it to the browsing structure.- Specified by:
newNodein interfaceBrowsePublisher- Parameters:
typeId- the type identifier for the new nodename- the name of the new node- Returns:
- a
BrowsePublisher.NodeBuilderinstance to configure and add the new node
-
recurse
Description copied from interface:BrowsePublisherCreates and returns a newBrowsePublisherinstance to continue browsing deeper into the hierarchical structure. This is typically used when recursive browsing is required, starting from the current state or node.- Specified by:
recursein interfaceBrowsePublisher- Returns:
- a
BrowsePublisherfor recursive browsing at a deeper level of the hierarchy
-