forked from External/mage
* Draft - Added "Quit Tournament" button to draft panel. Minor formatting.
This commit is contained in:
parent
024ec1169a
commit
8d2f4cc9ac
26 changed files with 340 additions and 157 deletions
|
|
@ -46,7 +46,7 @@ public class DraftManager {
|
|||
|
||||
private DraftManager() {}
|
||||
|
||||
private ConcurrentHashMap<UUID, DraftController> draftControllers = new ConcurrentHashMap<UUID, DraftController>();
|
||||
private final ConcurrentHashMap<UUID, DraftController> draftControllers = new ConcurrentHashMap<>();
|
||||
|
||||
public UUID createDraftSession(Draft draft, ConcurrentHashMap<UUID, UUID> userPlayerMap, UUID tableId) {
|
||||
DraftController draftController = new DraftController(draft, userPlayerMap, tableId);
|
||||
|
|
@ -84,6 +84,10 @@ public class DraftManager {
|
|||
draftControllers.remove(draftId);
|
||||
}
|
||||
|
||||
public DraftController getControllerByDraftId(UUID draftId) {
|
||||
return draftControllers.get(draftId);
|
||||
}
|
||||
|
||||
public DraftController getController(UUID tableId) {
|
||||
for (DraftController controller: draftControllers.values()) {
|
||||
if (controller.getTableId().equals(tableId)) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue