xtd 0.2.0
progress_changed_event_args.h
Go to the documentation of this file.
1 #pragma once
5 #include <xtd/any>
6 #include <xtd/event_args>
7 #include <cstdint>
8 
10 namespace xtd {
12  namespace forms {
22  public:
25  progress_changed_event_args& operator =(const progress_changed_event_args&) = default;
27 
29 
33  progress_changed_event_args(int32 progress_percentage, const std::any& user_state) : progress_percentage_(progress_percentage), user_state_(user_state) {}
35 
37 
39  int32 progress_percentage() const noexcept {return progress_percentage_;}
40 
43  std::any user_state() const noexcept {return user_state_;}
45 
46  private:
47  int32 progress_percentage_ = 0;
48  std::any user_state_;
49  };
50  }
51 }
Represents the base class for classes that contain event data, and provides a value to use for events...
Definition: event_args.h:18
The xtd namespace contains all fundamental classes to access Hardware, Os, System, and more.
Definition: system_report.h:17
Indicates that all styles except allow_binary_specifier, allow_octal_specifier and allow_hex_specifie...
Provides data for the xtd::forms::background_worker::progress_changed event handler.
Definition: progress_changed_event_args.h:21
int_least32_t int32
Represents a 32-bit signed integer.
Definition: types.h:129
The xtd::forms namespace contains classes for creating Windows-based applications that take full adva...
Definition: about_box.h:13
progress_changed_event_args(int32 progress_percentage, const std::any &user_state)
Initializes a new instance of the DoWorkEventArgs class.
Definition: progress_changed_event_args.h:33
std::any user_state() const noexcept
Gets a value that represents the argument of an asynchronous operation.
Definition: progress_changed_event_args.h:43