Record Class ProductImageUploadRequest
java.lang.Object
java.lang.Record
com.alpermulayim.openfoodfacts_spring_boot_starter.requests.images.ProductImageUploadRequest
public record ProductImageUploadRequest(String productCode, org.springframework.web.multipart.MultipartFile file, ImageFormat imageFormat, ImageFacet facet, Language language)
extends Record
-
Nested Class Summary
Nested Classes -
Constructor Summary
ConstructorsConstructorDescriptionProductImageUploadRequest
(String productCode, org.springframework.web.multipart.MultipartFile file, ImageFormat imageFormat, ImageFacet facet, Language language) Creates an instance of aProductImageUploadRequest
record class. -
Method Summary
Modifier and TypeMethodDescriptionbuilder()
final boolean
Indicates whether some other object is "equal to" this one.facet()
Returns the value of thefacet
record component.org.springframework.web.multipart.MultipartFile
file()
Returns the value of thefile
record component.final int
hashCode()
Returns a hash code value for this object.Returns the value of theimageFormat
record component.language()
Returns the value of thelanguage
record component.Returns the value of theproductCode
record component.final String
toString()
Returns a string representation of this record class.
-
Constructor Details
-
ProductImageUploadRequest
public ProductImageUploadRequest(String productCode, org.springframework.web.multipart.MultipartFile file, ImageFormat imageFormat, ImageFacet facet, Language language) Creates an instance of aProductImageUploadRequest
record class.- Parameters:
productCode
- the value for theproductCode
record componentfile
- the value for thefile
record componentimageFormat
- the value for theimageFormat
record componentfacet
- the value for thefacet
record componentlanguage
- the value for thelanguage
record component
-
-
Method Details
-
builder
-
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)
. -
productCode
Returns the value of theproductCode
record component.- Returns:
- the value of the
productCode
record component
-
file
public org.springframework.web.multipart.MultipartFile file()Returns the value of thefile
record component.- Returns:
- the value of the
file
record component
-
imageFormat
Returns the value of theimageFormat
record component.- Returns:
- the value of the
imageFormat
record component
-
facet
Returns the value of thefacet
record component.- Returns:
- the value of the
facet
record component
-
language
Returns the value of thelanguage
record component.- Returns:
- the value of the
language
record component
-