Changed arguments from String to Class type.