Two workers were assaulted in random attacks by a man addicted to prescription medic- ation as they made their way to a Dublin hospital.
Anthony O'Shaughnessy (31) also jumped in front of another woman's car, hitting her windscreen with a stick and cracking it.
Judge David McHugh sentenced O'Shaughnessy to four months in prison.
The defendant, with add- resses at Avondale Park, Mulhuddart, and Plunkett Road, Askeaton, Limerick, admitted counts of assault and criminal damage.
The incidents all took place at Mill Road in Blanchardstown last February 26.
Sgt Maria Callaghan said the first victim was driving to work at James Connolly Memorial Hospital when the defendant jumped out in front of her car.
He hit the vehicle with a stick, cracking the windscreen and damaging the bonnet. The monetary loss was assessed at €825.
In the second incident, Sgt Callaghan said the victim was walking towards the hospital when the defendant ran towards her, shouting.
He threw a book - a vehicle manual - at her and shouted racial slurs.
In the third incident, Sgt Callaghan said the victim was walking towards the hospital when O'Shaughnessy ran across the road towards her. He picked up a rock and threw it, but it did not hit her. He also threw a water bottle which struck her.
O'Shaughnessy further ad- mitted driving without insurance at Ladyswell Road, Mulhuddart, on August 19.
The court heard he had no previous convictions.
Defence solicitor Wayne Kenny said the attacks were completely random and O'Shaughnessy wished to apologise to the victims for his behaviour.
Mr Kenny said the defendant suffered from anxiety and his "choice of poison" was prescription medication.
On the day of the assaults, Mr Kenny said that the defend- ant had "over-indulged" on tablets.
Imposing a four-month sentence, Judge McHugh said the assaults were "appalling".
On the uninsured driving charge, Judge McHugh fined O'Shaughnessy €300 and disqualified him from driving for two years.