Lines Matching defs:extension

53 	extension in the pre-allocated \c BMessage pointed to by \c types.
58 AssociatedTypes::GetAssociatedTypes(const char *extension, BMessage *types)
60 status_t err = extension && types ? B_OK : B_BAD_VALUE;
67 // Format the extension
69 extStr = PrepExtension(extension);
77 // Add the types associated with this extension
88 /*! \brief Guesses a MIME type for the given filename based on its extension
119 // Extract the extension from the file
122 // If there was an extension, grab it and look up its associated
126 std::string extension = PrepExtension(rawExtension + 1);
131 std::set<std::string> &types = fAssociatedTypes[extension];
145 /*! \brief Guesses a MIME type for the given \c entry_ref based on its filename extension
199 // for each extension
201 const char *extension;
203 extensions->FindString(kTypesField, i, &extension) == B_OK;
206 newExtensions.insert(extension);
207 AddAssociatedType(extension, type);
277 for the given extension.
279 \param extension The file extension
286 AssociatedTypes::AddAssociatedType(const char *extension, const char *type)
288 status_t err = extension && type ? B_OK : B_BAD_VALUE;
291 extStr = PrepExtension(extension);
301 for the given extension.
303 \param extension The file extension
310 AssociatedTypes::RemoveAssociatedType(const char *extension, const char *type)
312 status_t err = extension && type ? B_OK : B_BAD_VALUE;
315 extStr = PrepExtension(extension);
319 fAssociatedTypes[extension].erase(type);
325 for every associated file extension.
424 // Read in the list of file extension types
429 // to the list of associated types for each file extension
430 const char *extension;
432 for (int i = 0; msg.FindString(kExtensionsField, i, &extension) == B_OK; i++) {
433 std::string extStr = PrepExtension(extension);
445 /*! \brief Strips any leading '.' chars from the given extension and
449 AssociatedTypes::PrepExtension(const char *extension) const
451 if (extension) {
453 while (extension[i] == '.')
455 return BPrivate::Storage::to_lower(&(extension[i]));
458 // empty string is considered an invalid extension