Skip to content

Instantly share code, notes, and snippets.

@rafb43
Created August 26, 2010 04:59
Show Gist options
  • Select an option

  • Save rafb43/550846 to your computer and use it in GitHub Desktop.

Select an option

Save rafb43/550846 to your computer and use it in GitHub Desktop.
class MyClass
def complex_property
@my_complex_property
end
def complex_property= value
#complex logic
@my_complex_property = revamped_value
end
def do_something_with_complex_property
return false unless @my_complex_property < 2
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment