Package com.pengrad.telegrambot.request
Class SetMyCommands
- java.lang.Object
-
- com.pengrad.telegrambot.request.BaseRequest<SetMyCommands,BaseResponse>
-
- com.pengrad.telegrambot.request.SetMyCommands
-
public class SetMyCommands extends BaseRequest<SetMyCommands,BaseResponse>
Stas Parshin 31 March 2020
-
-
Field Summary
-
Fields inherited from class com.pengrad.telegrambot.request.BaseRequest
thisAsT
-
-
Constructor Summary
Constructors Constructor Description SetMyCommands(BotCommand... commands)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description SetMyCommands
languageCode(java.lang.String languageCode)
SetMyCommands
scope(BotCommandScope scope)
-
Methods inherited from class com.pengrad.telegrambot.request.BaseRequest
add, addAll, getContentType, getFileName, getMethod, getParameters, getResponseType, getTimeoutSeconds, isMultipart, toWebhookResponse
-
-
-
-
Constructor Detail
-
SetMyCommands
public SetMyCommands(BotCommand... commands)
-
-
Method Detail
-
scope
public SetMyCommands scope(BotCommandScope scope)
- Parameters:
scope
- An object that extends the BotCommandScope class. For example: new BotCommandScopeAllPrivateChats()- Returns:
-
languageCode
public SetMyCommands languageCode(java.lang.String languageCode)
- Parameters:
languageCode
- A two-letter ISO 639-1 language code. If empty, commands will be applied to all users from the given scope, for whose language there are no dedicated commands- Returns:
-
-