public class PunishmentList extends Object
PunishmentInterface's. This is required because of the way the API is structured
There is no need for the user of this API to use this class, it is simply used to make
converting a list of punishments to a list of PunishmentInterface's easier| Constructor and Description |
|---|
PunishmentList()
Setup the list
|
| Modifier and Type | Method and Description |
|---|---|
void |
add(PunishmentInterface punishment)
Add a
PunishmentInterface to the list |
void |
addAll(Collection<PunishmentInterface> punishments)
Add multiple vales at once
|
PunishmentInterface |
get(Integer index)
Get the punishment at any index
|
List<PunishmentInterface> |
getAsList()
Get the
PunishmentInterface's currently stored as a List |
void |
remove(PunishmentInterface punishment)
Remove a
PunishmentInterface from the list |
Integer |
size()
Get the number of items currently in the list
|
public Integer size()
public PunishmentInterface get(Integer index)
index - The index you wish to fetchPunishmentInterface at the index providedpublic void add(PunishmentInterface punishment)
PunishmentInterface to the listpunishment - The punishment you wish to addpublic void addAll(Collection<PunishmentInterface> punishments)
punishments - The collection of PunishmentInterface's you wish to addpublic void remove(PunishmentInterface punishment)
PunishmentInterface from the listpunishment - the punishment you wish to removepublic List<PunishmentInterface> getAsList()
PunishmentInterface's currently stored as a ListCopyright © 2019. All rights reserved.