Sign in to follow this  
jyk

Handle-based smart pointers

Recommended Posts

Can anyone give me the general idea behind a handle-based smart pointer? I've heard of them, but can't seem to find any info (I think there's an article in the GPG series, but I can't afford any new books right now). The reason I'm curious is that it sounds like it might combine the relative advantages of the smart pointer and handle approaches, such as the reproducability of handles (i.e. for saving gamestates), and the convenience of pointer semantics (such as overloaded ->). I may have that all wrong though. So, if anyone could tell me a little about this method, I'd appreciate it.

Share this post


Link to post
Share on other sites
Actually, I beleive what you are talking about is simply a normal handle.

They are compared to smart pointers because both have a safety-layer that's put between you and the object. Smart pointers have themselves as the layer, and handles have whatever you are passing the handle too. However, there might be something more specific that you're talking about, so in that case disrgard what I just said.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this