replaced class by resource