How to check if the device is on vibration mode or not, it is possible?

I want to either reproduce a sound if the device is on sound mode or make a vibration in case the device is on vibration mode after certain action.

Thanks