org.cef.handler.CefRequestHandlerAdapter Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of java-cef2 Show documentation
Show all versions of java-cef2 Show documentation
java-org.cef 2 maven support by gopriaj
The newest version!
// Copyright (c) 2014 The Chromium Embedded Framework Authors. All rights
// reserved. Use of this source code is governed by a BSD-style license that
// can be found in the LICENSE file.
package org.cef.handler;
import org.cef.browser.CefBrowser;
import org.cef.browser.CefFrame;
import org.cef.callback.CefAuthCallback;
import org.cef.callback.CefRequestCallback;
import org.cef.misc.BoolRef;
import org.cef.misc.StringRef;
import org.cef.network.CefRequest;
import org.cef.network.CefResponse;
import org.cef.network.CefURLRequest;
import org.cef.handler.CefLoadHandler.ErrorCode;
/**
* An abstract adapter class for receiving browser request events.
* The methods in this class are empty.
* This class exists as convenience for creating handler objects.
*/
public abstract class CefRequestHandlerAdapter implements CefRequestHandler {
@Override
public boolean onBeforeBrowse(CefBrowser browser, CefFrame frame, CefRequest request,
boolean user_gesture, boolean is_redirect) {
return false;
}
@Override
public boolean onBeforeResourceLoad(CefBrowser browser, CefFrame frame, CefRequest request) {
return false;
}
@Override
public CefResourceHandler getResourceHandler(
CefBrowser browser, CefFrame frame, CefRequest request) {
return null;
}
@Override
public void onResourceRedirect(CefBrowser browser, CefFrame frame, CefRequest request,
CefResponse response, StringRef new_url) {}
@Override
public boolean onResourceResponse(
CefBrowser browser, CefFrame frame, CefRequest request, CefResponse response) {
return false;
}
@Override
public void onResourceLoadComplete(CefBrowser browser, CefFrame frame, CefRequest request,
CefResponse response, CefURLRequest.Status status, long receivedContentLength) {}
@Override
public boolean getAuthCredentials(CefBrowser browser, CefFrame frame, boolean isProxy,
String host, int port, String realm, String scheme, CefAuthCallback callback) {
return false;
}
@Override
public boolean onQuotaRequest(
CefBrowser browser, String origin_url, long new_size, CefRequestCallback callback) {
return false;
}
@Override
public void onProtocolExecution(CefBrowser browser, String url, BoolRef allow_os_execution) {}
@Override
public boolean onCertificateError(CefBrowser browser, ErrorCode cert_error, String request_url,
CefRequestCallback callback) {
return false;
}
@Override
public void onPluginCrashed(CefBrowser browser, String pluginPath) {}
@Override
public void onRenderProcessTerminated(CefBrowser browser, TerminationStatus status) {}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy