Writing interface for Matrix

  abstract, c++, interface

I am writing an Interface for Matrix class in C++
So all functions need to be virtual
Now in the below code I have defined a virtual function virtual Matrix add(Matrix A, Matrix B) const = 0;
The problem I see is the class Matrix is not defined. So I am confused should I define the
class Matrix in the interface ? Or is there a better way to implement the interface

class MatrixInterface
    {
    public:
       
        virtual Matrix add(Matrix A, Matrix B) const = 0;
    };

Source: Windows Questions C++

LEAVE A COMMENT