예제 #1
0
    public void changeTableStatus(int tableId, Table.State newStatus)
    {
        Table table = tables.Find(t => t.Id.Equals(tableId));

        table.StateProperty = newStatus;
        NotifyClients(Operation.Changed_Table_State, null, tableId);
    }
예제 #2
0
    public List <Table> getTables(Table.State state)
    {
        Console.WriteLine("getTables() called.");
        List <Table> res = new List <Table>();

        foreach (Table table in tables)
        {
            if (table.StateProperty.Equals(state))
            {
                res.Add(table);
            }
        }
        return(res);
    }
예제 #3
0
파일: Table.cs 프로젝트: bernardoleite/TDIN
 public Table(int id, Table.State state)
 {
     this.Id            = id;
     this.StateProperty = state;
 }