Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(206)

Unified Diff: components/cronet/ios/Cronet.h

Issue 1858483002: Cronet for iOS with C API for GRPC support. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@small
Patch Set: Address comments, bundle libboringssl.a into libcronet.a Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « components/cronet.gypi ('k') | components/cronet/ios/Cronet.mm » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/cronet/ios/Cronet.h
diff --git a/components/cronet/ios/Cronet.h b/components/cronet/ios/Cronet.h
new file mode 100644
index 0000000000000000000000000000000000000000..fd3f500033a04354a9839898a6bc12581ad5a637
--- /dev/null
+++ b/components/cronet/ios/Cronet.h
@@ -0,0 +1,55 @@
+// Copyright 2016 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#import <Foundation/Foundation.h>
+
+#include "cronet_c_for_grpc.h"
+
+// Interface for installing Cronet.
+@interface Cronet : NSObject
+
+// Sets whether HTTP/2 should be supported by CronetEngine. This method only has
+// any effect before |start| is called.
++ (void)setHttp2Enabled:(BOOL)http2Enabled;
+
+// Sets whether QUIC should be supported by CronetEngine. This method only has
+// any effect before |start| is called.
++ (void)setQuicEnabled:(BOOL)quicEnabled;
+
+// Adds hint that host supports QUIC on altPort. This method only has any effect
+// before |start| is called.
++ (void)addQuicHint:(NSString*)host port:(int)port altPort:(int)altPort;
+
+// |userAgent| is expected to be of the form Product/Version.
+// Example: Foo/3.0.0.0
+//
+// This method only has any effect before |start| is called.
++ (void)setPartialUserAgent:(NSString*)userAgent;
+
+// Sets SSLKEYLogFileName to export SSL key for Wireshark decryption of packet
+// captures. This method only has any effect before |start| is called.
++ (void)setSslKeyLogFileName:(NSString*)sslKeyLogFileName;
+
+// Starts CronetEngine.
++ (void)start;
+
+// Starts net-internals logging to a file named |fileName| in the application
+// temporary directory. |fileName| must not be empty. Log level is determined
+// by |logBytes| - if YES then LOG_ALL otherwise LOG_ALL_BUT_BYTES. If the file
+// exists it is truncated before starting. If actively logging the call is
+// ignored.
++ (void)startNetLogToFile:(NSString*)fileName logBytes:(BOOL)logBytes;
+
+// Stop net-internals logging and flush file to disk. If a logging session is
+// not in progress this call is ignored.
++ (void)stopNetLog;
+
+// Returns the full user-agent that the stack uses.
+// This is the exact string servers will see.
++ (NSString*)getUserAgent;
+
+// Get a pointer to global instance of cronet_engine for GRPC C API.
++ (cronet_engine*)getGlobalEngine;
+
+@end
« no previous file with comments | « components/cronet.gypi ('k') | components/cronet/ios/Cronet.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698