Interface RelevantContent.Builder

  • Method Details

    • content

      RelevantContent.Builder content(String content)

      The actual content of the relevant item.

      Parameters:
      content - The actual content of the relevant item.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • documentId

      RelevantContent.Builder documentId(String documentId)

      The unique identifier of the document containing the relevant content.

      Parameters:
      documentId - The unique identifier of the document containing the relevant content.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • documentTitle

      RelevantContent.Builder documentTitle(String documentTitle)

      The title of the document containing the relevant content.

      Parameters:
      documentTitle - The title of the document containing the relevant content.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • documentUri

      RelevantContent.Builder documentUri(String documentUri)

      The URI of the document containing the relevant content.

      Parameters:
      documentUri - The URI of the document containing the relevant content.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • documentAttributes

      RelevantContent.Builder documentAttributes(Collection<DocumentAttribute> documentAttributes)

      Additional attributes of the document containing the relevant content.

      Parameters:
      documentAttributes - Additional attributes of the document containing the relevant content.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • documentAttributes

      RelevantContent.Builder documentAttributes(DocumentAttribute... documentAttributes)

      Additional attributes of the document containing the relevant content.

      Parameters:
      documentAttributes - Additional attributes of the document containing the relevant content.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • documentAttributes

      RelevantContent.Builder documentAttributes(Consumer<DocumentAttribute.Builder>... documentAttributes)

      Additional attributes of the document containing the relevant content.

      This is a convenience method that creates an instance of the DocumentAttribute.Builder avoiding the need to create one manually via DocumentAttribute.builder().

      When the Consumer completes, SdkBuilder.build() is called immediately and its result is passed to documentAttributes(List<DocumentAttribute>).

      Parameters:
      documentAttributes - a consumer that will call methods on DocumentAttribute.Builder
      Returns:
      Returns a reference to this object so that method calls can be chained together.
      See Also:
    • scoreAttributes

      RelevantContent.Builder scoreAttributes(ScoreAttributes scoreAttributes)

      Attributes related to the relevance score of the content.

      Parameters:
      scoreAttributes - Attributes related to the relevance score of the content.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • scoreAttributes

      default RelevantContent.Builder scoreAttributes(Consumer<ScoreAttributes.Builder> scoreAttributes)

      Attributes related to the relevance score of the content.

      This is a convenience method that creates an instance of the ScoreAttributes.Builder avoiding the need to create one manually via ScoreAttributes.builder().

      When the Consumer completes, SdkBuilder.build() is called immediately and its result is passed to scoreAttributes(ScoreAttributes).

      Parameters:
      scoreAttributes - a consumer that will call methods on ScoreAttributes.Builder
      Returns:
      Returns a reference to this object so that method calls can be chained together.
      See Also: