Class generator