-
public final class FileExtKt
-
-
Method Summary
Modifier and Type Method Description final static BooleancanReadSafe(File $self, InternalLogger internalLogger)Non-throwing version of File.canRead. final static BooleanexistsSafe(File $self, InternalLogger internalLogger)Non-throwing version of File.exists. final static Array<File>listFilesSafe(File $self, InternalLogger internalLogger, FilenameFilter filter)Non-throwing version of File.listFiles. final static StringreadTextSafe(File $self, Charset charset, InternalLogger internalLogger)Non-throwing version of File. final static List<String>readLinesSafe(File $self, Charset charset, InternalLogger internalLogger)Non-throwing version of File. -
-
Method Detail
-
canReadSafe
final static Boolean canReadSafe(File $self, InternalLogger internalLogger)
Non-throwing version of File.canRead. If exception happens, false is returned.
-
existsSafe
final static Boolean existsSafe(File $self, InternalLogger internalLogger)
Non-throwing version of File.exists. If exception happens, false is returned.
-
listFilesSafe
final static Array<File> listFilesSafe(File $self, InternalLogger internalLogger, FilenameFilter filter)
Non-throwing version of File.listFiles. If exception happens, null is returned.
-
readTextSafe
final static String readTextSafe(File $self, Charset charset, InternalLogger internalLogger)
Non-throwing version of File.readText. If exception happens, null is returned.
-
readLinesSafe
final static List<String> readLinesSafe(File $self, Charset charset, InternalLogger internalLogger)
Non-throwing version of File.readLines. If exception happens, null is returned.
-
-
-
-