Interface DocumentParser

All Known Implementing Classes:
JsonDocumentParser, TextDocumentParser

public interface DocumentParser
Since:
2024-12-02 11:25
Author:
HeYQ
  • Method Summary

    Modifier and Type
    Method
    Description
    List<org.springframework.ai.document.Document>
    parse(InputStream inputStream)
    Parses a given InputStream into a Document.
  • Method Details

    • parse

      List<org.springframework.ai.document.Document> parse(InputStream inputStream)
      Parses a given InputStream into a Document. The specific implementation of this method will depend on the type of the document being parsed.

      Note: This method does not close the provided InputStream - it is the caller's responsibility to manage the lifecycle of the stream.

      Parameters:
      inputStream - The InputStream that contains the content of the Document.
      Returns:
      The parsed Document.