Constructor and Description |
---|
Union(int nomEntries,
SummarySetOperations<S> summarySetOps)
Creates new Union instance with instructions on how to process two summaries that
overlap.
|
Union(SummarySetOperations<S> summarySetOps)
Creates new Union instance with instructions on how to process two summaries that
overlap.
|
Modifier and Type | Method and Description |
---|---|
CompactSketch<S> |
getResult()
Gets the result of a sequence of stateful union operations as an unordered CompactSketch
|
void |
reset()
Resets the internal set to the initial state, which represents an empty set.
|
void |
union(Sketch<S> tupleSketch)
Performs a stateful union of the internal set with the given tupleSketch.
|
CompactSketch<S> |
union(Sketch<S> tupleSketchA,
Sketch<S> tupleSketchB)
Perform a stateless, pair-wise union operation between two tuple sketches.
|
CompactSketch<S> |
union(Sketch<S> tupleSketch,
Sketch thetaSketch,
S summary)
Perform a stateless, pair-wise union operation between a tupleSketch and a thetaSketch.
|
void |
union(Sketch thetaSketch,
S summary)
Performs a stateful union of the internal set with the given thetaSketch by combining entries
using the hashes from the theta sketch and summary values from the given summary and rules
from the summarySetOps defined by the Union constructor.
|
void |
update(Sketch<S> tupleSketch)
Deprecated.
2.0.0. Please use
union(org.apache.datasketches.tuple.Sketch) . |
void |
update(Sketch thetaSketch,
S summary)
Deprecated.
2.0.0. Please use union(org.apache.datasketches.theta.Sketch, S).
|
public Union(SummarySetOperations<S> summarySetOps)
summarySetOps
- instance of SummarySetOperationspublic Union(int nomEntries, SummarySetOperations<S> summarySetOps)
nomEntries
- nominal entries (K). Forced to the nearest power of 2 greater than
given value.summarySetOps
- instance of SummarySetOperationspublic CompactSketch<S> union(Sketch<S> tupleSketchA, Sketch<S> tupleSketchB)
Nulls and empty sketches are ignored.
tupleSketchA
- The first argumenttupleSketchB
- The second argumentpublic CompactSketch<S> union(Sketch<S> tupleSketch, Sketch thetaSketch, S summary)
Nulls and empty sketches are ignored.
tupleSketch
- The first argumentthetaSketch
- The second argumentsummary
- the given proxy summary for the theta sketch, which doesn't have one.
This may not be null.@Deprecated public void update(Sketch<S> tupleSketch)
union(org.apache.datasketches.tuple.Sketch)
.tupleSketch
- input tuple sketch to add to the internal set.
Nulls and empty sketches are ignored.
public void union(Sketch<S> tupleSketch)
tupleSketch
- input tuple sketch to merge with the internal set.
Nulls and empty sketches are ignored.
@Deprecated public void update(Sketch thetaSketch, S summary)
thetaSketch
- the given theta sketch input. If null or empty, it is ignored.summary
- the given proxy summary for the theta sketch, which doesn't have one. This may
not be null.public void union(Sketch thetaSketch, S summary)
thetaSketch
- the given theta sketch input. If null or empty, it is ignored.summary
- the given proxy summary for the theta sketch, which doesn't have one. This may
not be null.public CompactSketch<S> getResult()
public void reset()
Copyright © 2015–2021 The Apache Software Foundation. All rights reserved.