Class BatteryProtection.Builder
- java.lang.Object
-
- io.openems.edge.battery.protection.BatteryProtection.Builder
-
- Enclosing class:
- BatteryProtection
public static class BatteryProtection.Builder extends java.lang.Object
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description BatteryProtection.Builder
applyBatteryProtectionDefinition(BatteryProtectionDefinition def, ClockProvider clockProvider)
Applies all values from aBatteryProtectionDefinition
.BatteryProtection
build()
Builds theBatteryProtection
instance.BatteryProtection.Builder
setChargeMaxCurrentHandler(ChargeMaxCurrentHandler chargeMaxCurrentHandler)
Sets theChargeMaxCurrentHandler
.BatteryProtection.Builder
setDischargeMaxCurrentHandler(DischargeMaxCurrentHandler dischargeMaxCurrentHandler)
Sets theDischargeMaxCurrentHandler
.
-
-
-
Constructor Detail
-
Builder
protected Builder(Battery battery)
-
-
Method Detail
-
applyBatteryProtectionDefinition
public BatteryProtection.Builder applyBatteryProtectionDefinition(BatteryProtectionDefinition def, ClockProvider clockProvider)
Applies all values from aBatteryProtectionDefinition
.- Parameters:
def
- theBatteryProtectionDefinition
clockProvider
- aClockProvider
- Returns:
- a
BatteryProtection.Builder
-
setChargeMaxCurrentHandler
public BatteryProtection.Builder setChargeMaxCurrentHandler(ChargeMaxCurrentHandler chargeMaxCurrentHandler)
Sets theChargeMaxCurrentHandler
.- Parameters:
chargeMaxCurrentHandler
- theChargeMaxCurrentHandler
- Returns:
- a
BatteryProtection.Builder
-
setDischargeMaxCurrentHandler
public BatteryProtection.Builder setDischargeMaxCurrentHandler(DischargeMaxCurrentHandler dischargeMaxCurrentHandler)
Sets theDischargeMaxCurrentHandler
.- Parameters:
dischargeMaxCurrentHandler
- theDischargeMaxCurrentHandler
- Returns:
- a
BatteryProtection.Builder
-
build
public BatteryProtection build()
Builds theBatteryProtection
instance.- Returns:
- a
BatteryProtection
-
-