• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 // Copyright (c) 2022 The Chromium Embedded Framework Authors. All rights
2 // reserved. Use of this source code is governed by a BSD-style license that
3 // can be found in the LICENSE file.
4 //
5 // ---------------------------------------------------------------------------
6 //
7 // This file was generated by the CEF translator tool. If making changes by
8 // hand only do so within the body of existing method and function
9 // implementations. See the translator.README.txt file in the tools directory
10 // for more information.
11 //
12 // $hash=252841f4863d24030d5b42fd34179cfe23ac84c4$
13 //
14 
15 #include "libcef_dll/ctocpp/cookie_visitor_ctocpp.h"
16 #include "libcef_dll/shutdown_checker.h"
17 
18 // VIRTUAL METHODS - Body may be edited by hand.
19 
20 NO_SANITIZE("cfi-icall")
Visit(const CefCookie & cookie,int count,int total,bool & deleteCookie)21 bool CefCookieVisitorCToCpp::Visit(const CefCookie& cookie,
22                                    int count,
23                                    int total,
24                                    bool& deleteCookie) {
25   shutdown_checker::AssertNotShutdown();
26 
27   cef_cookie_visitor_t* _struct = GetStruct();
28   if (CEF_MEMBER_MISSING(_struct, visit))
29     return false;
30 
31   // AUTO-GENERATED CONTENT - DELETE THIS COMMENT BEFORE MODIFYING
32 
33   // Translate param: deleteCookie; type: bool_byref
34   int deleteCookieInt = deleteCookie;
35 
36   // Execute
37   int _retval =
38       _struct->visit(_struct, &cookie, count, total, &deleteCookieInt);
39 
40   // Restore param:deleteCookie; type: bool_byref
41   deleteCookie = deleteCookieInt ? true : false;
42 
43   // Return type: bool
44   return _retval ? true : false;
45 }
46 
47 // CONSTRUCTOR - Do not edit by hand.
48 
CefCookieVisitorCToCpp()49 CefCookieVisitorCToCpp::CefCookieVisitorCToCpp() {}
50 
51 // DESTRUCTOR - Do not edit by hand.
52 
~CefCookieVisitorCToCpp()53 CefCookieVisitorCToCpp::~CefCookieVisitorCToCpp() {
54   shutdown_checker::AssertNotShutdown();
55 }
56 
57 template <>
58 cef_cookie_visitor_t*
59 CefCToCppRefCounted<CefCookieVisitorCToCpp,
60                     CefCookieVisitor,
UnwrapDerived(CefWrapperType type,CefCookieVisitor * c)61                     cef_cookie_visitor_t>::UnwrapDerived(CefWrapperType type,
62                                                          CefCookieVisitor* c) {
63   NOTREACHED() << "Unexpected class type: " << type;
64   return nullptr;
65 }
66 
67 template <>
68 CefWrapperType CefCToCppRefCounted<CefCookieVisitorCToCpp,
69                                    CefCookieVisitor,
70                                    cef_cookie_visitor_t>::kWrapperType =
71     WT_COOKIE_VISITOR;
72