2019-01-11 11:33:05 +00:00
|
|
|
/*
|
|
|
|
* This file is part of ComputerCraft - http://www.computercraft.info
|
|
|
|
* Copyright Daniel Ratcliffe, 2011-2019. Do not distribute without permission.
|
|
|
|
* Send enquiries to dratcliffe@gmail.com
|
|
|
|
*/
|
|
|
|
|
|
|
|
package dan200.computercraft.shared.util;
|
|
|
|
|
|
|
|
import java.io.Closeable;
|
|
|
|
import java.io.IOException;
|
|
|
|
|
2019-03-29 21:21:39 +00:00
|
|
|
public final class IoUtil
|
2019-01-11 11:33:05 +00:00
|
|
|
{
|
2019-03-29 21:21:39 +00:00
|
|
|
private IoUtil() {}
|
|
|
|
|
2019-01-11 11:33:05 +00:00
|
|
|
public static void closeQuietly( Closeable closeable )
|
|
|
|
{
|
|
|
|
try
|
|
|
|
{
|
|
|
|
closeable.close();
|
|
|
|
}
|
|
|
|
catch( IOException ignored )
|
|
|
|
{
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|