while (iterator.hasNext()) {
StackTraceElement element = iterator.next();
iterator.remove();
// If we haven't yet reached an entry point, just keep going
if (!start.accept(element.getClassName())) continue;
// We found an entry point.
// Fast-forward past this class
while(iterator.hasNext()&&element.getClassName().equals(iterator.next().getClassName())) iterator.remove();