0

Hello again I'm working with the Poco internet library trying to understand it but I have come across some syntax that I don't quite understand. This may be a beginner question. Here it is:

Poco::AutoPtr<Poco::Notification> pNf (_queue.waitDequeueNotification);

I know AutoPtr's contain a count of how many objects reference the object being pointed to; and that only one object can hold ownership over the object. I do not understand what's going on here. Could somebody explain it to me?

2
Contributors
2
Replies
8
Views
3 Years
Discussion Span
Last Post by Curious Gorge
1

This line declares a variable called pNf which is an auto-pointer to a Notification object, and it is initialized to _queue.waitDequeueNotification.

The AutoPtr is a class template. And the Notification class is it's template argument, making AutoPtr<Notification> an auto-pointer to a notification object. I believe that it is essentially equivalent to the standard unique-pointer.

0

Ah, that's almost exactly what I guessed that it was. Looking up unknown syntax is difficult you know? :D

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.