• 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: Seconds since system startup
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Seconds since system startup


  • Subject: Re: Seconds since system startup
  • From: Jean-Daniel Dupas <email@hidden>
  • Date: Tue, 24 Jun 2008 15:07:05 +0200

Wow, that one of the more complexe way i see to retreive it.

The former equivalent of GetCurrentEventTime() is -[NSEvent timestamp].

But if you need the uptime without using an event, you can use mach_absolute_time() or UpTime() (from the CoreServices framework).


Le 24 juin 08 à 15:00, Chris a écrit :



Do a

man 3 sysctl

in the terminal and look for KERN_BOOTTIME






On 24/06/2008, at 10:51 PM, Stefan Hafeneger wrote:

Hi,

I'm looking for a Cocoa function like GetCurrentEventTime() for Carbon to get the interval since system startup. Any ideas?

With best wishes, Stefan_______________________________________________

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


Attachment: smime.p7s
Description: S/MIME cryptographic signature

_______________________________________________

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

  • Follow-Ups:
    • Re: Seconds since system startup
      • From: Jean-Daniel Dupas <email@hidden>
References: 
 >Seconds since system startup (From: Stefan Hafeneger <email@hidden>)
 >Re: Seconds since system startup (From: Chris <email@hidden>)

  • Prev by Date: Re: NSPredicateEditorRowTemplate
  • Next by Date: Re: Seconds since system startup
  • Previous by thread: Re: Seconds since system startup
  • Next by thread: Re: Seconds since system startup
  • Index(es):
    • Date
    • Thread