Add class info to string