From 5632da3fed09142bbf36b2adc948d7afbe44e2bc Mon Sep 17 00:00:00 2001 From: Jim Evans Date: Tue, 12 Oct 2021 14:59:42 -0400 Subject: [PATCH] [dotnet] Making SlowLoadableComponent more exentsible Fixes issue #9009 --- .../support/UI/SlowLoadableComponent{T}.cs | 21 ++++++++++++++++++- 1 file changed, 20 insertions(+), 1 deletion(-) diff --git a/dotnet/src/support/UI/SlowLoadableComponent{T}.cs b/dotnet/src/support/UI/SlowLoadableComponent{T}.cs index f2c8ca21ca181..1ee0d879eaea3 100644 --- a/dotnet/src/support/UI/SlowLoadableComponent{T}.cs +++ b/dotnet/src/support/UI/SlowLoadableComponent{T}.cs @@ -69,6 +69,22 @@ public TimeSpan SleepInterval set { this.sleepInterval = value; } } + /// + /// Gets the timeout interval before which this component must be considered loaded. + /// + protected TimeSpan Timeout + { + get { return this.timeout; } + } + + /// + /// Gets the clock object providing timing for monitoring the load status of this component. + /// + protected IClock Clock + { + get { return this.clock; } + } + /// /// Ensures that the component is currently loaded. /// @@ -125,7 +141,10 @@ protected virtual void HandleErrors() // no-op by default } - private void Wait() + /// + /// Waits between polls of the load status of this component. + /// + protected virtual void Wait() { Thread.Sleep(this.sleepInterval); }