Class ConfigFile

java.lang.Object
me.tayebyassine.homestead.resources.ResourceFile
me.tayebyassine.homestead.resources.files.ConfigFile

public final class ConfigFile extends ResourceFile
Typed accessor for config.yml.
  • Constructor Details

  • Method Details

    • getLanguageSetting

      public String getLanguageSetting()
      The active language locale code (e.g. "en-US").
      Returns:
      the language setting, defaults to "en-US"
    • getMenusSetting

      public String getMenusSetting()
      The active menus locale code (e.g. "en-US").
      Returns:
      the menus locale setting, defaults to "en-US"
    • isDebugEnabled

      public boolean isDebugEnabled()
      Whether the plugin debug mode is turned on.
      Returns:
      true if debug logging is enabled, defaults to false
    • isMetricsEnabled

      public boolean isMetricsEnabled()
      Whether anonymous usage statistics (bStats and FastStats) are enabled.
      Returns:
      true if metrics are enabled, defaults to true
    • getCacheInterval

      public int getCacheInterval()
      The interval (in minutes) between cache refreshes.
      Returns:
      cache interval in minutes, defaults to 30
    • getDatabaseProvider

      public String getDatabaseProvider()
      The database backend provider name.
      Returns:
      provider identifier, defaults to "sqlite"
    • regenerateChunksWithFAWE

      public boolean regenerateChunksWithFAWE()
      Whether FAWE chunk regeneration is enabled for region operations.
      Returns:
      true if FAWE regeneration is enabled, defaults to false
    • protectWorldGuardRegions

      public boolean protectWorldGuardRegions()
      Whether existing WorldGuard regions should be protected from claiming.
      Returns:
      true if WorldGuard protection is active, defaults to false
    • isDynamicMapsEnabled

      public boolean isDynamicMapsEnabled()
      Whether the dynamic maps feature is enabled.
      Returns:
      true if dynamic maps are enabled, defaults to false
    • getDynamicMapsUpdateInterval

      public int getDynamicMapsUpdateInterval()
      The interval (in seconds) for dynamic maps update.
      Returns:
      update interval in seconds, defaults to 60
    • isDynamicMapsIconsEnabled

      public boolean isDynamicMapsIconsEnabled()
      Whether custom map icons are enabled on dynamic maps.
      Returns:
      true if icons are enabled, defaults to false
    • getDynamicMapsIconsDefault

      public String getDynamicMapsIconsDefault()
      The key of the default map icon.
      Returns:
      default icon key, defaults to ""
    • getDynamicMapsIconKeys

      public List<String> getDynamicMapsIconKeys()
      The list of configured map icon keys.
      Returns:
      list of icon keys, never null
    • getDynamicMapsIconValue

      public String getDynamicMapsIconValue(String icon)
      The material or identifier for a specific map icon.
      Parameters:
      icon - the icon key
      Returns:
      the icon value, defaults to ""
    • isBlueMapUse2dMarkers

      public boolean isBlueMapUse2dMarkers()
      Whether BlueMap markers should render as 2D.
      Returns:
      true if 2D markers are used, defaults to false
    • isDiscordEnabled

      public boolean isDiscordEnabled()
      Whether the Discord webhook integration is enabled.
      Returns:
      true if Discord integration is on, defaults to false
    • getDiscordWebhookURL

      public String getDiscordWebhookURL()
      The Discord webhook URL for sending event notifications.
      Returns:
      the webhook URL string
    • isDiscordEventEnabled

      public boolean isDiscordEventEnabled(String eventName)
      Whether a specific Discord webhook event is enabled.
      Parameters:
      eventName - the event identifier (e.g. "region_create")
      Returns:
      true if the event webhook fires, defaults to false
    • getDiscordEventMessage

      public String getDiscordEventMessage(String eventName)
      The message template for a specific Discord webhook event.
      Parameters:
      eventName - the event identifier
      Returns:
      the message template, defaults to ""
    • getPlayerInputType

      public String getPlayerInputType()
      The player input type used for in-game prompts.
      Returns:
      the input type string, defaults to ""
    • getPlaceholderDefault

      public String getPlaceholderDefault(String key)
      The default value shown by a PlaceholderAPI placeholder when no region context is available.
      Parameters:
      key - the placeholder name (e.g. "region_bank")
      Returns:
      the default text, defaults to ""