Interface EmbedImage



  • public interface EmbedImage
    This interface represents an embed image.
    • Method Detail

      • getUrl

        URL getUrl​()
        Gets the url of the image.
        Returns:
        The url of the image.
      • getProxyUrl

        URL getProxyUrl​()
        Gets the proxy url of the image.
        Returns:
        The proxy url of the image.
      • getHeight

        int getHeight​()
        Gets the height of the image.
        Returns:
        The height of the image.
      • getWidth

        int getWidth​()
        Gets the width of the image.
        Returns:
        The width of the image.
      • downloadAsBufferedImage

        CompletableFuture<BufferedImage> downloadAsBufferedImage​(DiscordApi api)
        Downloads the image as a BufferedImage.
        Parameters:
        api - The discord api instance used to download the image.
        Returns:
        The thumbnail as a BufferedImage.
      • downloadAsByteArray

        CompletableFuture<byte[]> downloadAsByteArray​(DiscordApi api)
        Downloads the image as a byte array.
        Parameters:
        api - The discord api instance used to download the image.
        Returns:
        The thumbnail as a byte array.
      • downloadAsInputStream

        InputStream downloadAsInputStream​(DiscordApi api)
                                   throws IOException
        Downloads the image as an input stream.
        Parameters:
        api - The discord api instance used to download the image.
        Returns:
        The thumbnail as a input stream.
        Throws:
        IOException - If an IO error occurs.