本文整理了Java中org.apache.catalina.WebResourceSet.list()
方法的一些代码示例,展示了WebResourceSet.list()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。WebResourceSet.list()
方法的具体详情如下:
包路径:org.apache.catalina.WebResourceSet
类名称:WebResourceSet
方法名:list
[英]Obtain the list of the names of all of the files and directories located in the specified directory.
[中]获取位于指定目录中的所有文件和目录的名称列表。
代码示例来源:origin: org.springframework.boot/spring-boot
@Override
public String[] list(String path) {
return this.delegate.list(path);
}
代码示例来源:origin: codefollower/Tomcat-Research
private String[] list(String path, boolean validate) {
if (validate) {
path = validate(path);
}
// Set because we don't want duplicates
// LinkedHashSet to retain the order. It is the order of the
// WebResourceSet that matters but it is simpler to retain the order
// over all of the JARs.
HashSet<String> result = new LinkedHashSet<>();
for (ArrayList<WebResourceSet> list : allResources) {
for (WebResourceSet webResourceSet : list) {
if (!webResourceSet.getClassLoaderOnly()) {
String[] entries = webResourceSet.list(path);
for (String entry : entries) {
result.add(entry);
}
}
}
}
return result.toArray(new String[result.size()]);
}
代码示例来源:origin: org.apache.tomcat/tomcat-catalina
private String[] list(String path, boolean validate) {
if (validate) {
path = validate(path);
}
// Set because we don't want duplicates
// LinkedHashSet to retain the order. It is the order of the
// WebResourceSet that matters but it is simpler to retain the order
// over all of the JARs.
HashSet<String> result = new LinkedHashSet<>();
for (List<WebResourceSet> list : allResources) {
for (WebResourceSet webResourceSet : list) {
if (!webResourceSet.getClassLoaderOnly()) {
String[] entries = webResourceSet.list(path);
for (String entry : entries) {
result.add(entry);
}
}
}
}
return result.toArray(new String[result.size()]);
}
代码示例来源:origin: org.ops4j.pax.tipi/org.ops4j.pax.tipi.tomcat-embed-core
private String[] list(String path, boolean validate) {
if (validate) {
path = validate(path);
}
// Set because we don't want duplicates
// LinkedHashSet to retain the order. It is the order of the
// WebResourceSet that matters but it is simpler to retain the order
// over all of the JARs.
HashSet<String> result = new LinkedHashSet<>();
for (List<WebResourceSet> list : allResources) {
for (WebResourceSet webResourceSet : list) {
if (!webResourceSet.getClassLoaderOnly()) {
String[] entries = webResourceSet.list(path);
for (String entry : entries) {
result.add(entry);
}
}
}
}
return result.toArray(new String[result.size()]);
}
代码示例来源:origin: org.apache.tomee/tomee-catalina
final File baseFile = URLs.toFile(base);
if (baseFile.isDirectory()) {
final String[] libs = wr.list("/WEB-INF/lib/");
if (libs != null) {
for (final String resource : libs) {
内容来源于网络,如有侵权,请联系作者删除!