2017-01-11 00:00:30 +01:00
|
|
|
// Copyright (c) 2017 The Chromium Embedded Framework Authors. All rights
|
2016-09-02 12:01:33 +02:00
|
|
|
// reserved. Use of this source code is governed by a BSD-style license that
|
|
|
|
// can be found in the LICENSE file.
|
|
|
|
//
|
|
|
|
// ---------------------------------------------------------------------------
|
|
|
|
//
|
|
|
|
// This file was generated by the CEF translator tool. If making changes by
|
|
|
|
// hand only do so within the body of existing method and function
|
|
|
|
// implementations. See the translator.README.txt file in the tools directory
|
|
|
|
// for more information.
|
|
|
|
//
|
2017-07-27 01:19:27 +02:00
|
|
|
// $hash=bddcbd095ff5e3b5f0fd2c4e5a52a2574a4fcd4f$
|
2017-05-17 11:29:28 +02:00
|
|
|
//
|
2016-09-02 12:01:33 +02:00
|
|
|
|
|
|
|
#include "libcef_dll/cpptoc/sslstatus_cpptoc.h"
|
|
|
|
#include "libcef_dll/cpptoc/x509certificate_cpptoc.h"
|
|
|
|
|
|
|
|
namespace {
|
|
|
|
|
|
|
|
// MEMBER FUNCTIONS - Body may be edited by hand.
|
|
|
|
|
|
|
|
int CEF_CALLBACK sslstatus_is_secure_connection(struct _cef_sslstatus_t* self) {
|
|
|
|
// AUTO-GENERATED CONTENT - DELETE THIS COMMENT BEFORE MODIFYING
|
|
|
|
|
|
|
|
DCHECK(self);
|
|
|
|
if (!self)
|
|
|
|
return 0;
|
|
|
|
|
|
|
|
// Execute
|
|
|
|
bool _retval = CefSSLStatusCppToC::Get(self)->IsSecureConnection();
|
|
|
|
|
|
|
|
// Return type: bool
|
|
|
|
return _retval;
|
|
|
|
}
|
|
|
|
|
2017-05-17 11:29:28 +02:00
|
|
|
cef_cert_status_t CEF_CALLBACK
|
|
|
|
sslstatus_get_cert_status(struct _cef_sslstatus_t* self) {
|
2016-09-02 12:01:33 +02:00
|
|
|
// AUTO-GENERATED CONTENT - DELETE THIS COMMENT BEFORE MODIFYING
|
|
|
|
|
|
|
|
DCHECK(self);
|
|
|
|
if (!self)
|
|
|
|
return CERT_STATUS_NONE;
|
|
|
|
|
|
|
|
// Execute
|
|
|
|
cef_cert_status_t _retval = CefSSLStatusCppToC::Get(self)->GetCertStatus();
|
|
|
|
|
|
|
|
// Return type: simple
|
|
|
|
return _retval;
|
|
|
|
}
|
|
|
|
|
2017-05-17 11:29:28 +02:00
|
|
|
cef_ssl_version_t CEF_CALLBACK
|
|
|
|
sslstatus_get_sslversion(struct _cef_sslstatus_t* self) {
|
2016-09-02 12:01:33 +02:00
|
|
|
// AUTO-GENERATED CONTENT - DELETE THIS COMMENT BEFORE MODIFYING
|
|
|
|
|
|
|
|
DCHECK(self);
|
|
|
|
if (!self)
|
|
|
|
return SSL_CONNECTION_VERSION_UNKNOWN;
|
|
|
|
|
|
|
|
// Execute
|
|
|
|
cef_ssl_version_t _retval = CefSSLStatusCppToC::Get(self)->GetSSLVersion();
|
|
|
|
|
|
|
|
// Return type: simple
|
|
|
|
return _retval;
|
|
|
|
}
|
|
|
|
|
2017-05-17 11:29:28 +02:00
|
|
|
cef_ssl_content_status_t CEF_CALLBACK
|
|
|
|
sslstatus_get_content_status(struct _cef_sslstatus_t* self) {
|
2016-09-02 12:01:33 +02:00
|
|
|
// AUTO-GENERATED CONTENT - DELETE THIS COMMENT BEFORE MODIFYING
|
|
|
|
|
|
|
|
DCHECK(self);
|
|
|
|
if (!self)
|
|
|
|
return SSL_CONTENT_NORMAL_CONTENT;
|
|
|
|
|
|
|
|
// Execute
|
2017-05-17 11:29:28 +02:00
|
|
|
cef_ssl_content_status_t _retval =
|
|
|
|
CefSSLStatusCppToC::Get(self)->GetContentStatus();
|
2016-09-02 12:01:33 +02:00
|
|
|
|
|
|
|
// Return type: simple
|
|
|
|
return _retval;
|
|
|
|
}
|
|
|
|
|
2017-05-17 11:29:28 +02:00
|
|
|
struct _cef_x509certificate_t* CEF_CALLBACK
|
|
|
|
sslstatus_get_x509certificate(struct _cef_sslstatus_t* self) {
|
2016-09-02 12:01:33 +02:00
|
|
|
// AUTO-GENERATED CONTENT - DELETE THIS COMMENT BEFORE MODIFYING
|
|
|
|
|
|
|
|
DCHECK(self);
|
|
|
|
if (!self)
|
|
|
|
return NULL;
|
|
|
|
|
|
|
|
// Execute
|
2017-05-17 11:29:28 +02:00
|
|
|
CefRefPtr<CefX509Certificate> _retval =
|
|
|
|
CefSSLStatusCppToC::Get(self)->GetX509Certificate();
|
2016-09-02 12:01:33 +02:00
|
|
|
|
|
|
|
// Return type: refptr_same
|
|
|
|
return CefX509CertificateCppToC::Wrap(_retval);
|
|
|
|
}
|
|
|
|
|
|
|
|
} // namespace
|
|
|
|
|
|
|
|
// CONSTRUCTOR - Do not edit by hand.
|
|
|
|
|
|
|
|
CefSSLStatusCppToC::CefSSLStatusCppToC() {
|
|
|
|
GetStruct()->is_secure_connection = sslstatus_is_secure_connection;
|
|
|
|
GetStruct()->get_cert_status = sslstatus_get_cert_status;
|
|
|
|
GetStruct()->get_sslversion = sslstatus_get_sslversion;
|
|
|
|
GetStruct()->get_content_status = sslstatus_get_content_status;
|
|
|
|
GetStruct()->get_x509certificate = sslstatus_get_x509certificate;
|
|
|
|
}
|
|
|
|
|
2017-05-17 11:29:28 +02:00
|
|
|
template <>
|
|
|
|
CefRefPtr<CefSSLStatus>
|
|
|
|
CefCppToCRefCounted<CefSSLStatusCppToC, CefSSLStatus, cef_sslstatus_t>::
|
|
|
|
UnwrapDerived(CefWrapperType type, cef_sslstatus_t* s) {
|
2016-09-02 12:01:33 +02:00
|
|
|
NOTREACHED() << "Unexpected class type: " << type;
|
|
|
|
return NULL;
|
|
|
|
}
|
|
|
|
|
|
|
|
#if DCHECK_IS_ON()
|
2017-05-17 11:29:28 +02:00
|
|
|
template <>
|
2017-07-27 01:19:27 +02:00
|
|
|
base::AtomicRefCount
|
|
|
|
CefCppToCRefCounted<CefSSLStatusCppToC, CefSSLStatus, cef_sslstatus_t>::
|
|
|
|
DebugObjCt ATOMIC_DECLARATION;
|
2016-09-02 12:01:33 +02:00
|
|
|
#endif
|
|
|
|
|
2017-05-17 11:29:28 +02:00
|
|
|
template <>
|
|
|
|
CefWrapperType CefCppToCRefCounted<CefSSLStatusCppToC,
|
|
|
|
CefSSLStatus,
|
|
|
|
cef_sslstatus_t>::kWrapperType =
|
|
|
|
WT_SSLSTATUS;
|