• 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: Timing is everything [Was: Re: Yosemite decimal number conversion error]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Timing is everything [Was: Re: Yosemite decimal number conversion error]


  • Subject: Re: Timing is everything [Was: Re: Yosemite decimal number conversion error]
  • From: Takaaki Naganoya <email@hidden>
  • Date: Thu, 30 Oct 2014 19:43:11 +0900

Thank you, Shane!
This will be a good friend for benchmarks.

--
Takaaki Naganoya
email@hidden
http://piyocast.com/as/

> 2014/10/29 15:33、Shane Stanley <email@hidden> のメール:
>
> Looking at Takaaki Naganoya's Web site reminded me of a neat hint to do with timing scripts. Typically people do things like:
>
> set a1Dat to current date
> -- do stuff
> set b1Dat to current date
> set c1Dat to b1Dat - a1Dat
>
> for rough timings. That's fine, but sometimes you want better than to the nearest second.
>
> In Yosemite, you can include a 'use framework "Foundation"' statement and then use:
>
> set a1Dat to current application's NSDate's timeIntervalSinceReferenceDate()
> -- do stuff
> set b1Dat to current application's NSDate's timeIntervalSinceReferenceDate()
> set c1Dat to b1Dat - a1Dat
>
> Not only are the commands themselves a bit quicker, but the result includes fractions of a second.
>
> --
> Shane Stanley <email@hidden>
> <www.macosxautomation.com/applescript/apps/>
>
> _______________________________________________
> Do not post admin requests to the list. They will be ignored.
> AppleScript-Users mailing list      (email@hidden)
> Help/Unsubscribe/Update your Subscription:
> Archives: http://lists.apple.com/archives/applescript-users
>
> This email sent to email@hidden





 _______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users

This email sent to email@hidden


References: 
 >Yosemite decimal number conversion error (From: Takaaki Naganoya <email@hidden>)
 >Re: Yosemite decimal number conversion error (From: Shane Stanley <email@hidden>)
 >Re: Yosemite decimal number conversion error (From: Takaaki Naganoya <email@hidden>)
 >Timing is everything [Was: Re: Yosemite decimal number conversion error] (From: Shane Stanley <email@hidden>)

  • Prev by Date: Re: Create link in OSX Mail
  • Next by Date: Re: Create link in OSX Mail
  • Previous by thread: Timing is everything [Was: Re: Yosemite decimal number conversion error]
  • Next by thread: Re: Yosemite shell script
  • Index(es):
    • Date
    • Thread