Class ConfigVoteSites

java.lang.Object
com.bencodez.advancedcore.api.yml.YMLFile
com.bencodez.votingplugin.config.ConfigVoteSites

public class ConfigVoteSites extends com.bencodez.advancedcore.api.yml.YMLFile
The Class ConfigVoteSites.
  • Constructor Details

  • Method Details

    • generateVoteSite

      public void generateVoteSite(String siteName)
      Generate vote site.
      Parameters:
      siteName - the site name
    • getData

      public org.bukkit.configuration.ConfigurationSection getData(String siteName)
      Gets the data.
      Parameters:
      siteName - the site name
      Returns:
      the data
    • getDisplayName

      public String getDisplayName(String site)
    • getEverySiteRewardPath

      public String getEverySiteRewardPath()
    • getItem

      public org.bukkit.configuration.ConfigurationSection getItem(String site)
    • getPriority

      public int getPriority(String siteName)
      Gets the priority.
      Parameters:
      siteName - the site name
      Returns:
      the priority
    • getRewardsPath

      public String getRewardsPath(String siteName)
      Gets the rewards.
      Parameters:
      siteName - the site name
      Returns:
      the rewards
    • getServiceSite

      public String getServiceSite(String siteName)
      Gets the service site.
      Parameters:
      siteName - the site name
      Returns:
      the service site
    • getVoteDelayDailyHour

      public int getVoteDelayDailyHour(String siteName)
    • getVoteDelay

      public double getVoteDelay(String siteName)
      Gets the vote delay.
      Parameters:
      siteName - the site name
      Returns:
      the vote delay
    • getVoteDelayMin

      public double getVoteDelayMin(String siteName)
    • getVoteSiteEnabled

      public boolean getVoteSiteEnabled(String siteName)
      Gets the vote site enabled.
      Parameters:
      siteName - the site name
      Returns:
      the vote site enabled
    • getVoteSiteFile

      public File getVoteSiteFile(String siteName)
      Gets the vote site file.
      Parameters:
      siteName - the site name
      Returns:
      the vote site file
    • getVoteSiteGiveOffline

      public boolean getVoteSiteGiveOffline(String site)
    • getVoteSiteHidden

      public boolean getVoteSiteHidden(String siteName)
    • getVoteSiteIgnoreCanVote

      public boolean getVoteSiteIgnoreCanVote(String siteName)
    • getVoteSiteResetVoteDelayDaily

      public boolean getVoteSiteResetVoteDelayDaily(String siteName)
    • getVoteSitesLoad

      public ArrayList<VoteSite> getVoteSitesLoad()
      Gets the vote sites load.
      Returns:
      the vote sites load
    • getVoteSitesNames

      public ArrayList<String> getVoteSitesNames(boolean checkEnabled)
    • getVoteURL

      public String getVoteURL(String siteName)
      Gets the vote URL.
      Parameters:
      siteName - the site name
      Returns:
      the vote URL
    • getWaitUntilVoteDelay

      public boolean getWaitUntilVoteDelay(String siteName)
    • isServiceSiteGood

      public boolean isServiceSiteGood(String siteName)
      Checks if is service site good.
      Parameters:
      siteName - the site name
      Returns:
      true, if is service site good
    • isVoteURLGood

      public boolean isVoteURLGood(String siteName)
      Checks if is vote URL good.
      Parameters:
      siteName - the site name
      Returns:
      true, if is vote URL good
    • onFileCreation

      public void onFileCreation()
      Specified by:
      onFileCreation in class com.bencodez.advancedcore.api.yml.YMLFile
    • renameVoteSite

      public boolean renameVoteSite(String siteName, String newName)
      Rename vote site.
      Parameters:
      siteName - the site name
      newName - the new name
      Returns:
      true, if successful
    • set

      public void set(String siteName, String path, Object value)
      Sets the.
      Parameters:
      siteName - the site name
      path - the path
      value - the value
    • setCumulativeRewards

      public void setCumulativeRewards(String siteName, ArrayList<String> value)
      Sets the cumulative rewards.
      Parameters:
      siteName - the site name
      value - the value
    • setCumulativeVotes

      public void setCumulativeVotes(String siteName, int value)
    • setDisplayName

      public void setDisplayName(String siteName, String value)
    • setEnabled

      public void setEnabled(String siteName, boolean disabled)
      Sets the enabled.
      Parameters:
      siteName - the site name
      disabled - the disabled
    • setForceOffline

      public void setForceOffline(String siteName, boolean value)
    • setPriority

      public void setPriority(String siteName, int value)
      Sets the priority.
      Parameters:
      siteName - the site name
      value - the value
    • setRewards

      public void setRewards(String siteName, ArrayList<String> value)
      Sets the rewards.
      Parameters:
      siteName - the site name
      value - the value
    • setServiceSite

      public void setServiceSite(String siteName, String serviceSite)
      Sets the service site.
      Parameters:
      siteName - the site name
      serviceSite - the service site
    • setVoteDelay

      public void setVoteDelay(String siteName, double voteDelay)
      Sets the vote delay.
      Parameters:
      siteName - the site name
      voteDelay - the vote delay
    • setVoteDelayDaily

      public void setVoteDelayDaily(String siteName, boolean value)
    • setVoteURL

      public void setVoteURL(String siteName, String url)
      Sets the vote URL.
      Parameters:
      siteName - the site name
      url - the url
    • siteCheck

      public boolean siteCheck(String siteName)
      Site check.
      Parameters:
      siteName - the site name
      Returns:
      true, if successful