Provides an easy way to collect diagnostics in a list.
implements DiagnosticListener<S>
Parameters:
<S>
Since: 1.6