Created
April 8, 2013 03:11
-
-
Save KeepJ96/5333963 to your computer and use it in GitHub Desktop.
Backend Interface for IP-Check
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package net.risenphoenix.jnk.ipcheck; | |
import java.util.ArrayList; | |
/*** | |
* Main Interface for backend management. Contains all method declarations required by any and all Backend Managers for IP-Check. | |
*/ | |
public interface Backend { | |
/*** | |
* Performs any specified instructions required by the Backend Manager when IP-Check starts. | |
*/ | |
public void onLoad(); | |
/*** | |
* Performs any specified instructions required by the Backend Manager when IP-Check shuts down. | |
*/ | |
public void onDisable(); | |
/*** | |
* Loads Save File from hard-disk. | |
* @return save file as ArrayList. | |
*/ | |
public void loadFile(); | |
/*** | |
* Writes the save file for the Backend Manager to disk. | |
* @param current | |
*/ | |
public void saveFile(); | |
/*** | |
* Writes a User-Name/IP entry to an active copy of the Backend Manager's save-file. | |
* @param player | |
* @param ip | |
*/ | |
public void log(String player, String ip); | |
/*** | |
* Generates a blank save file on disk for use with the Backend Manager. | |
*/ | |
public void generateFile(); | |
/*** | |
* Scans the active copy of the Backend Manager's save file in order to detect alternate player accounts | |
* @param player | |
* @return ArrayList of player accounts. | |
*/ | |
public ArrayList<String> getAlts(String ip); | |
/*** | |
* Returns a list of banned IP addresses. | |
*/ | |
public ArrayList<String> getBannedList(); | |
/*** | |
* Checks if IP given is banned or not. | |
* @return true if IP is banned, return false if IP is not banned. | |
*/ | |
public boolean isBannedIP(String ip); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment