def filter(self, source_file, encoding):  # noqa A001
        """Parse XML file."""

        sources = []
        for content, filename, enc in self.get_content(source_file):
            self.additional_context = self.get_context(filename)
            sources.extend(self._filter(content, source_file, enc))
        return sources
def filter ( self , source_file , encoding ) : sources = [ ] for content , filename , enc in self . get_content ( source_file ) : self . additional_context = self . get_context ( filename ) sources . extend ( self . _filter ( content , source_file , enc ) ) return sources
Parse XML file.