Forums before death by AOL, social media and spammers... "We can't have nice things"
|    comp.lang.c++.moderated    |    Moderated discussion of C++ superhackery    |    33,346 messages    |
[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]
|    Message 33,213 of 33,346    |
|    Kamil Rojewski to All    |
|    Re: Template setters    |
|    23 Sep 13 10:20:02    |
      From: kamil.rojewski@googlemail.com              On Friday, September 20, 2013 2:10:01 PM UTC+2, Öö Tiib wrote:       > I have so far had impression that the member variable that setter sets       > is component of the class that has the setter. I think that whole object       > is combination of its components. Person who does not know interfaces       > of members of class can not therefore make much functionality using       > those members.       >       > Are there several persons? One who designs the functionality of       > class and other who designs the setters of its members? If so then       > that is rather unusual organization I'm afraid.              The class designer has the knowledge of its components, of course.       Nowhere I suggest otherwise. The decoupling, I was talking about,       frees us from the requirements imposed by those components in the       given situation. But it doesn't free us in other use cases and it's       not meant to. In the case of trivial setters acting as perfect       forwarders, there is no much more knowledge required than operator =.       I preserve that requirement, but I offer the possibility of extending       the setter functionality and make it resistant to change further down       the chain. You did have a point, when the possible types passed       through by the user are not known. This is a place where we must       commit to certain acceptable types to make the interface unambiguous.                     --        [ See http://www.gotw.ca/resources/clcm.htm for info about ]        [ comp.lang.c++.moderated. First time posters: Do this! ]              --- SoupGate-Win32 v1.05        * Origin: you cannot sedate... all the things you hate (1:229/2)    |
[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]
(c) 1994, bbs@darkrealms.ca