• 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: constructing an NSString with va_list?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: constructing an NSString with va_list?


  • Subject: Re: constructing an NSString with va_list?
  • From: Boyd Collier <email@hidden>
  • Date: Sat, 27 Feb 2010 17:04:43 -0800

Take a look at

http://www.cocoabuilder.com/archive/cocoa/205083-nslog-replacement-for-debugger-output.html

I've been using Don Arnel's method as modified by Ken Thomases and it works very well.

Boyd



On Feb 27, 2010, at 4:02 PM, Rick Mann wrote:

> I'm trying to improve our logging a bit. We have some logging code that calls NSLog(), but that prepends a bunch of fairly useless stuff for our purposes, taking up a significant portion of the line. printf() doesn't, but doesn't understand %@. I'd like to construct a string by passing in a format string and a va_list, but I don't see a constructor for that.
>
> Is there a way to build an NSString with a va_list?
>
> or
>
> Is there a way to get NSLog() to be less verbose?
>
> TIA,
> Rick
>
> _______________________________________________
>
> Cocoa-dev mailing list (email@hidden)
>
> Please do not post admin requests or moderator comments to the list.
> Contact the moderators at cocoa-dev-admins(at)lists.apple.com
>
> Help/Unsubscribe/Update your Subscription:
>
> This email sent to email@hidden
>
>

_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

References: 
 >constructing an NSString with va_list? (From: Rick Mann <email@hidden>)

  • Prev by Date: Re: NSViewAnimation vs Distributed Notification: Bug?
  • Next by Date: Re: UITextView as its own delegate - infinite loop on keyboard select
  • Previous by thread: Re: constructing an NSString with va_list?
  • Next by thread: Where in the MVC should my code go?
  • Index(es):
    • Date
    • Thread