Cratylus
Cratylus

Reputation: 54094

Question (again) on eclipse debugging java apis


I have a question that pops up occusionally.
I am trying to debug some jdk apis using eclipse.
I have tried:
1) Using the jre inside jdk (containing the jdk src) as the jre to use
2) Adding the jdk src as a separate project and add reference from my project to the jdk project.
I started debugging.
I got into the jdk code but only up to a certain point.
Then I got the "Attach Source" editor.
The part of code I am trying to debug is part of java's pkix apis that uses the JCE provider architecture.
So for example I do

Certificate generateCertificate(fin);//I go into the code

then I step into

return certFacSpi.engineGenerateCertificate(inStream);

And I get "Source Not Found Editor"
I see that the class called is:

public class sun.security.provider.X509Factory extends java.security.cert.CertificateFactorySpi

But I can not seem to find the package sun.security.provider in the jdk src.
Isn't all src available from SUN? Am I doing something wrong in my environment setup?

Any input is highly welcome

Upvotes: 0

Views: 220

Answers (1)

dunni
dunni

Reputation: 44545

The full source code is distributed as separate jar file, but it's a little bit outdated (6u23): http://download.java.net/jdk6/source/

But you can also download the openjdk sources, that contain also the source of the sun specific classes.

Upvotes: 2

Related Questions