public class

ImageRepresentation

extends Object
implements Parcelable
java.lang.Object
   ↳ com.nexmo.sdk.conversation.client.ImageRepresentation

Class Overview

Each image representation can be defined by type: ImageRepresentation.TYPE.

Summary

Nested Classes
enum ImageRepresentation.TYPE  
[Expand]
Inherited Constants
From interface android.os.Parcelable
Fields
public static final Creator<ImageRepresentation> CREATOR
public ImageRepresentation.TYPE type
Protected Constructors
ImageRepresentation(ImageRepresentation.TYPE type, String id, String url, long size, String localFilePath)
ImageRepresentation(Parcel in)
Public Methods
int describeContents()
boolean equals(Object o)
Bitmap getBitmap()
If image representation was downloaded, the bitmap can be used to update UI.
String getLocalFilePath()
long getSize()
String getUrl()
Get the Image representation url.
int hashCode()
String toString()
void writeToParcel(Parcel dest, int flags)
[Expand]
Inherited Methods
From class java.lang.Object
From interface android.os.Parcelable

Fields

public static final Creator<ImageRepresentation> CREATOR

Protected Constructors

protected ImageRepresentation (ImageRepresentation.TYPE type, String id, String url, long size, String localFilePath)

protected ImageRepresentation (Parcel in)

Public Methods

public int describeContents ()

public boolean equals (Object o)

public Bitmap getBitmap ()

If image representation was downloaded, the bitmap can be used to update UI.

Returns
  • The bitmap of the image representation.

public String getLocalFilePath ()

public long getSize ()

public String getUrl ()

Get the Image representation url.

Image can be downloaded explicitly via

  • <download(TYPE, RequestHandler) that uses okhttp3 library under the hood.
  • Alternatively, download from this link using an http library of your own choosing. Attach mandatory Nexmo custom authorization headers to your request in order to download: ipsHeaders()

Returns
  • The image representation url.

public int hashCode ()

public String toString ()

public void writeToParcel (Parcel dest, int flags)