<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def top_level_domain(self, tld_type: Optional[TLDType] = None) -> str: """Return random top level domain. :param tld_type: Enum object DomainType :return: Top level domain. :raises NonEnumerableError: if tld_type not in DomainType. """

        key = self._validate_enum(item=tld_type, enum=TLDType)
        return self.random.choice(TLD[key])