File indexing completed on 2025-01-26 03:34:15
0001 /* 0002 File : XYAnalysisCurvePrivate.h 0003 Project : LabPlot 0004 Description : Private members of XYAnalysisCurve 0005 -------------------------------------------------------------------- 0006 SPDX-FileCopyrightText: 2017 Alexander Semke <alexander.semke@web.de> 0007 SPDX-License-Identifier: GPL-2.0-or-later 0008 */ 0009 0010 #ifndef XYANALYSISCURVEPRIVATE_H 0011 #define XYANALYSISCURVEPRIVATE_H 0012 0013 #include "backend/worksheet/plots/cartesian/XYAnalysisCurve.h" 0014 #include "backend/worksheet/plots/cartesian/XYCurvePrivate.h" 0015 0016 class XYAnalysisCurve; 0017 class Column; 0018 class AbstractColumn; 0019 0020 class XYAnalysisCurvePrivate : public XYCurvePrivate { 0021 public: 0022 explicit XYAnalysisCurvePrivate(XYAnalysisCurve*); 0023 ~XYAnalysisCurvePrivate() override; 0024 0025 XYAnalysisCurve::DataSourceType dataSourceType{XYAnalysisCurve::DataSourceType::Spreadsheet}; 0026 const XYCurve* dataSourceCurve{nullptr}; 0027 0028 void recalculate(); 0029 virtual bool recalculateSpecific(const AbstractColumn* tmpXDataColumn, const AbstractColumn* tmpYDataColumn) = 0; 0030 virtual void prepareTmpDataColumn(const AbstractColumn** tmpXDataColumn, const AbstractColumn** tmpYDataColumn); 0031 virtual void resetResults() = 0; // Clear the results of the previous calculation 0032 virtual bool preparationValid(const AbstractColumn* tmpXDataColumn, const AbstractColumn* tmpYDataColumn); 0033 0034 const AbstractColumn* xDataColumn{nullptr}; //<! column storing the values for the input x-data for the analysis function 0035 const AbstractColumn* yDataColumn{nullptr}; //<! column storing the values for the input y-data for the analysis function 0036 const AbstractColumn* y2DataColumn{nullptr}; //<! column storing the values for the optional second input y-data 0037 QString xDataColumnPath; 0038 QString yDataColumnPath; 0039 QString y2DataColumnPath; 0040 0041 Column* xColumn{nullptr}; //<! column used internally for storing the x-values of the result analysis curve 0042 Column* yColumn{nullptr}; //<! column used internally for storing the y-values of the result analysis curve 0043 QVector<double>* xVector{nullptr}; 0044 QVector<double>* yVector{nullptr}; 0045 0046 XYAnalysisCurve* const q; 0047 }; 0048 0049 #endif