• 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: Is NSStreamEvent a bitfield or not?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Is NSStreamEvent a bitfield or not?


  • Subject: Re: Is NSStreamEvent a bitfield or not?
  • From: Andreas Mayer <email@hidden>
  • Date: Tue, 2 Nov 2010 13:39:37 +0100

Am 01.11.2010 um 23:01 schrieb Sean McBride:

> I'm just playing with NSStream for the first time,

Me too. :)

> If these things can be bitwised ORed, why is all the code out there
> 'switch'ing?  I'm confused.

Good question. My test application seems to work fine with switch statements. Maybe the documentation is incorrect?

The "Stream Programming Guide" says in "Handling Stream Events":

"More importantly, once the stream object has been opened, it keeps sending stream:handleEvent: messages to its delegate until it encounters the end of the stream. These messages include a parameter with an NSStreamEvent constant that indicates the type of event."

This seems to indicate that only a single constant value is passed, instead of a bit field.


Andreas_______________________________________________

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: 
 >Is NSStreamEvent a bitfield or not? (From: "Sean McBride" <email@hidden>)

  • Prev by Date: IKImageView vs sibling views as part of a window's contentView hierarchy
  • Next by Date: Re: Notifications on main thread
  • Previous by thread: Is NSStreamEvent a bitfield or not?
  • Next by thread: Unhidable App
  • Index(es):
    • Date
    • Thread