Module tdlight.api
Package it.tdlight.jni

# Class TdApi.Animation

java.lang.Object
it.tdlight.jni.TdApi.Object
it.tdlight.jni.TdApi.Animation

Enclosing class:
  TdApi

public static final class TdApi.Animation extends TdApi.Object
Describes an animation file. The animation must be encoded in GIF or MPEG4 format.

## Field Summary

Fields
Modifier and Type
Field
Description
`TdApi.File`
`animation`
File containing the animation.
`static final int`
`CONSTRUCTOR`
`int`
`duration`
Duration of the animation, in seconds; as defined by the sender.
`String`
`fileName`
Original name of the file; as defined by the sender.
`boolean`
`hasStickers`
True, if stickers were added to the animation.
`int`
`height`
Height of the animation.
`String`
`mimeType`
MIME type of the file, usually "image/gif" or "video/mp4".
`TdApi.Minithumbnail`
`minithumbnail`
Animation minithumbnail; may be null.
`TdApi.Thumbnail`
`thumbnail`
Animation thumbnail in JPEG or MPEG4 format; may be null.
`int`
`width`
Width of the animation.

## Constructor Summary

Constructors
Constructor
Description
`Animation()`
Describes an animation file.
`Animation(int duration, int width, int height, String fileName, String mimeType, boolean hasStickers, TdApi.Minithumbnail minithumbnail, TdApi.Thumbnail thumbnail, TdApi.File animation)`
Describes an animation file.
`Animation(DataInput input)`
Describes an animation file.

## Method Summary

Modifier and Type
Method
Description
`boolean`
`equals(Object o)`
`int`
`getConstructor()`
`int`
`hashCode()`
`void`
`serialize(DataOutput output)`

### Methods inherited from class it.tdlight.jni.TdApi.Object

`serialize, toString`

### Methods inherited from class java.lang.Object

`clone, finalize, getClass, notify, notifyAll, wait, wait, wait`

## Field Details

### duration

public int duration
Duration of the animation, in seconds; as defined by the sender.

### width

public int width
Width of the animation.

### height

public int height
Height of the animation.

### fileName

public String fileName
Original name of the file; as defined by the sender.

### mimeType

public String mimeType
MIME type of the file, usually "image/gif" or "video/mp4".

### hasStickers

public boolean hasStickers
True, if stickers were added to the animation. The list of corresponding sticker set can be received using getAttachedStickerSets.

### minithumbnail

public TdApi.Minithumbnail minithumbnail
Animation minithumbnail; may be null.

### thumbnail

public TdApi.Thumbnail thumbnail
Animation thumbnail in JPEG or MPEG4 format; may be null.

### animation

public TdApi.File animation
File containing the animation.

### CONSTRUCTOR

public static final int CONSTRUCTOR

See Also:
  - Constant Field Values

## Constructor Details

### Animation

public Animation()
Describes an animation file. The animation must be encoded in GIF or MPEG4 format.

### Animation

public Animation(int duration, int width, int height, String fileName, String mimeType, boolean hasStickers, TdApi.Minithumbnail minithumbnail, TdApi.Thumbnail thumbnail, TdApi.File animation)
Describes an animation file. The animation must be encoded in GIF or MPEG4 format.

Parameters:
  `duration` - int Duration of the animation, in seconds; as defined by the sender.
  `width` - int Width of the animation.
  `height` - int Height of the animation.
  `fileName` - String Original name of the file; as defined by the sender.
  `mimeType` - String MIME type of the file, usually "image/gif" or "video/mp4".
  `hasStickers` - boolean True, if stickers were added to the animation. The list of corresponding sticker set can be received using getAttachedStickerSets.
  `minithumbnail` - Minithumbnail Animation minithumbnail; may be null.
  `thumbnail` - Thumbnail Animation thumbnail in JPEG or MPEG4 format; may be null.
  `animation` - File File containing the animation.

### Animation

public Animation(DataInput input) throws IOException
Describes an animation file. The animation must be encoded in GIF or MPEG4 format.

Throws:
  `IOException`

## Method Details

### getConstructor

public int getConstructor()

Specified by:
  `getConstructor` in class `TdApi.Object`

### serialize

public void serialize(DataOutput output) throws IOException

Specified by:
  `serialize` in class `TdApi.Object`
Throws:
  `IOException`

### equals

public boolean equals(Object o)

Overrides:
  `equals` in class `Object`

### hashCode

public int hashCode()

Overrides:
  `hashCode` in class `Object`