Change requirement of image extensions in ImageSuffix class' Javadoc to a possibility

Some services may provide different image formats using the same suffix,
without we know what format the service provide. Enforcing an image extension
could so lead to provide invalid image URLs, like for SoundCloud PNG images
currently.

With this documentation change, it is now clear that users of this class decide
of whether they want to include image extensions in the suffix. The previous
behavior described in the Javadoc was not enforced.
This commit is contained in:
AudricV 2023-09-30 21:11:09 +02:00
parent 917554acc4
commit ac00459c1a
No known key found for this signature in database
GPG Key ID: DA92EC7905614198
1 changed files with 3 additions and 3 deletions

View File

@ -7,9 +7,9 @@ import java.io.Serializable;
import java.util.Objects;
/**
* Serializable class representing a suffix (including its format extension, such as {@code .jpg})
* which needs to be added to get an image/thumbnail URL with its corresponding height, width and
* estimated resolution level.
* Serializable class representing a suffix (which may include its format extension, such as
* {@code .jpg}) which needs to be added to get an image/thumbnail URL with its corresponding
* height, width and estimated resolution level.
*
* <p>
* This class is used to construct {@link org.schabi.newpipe.extractor.Image Image}