advertisement

Article:
  Creating Spotlight Plugins
Subject:   com.apple.ostype = T78q ?
Date:   2005-07-18 12:39:01
From:   ptwobrussell
Response to: com.apple.ostype = T78q ?

That line wasn't highlighted because I didn't think it was all that interesting at the time -- but perhaps it should have been highlighted.


If you take a look at Table 3-2 from Apple's document Understanding UTIs (http://developer.apple.com/documentation/Carbon/Conceptual/understanding_utis/understanding_utis.pdf) , you'll see that ostype is of type OSType. From Wikipedia, you can find a brief summary of OSType here (http://en.wikipedia.org/wiki/OSType) .


To your question "should all importers be set to this ostype" -- No. The 4 character code of type OSType should correspond to the UTI/file extension in question. In our case, we're associating "T78q" with UTI type "aaa". See here (http://developer.apple.com/documentation/Carbon/Conceptual/understanding_utis/understand_utis_conc/chapter_2_section_4.html) for an example with images.) A hint that this association was occuring is because both of these values are wrapped up in a dictionary in the plist.


The "T78q" value I used was the same one from the Apple sample code, and I'm assuming it's not really assigned to anything. Perhaps we could/should have named it "stick" and introduced a "formal" 4 digit OSType value that identified documents of UTI type "aaa".


I hope that helps.