def next(self, type=None):
i = self.stop<EOL>s = self.sentence<EOL>while i < len(s):<EOL><INDENT>if s[i].chunk is not None and type in (s[i].chunk.type, None):<EOL><INDENT>return s[i].chunk<EOL><DEDENT>i += <NUM_LIT:1><EOL><DEDENT>
Returns the next chunk in the sentence with the given type.