A
Allen
class SerializedObject
{
public:
int setBytes(void * buffer, int length)
{ return setBytes(buffer, length, ByteOrder::LocalOrder()); }
virtual int setBytes(void *buffer, int length, int order);
...
};
class MySerializedObject : public SerilizedObject
{
public:
MySerializedObject() {}
virtual ~MySerializedObject() {}
public:
int setBytes(void * buffer, int length, int order) { ... }
...
};
int main()
{
MySerializedObject obj;
char buffer[8];
obj.setBytes(buffer, 8); /* MARKED */
return 0;
}
vs2005 tells that MySerializedObject class has no setBytes method
defined which accepts two arguments at the MARKED line. Why and how to
correct it?
Thank you in advance.
{
public:
int setBytes(void * buffer, int length)
{ return setBytes(buffer, length, ByteOrder::LocalOrder()); }
virtual int setBytes(void *buffer, int length, int order);
...
};
class MySerializedObject : public SerilizedObject
{
public:
MySerializedObject() {}
virtual ~MySerializedObject() {}
public:
int setBytes(void * buffer, int length, int order) { ... }
...
};
int main()
{
MySerializedObject obj;
char buffer[8];
obj.setBytes(buffer, 8); /* MARKED */
return 0;
}
vs2005 tells that MySerializedObject class has no setBytes method
defined which accepts two arguments at the MARKED line. Why and how to
correct it?
Thank you in advance.