They didn’t say how far in advance it was planned, could have been two days. What they are saying is it was not she was rushed in for emergency surgery, but clearly it was planned very quickly.
but to be honest, as they are both cancelling arrangements now, and they aren’t known for honesty, ie the queen. Then, I’d have to assume this was pretty much emergency surgery. So it’s not a hysterectomy, and as she’s known to leave hospital as soon as she can, Ie after the babies, then it’s likely this was very serious, but that doesn’t mean she won’t be absolutely fine.