背景我有一个在内部使用vector的容器类。我已经为这个包装类提供了一个方法AddChar(std::string),它对内部vector执行push_back()。在我的代码中,有时我必须向容器中添加多个项目。为此,我必须使用container.AddChar("First");container.AddChar("Second");这会使代码变大。所以为了让它更容易,我打算重载运算符container两个项目将被添加到基础vector中。这是我使用的代码classExtendedVector{private:vectorcontainer;public:friendExtended