Interface AggregateTask<T>
- All Known Subinterfaces:
ComponentAggregateTask
,PersistencePredictorAggregateTask
,SchedulerAggregateTask
,SchedulerByCentralOrderAggregateTask
,StaticIpAggregateTask
- All Known Implementing Classes:
ComponentAggregateTaskImpl
,PersistencePredictorAggregateTaskImpl
,SchedulerAggregateTaskImpl
,SchedulerByCentralOrderAggregateTaskImpl
,StaticIpAggregateTaskImpl
public interface AggregateTask<T>
-
Nested Class Summary
Modifier and TypeInterfaceDescriptionstatic final record
-
Method Summary
Modifier and TypeMethodDescriptionvoid
Aggregates the given instance.void
create
(User user, List<AppConfiguration> otherAppConfigurations) e.void
delete
(User user, List<AppConfiguration> otherAppConfigurations) e.Gets a general message for the user if any operations fails.void
reset()
Resets the task.void
validate
(List<String> errors, AppConfiguration appConfiguration, T config) Validates the expected configuration.
-
Method Details
-
aggregate
Aggregates the given instance.- Parameters:
currentConfiguration
- theAppConfiguration
of the instancelastConfiguration
- the old configuration of the instance
-
create
void create(User user, List<AppConfiguration> otherAppConfigurations) throws OpenemsError.OpenemsNamedException e. g. creates components that were aggregated by the instances and my also delete unused components.- Parameters:
user
- the executing userotherAppConfigurations
- the other existingAppConfiguration
s- Throws:
OpenemsError.OpenemsNamedException
- on error
-
delete
void delete(User user, List<AppConfiguration> otherAppConfigurations) throws OpenemsError.OpenemsNamedException e. g. deletes components that were aggregated.- Parameters:
user
- the executing userotherAppConfigurations
- the other existingAppConfiguration
s- Throws:
OpenemsError.OpenemsNamedException
- on error
-
validate
Validates the expected configuration.- Parameters:
errors
- the errors that occur during the validationappConfiguration
- the whole configurationconfig
- the configuration to validate
-
getGeneralFailMessage
Gets a general message for the user if any operations fails.- Parameters:
l
- theLanguage
of the message- Returns:
- the error message
-
getExecuteConstraints
-
reset
void reset()Resets the task.
-