hey, i implemented the following functor:
struct CompareCatId : public std::binary_function<Vehicle*, Vehicle*, bool>
{
bool operator()(Vehicle* x, Vehicle* y) const
{
if(x->GetVehicleType() > y->GetVehicleType())
return true;
else if (x->GetVehicleType() == y->GetVehicleType() && x->GetLicenseNumber() > y->GetLicenseNumber())
return true;
else
return false;
}
};
when i try to define a vector as the following i am getting alot of errors :
vector<Vehicle*,CompareCatId>* m_vehiclesVector;
thanks in advance for your help.