The interface representing a threshold to be used in ThresholdBatcher. Thresholds do not need to
be thread-safe if they are only used inside ThresholdBatcher.
Type Parameter
Name
Description
E
Methods
accumulate(E e)
publicabstractvoidaccumulate(Ee)
Presents the element to the threshold for the attribute of interest to be accumulated.
Any calls into this function from ThresholdBatcher will be under a lock.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-03-21 UTC."],[[["This webpage provides documentation for the `BatchingThreshold` interface in the Google API Client Library for Java, specifically within the `com.google.api.gax.batching` package, with the latest version being 2.63.1."],["The `BatchingThreshold` interface is used within `ThresholdBatcher` to define criteria for batching elements, and does not require thread-safety if used exclusively within `ThresholdBatcher`."],["Key methods of the `BatchingThreshold` interface include `accumulate(E e)` for accumulating elements, `copyWithZeroedValue()` for creating a copy with a zeroed value, and `isThresholdReached()` to check if the batching threshold has been met."],["The page lists the available versions of this documentation from version 2.63.1 down to version 2.7.1, with links to each version's specific documentation, offering a comprehensive history of the `BatchingThreshold` interface."],["The `E` type parameter used throughout the documentation does not have a provided description."]]],[]]