PhoneGroupParticipants.deserialize constructor

PhoneGroupParticipants.deserialize(
  1. BinaryReader reader
)

Deserialize.

Implementation

factory PhoneGroupParticipants.deserialize(BinaryReader reader) {
  // Read [PhoneGroupParticipants] fields.
  final count = reader.readInt32();
  final participants = reader.readVectorObject<GroupCallParticipantBase>();
  final nextOffset = reader.readString();
  final chats = reader.readVectorObject<ChatBase>();
  final users = reader.readVectorObject<UserBase>();
  final version = reader.readInt32();

  // Construct [PhoneGroupParticipants] object.
  final returnValue = PhoneGroupParticipants(
    count: count,
    participants: participants,
    nextOffset: nextOffset,
    chats: chats,
    users: users,
    version: version,
  );

  // Now return the deserialized [PhoneGroupParticipants].
  return returnValue;
}