What is the favorable naming convention for methods or properties returning a boolean value in Ruby? -
i've seen of these:
is_validis_valid?valid?
is there preferred one?
edit: more conditionals:
has_commenthas_comment?comment?was_fullwas_full?full?
please add more descriptive examples.
i think convention add '?' @ end of method instead of 'is'
valid?
Comments
Post a Comment