• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Leave NSLog()s in Final Product? - solution
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Leave NSLog()s in Final Product? - solution


  • Subject: Re: Leave NSLog()s in Final Product? - solution
  • From: Bob Frank <email@hidden>
  • Date: Fri, 19 Mar 2004 09:27:07 -0600

Hi,

Been swamped and just catching up on my reading. Sorry for not seeing this thread sooner.

Use the right tools for the right job. Lightweight logging functions like those are good and all you need in many apps ... but .... Log4Cocoa is much more flexible. Its basically a straight port of the popular Log4J package with some extra obj-c goodness (and more planned).

http://sourceforge.net/projects/log4cocoa/

Log4Cocoa lets you control your logging not just on priority of the log statement, but also on the class where the log message is, provide a variety of formatting options for log messages (timstamp options, file name, line number where log message was, etc.), and control where the log messages get output (files, database, syslog server, etc.). Also, its easy to control all of those settings at runtime.

However, please note that many of these capabilities in the Java version that aren't fully implemented in the Cocoa version ... yet ... but we've got all of the hooks in place (*hint* *hint* ... its open source at sourceforge, if you want to start contributing just let me know or send me a patch).

If you want to read more on the benefits of flexibility, read the intro to Log4J:
http://logging.apache.org/log4j/docs/index.html (short blurb)
http://logging.apache.org/log4j/docs/manual.html (intro to various capabilities ...)


Thanks,
Bob

PS: Thanks to this thread (I think) we've got another contributor onboard. If you want the latest and greatest, grab the most current version from sourceforge cvs, because the public tarballs are a bit stale (after a move to the suburbs and a new baby last year, it seems that my coding time somehow mysteriously all disappeared :-)

[sideshow:~] bob% cvs -d:pserver:email@hidden:/cvsroot/log4cocoa login
[sideshow:~] bob% cvs -z3 -d:pserver:email@hidden:/cvsroot/log4cocoa co log4cocoa
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.


References: 
 >Re: Leave NSLog()s in Final Product? - solution (From: Jerry Krinock <email@hidden>)

  • Prev by Date: Re: NSView setHidden vs. setTransparent
  • Next by Date: Applescript questions
  • Previous by thread: Re: Leave NSLog()s in Final Product? - solution
  • Next by thread: RE: Leave NSLog()s in Final Product?
  • Index(es):
    • Date
    • Thread