J
Jonathon McKitrick
I'm trying to avoid leftover C-style in my new Python programs.
If a class has a boolean property, and I am branching based on that
property, which of these is preferred?
if MyClass.boolProp:
<continue>
OR
if MyClass.IsTrueProp():
<continue>
In other words, do you use accessors or just access the variable directly?
jm
If a class has a boolean property, and I am branching based on that
property, which of these is preferred?
if MyClass.boolProp:
<continue>
OR
if MyClass.IsTrueProp():
<continue>
In other words, do you use accessors or just access the variable directly?
jm