Some convenient utilities.