protected File getDir ( String pdbId , boolean obsolete ) { File dir = null ; if ( obsolete ) { // obsolete is always split String middle = pdbId . substring ( 1 , 3 ) . toLowerCase ( ) ; dir = new File ( obsoleteDirPath , middle ) ; } else { String middle = pdbId . substring ( 1 , 3 ) . toLowerCase ( ) ; dir = new File ( splitDirPath , middle ) ; } if ( ! dir . exists ( ) ) { boolean success = dir . mkdirs ( ) ; if ( ! success ) logger . error ( "Could not create mmCIF dir {}" , dir . toString ( ) ) ; } return dir ; }
Gets the directory in which the file for a given MMCIF file would live creating it if necessary .