Entries:
Comments:
Posts:

Loading User Information from Channel 9

Something went wrong getting user information from Channel 9

Latest Achievement:

Loading User Information from MSDN

Something went wrong getting user information from MSDN

Visual Studio Achievements

Latest Achievement:

Loading Visual Studio Achievements

Something went wrong getting the Visual Studio Achievements

Jeff Koftinoff

Jeff Koftinoff jdkoftinoff

Niner since 2012

  • Inheritance Is The Base Class of Evil

    I found that Sean did pretty much the same presentation before, and the source code for that one is on github here: https://github.com/boostcon/cppnow_presentations_2012/blob/master/fri/value_semantics/value_semantics.cpp 

    Sean, is there any difference in the code now? And thank you for the great presentation!

  • Day 1 Keynote - Bjarne Stroustrup: C++11 Style

    @Ray: The problem with that approach becomes when your 'controller' needs to do something a bit more complex and needs the target object's state to decide what to do or needs to notify the target object to do something else upon a change.

    In my experience I've found those cases the primary cases where I actually needed getters and setters.

    So then in that case the Property class template needs to change to be able to contain a controller object which then holds a reference to the target object ( 'Man', in this case ), and the Controller then can not use static methods.  

    But then here is the bloat added.

    So I like Darren's new proposal best - if they are logically publically available properties just leave them as public member variables.  

    In the future, when you realize that you need something more complex, either make them private and add getters and setters and modify the client code, or make a decorator that allows the assignment operator to work with them which calls the real getters and setter behind the scenes.