Interface KarmaSource

All Superinterfaces:
Serializable
All Known Implementing Classes:
APISource

public interface KarmaSource extends Serializable
Karma API source
  • Method Details

    • name

      String name()
      Karma source name
      Returns:
      the source name
    • version

      String version()
      Karma source version
      Returns:
      the source version
    • description

      String description()
      Karma source description
      Returns:
      the source description
    • authors

      String[] authors()
      Karma source authors
      Returns:
      the source authors
    • updateURL

      String updateURL()
      Karma source update URL
      Returns:
      the source update URL
    • stopTasks

      default void stopTasks()
      Stop all the source tasks
    • authors

      default String authors(boolean firstSeparator, String separator)
      Get the authors using a custom separator
      Parameters:
      firstSeparator - if the first object should have separator
      separator - the separator
      Returns:
      the authors using the separator options
    • getSourceFile

      default File getSourceFile()
      Get the source file
      Returns:
      the source file
    • getDataPath

      default Path getDataPath()
      Get the source data path
      Returns:
      the source data path
    • isSource

      default boolean isSource(KarmaSource source)
      Get if the source is an instance of this
      Parameters:
      source - the source
      Returns:
      if the source is this source
    • console

      default Console console()
      Get the source out
      Returns:
      the source out
    • async

      default Scheduler async()
      Get the source async scheduler
      Returns:
      the source async scheduler
    • sync

      default Scheduler sync()
      Get the source sync scheduler
      Returns:
      the source sync scheduler
    • srcEquals

      default boolean srcEquals(KarmaSource dst)
      Returns if the specified source is the same as this one
      Parameters:
      dst - the source to check with
      Returns:
      if the source is the same as this