All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.telegram.telegrambots.abilitybots.api.toggle.AbilityToggle Maven / Gradle / Ivy

There is a newer version: 8.0.0
Show newest version
package org.telegram.telegrambots.abilitybots.api.toggle;

import org.telegram.telegrambots.abilitybots.api.objects.Ability;

/**
 * This interface can be used to toggle or customize unwanted default abilities by the user.
 */
public interface AbilityToggle {
  /**
   * @param ab the target ability
   * @return true if the ability has been turned off
   */
  boolean isOff(Ability ab);

  /**
   * Abilities that are ON (and have failed the {@link AbilityToggle#isOff} condition) will be processed by this method.
   * @param ab the target ability
   * @return the processed ability
   */
  Ability processAbility(Ability ab);
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy