Add a method to extend a ring class