use class object instead of string name