/// <summary> /// Initializes a new instance of the <see cref="DownloadThread"/> class. /// </summary> /// <param name="info"> /// The info. /// </param> /// <param name="service"> /// The service. /// </param> /// <param name="notification"> /// The notification. /// </param> internal DownloadThread(DownloadInfo info, DownloaderService service, DownloadNotification notification) { this.context = service; this.downloadInfo = info; this.downloaderService = service; this.downloadNotification = notification; this.UserAgent = string.Format("APKXDL (Linux; U; Android {0};{1}; {2}/{3}){4}", Build.VERSION.Release, System.Threading.Thread.CurrentThread.CurrentCulture.Name, Build.Device, Build.Id, this.downloaderService.PackageName); }
/// <summary> /// Initializes a new instance of the <see cref="LvlRunnable"/> class. /// </summary> /// <param name="context"> /// The context. /// </param> /// <param name="intent"> /// The intent. /// </param> internal LvlRunnable(DownloaderService context, PendingIntent intent) { Debug.WriteLine("DownloaderService.LvlRunnable.ctor"); this.context = context; this.context.pPendingIntent = intent; }
/// <summary> /// Initializes a new instance of the <see cref="InnerBroadcastReceiver"/> class. /// </summary> /// <param name="service"> /// The service. /// </param> internal InnerBroadcastReceiver(DownloaderService service) { this.service = service; }
/// <summary> /// Updates the LVL information from the server. /// </summary> /// <param name="context"> /// </param> private void UpdateLvl(DownloaderService context) { var h = new Handler(context.MainLooper); h.Post(new LvlRunnable(context, this.pPendingIntent)); }
/// <summary> /// Initializes a new instance of the <see cref="State"/> class. /// </summary> /// <param name="info"> /// The info. /// </param> /// <param name="service"> /// The service. /// </param> public State(DownloadInfo info, DownloaderService service) { this.RedirectCount = info.RedirectCount; this.RequestUri = info.Uri; this.Filename = service.GenerateTempSaveFileName(info.FileName); }