java - Parameter 'directory' is not a directory for a parameter which is a directory -


i'm getting strange error parameter supply method complains it's not directory in fact directory files in it...i don't understand what's wrong...

toplevel:

public static file mainschemafile = new file("src/test/resources/1040.xsd"); public static file contentdirectory = new file("src/test/resources/input"); public static file outputdirectory = new file("src/test/resources/output");   decisiontablebuilder builder =constructor.newinstance(log, contentdirectory, outputdirectory);  // here error occurs builder.compile(mainschemafile); 

the class i'm using:

public class decisiontablebuilder {     public void compiler(file schemafile) {       ...       // it's complaining contentdirectory, goes fileutils class       collection<file> flowchartfiles = fileutils.listfiles(contentdirectory, mapextension, true);       ...    } } 

here apache fileutils class:

public class fileutils {      private static void validatelistfilesparameters(file directory, iofilefilter filefilter) {         if (!directory.isdirectory()) {             throw new illegalargumentexception("parameter 'directory' not directory");         }         if (filefilter == null) {             throw new nullpointerexception("parameter 'filefilter' null");         }     }  } 

output: parameter 'directory' not directory

which error output getting...

anyone have idea happening here i'm super confused...any appreciated.

edit:

in toplevel added following line:

if(contentdirectory.isdirectory()) {     system.out.println("content directory: "+contentdirectory); }  output: src/test/resources/input 


Comments

Popular posts from this blog

c# - Better 64-bit byte array hash -

webrtc - Which ICE candidate am I using and why? -

php - Zend Framework / Skeleton-Application / Composer install issue -