public final class DoubleSummarySetOperations extends Object implements SummarySetOperations<DoubleSummary>
Constructor and Description |
---|
DoubleSummarySetOperations(DoubleSummary.Mode unionSummaryMode,
DoubleSummary.Mode intersectionSummaryMode)
Creates a new instance with two modes
|
Modifier and Type | Method and Description |
---|---|
DoubleSummary |
intersection(DoubleSummary a,
DoubleSummary b)
This is called by the intersection operator when both sketches have the same hash value.
|
DoubleSummary |
union(DoubleSummary a,
DoubleSummary b)
This is called by the union operator when both sketches have the same hash value.
|
public DoubleSummarySetOperations(DoubleSummary.Mode unionSummaryMode, DoubleSummary.Mode intersectionSummaryMode)
unionSummaryMode
- for unionsintersectionSummaryMode
- for intersectionspublic DoubleSummary union(DoubleSummary a, DoubleSummary b)
SummarySetOperations
Caution: Do not modify the input Summary objects. Also do not return them directly, unless they are immutable (most Summary objects are not). For mutable Summary objects, it is important to create a new Summary object with the correct contents to be returned. Do not return null summaries.
union
in interface SummarySetOperations<DoubleSummary>
a
- Summary from sketch Ab
- Summary from sketch Bpublic DoubleSummary intersection(DoubleSummary a, DoubleSummary b)
SummarySetOperations
Caution: Do not modify the input Summary objects. Also do not return them directly, unless they are immutable (most Summary objects are not). For mutable Summary objects, it is important to create a new Summary object with the correct contents to be returned. Do not return null summaries.
intersection
in interface SummarySetOperations<DoubleSummary>
a
- Summary from sketch Ab
- Summary from sketch BCopyright © 2015–2021 The Apache Software Foundation. All rights reserved.