public void dragCard(String ID, int newx, int newy) {
        for (Object e : table.getComponents()) {
            if ((e.getClass().equals(TCard.class)
                    || e.getClass().equals(Token.class))
                    &&((TCard) e).getID().equals(ID)) {
                ((TCard) e).setCardPosition(newx, newy);
                break;
            }
        }
    }