}
@Override
public final void writeList(Class<?> elementType, Collection<?> t, MediaType mediaType, Charset c, Marshaller m, OutputStream entityStream) throws JAXBException, IOException {
final OutputStreamWriter osw = new OutputStreamWriter(entityStream, c);
JSONConfiguration jsonConfig = JSONConfiguration.DEFAULT;
if (m instanceof JSONConfigurated) {
jsonConfig = ((JSONConfigurated)m).getJSONConfiguration();
}
final XMLStreamWriter jxsw = Stax2JsonFactory.createWriter(osw, jsonConfig, true);
try {