Correctly log how many prisoners were loaded.
This commit is contained in:
@ -154,6 +154,21 @@ public class JailManager {
|
||||
return this.jails.get(name) != null;
|
||||
}
|
||||
|
||||
/**
|
||||
* Gets all the prisoners in the system, best for a system wide count of the prisoners or accessing all the prisoners at once.
|
||||
*
|
||||
* @return HashSet of Prisoners.
|
||||
*/
|
||||
public HashSet<Prisoner> getAllPrisoners() {
|
||||
HashSet<Prisoner> prisoners = new HashSet<Prisoner>();
|
||||
|
||||
for(Jail j : jails.values()) {
|
||||
prisoners.addAll(j.getAllPrisoners());
|
||||
}
|
||||
|
||||
return prisoners;
|
||||
}
|
||||
|
||||
/**
|
||||
* Gets the {@link Jail jail} the given prisoner is in.
|
||||
*
|
||||
|
Reference in New Issue
Block a user