def METHOD_NAME(self):
    if self.is_comment:
        return self.data.endswith("-->")
    elif self.is_cdata:
        return self.data.endswith("]]>")
    else:
        # This fails for attributes that contain an unescaped ">"
        return self.data.endswith(">")