Interface AvatarManager

    • Method Detail

      • getAvatar

        AsyncResult<byte[]> getAvatar​(Jid contact)
        Gets the user avatar as byte array.
        Parameters:
        contact - The contact. Must not be null.
        Returns:
        The async result with the contact's avatar or null, if it has no avatar.
      • getAvatarImage

        AsyncResult<BufferedImage> getAvatarImage​(Jid contact)
        Gets the user avatar.
        Parameters:
        contact - The contact. Must not be null.
        Returns:
        The async result with the contact's avatar or null, if it has no avatar.
      • publishAvatar

        AsyncResult<Void> publishAvatar​(byte[] imageData)
        Publishes an avatar.
        Parameters:
        imageData - The avatar image data, which must be in PNG format. null resets the avatar.
        Returns:
        The async result.
      • publishAvatarImage

        AsyncResult<Void> publishAvatarImage​(BufferedImage bufferedImage)
                                      throws XmppException
        Publishes an avatar.
        Parameters:
        bufferedImage - The avatar image, which must be in PNG format. null resets the avatar.
        Returns:
        The async result.
        Throws:
        XmppException - If the image could not be converted to PNG.