Exemplo n.º 1
0
 /// <summary>
 /// Adds the elements of an array to the end of this LogColumnCollection.
 /// </summary>
 /// <param name="items">
 /// The array whose elements are to be added to the end of this LogColumnCollection.
 /// </param>
 public virtual void AddRange(LogColumn[] items)
 {
     foreach (LogColumn item in items)
     {
         this.List.Add(item);
     }
 }
Exemplo n.º 2
0
 /// <summary>
 /// Adds an instance of type LogColumn to the end of this LogColumnCollection.
 /// </summary>
 /// <param name="value">
 /// The LogColumn to be added to the end of this LogColumnCollection.
 /// </param>
 public virtual void Add(LogColumn value)
 {
     this.List.Add(value);
 }
Exemplo n.º 3
0
 /// <summary>
 /// Removes the first occurrence of a specific LogColumn from this LogColumnCollection.
 /// </summary>
 /// <param name="value">
 /// The LogColumn value to remove from this LogColumnCollection.
 /// </param>
 public virtual void Remove(LogColumn value)
 {
     this.List.Remove(value);
 }
Exemplo n.º 4
0
 /// <summary>
 /// Initializes a new instance of the LogColumnCollection class, containing elements
 /// copied from an array.
 /// </summary>
 /// <param name="items">
 /// The array whose elements are to be added to the new LogColumnCollection.
 /// </param>
 public LogColumnCollection(LogColumn[] items)
 {
     this.AddRange(items);
 }
Exemplo n.º 5
0
 /// <summary>
 /// Return the zero-based index of the first occurrence of a specific value
 /// in this LogColumnCollection
 /// </summary>
 /// <param name="value">
 /// The LogColumn value to locate in the LogColumnCollection.
 /// </param>
 /// <returns>
 /// The zero-based index of the first occurrence of the _ELEMENT value if found;
 /// -1 otherwise.
 /// </returns>
 public virtual int IndexOf(LogColumn value)
 {
     return this.List.IndexOf(value);
 }
Exemplo n.º 6
0
 /// <summary>
 /// Inserts an element into the LogColumnCollection at the specified index
 /// </summary>
 /// <param name="index">
 /// The index at which the LogColumn is to be inserted.
 /// </param>
 /// <param name="value">
 /// The LogColumn to insert.
 /// </param>
 public virtual void Insert(int index, LogColumn value)
 {
     this.List.Insert(index, value);
 }
Exemplo n.º 7
0
        public void ApplyGrouping(LogColumn column, object value)
        {
            GroupCache gc;
            if (!_grouping.ContainsKey(column.Ordinal))
            {
                gc = new GroupCache();

                TreeNode newRoot = new TreeNode();
                gc.RootNode = newRoot;
                newRoot.Text = column.Name;
                treeView.Nodes.Add(newRoot);
                _grouping[column.Ordinal] = gc;
            }
            else
            {
                gc = _grouping[column.Ordinal];
            }

            char separator = (char)0;

            switch (column.Grouping)
            {
                case LogColumnGrouping.Hierarchy:
                    separator = '.';
                    break;

                case LogColumnGrouping.FileSystem:
                    separator = Path.DirectorySeparatorChar;
                    break;
            }
            gc.LogEventAttributeToNode(Convert.ToString(value), gc.RootNode, separator);
        }
Exemplo n.º 8
0
 /// <summary>
 /// Determines whether a specfic LogColumn value is in this LogColumnCollection.
 /// </summary>
 /// <param name="value">
 /// The LogColumn value to locate in this LogColumnCollection.
 /// </param>
 /// <returns>
 /// true if value is found in this LogColumnCollection;
 /// false otherwise.
 /// </returns>
 public virtual bool Contains(LogColumn value)
 {
     return this.List.Contains(value);
 }
Exemplo n.º 9
0
 /// <summary>
 /// Determines whether a specfic LogColumn value is in this LogColumnCollection.
 /// </summary>
 /// <param name="value">
 /// The LogColumn value to locate in this LogColumnCollection.
 /// </param>
 /// <returns>
 /// true if value is found in this LogColumnCollection;
 /// false otherwise.
 /// </returns>
 public virtual bool Contains(LogColumn value)
 {
     return(this.List.Contains(value));
 }
Exemplo n.º 10
0
 /// <summary>
 /// Adds an instance of type LogColumn to the end of this LogColumnCollection.
 /// </summary>
 /// <param name="value">
 /// The LogColumn to be added to the end of this LogColumnCollection.
 /// </param>
 public virtual void Add(LogColumn value)
 {
     this.List.Add(value);
 }
Exemplo n.º 11
0
 /// <summary>
 /// Removes the first occurrence of a specific LogColumn from this LogColumnCollection.
 /// </summary>
 /// <param name="value">
 /// The LogColumn value to remove from this LogColumnCollection.
 /// </param>
 public virtual void Remove(LogColumn value)
 {
     this.List.Remove(value);
 }
Exemplo n.º 12
0
 /// <summary>
 /// Inserts an element into the LogColumnCollection at the specified index
 /// </summary>
 /// <param name="index">
 /// The index at which the LogColumn is to be inserted.
 /// </param>
 /// <param name="value">
 /// The LogColumn to insert.
 /// </param>
 public virtual void Insert(int index, LogColumn value)
 {
     this.List.Insert(index, value);
 }
Exemplo n.º 13
0
 /// <summary>
 /// Return the zero-based index of the first occurrence of a specific value
 /// in this LogColumnCollection
 /// </summary>
 /// <param name="value">
 /// The LogColumn value to locate in the LogColumnCollection.
 /// </param>
 /// <returns>
 /// The zero-based index of the first occurrence of the _ELEMENT value if found;
 /// -1 otherwise.
 /// </returns>
 public virtual int IndexOf(LogColumn value)
 {
     return(this.List.IndexOf(value));
 }