copyWith method

ChatPermissions copyWith({
  1. bool? canSendBasicMessages,
  2. bool? canSendAudios,
  3. bool? canSendDocuments,
  4. bool? canSendPhotos,
  5. bool? canSendVideos,
  6. bool? canSendVideoNotes,
  7. bool? canSendVoiceNotes,
  8. bool? canSendPolls,
  9. bool? canSendOtherMessages,
  10. bool? canAddWebPagePreviews,
  11. bool? canChangeInfo,
  12. bool? canInviteUsers,
  13. bool? canPinMessages,
  14. bool? canManageTopics,
})

Implementation

ChatPermissions copyWith({
  bool? canSendBasicMessages,
  bool? canSendAudios,
  bool? canSendDocuments,
  bool? canSendPhotos,
  bool? canSendVideos,
  bool? canSendVideoNotes,
  bool? canSendVoiceNotes,
  bool? canSendPolls,
  bool? canSendOtherMessages,
  bool? canAddWebPagePreviews,
  bool? canChangeInfo,
  bool? canInviteUsers,
  bool? canPinMessages,
  bool? canManageTopics,
}) =>
    ChatPermissions(
      canSendBasicMessages: canSendBasicMessages ?? this.canSendBasicMessages,
      canSendAudios: canSendAudios ?? this.canSendAudios,
      canSendDocuments: canSendDocuments ?? this.canSendDocuments,
      canSendPhotos: canSendPhotos ?? this.canSendPhotos,
      canSendVideos: canSendVideos ?? this.canSendVideos,
      canSendVideoNotes: canSendVideoNotes ?? this.canSendVideoNotes,
      canSendVoiceNotes: canSendVoiceNotes ?? this.canSendVoiceNotes,
      canSendPolls: canSendPolls ?? this.canSendPolls,
      canSendOtherMessages: canSendOtherMessages ?? this.canSendOtherMessages,
      canAddWebPagePreviews:
          canAddWebPagePreviews ?? this.canAddWebPagePreviews,
      canChangeInfo: canChangeInfo ?? this.canChangeInfo,
      canInviteUsers: canInviteUsers ?? this.canInviteUsers,
      canPinMessages: canPinMessages ?? this.canPinMessages,
      canManageTopics: canManageTopics ?? this.canManageTopics,
    );