Record Class Address
java.lang.Object
java.lang.Record
energy.eddie.regionconnector.fr.enedis.dto.situation.Address
public record Address(@Nullable String line1, @Nullable String line2, @Nullable String line3, @Nullable String line4, @Nullable String line5, @Nullable String line6, @Nullable String line7)
extends Record
Address of the customer (not the PRM address).
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.@Nullable Stringline1()Returns the value of theline1record component.@Nullable Stringline2()Returns the value of theline2record component.@Nullable Stringline3()Returns the value of theline3record component.@Nullable Stringline4()Returns the value of theline4record component.@Nullable Stringline5()Returns the value of theline5record component.@Nullable Stringline6()Returns the value of theline6record component.@Nullable Stringline7()Returns the value of theline7record component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
Address
public Address(@Nullable String line1, @Nullable String line2, @Nullable String line3, @Nullable String line4, @Nullable String line5, @Nullable String line6, @Nullable String line7) Creates an instance of aAddressrecord class.- Parameters:
line1- the value for theline1record componentline2- the value for theline2record componentline3- the value for theline3record componentline4- the value for theline4record componentline5- the value for theline5record componentline6- the value for theline6record componentline7- the value for theline7record component
-
-
Method Details
-
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). -
line1
Returns the value of theline1record component.- Returns:
- the value of the
line1record component
-
line2
Returns the value of theline2record component.- Returns:
- the value of the
line2record component
-
line3
Returns the value of theline3record component.- Returns:
- the value of the
line3record component
-
line4
Returns the value of theline4record component.- Returns:
- the value of the
line4record component
-
line5
Returns the value of theline5record component.- Returns:
- the value of the
line5record component
-
line6
Returns the value of theline6record component.- Returns:
- the value of the
line6record component
-
line7
Returns the value of theline7record component.- Returns:
- the value of the
line7record component
-