Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6148421
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T19:16:39+00:00 2026-05-23T19:16:39+00:00

i have a strange problem with truezip. i run the following code: TFile.setDefaultArchiveDetector(new TArchiveDetector(zip));

  • 0

i have a strange problem with truezip.
i run the following code:

    TFile.setDefaultArchiveDetector(new TArchiveDetector("zip"));
    String zipFile = "c:\\test\\test.zip";
    TFile dstZip = new TFile(zipFile);
    TFile newFile = new TFile("c:\\test\\c.txt");

    try {
        newFile.cp_rp(dstZip);
    } catch (IOException e) {
        // TODO Auto-generated catch block
        e.printStackTrace();
    }

when i just run it – it runs ok.

but when i debug, a “breakpoint” (not one i set) is met in line
TFile.setDefaultArchiveDetector(new TArchiveDetector(“zip”));

with the following stack:

Thread [main] (Suspended (exception ClassNotFoundException))    
URLClassLoader$1.run() line: not available [local variables unavailable]    
AccessController.doPrivileged(PrivilegedExceptionAction<T>, AccessControlContext)     line: not available [native method]   
Launcher$AppClassLoader(URLClassLoader).findClass(String) line: not available   
Launcher$AppClassLoader(ClassLoader).loadClass(String, boolean) line: not available 
Launcher$AppClassLoader.loadClass(String, boolean) line: not available  
Launcher$AppClassLoader(ClassLoader).loadClass(String) line: not available  
JSE7.<clinit>() line: 35    
FileDriver.getPriority() line: 57   
FsDriverLocator$Boot.<clinit>() line: 85    
FsDriverLocator.get() line: 59  
TArchiveDetector.<init>(FsDriverProvider, String) line: 125 
TArchiveDetector.<init>(String) line: 105   
TArchiveDetector.<clinit>() line: 80    
Test.main(String[]) line: 12    

the arg in the second line is:
java.lang.ClassNotFoundException: java.nio.file.Path

now, I truly don’t have this interface, but this is part of java.nio2 and as far as i know of, TrueZip doesn’t requires this.

any idea?

thanks

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-23T19:16:40+00:00Added an answer on May 23, 2026 at 7:16 pm

    It seems that TrueZIP tries to use the new NIO classes in Java 7.

    It seems to do so by dynamically loading a class called JSE7 and probably falling back to classic NIO when that fails.

    So even though the exception is thrown, it’s handled (caught and acted upon) by TrueZIP itself and the user won’t ever see that something went wrong.

    The code in question is in the class named de.schlichtherle.truezip.JSE7.

    It has a static initializer block, that tries to access the class java.nio.file.Path (that only exists in Java 7). When it gets a NoClassDefFoundError (usually because the class does not exist), then the static final field AVAILABLE will be set to false (which in turn leads to the new NIO driver not to be loaded).

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a strange problem, I'm using the code below to test for a
I have a strange problem with Jquery Ajax with the following code. Situation 1:
We have a strange problem. I added a couple of new schema's and orchestrations
I have a strange problem creating new counters in existing group. I have a
i have a strange problem... I'm getting string-data from db: $siteDesc = strval( $configHandle->getConfigValue(
I have a strange problem, my MSBuild runs tests, code-coverage and publishing fine (part
I have strange problem on my pc/server. I run query such as Select field1,
I have strange problem. I have class which behaves similar dropdown list. package test.view;
I have strange problem... My file strings.xml contains: <?xml version=1.0 encoding=utf-8?> <resources> <string name=building_name>My
I have a strange problem regarding null pointer exception. I'm posting the problematic code

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.