@Test(expected=IllegalStateException.class) public void getDataClassOnEmptyObjectThrowsException() { Points<SimpleNumber> points = new Points<SimpleNumber>(); Class actual = points.getDataClass(); }
public Class getDataClass() { if (points.size() == 0) throw new IllegalStateException(""); return points.values().iterator().next().data.getClass(); }
Points { public Class getDataClass() { if (points.size() == 0) throw new IllegalStateException(""); return points.values().iterator().next().data.getClass(); } }
Points { public Class getDataClass() { if (points.size() == 0) throw new IllegalStateException(""); return points.values().iterator().next().data.getClass(); } Points(); }
Points { public Class getDataClass() { if (points.size() == 0) throw new IllegalStateException(""); return points.values().iterator().next().data.getClass(); } Points(); void add(Point<T> point); Map<Long, Point<T>> getPoints(); boolean isEmpty(); Class getDataClass(); }
Points { public Class getDataClass() { if (points.size() == 0) throw new IllegalStateException(""); return points.values().iterator().next().data.getClass(); } Points(); void add(Point<T> point); Map<Long, Point<T>> getPoints(); boolean isEmpty(); Class getDataClass();  }