If you were not committed to stand trial then the case is generally finished and you have won.
It is very rare but the prosecution can directly present a defendant. Even if a Magistrate knocks out all the charges, they can still take you to trial.
We would know at the end of your case if a direct presentment was likely to happen. Generally the prosecution accept the Magistrate’s decision that the case is too weak to proceed further.
If the charges were struck out, an application for costs can be made on your behalf. The costs are at the discretion of the Magistrate.