Package io.openems.common.types
Class EdgeConfigDiff
java.lang.Object
io.openems.common.types.EdgeConfigDiff
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic class
Represents the difference between an old and a new configuration of a Component. -
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic EdgeConfigDiff
diff
(EdgeConfig newConfig, EdgeConfig oldConfig) Find difference between two EdgeConfigs.Formats the Diff as a HTML table.Formats the Diff as Text.boolean
Gets whether this diff is not empty, i.e.toString()
-
Constructor Details
-
EdgeConfigDiff
public EdgeConfigDiff()
-
-
Method Details
-
diff
Find difference between two EdgeConfigs.- Parameters:
newConfig
- the new EdgeConfigoldConfig
- the old EdgeConfig- Returns:
- an instance of EdgeConfigDiff
-
getAsHtml
Formats the Diff as a HTML table.- Returns:
- a String with the HTML code
-
getAsText
Formats the Diff as Text.- Returns:
- a String representing the Diff
-
getComponents
-
isDifferent
public boolean isDifferent()Gets whether this diff is not empty, i.e. the EdgeConfig instances were different.- Returns:
- true for different EdgeConfigs.
-
toString
-