本文整理了Java中org.assertj.core.util.Files.newFolder()
方法的一些代码示例,展示了Files.newFolder()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Files.newFolder()
方法的具体详情如下:
包路径:org.assertj.core.util.Files
类名称:Files
方法名:newFolder
[英]Creates a new directory using the given path.
[中]使用给定路径创建新目录。
代码示例来源:origin: org.assertj/assertj-core
/**
* Creates a new directory in the system's temporary directory. The name of the directory will be the result of:
* <pre><code class='java'> UUID.randomUUID().toString();</code></pre>
*
* @return the created file.
*/
public static File newTemporaryFolder() {
String tempFileName = UUID.randomUUID().toString();
return newFolder(concat(temporaryFolderPath(), tempFileName));
}
代码示例来源:origin: joel-costigliola/assertj-core
/**
* Creates a new directory in the system's temporary directory. The name of the directory will be the result of:
* <pre><code class='java'> UUID.randomUUID().toString();</code></pre>
*
* @return the created file.
*/
public static File newTemporaryFolder() {
String tempFileName = UUID.randomUUID().toString();
return newFolder(concat(temporaryFolderPath(), tempFileName));
}
代码示例来源:origin: org.assertj/assertj-core-java8
/**
* Creates a new directory in the system's temporary directory. The name of the directory will be the result of:
* <p/>
*
* <pre><code class='java'>
* System.currentTimeMillis();
* </code></pre>
*
* @return the created file.
*/
public static File newTemporaryFolder() {
String tempFileName = String.valueOf(System.currentTimeMillis());
return newFolder(concat(temporaryFolderPath(), tempFileName));
}
内容来源于网络,如有侵权,请联系作者删除!