Issue #2305839 by jhodgdon, tim.plunkett: Convert hook_element_info() to annotated classes.