Please could someone explain to me what this operator does in C++ at a function?
class simplecanny
{
ros::NodeHandle nh_;
ros::NodeHandle n;
ros::Publisher pub ;
image_transport::ImageTransport it_;
image_transport::Subscriber image_sub_; //image subscriber
image_transport::Publisher image_pub_; //image publisher(we subscribe to ardrone image_raw)
std_msgs::String msg;
public:
*** simplecanny()
: it_(nh_) ***
{
image_sub_ = it_.subscribe("/ardrone/image_raw", 1, &simplecanny::imageCb, this);
image_pub_= it_.advertise("/arcv/Image",1);
}
~simplecanny()
{
cv::destroyWindow(WINDOW);
}
...
At the simplecanny() : it_(nh_)
constructor, Im not familiar with the : it_(nh_)
part. What does it do? Is that a case of operator overloading?
Thanks in advance!