public class PcFileNetworkIoUtils extends Object
| Constructor and Description |
|---|
PcFileNetworkIoUtils() |
| Modifier and Type | Method and Description |
|---|---|
static List<String> |
getListFromLineByLineText(String sourcePath,
HostsSourceType sourceType) |
static boolean |
isFileExist(String filePath)
Checks if is file exist.
|
static String |
readAll(Reader rd)
Read all.
|
static String |
readFileContentToString(String filePath)
Read file content to string.
|
static InputStream |
readFileToInputStream(String filePath)
20140907: for key management get from file to input stream.
|
static String |
readStringFromUrlGeneric(String url)
Read string from url generic.
|
public static InputStream readFileToInputStream(String filePath) throws FileNotFoundException
filePath - the file pathFileNotFoundException - the file not found exceptionpublic static boolean isFileExist(String filePath)
filePath - the file pathpublic static String readFileContentToString(String filePath) throws IOException
filePath - the file pathIOException - Signals that an I/O exception has occurred.public static String readStringFromUrlGeneric(String url) throws IOException
url - the urlIOException - Signals that an I/O exception has occurred.public static String readAll(Reader rd) throws IOException
rd - the rdIOException - Signals that an I/O exception has occurred.public static List<String> getListFromLineByLineText(String sourcePath, HostsSourceType sourceType)
Copyright © 2015–2017 eBay. All rights reserved.