Progressive C # with -1 part of the team template

I need to implement progressbar in EXT.NET. I have a Process command, as in transaction processing. I have to keep track of the total number of transactions and transactions that failed and succeeded. For instance. “A total of 60 transactions. 12 failed and 48 failed.”)

Now my question is: can I use the command template to implement it? I am not asking for the code, but I want to know if it makes sense.

The reason for this is that I have to implement some design patterns for assignment.

( http://en.wikipedia.org/wiki/Command_pattern one of the applications is progressbar)

PS:

If anyone has an example of a progress bar implemented using a command template, feel free to post: P

+5
source share
1 answer

The clip is here:

Progress bars Assume that a program has a sequence of commands that it executes in order. If each command object has a getEstimatedDuration () method, the program can easily estimate the total duration. It can display a progress bar that intelligently reflects how complete the program is for all the tasks.

If you look at this:

enter image description here

The caller may have a sequence of commands to execute. Each command object has getEstimatedDuration (), which knows approximately how long it takes. Thus, each time the command is executed, you can update the progress panel with the return value getEstimatedDuration ().

0
source

All Articles