需要一个java web编写的类似新浪微博的工程!学习一下

2025-01-27 11:37:49
推荐回答(1个)
回答1:

}
friend ostream& operator<< (ostream&,MyString&);//重载<<运算符
friend istream& operator>> (istream&,MyString&);//重载>>运算符
MyString& operator=(const char *cstr);//只能被重载为成员函数
char operator[](const int nPos);//只能被重载为成员函数
char at(const unsigned int nPos);
private:
int m_nLength; //获取当前 String 对象中的字符数
char* m_pChars;
int maxSize;
};