Package com.poker.web

Source Code of com.poker.web.MessageWebHandlers

package com.poker.web;

import java.util.List;

import com.britesnow.snow.web.handler.annotation.WebModelHandler;
import com.britesnow.snow.web.param.annotation.WebModel;
import com.britesnow.snow.web.param.annotation.WebParam;
import com.google.inject.Inject;
import com.poker.game.GameManager;
import com.poker.game.Message;
import com.poker.game.Table;

public class MessageWebHandlers {
    @Inject
        private GameManager gameManager;
    @WebModelHandler(startsWith = "/message/getMessage")
    public void getMessage(@WebModel List<Message> ls, @WebParam("room") String room) {
        Table table = gameManager.getTable(room);
        ls.addAll(table.getMessages());
    }
}
TOP

Related Classes of com.poker.web.MessageWebHandlers

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.