map<TResult extends Object?> method
TResult
map<TResult extends Object?>({
- required TResult allowCalls(),
- required TResult allowChatInvites(),
- required TResult allowFindingByPhoneNumber(),
- required TResult allowPeerToPeerCalls(),
- required TResult allowPrivateVoiceAndVideoNoteMessages(),
- required TResult allowUnpaidMessages(),
- required TResult autosaveGifts(),
- required TResult showBio(),
- required TResult showBirthdate(),
- required TResult showLinkInForwardedMessages(),
- required TResult showPhoneNumber(),
- required TResult showProfileAudio(),
- required TResult showProfilePhoto(),
- required TResult showStatus(),
Implementation
TResult map<TResult extends Object?>({
required TResult Function(UserPrivacySettingAllowCalls value) allowCalls,
required TResult Function(UserPrivacySettingAllowChatInvites value)
allowChatInvites,
required TResult Function(UserPrivacySettingAllowFindingByPhoneNumber value)
allowFindingByPhoneNumber,
required TResult Function(UserPrivacySettingAllowPeerToPeerCalls value)
allowPeerToPeerCalls,
required TResult Function(
UserPrivacySettingAllowPrivateVoiceAndVideoNoteMessages value,
)
allowPrivateVoiceAndVideoNoteMessages,
required TResult Function(UserPrivacySettingAllowUnpaidMessages value)
allowUnpaidMessages,
required TResult Function(UserPrivacySettingAutosaveGifts value)
autosaveGifts,
required TResult Function(UserPrivacySettingShowBio value) showBio,
required TResult Function(UserPrivacySettingShowBirthdate value)
showBirthdate,
required TResult Function(
UserPrivacySettingShowLinkInForwardedMessages value,
)
showLinkInForwardedMessages,
required TResult Function(UserPrivacySettingShowPhoneNumber value)
showPhoneNumber,
required TResult Function(UserPrivacySettingShowProfileAudio value)
showProfileAudio,
required TResult Function(UserPrivacySettingShowProfilePhoto value)
showProfilePhoto,
required TResult Function(UserPrivacySettingShowStatus value) showStatus,
}) {
switch (getConstructor()) {
case UserPrivacySettingAllowCalls.constructor:
return allowCalls.call(this as UserPrivacySettingAllowCalls);
case UserPrivacySettingAllowChatInvites.constructor:
return allowChatInvites.call(
this as UserPrivacySettingAllowChatInvites,
);
case UserPrivacySettingAllowFindingByPhoneNumber.constructor:
return allowFindingByPhoneNumber.call(
this as UserPrivacySettingAllowFindingByPhoneNumber,
);
case UserPrivacySettingAllowPeerToPeerCalls.constructor:
return allowPeerToPeerCalls.call(
this as UserPrivacySettingAllowPeerToPeerCalls,
);
case UserPrivacySettingAllowPrivateVoiceAndVideoNoteMessages.constructor:
return allowPrivateVoiceAndVideoNoteMessages.call(
this as UserPrivacySettingAllowPrivateVoiceAndVideoNoteMessages,
);
case UserPrivacySettingAllowUnpaidMessages.constructor:
return allowUnpaidMessages.call(
this as UserPrivacySettingAllowUnpaidMessages,
);
case UserPrivacySettingAutosaveGifts.constructor:
return autosaveGifts.call(this as UserPrivacySettingAutosaveGifts);
case UserPrivacySettingShowBio.constructor:
return showBio.call(this as UserPrivacySettingShowBio);
case UserPrivacySettingShowBirthdate.constructor:
return showBirthdate.call(this as UserPrivacySettingShowBirthdate);
case UserPrivacySettingShowLinkInForwardedMessages.constructor:
return showLinkInForwardedMessages.call(
this as UserPrivacySettingShowLinkInForwardedMessages,
);
case UserPrivacySettingShowPhoneNumber.constructor:
return showPhoneNumber.call(this as UserPrivacySettingShowPhoneNumber);
case UserPrivacySettingShowProfileAudio.constructor:
return showProfileAudio.call(
this as UserPrivacySettingShowProfileAudio,
);
case UserPrivacySettingShowProfilePhoto.constructor:
return showProfilePhoto.call(
this as UserPrivacySettingShowProfilePhoto,
);
case UserPrivacySettingShowStatus.constructor:
return showStatus.call(this as UserPrivacySettingShowStatus);
}
throw StateError('not handled type Generator');
}