Dynamic line number in debug info

Discussion in 'Java' started by =?iso-8859-1?B?bW9vcJk=?=, Dec 19, 2005.

  1. Hi,
    I want to print out debug message with the acutal line number of the
    source file, such as:
    789 Logger.debug("hello, world!", 789);

    But when the source is changed, the line of debugging print moves upper
    or lower, is there any better way I can have the logger automatically
    trace the line number for me? Thx!
    =?iso-8859-1?B?bW9vcJk=?=, Dec 19, 2005
    #1
    1. Advertising

  2. =?iso-8859-1?B?bW9vcJk=?=

    Roedy Green Guest

    On 18 Dec 2005 17:46:25 -0800, "moop™" <> wrote,
    quoted or indirectly quoted someone who said :

    >I want to print out debug message with the acutal line number of the
    >source file, such as:
    >789 Logger.debug("hello, world!", 789);
    >
    >But when the source is changed, the line of debugging print moves upper
    >or lower, is there any better way I can have the logger automatically
    >trace the line number for me? Thx!

    see my code for imAt
    http://mindprod.com/jgloss/trace.html
    --
    Canadian Mind Products, Roedy Green.
    http://mindprod.com Java custom programming, consulting and coaching.
    Roedy Green, Dec 19, 2005
    #2
    1. Advertising

  3. Thank you, it helps!
    =?iso-8859-1?B?bW9vcJk=?=, Dec 19, 2005
    #3
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Vasanth
    Replies:
    0
    Views:
    528
    Vasanth
    Jun 28, 2004
  2. Andrea Williams

    Clear the Render info & change to different info

    Andrea Williams, Oct 27, 2004, in forum: ASP .Net
    Replies:
    2
    Views:
    1,397
    Ken Dopierala Jr.
    Oct 27, 2004
  3. Hugo
    Replies:
    10
    Views:
    1,289
    Matt Humphrey
    Oct 18, 2004
  4. Kiran
    Replies:
    0
    Views:
    1,205
    Kiran
    Feb 6, 2005
  5. ilya

    get CPU info, RAM info

    ilya, Apr 8, 2010, in forum: Java
    Replies:
    43
    Views:
    5,927
    Mike Schilling
    Apr 19, 2010
Loading...

Share This Page