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

Method format

src/org/apache/pig/impl/util/BagFormat.java:29–43  ·  view source on GitHub ↗
(DataBag bag)

Source from the content-addressed store, hash-verified

27public class BagFormat {
28
29 public static String format(DataBag bag) {
30 StringBuffer sb = new StringBuffer();
31 sb.append('{');
32
33 Iterator<Tuple> it = bag.iterator();
34 while (it.hasNext()) {
35 Tuple t = it.next();
36 String s = TupleFormat.format(t);
37 sb.append(s);
38 if (it.hasNext())
39 sb.append(",");
40 }
41 sb.append('}');
42 return sb.toString();
43 }
44}

Callers 15

testBagFormatMethod · 0.95
toStringMethod · 0.95
formatMethod · 0.95
createOutputStreamMethod · 0.45
writeFieldAsStringMethod · 0.45
execMethod · 0.45
mockAliasMethod · 0.45
overrideMethod · 0.45
doIncrementTestMethod · 0.45
genDataSetFileMethod · 0.45

Calls 6

formatMethod · 0.95
appendMethod · 0.65
iteratorMethod · 0.65
hasNextMethod · 0.45
nextMethod · 0.45
toStringMethod · 0.45

Tested by 15

testBagFormatMethod · 0.76
mockAliasMethod · 0.36
overrideMethod · 0.36
doIncrementTestMethod · 0.36
genDataSetFileMethod · 0.36
genDataSetFile1Method · 0.36
TestOrderByMethod · 0.36
genDataSetFile1Method · 0.36