When a material witness for the defendant is about to leave the state, or is so sick or infirm as to afford reasonable grounds for apprehending that he will be unable to attend the trial, the defendant may apply for an order that the witness be examined conditionally.
Idaho Code § 19-3102