A judge may consult with or appear at a public hearing before an executive or legislative body or official: