Here you can find the source of closeQuietly(XMLStreamWriter c)
public static void closeQuietly(XMLStreamWriter c)
//package com.java2s; //License from project: Apache License import javax.xml.stream.XMLStreamException; import javax.xml.stream.XMLStreamWriter; import java.io.Closeable; import java.io.IOException; public class Main { public static void closeQuietly(XMLStreamWriter c) { if (c == null) return; try {//from ww w .ja va2 s. com c.close(); } catch (XMLStreamException ignore) { } } public static void closeQuietly(Closeable c) { if (c == null) return; try { c.close(); } catch (IOException ignore) { } } }