1 // Copyright (c) 2012 The Chromium Embedded Framework Authors. All rights 2 // reserved. Use of this source code is governed by a BSD-style license that can 3 // be found in the LICENSE file. 4 5 #ifndef CEF_LIBCEF_COMMON_SCHEME_REGISTRAR_IMPL_H_ 6 #define CEF_LIBCEF_COMMON_SCHEME_REGISTRAR_IMPL_H_ 7 #pragma once 8 9 #include <string> 10 #include <vector> 11 12 #include "include/cef_scheme.h" 13 14 #include "content/public/common/content_client.h" 15 16 class CefSchemeRegistrarImpl : public CefSchemeRegistrar { 17 public: 18 CefSchemeRegistrarImpl(); 19 20 CefSchemeRegistrarImpl(const CefSchemeRegistrarImpl&) = delete; 21 CefSchemeRegistrarImpl& operator=(const CefSchemeRegistrarImpl&) = delete; 22 23 // CefSchemeRegistrar methods. 24 bool AddCustomScheme(const CefString& scheme_name, int options) override; 25 26 void GetSchemes(content::ContentClient::Schemes* schemes); 27 28 private: 29 content::ContentClient::Schemes schemes_; 30 std::set<std::string> registered_schemes_; 31 }; 32 33 #endif // CEF_LIBCEF_COMMON_SCHEME_REGISTRAR_IMPL_H_ 34