<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def append(self, ldap_filter):
 """ Appends a filter or a criterion to this filter :param ldap_filter: An LDAP filter or criterion :raise TypeError: If the parameter is not of a known type :raise ValueError: If the more than one filter is associated to a NOT operator """

        if not isinstance(ldap_filter, (LDAPFilter, LDAPCriteria)):
            raise TypeError(
                "Invalid filter type: {0}".format(type(ldap_filter).__name__)
            )

        if len(self.subfilters) >= 1 and self.operator == NOT:
            raise ValueError("Not operator only handles one child")

        self.subfilters.append(ldap_filter)