Class SplunkConnectionImpl.CountingSearchResultListener
java.lang.Object
org.apache.calcite.adapter.splunk.search.SplunkConnectionImpl.CountingSearchResultListener
- All Implemented Interfaces:
SearchResultListener
- Enclosing class:
- SplunkConnectionImpl
public static class SplunkConnectionImpl.CountingSearchResultListener
extends Object
implements SearchResultListener
Implementation of
SearchResultListener
interface that just counts the results.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionint
boolean
processSearchResult
(String[] values) Handles a record from a search result.void
setFieldNames
(String[] fieldNames)
-
Constructor Details
-
CountingSearchResultListener
public CountingSearchResultListener(boolean print)
-
-
Method Details
-
setFieldNames
- Specified by:
setFieldNames
in interfaceSearchResultListener
-
processSearchResult
Description copied from interface:SearchResultListener
Handles a record from a search result.- Specified by:
processSearchResult
in interfaceSearchResultListener
- Parameters:
values
- Values of the record- Returns:
- true to continue parsing, false otherwise
-
getResultCount
public int getResultCount()
-