'Creates a table of TokenTableFields'

def _create_token_table(self, token_sequences, par_breaks):

    token_table = {}
    current_par = 0
    current_tok_seq = 0
    pb_iter = par_breaks.__iter__()
    current_par_break = next(pb_iter)
    if (current_par_break == 0):
        try:
            current_par_break = next(pb_iter)
        except StopIteration:
            raise ValueError('No    paragraph    breaks    were    found(text    too    short    perhaps?)')
    for ts in token_sequences:
        for (word, index) in ts.wrdindex_list:
            try:
                while (index > current_par_break):
                    current_par_break = next(pb_iter)
                    current_par += 1
            except StopIteration:
                pass
            if (word in token_table):
                token_table[word].total_count += 1
                if (token_table[word].last_par != current_par):
                    token_table[word].last_par = current_par
                    token_table[word].par_count += 1
                if (token_table[word].last_tok_seq != current_tok_seq):
                    token_table[word].last_tok_seq = current_tok_seq
                    token_table[word].ts_occurences.append([current_tok_seq, 1])
                else:
                    token_table[word].ts_occurences[(-1)][1] += 1
            else:
                token_table[word] = TokenTableField(first_pos=index, ts_occurences=[[current_tok_seq, 1]], total_count=1, par_count=1, last_par=current_par, last_tok_seq=current_tok_seq)
        current_tok_seq += 1
    return token_table
