1/* MIME Sniffer Add-On Protocol 2 * 3 * Copyright 2006, Haiku Inc. All Rights Reserved. 4 * Distributed under the terms of the MIT License. 5 */ 6#ifndef _MIME_SNIFFER_ADDON_H 7#define _MIME_SNIFFER_ADDON_H 8 9#include <SupportDefs.h> 10 11class BFile; 12class BMimeType; 13 14// ********************************** 15// *** WARNING: EXPERIMENTAL API! *** 16// ********************************** 17 18class BMimeSnifferAddon { 19public: 20 BMimeSnifferAddon(); 21 virtual ~BMimeSnifferAddon(); 22 23 virtual size_t MinimalBufferSize(); 24 25 virtual float GuessMimeType(const char* fileName, 26 BMimeType* type); 27 virtual float GuessMimeType(BFile* file, 28 const void* buffer, int32 length, 29 BMimeType* type); 30}; 31 32#endif // _MIME_SNIFFER_ADDON_H 33