haiku/headers/private/storage/mime/database_access.h
Tyler Dauwalder e3a2f2069e + Added SetSupportedTypes() test
+ Modified BMimeType::SetSupportedTypes functionality so it keeps track of
stranded types (i.e. previously supported types that have not had the now
unsupporting app signature removed from their supporting apps list yet due
to a false fullSync parameter) over consecutive SetSupportedTypes(...,
false) calls and updates all appropriate stranded types on the next
SetSupportedTypes(..., true) call.
+ Added fullSync parameter to BMimeType::DeleteSupportedTypes
+ Made BMimeType::Delete() do a DeleteSupportedTypes(..., true) call to
properly update the supporting apps lists when a mime type is deleted.
+ Added initial BMimeType::Get/SetSnifferRule
+ Updated BMimeType::CheckSnifferRule() to return B_BAD_VALUE when passed
a NULL rule string.
+ Brought CheckSnifferRule() tests up to date
+ Added lots of Mime::Database doxygen
+ Added any missing mime monitor notifications in Mime::Database
+ Possibly made some other changes as well... :-)


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@1004 a95241bf-73f2-0310-859d-f6bbb57e9c96
2002-09-09 08:12:03 +00:00

47 lines
1.5 KiB
C++

//----------------------------------------------------------------------
// This software is part of the OpenBeOS distribution and is covered
// by the OpenBeOS license.
//---------------------------------------------------------------------
/*!
\file database_access.h
Mime database atomic read function declarations
*/
#ifndef _MIME_DATABASE_ACCESS_H
#define _MIME_DATABASE_ACCESS_H
#include <Mime.h>
class BNode;
class BBitmap;
class BMessage;
namespace BPrivate {
namespace Storage {
namespace Mime {
// Get() functions
status_t get_app_hint(const char *type, entry_ref *ref);
status_t get_attr_info(const char *type, BMessage *info);
status_t get_short_description(const char *type, char *description);
status_t get_long_description(const char *type, char *description);
status_t get_file_extensions(const char *type, BMessage *extensions);
status_t get_icon(const char *type, BBitmap *icon, icon_size size);
status_t get_icon_for_type(const char *type, const char *fileType, BBitmap *icon,
icon_size which);
status_t get_preferred_app(const char *type, char *signature, app_verb verb);
status_t get_sniffer_rule(const char *type, BString *result);
status_t get_supported_types(const char *type, BMessage *types);
bool is_installed(const char *type);
// Called by BMimeType to get properly formatted icon data ready
// to be shipped off to SetIcon*() and written to the database
status_t get_icon_data(const BBitmap *icon, icon_size size, void **data, int32 *dataSize);
} // namespace Mime
} // namespace Storage
} // namespace BPrivate
#endif // _MIME_DATABASE_H