Interface AccountUpdaterDelegate



  • public interface AccountUpdaterDelegate
    This class is internally used by the AccountUpdater to update the connected account. You usually don't want to interact with this object.
    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      void setAvatar​(byte[] avatar)
      Queues the avatar of the connected account to get updated.
      void setAvatar​(byte[] avatar, String fileType)
      Queues the avatar of the connected account to get updated.
      void setAvatar​(BufferedImage avatar)
      Queues the avatar of the connected account to get updated.
      void setAvatar​(BufferedImage avatar, String fileType)
      Queues the avatar of the connected account to get updated.
      void setAvatar​(File avatar)
      Queues the avatar of the connected account to get updated.
      void setAvatar​(InputStream avatar)
      Queues the avatar of the connected account to get updated.
      void setAvatar​(InputStream avatar, String fileType)
      Queues the avatar of the connected account to get updated.
      void setAvatar​(URL avatar)
      Queues the avatar of the connected account to get updated.
      void setAvatar​(Icon avatar)
      Queues the avatar of the connected account to get updated.
      void setUsername​(String username)
      Queues the username of the connected account to get updated.
      CompletableFuture<Void> update​()
      Performs the queued updates.
    • Method Detail

      • setUsername

        void setUsername​(String username)
        Queues the username of the connected account to get updated.
        Parameters:
        username - The username to set.
      • setAvatar

        void setAvatar​(BufferedImage avatar)
        Queues the avatar of the connected account to get updated. This method assumes the file type is "png"!
        Parameters:
        avatar - The avatar to set.
      • setAvatar

        void setAvatar​(BufferedImage avatar,
                       String fileType)
        Queues the avatar of the connected account to get updated.
        Parameters:
        avatar - The avatar to set.
        fileType - The type of the avatar, e.g. "png" or "jpg".
      • setAvatar

        void setAvatar​(File avatar)
        Queues the avatar of the connected account to get updated.
        Parameters:
        avatar - The avatar to set.
      • setAvatar

        void setAvatar​(Icon avatar)
        Queues the avatar of the connected account to get updated.
        Parameters:
        avatar - The avatar to set.
      • setAvatar

        void setAvatar​(URL avatar)
        Queues the avatar of the connected account to get updated.
        Parameters:
        avatar - The avatar to set.
      • setAvatar

        void setAvatar​(byte[] avatar)
        Queues the avatar of the connected account to get updated. This method assumes the file type is "png"!
        Parameters:
        avatar - The avatar to set.
      • setAvatar

        void setAvatar​(byte[] avatar,
                       String fileType)
        Queues the avatar of the connected account to get updated.
        Parameters:
        avatar - The avatar to set.
        fileType - The type of the avatar, e.g. "png" or "jpg".
      • setAvatar

        void setAvatar​(InputStream avatar)
        Queues the avatar of the connected account to get updated. This method assumes the file type is "png"!
        Parameters:
        avatar - The avatar to set.
      • setAvatar

        void setAvatar​(InputStream avatar,
                       String fileType)
        Queues the avatar of the connected account to get updated.
        Parameters:
        avatar - The avatar to set.
        fileType - The type of the avatar, e.g. "png" or "jpg".
      • update

        CompletableFuture<Void> update​()
        Performs the queued updates.
        Returns:
        A future to check if the update was successful.