(1) The court shall appoint an attorney to act as guardian ad litem to defend the rights and interests of the person to be sterilized.
(2) The person to be sterilized is entitled to appear and testify at the hearing, to examine and cross examine witnesses, and to compel the attendance of witnesses.
(3) The person who is the subject of a sterilization proceeding may, on motion to the court and for good cause shown, waive the right to be present at the hearing. If the court grants that motion, the person shall be represented by a guardian ad litem at the hearing.