The officer was taken to hospital after the incident.