• 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
UTI case doesn't matter sometimes?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

UTI case doesn't matter sometimes?


  • Subject: UTI case doesn't matter sometimes?
  • From: Steve Mills <email@hidden>
  • Date: Mon, 13 Apr 2015 14:09:06 -0500

The docs for creating a new app state that UTIs are case-sensitive:

https://developer.apple.com/library/ios/documentation/IDEs/Conceptual/AppDistributionGuide/ConfiguringYourApp/ConfiguringYourApp.html#//apple_ref/doc/uid/TP40012582-CH28-SW8

"However, unlike domain names, bundle IDs are case sensitive. If the App ID is lowercase, your bundle ID needs to be lowercase, too."

My document type UTIs are generated in the Info.plist as:

com.armpitstudios.$(PRODUCT_NAME:rfc1034identifier).chest

And since they're based on the product name, the app name part of the UTI is titlecased:

com.armpitstudios.Image-Chest.chest

This tends to match all of the Apple application UTIs I've looked at. However, I've been seeing my file type UTI come in as lowercase when a document is being reopened on launch, with the fileType coming through these NSDocumentController methods on the stack:

makeDocumentForURL:withContentsOfURL:ofType:error:
reopenDocumentForURL:withContentsOfURL:display:completionHandler:

So, should string comparisons be case-insensitive when comparing UTIs? If not, then things fail.

--
Steve Mills
Drummer, Mac geek


_______________________________________________

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: UTI case doesn't matter sometimes?
      • From: Sean McBride <email@hidden>
  • Prev by Date: Re: NSURLProtocol
  • Next by Date: Re: objc_msgSend() selector name: tableView:objectValueForTableColumn:row:
  • Previous by thread: Re: Crash when move open document based app file to trash
  • Next by thread: Re: UTI case doesn't matter sometimes?
  • Index(es):
    • Date
    • Thread