The integrity of the courts depends on their acting in accordance with the judicial process and, in no small measure, on the maintenance of public confidence in that process. Particularly is that so in relation to criminal proceedings which involve the most important of all judicial functions, namely, the determination of the guilt or innocence of persons accused of criminal offences. Public confidence cannot be maintained in the courts and their criminal processes if, as postulated by s 5(1), the courts are required to deprive persons of their liberty, not on the basis that they have breached any law, but on the basis that an opinion is formed, by reference to material which may or may not be admissible in legal proceedings, that on the balance of probabilities, they may do so."