本文整理了Java中org.apache.hadoop.util.Shell.fileNotFoundException()
方法的一些代码示例,展示了Shell.fileNotFoundException()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Shell.fileNotFoundException()
方法的具体详情如下:
包路径:org.apache.hadoop.util.Shell
类名称:Shell
方法名:fileNotFoundException
[英]Create a FileNotFoundException with the inner nested cause set to the given exception. Compensates for the fact that FNFE doesn't have an initializer that takes an exception.
[中]
代码示例来源:origin: org.apache.hadoop/hadoop-common
/**
* Get a file reference to winutils.
* Always raises an exception if there isn't one
* @return the file instance referring to the winutils bin.
* @throws FileNotFoundException on any failure to locate that file.
*/
public static File getWinUtilsFile() throws FileNotFoundException {
if (WINUTILS_FAILURE == null) {
return WINUTILS_FILE;
} else {
// raise a new exception to generate a new stack trace
throw fileNotFoundException(WINUTILS_FAILURE.toString(),
WINUTILS_FAILURE);
}
}
代码示例来源:origin: org.apache.hadoop/hadoop-common
/**
* Get the Hadoop home directory. If it is invalid,
* throw an exception.
* @return a path referring to hadoop home.
* @throws FileNotFoundException if the directory doesn't exist.
*/
private static File getHadoopHomeDir() throws FileNotFoundException {
if (HADOOP_HOME_DIR_FAILURE_CAUSE != null) {
throw fileNotFoundException(
addOsText(HADOOP_HOME_DIR_FAILURE_CAUSE.toString()),
HADOOP_HOME_DIR_FAILURE_CAUSE);
}
return HADOOP_HOME_FILE;
}
代码示例来源:origin: org.apache.hadoop/hadoop-common
throw fileNotFoundException(e.toString(), e);
代码示例来源:origin: io.hops/hadoop-common
/**
* Get a file reference to winutils.
* Always raises an exception if there isn't one
* @return the file instance referring to the winutils bin.
* @throws FileNotFoundException on any failure to locate that file.
*/
public static File getWinUtilsFile() throws FileNotFoundException {
if (WINUTILS_FAILURE == null) {
return WINUTILS_FILE;
} else {
// raise a new exception to generate a new stack trace
throw fileNotFoundException(WINUTILS_FAILURE.toString(),
WINUTILS_FAILURE);
}
}
代码示例来源:origin: io.hops/hadoop-common
/**
* Get the Hadoop home directory. If it is invalid,
* throw an exception.
* @return a path referring to hadoop home.
* @throws FileNotFoundException if the directory doesn't exist.
*/
private static File getHadoopHomeDir() throws FileNotFoundException {
if (HADOOP_HOME_DIR_FAILURE_CAUSE != null) {
throw fileNotFoundException(
addOsText(HADOOP_HOME_DIR_FAILURE_CAUSE.toString()),
HADOOP_HOME_DIR_FAILURE_CAUSE);
}
return HADOOP_HOME_FILE;
}
代码示例来源:origin: io.hops/hadoop-common
throw fileNotFoundException(e.toString(), e);
内容来源于网络,如有侵权,请联系作者删除!