code: public static void createParentDirectories(File file) {
  		File parent = file.getParentFile();
  		if (!parent.isDirectory()) {
  			// Test the creation separately as there appears to be a race
  			// condition that causes unit tests to sometimes fail.
  			boolean created = parent.mkdirs();
  			if (!created && !parent.isDirectory()) {
  				throw new SystemException(MessageUtils.format(
  						MSG_CANNOT_CREATE_OUTPUT_DIRECTORY,
  						parent.getAbsolutePath()), parent);
  			}
  		}
  
  	}
docs: Creates parent directories of the given file. The file must be absolute.
  
  @param file absolute file to use for creating parent directories
  
  @throws SystemException
  if directory or directories cannot be created