xtd 0.2.0
Loading...
Searching...
No Matches

◆ on_completed()

template<typename type_t >
virtual void xtd::iobserver< type_t >::on_completed ( )
pure virtualnoexcept

Notifies the observer that the provider has finished sending push-based notifications.

Examples
The following example provides an implementation of the OnCompleted method in a latitude/longitude tracking application. The method simply reports that no further data is available and calls the provider's IDisposable.Dispose implementation. See the Example section of the IObserver<T> topic for the complete example.
void on_completed() noexcept override {
console::write_line("The location Tracker has completed transmitting data to {}.", name());
unsubscribe();
}
static void write_line()
Writes the current line terminator to the standard output stream using the specified format informati...
virtual void on_completed() noexcept=0
Notifies the observer that the provider has finished sending push-based notifications.