public interface ProtocolHandler
Modifier and Type | Method and Description |
---|---|
URLResponse |
onRequest(URLRequest request)
This method is invoked for each URL request whose protocol equals to the protocol associated with the current
对于协议等于与当前ProtocolHandler实例关联的协议的每个URL请求,将调用此方法。 ProtocolHandler instance.
|
URLResponse onRequest(URLRequest request)
ProtocolHandler
instance.
If the method throws an exception, it will be treated as if the method returns null
- Chromium engine will handle request.
request
- provides information about URL request.
-提供有关URL请求的信息。
URLResponse
instance if the request is handled, or
null
if the given request must be handled by Chromium engine.
例如,如果请求已处理,或者给定的请求必须由Chromium引擎处理。