This is code for ruby class