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-04-02 UTC."],[[["This webpage provides documentation for the `BatchingThreshold` interface in the Google API Client Library for Java (GAX), covering versions from 2.7.1 up to the latest release, 2.63.1."],["The `BatchingThreshold` interface defines a mechanism for managing thresholds within the `ThresholdBatcher`, where each threshold does not need to be thread-safe as long as it is used within the `ThresholdBatcher`."],["The `accumulate(E e)` method allows for the accumulation of an element's attributes of interest under a lock, while the `copyWithZeroedValue()` method creates a copy of the threshold with a zeroed accumulated value, also under a lock."],["The `isThresholdReached()` method checks if a threshold has been reached and will be executed under a lock."],["Users can access specific documentation for each version of the `BatchingThreshold` interface by selecting the desired version number from the list provided, with the latest being 2.63.1."]]],[]]