Categorygithub.com/sagernet/cronet-go
modulepackage
0.0.0-20220816045649-24139c8f10b0
Repository: https://github.com/sagernet/cronet-go.git
Documentation: pkg.go.dev

# README

cronet-go

Cronet is the Chromium network stack made available to Android apps as a library. Cronet takes advantage of multiple technologies that reduce the latency and increase the throughput of the network requests that your app needs to work.

The Cronet Library handles the requests of apps used by millions of people on a daily basis, such as YouTube, Google App, Google Photos, and Maps - Navigation & Transit.

This experimental project ported Cronet to golang with NaiveProxy support. To learn how to use the Cronet Library in your app, see the transport and naive-go example.

# Packages

No description provided by the author
No description provided by the author

# Functions

No description provided by the author

# Constants

ResultIllegalArgument Illegal argument.
ResultIllegalArgumentInvalidHostname Host name is invalid.
ResultIllegalArgumentInvalidHttpHeader Invalid http header.
ResultIllegalArgumentInvalidHttpMethod Invalid http method.
ResultIllegalArgumentInvalidPin Public key pin is invalid.
ResultIllegalArgumentStoragePathMustExist Storage path must be set to existing directory.
ResultIllegalState Illegal state.
ResultIllegalStateCannotShutdownEngineFromNetworkThread Cannot shutdown engine from network thread.
ResultIllegalStateEngineAlreadyStarted The engine has already started.
ResultIllegalStateReadFailed Unexpected read failure.
ResultIllegalStateRequestAlreadyInitialized The request is already initialized.
ResultIllegalStateRequestAlreadyStarted The request has already started.
ResultIllegalStateRequestNotInitialized The request is not initialized.
ResultIllegalStateRequestNotStarted The request is not started.
ResultIllegalStateStoragePathInUse Storage path is used by another engine.
ResultIllegalStateUnexpectedRead Unexpected read attempt.
ResultIllegalStateUnexpectedRedirect No redirect to follow.
ResultNullPointer Null pointer or empty data.
ResultNullPointerCallback Callback is required.
ResultNullPointerEngine Engine is required.
ResultNullPointerExecutor Executor is required.
ResultNullPointerExpirationDate The pin expiration date cannot be null.
ResultNullPointerHeaderName Invalid header name.
ResultNullPointerHeaderValue Invalid header value.
ResultNullPointerHostname The hostname cannot be null.
ResultNullPointerMethod Method is required.
ResultNullPointerParams Params is required.
ResultNullPointerRequestFinishedInfoListenerExecutor Executor for RequestFinishedInfoListener is required.
ResultNullPointerSha256Pins The set of SHA256 pins cannot be null.
ResultNullPointerURL URL is required.
ResultSuccess Operation completed successfully.

# Structs

BidirectionalConn is a wrapper from BidirectionalStream to net.Conn.
No description provided by the author
RoundTripper is a wrapper from URLRequest to http.RoundTripper.

# Type aliases

Result is runtime result code returned by Engine and URLRequest.