The answer is that there is no nice way to do that.
It's because of the way USB standard was designed. Basically when device is plugged in, it is enumerated and then it can be used by the system. A USB device (for USB less than 3.0) itself can't initiate communication with the system on its own, so it relies on the system to initiate communication with it first. So when you safely remove a device it loses its enumeration and since the device can't communicate any more with the system, system doesn't know it's there. The only way to solve this is to reset the USB hub which will in turn reset all devices connected to it.
USB 3.0 devices should be able to initiate communication on their own, so maybe we'll have flash drives that can remount themselves after being safely removed.