/// <summary>standard typed insert method </summary> 
 public void Insert( int index, Match value )  
 {
     if (this.atomElement.ExtensionElements.Contains(value))
     {
         this.atomElement.ExtensionElements.Remove(value);
     }
     this.atomElement.ExtensionElements.Add(value);
     List.Insert( index, value );
 }
 /// <summary>standard typed Contains method </summary> 
 public bool Contains( Match value )  
 {
     // If value is not of type AtomEntry, this will return false.
     return( List.Contains( value ) );
 }
 /// <summary>standard typed remove method </summary> 
 public void Remove( Match value )  
 {
     this.atomElement.ExtensionElements.Remove(value);
     List.Remove( value );
 }
 /// <summary>standard typed indexOf method </summary> 
 public int IndexOf( Match value )  
 {
     return( List.IndexOf( value ) );
 }
 /// <summary>standard typed add method </summary> 
 public int Add( Match value )  
 {
     this.atomElement.ExtensionElements.Add(value); 
     return( List.Add( value ) );
 }
        //////////////////////////////////////////////////////////////////////
        /// <summary>Parses an xml node to create a Match object.</summary> 
        /// <param name="node">Match node</param>
        /// <param name="parser">AtomFeedParser to use</param>
        /// <returns>the created Match object</returns>
        //////////////////////////////////////////////////////////////////////
        public static Match ParseMatch(XmlNode node, AtomFeedParser parser)
        {
            Tracing.TraceCall();
            Match match = null;
            Tracing.Assert(node != null, "node should not be null");
            if (node == null)
            {
                throw new ArgumentNullException("node");
            }

            object localname = node.LocalName;
            // Ensure that the namespace is correct.
            if (String.Compare(node.NamespaceURI,
                GCodeSearchParserNameTable.CSNamespace, true) == 0)
            {
                if (localname.Equals(GCodeSearchParserNameTable.EVENT_MATCH))
                {
                    match = new Match();
                    if (node.Attributes != null)
                    {
                        match.linenumber =
                            node.Attributes[
                            GCodeSearchParserNameTable.ATTRIBUTE_LINE_NUMBER].Value;
                    }
                    match.linetext = node.InnerText;
                    }
                    else 
                    {
                        throw new ArgumentNullException(
                            BaseNameTable.gBatchNamespace +
                            ":" + GCodeSearchParserNameTable.EVENT_MATCH +
                            " must contain the attribute " +
                            GCodeSearchParserNameTable.ATTRIBUTE_LINE_NUMBER);
                    }
                }
            return match;
        }