def is_complete_v4_key(v4_key):
 assert (len(v4_key.path_element_list()) >= 1)
 last_element = v4_key.path_element((len(v4_key.path_element_list()) - 1))
 return (last_element.has_id() or last_element.has_name())

def is_complete_v4_key ( v4_key ) : assert ( len ( v4_key . path_element_list ( ) ) >= 1 ) last_element = v4_key . path_element ( ( len ( v4_key . path_element_list ( ) ) - 1 ) ) return ( last_element . has_id ( ) or last_element . has_name ( ) )
returns true if a key specifies an id or name .