I’m noobie in c++.
I have class DataBase which contains tables( class Table) and I must overload operators to get next result:
dataBase(3,5)=someTable; – this code must replace tables 3-5 from database with table someTable.
So, help me please whith overload methods signatures.
The signature for overloading the function call operator within your
DataBaseclass is:Where
reference_typeis a proxy reference, that is a helper type that stores a reference to the database and the first and last indexes, and overloadsoperator=to do the replacement. Something in the lines of: