Class DocumentParserExtensionsKt

    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
    • Field Summary

      Fields 
      Modifier and Type Field Description
    • Constructor Summary

      Constructors 
      Constructor Description
    • Enum Constant Summary

      Enum Constants 
      Enum Constant Description
    • Method Summary

      Modifier and Type Method Description
      final static Document parseAsync(DocumentParser $self, DocumentSource source, CoroutineContext context) Asynchronously parses a document from the specified document source using the given coroutine context.
      final static Document parseAsync(DocumentParser $self, InputStream input, CoroutineContext context) Asynchronously parses a document from the provided input stream using the specified dispatcher.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

    • Method Detail

      • parseAsync

         final static Document parseAsync(DocumentParser $self, DocumentSource source, CoroutineContext context)

        Asynchronously parses a document from the specified document source using the given coroutine context.

        Parameters:
        source - The dev.langchain4j.data.document.DocumentSource from which the document will be parsed.
        context - The CoroutineContext to use for asynchronous execution, defaults to Dispatchers.IO.
        Returns:

        The parsed dev.langchain4j.data.document.Document, potentially with merged metadata from the document source.

      • parseAsync

         final static Document parseAsync(DocumentParser $self, InputStream input, CoroutineContext context)

        Asynchronously parses a document from the provided input stream using the specified dispatcher.

        Parameters:
        input - The InputStream from which the document will be parsed.
        context - The CoroutineContext to use for asynchronous execution, defaults to [Dispatchers.IO].
        Returns:

        The parsed Document.