Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Java > the problem for accessing the classes in rt.jar

Reply
Thread Tools

the problem for accessing the classes in rt.jar

 
 
Andreas Leitgeb
Guest
Posts: n/a
 
      04-18-2012
zyng <(E-Mail Removed)> wrote:
> http://stackoverflow.com/questions/4...ses-with-javac
> I copied his answer here:
> "When javac is compiling code it doesn't link against rt.jar by default.
> Instead it uses special symbol file lib/ct.sym with class stubs.


I'm glad to have learnt what "trick" it is, whose existence I
merely deduced from the symptoms you described.

Still, it's a bad thing to depend on internal classes, even if you
managed to get it to work (for now).
 
Reply With Quote
 
 
 
 
markspace
Guest
Posts: n/a
 
      04-18-2012
On 4/18/2012 8:35 AM, zyng wrote:

> I copied his answer here: "When javac is compiling code it doesn't
> link against rt.jar by default. Instead it uses special symbol file
> lib/ct.sym with class stubs.


> And the answer to my question is: javac -XDignore.symbol.file



Sweet. Thanks for posting that. I think you've helped us more than we
helped you. Much appreciated!


 
Reply With Quote
 
 
 
 
zyng
Guest
Posts: n/a
 
      04-18-2012
On Wednesday, April 18, 2012 12:02:16 PM UTC-4, markspace wrote:
>
> Sweet. Thanks for posting that. I think you've helped us more than we
> helped you. Much appreciated!


I have to thank Andreas Leitgeb for his first reply, not with the answer, but with some good content pointing me to the right direction.
Sparked by his reply, with myself several diggings, finally I found the answer.

This is the reason I come to this news group.
 
Reply With Quote
 
Andreas Leitgeb
Guest
Posts: n/a
 
      04-18-2012
zyng <(E-Mail Removed)> wrote:
> On Wednesday, April 18, 2012 12:02:16 PM UTC-4, markspace wrote:
>> Sweet. Thanks for posting that. I think you've helped us more than we
>> helped you. Much appreciated!

> I have to thank Andreas Leitgeb for his first reply,


You're welcome
 
Reply With Quote
 
Arne Vajh°j
Guest
Posts: n/a
 
      04-19-2012
On 4/18/2012 11:06 AM, zyng wrote:
> Thank you. Now I recall why we reach the current stage:
>
> The classes we need for handling fast info documents, e.g. StAXDocumentParser.class, are contained within this JAR file FastInfo_x_x.jar, a free JAR file. So we include the FastInfo JAR file in the classpath. It is referenced in build.xml
>
> However, we also found that all classes inside FastInfo JAR file are also inside rt.jar. Since rt.jar comes with jre automatically, we try to reduce one JAR file in our develop environment by eliminating FastInfo JAR and use rt.jar. Then we reached the current stage.
>
> Anyway, with all the help, I believe that to really solve the problem, we need to re-write the code which handles fast info files. Playing with build.xml cannot solve the problem.
>
> BTW, I think the way of organizing class files(FastInfo JAR -- not sure from Sun or Apache and all its content are also inside rt.jar) is not good.


You should avoid using anything undocumented from rt.jar.

It should not be a big problem using the FastInfo_x_x.jar - you
are not charged per jar file.

You should be able to get newest version from here:
http://search.maven.org/#browse|-268259873

Arne


 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Classes within classes David ASP .Net 2 07-22-2005 07:13 PM
What is the difference between nested classes and inner classes ? Razvan Java 5 07-27-2004 07:59 PM
Modifiers applied to attributes, local variables, member functions, classes and inncer classes ! Razvan Java 11 07-17-2004 08:57 PM
Can I using reflection to get all child classes or classes undera package dynamically? Carfield Yim Java 1 05-31-2004 05:33 PM
How to access inner classes variables & methods from outer classes lonelyplanet999 Java 1 11-13-2003 01:54 PM



Advertisments