### Question:
LineSequence implements Iterable<Line> { public LineSequence transform(Function<Line, Line> transform) { return new TransformLineSequence(this, transform); }  static LineSequence create(String content); abstract Line getCurrentLine(); abstract Line getNextLine(); abstract void advance(); void advance(int count); @Override Iterator<Line> iterator(); LineSequence with(Predicate<Line> predicate); LineSequence transform(Function<Line, Line> transform); abstract LineSequence lookAhead(); @Override String toString();  }### Answer:
@Test public void transform() { LineSequence lineSequence = LineSequence.create("one").transform(input -> { throw new UnsupportedOperationException(); }); assertNotNull(lineSequence); assertEquals(TransformLineSequence.class, lineSequence.getClass()); }
@Test public void transform() { LineSequence lineSequence = LineSequence.create("one").transform(new Function<Line, Line>() { @Override public Line apply(Line input) { throw new UnsupportedOperationException(); } }); assertNotNull(lineSequence); assertEquals(TransformLineSequence.class, lineSequence.getClass()); }