QwtData(3)

πŸ“¦
version 5.2.3_qt5+git20181129.2819734 Β· 2 versions
, in opensuse-leap 16.0

πŸ’– QwtData β€” from the Qwt User's Guide, bestie edition πŸ’–

okay so like. this is QwtData(3), part of the Qwt User's Guide, and honestly? it's giving ✨blueprint energy✨. it's the interface, the vibe, the blueprint β€” not the actual data itself. let's get into it 🫢


🌸 NAME 🌸

QwtData β€” no extra words needed, she speaks for herself πŸ’…


✨ SYNOPSIS ✨

#include <qwt_data.h>

Inherited by QwtArrayData, QwtCPointerData, and QwtPolygonFData.

so yeah, those three are her daughters and they all carry the family name πŸŽ€

πŸ¦‹ Public Member Functions πŸ¦‹

  • QwtData () β€” the constructor, she's here, she's simple, she's ready
  • virtual ~QwtData () β€” the destructor, virtual bc we do polymorphism in this house
  • virtual QwtDoubleRect boundingRect () const β€” hands you the bounding rectangle of the data
  • virtual QwtData * copy () const =0 β€” pure virtual, returns a pointer to a copy (virtual copy constructor vibes) β€” you gotta implement this
  • virtual size_t size () const =0 β€” pure virtual, returns the size of the data set β€” also mandatory bestie
  • virtual double x (size_t i) const =0 β€” pure virtual, the x value of data point i
  • virtual double y (size_t i) const =0 β€” pure virtual, the y value of data point i

πŸ”’ Protected Member Functions πŸ”’

  • QwtData & operator= (const QwtData &) β€” assignment operator, but make it virtualized 😌

πŸ‘‘ Detailed Description πŸ‘‘

so QwtData defines an interface to any type of curve data. literally any. she's flexible like that πŸ’…

classes that derive from QwtData may:

  • store the data in almost any type of container πŸ“¦
  • calculate the data on the fly instead of storing it 🧚 (main character energy honestly)

πŸ”₯ Member Function Documentation πŸ”₯

QwtDoubleRect QwtData::boundingRect () const [virtual]

returns the bounding rectangle of the data. if there's no bounding rect β€” like, say, for empty data β€” the rectangle is invalid:

QwtDoubleRect::isValid() == false

⚠️ warning bestie, listen up: this is a slow implementation that iterates over all the points. it's intended to be overloaded by derived classes. and in case of auto scaling, boundingRect() gets called for every replot, so it might genuinely be worth it to implement a cache, or use x(0), x(size() - 1) for ordered data ... πŸ‘€

Reimplemented in</purage> QwtCPointerData, and QwtArrayData.


virtual QwtData* QwtData::copy () const [pure virtual]

Returns: pointer to a copy (virtual copy constructor) 🫢

Implemented in QwtCPointerData, QwtArrayData, and QwtPolygonFData.


QwtData& QwtData::operator= (const QwtData &) [protected]

assignment operator (virtualized) ✨ short and iconic, no notes.


virtual size_t QwtData::size () const [pure virtual]

Returns: size of the data set πŸ“

Implemented in QwtCPointerData, QwtArrayData, and QwtPolygonFData.


virtual double QwtData::x (size_t i) const [pure virtual]

return the x value of data point i

Parameters:

  • i β€” index

Returns:

  • x β€” x value of data point i

Implemented in QwtCPointerData, QwtArrayData, and QwtPolygonFData.


virtual double QwtData::y (size_t i) const [pure virtual]

return the y value of data point i

Parameters:

  • i β€” index

Returns:

  • y β€” y value of data point i

Implemented in QwtCPointerData, QwtArrayData, and QwtPolygonFData.


πŸŽ€ Author πŸŽ€

generated automatically by Doxygen for Qwt User's Guide from the source code. no human author, just robot slay πŸ€–πŸ’…


and that's the whole page, bestie!! πŸ’–βœ¨πŸŒΈπŸ¦‹πŸ«Ά

this was Version 5.2.3, dated Tue Nov 20 2012 β€” yeah she's a little vintage but vintage is literally iconic, periodt. πŸ‘‘