Class PrepareJobState

java.lang.Object
com.qtsurfer.api.client.model.PrepareJobState

@Generated(value="org.openapitools.codegen.languages.JavaClientCodegen", comments="Generator version: 7.14.0") public class PrepareJobState extends Object
State of a single-instrument prepare job — the `JobState` shape plus a per-hour data-coverage summary. A single-instrument prepare is always terminal (`status: Completed`): the client decides what to do from `coverageRatio` (e.g. execute if it is at or above a chosen threshold) rather than polling for missing hours that may never arrive — a missing hour for one instrument usually means low activity, not missing data.
  • Field Details

  • Constructor Details

    • PrepareJobState

      public PrepareJobState()
  • Method Details

    • contextId

      public PrepareJobState contextId(@Nonnull String contextId)
    • getContextId

      @Nonnull public String getContextId()
      Opaque context identifier for the job
      Returns:
      contextId
    • setContextId

      public void setContextId(@Nonnull String contextId)
    • status

      public PrepareJobState status(@Nonnull PrepareJobState.StatusEnum status)
    • getStatus

      @Nonnull public PrepareJobState.StatusEnum getStatus()
      Current status of the job. Treat `Completed | Aborted | Failed` as terminal; `New | Started` mean keep polling. A single-instrument prepare is always terminal (`Completed`) — decide from `PrepareJobState.coverageRatio`, not by polling.
      Returns:
      status
    • setStatus

      public void setStatus(@Nonnull PrepareJobState.StatusEnum status)
    • statusDetail

      public PrepareJobState statusDetail(@Nullable String statusDetail)
    • getStatusDetail

      @Nullable public String getStatusDetail()
      Detailed status information, if available
      Returns:
      statusDetail
    • setStatusDetail

      public void setStatusDetail(@Nullable String statusDetail)
    • size

      public PrepareJobState size(@Nonnull Integer size)
    • getSize

      @Nonnull public Integer getSize()
      Total size of the data being prepared
      Returns:
      size
    • setSize

      public void setSize(@Nonnull Integer size)
    • completed

      public PrepareJobState completed(@Nonnull Integer completed)
    • getCompleted

      @Nonnull public Integer getCompleted()
      The amount of data processed so far
      Returns:
      completed
    • setCompleted

      public void setCompleted(@Nonnull Integer completed)
    • startTime

      public PrepareJobState startTime(@Nullable OffsetDateTime startTime)
    • getStartTime

      @Nullable public OffsetDateTime getStartTime()
      Timestamp for when the preparation started
      Returns:
      startTime
    • setStartTime

      public void setStartTime(@Nullable OffsetDateTime startTime)
    • endTime

      public PrepareJobState endTime(@Nullable OffsetDateTime endTime)
    • getEndTime

      @Nullable public OffsetDateTime getEndTime()
      Timestamp for when the preparation finished
      Returns:
      endTime
    • setEndTime

      public void setEndTime(@Nullable OffsetDateTime endTime)
    • dataFrom

      public PrepareJobState dataFrom(@Nullable OffsetDateTime dataFrom)
    • getDataFrom

      @Nullable public OffsetDateTime getDataFrom()
      Start of the available data range for the prepared instrument.
      Returns:
      dataFrom
    • setDataFrom

      public void setDataFrom(@Nullable OffsetDateTime dataFrom)
    • dataTo

      public PrepareJobState dataTo(@Nullable OffsetDateTime dataTo)
    • getDataTo

      @Nullable public OffsetDateTime getDataTo()
      End of the available data range for the prepared instrument.
      Returns:
      dataTo
    • setDataTo

      public void setDataTo(@Nullable OffsetDateTime dataTo)
    • coverageRatio

      public PrepareJobState coverageRatio(@Nullable Double coverageRatio)
    • getCoverageRatio

      @Nullable public Double getCoverageRatio()
      `hoursWithData / totalHours` in `[0,1]` (`1.0` when `totalHours` is 0) — the fraction of hours in the requested range that have served data. minimum: 0 maximum: 1
      Returns:
      coverageRatio
    • setCoverageRatio

      public void setCoverageRatio(@Nullable Double coverageRatio)
    • totalHours

      public PrepareJobState totalHours(@Nullable Integer totalHours)
    • getTotalHours

      @Nullable public Integer getTotalHours()
      Number of whole hours in the requested prepare range.
      Returns:
      totalHours
    • setTotalHours

      public void setTotalHours(@Nullable Integer totalHours)
    • hoursWithData

      public PrepareJobState hoursWithData(@Nullable Integer hoursWithData)
    • getHoursWithData

      @Nullable public Integer getHoursWithData()
      Number of hours in the range that have data.
      Returns:
      hoursWithData
    • setHoursWithData

      public void setHoursWithData(@Nullable Integer hoursWithData)
    • hoursWithoutData

      public PrepareJobState hoursWithoutData(@Nullable List<PrepareJobStateAllOfHoursWithoutData> hoursWithoutData)
    • addHoursWithoutDataItem

      public PrepareJobState addHoursWithoutDataItem(PrepareJobStateAllOfHoursWithoutData hoursWithoutDataItem)
    • getHoursWithoutData

      @Nullable public List<PrepareJobStateAllOfHoursWithoutData> getHoursWithoutData()
      One entry per hour in the range that has no data, with a rationale.
      Returns:
      hoursWithoutData
    • setHoursWithoutData

      public void setHoursWithoutData(@Nullable List<PrepareJobStateAllOfHoursWithoutData> hoursWithoutData)
    • equals

      public boolean equals(Object o)
      Return true if this PrepareJobState object is equal to o.
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • toUrlQueryString

      public String toUrlQueryString()
      Convert the instance into URL query string.
      Returns:
      URL query string
    • toUrlQueryString

      public String toUrlQueryString(String prefix)
      Convert the instance into URL query string.
      Parameters:
      prefix - prefix of the query string
      Returns:
      URL query string