Rosetta
Public Types | Public Member Functions | Private Slots | Private Attributes | List of all members
ui::task::FunctorASyncSequence Class Reference

FunctorASyncSequence: same as FunctorSequence but start excution of all functors at once. More...

#include <functor.h>

Inheritance diagram for ui::task::FunctorASyncSequence:
Inheritance graph
[legend]

Public Types

using ValueType = FunctorSP
 
- Public Types inherited from ui::task::Functor
enum class  State { _none_ , _running_ , _finished_ }
 

Public Member Functions

 FunctorASyncSequence (QString const &name, std::initializer_list< ValueType > sequence)
 
void add_functor (ValueType const &v)
 
std::pair< int, int > progress () const override
 
 Functor (QString const &name, QObject *parent=Q_NULLPTR)
 
- Public Member Functions inherited from ui::task::Functor
 Functor (QString const &name, QObject *parent=Q_NULLPTR)
 
State state () const
 return current state More...
 
bool is_running () const
 return true if Functor is now executing More...
 
bool is_finished () const
 return true if Functor is finished More...
 
QString name () const
 
void execute ()
 

Private Slots

void run () override
 
void item_finished ()
 

Private Attributes

std::vector< ValueTypesequence_
 

Additional Inherited Members

- Public Slots inherited from ui::task::Functor
void finish ()
 change state to finished More...
 
- Signals inherited from ui::task::Functor
void started ()
 indicate start of this Functor, emitted only once More...
 
void tick ()
 Might be emitted periodically if Functor have loops. At least one tick() event is guaranteed to happened between start and finish. More...
 
void finished ()
 indicate end of this Functor execution, emitted only once More...
 
void final ()
 last emitted singal, before Functor consider fully done, emitted only once More...
 
- Protected Member Functions inherited from ui::task::Functor
void state (State state)
 

Detailed Description

FunctorASyncSequence: same as FunctorSequence but start excution of all functors at once.

Member Typedef Documentation

◆ ValueType

Constructor & Destructor Documentation

◆ FunctorASyncSequence()

ui::task::FunctorASyncSequence::FunctorASyncSequence ( QString const &  name,
std::initializer_list< ValueType sequence 
)

Member Function Documentation

◆ add_functor()

void ui::task::FunctorASyncSequence::add_functor ( ValueType const &  v)

◆ Functor()

ui::task::Functor::Functor
inline

◆ item_finished

void ui::task::FunctorASyncSequence::item_finished ( )
privateslot

◆ progress()

std::pair< int, int > ui::task::FunctorASyncSequence::progress ( ) const
overridevirtual

◆ run

void ui::task::FunctorASyncSequence::run ( )
overrideprivateslot

Member Data Documentation

◆ sequence_

std::vector<ValueType> ui::task::FunctorASyncSequence::sequence_
private

The documentation for this class was generated from the following files: