org.telegram.api.update.TLUpdateChatParticipantAdd Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of telegramapi Show documentation
Show all versions of telegramapi Show documentation
Java library to create Telegram Clients
package org.telegram.api.update;
import org.telegram.tl.StreamingUtils;
import org.telegram.tl.TLContext;
import java.io.IOException;
import java.io.InputStream;
import java.io.OutputStream;
/**
* The type TL update chat participant add.
*/
public class TLUpdateChatParticipantAdd extends TLAbsUpdate {
/**
* The constant CLASS_ID.
*/
public static final int CLASS_ID = 0xea4b0e5c;
private int chatId;
private int userId;
private int inviterId;
private int date;
private int version;
/**
* Instantiates a new TL update chat participant add.
*/
public TLUpdateChatParticipantAdd() {
super();
}
public int getClassId() {
return CLASS_ID;
}
/**
* Gets chat id.
*
* @return the chat id
*/
public int getChatId() {
return this.chatId;
}
/**
* Sets chat id.
*
* @param chatId the chat id
*/
public void setChatId(int chatId) {
this.chatId = chatId;
}
/**
* Gets version.
*
* @return the version
*/
public int getVersion() {
return this.version;
}
/**
* Sets version.
*
* @param version the version
*/
public void setVersion(int version) {
this.version = version;
}
/**
* Gets inviter id.
*
* @return the inviter id
*/
public int getInviterId() {
return this.inviterId;
}
/**
* Sets inviter id.
*
* @param inviterId the inviter id
*/
public void setInviterId(int inviterId) {
this.inviterId = inviterId;
}
/**
* Gets user id.
*
* @return the user id
*/
public int getUserId() {
return this.userId;
}
/**
* Sets user id.
*
* @param userId the user id
*/
public void setUserId(int userId) {
this.userId = userId;
}
public int getDate() {
return date;
}
public void setDate(int date) {
this.date = date;
}
public void serializeBody(OutputStream stream)
throws IOException {
StreamingUtils.writeInt(this.chatId, stream);
StreamingUtils.writeInt(this.userId, stream);
StreamingUtils.writeInt(this.inviterId, stream);
StreamingUtils.writeInt(this.date, stream);
StreamingUtils.writeInt(this.version, stream);
}
public void deserializeBody(InputStream stream, TLContext context)
throws IOException {
this.chatId = StreamingUtils.readInt(stream);
this.userId = StreamingUtils.readInt(stream);
this.inviterId = StreamingUtils.readInt(stream);
this.date = StreamingUtils.readInt(stream);
this.version = StreamingUtils.readInt(stream);
}
public String toString() {
return "updateChatParticipantAdd#ea4b0e5c";
}
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy