Interface MemoryRecord.Builder

All Superinterfaces:
Buildable, CopyableBuilder<MemoryRecord.Builder,MemoryRecord>, SdkBuilder<MemoryRecord.Builder,MemoryRecord>, SdkPojo
Enclosing class:
MemoryRecord

@Mutable @NotThreadSafe public static interface MemoryRecord.Builder extends SdkPojo, CopyableBuilder<MemoryRecord.Builder,MemoryRecord>
  • Method Details

    • memoryRecordId

      MemoryRecord.Builder memoryRecordId(String memoryRecordId)

      The unique identifier of the memory record.

      Parameters:
      memoryRecordId - The unique identifier of the memory record.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • content

      The content of the memory record.

      Parameters:
      content - The content of the memory record.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • content

      The content of the memory record.

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

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

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

      MemoryRecord.Builder memoryStrategyId(String memoryStrategyId)

      The identifier of the memory strategy associated with this record.

      Parameters:
      memoryStrategyId - The identifier of the memory strategy associated with this record.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • namespaces

      MemoryRecord.Builder namespaces(Collection<String> namespaces)

      The namespaces associated with this memory record. Namespaces help organize and categorize memory records.

      Parameters:
      namespaces - The namespaces associated with this memory record. Namespaces help organize and categorize memory records.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • namespaces

      MemoryRecord.Builder namespaces(String... namespaces)

      The namespaces associated with this memory record. Namespaces help organize and categorize memory records.

      Parameters:
      namespaces - The namespaces associated with this memory record. Namespaces help organize and categorize memory records.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • createdAt

      MemoryRecord.Builder createdAt(Instant createdAt)

      The timestamp when the memory record was created.

      Parameters:
      createdAt - The timestamp when the memory record was created.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • metadata

      A map of metadata key-value pairs associated with a memory record.

      Parameters:
      metadata - A map of metadata key-value pairs associated with a memory record.
      Returns:
      Returns a reference to this object so that method calls can be chained together.