Thread: [jdee-users] System include paths for Java
Brought to you by:
paullandes
From: <lu...@gn...> - 2009-07-08 14:25:16
|
Hello, What kind of support does Semantic have for "system include paths" in Java? In Java, there are two ways to obtain classes and symbols: 1. From source files, which Semantic should be able to do on its own, provided it knows where to look for them. 2. From compiled `.class' files, which needs help from external Java tools. My understanding is that, at best, Semantic can only do (1) while JDEE can only do (2). This means that using `semantic-add-system-include' to point to `.jar' or `.class' files will not have any effect. Likewise, Semantic's tools such as smart completion will not work with symbols/classes coming from compiled Java code, while JDEE's own completion system may have limitations of its own (e.g., no idle completion). My feeling is that there's a gap to be bridged between both tools. It would be nice if Semantic were able to handle (2), so that we'd have a uniform handling of Java symbol/class lookup. Technically, that would mean bringing some Elisp/Java support code from JDEE to Semantic, which may be a fair amount of work (I'm not sufficiently familiar with the two projects to have a clear idea, though). What do you think? Thanks, Ludo'. |
From: <er...@si...> - 2009-07-08 17:03:43
|
Paul Kinnucan, the original developer of JDE, wrote a prototype of what is now the semantic database system in Semantic. This database system was designed to add the layer needed to integrate the JDE tag lookup system into Semantic. I then did the current implementation, and also made a database for Emacs Lisp tags to prove it was possible. As you noticed, however, the JDEE integration never happened. Joakim has since taken my original semanticdb-java.el implementation, and started adapting it to use clojure, and has had some success. His code so far is already in CEDET/CVS. Someone who understands the language and has the necessary installed tools needs to take the time to finish this task. Eric Ludovic Courtès <lu...@gn...> seems to think that: > Hello, > > What kind of support does Semantic have for "system include paths" in > Java? > > In Java, there are two ways to obtain classes and symbols: > > 1. From source files, which Semantic should be able to do on its own, > provided it knows where to look for them. > > 2. From compiled `.class' files, which needs help from external Java > tools. > > My understanding is that, at best, Semantic can only do (1) while JDEE > can only do (2). This means that using `semantic-add-system-include' to > point to `.jar' or `.class' files will not have any effect. Likewise, > Semantic's tools such as smart completion will not work with > symbols/classes coming from compiled Java code, while JDEE's own > completion system may have limitations of its own (e.g., no idle > completion). > > My feeling is that there's a gap to be bridged between both tools. It > would be nice if Semantic were able to handle (2), so that we'd have a > uniform handling of Java symbol/class lookup. Technically, that would > mean bringing some Elisp/Java support code from JDEE to Semantic, which > may be a fair amount of work (I'm not sufficiently familiar with the two > projects to have a clear idea, though). > > What do you think? > |
From: <lu...@gn...> - 2009-07-09 08:10:49
|
Hi Eric, er...@si... writes: > Paul Kinnucan, the original developer of JDE, wrote a prototype of > what is now the semantic database system in Semantic. This database > system was designed to add the layer needed to integrate the JDE tag > lookup system into Semantic. I then did the current implementation, > and also made a database for Emacs Lisp tags to prove it was possible. > > As you noticed, however, the JDEE integration never happened. Joakim > has since taken my original semanticdb-java.el implementation, and > started adapting it to use clojure, and has had some success. His > code so far is already in CEDET/CVS. Someone who understands the > language and has the necessary installed tools needs to take the time > to finish this task. Thanks for the explanation. `semanticdb-java.el' is not part of CEDET 1.0pre6, but hopefully it'll be part of the next (pre-)release? Could it be changed to optionally use more "standard" Java tools instead of Clojure? Thanks, Ludo'. |
From: Eric M. L. <er...@si...> - 2009-07-09 10:42:47
|
On Thu, 2009-07-09 at 10:10 +0200, Ludovic Courtès wrote: > Hi Eric, > > er...@si... writes: > > > Paul Kinnucan, the original developer of JDE, wrote a prototype of > > what is now the semantic database system in Semantic. This database > > system was designed to add the layer needed to integrate the JDE tag > > lookup system into Semantic. I then did the current implementation, > > and also made a database for Emacs Lisp tags to prove it was possible. > > > > As you noticed, however, the JDEE integration never happened. Joakim > > has since taken my original semanticdb-java.el implementation, and > > started adapting it to use clojure, and has had some success. His > > code so far is already in CEDET/CVS. Someone who understands the > > language and has the necessary installed tools needs to take the time > > to finish this task. > > Thanks for the explanation. `semanticdb-java.el' is not part of > CEDET 1.0pre6, but hopefully it'll be part of the next (pre-)release? > > Could it be changed to optionally use more "standard" Java tools instead > of Clojure? Hi, That code does not currently work, so it won't go into a release until it can do something useful. The tools semanticdb-java uses is up to what sorts of contributions I get for making it work. Eric |
From: <lu...@gn...> - 2009-07-09 11:52:29
|
Hi, "Eric M. Ludlam" <er...@si...> writes: > That code does not currently work, so it won't go into a release until > it can do something useful. OK. > The tools semanticdb-java uses is up to what sorts of contributions I > get for making it work. Message received! ;-) Thanks, Ludo'. |
From: Yee K. P. <yk...@gm...> - 2009-08-17 09:11:00
|
Hi, On Wed, Jul 8, 2009 at 10:11 PM, Ludovic Courtès <lu...@gn...> wrote: [snip] > > 1. From source files, which Semantic should be able to do on its own, > provided it knows where to look for them. > > 2. From compiled `.class' files, which needs help from external Java > tools. [snip] > My feeling is that there's a gap to be bridged between both tools. It > would be nice if Semantic were able to handle (2), so that we'd have a > uniform handling of Java symbol/class lookup. I am actually playing around with this. I have been a long time user of jdee so I wasn't really sure which part of the module I am using is jdee and which part is cedet/semantic. Its actually quite easy to extract out symbols from .class files, the format is pretty well documented and the parser can be easily ported from eclipse. Personally I felt that going through the JVM Reflection way is what caused completion and lookup in jdee to be extremly slow for me some of the cases. The hard part for me currently is to understand how all these semantic stuffs work. :P Cheers, Phuah Yee Keat |
From: <lu...@gn...> - 2009-08-17 09:53:06
|
Hello, Yee Keat Phuah <yk...@gm...> writes: > On Wed, Jul 8, 2009 at 10:11 PM, Ludovic Courtès <lu...@gn...> wrote: > [snip] > >> >> 1. From source files, which Semantic should be able to do on its own, >> provided it knows where to look for them. >> >> 2. From compiled `.class' files, which needs help from external Java >> tools. > > [snip] > >> My feeling is that there's a gap to be bridged between both tools. It >> would be nice if Semantic were able to handle (2), so that we'd have a >> uniform handling of Java symbol/class lookup. > > > I am actually playing around with this. Great! > Its actually quite easy to extract out symbols from .class files, the format > is pretty well documented and the parser can be easily ported from eclipse. JDEE has a `.class' parser written in elisp (jde-parse-class.el). My understanding is that it's currently underutilized, as the commentary in this file suggests. In an ideal world, Semantic/Senator's neat completion framework would allow us to complete things regardless of whether they are defined in a `.java' or `.class' file---as opposed to choosing between `C-c C-v .' and `M-/' depending on the phase of the moon. Thanks, Ludo'. |
From: Yee K. P. <yk...@gm...> - 2009-08-18 00:45:35
|
Hi! On Mon, Aug 17, 2009 at 5:52 PM, Ludovic Courtès <lu...@gn...> wrote: > In an ideal world, Semantic/Senator's neat completion framework would > allow us to complete things regardless of whether they are defined in a > `.java' or `.class' file And also in .jar file! Cheers, Phuah Yee Keat |
From: Paul L. <la...@ma...> - 2009-08-21 04:26:08
|
Ludovic Courtès writes: > Hello, > > Yee Keat Phuah <yk...@gm...> writes: > > > On Wed, Jul 8, 2009 at 10:11 PM, Ludovic Courtès <lu...@gn...> wrote: > > [snip] > >> My feeling is that there's a gap to be bridged between both tools. It > >> would be nice if Semantic were able to handle (2), so that we'd have a > >> uniform handling of Java symbol/class lookup. > > > > > > I am actually playing around with this. > > Great! > > > Its actually quite easy to extract out symbols from .class files, the format > > is pretty well documented and the parser can be easily ported from eclipse. > > JDEE has a `.class' parser written in elisp (jde-parse-class.el). My > understanding is that it's currently underutilized, as the commentary in > this file suggests. I'm weary of anything that isn't supported well that parses classes. The class format changes between releases of the JDK and I we (JDEE) don't have the resources to keep up with the changing format. > In an ideal world, Semantic/Senator's neat completion framework would > allow us to complete things regardless of whether they are defined in a > `.java' or `.class' file---as opposed to choosing between `C-c C-v .' > and `M-/' depending on the phase of the moon. My feeling is that semantic is the way to go for all things for which we have source and using a (common) lisp JVM language (i.e. abcl/armed bear) for everything else. -- Paul Landes la...@ma... |
From: Eric M. L. <er...@si...> - 2009-08-18 01:50:49
|
On Mon, 2009-08-17 at 11:52 +0200, Ludovic Courtès wrote: > > JDEE has a `.class' parser written in elisp (jde-parse-class.el). My > understanding is that it's currently underutilized, as the commentary in > this file suggests. > > In an ideal world, Semantic/Senator's neat completion framework would > allow us to complete things regardless of whether they are defined in a > `.java' or `.class' file---as opposed to choosing between `C-c C-v .' > and `M-/' depending on the phase of the moon. > Howdy, CEDET/Semantic has a semanticdb class hierarchy that Paul K originally provided the inspiration for for just this purpose. With it, you can create a database back-end that can import any kind of file or external application into Semantic tags which will feed into the Semantic completion engine. Joakim V. has already created a backend originally for beanshell, but more recently with clojure, for doing this task, but it is not finished. If someone wanted to finish this project, I'm sure Joakim would lend a hand, and I'll help with anything on the CEDET/Semantic side. By way of example, you can use a GNU Global tags system to search for tags, or CScope. There is an example for Emacs Lisp, and Ebrowse also. Many of these tag databases provide incomplete information. It is my understanding that the Java one will be much more complete, which would be great for Java programmers. Eric |
From: <lu...@gn...> - 2009-08-18 08:26:46
|
Hi, "Eric M. Ludlam" <er...@si...> writes: > With it, you can create a database back-end that can import any kind > of file or external application into Semantic tags which will feed into > the Semantic completion engine. Joakim V. has already created a backend > originally for beanshell, but more recently with clojure, for doing this > task, but it is not finished. Noted. I haven't yet taken the time to look into it. Thanks, Ludo'. |
From: Paul L. <la...@ma...> - 2009-08-21 04:28:17
|
I'd like to see the clojure implementation. Will you pass along Joakim's contact info, please? Eric M. Ludlam writes: > On Mon, 2009-08-17 at 11:52 +0200, Ludovic Courtès wrote: > > > > > JDEE has a `.class' parser written in elisp (jde-parse-class.el). My > > understanding is that it's currently underutilized, as the commentary in > > this file suggests. > > > > In an ideal world, Semantic/Senator's neat completion framework would > > allow us to complete things regardless of whether they are defined in a > > `.java' or `.class' file---as opposed to choosing between `C-c C-v .' > > and `M-/' depending on the phase of the moon. > > > > Howdy, > > CEDET/Semantic has a semanticdb class hierarchy that Paul K originally > provided the inspiration for for just this purpose. > > With it, you can create a database back-end that can import any kind > of file or external application into Semantic tags which will feed into > the Semantic completion engine. Joakim V. has already created a backend > originally for beanshell, but more recently with clojure, for doing this > task, but it is not finished. > > If someone wanted to finish this project, I'm sure Joakim would lend a > hand, and I'll help with anything on the CEDET/Semantic side. > > By way of example, you can use a GNU Global tags system to search for > tags, or CScope. There is an example for Emacs Lisp, and Ebrowse also. > Many of these tag databases provide incomplete information. It is my > understanding that the Java one will be much more complete, which would > be great for Java programmers. > > Eric > > ------------------------------------------------------------------------------ > Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day > trial. Simplify your report design, integration and deployment - and focus on > what you do best, core application coding. Discover what's new with > Crystal Reports now. http://p.sf.net/sfu/bobj-july > _______________________________________________ > jdee-users mailing list > jde...@li... > https://lists.sourceforge.net/lists/listinfo/jdee-users -- Paul Landes la...@ma... |
From: Eric M. L. <er...@si...> - 2009-08-21 10:58:34
|
I think he was on these mailing lists, but if not, his email is in the sources of cedet/semantic/semanticdb-java.el, and cedet/ede/ede-proj-maven2.el. which are also the files you want to look at anyway. ;) These files are in CEDET/CVS, and not in the last distribution. Eric On Thu, 2009-08-20 at 23:28 -0500, Paul Landes wrote: > I'd like to see the clojure implementation. Will you pass along > Joakim's contact info, please? > > Eric M. Ludlam writes: > > On Mon, 2009-08-17 at 11:52 +0200, Ludovic Courtès wrote: > > > > > > > > JDEE has a `.class' parser written in elisp (jde-parse-class.el). My > > > understanding is that it's currently underutilized, as the commentary in > > > this file suggests. > > > > > > In an ideal world, Semantic/Senator's neat completion framework would > > > allow us to complete things regardless of whether they are defined in a > > > `.java' or `.class' file---as opposed to choosing between `C-c C-v .' > > > and `M-/' depending on the phase of the moon. > > > > > > > Howdy, > > > > CEDET/Semantic has a semanticdb class hierarchy that Paul K originally > > provided the inspiration for for just this purpose. > > > > With it, you can create a database back-end that can import any kind > > of file or external application into Semantic tags which will feed into > > the Semantic completion engine. Joakim V. has already created a backend > > originally for beanshell, but more recently with clojure, for doing this > > task, but it is not finished. > > > > If someone wanted to finish this project, I'm sure Joakim would lend a > > hand, and I'll help with anything on the CEDET/Semantic side. > > > > By way of example, you can use a GNU Global tags system to search for > > tags, or CScope. There is an example for Emacs Lisp, and Ebrowse also. > > Many of these tag databases provide incomplete information. It is my > > understanding that the Java one will be much more complete, which would > > be great for Java programmers. > > > > Eric > > > > ------------------------------------------------------------------------------ > > Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day > > trial. Simplify your report design, integration and deployment - and focus on > > what you do best, core application coding. Discover what's new with > > Crystal Reports now. http://p.sf.net/sfu/bobj-july > > _______________________________________________ > > jdee-users mailing list > > jde...@li... > > https://lists.sourceforge.net/lists/listinfo/jdee-users > > |