# A self.method! returning a changing self attributes

**URL:** <https://www.ruby-forum.com/t/a-self-method-returning-a-changing-self-attributes/123254>\
**Category:** Ruby\
**Created:** [December 15, 2007, 2:31pm UTC](https://www.ruby-forum.com/t/a-self-method-returning-a-changing-self-attributes/123254 "2007-12-15T14:31:31Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Une\_BSSSSvS\_ue](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/u/2acd7d/32.png) [@Une\_BSSSSvS\_ue](https://www.ruby-forum.com/u/Une_BSSSSvS_ue)\
**Post date:** [December 15, 2007, 2:31pm UTC](https://www.ruby-forum.com/t/a-self-method-returning-a-changing-self-attributes/123254/1 "2007-12-15T14:31:31Z")

</div>

say, i’ve a class “Clazz” i’ve a method #revert\_to\_saved  
who returns a revert to saved instance of Clazz BUT i want to implement  
also  
#revert\_to\_saved!

that is having all self attributes modified to the revert to saved  
instance of Clazz at once…

then, how, could I modify self ?
