Cómo descomprimir un archivo TAR usando Apache Commons

Estoy usando la biblioteca Apache Commons 1.4.1 para comprimir y descomprimir".tar.gz" archivos.

Estoy teniendo problemas con el último bit: convertir unTarArchiveInputStream en unaFileOutputStream.

Curiosamente, se está rompiendo en esta línea:

FileOutputStream fout = new FileOutputStream(destPath);

destPath es un archivo con una ruta canónica de: C: \ Documents and Settings \ Administrator \ My Documents \ JavaWorkspace \ BackupUtility \ untarred \ Test \ subdir \ testinsub.txt

Error producido:

Exception in thread "main" java.io.IOException: The system cannot find the path specified

¿Alguna idea de que podría ser? ¿Y por qué no es capaz de encontrar el camino?

Adjunto el método completo a continuación (la mayoría de los cuales se levanta deaquí).

private void untar(File dest) throws IOException {
    dest.mkdir();
    TarArchiveEntry tarEntry = tarIn.getNextTarEntry();
    // tarIn is a TarArchiveInputStream
    while (tarEntry != null) {// create a file with the same name as the tarEntry
        File destPath = new File(dest.toString() + System.getProperty("file.separator") + tarEntry.getName());
        System.out.println("working: " + destPath.getCanonicalPath());
        if (tarEntry.isDirectory()) {
            destPath.mkdirs();
        } else {
            destPath.createNewFile();
            FileOutputStream fout = new FileOutputStream(destPath);
            tarIn.read(new byte[(int) tarEntry.getSize()]);
            fout.close();
        }
        tarEntry = tarIn.getNextTarEntry();
    }
    tarIn.close();
}

Respuestas a la pregunta(2)

Su respuesta a la pregunta