Record Class EditarVeiculoDTO
java.lang.Object
java.lang.Record
br.com.selfmaintenance.app.records.veiculo.EditarVeiculoDTO
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionano()Returns the value of theanorecord component.cor()Returns the value of thecorrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.marca()Returns the value of themarcarecord component.modelo()Returns the value of themodelorecord component.tipo()Returns the value of thetiporecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
EditarVeiculoDTO
public EditarVeiculoDTO(Optional<String> marca, Optional<String> modelo, Optional<Integer> ano, Optional<String> cor, String tipo) Creates an instance of aEditarVeiculoDTOrecord class.- Parameters:
marca- the value for themarcarecord componentmodelo- the value for themodelorecord componentano- the value for theanorecord componentcor- the value for thecorrecord componenttipo- the value for thetiporecord 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). -
marca
Returns the value of themarcarecord component.- Returns:
- the value of the
marcarecord component
-
modelo
Returns the value of themodelorecord component.- Returns:
- the value of the
modelorecord component
-
ano
Returns the value of theanorecord component.- Returns:
- the value of the
anorecord component
-
cor
Returns the value of thecorrecord component.- Returns:
- the value of the
correcord component
-
tipo
Returns the value of thetiporecord component.- Returns:
- the value of the
tiporecord component
-