public OfflinePage(INetworkStatus networkStatus = null) { this.networkStatus = networkStatus ?? new NetworkStatus(); this.InitializeComponent(); NetworkInformation.NetworkStatusChanged += this.OnNetworkStatusChanged; }
/// <summary> /// Initializes a new instance of the <see cref="HttpServiceClient"/> class. /// </summary> /// <param name="messageInvoker">An object used to send server requests.</param> /// <param name="networkStatus">An object that provides the current network status.</param> protected HttpServiceClient(HttpMessageInvoker messageInvoker, INetworkStatus networkStatus) { Throw.IfArgumentNull(messageInvoker, "client"); Throw.IfArgumentNull(networkStatus, "networkStatus"); this.messageInvoker = messageInvoker; this.NetworkStatus = networkStatus; }
public AppUpdater(INetworkStatus network = null, IResourcesHelper resources = null) { this.network = network ?? new NetworkStatus(); this.resources = resources == null ? new ResourcesHelper().GetResourceLoader(ResourceMapIds.Strings) : resources.GetResourceLoader(ResourceMapIds.Strings); this.storeContext = StoreContext.GetDefault(); this.localSettings = ApplicationData.Current.LocalSettings; }
internal static void RegisterNetworkStatusProvider(INetworkStatus networkStatus) { _addtionalNetworkStatusProviders.Add(networkStatus); }
/// <summary> /// Initializes a new instance of the <see cref="HttpResourceDownloader"/> class. /// </summary> /// <param name="messageInvoker">An object used to send server requests.</param> /// <param name="networkStatus">An object that provides the current network status.</param> public HttpResourceDownloader(HttpMessageInvoker messageInvoker, INetworkStatus networkStatus) : base(messageInvoker, networkStatus) { }
/** * Set the delegate implementation. * * @param _delegate The delegate implementing platform specific functions. */ public void SetDelegate(INetworkStatus _delegate) { this._delegate = _delegate; }
/** * Constructor with delegate. * * @param _delegate The delegate implementing platform specific functions. */ public NetworkStatusBridge(INetworkStatus _delegate) : base() { this._delegate = _delegate; }