Record Class TemporalPointBatch<P extends TemporalPoint<?,?>>

java.lang.Object
java.lang.Record
com.inductiveautomation.historian.gateway.api.storage.TemporalPointBatch<P>
Type Parameters:
P - The type of temporal points in the batch.

public record TemporalPointBatch<P extends TemporalPoint<?,?>>(List<P extends TemporalPoint<?,?>> points, CompletableFuture<StorageResult<P extends TemporalPoint<?,?>>> result) extends Record
A record representing a batch of temporal points and their associated storage result.
  • Constructor Details

  • Method Details

    • pointType

      public TemporalPointType pointType()
      Retrieves the type of the temporal points in the batch.
      Returns:
      The type of the temporal points.
    • of

      public static <P extends TemporalPoint<?, ?>> TemporalPointBatch<P> of(List<P> points)
      Creates a new TemporalPointBatch with the given list of points.
      Type Parameters:
      P - The type of temporal points.
      Parameters:
      points - The list of temporal points.
      Returns:
      A new TemporalPointBatch instance.
    • combine

      public static <P extends TemporalPoint<?, ?>> TemporalPointBatch<P> combine(List<TemporalPointBatch<P>> batches)
      Combines multiple TemporalPointBatch instances into a single batch.
      Type Parameters:
      P - The type of temporal points in the batches.
      Parameters:
      batches - The list of TemporalPointBatch instances to combine.
      Returns:
      A new TemporalPointBatch containing all points from the input batches.
    • toString

      public final String toString()
      Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • hashCode

      public final int hashCode()
      Returns a hash code value for this object. The value is derived from the hash code of each of the record components.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • equals

      public final boolean equals(Object o)
      Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared with Objects::equals(Object,Object).
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • points

      public List<P> points()
      Returns the value of the points record component.
      Returns:
      the value of the points record component
    • result

      public CompletableFuture<StorageResult<P>> result()
      Returns the value of the result record component.
      Returns:
      the value of the result record component