public class ReadonlyAttachment
extends java.lang.Object
implements org.json.JSONString
| Constructor and Description |
|---|
ReadonlyAttachment(@NotNull java.lang.String url,
@NotNull java.lang.String proxyUrl,
@NotNull java.lang.String fileName,
int width,
int height,
int size,
long id) |
| Modifier and Type | Method and Description |
|---|---|
@NotNull java.lang.String |
getFileName()
The name of this attachment
|
int |
getHeight()
Height of the attachment, this is only relevant to images and videos
|
long |
getId()
The id of this attachment
|
@NotNull java.lang.String |
getProxyUrl()
The proxy url for this attachment, this is used by the client
to generate previews of images.
|
int |
getSize()
The approximated size of this embed in bytes
|
@NotNull java.lang.String |
getUrl()
The URL for this attachment
|
int |
getWidth()
Width of the attachment, this is only relevant to images and videos
|
java.lang.String |
toJSONString() |
java.lang.String |
toString()
JSON representation of this attachment
|
public ReadonlyAttachment(@NotNull
@NotNull java.lang.String url,
@NotNull
@NotNull java.lang.String proxyUrl,
@NotNull
@NotNull java.lang.String fileName,
int width,
int height,
int size,
long id)
@NotNull public @NotNull java.lang.String getUrl()
@NotNull @JSONPropertyName(value="proxy_url") public @NotNull java.lang.String getProxyUrl()
@NotNull @JSONPropertyName(value="filename") public @NotNull java.lang.String getFileName()
public int getSize()
public int getWidth()
public int getHeight()
public long getId()
public java.lang.String toString()
toString in class java.lang.Objectpublic java.lang.String toJSONString()
toJSONString in interface org.json.JSONString