**Undertaking**— An agreement, signed by the accused or a surety that the accused will attend a hearing, trial, sentencing or surrender themselves.