Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: FSGetCatalogInfo returns mod dates in a deprecated data type: UTCDateTime



On Jan 17, 2007, at 6:36 PM, João Varela wrote:

Gary

If the getter API for UTCDateTime is deprecated I guess we can safely assume the data type is also deprecated.

See:

/*
 *  GetUTCDateTime()   *** DEPRECATED ***

[snip]

The utilities you mention are just bridges for us to use the recommended APIs. I know Larry is always warning us how dangerous and evil assumptions are but I guess my assumption is on the safe side. :)

Apple deprecated all of QuickDraw, including data types that are still in use in other places because newer replacement APIs haven't yet been provided. Likewise for UTCDateTime, there are still a number of non-deprecated routines that use the data type, such as UCConvertUTCDateTimeToCFAbsoluteTime, UCConvertCFAbsoluteTimeToUTCDateTime and File Manager routines that work with the FSCatalogInfo structure.

You could always wrap API calls that directly manipulate UTCDateTime values in standalone routines such that the rest of your code always uses CFAbsoluteTime. Then your wrapper routine can be updated over time to handle both the old way (if still relevant) and new way, once a new way is provided.

steve


On 2007/01/18, at 00:29, Gary L. Wade wrote:

It looks like you're assuming that UTCDateTime was deprecated when it was the
functions in UTCUtils.h that were deprecated.  See DateTimeUtils.h for
non-deprecated functions that operate upon UTCDateTime.

Quoting João Varela <email@hidden>:

Hi Chris, Larry

I knew about converting UTCDateTime to CFAbsoluteTime; that was not
the problem, although I do appreciate the fact that you replied to my
question. What I asked was a way to get rid of UTCDateTime data type
completely by using a more modern API than FSGetCatalogInfo, but I
guess the "deafening silence" concerning my question means there is
none at the moment. :)  Therefore I was planning to use the APIs that
Larry suggested, although it's good to know that you can do that
manually if you wish. :) I could file a bug but I guess Apple is
perfectly aware of that problem when they declared UTCDateTime
deprecated in Tiger. The "deafening silence" is quite understandable. :)

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Carbon-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/carbon-dev/email@hidden

This email sent to email@hidden

References: 
 >FSGetCatalogInfo returns mod dates in a deprecated data type: UTCDateTime (From: João Varela <email@hidden>)
 >Re: FSGetCatalogInfo returns mod dates in a deprecated data type: UTCDateTime (From: Chris Newman <email@hidden>)
 >Re: FSGetCatalogInfo returns mod dates in a deprecated data type: UTCDateTime (From: Laurence Harris <email@hidden>)
 >Re: FSGetCatalogInfo returns mod dates in a deprecated data type: UTCDateTime (From: João Varela <email@hidden>)
 >Re: FSGetCatalogInfo returns mod dates in a deprecated data type: UTCDateTime (From: João Varela <email@hidden>)



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.