2 // System.Web.Services.Protocols.SoapHeaderCollection.cs
\r
5 // Tim Coleman (tim@timcoleman.com)
\r
7 // Copyright (C) Tim Coleman, 2002
\r
10 using System.Collections;
\r
12 namespace System.Web.Services.Protocols {
\r
13 public class SoapHeaderCollection : CollectionBase {
\r
15 #region Constructors
\r
17 public SoapHeaderCollection ()
\r
25 public SoapHeader this [int index] {
\r
26 get { return (SoapHeader) List[index]; }
\r
27 set { List[index] = value; }
\r
30 #endregion // Properties
\r
34 public int Add (SoapHeader header)
\r
36 Insert (Count, header);
\r
40 public bool Contains (SoapHeader header)
\r
42 return List.Contains (header);
\r
45 public void CopyTo (SoapHeader[] array, int index)
\r
47 List.CopyTo (array, index);
\r
50 public void Insert (int index, SoapHeader header)
\r
52 if (index < 0 || index > Count)
\r
53 throw new ArgumentOutOfRangeException ();
\r
54 List.Insert (index, header);
\r
57 public void Remove (SoapHeader header)
\r
59 List.Remove (header);
\r
62 #endregion // Methods
\r