LibreVNA/Software/PC_Application/VNA/Deembedding/deembeddingoption.h

41 lines
1.1 KiB
C
Raw Normal View History

#ifndef DEEMBEDDINGOPTION_H
#define DEEMBEDDINGOPTION_H
#include "savable.h"
#include "Device/device.h"
#include "Traces/tracemodel.h"
2021-10-21 19:00:34 +08:00
#include <QWidget>
class DeembeddingOption : public QObject, public Savable
{
Q_OBJECT
public:
enum class Type {
PortExtension,
TwoThru,
MatchingNetwork,
ImpedanceRenormalization,
// Add new deembedding options here, do not explicitly assign values and keep the Last entry at the last position
Last,
};
static DeembeddingOption *create(Type type);
static QString getName(Type type);
virtual std::set<int> getAffectedPorts() = 0;
2022-08-05 02:12:15 +08:00
virtual void transformDatapoint(VirtualDevice::VNAMeasurement &p) = 0;
virtual void edit(){}
virtual Type getType() = 0;
2021-02-11 23:59:59 +08:00
public slots:
2022-08-05 02:12:15 +08:00
virtual void measurementCompleted(std::vector<VirtualDevice::VNAMeasurement> m){Q_UNUSED(m)}
signals:
// Deembedding option may selfdestruct if not applicable with current settings. It should emit this signal before deleting itself
void deleted(DeembeddingOption *option);
2021-02-11 23:59:59 +08:00
void triggerMeasurement();
};
#endif // DEEMBEDDING_H