I have some classes:
class Transform {
public:
virtual auto operator()(everything is ok) const -> void = 0;
};
class FourierTransform : public Transform{
public:
virtual auto operator()(type1&, type2&) const -> void = 0; // someone else will override with a real operation
};
class DWTTransform : public Transform{
protected:
public:
auto operator()(type3&, type4&, type5&, type6&) const;
};
I want to be able to have a pointer to the base and be able to use a operation at runtime depending on which class I use, like this:
shared_ptr<Transform>fft = make_shared<IterativeFastFourierTransform>();
fft->operator()(stuff1, stuff2);
1