BanEntry

public interface BanEntry

A single entry from ban list. This may represent either player ban or an IP ban.

Ban entries include the following properties:

Target Name / IP AddressThe target name or IP address
Creation DateThe creation date of the ban
SourceThe source of the ban, such as player, console, plugin, etc
Expiration DateThe expiration date of the ban
ReasonThe reason for the ban

Unsaved information is not automatically written to the implementation's ban list, instead, the save method must be called to write the changes to the ban list. If this ban entry has expired (such as from an unban) and is no longer found in the list, the save call will re-add it to the list, therefore banning the victim specified.

Likewise, changes to the associated BanList or other entries may or may not be reflected in this entry.

Functions

Link copied to clipboard
public abstract Date getCreated()
Gets the date this ban entry was created.
Link copied to clipboard
public abstract Date getExpiration()
Gets the date this ban expires on, or null for no defined end date.
Link copied to clipboard
public abstract String getReason()
Gets the reason for this ban.
Link copied to clipboard
public abstract String getSource()
Gets the source of this ban.
Link copied to clipboard
public abstract String getTarget()
Gets the target involved.
Link copied to clipboard
public abstract void save()
Saves the ban entry, overwriting any previous data in the ban list.
Link copied to clipboard
public abstract void setCreated(Date created)
Sets the date this ban entry was created.
Link copied to clipboard
public abstract void setExpiration(Date expiration)
Sets the date this ban expires on.
Link copied to clipboard
public abstract void setReason(String reason)
Sets the reason for this ban.
Link copied to clipboard
public abstract void setSource(String source)
Sets the source of this ban.