Here you can find the source of closeReader(Reader reader)
Parameter | Description |
---|---|
reader | a parameter |
public static void closeReader(Reader reader)
//package com.java2s; //License from project: Open Source License import java.io.IOException; import java.io.Reader; public class Main { /**/* w ww .j av a 2 s . c o m*/ * Closes the reader * @param reader */ public static void closeReader(Reader reader) { try { reader.close(); } catch (IOException e) { e.printStackTrace(); throw new RuntimeException("Unable to close the reader " + e.getMessage()); } } }