private void ChooseColumnsDialog_Load(object sender, EventArgs e)
        {
            LogColumnCollection lcc = new LogColumnCollection();

            foreach (LogColumn lc in Session.Columns)
            {
                lcc.Add(lc.Clone());
            }

            _lcc = lcc;

            dataGridView1.DataSource = lcc;
        }
示例#2
0
        public void Resolve()
        {
            if (Columns.Count == 0)
            {
                Columns.Add(new LogColumn("ID", 120));
                Columns.Add(new LogColumn("Received Time", 120, true));
            }

            // initialize the ordinals
            for (int i = 0; i < Columns.Count; ++i)
            {
                Columns[i].Ordinal = i;
            }

            _columnOrdinalID           = GetOrAllocateOrdinal("ID");
            _columnOrdinalReceivedDate = GetOrAllocateOrdinal("Received Time");
            _columnOrdinalLevel        = GetOrAllocateOrdinal("Level");

            _bufferedEvents = new CyclicBuffer <LogEvent>(MaxLogEntries);
            NewSortOrder();
            Receiver.Connect(this);
        }