public class ImportUtils
extends java.lang.Object
Constructor and Description |
---|
ImportUtils() |
Modifier and Type | Method and Description |
---|---|
static DistributedFileSystem |
getFileSystem(java.lang.String path) |
static FileInfo |
getImportFileInfo(java.lang.String filePath)
Return the total space consumed by the import data files.
|
static java.lang.String |
unescape(java.lang.String str) |
static void |
validateReadable(java.lang.String file,
boolean checkDirectory)
Check that the file given by the string path (or directory, if flagged) exists and is readable.
|
static void |
validateWritable(java.lang.String path,
boolean checkDirectory)
ValidateWritable FileSystem
|
public static FileInfo getImportFileInfo(java.lang.String filePath) throws StandardException, java.io.IOException
java.io.IOException
StandardException
public static void validateReadable(java.lang.String file, boolean checkDirectory) throws StandardException
file
- the absolute path to the filecheckDirectory
- check as a directory if this flag setStandardException
public static void validateWritable(java.lang.String path, boolean checkDirectory) throws StandardException
path
- the path to checkcheckDirectory
- if true, then ensure that the file specified by path
is not
a directoryStandardException
public static DistributedFileSystem getFileSystem(java.lang.String path) throws StandardException
StandardException
public static java.lang.String unescape(java.lang.String str) throws java.io.IOException
java.io.IOException