SOLR-8333: fix public API from referring to inner class implementation

git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/trunk@1715999 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Erik Hatcher 2015-11-24 00:34:26 +00:00
parent bc01212d1a
commit 4995bbdd85
2 changed files with 6 additions and 6 deletions

View File

@ -111,7 +111,7 @@ public class SimplePostTool {
private int currentDepth;
static HashMap<String,String> mimeMap;
GlobFileFilter globFileFilter;
FileFilter fileFilter;
// Backlog for crawling
List<LinkedHashSet<URL>> backlog = new ArrayList<>();
Set<URL> visited = new HashSet<>();
@ -286,7 +286,7 @@ public class SimplePostTool {
this.recursive = recursive;
this.delay = delay;
this.fileTypes = fileTypes;
this.globFileFilter = getFileFilterFromFileTypes(fileTypes);
this.fileFilter = getFileFilterFromFileTypes(fileTypes);
this.out = out;
this.commit = commit;
this.optimize = optimize;
@ -487,9 +487,9 @@ public class SimplePostTool {
private int postDirectory(File dir, OutputStream out, String type) {
if(dir.isHidden() && !dir.getName().equals("."))
return(0);
info("Indexing directory "+dir.getPath()+" ("+dir.listFiles(globFileFilter).length+" files, depth="+currentDepth+")");
info("Indexing directory "+dir.getPath()+" ("+dir.listFiles(fileFilter).length+" files, depth="+currentDepth+")");
int posted = 0;
posted += postFiles(dir.listFiles(globFileFilter), out, type);
posted += postFiles(dir.listFiles(fileFilter), out, type);
if(recursive > currentDepth) {
for(File d : dir.listFiles()) {
if(d.isDirectory()) {
@ -965,7 +965,7 @@ public class SimplePostTool {
if (null != dest) dest.flush();
}
public GlobFileFilter getFileFilterFromFileTypes(String fileTypes) {
public FileFilter getFileFilterFromFileTypes(String fileTypes) {
String glob;
if(fileTypes.equals("*"))
glob = ".*";

View File

@ -117,7 +117,7 @@ public class SimplePostToolTest extends SolrTestCaseJ4 {
assertFalse(t_web.typeSupported("text/foo"));
t_web.fileTypes = "doc,xls,ppt";
t_web.globFileFilter = t_web.getFileFilterFromFileTypes(t_web.fileTypes);
t_web.fileFilter = t_web.getFileFilterFromFileTypes(t_web.fileTypes);
assertFalse(t_web.typeSupported("application/pdf"));
assertTrue(t_web.typeSupported("application/msword"));
}