qwt_system_clock.cpp
Go to the documentation of this file.
1 /******************************************************************************
2  * Qwt Widget Library
3  * Copyright (C) 1997 Josef Wilgen
4  * Copyright (C) 2002 Uwe Rathmann
5  *
6  * This library is free software; you can redistribute it and/or
7  * modify it under the terms of the Qwt License, Version 1.0
8  *****************************************************************************/
9 
10 #include "qwt_system_clock.h"
11 #include <qelapsedtimer.h>
12 
15 {
16  return m_timer.isValid();
17 }
18 
21 {
22  m_timer.start();
23 }
24 
30 {
31  const qint64 nsecs = m_timer.restart();
32  return nsecs / 1e6;
33 }
34 
37 {
38  const qint64 nsecs = m_timer.nsecsElapsed();
39  return nsecs / 1e6;
40 }
QwtSystemClock::start
void start()
Start the elapsed timer.
Definition: qwt_system_clock.cpp:20
QwtSystemClock::elapsed
double elapsed() const
Definition: qwt_system_clock.cpp:36
QwtSystemClock::isNull
bool isNull() const
Definition: qwt_system_clock.cpp:14
QwtSystemClock::restart
double restart()
Definition: qwt_system_clock.cpp:29
qwt_system_clock.h
QwtSystemClock::m_timer
QElapsedTimer m_timer
Definition: qwt_system_clock.h:41


plotjuggler
Author(s): Davide Faconti
autogenerated on Mon Nov 11 2024 03:23:46