def add_chain_info(data_api, data_setters, chain_index):
chain_id = data_api.chain_id_list[chain_index]<EOL>chain_name = data_api.chain_name_list[chain_index]<EOL>num_groups = data_api.groups_per_chain[chain_index]<EOL>data_setters.set_chain_info(chain_id, chain_name, num_groups)<EOL>next_ind = data_api.group_counter + num_groups<EOL>last_ind = data_api.group_counter<EOL>for group_ind in range(last_ind, next_ind):<EOL><INDENT>add_group(data_api, data_setters, group_ind)<EOL>data_api.group_counter +=<NUM_LIT:1><EOL><DEDENT>data_api.chain_counter+=<NUM_LIT:1><EOL>
Add the data for a whole chain.
    :param data_api the data api from where to get the data
    :param data_setters the class to push the data to
    :param chain_index the index for this chain