• 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: Session terminate
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Session terminate


  • Subject: Re: Session terminate
  • From: Mark Ritchie <email@hidden>
  • Date: Tue, 17 May 2005 12:44:01 -0400

On May 17, 2005, at 12:16 PM, Sébastien Gruhier wrote:
I have overriden the terminate function in Session but how do I know if the call is done by a timeout?

I have an icky way to do this... I'd love to find a cleaner solution if anyone has one.
< mutters something about private ivars and no accessor methods... >


If you print out Session's toString(), you should see something like _wasTimedOut
followed by true or false. (Note that there are spacing issues around _wasTimedOut).
In my implementation of terminate(), I parse the toString() and check the flag.
Did I mention that this was a terrible way to find out if you've been terminated by a
timeout but it works for me. Tested under: WOF 5.2.3, OSX 10.2.8
This is very likely to be effected by version / platform / phase of the moon changes. :-)


Good luck!
Mark.
__
Mark Ritchie, email@hidden 416-843-5479
Software Developer, Apple Certified Developer Trainer
WebObjects, Cocoa, Mac OS X and Mac OS X Server
Diamond Lake Consulting Inc., Toronto, Ontario, Canada

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


  • Follow-Ups:
    • Re: Session terminate
      • From: Pierre Frisch <email@hidden>
References: 
 >Session terminate (From: Sébastien Gruhier <email@hidden>)

  • Prev by Date: Re: bosses who want to research .NET alternatives
  • Next by Date: Threads and HttpsURLConnection underlying shared connection?
  • Previous by thread: Session terminate
  • Next by thread: Re: Session terminate
  • Index(es):
    • Date
    • Thread