JBBPTokenizer implements Iterable<JBBPToken>, Iterator<JBBPToken> { @Override public void remove() { throw new UnsupportedOperationException("Unsupported operation"); } JBBPTokenizer(final String str);  JBBPTokenizer(final String str, final JBBPCustomFieldTypeProcessor customFieldTypeProcessor); static boolean isGlobalReservedName(final String name); @SuppressWarnings("NullableProblems") @Override Iterator<JBBPToken> iterator(); @Override boolean hasNext(); @Override JBBPToken next(); @Override void remove();  }
@Test public void testErrorForIteratorRemove() { assertThrows(UnsupportedOperationException.class, () -> new JBBPTokenizer("int a;").remove()); }