Extracted an interface for TextExtractor