Class ConnectionLimitViolation

java.lang.Object
energy.eddie.aiida.models.connectionlimit.ConnectionLimitViolation

@Entity public class ConnectionLimitViolation extends Object
A continuous period in which the measured power of a permission was outside its connection limits.

The limit and the document are only the ones that were violated first. If the limit changes while the violation is ongoing, they are not updated. The peak power is only tracked in the direction of the first violation. The measurements and limits are copied, as they may be cleaned up independently of the violation.

  • Constructor Details

    • ConnectionLimitViolation

      protected ConnectionLimitViolation()
    • ConnectionLimitViolation

      public ConnectionLimitViolation(UUID permissionId, UUID dataSourceId, Instant startedAt, @Nullable String documentId, @Nullable BigDecimal minLimitKw, @Nullable BigDecimal maxLimitKw, BigDecimal startPowerKw)
  • Method Details

    • permissionId

      public UUID permissionId()
    • dataSourceId

      public UUID dataSourceId()
    • startedAt

      public Instant startedAt()
    • endedAt

      @Nullable public Instant endedAt()
    • documentId

      @Nullable public String documentId()
    • minLimitKw

      @Nullable public BigDecimal minLimitKw()
    • maxLimitKw

      @Nullable public BigDecimal maxLimitKw()
    • startPowerKw

      public BigDecimal startPowerKw()
    • peakPowerKw

      public BigDecimal peakPowerKw()
    • end

      public void end(Instant endedAt)
    • registerPower

      public boolean registerPower(BigDecimal powerKw)
      Updates the peak power if the measured power is further beyond the limit than any previous measurement.
      Returns:
      true if the peak changed.