To decide whether a defendant is guilty or not guilty, the magistrate can only take into account the evidence presented in court, see Evidence below. Evidence includes all the information given directly to the court by a witness under oath.
This information must comply with particular rules (the rules of evidence) which have been built up by the courts over many years and some have also been made by the Parliament. If the prosecution or the defence object to certain information being given the magistrate must decide whether it complies with these rules. If it does, then it is included in the evidence and the magistrate can take notice of it in reaching a verdict. If not, it is excluded.