Class TaskStatusMetadata

java.lang.Object
ai.docling.serve.api.task.response.TaskStatusMetadata

public class TaskStatusMetadata extends Object
Represents metadata for the status of a task, providing detailed information about the task's progress and outcomes. This class is used to encapsulate the statistical data related to the execution of a task, such as the number of documents processed, succeeded, or failed. It is intended for use in tracking task processing and is serialized to JSON for communication between system components. Features: - Serialization and deserialization using Jackson annotations. - All fields are included in the JSON only if they are non-empty. - Immutable structure with a builder pattern for object creation. Fields: - numDocs: The total number of documents associated with the task. - numProcessed: The number of documents that have been processed. - numSucceeded: The number of documents that were successfully processed. - numFailed: The number of documents that failed processing.
  • Method Details

    • builder

      public static @NonNull TaskStatusMetadata.Builder builder()
    • toBuilder

      public @NonNull TaskStatusMetadata.Builder toBuilder()
    • getNumDocs

      public Long getNumDocs()
      Total number of documents in the task.
      Returns:
      the total number of documents
    • getNumProcessed

      public Long getNumProcessed()
      Number of documents processed so far.
      Returns:
      the number of processed documents
    • getNumSucceeded

      public Long getNumSucceeded()
      Number of documents that succeeded.
      Returns:
      the number of successful documents
    • getNumFailed

      public Long getNumFailed()
      Number of documents that failed.
      Returns:
      the number of failed documents
    • toString

      public @NonNull String toString()
      Overrides:
      toString in class Object