copyWith method

ReplyToCallbackQueryWithEphemeralMessage copyWith({
  1. int? callbackQueryId,
  2. bool? replaceCallbackQueryMessage,
  3. bool? protectContent,
  4. ReplyMarkup? replyMarkup()?,
  5. InputMessageContent? inputMessageContent,
})

Returns a copy with the given fields replaced. For a nullable field pass a function, e.g. field: () => null to clear it.

Implementation

ReplyToCallbackQueryWithEphemeralMessage copyWith({
  int? callbackQueryId,
  bool? replaceCallbackQueryMessage,
  bool? protectContent,
  ReplyMarkup? Function()? replyMarkup,
  InputMessageContent? inputMessageContent,
}) => ReplyToCallbackQueryWithEphemeralMessage(
  callbackQueryId: callbackQueryId ?? this.callbackQueryId,
  replaceCallbackQueryMessage:
      replaceCallbackQueryMessage ?? this.replaceCallbackQueryMessage,
  protectContent: protectContent ?? this.protectContent,
  replyMarkup: replyMarkup != null ? replyMarkup() : this.replyMarkup,
  inputMessageContent: inputMessageContent ?? this.inputMessageContent,
);