Package io.manebot.database.model
Class UserBan
- java.lang.Object
-
- io.manebot.database.model.TimedRow
-
- io.manebot.database.model.UserBan
-
-
Method Summary
Modifier and Type Method Description UsergetBanningUser()Gets the user that created this ban record, null if no reason was supplied.java.util.DategetDate()Gets the date that the ban was created.java.util.DategetEnd()Gets the date that the ban ends, null if there is no end.java.lang.StringgetReason()Gets the reason for the user being banned.UsergetUser()Gets the user that was banned.intgetUserBanId()inthashCode()booleanisPardoned()Finds if the ban has been pardoned.voidpardon()Pardons the ban.-
Methods inherited from class io.manebot.database.model.TimedRow
getCreated, getCreatedDate, getUpdated, getUpdatedDate, setCreated, setCreated, setCreatedDate, setUpdated, setUpdated, setUpdatedDate
-
-
-
-
Method Detail
-
getUserBanId
public int getUserBanId()
-
getUser
public User getUser()
Description copied from interface:UserBanGets the user that was banned.
-
getReason
public java.lang.String getReason()
Description copied from interface:UserBanGets the reason for the user being banned.
-
getBanningUser
public User getBanningUser()
Description copied from interface:UserBanGets the user that created this ban record, null if no reason was supplied.- Specified by:
getBanningUserin interfaceUserBan- Returns:
- ban reason.
-
getDate
public java.util.Date getDate()
Description copied from interface:UserBanGets the date that the ban was created.
-
getEnd
public java.util.Date getEnd()
Description copied from interface:UserBanGets the date that the ban ends, null if there is no end.
-
isPardoned
public boolean isPardoned()
Description copied from interface:UserBanFinds if the ban has been pardoned.- Specified by:
isPardonedin interfaceUserBan- Returns:
- true if the ban was pardoned, false otherwise.
-
pardon
public void pardon() throws java.lang.SecurityExceptionDescription copied from interface:UserBanPardons the ban.
-
hashCode
public int hashCode()
- Overrides:
hashCodein classjava.lang.Object
-
-