if (zip.getEntry(IWorkPackageParser.IWORK_COMMON_ENTRY) != null) {
// Locate the appropriate index file entry, and reads from that
// the root element of the document. That is used to the identify
// the correct type of the keynote container.
for (String entryName : IWorkPackageParser.IWORK_CONTENT_ENTRIES) {
IWORKDocumentType type = IWORKDocumentType.detectType(zip.getEntry(entryName), zip);
if (type != null) {
return type.getType();
}
}
// Not sure, fallback to the container type
return MediaType.application("vnd.apple.iwork");