QWT API (English) 7.0.1
Qt Widget Library for Technical Applications - English API Documentation
Loading...
Searching...
No Matches
Classes | Public Slots | Public Member Functions | Protected Member Functions | List of all members
QwtSamplingThread Class Referenceabstract

A thread collecting samples at regular intervals. More...

#include <qwt_sampling_thread.h>

Inheritance diagram for QwtSamplingThread:

Classes

class  PrivateData
 

Public Slots

void setInterval (double interval)
 Change the interval (in ms), when sample() is called.
 
void stop ()
 Terminate the collecting thread.
 

Public Member Functions

virtual ~QwtSamplingThread ()
 Destructor .
 
double interval () const
 Get the interval (in ms), between 2 calls of sample()
 
double elapsed () const
 Get the time (in ms) since the thread was started.
 

Protected Member Functions

 QwtSamplingThread (QObject *parent=nullptr)
 Constructor.
 
virtual void run () override
 Run the thread.
 
virtual void sample (double elapsed)=0
 Collect a sample.
 

Detailed Description

A thread collecting samples at regular intervals.

Constructor & Destructor Documentation

◆ ~QwtSamplingThread()

QwtSamplingThread::~QwtSamplingThread ( )
virtual

Destructor .

◆ QwtSamplingThread()

QwtSamplingThread::QwtSamplingThread ( QObject *  parent = nullptr)
explicitprotected

Constructor.

Member Function Documentation

◆ elapsed()

double QwtSamplingThread::elapsed ( ) const

Get the time (in ms) since the thread was started.

◆ interval()

double QwtSamplingThread::interval ( ) const

Get the interval (in ms), between 2 calls of sample()

◆ run()

void QwtSamplingThread::run ( )
overrideprotectedvirtual

Run the thread.

Loop collecting samples started from QThread::start()

◆ sample()

virtual void QwtSamplingThread::sample ( double  elapsed)
protectedpure virtual

Collect a sample.

◆ setInterval

void QwtSamplingThread::setInterval ( double  msecs)
slot

Change the interval (in ms), when sample() is called.

◆ stop

void QwtSamplingThread::stop ( )
slot

Terminate the collecting thread.


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