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

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

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

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

/**
 * This toggle can be used as-is to turn off ALL the default abilities supplied by the library.
 * This is for users who are interested in the barebone functionality of AbilityBot.
 */
public class BareboneToggle implements AbilityToggle {
  @Override
  public boolean isOff(Ability ability) {
    return true;
  }

  @Override
  public Ability processAbility(Ability ab) {
    // Should never hit this
    throw new RuntimeException("Should not process any ability in a vanilla toggle");
  }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy