When any person for whose appearance or arrest the officer presiding in any court is empowered to issue a summons or warrant, is present in such court, such officer may require such person to execute a bond, with or without sureties, for his appearance in such court, or any other court to which the case may be transferred for trial.