When Merrick Garland is sworn in as attorney general, it will serve as a capstone on a career that has spanned years at the Justice Department and decades as a federal appellate court judge.