Changing handlerClass type to Class