'Main gateway into parsing the data. Will retrieve all necessary data elements.'

def parse_for_data(self, code_or_second_para, hstyle, pstyle):

    parsing_data = []
    for section in self.tag_sections:
        (name, anchor) = self.parse_name_and_anchor_from_data(section, hstyle)
        first_paragraph = self.parse_first_paragraph_from_data(section, pstyle)
        if (code_or_second_para == 'code'):
            code = self.parse_code_from_data(section)
            second_paragraph = ''
        elif (code_or_second_para == 'para'):
            second_paragraph = self.parse_second_paragraph_from_data(section, pstyle)
            code = ''
        data_elements = {'name': name, 'anchor': anchor, 'first_paragraph': first_paragraph, 'second_paragraph': second_paragraph, 'code': code, 'url': self.url}
        parsing_data.append(data_elements)
    self.parsed_data = parsing_data
