Class TextExtractor
Class TextExtractor
Namespace: Aspose.Pdf.Plugins
Assembly: Aspose.PDF.dll
TextExtractor 플러그인을 나타냅니다.
public class TextExtractor : PdfExtractor, IPlugin, IDisposable
상속
object ← PdfExtractor ← TextExtractor
구현
상속된 멤버
PdfExtractor.Process(IPluginOptions), PdfExtractor.Dispose(), object.GetType(), object.MemberwiseClone(), object.ToString(), object.Equals(object?), object.Equals(object?, object?), object.ReferenceEquals(object?, object?), object.GetHashCode()
예제
이 예제는 PDF 문서의 텍스트 내용을 추출하는 방법을 보여줍니다.
// PDF 내용에서 텍스트를 추출하기 위해 TextExtractor 객체를 생성합니다.
using (TextExtractor extractor = new TextExtractor())
{
// TextExtractorOptions 생성
textExtractorOptions = new TextExtractorOptions();
// 데이터 소스에 입력 파일 경로 추가
textExtractorOptions.AddDataSource(new FileDataSource(inputPath));
// 추출 프로세스 수행
ResultContainer resultContainer = extractor.Process(textExtractorOptions);
// ResultContainer 객체에서 추출된 텍스트 가져오기
string textExtracted = resultContainer.ResultCollection[0].ToString();
}
비고
Aspose.Pdf.Plugins.TextExtractor 객체는 PDF 문서에서 텍스트를 추출하는 데 사용됩니다.
생성자
TextExtractor()
public TextExtractor()