2011年10月22日

String类的构造函数,析构函数,赋值函数

摘要: View Code 1 #include<string.h> 2 class String 3 { 4 private: 5 char * m_data; 6 public: 7 String(const char *str = NULL);//构造函数 8 String(const String &other);//拷贝构造函数 9 ~String(void);//析构函数10 String &operator = (const String &other);//赋值函数11 }12 13 St... 阅读全文

posted @ 2011-10-22 10:23 mrpomelo 阅读(384) 评论(4) 推荐(0)

导航