Class ChargeSessionStamp

java.lang.Object
io.openems.edge.evcs.ocpp.common.ChargeSessionStamp

public class ChargeSessionStamp extends Object
  • Constructor Details

    • ChargeSessionStamp

      public ChargeSessionStamp(Instant time, long energy)
      Constructor of a ChargeSession with the given time and energy.
      Parameters:
      time - the Instant time
      energy - the Energy
    • ChargeSessionStamp

      public ChargeSessionStamp(long energy)
      Constructor of a ChargeSession with the initial Energy.

      The time will be initialized by Instant.now().

      Parameters:
      energy - the Energy
    • ChargeSessionStamp

      public ChargeSessionStamp(Instant time)
      Constructor of a ChargeSession with the initial Time.

      The energy will be initialized by 0.

      Parameters:
      time - the Instant time
    • ChargeSessionStamp

      public ChargeSessionStamp()
      Constructor of a ChargeSession with no initial values.
  • Method Details

    • getTime

      public Instant getTime()
    • setTime

      public void setTime(Instant time)
    • getEnergy

      public long getEnergy()
    • setEnergy

      public void setEnergy(long energy)
    • isChargeSessionStampPresent

      public boolean isChargeSessionStampPresent()
    • setChargeSessionStamp

      public void setChargeSessionStamp(Instant time, long energy)
    • resetChargeSessionStamp

      protected void resetChargeSessionStamp()
    • setChargeSessionStampIfNotPresent

      public void setChargeSessionStampIfNotPresent(Instant time, long energy)
    • resetChargeSessionStampIfPresent

      public void resetChargeSessionStampIfPresent()
      Reset the Charge Session Timestamp.