Permalink
Browse files

Merge branch 'master' into 0.9.0

  • Loading branch information...
Nathan Marz
Nathan Marz committed Dec 10, 2012
2 parents 41c988f + bba7263 commit 0ed2b6a4bea74ed020f60a89d3c9aa147ccc879c
Showing with 5 additions and 0 deletions.
  1. +5 −0 src/jvm/storm/trident/tuple/ComboList.java
@@ -8,8 +8,10 @@
public class ComboList extends AbstractList<Object> {
public static class Factory implements Serializable {
Pointer[] index;
+ int numLists;
public Factory(int... sizes) {
+ numLists = sizes.length;
int total = 0;
for(int size: sizes) {
total+=size;
@@ -27,6 +29,9 @@ public Factory(int... sizes) {
}
public ComboList create(List[] delegates) {
+ if(delegates.length!=numLists) {
+ throw new RuntimeException("Expected " + numLists + " lists, but instead got " + delegates.length + " lists");
+ }
return new ComboList(delegates, index);
}
}

0 comments on commit 0ed2b6a

Please sign in to comment.