Ignore:
Timestamp:
11/28/19 14:41:10 (5 years ago)
Author:
bart
Message:

Release 1.1.0

Location:
src/main/java/geniusweb/partiesserver/repository
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • src/main/java/geniusweb/partiesserver/repository/AvailablePartiesRepo.java

    r1 r8  
    1212 * Stores all currently available parties that can be run.
    1313 */
    14 public class AvailablePartiesRepo extends DefaultListenable<String> implements Repository<String, AvailableParty> {
     14public class AvailablePartiesRepo extends DefaultListenable<String>
     15                implements Repository<String, AvailableParty> {
    1516        private static final AvailablePartiesRepo instance = new AvailablePartiesRepo();
    1617
     
    3738        public void put(AvailableParty entity) {
    3839                availableParties.put(entity.getID(), entity);
    39                 notifyChange(entity.getID());
     40                notifyListeners(entity.getID());
    4041        }
    4142
     
    4344        public void remove(String id) {
    4445                availableParties.remove(id);
    45                 notifyChange(id);
     46                notifyListeners(id);
    4647        }
    4748
  • src/main/java/geniusweb/partiesserver/repository/RunningPartiesRepo.java

    r1 r8  
    7474                        runningParties.put(id, newParty);
    7575                }
    76                 notifyChange(id);
     76                notifyListeners(id);
    7777        }
    7878
     
    8787                        runningParties.put(id, newParty);
    8888                }
    89                 notifyChange(id);
     89                notifyListeners(id);
    9090
    9191        }
     
    125125                        }
    126126                }
    127                 notifyChange(id);
     127                notifyListeners(id);
    128128        }
    129129
  • src/main/java/geniusweb/partiesserver/repository/RunningParty.java

    r4 r8  
    99import com.fasterxml.jackson.annotation.JsonAutoDetect.Visibility;
    1010
    11 import geniusweb.actions.Action;
    1211import geniusweb.actions.PartyId;
    1312import geniusweb.connection.DefaultConnection;
    1413import geniusweb.partiesserver.RunningPartiesUpdater;
     14import geniusweb.partiesserver.websocket.PartySocket;
    1515import geniusweb.party.Party;
    1616import geniusweb.party.inform.Inform;
     
    4040         * set when someone contacts our socket. null if not set.
    4141         */
    42         private final transient DefaultConnection<Inform, Action> connection;
     42        private final transient PartySocket connection;
    4343
    4444        /**
     
    5858         */
    5959        protected RunningParty(Party party, PartyId id, String name, Date start,
    60                         Date end, DefaultConnection conn) {
     60                        Date end, PartySocket conn) {
    6161                if (party == null || id == null || name == null || start == null
    6262                                || end == null) {
     
    101101         * @param name         The name, this should match the filename in the repo
    102102         *                     (without the .jar).
    103          * @param maxRunTimeMS the maximum runtime for this party (ms). The {@link RunningPartiesUpdater}
    104          * will keep an eye on the time and handle removal after time is up.
     103         * @param maxRunTimeMS the maximum runtime for this party (ms). The
     104         *                     {@link RunningPartiesUpdater} will keep an eye on the
     105         *                     time and handle removal after time is up.
    105106         *
    106107         */
     
    212213         */
    213214        public void inform(Inform info) {
    214                 connection.notifyChange(info);
     215                connection.notifyListeners(info);
    215216        }
    216217
     
    223224         * @throws IllegalStateException if the party is already connected.
    224225         */
    225         public RunningParty withConnection(
    226                         DefaultConnection<Inform, Action> newconn) {
     226        public RunningParty withConnection(PartySocket newconn) {
    227227                if (newconn == null)
    228228                        throw new NullPointerException("newconn must be not null");
Note: See TracChangeset for help on using the changeset viewer.