MCPcopy Create free account
hub / github.com/apache/pig / bloomOr

Method bloomOr

src/org/apache/pig/builtin/BuildBloomBase.java:83–97  ·  view source on GitHub ↗
(Tuple input)

Source from the content-addressed store, hash-verified

81
82
83 protected DataByteArray bloomOr(Tuple input) throws IOException {
84 filter = new BloomFilter(vSize, numHash, hType);
85
86 try {
87 DataBag values = (DataBag)input.get(0);
88 for (Iterator<Tuple> it = values.iterator(); it.hasNext();) {
89 Tuple t = it.next();
90 filter.or(bloomIn((DataByteArray)t.get(0)));
91 }
92 } catch (ExecException ee) {
93 throw new IOException(ee);
94 }
95
96 return bloomOut();
97 }
98
99 protected DataByteArray bloomOut() throws IOException {
100 ByteArrayOutputStream baos = new ByteArrayOutputStream(vSize / 8);

Callers 2

execMethod · 0.80
execMethod · 0.80

Calls 6

getMethod · 0.95
iteratorMethod · 0.95
bloomInMethod · 0.95
bloomOutMethod · 0.95
hasNextMethod · 0.45
nextMethod · 0.45

Tested by

no test coverage detected