Package org.gnome.webkit
Interface WebView.LoadFailedWithTlsErrorsCallback
- All Superinterfaces:
FunctionPointer
- Enclosing class:
WebView
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
@FunctionalInterface
public static interface WebView.LoadFailedWithTlsErrorsCallback
extends FunctionPointer
Functional interface declaration of the
LoadFailedWithTlsErrorsCallback
callback.
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionboolean
run
(String failingUri, TlsCertificate certificate, Set<TlsCertificateFlags> errors) Emitted when a TLS error occurs during a load operation.default MemorySegment
toCallback
(Arena arena) Creates a native function pointer to theupcall(java.lang.foreign.MemorySegment, java.lang.foreign.MemorySegment, java.lang.foreign.MemorySegment, int)
method.default int
upcall
(MemorySegment sourceWebView, MemorySegment failingUri, MemorySegment certificate, int errors) Theupcall
method is called from native code.
-
Method Details
-
run
Emitted when a TLS error occurs during a load operation. To allow an exception for thiscertificate
and the host offailingUri
use webkit_web_context_allow_tls_certificate_for_host().To handle this signal asynchronously you should call g_object_ref() on
certificate
and returntrue
.If
false
is returned,WebKitWebView
::load-failed will be emitted. The load will finish regardless of the returned value. -
upcall
default int upcall(MemorySegment sourceWebView, MemorySegment failingUri, MemorySegment certificate, int errors) Theupcall
method is called from native code. The parameters are marshaled andrun(java.lang.String, org.gnome.gio.TlsCertificate, java.util.Set<org.gnome.gio.TlsCertificateFlags>)
is executed. -
toCallback
Creates a native function pointer to theupcall(java.lang.foreign.MemorySegment, java.lang.foreign.MemorySegment, java.lang.foreign.MemorySegment, int)
method.- Specified by:
toCallback
in interfaceFunctionPointer
- Parameters:
arena
- the function pointer will be allocated in this arena- Returns:
- the native function pointer
-