Enum Flag
- java.lang.Object
-
- java.lang.Enum<Flag>
-
- org.telegram.abilitybots.api.objects.Flag
-
- All Implemented Interfaces:
Serializable,Comparable<Flag>,Predicate<org.telegram.telegrambots.meta.api.objects.Update>
public enum Flag extends Enum<Flag> implements Predicate<org.telegram.telegrambots.meta.api.objects.Update>
Flags are an conditions that are applied on anUpdate.They can be used on
Ability.AbilityBuilder.flag(Predicate[])and on the post conditions inAbility.AbilityBuilder.reply(Consumer, Predicate[]).- Author:
- Abbas Abou Daya
-
-
Enum Constant Summary
Enum Constants Enum Constant Description CALLBACK_QUERYCAPTIONCHANNEL_POSTCHOSEN_INLINE_QUERYDOCUMENTEDITED_CHANNEL_POSTEDITED_MESSAGEINLINE_QUERYLOCATIONMESSAGENONEPHOTOPOLLPOLL_ANSWERPRECHECKOUT_QUERYREPLYSHIPPING_QUERYTEXT
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description booleantest(org.telegram.telegrambots.meta.api.objects.Update update)static FlagvalueOf(String name)Returns the enum constant of this type with the specified name.static Flag[]values()Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
NONE
public static final Flag NONE
-
MESSAGE
public static final Flag MESSAGE
-
CALLBACK_QUERY
public static final Flag CALLBACK_QUERY
-
CHANNEL_POST
public static final Flag CHANNEL_POST
-
EDITED_CHANNEL_POST
public static final Flag EDITED_CHANNEL_POST
-
EDITED_MESSAGE
public static final Flag EDITED_MESSAGE
-
INLINE_QUERY
public static final Flag INLINE_QUERY
-
CHOSEN_INLINE_QUERY
public static final Flag CHOSEN_INLINE_QUERY
-
SHIPPING_QUERY
public static final Flag SHIPPING_QUERY
-
PRECHECKOUT_QUERY
public static final Flag PRECHECKOUT_QUERY
-
POLL
public static final Flag POLL
-
POLL_ANSWER
public static final Flag POLL_ANSWER
-
REPLY
public static final Flag REPLY
-
DOCUMENT
public static final Flag DOCUMENT
-
TEXT
public static final Flag TEXT
-
PHOTO
public static final Flag PHOTO
-
LOCATION
public static final Flag LOCATION
-
CAPTION
public static final Flag CAPTION
-
-
Method Detail
-
values
public static Flag[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (Flag c : Flag.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static Flag valueOf(String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException- if this enum type has no constant with the specified nameNullPointerException- if the argument is null
-
-