‘getPrivateNodeHandle’ and ‘getNodeHandle’ as class constructor parameters [closed]
Hello,
I have the following constructor for a non nodelet class.
Chor::Chor(ros::NodeHandle &_nh , ros::NodeHandle &_nhPriv):nh_(_nh),nhPriv_(_nhPriv)
{
}
I want to pass nodeHandle from the nodelet to the class above. The class above is instatiated as private inside the nodelet. In my nodelet class I do
private:
Chor chor_nodelet(getNodeHandle(),getPrivateNodeHandle());
onInit()
{ ..
}
But I get the following error
error: ‘getNodeHandle’ is not a type
error: ‘getPrivateNodeHandle’ is not a type
What is wrong here ?