<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def build_transitive_closures(self):
 """Build the transitive closures of the hierarchy. This method constructs dictionaries which contain terms in the hierarchy as keys and either all the "isa+" or "partof+" related terms as values. """

        self.component_counter = 0
        for rel, tc_dict in ((self.isa_objects, self.isa_closure),
                             (self.partof_objects, self.partof_closure),
                             (self.isa_or_partof_objects,
                                 self.isa_or_partof_closure)):
            self.build_transitive_closure(rel, tc_dict)