[prev in list] [next in list] [prev in thread] [next in thread]
List: kdevelop-devel
Subject: Re: Someone mentioned accessor methods?
From: Alexander Dymo <cloudtemple () mksat ! net>
Date: 2004-03-09 20:30:43
Message-ID: 200403092230.43932.cloudtemple () mksat ! net
[Download RAW message or body]
On Tuesday 09 March 2004 21:53, Steven T. Hatton wrote:
> Works just fine in Java, but I don't believe the same can be done in C++.
> Correct?
>
> Also, C++ers tend to simply use the name of the member field as the name of
> the retrieval (getter) method. Agreed?
>
> What about passing a reference verses passing a value; to the mutator
> (setter)?; as the return value?
>
> What about constness?
>
> Does someone have a paradigm for this they would like to share?
I like this one ;)
public:
void setMemberName(const type &memberName)
type memberName() const
private:
type m_memberName;
--
Alexander Dymo
Ukrainian State Maritime Technical University, ICST Department
_______________________________________________
Kdevelop-devel mailing list
Kdevelop-devel@barney.cs.uni-potsdam.de
http://barney.cs.uni-potsdam.de/mailman/listinfo/kdevelop-devel
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic