FeaturesPluginsDocs & SupportCommunityPartners

NetBeans Forums

 FAQFAQ   SearchSearch   MemberlistMemberlist   RegisterRegister   ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 
  

where is com.sun.source.tree?

 
Post new topic   Reply to topic    NetBeans Forums -> NetBeans Developers
View previous topic :: View next topic  
Author Message
swv



Joined: 25 Feb 2009
Posts: 163

PostPosted: Fri Oct 23, 2009 10:14 pm    Post subject: where is com.sun.source.tree? Reply with quote

I have rt.jar for java1.6 which is what was installed when I downloaded NB 6.7.1 last week and installed it.OK. That rt.jar has no com.sun.source... I discovered this by trying to import it, then going to libraries then java1.6(Default) then rt.jar.... yep nothing there.... what have I done wrong?

TIA
Back to top
View user's profile Send private message
Radosław Smogura
Posted via mailing list.





PostPosted: Sat Oct 24, 2009 11:57 am    Post subject: where is com.sun.source.tree? Reply with quote

Those packgaes are in tools.jar in _JDK_ folder, as ones are only used by
compiler and only for compiling text (Java source) files. Java API doesn't says
anything about it so, you need to bear in mind that thoes are vendor specific
and runtime doesn't have it. Other compilers can use different way to parse
sources.

If you want to develop code based on trees (in other words code using SUN
compiler), the best way is to create library and reference it in project, or
just reference tools.jar.

As the future sugestion, there are Java language model packages and classes
in javax.lang.model.* wich should be available in Java 6 versions.


Dnia sobota 24 październik 2009 o 00:14:19 software visualization napisał(a):
Quote:
I have rt.jar for java1.6 which is what was installed when I downloaded NB
6.7.1 last week and installed it.OK. That rt.jar has no com.sun.source... I
discovered this by trying to import it, then going to libraries then
java1.6(Default) then rt.jar.... yep nothing there.... what have I done
wrong?

TIA
Back to top
swv



Joined: 25 Feb 2009
Posts: 163

PostPosted: Sat Oct 24, 2009 2:08 pm    Post subject: where is com.sun.source.tree? Reply with quote

Thanks Radoslaw.. I had no idea! 

On Sat, Oct 24, 2009 at 7:56 AM, Radosław Smogura <address-removed> wrote:
Quote:
Those packgaes are in tools.jar in _JDK_ folder, as ones are only used by
compiler and only for compiling text (Java source) files. Java API doesn't says
anything about it so, you need to bear in mind that thoes are vendor specific
and runtime doesn't have it. Other compilers can use different way to parse
sources.

If you want to develop code based on trees (in other words code using SUN
compiler), the best way is to create library and reference it in project, or
just reference tools.jar.

As the future sugestion, there are Java language model packages and classes
in javax.lang.model.* wich should be available in Java 6 versions.


Dnia sobota 24 październik 2009 o 00:14:19 software visualization napisał(a):

Quote:
I have rt.jar for java1.6 which is what was installed when I downloaded NB
6.7.1 last week and installed it.OK. That rt.jar has no com.sun.source... I
discovered this by trying to import it, then going to libraries then
java1.6(Default) then rt.jar.... yep nothing there.... what have I done
wrong?

TIA



Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    NetBeans Forums -> NetBeans Developers All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum


Powered by phpBB