|
-
April 11th, 2010, 03:16 PM
#1
how to add copy contructor to this class since the construtor has a void
class Utils {
public:
// Constructor
Utils(void);
// copy Constructor
Utils(const Utils &src);
// Destructor
~Utils(void);
// This method will write two bytes to given destination
void writeTwoBytes(usigned char *desPtr, unsigned short src);
// This method will read two bytes from a given source pointer
ubin16 readTwoBytes(unsigned char *srcPtr);
// This method checks the range
ubin8 rangeCheckingPorts(PTypes eType, unsigned short sourceIpPort,
unsigned short destIpPort);
private:
// This method checks for big endian at run time
int isBigEndian();
// This member variable stores the output of the isBigEndian
int m_bigEndianTest;
};
-
April 11th, 2010, 04:22 PM
#2
Re: how to add copy contructor to this class since the construtor has a void
It hardly seems like you need to define a copy constructor or destructor here, since the only member is a single int.....
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|