If the cattle rubbed on anything in the barn, its a good chance the ringworm fungus will now be in the barn. Most things I've read say that it takes about a year for the fungus to go away. I wouldn't worry much about it as even if the fungus is in the barn, it doesn't mean another batch of animals will catch it. Even if they do, it simply looks bad. It doesn't hurt anything.
You can clean the barn and pens with an Iodine bath if you want. That would eliminate the fungus.
Rod