Record Class ThermalUnits
java.lang.Object
java.lang.Record
edu.ie3.datamodel.models.input.container.ThermalUnits
- Record Components:
houses
- Available housesstorages
- Available storage
- All Implemented Interfaces:
InputContainer<ThermalUnitInput>
,Serializable
public record ThermalUnits(Set<ThermalHouseInput> houses, Set<ThermalStorageInput> storages)
extends Record
implements InputContainer<ThermalUnitInput>
Container to group together all
ThermalUnitInput
s- See Also:
-
Constructor Summary
ConstructorDescriptionThermalUnits
(Collection<ThermalHouseInput> houses, Collection<ThermalStorageInput> storages) ThermalUnits
(Set<ThermalHouseInput> houses, Set<ThermalStorageInput> storages) Creates an instance of aThermalUnits
record class. -
Method Summary
Modifier and TypeMethodDescriptionfinal boolean
Indicates whether some other object is "equal to" this one.final int
hashCode()
Returns a hash code value for this object.houses()
Returns the value of thehouses
record component.storages()
Returns the value of thestorages
record component.toString()
Returns a string representation of this record class.
-
Constructor Details
-
Method Details
-
allEntitiesAsList
- Specified by:
allEntitiesAsList
in interfaceInputContainer<ThermalUnitInput>
- Returns:
- unmodifiable List of all entities
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared withObjects::equals(Object,Object)
. -
houses
Returns the value of thehouses
record component.- Returns:
- the value of the
houses
record component
-
storages
Returns the value of thestorages
record component.- Returns:
- the value of the
storages
record component
-