Interface Updater

All Superinterfaces:
Manager
All Known Implementing Classes:
HangarUpdater

public interface Updater extends Manager

Updater

This interface represents a update manager, that tells server to update or not.
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
    Returns updates availability for OpenCreative+.
    Sends web request and checks if new updates of OpenCreative+ are available.

    Methods inherited from interface Manager

    getName, init, isEnabled
    Modifier and Type
    Method
    Description
    Returns name of manager, that will be displayed by request in the logs.
    void
    Initialization of manager.
    boolean
    Checks if manager is ready to work.
  • Method Details

    • checkUpdates

      CompletableFuture<String> checkUpdates()
      Sends web request and checks if new updates of OpenCreative+ are available. It's called once on plugin enable and on command usage.
    • canBeUpdated

      boolean canBeUpdated()
      Returns updates availability for OpenCreative+. It gets saved value from checkUpdates().
      Returns:
      true - if updates are available, false - if not.