Important Notice: Our web hosting provider recently started charging us for additional visits, which was unexpected. In response, we're seeking donations. Depending on the situation, we may explore different monetization options for our Community and Expert Contributors. It's crucial to provide more returns for their expertise and offer more Expert Validated Answers or AI Validated Answers. Learn more about our hosting issue here.

How do I implement document packages (documents that are really folders, but appear to be opaque documents)?

0
Posted

How do I implement document packages (documents that are really folders, but appear to be opaque documents)?

0

Usually, an application that wants its documents to be document packages will use the NSFileWrapper class to construct and access its documents. If this is true for some or all of the types that your document class supports, then instead of overriding dataRepresentationOfType: and loadDataRepresentation:ofType:, you should override fileWrapperRepresentationOfType: and loadFileWrapperRepresentation:ofType:. These methods are much the same as the “data” methods, but they use NSFileWrappers instead. You should also specify, in the document types section of your application’s information property list, that documents of the specified type are packages (as described in “Storing Document Types Information in a Property List”).

Related Questions

What is your question?

*Sadly, we had to bring back ads too. Hopefully more targeted.