Пример #1
0
        public void Load(string path)
        {
            TableBuffer document = new TableBuffer(path);

            document.Load();
            for (int index = 0; index < document.RowCnt; index++)
            {
                TableRowBuffer node = document.GetRowBuffer(index);
                try {
                    TData data = new TData();
                    data.Load(node);
                    Add(data);
                } catch (System.Exception ex) {
                    GameLog.Error("ITable load file({0}) row(1) failed.Exception:{2}\n{3}",
                                  path, node.Idx, ex.Message, ex.StackTrace);
                }
            }
            OnLoadTable();
            GameLog.Info("ITable load file({0}) done.", path);
        }
Пример #2
0
 public TableRowBuffer(TableBuffer buffer, int idx)
 {
     _idx    = idx;
     _data   = new List <string>();
     _buffer = buffer;
 }