private File getNextTempDirectory ( ) throws AnalysisException { File directory ; // getting an exception for some directories not being able to be // created; might be because the directory already exists? do { final int dirCount = DIR_COUNT . incrementAndGet ( ) ; directory = new File ( tempFileLocation , String . valueOf ( dirCount ) ) ; } while ( directory . exists ( ) ) ; if ( ! directory . mkdirs ( ) ) { throw new AnalysisException ( String . format ( "Unable to create temp directory '%s'." , directory . getAbsolutePath ( ) ) ) ; } return directory ; }
Retrieves the next temporary destination directory for extracting an archive .