I've seen hospital carparks like that.
As I recall barrier on entry which records your licence plate.
Then...if over the free period you pay at a paymachine putting in your number plate details and then exit at the barrier which again records your numberplate on exit, checks for payment and lifts for you.
Alternatively if you are within the free period you just drive up to the barrier and it opens for you....which I have been in all cases.
I've no idea what happens if you don't pay, and then just drive up to the exist barrier - does it block your exit until you do? no idea.