static String unnullForIteration(String s) { return s == null ? "" : s; } static Collection unnullForIteration(Collection l) { ret l == null ? immutableEmptyList() : l; } static L unnullForIteration(L l) { ret l == null ? immutableEmptyList() : l; } static byte[] unnullForIteration(byte[] l) { ret l == null ? emptyByteArray() : l; } static int[] unnullForIteration(int[] l) { ret l == null ? emptyIntArray() : l; } static char[] unnullForIteration(char[] l) { ret l == null ? emptyCharArray() : l; } static double[] unnullForIteration(double[] l) { ret l == null ? emptyDoubleArray() : l; } static short[] unnullForIteration(short[] l) { ret l == null ? emptyShortArray() : l; } static Map unnullForIteration(Map l) { ret l == null ? immutableEmptyMap() : l; } static Iterable unnullForIteration(Iterable i) { ret i == null ? immutableEmptyList() : i; } static A[] unnullForIteration(A[] a) { ret a == null ? (A[]) emptyObjectArray() : a; } static BitSet unnullForIteration(BitSet b) { ret b == null ? new BitSet() : b; } ifclass Pt static Pt unnullForIteration(Pt p) { ret p == null ? new Pt : p; } endif //ifclass Symbol ifndef SymbolAsString static Symbol unnullForIteration(Symbol s) { ret s == null ? emptySymbol() : s; } //endif endifndef ifclass Pair static Pair unnullForIteration(Pair p) { ret p != null ? p : Pair(null, null); } endif static long unnullForIteration(Long l) { ret l == null ? 0L : l; }