/// <summary>
 /// Convenience method for initializing AppCenter
 /// </summary>
 /// <param name="appleSecret">iOS secret</param>
 /// <param name="androidSecret">Android secret</param>
 /// <param name="anonymizeUser">Set to TRUE to use a 8 character unique key as the UserId</param>
 /// <param name="appCenterSetup">Keep this as NULL to use the default implementation. This is only exposed for unit testing purposes</param>
 public static void Initialize(
     string appleSecret,
     string androidSecret,
     bool anonymizeUser,
     IAppCenterSetup appCenterSetup = null)
 => (appCenterSetup ?? AppCenterSetup.Instance)
 .Start(appleSecret, androidSecret, anonymizeUser);
Exemplo n.º 2
0
 /// <summary>
 /// Creates a new instance of DiagnosticDelegatingHandler
 /// using the default HttpClientHandler as the inner handler
 /// </summary>
 /// <param name="analytics">Keep this as NULL to use the default implementation. This is only exposed for unit testing purposes</param>
 /// <param name="appCenterSetup">Keep this as NULL to use the default implementation. This is only exposed for unit testing purposes</param>
 public DiagnosticDelegatingHandler(
     IAnalytics analytics           = null,
     IAppCenterSetup appCenterSetup = null)
     : base(new HttpClientHandler())
 {
     this.analytics      = analytics ?? new AppCenterAnalytics();
     this.appCenterSetup = appCenterSetup ?? AppCenterSetup.Instance;
 }
Exemplo n.º 3
0
 /// <summary>
 /// Creates a new instance of DiagnosticDelegatingHandler
 /// using the specified HttpMessageHandler as the inner handler
 /// </summary>
 /// <param name="innerHandler">The inner handler responsible for processing HTTP requests</param>
 /// <param name="analytics">Keep this as NULL to use the default implementation. This is only exposed for unit testing purposes</param>
 /// <param name="appCenterSetup">Keep this as NULL to use the default implementation. This is only exposed for unit testing purposes</param>
 public DiagnosticDelegatingHandler(
     HttpMessageHandler innerHandler,
     IAnalytics analytics           = null,
     IAppCenterSetup appCenterSetup = null)
     : base(innerHandler)
 {
     this.analytics      = analytics ?? new AppCenterAnalytics();
     this.appCenterSetup = appCenterSetup ?? AppCenterSetup.Instance;
 }