Here you can find the source of close(InputStream inputStream)
public static void close(InputStream inputStream)
//package com.java2s; /******************************************************************************* * Copyright (c) 2011 Frank Appel and others. * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License v1.0 * which accompanies this distribution, and is available at * http://www.eclipse.org/legal/epl-v10.html * * Contributors:// ww w. j a va 2s .c om * Frank Appel - initial API and implementation * EclipseSource - ongoing development ******************************************************************************/ import java.io.*; public class Main { public static void close(InputStream inputStream) { try { inputStream.close(); } catch (IOException ioe) { throw new RuntimeException("Failed to close input stream.", ioe); } } }