Added an example of generating methods for objects