• 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: How to interrupt a function
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: How to interrupt a function


  • Subject: Re: How to interrupt a function
  • From: Shawn Erickson <email@hidden>
  • Date: Wed, 30 Nov 2005 10:07:41 -0800

On 11/30/05, j o a r <email@hidden> wrote:
>
> On 30 nov 2005, at 17.27, Andrea Salomoni wrote:
>
> > All works fine until (for some problem) the server will go down.
> > if the server is down the method  [socket connectToHostName:host
> > port:port];  returns false, but the GUI is not available (while
> > isn't multithread app and the socket blocking is set on YES.).
>
> But you don't check for the return value of the "connectToHost" method.
> Also, where does the exception come from? When you call methods that
> can throw exceptions, you need to use guards. You simply have to. So,
> open your Cocoa-textbook and read up on that before you continue!

If you don't have a book handy review the following to understand
exceptions and how to handle them...

<http://developer.apple.com/documentation/Cocoa/Conceptual/ObjectiveC/LanguageOverview/chapter_4_section_9.html>

<http://developer.apple.com/documentation/Cocoa/Conceptual/Exceptions/index.html>

-Shawn
 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

References: 
 >How to interrupt a function (From: Andrea Salomoni <email@hidden>)
 >Re: How to interrupt a function (From: Colin Barrett <email@hidden>)
 >Re: How to interrupt a function (From: Andrea Salomoni <email@hidden>)
 >Re: How to interrupt a function (From: j o a r <email@hidden>)
 >Re: How to interrupt a function (From: Andrea Salomoni <email@hidden>)
 >Re: How to interrupt a function (From: j o a r <email@hidden>)

  • Prev by Date: Re: class changes and serialized objects in a nib file
  • Next by Date: Re: NSComboBox Coredata bindings
  • Previous by thread: Re: How to interrupt a function
  • Next by thread: Re: How to interrupt a function
  • Index(es):
    • Date
    • Thread