Ok, then I might as well use SimplifiedClient... but I already have the
retrieval running without SimplifiedClient.

What I didn't find in SimplifiedClient is a method to turn a FreenetURI into
a ClientKey. I modified a similar method from SimplifiedClient like this:

  private static ClientKey makeClientKey(FreenetURI uri) throws
KeyException, IOException
  {
        if (uri.getKeyType().equals("CHK")) {
            return new ClientCHK(uri);
        } else if (uri.getKeyType().equals("KSK")) {
            return new ClientKSK(uri);
        } else if (uri.getKeyType().equals("SVK"))
            return new ClientSVK(uri);
        else if (uri.getKeyType().equals("SSK")) {
            return new ClientSSK(uri);
        } else
            throw new KeyException("Unsupported keytype in URI");
  }

Maybe that's a method worth integrating.

-Stefan

----- Original Message -----
From: "Brandon" <[email protected]>
To: <devl at freenetproject.org>
Sent: Sunday, April 08, 2001 8:07 PM

Reply via email to