v = actual.apply(t1, t2, t3, t4, t5, t6, t7); } catch (Throwable ex) { throw FunctionTagging.<Exception>justThrow(new FunctionTaggingException(tag).appendLast(ex));
v = actual.apply(t1, t2, t3, t4, t5, t6, t7); } catch (Throwable ex) { throw FunctionTagging.<Exception>justThrow(new FunctionTaggingException(tag).appendLast(ex));
v = actual.apply(t1, t2, t3, t4, t5, t6, t7, t8, t9); } catch (Throwable ex) { throw FunctionTagging.<Exception>justThrow(new FunctionTaggingException(tag).appendLast(ex));
v = actual.apply(t1, t2, t3, t4, t5, t6, t7, t8, t9); } catch (Throwable ex) { throw FunctionTagging.<Exception>justThrow(new FunctionTaggingException(tag).appendLast(ex));
v = actual.apply(t1, t2, t3, t4, t5, t6, t7, t8); } catch (Throwable ex) { throw FunctionTagging.<Exception>justThrow(new FunctionTaggingException(tag).appendLast(ex));
v = actual.apply(t1, t2, t3, t4, t5, t6); } catch (Throwable ex) { throw FunctionTagging.<Exception>justThrow(new FunctionTaggingException(tag).appendLast(ex));
v = actual.apply(t1, t2, t3, t4, t5, t6); } catch (Throwable ex) { throw FunctionTagging.<Exception>justThrow(new FunctionTaggingException(tag).appendLast(ex));
@Override public R apply(T1 t1, T2 t2, T3 t3, T4 t4, T5 t5) throws Exception { if (t1 == null) { throw new NullPointerException("t1 is null, tag = " + tag); } if (t2 == null) { throw new NullPointerException("t2 is null, tag = " + tag); } if (t3 == null) { throw new NullPointerException("t3 is null, tag = " + tag); } if (t4 == null) { throw new NullPointerException("t4 is null, tag = " + tag); } if (t5 == null) { throw new NullPointerException("t5 is null, tag = " + tag); } R v; try { v = actual.apply(t1, t2, t3, t4, t5); } catch (Throwable ex) { throw FunctionTagging.<Exception>justThrow(new FunctionTaggingException(tag).appendLast(ex)); } if (v == null) { throw new NullPointerException("The BiFunction returned null, tag = " + tag); } return v; } }
@Override public R apply(T1 t1, T2 t2, T3 t3, T4 t4, T5 t5) throws Exception { if (t1 == null) { throw new NullPointerException("t1 is null, tag = " + tag); } if (t2 == null) { throw new NullPointerException("t2 is null, tag = " + tag); } if (t3 == null) { throw new NullPointerException("t3 is null, tag = " + tag); } if (t4 == null) { throw new NullPointerException("t4 is null, tag = " + tag); } if (t5 == null) { throw new NullPointerException("t5 is null, tag = " + tag); } R v; try { v = actual.apply(t1, t2, t3, t4, t5); } catch (Throwable ex) { throw FunctionTagging.<Exception>justThrow(new FunctionTaggingException(tag).appendLast(ex)); } if (v == null) { throw new NullPointerException("The BiFunction returned null, tag = " + tag); } return v; } }
@Override public R apply(T1 t1, T2 t2, T3 t3, T4 t4) throws Exception { if (t1 == null) { throw new NullPointerException("t1 is null, tag = " + tag); } if (t2 == null) { throw new NullPointerException("t2 is null, tag = " + tag); } if (t3 == null) { throw new NullPointerException("t3 is null, tag = " + tag); } if (t4 == null) { throw new NullPointerException("t4 is null, tag = " + tag); } R v; try { v = actual.apply(t1, t2, t3, t4); } catch (Throwable ex) { throw FunctionTagging.<Exception>justThrow(new FunctionTaggingException(tag).appendLast(ex)); } if (v == null) { throw new NullPointerException("The BiFunction returned null, tag = " + tag); } return v; } }
@Override public R apply(T1 t1, T2 t2, T3 t3, T4 t4) throws Exception { if (t1 == null) { throw new NullPointerException("t1 is null, tag = " + tag); } if (t2 == null) { throw new NullPointerException("t2 is null, tag = " + tag); } if (t3 == null) { throw new NullPointerException("t3 is null, tag = " + tag); } if (t4 == null) { throw new NullPointerException("t4 is null, tag = " + tag); } R v; try { v = actual.apply(t1, t2, t3, t4); } catch (Throwable ex) { throw FunctionTagging.<Exception>justThrow(new FunctionTaggingException(tag).appendLast(ex)); } if (v == null) { throw new NullPointerException("The BiFunction returned null, tag = " + tag); } return v; } }
@Override public R apply(T1 t1, T2 t2, T3 t3) throws Exception { if (t1 == null) { throw new NullPointerException("t1 is null, tag = " + tag); } if (t2 == null) { throw new NullPointerException("t2 is null, tag = " + tag); } if (t3 == null) { throw new NullPointerException("t3 is null, tag = " + tag); } R v; try { v = actual.apply(t1, t2, t3); } catch (Throwable ex) { throw FunctionTagging.<Exception>justThrow(new FunctionTaggingException(tag).appendLast(ex)); } if (v == null) { throw new NullPointerException("The BiFunction returned null, tag = " + tag); } return v; } }
@Override public R apply(T1 t1, T2 t2) throws Exception { if (t1 == null) { throw new NullPointerException("t1 is null, tag = " + tag); } if (t2 == null) { throw new NullPointerException("t2 is null, tag = " + tag); } R v; try { v = actual.apply(t1, t2); } catch (Throwable ex) { throw FunctionTagging.<Exception>justThrow(new FunctionTaggingException(tag).appendLast(ex)); } if (v == null) { throw new NullPointerException("The BiFunction returned null, tag = " + tag); } return v; } }
@Override public R apply(T1 t1, T2 t2, T3 t3) throws Exception { if (t1 == null) { throw new NullPointerException("t1 is null, tag = " + tag); } if (t2 == null) { throw new NullPointerException("t2 is null, tag = " + tag); } if (t3 == null) { throw new NullPointerException("t3 is null, tag = " + tag); } R v; try { v = actual.apply(t1, t2, t3); } catch (Throwable ex) { throw FunctionTagging.<Exception>justThrow(new FunctionTaggingException(tag).appendLast(ex)); } if (v == null) { throw new NullPointerException("The BiFunction returned null, tag = " + tag); } return v; } }
@Override public R apply(T t) throws Exception { if (t == null) { throw new NullPointerException("t is null, tag = " + tag); } R v; try { v = actual.apply(t); } catch (Throwable ex) { throw FunctionTagging.<Exception>justThrow(new FunctionTaggingException(tag).appendLast(ex)); } if (v == null) { throw new NullPointerException("The Function returned null, tag = " + tag); } return v; } }
@Override public R apply(T1 t1, T2 t2) throws Exception { if (t1 == null) { throw new NullPointerException("t1 is null, tag = " + tag); } if (t2 == null) { throw new NullPointerException("t2 is null, tag = " + tag); } R v; try { v = actual.apply(t1, t2); } catch (Throwable ex) { throw FunctionTagging.<Exception>justThrow(new FunctionTaggingException(tag).appendLast(ex)); } if (v == null) { throw new NullPointerException("The BiFunction returned null, tag = " + tag); } return v; } }
@Override public R apply(T t) throws Exception { if (t == null) { throw new NullPointerException("t is null, tag = " + tag); } R v; try { v = actual.apply(t); } catch (Throwable ex) { throw FunctionTagging.<Exception>justThrow(new FunctionTaggingException(tag).appendLast(ex)); } if (v == null) { throw new NullPointerException("The Function returned null, tag = " + tag); } return v; } }
@Test public void addLastWhenLoopCause() { List<Throwable> list = TestHelper.trackPluginErrors(); try { IOException ex = new IOException(); IllegalArgumentException ex2 = new IllegalArgumentException(); ex.initCause(ex2); ex2.initCause(ex); new FunctionTaggingException("Tag").appendLast(ex); list = TestHelper.compositeList(list.get(0)); TestHelper.assertError(list, 0, IOException.class); TestHelper.assertError(list, 1, FunctionTaggingException.class, "Tag"); } finally { RxJavaPlugins.reset(); } }
@Test public void addLastWhenNullCause() { List<Throwable> list = TestHelper.trackPluginErrors(); try { IOException ex = new IOException((Throwable)null); new FunctionTaggingException("Tag").appendLast(ex); list = TestHelper.compositeList(list.get(0)); TestHelper.assertError(list, 0, IOException.class); TestHelper.assertError(list, 1, FunctionTaggingException.class, "Tag"); } finally { RxJavaPlugins.reset(); } }
@Test public void addLastWhenCausePresent() { IOException ex = new IOException(new NullPointerException()); new FunctionTaggingException("Tag").appendLast(ex); assertTrue(ex.getCause().getCause().toString(), ex.getCause().getCause().toString().contains("Tag")); }