| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2010 Apple Inc. All Rights Reserved. | 2 * Copyright (C) 2010 Apple 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 Loading... |
| 29 | 29 |
| 30 #include "platform/PlatformExport.h" | 30 #include "platform/PlatformExport.h" |
| 31 #include "wtf/Allocator.h" | 31 #include "wtf/Allocator.h" |
| 32 #include "wtf/HashMap.h" | 32 #include "wtf/HashMap.h" |
| 33 #include "wtf/HashSet.h" | 33 #include "wtf/HashSet.h" |
| 34 #include "wtf/text/StringHash.h" | 34 #include "wtf/text/StringHash.h" |
| 35 #include "wtf/text/WTFString.h" | 35 #include "wtf/text/WTFString.h" |
| 36 | 36 |
| 37 namespace blink { | 37 namespace blink { |
| 38 | 38 |
| 39 using URLSchemesSet = HashSet<String, CaseFoldingHash>; | 39 using URLSchemesSet = HashSet<String>; |
| 40 | 40 |
| 41 template <typename T> | 41 template <typename T> |
| 42 using URLSchemesMap = HashMap<String, T, CaseFoldingHash>; | 42 using URLSchemesMap = HashMap<String, T>; |
| 43 | 43 |
| 44 class PLATFORM_EXPORT SchemeRegistry { | 44 class PLATFORM_EXPORT SchemeRegistry { |
| 45 STATIC_ONLY(SchemeRegistry); | 45 STATIC_ONLY(SchemeRegistry); |
| 46 | 46 |
| 47 public: | 47 public: |
| 48 static void initialize(); | 48 static void initialize(); |
| 49 | 49 |
| 50 static void registerURLSchemeAsLocal(const String&); | 50 static void registerURLSchemeAsLocal(const String&); |
| 51 static bool shouldTreatURLSchemeAsLocal(const String&); | 51 static bool shouldTreatURLSchemeAsLocal(const String&); |
| 52 | 52 |
| (...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 142 const String& scheme); | 142 const String& scheme); |
| 143 static bool schemeShouldBypassSecureContextCheck(const String& scheme); | 143 static bool schemeShouldBypassSecureContextCheck(const String& scheme); |
| 144 | 144 |
| 145 private: | 145 private: |
| 146 static const URLSchemesSet& localSchemes(); | 146 static const URLSchemesSet& localSchemes(); |
| 147 }; | 147 }; |
| 148 | 148 |
| 149 } // namespace blink | 149 } // namespace blink |
| 150 | 150 |
| 151 #endif // SchemeRegistry_h | 151 #endif // SchemeRegistry_h |
| OLD | NEW |