C++问题求解class B { public: B(a& aA){} 在类B中那个B()是什么?
classB{public:B(a&aA){pA=&aA;}voidFunc(){cout<<"ThisismemberfunctionFunc()"<<endl;}vo...
class B {
public:
B(a& aA) {
pA = &aA;
}
void Func() {
cout<<"This is member function Func()"<<endl;
}
void NewFunc()
{
pA->OtherFunc();
}
private:
a * pA;
}; 展开
public:
B(a& aA) {
pA = &aA;
}
void Func() {
cout<<"This is member function Func()"<<endl;
}
void NewFunc()
{
pA->OtherFunc();
}
private:
a * pA;
}; 展开
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询