enabling etrace-xxx in ant based runs ?
Hi! I do not use jde-run (nor compile for that matter) as all our builds (including launching of compile, run, debug etc.) is initiated and controlled by ant. But for some reason the jde-run-etrace-xxx is only available when i am using jde-run, so... How do I enable jde-run-etrace-xxx functions when jde-build has been run ? (the other standard compilation functions works - like next-error etc.) With hope, Max
Re: print the stack in JDebug
Any tips on howto enable this for stacktraces generated when compiling, building and running via jde-build ? /Max Paul Kinnucan [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... Laurent Mirguet writes: Thank you for your answer. It is indeed what I was looking for. Do you intend to include jde-stack.el in JDE in the future ? The jde-stack.el functionality is already included in the JDE in jde-run.el. - Paul
Re: JDEbug performance
Start your java application with a -classic option to disable HotSpot - then it runs smooth! What JVM are you running under? java -version java version 1.3.1_02 Java(TM) 2 Runtime Environment, Standard Edition (build 1.3.1_02-b02) Java HotSpot(TM) Client VM (build 1.3.1_02-b02, mixed mode) Runing on Windows 2000 Service pack 2 I am just setting -Djava.compiler=NONE That was also enough in the good old days :) This is from my 1.3.1_02 javadoc: The Java HotSpotTM Client VM The Java HotSpot Client VM is the default virtual machine. Its use of Java HotSpot technology gives it superior performance to that of the Classic VM. Unless special command-line options are used to invoke the Classic VM instead (see below), java will always launch an application to run on the Client VM. The Java 2 Classic VM The Java 2 Classic VM is essentially the same virtual machine implementation as in version 1.2 of the Java 2 SDK. It may be invoked by using the -classic command-line option, as in this example: java -classic MyApp The Java 2 Classic VM is included only in the Java 2 SDK. It is not included in the Java 2 Runtime Environment. The -classic option will not work with the Java 2 Runtime Environment. So, even the doc says: To disable HotSpot use -classic, AND it is only possible on the SDK. I also read at some point which I can't find again (nice proof, eh! :) that the JDK in 1.3 will ignore the -Djava.compiler=NONE instruction and still use HotSpot. A while ago I posted some fixes/suggestions for changes in JDE to ensure that debugged applications started from JDE ran in classic mode, but I do not know if these changes have made it into the codebase yet Do you have this documented anywhere? What was the subject line? Here is some trace of it. http://www.mail-archive.com/jde@sunsite.dk/msg02979.html Maybe it has been fixed - can't remember it. But this still holds: But the solution is to just start your java app externally from e.g. Ant or a simple commandline and then just attach to the JVM from JDebug. With hope Max
Re: JDEbug performance
Huh... when I try -classic -Xdebug, I get: Exception in thread main java.lang.NoClassDefFoundError: sun/tools/agent/Agent Could not create the Java virtual machine. Running just -classic works, but adding the -Xdebug gives me the above barfage. It should be the very first argument to java! This one works for me (running it via ant) jdk-1.3.1_02\jre\..\bin\java.exe -classic -Xrunjdwp:transport=dt_socket,addr ess=2112,server=y,suspend=y -Xdebug -Xnoagent -
problem with stack/Up
When I press stack Up in JDEbug i get a message saying let*: Symbol's function definition is void: jde-dbo-show-line Anyone ? With hope Max
todays contribution :)
With these updated funcitons in jde-db.el JDEbug will stop bugging you about source file it cannot find. Just remember to set jde-db-query-source-file-silently to t to activate it. Use it as you pleases. (defcustom jde-db-query-source-file-silently nil *If non-nil the debugger will just silently ignore sourcebuffers for which there is no source. :group 'jde-project :type 'boolean) (defun jde-db-query-source-file (class) (let ((source-file (if jde-db-query-source-file-silently (progn (message JDEbug silently ignoring to find source for %s class) nil) (read-file-name (format Cannot find %s source. Enter path: class ) (if (and source-file (file-exists-p source-file) (not (file-directory-p source-file))) (find-file-noselect source-file With hope Max Rydahl Andersen
Re: problems with jde-help-docsets
Hello Paul, It is JDE 2.2.9beta8. Maybe this info can help When i do a M-x describe-variable jde-help-docsets the value shown is the following: ((javadoc x:\\products\\jdk-1.3.1_02\\docs\\api jde-help-find-javadoc) (javadoc x:\\products\\junit-3.7\\javadoc jde-help-find-javadoc) (javadoc x:\\products\\log4j-1.1.3\\docs\\api jde-help-find-javadoc) (javadoc x:\\products\\jaxp-1.1\\docs\\api jde-help-find-javadoc) (javadoc x:\\products\\oracle_jdbc-8.1.7\\doc jde-help-find-javadoc) (javadoc x:\\products\\eospac-1.0.EA2\\doc\\api\\ jde-help-find-javadoc) (javadoc u:/projects/devel/elektra/modules/persistence/doc/javadoc jde-help-find-javadoc) (javadoc u:/projects/devel/elektra/modules/integrator/doc/javadoc jde-help-find-javadoc) (JDK API nil)) These values are added like this: (add-to-list 'jde-help-docsets (list javadoc x 'jde-help-find-javadoc)) Where x is a string. Then when I do a M-x customize-variable jde-help-docsets then the customization buffer shows this: jde-help-docsets: Hide (list (list JDK API nil)) State: this option has been changed outside the customize buffer. (mismatch) Lists collections of HTML files documenting Java classes. Hide This list is used by the `jde-help-class' command to find help for a class. You can specify the following information for each docset: Friday, January 25, 2002, 11:58:02 AM, you wrote: Paul Max Rydahl Andersen writes: Paul I've discovered a oddity with jde-help-docsets :) Paul Paul It seems that the third parameter which designates the doc-lookup-function Paul has to be something other than nil, even though it is ignored by the jde Paul lookup facility when it simply is a javadoc type of docset. Paul Paul Customise will not let me save manually added docsets which has no function Paul present Paul and C-v-w complains about a function definition being nil if I set it Paul programaticlly. Paul Paul My current workaround is just to put in a name of an existing function - Paul then it works. Paul Paul Just so you know :) Paul Which version of the JDE are you using? The latest version (JDE 2.2.9beta8) Paul lets you specify nil as the value. Paul - Paul -- Best regards, Maxmailto:[EMAIL PROTECTED]
problems with jde-help-docsets
I've discovered a oddity with jde-help-docsets :) It seems that the third parameter which designates the doc-lookup-function has to be something other than nil, even though it is ignored by the jde lookup facility when it simply is a javadoc type of docset. Customise will not let me save manually added docsets which has no function present and C-v-w complains about a function definition being nil if I set it programaticlly. My current workaround is just to put in a name of an existing function - then it works. Just so you know :) Max
Re: problems with jde-help-docsets
Hello Paul, Always ready to help a great and usable project :) Thursday, January 24, 2002, 9:26:09 PM, you wrote: Paul Max Rydahl Andersen writes: Paul I've discovered a oddity with jde-help-docsets :) Paul Paul It seems that the third parameter which designates the doc-lookup-function Paul has to be something other than nil, even though it is ignored by the jde Paul lookup facility when it simply is a javadoc type of docset. Paul Paul Customise will not let me save manually added docsets which has no function Paul present Paul and C-v-w complains about a function definition being nil if I set it Paul programaticlly. Paul Paul My current workaround is just to put in a name of an existing function - Paul then it works. Paul Paul Just so you know :) Paul Hey Max, Paul Looks like I'm going to have a busy night tonight. Thanks for today's Paul many contributions. Paul Regards, Paul Paul -- Best regards, Maxmailto:[EMAIL PROTECTED]
Re: jde-file-to-url which are compatible with Opera and internet explorer
And now I have tested it with IE6 and it works! halleluja! :) Max Rydahl Andersen [EMAIL PROTECTED] wrote in message a2pm59$ei1$[EMAIL PROTECTED]">news:a2pm59$ei1$[EMAIL PROTECTED]... Paul Kinnucan [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... Schewe, Jon (MN65) writes: I just tried it in IE6 and it doesn't work. Sorry to spoil you're day. Maybe I spoke too fast. This bears further investigation. - Paul ok - I have now tried this function with IE5, Opera 6, Mozilla 0.9.7 - can anyone check it on IE6 and others ? It simply just uses a empty-string for localhost insted (as in accordance to http://www.w3.org/Addressing/rfc1738.txt) With hope :) (defun jde-file-to-url (file) Convert FILE path to a URL. If FILE is a DOS path, this function replaces the colon in the drive specifier with a vertical bar (|) because both Internet Explorer and Netscape accept the resulting URL whereas Netscape does not accept a drive specifier with a colon. (if (or (string-match http: file) (string-match file: file)) file (format file:///%s ;; Check for DOS path. (if (string-match [a-zA-Z]: file) (substitute ?| ?: file) (jde-convert-cygwin-path file)
Re: JDE vs. java-mode
Stuff that java-mode does not do which is VERY usefull :) * import of a class with a simple keystroke (C-v-z) * lookup java doc for a class or symbol (C-v-w) * lookup java source code for class (C-v-y) * auto-completion (C-v .) Hey, some of those *are* pretty cool. Thanks. You're welcome :) I've got #2 and #3 working and they're nifty. I can't seem to get imports to work though; I get an error as such: Invalid function: (macro . #compiled-function (token streamorbuffer optional search-parts search-includes) ...(15) [search-includes search-parts streamorbuffer token semantic-find-nonterminal-by-function lambda (tok) eq ((semantic-token-token tok))] 6 (c:\\Program Files\\XEmacs\\xemacs-packages\\lisp\\semantic\\semantic-util.elc . 14003)) I haven't tried to debug this yet. I would suggest upgrading to the newest jde. As for ECB, I'll play with it sometime later... don't feel like downloading a new version of semantic right now. :) I'm using the latest semantic without any problemsso just do it :) With hope Max scott and more :) And try and combine it with ecb (Emacs code browser) and you get a fab combination :) Scott Evans [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... (sorry if this is a duplicate; I sent this message once, but I believe I sent it to the wrong address.) I've been using JDE for a while now but I just realized that I'm not sure I need it. I do pretty vanilla servlet development. - I don't use the JDE debugger - I do my builds with ant (via a custom build script) but that runs fine if I simply run it under M-x compile. - I don't need Java code generation - I never found speedbar very useful - I *do* like jumping to methods by name, but I generally use func-menu for that (I think senator provides this functionality for JDE?). So it seems like the only thing I get form using JDE is notably slower file-open times. Forgive me if this is a FAQ, but for basic stuff like fontification and indentation, is there any reason to use JDE instead of java-mode? JDE inherits from java-mode so I assume all the fontification and indentation code comes from cc-mode... I haven't read the JDE code to see, but I figure if there are persuasive reasons to choose JDE over java-mode (like java-mode gets a bunch of things really wrong!), this is the place to ask. Thanks! scott
another (and better?) jde-open-soruce-for-symbol
Hi! I was getting tired of having the javadoc lookup and source-code lookup behave diferently, so I decided to code a better source lookup method :) You are free to (mis)use it as you please :) (defun jde-open-source-for-symbol () Displays source for a symbol. The symbol may reference an object, a class, or a method or field. If the symbol references a class, this function displays the source code for the class. If the symbol references an object, this method displays the source code for the class of the object. If the symbol references a field or a method, this function displays the source code for the class of the object of which the field or method is a member. Eventually this function will be enhanced to position the source code at the point where the method or field is located. (interactive) (condition-case err (let* ( (unqualified-name (thing-at-point 'symbol)) (class-name (jde-complete-get-qualified-name unqualified-name)) ) (if (not class-name) (let ((parse-result (jde-help-parse-symbol-at-point))) (if parse-result (progn (setq unqualified-name (car parse-result)) (setq class-name (jde-complete-get-qualified-name unqualified-name)) (if class-name (jde-open-class-source unqualified-name) (message Error: cannot find class '%s' on the current classpath. unqualified-name))) (error (message %s (error-message-string err)
Re: best mode to edit Ant files ?
If u use Emacs 21 (maybe even 20.7) use this small, but efficient addition to sgml/xml-mode. sgml/xml-mode provides the colouring of the tags (it is xml after all) - the hack provide indention and auto-completion of end tags. Completion of the tags is not possible without a DTD, but for this I just use hippie-expand or dabbrev-expand. Hope it helps: ; The functions is stolen/modfied from xslide.el ; ; It adds support for indention of tags and automatic insertion of end ; tags in xml files (without the need for DTD's) ; ; Alternatively PSGML could be used but it seems to be overkill for regular xml editing. ; e.g. it require a DTD for proper fontification and indention. (defun xml-electric-tab () Function called when TAB is pressed in XML mode. (interactive) (save-excursion (beginning-of-line) (delete-horizontal-space) (if (looking-at /) (indent-to (max 0 (- (xml-calculate-indent) 2))) (indent-to (xml-calculate-indent (if (and (bolp) (looking-at [ \t]+)) (goto-char (match-end 0 (defun xml-calculate-indent () Calculate what the indent should be for the current line (interactive) (save-excursion (if (re-search-backward ^\\([ \t]*\\) nil t) (goto-char (match-end 1)) (beginning-of-line)) (if (or (save-excursion (re-search-forward \\(/[^]+\\|[^/][^]+/\\)[ \t]*$ (save-excursion (end-of-line) (1+ (point))) t)) (bobp)) (current-column) (+ (current-column) 2 (defun xml-electric-return () Function called when enter/return is pressed in xml mode (interactive) (insert \n) (xml-electric-tab)) (defun xml-electric-less-than () Function called when \\ is pressed in xml mode (interactive) (insert ) (xml-electric-tab)) (defun xml-electric-slash () Function called when \/\ is pressed in xml mode (interactive) (insert /) (xml-electric-tab) (if (looking-at $) (let ((element-name (save-excursion (backward-char 2) (if (looking-at /) (catch 'start-tag (while (re-search-backward nil t) (cond ((looking-at /\\([^/ \t]+\\)) ;;(message End tag: %s (match-string 1)) (re-search-backward (concat (match-string 1) [ \t\n\r]) nil t)) ((looking-at \\(\\([^/]\\|/[^]\\)+\\)/)) ;;(message Empty tag: %s (match-string 1))) ((looking-at !--[^-]*\\(-[^-]+\\)*--)) ((looking-at \\([^/ \t]+\\)) ;;(message Start tag: %s (match-string 1)) (throw 'start-tag (match-string 1))) ((bobp) (throw 'start-tag nil) nil (if element-name (insert (concat element-name )) ; register additional keybindings in xml (add-hook 'sgml-mode-hook '(lambda () (progn (define-key sgml-mode-map [tab] 'xml-electric-tab) (define-key sgml-mode-map /'xml-electric-slash) (define-key sgml-mode-map 'xml-electric-less-than) ) ) ) Jeff Rancier [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... You could try http://xae.sunsite.dk Jeff -Original Message- From: Eric Chastan [mailto:[EMAIL PROTECTED]] Sent: Wednesday, December 12, 2001 3:52 AM To: [EMAIL PROTECTED] Subject: best mode to edit Ant files ? Hello, Do you know a good mode to edit Ant files (with colorization, indentation, completion ...) ? Eric.
Re: Emacs, JDE, already done ? help please
If you have configured jde-db-sourcepath to something reasonable C-c C-v C-y looksup the symbol around your cursor :) Joel Cordonnier [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... Hi ! I have start to use Emacs JDE as my IDE (instead of bad slow java IDE), but I need more functionalities. For example, with Java (or C++), how to find very quickly the java source code of a class in an 'import' statement ? For exmample, to use F1 when the cursor is in an import statement search in the 'source path' for search a class. Any idea how to do that ? already done ? I'm not an emacs-lisp programmer. Thanks /Joel ___ Do You Yahoo!? -- Une adresse @yahoo.fr gratuite et en français ! Yahoo! Courrier : http://courrier.yahoo.fr
jde-package-gen question
Hi! Why does jde-gen-package only search for a valid package name in the first non-nil variable found in jde-package-search-classpath-variabels ? Why not just search from the begining to the end and use the first best-fit ? With hope Max
another beanshell bug :)
It seems that beanshell keeps a handle to all the .zip/.jar files it has accessed. That is not nice :) It makes it impossible to call ant clean on a project which deletes all the generated .jar files which might be on jde-global-classpath. It would be much better if beanshell just kept a handle when it has to - at least not forever :) Any toggles/customization for making this happen ? With hope Max
Re: mini-buffer completion completion ? (I could not wait :) - e
Anyone with knowledge on how to have syntax-highlighting in the buffer used when calling completing-read ? It could be nice to have the correct colors while completing (it would be easier to get an overivew of the completion possibilities) With hope Max Max Rydahl Andersen [EMAIL PROTECTED] wrote in message 9quar7$776$[EMAIL PROTECTED]">news:9quar7$776$[EMAIL PROTECTED]... Well, I found that with a small addition to jde-complete-popup-completion-menu it could be easily customized :) So here is a new version of jde-complete-popup-completion-menu and a boolean customization jde-complete-use-menu which makes it possible to either use a real-menu or the more emacs-all-powerfull-completion-in-minibuffer version that I wanted. Paul, you are free to add this to newer versions of JDE(E)...ps. how does it go with the JDE problem ? ;; The following replaces the original function in jde-complete.el (defun jde-complete-popup-completion-menu (optional title) Popup a completion menu for the object at point. The popup menu displays all of the possible completions for the object it was invoked on. To automatically split large menus this function use `imenu--mouse-menu' to handle the popup menu. (let (index-alist pair name) (setq index-alist jde-complete-current-list) (setq pair (if (= (length index-alist) 1) ;; if only one item match, return it (car index-alist) (if jde-complete-use-menu ;; delegates menu handling to imenu :-) (imenu--mouse-menu index-alist (jde-cursor-posn-as-event) ; Popup window at text cursor (or title Completion)) (assoc (completing-read (or title Completion) index-alist) index-alist)) )) (setq name (cdr pair)) (setq jde-complete-current-signature (car pair)) (jde-complete-insert-completion name))) (defcustom jde-complete-use-menu t *If non nil it will use a real menu in 'jde-complete-at-point-menu' otherwise it uses the mini-buffer for completion. :group 'jde-project :type 'boolean) Max Rydahl Andersen [EMAIL PROTECTED] wrote in message 9qu8q2$q41$[EMAIL PROTECTED]">news:9qu8q2$q41$[EMAIL PROTECTED]... Hi! In JDE there is two modes of method-completion (that I have found) - either via a real-menu (jde-complete-at-point-menu) or by cycling through the possibilities via jde-complete-at-point. Is there not a method for using the standard completion buffers in emacs ? Like a jde-complete-at-point-via-completion function ? With hope Max
Re: Can't use env variable in global classpath
The JDE does support environment variables in jde-global-classpath. Ok - so the documentation concerning jde-global-classpath is wrong then ? Snip from jde-global-classpath doc: Note: do not use environment variables in the paths that you set via jde-global-classpath. Max I don't know why your environment variable is not defined in Emacs. Are you sure that your .bashrc is being invoked? Have you checked by other means that the environment variable (e.g., (getenv VAR) is defined in the Emacs child process? - Paul Max [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... Okay, found this in the docs... Note: do not use environment variables in the paths that you set via jde-global-classpath. ...so nevermind my question. Thanks, Ian - Original Message - From: [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Sunday, September 30, 2001 12:52 AM Subject: Can't use env variable in global classpath Hi, Running latest cygwin on Win2K, pre-compiled NTEmacs 20.7.1, and JDE2.2.8. I have set the global classpath to include entries that use environment variables per the users guide, but when I try to Run App I get Substituting nonexistent environment variable MY_ENV_VAR. I am using unix format for the variable (e.g. $MY_ENV_VAR). The variable is set in my .bashrc for Cygwin (e.g. export MY_ENV_VAR=/foo/bar). I launch emacs from that same bash shell (so in other words I am assuming emacs gets the env of that shell). What am I missing? Thanks, Ian . .
Re: junit integration....and questions :)
Paul Kinnucan [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... At 06:52 PM 8/16/2001 +0200, Max Rydahl Andersen wrote: Sounds great - but is there not a method for adding such templates programattically as an extension to the current buffer-templates ? The custom-set-variables should only be used in .emacs, should it not ? Yes, there is. Customize jde-gen-buffer-templates to add a template to the JDE New-Other list. Yes - but that is something that I only know to do manually through the custimization interface. My questions is - how do you do that programmatically ? I would think there should be a programmatic interface like this: (add-to-list 'jde-gen-buffer-templates my-own-buffer-template) But the above line does not work :( (probably because it ignores the :set function on the defcustom of jde-gen-buffer-templates) If it worked it would make it possible to add such buffer-templates without modifying jde-gen.el or require the user to manually copy-paste the template into the customization work. Regards Max
Re: junit integration....and questions :)
Sounds great - but is there not a method for adding such templates programattically as an extension to the current buffer-templates ? The custom-set-variables should only be used in .emacs, should it not ? Regards Max Paul Kinnucan [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... At 07:26 AM 8/15/2001 -0600, Kevin Mukhar wrote: I don't know enough lisp to know if this is the best way, but sometime ago (from this list I think) someone posted some lisp that does what you need. After putting the code into my .emacs, I can select File/JDE New/Other, then press the space bar in the mini buffer to get a selection list of the templates, from which I can select the Test Class template that I have in my .emacs. I will include the JUnit template in a future release of the JDE. - Paul The parts of my .emacs that seem to be related to creating a junit test class are as follows: (custom-set-variables ;;;other variables from my .emacs not shown '(jde-gen-test-class-buffer-template (quote ((funcall jde-gen-boilerplate-function) \package ;\''n ''n \import junit.framework.*;\''n ''n \/**\ ''n \ * \ (file-name-nondirectory buffer-file-name) ''n \ *\ ''n \ *\ ''n \ * Created: \ (current-time-string) ''n \ *\ ''n \ * @author a href=\\\mailto: (user-full-name) \/a\''n \ * @version\ ''n \ */\ ''n' ''n \public class \ (file-name-sans-extension (file-name-nondirectory buffer-file-name)) \ extends TestCase\ (if jde-gen-kr () ''n) \ {\''n'n \public \ (file-name-sans-extension (file-name-nondirectory buffer-file-name)) \ (String name)\ (if jde-gen-kr () ''n) \ {\''n \super(name);\ ''p'n \}\ ''n'n \protected void setUp() \ (if jde-gen-kr () ''n) \{\''n \}\ ''n'n \public static Test suite() \ (if jde-gen-kr () ''n) \{\''n \return new TestSuite(\ (file-name-sans-extension (file-name-nondirectory buffer-file-name)) \.class);\'n \}\ ''n'n \public static void main(String[] args) \ (if jde-gen-kr () ''n) \{\''n \junit.textui.TestRunner.run(\ (file-name-sans-extension (file-name-nondirectory buffer-file-name)) \.class);\'n \}\ ''n \}\ ''n))) '(jde-gen-buffer-templates (quote ((Test Class . jde-gen-test-class) (Class . jde-gen-class) (Console . jde-gen-console) (Swing App . jde-gen-jfc-app ) ;;;this should close custom-set-variables (defcustom jde-gen-test-class-buffer-template (list (funcall jde-gen-boilerplate-function) ''n \/**\ ''n \ * \ (file-name-nondirectory buffer-file-name) ''n \ *\ ''n \ *\ ''n \ * Created: \ (current-time-string) ''n \ *\ ''n \ * @author a href=\\\mailto: (user-full-name) \/a\''n \ * @version\ ''n \ */\ ''n' ''n \public class \ (file-name-sans-extension (file-name-nondirectory buffer-file-name)) \ extends TestCase\ (if jde-gen-kr () ''n) \{\''n'n \public \ (file-name-sans-extension (file-name-nondirectory buffer-file-name)) \ (String name)\ (if jde-gen-kr () ''n) \{\''n \super(name);\ ''p'n \}\ ''n'n \protected void setUp() \ (if jde-gen-kr () ''n) \{\''n ''p'n \}\ ''n'n \public static Test suite() \ (if jde-gen-kr () ''n) \{\''n \return new TestSuite(\ (file-name-sans-extension (file-name-nondirectory buffer-file-name)) \.class);\'n ''p'n \}\ ''n'n \public static void main(String[] args) \ (if jde-gen-kr () ''n) \{\''n \junit.textui.TestRunner.run(\ (file-name-sans-extension (file-name-nondirectory buffer-file-name)) \.class);\'n ''p'n \}\ ''n'n \}\ \// \ (file-name-sans-extension (file-name-nondirectory buffer-file-name)) ''n) *Template for new Java class. Setting this variable defines a template instantiation command `jde-gen-test-class', as a side-effect. :group 'jde-gen :type '(repeat string) :set '(lambda (sym val) (defalias 'jde-gen-test-class (tempo-define-template java-test-class-buffer-template (jde-gen-read-template val) nil Insert a generic Java class buffer skeleton.)) (set-default sym val))) ;;;###autoload (defun jde-gen-test-class-buffer (file) Create a new Java buffer containing a class of the same name. This command inserts the class template generated by `jde-gen-class'. It then moves the point to the location to the constructor. (interactive F) (find-file file) (jde-gen-test-class) (beginning-of-buffer) (search-forward {) (backward-char 1) (c-indent-exp) (tempo-forward-mark)) Max Rydahl Andersen wrote: How does one correctly register a new template so it will be available via the Files/JDE New/Other... ?
Re: Speedbar output to std out?
Use the keyboard instead of the mouse to select the contents. Max Heemskerk, Marcel [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] m... Hi all, I cannot select the speedbar frame contents to put it in a different buffer. I'd like to be able to create a listing of methods of a class for print-out purposes. Thanks, Marcel
convert multiple imports into .* imports
Well - noone answered to my request so I implemented it my self. Here is a jde-import-collapse-imports function that will collapse multiple imports from the same package into a single package import statement if the number of imports are equal or higher than the value of jde-import-collapse-imports-threshold. Hope you can use it - I sure can :) With regards Max begin 666 jde-import-extras.el M*')E75IF4@)VID92D-BAD969C=7-T;VT@:F1E+6EM]R=UC;VQL87!S M92UI;7!OG1S+71HF5S:]L9 P#0H@((J(%1HF5S:]L9!L979E;!U MV5D()Y(=J94M:6UP;W)T+6-O;QA'-E+6EM]R=',@=\@95C:61E M('=H96X@82!P86-K86=E('-T87(@:6UP;W)T(ES('5S960@:6YS=5A9!O M9B!S:6YG;4@:6UP;W)TRX@4V5T=EN9R!T:4-G1HF5S:]L9!T;R P M(AD969A=6QT*2!C875S97,@=AE($I$12!T;R!N;W0@8V]L;%PV4@86YY M=AI;F@870@86QL+B(-B @.F=R;W5P(=J94M')O:F5C= T*( Z='EP M92 G;G5M8F5R*0T*#0HH95F=6X@:F1E+6EM]R=UC;VQL87!S92UI;7!O MG1S(@F;W!T:6]N86P@8V]M;65N=',I#0HB*B!=6YC=EO;B!T:%T(-O M;QA'-E(UU;'1IQE(-L87-S(EM]R=',@9G)O;2!T:4@V%M92!P M86-K86=E(EN=\@82!S:6YG;4@+BH@%C:V%G92!I;7!OG0N(%5S97,@ M)VID92UI;7!OG0M8V]L;%PV4M:6UP;W)TRUT:')EVAO;0@=\@95C M:61E('=H96X@82 N*B!S=%T96UE;G0@:7,@9V5N97)A=5D+B!);7!L96UE M;G1E9!B2!A90@=AE('!A8VMA9V4@W1A=5M96YTR!A;F0@=AE;B!I M;G9O:V4@)VID92UI;7!OG0M:VEL;UE'1R82UI;7!OG1S('1O(-L96%N M('5P+B(-B @*EN=5R86-T:79E()0(BD-B @*]R(AE2!M86IOBUM M;V1E(=J94M;6]D92D-B @( @(AEG)OB B36%J;W(@;6]D92!M=7-T M()E(=J94M;6]D92B*2D-B @*%N9 H:6YT97)A8W1I=F4MD-B @ M( @( H8V]NW @8W5RF5N=UPF5F:7@M87)G*0T*( @( @(AS971Q M(-O;6UE;G0@=DI#0H@(AL970J(@H=]K96YS( @(AS96UA;G1I8RUB M;W9I;F%T92UT;W!L979E;!T*2D-@D@*EM]R=',@( HV5M86YT:6,M M9FEN9UN;VYT97)M:6YA;UB2UT;VME;B G:6YC;'5D92!T;VME;G,I*2D- MB @( H:68@*#P](ID92UI;7!OG0M8V]L;%PV4M:6UP;W)TRUT:')E MVAO;0@,D-@DH;65SV%G92 B0V]L;%PV4@=AR97-H;VQD('-E=!T M;R!Z97)O+B!.;R!C;VQL87!S:6YG('=I;P@;V-C=7(N(BD-B @( H:68@ M*YO=!I;7!OG1S*0T*2AM97-S86=E().;R!I;7!OG0@9F]U;F0B*0T* M( @( @*QE=H@*AP86-K86=E+6)U8VME=',@*ID92UI;7!OG0M8V]L M;%PV4M:6UP;W)TRUB=6-K971IF4@:6UP;W)TRDI#0H)( @( H97AT MF$M:6UP;W)TR @(YI;D-@D@( @(AR97%U:7)E9UI;7!OG1S(YI M;D-@D@( @(AN97M:6UP;W)TR!N:6PI( T*2 @( @*0T*2AW:EL M92!P86-K86=E+6)U8VME=',-@D@(AL970J#0H)( @( @*AB=6-K970@ M*-AB!P86-K86=E+6)U8VME=',I*2D-@D@( @*EF(@^/2 H;5N9W1H M()U8VME=D@:F1E+6EM]R=UC;VQL87!S92UI;7!OG1S+71HF5S:]L M9D-@D)*'!R;V=N#0H)2 @*%D9UT;RUL:7-T(=E'1R82UI;7!OG1S M(AC9'(@8G5C:V5T*2D-@D)( H861D+71O+6QIW0@)VYE=RUI;7!OG1S M(AC;VYC870@*-AB!B=6-K970I((N*B(I*2 [.R!!90@=AE(-O;QA M'-I;F@%C:V%G92!S=%T96UE;G0-@D)( I#0H)( @( @*%D9UT M;RUL:7-T(=R97%U:7)E9UI;7!OG1S(AC9'(@8G5C:V5T*2D-@D@( @ M( I#0H)( @(D-@D@(AS971Q('!A8VMA9V4M8G5C:V5TR H8V1R('!A M8VMA9V4M8G5C:V5TRD-@D@(D-@DI#0H)*ID92UI;7!OG0M:6YS97)T M+6EM]R=',M:6YT;RUB=69F97(@;F5W+6EM]R=',I#0H)*ID92UI;7!O MG0M:VEL;UE'1R82UI;7!OG1S(-O;6UE;G1S*0T*2DI*2D-B @*0T* M#0H-@T**1E9G5N(ID92UI;7!OG0M8V]L;%PV4M:6UP;W)TRUB=6-K M971IF4@*EM]R=',I#0H@((J4'5T(%L;!I;7!OG1S(EN=\@82!B M=6-K970@;F%M960@87,@=AE('!A8VMA9V4@=AE2!B96QO;F@=\N(@T* M( H;5T(@H%C:V%G92UB=6-K971S*2D-B @( H=VAI;4@:6UP;W)T MPT*( @( @*QE=H@*AI;7!OG0@*-AB!I;7!OG1S*2D-@D@( @ M(AN86UE(AS96UA;G1I8RUT;VME;BUN86UE(EM]R=DI#0H)( @( H M%C:V%G96YA;64@*ID92UP87)S92UG970M%C:V%G92UFF]M+6YA;64@ M;F%M92DI#0H)( @( H%C:V%G96)I;BD-@D@( @(D-@DHV5T2!P M86-K86=E8FEN(AAW-O8R!P86-K86=E;F%M92!P86-K86=E+6)U8VME=',I M*0T*2AI9B!P86-K86=E8FEN#0H)( @(AS971C9'(@%C:V%G96)I;B H M8V]NR!I;7!OG0@*-DB!P86-K86=E8FEN*2DI#0H)( HV5T2!P86-K M86=E+6)U8VME=',@*-O;G,@*-O;G,@%C:V%G96YA;64@*QIW0@:6UP M;W)T*2D@%C:V%G92UB=6-K971S*2DI#0H)*'-E='$@:6UP;W)TR H8V1R M(EM]R=',I*0T*2DI#0H@('!A8VMA9V4M8G5C:V5TRD-B @*0T*0T* ` end
Submit...Re: convert multiple imports into .*
Well - noone answered to my request so I implemented it my self. Here is a jde-import-collapse-imports function that will collapse multiple imports from the same package into a single package import statement if the number of imports are equal or higher than the value of jde-import-collapse-imports-threshold. Hope you can use it - I sure can :) With regards Max Max Rydahl Andersen [EMAIL PROTECTED] wrote in message 9j43it$88r$[EMAIL PROTECTED]">news:9j43it$88r$[EMAIL PROTECTED]... The jde-import-kill-extra-imports is great, but how about a option to collapse multiple imports from the same package to a .* import ? It should ofcourse be optional and there might be a jde-import-collapse-threshold that decided how many imports from the same package the file should have before it should start creating .*'s Just an idea Regards -- Max Rydahl Andersen, Software Engineer --- Medfork, Margrethepladsen 3, 8000 Aarhus C, Denmark Tel: +45 8732 8787 / Fax: +45 8732 8788 begin 666 jde-import-extras.el M*')E75IF4@)VID92D-BAD969C=7-T;VT@:F1E+6EM]R=UC;VQL87!S M92UI;7!OG1S+71HF5S:]L9 P#0H@((J(%1HF5S:]L9!L979E;!U MV5D()Y(=J94M:6UP;W)T+6-O;QA'-E+6EM]R=',@=\@95C:61E M('=H96X@82!P86-K86=E('-T87(@:6UP;W)T(ES('5S960@:6YS=5A9!O M9B!S:6YG;4@:6UP;W)TRX@4V5T=EN9R!T:4-G1HF5S:]L9!T;R P M(AD969A=6QT*2!C875S97,@=AE($I$12!T;R!N;W0@8V]L;%PV4@86YY M=AI;F@870@86QL+B(-B @.F=R;W5P(=J94M')O:F5C= T*( Z='EP M92 G;G5M8F5R*0T*#0HH95F=6X@:F1E+6EM]R=UC;VQL87!S92UI;7!O MG1S(@F;W!T:6]N86P@8V]M;65N=',I#0HB*B!=6YC=EO;B!T:%T(-O M;QA'-E(UU;'1IQE(-L87-S(EM]R=',@9G)O;2!T:4@V%M92!P M86-K86=E(EN=\@82!S:6YG;4@+BH@%C:V%G92!I;7!OG0N(%5S97,@ M)VID92UI;7!OG0M8V]L;%PV4M:6UP;W)TRUT:')EVAO;0@=\@95C M:61E('=H96X@82 N*B!S=%T96UE;G0@:7,@9V5N97)A=5D+B!);7!L96UE M;G1E9!B2!A90@=AE('!A8VMA9V4@W1A=5M96YTR!A;F0@=AE;B!I M;G9O:V4@)VID92UI;7!OG0M:VEL;UE'1R82UI;7!OG1S('1O(-L96%N M('5P+B(-B @*EN=5R86-T:79E()0(BD-B @*]R(AE2!M86IOBUM M;V1E(=J94M;6]D92D-B @( @(AEG)OB B36%J;W(@;6]D92!M=7-T M()E(=J94M;6]D92B*2D-B @*%N9 H:6YT97)A8W1I=F4MD-B @ M( @( H8V]NW @8W5RF5N=UPF5F:7@M87)G*0T*( @( @(AS971Q M(-O;6UE;G0@=DI#0H@(AL970J(@H=]K96YS( @(AS96UA;G1I8RUB M;W9I;F%T92UT;W!L979E;!T*2D-@D@*EM]R=',@( HV5M86YT:6,M M9FEN9UN;VYT97)M:6YA;UB2UT;VME;B G:6YC;'5D92!T;VME;G,I*2D- MB @( H:68@*#P](ID92UI;7!OG0M8V]L;%PV4M:6UP;W)TRUT:')E MVAO;0@,D-@DH;65SV%G92 B0V]L;%PV4@=AR97-H;VQD('-E=!T M;R!Z97)O+B!.;R!C;VQL87!S:6YG('=I;P@;V-C=7(N(BD-B @( H:68@ M*YO=!I;7!OG1S*0T*2AM97-S86=E().;R!I;7!OG0@9F]U;F0B*0T* M( @( @*QE=H@*AP86-K86=E+6)U8VME=',@*ID92UI;7!OG0M8V]L M;%PV4M:6UP;W)TRUB=6-K971IF4@:6UP;W)TRDI#0H)( @( H97AT MF$M:6UP;W)TR @(YI;D-@D@( @(AR97%U:7)E9UI;7!OG1S(YI M;D-@D@( @(AN97M:6UP;W)TR!N:6PI( T*2 @( @*0T*2AW:EL M92!P86-K86=E+6)U8VME=',-@D@(AL970J#0H)( @( @*AB=6-K970@ M*-AB!P86-K86=E+6)U8VME=',I*2D-@D@( @*EF(@^/2 H;5N9W1H M()U8VME=D@:F1E+6EM]R=UC;VQL87!S92UI;7!OG1S+71HF5S:]L M9D-@D)*'!R;V=N#0H)2 @*%D9UT;RUL:7-T(=E'1R82UI;7!OG1S M(AC9'(@8G5C:V5T*2D-@D)( H861D+71O+6QIW0@)VYE=RUI;7!OG1S M(AC;VYC870@*-AB!B=6-K970I((N*B(I*2 [.R!!90@=AE(-O;QA M'-I;F@%C:V%G92!S=%T96UE;G0-@D)( I#0H)( @( @*%D9UT M;RUL:7-T(=R97%U:7)E9UI;7!OG1S(AC9'(@8G5C:V5T*2D-@D@( @ M( I#0H)( @(D-@D@(AS971Q('!A8VMA9V4M8G5C:V5TR H8V1R('!A M8VMA9V4M8G5C:V5TRD-@D@(D-@DI#0H)*ID92UI;7!OG0M:6YS97)T M+6EM]R=',M:6YT;RUB=69F97(@;F5W+6EM]R=',I#0H)*ID92UI;7!O MG0M:VEL;UE'1R82UI;7!OG1S(-O;6UE;G1S*0T*2DI*2D-B @*0T* M#0H-@T**1E9G5N(ID92UI;7!OG0M8V]L;%PV4M:6UP;W)TRUB=6-K M971IF4@*EM]R=',I#0H@((J4'5T(%L;!I;7!OG1S(EN=\@82!B M=6-K970@;F%M960@87,@=AE('!A8VMA9V4@=AE2!B96QO;F@=\N(@T* M( H;5T(@H%C:V%G92UB=6-K971S*2D-B @( H=VAI;4@:6UP;W)T MPT*( @( @*QE=H@*AI;7!OG0@*-AB!I;7!OG1S*2D-@D@( @ M(AN86UE(AS96UA;G1I8RUT;VME;BUN86UE(EM]R=DI#0H)( @( H M%C:V%G96YA;64@*ID92UP87)S92UG970M%C:V%G92UFF]M+6YA;64@ M;F%M92DI#0H)( @( H%C:V%G96)I;BD-@D@( @(D-@DHV5T2!P M86-K86=E8FEN(AAW-O8R!P86-K86=E;F%M92!P86-K86=E+6)U8VME=',I M*0T*2AI9B!P86-K86=E8FEN#0H)( @(AS971C9'(@%C:V%G96)I;B H M8V]NR!I;7!OG0@*-DB!P86-K86=E8FEN*2DI#0H)( HV5T2!P86-K M86=E+6)U8VME=',@*-O;G,@*-O;G,@%C:V%G96YA;64@*QIW0@:6UP M;W)T*2D@%C:V%G92UB=6-K971S*2DI#0H)*'-E='$@:6UP;W)TR H8V1R M(EM]R=',I*0T*2DI#0H@('!A8VMA9V4M8G5C:V5TRD-B @*0T*0T* ` end
convert multiple imports into .*
The jde-import-kill-extra-imports is great, but how about a option to collapse multiple imports from the same package to a .* import ? It should ofcourse be optional and there might be a jde-import-collapse-threshold that decided how many imports from the same package the file should have before it should start creating .*'s Just an idea Regards -- Max Rydahl Andersen, Software Engineer --- Medfork, Margrethepladsen 3, 8000 Aarhus C, Denmark Tel: +45 8732 8787 / Fax: +45 8732 8788
Re: [OT] Auto-scroll *compilation* window
Mark Bucciarelli [EMAIL PROTECTED] writes: I found a cool utility that will auto scroll the compilation window as the output grows. (Since I started using Ant/JUnit with JDE, the output to my *compilation* window has grown quite a bit and I got tired of C-x o, C-v or C-M-v to see if my tests passed.) What's wrong with (setq compilation-scroll-output t) ? Or even easier with a "GUI" M-x customize-variable compilation-scroll-output :) -- Max R. Andersen ([EMAIL PROTECTED])