Quantcast
Channel: Is this key-oriented access-protection pattern a known idiom? - Stack Overflow
Browsing latest articles
Browse All 5 View Live

Answer by user1703394 for Is this key-oriented access-protection pattern a...

Its pretty close to this:http://minorfs.wordpress.com/2013/01/18/raiicap-pattern-injected-singleton-alternative-for-c/Basically if you consider a reference to an object of well designed class to be...

View Article



Answer by thomas for Is this key-oriented access-protection pattern a known...

some boring man like me would make the fowllow code:int FraudKey=0;b.protectedMethod(reinterpret_cast<SomeKey&>(FraudKey));

View Article

Answer by Rick Yorgason for Is this key-oriented access-protection pattern a...

Thanks to your other question it looks like this pattern is now known as the "passkey" pattern.In C++11, it gets even cleaner, because instead of callingb.protectedMethod(SomeKey());you can just...

View Article

Answer by Haspemulator for Is this key-oriented access-protection pattern a...

It seems that this idiom like one mentioned in another SO question here. It is called Attorney-Client idiom and described in more details there.

View Article

Is this key-oriented access-protection pattern a known idiom?

Matthieu M. brought up a pattern for access-protection in this answer that i'd seen before, but never conciously considered a pattern:class SomeKey { friend class Foo; SomeKey() {} // possibly make it...

View Article

Browsing latest articles
Browse All 5 View Live


Latest Images