Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(403)

Side by Side Diff: Source/WebCore/platform/MIMETypeRegistry.h

Issue 7356002: Merge 90308 (Closed) Base URL: http://svn.webkit.org/repository/webkit/branches/chromium/782/
Patch Set: Created 9 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « Source/WebCore/fileapi/File.cpp ('k') | Source/WebCore/platform/MIMETypeRegistry.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2006 Apple Computer, Inc. All rights reserved. 2 * Copyright (C) 2006 Apple Computer, Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 1. Redistributions of source code must retain the above copyright 7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer. 8 * notice, this list of conditions and the following disclaimer.
9 * 2. Redistributions in binary form must reproduce the above copyright 9 * 2. Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the 10 * notice, this list of conditions and the following disclaimer in the
(...skipping 18 matching lines...) Expand all
29 #include "PlatformString.h" 29 #include "PlatformString.h"
30 #include <wtf/HashSet.h> 30 #include <wtf/HashSet.h>
31 #include <wtf/Vector.h> 31 #include <wtf/Vector.h>
32 #include <wtf/text/StringHash.h> 32 #include <wtf/text/StringHash.h>
33 33
34 namespace WebCore { 34 namespace WebCore {
35 35
36 class MIMETypeRegistry { 36 class MIMETypeRegistry {
37 public: 37 public:
38 static String getMIMETypeForExtension(const String& extension); 38 static String getMIMETypeForExtension(const String& extension);
39 #if ENABLE(FILE_SYSTEM) && ENABLE(WORKERS) 39 #if ENABLE(FILE_SYSTEM)
40 static String getMIMETypeForExtensionThreadSafe(const String& extension); 40 static String getWellKnownMIMETypeForExtension(const String& extension);
41 #endif 41 #endif
42
42 static Vector<String> getExtensionsForMIMEType(const String& type); 43 static Vector<String> getExtensionsForMIMEType(const String& type);
43 static String getPreferredExtensionForMIMEType(const String& type); 44 static String getPreferredExtensionForMIMEType(const String& type);
44 static String getMediaMIMETypeForExtension(const String& extension); 45 static String getMediaMIMETypeForExtension(const String& extension);
45 static Vector<String> getMediaMIMETypesForExtension(const String& extension) ; 46 static Vector<String> getMediaMIMETypesForExtension(const String& extension) ;
46 47
47 static String getMIMETypeForPath(const String& path); 48 static String getMIMETypeForPath(const String& path);
48 49
49 // Check to see if a mime type is suitable for being loaded inline as an 50 // Check to see if a mime type is suitable for being loaded inline as an
50 // image (e.g., <img> tags). 51 // image (e.g., <img> tags).
51 static bool isSupportedImageMIMEType(const String& mimeType); 52 static bool isSupportedImageMIMEType(const String& mimeType);
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
85 static HashSet<String>& getSupportedNonImageMIMETypes(); 86 static HashSet<String>& getSupportedNonImageMIMETypes();
86 static HashSet<String>& getSupportedMediaMIMETypes(); 87 static HashSet<String>& getSupportedMediaMIMETypes();
87 static HashSet<String>& getUnsupportedTextMIMETypes(); 88 static HashSet<String>& getUnsupportedTextMIMETypes();
88 }; 89 };
89 90
90 const String& defaultMIMEType(); 91 const String& defaultMIMEType();
91 92
92 } // namespace WebCore 93 } // namespace WebCore
93 94
94 #endif // MIMETypeRegistry_h 95 #endif // MIMETypeRegistry_h
OLDNEW
« no previous file with comments | « Source/WebCore/fileapi/File.cpp ('k') | Source/WebCore/platform/MIMETypeRegistry.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698