Skip to main content



      Home
Home » Newcomers » Newcomers » Use Annotation to add Line Numbers to Java Code
Use Annotation to add Line Numbers to Java Code [message #196367] Mon, 26 February 2007 17:10 Go to next message
Eclipse UserFriend
Originally posted by: nitrousfiz.googlemail.com

Hello,

I want to write a Java program that annotates java code with line number
information so that I can retrieve that information from class files after
it has been compiled.

Please help me to solve this problem!

Thanks,

Fayezin
Re: Use Annotation to add Line Numbers to Java Code [message #196419 is a reply to message #196367] Tue, 27 February 2007 01:40 Go to previous message
Eclipse UserFriend
Originally posted by: wharley.bea.com

"Fayezin Islam" <nitrousfiz@googlemail.com> wrote in message
news:ervlrs$329$1@utils.eclipse.org...
> Hello,
>
> I want to write a Java program that annotates java code with line number
> information so that I can retrieve that information from class files after
> it has been compiled.


Already done for you. It's the javac -g option, or -g:lines if you only
want line numbers and no other debugging info. Line numbers are part of the
standard debugging information.

In Eclipse, it's one of the options on the Java Compiler preferences page.
Previous Topic:detecting the end of POST_CHANGE event?
Next Topic:cannot import swt project
Goto Forum:
  


Current Time: Tue Jul 15 19:22:49 EDT 2025

Powered by FUDForum. Page generated in 0.06412 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top