<p>What's a good rule of thumb for naming methods that return properties/attributes/members of an object?  If an object has some immutable quality "blarg", should a method that returns that quality be called "blarg()" or "getBlarg()"?  The Java API, for example, is inconsistent: most properties are accessed through "get" methods (even those that don't have corresponding "set" methods), but yet we also have things like Object.hashCode() instead of Object.getHashCode().  </p>

<p>Update: Should whether or not it's the property is a field (in the implementation) be the determiner here?  What about a class to represent immutable points in 2-d space?  Regardless of whether the point is stored as (x,y) or (r,theta), I would still want accessors for all four properties.  Should they be getX(), getY(), etc, or just x(), y(), etc?  From the point of view of the user, shouldn't all four have the same naming convention since we don't want our user to know/care about our implementation?</p>

I believe the most often used conventions are:
```
```
GetBlarg() or getBlarg()
```
```
It could be argued that the name
```
GetHashCode()
```
is incorrect, since the object doesn't have a field called
```
hashcode
```
and that it's calculated.
These are of course all conventions, not rules, and most of them have evolved over a long time and as such are not 100% consistent.
Regards
K