Class InlineQuery
- java.lang.Object
-
- io.micronaut.chatbots.telegram.api.InlineQuery
-
public class InlineQuery extends java.lang.ObjectThis object represents an incoming inline query. When the user sends an empty query, your bot could return some default or trending results.- Since:
- 1.0.0
- Author:
- Sergio del Amo
- See Also:
- InlineQuery
-
-
Constructor Summary
Constructors Constructor Description InlineQuery()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.StringgetChatType()UsergetFrom()java.lang.StringgetId()LocationgetLocation()java.lang.StringgetOffset()java.lang.StringgetQuery()voidsetChatType(java.lang.String chatType)voidsetFrom(User from)voidsetId(java.lang.String id)voidsetLocation(Location location)voidsetOffset(java.lang.String offset)voidsetQuery(java.lang.String query)java.lang.StringtoString()
-
-
-
Method Detail
-
getId
@NonNull public java.lang.String getId()
- Returns:
- Unique identifier for this query.
-
setId
public void setId(@NonNull java.lang.String id)- Parameters:
id- Unique identifier for this query.
-
getFrom
@NonNull public User getFrom()
- Returns:
- Sender.
-
setFrom
public void setFrom(@NonNull User from)- Parameters:
from- Sender.
-
getLocation
@Nullable public Location getLocation()
- Returns:
- Sender location, only for bots that request user location.
-
setLocation
public void setLocation(@Nullable Location location)- Parameters:
location- Sender location, only for bots that request user location.
-
getQuery
@NonNull public java.lang.String getQuery()
- Returns:
- Text of the query (up to 512 characters).
-
setQuery
public void setQuery(@NonNull java.lang.String query)- Parameters:
query- Text of the query (up to 512 characters).
-
getOffset
@NonNull public java.lang.String getOffset()
- Returns:
- Offset of the results to be returned, can be controlled by the bot.
-
setOffset
public void setOffset(@NonNull java.lang.String offset)- Parameters:
offset- Offset of the results to be returned, can be controlled by the bot.
-
getChatType
@Nullable public java.lang.String getChatType()
- Returns:
- Type of the chat from which the inline query was sent
-
setChatType
public void setChatType(@Nullable java.lang.String chatType)- Parameters:
chatType- Type of the chat from which the inline query was sent
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
-