Skip to content

Commit 669c0fc

Browse files
author
Prashanth Govindarajan
committed
Address comments
1 parent 840f26f commit 669c0fc

File tree

3 files changed

+57
-244
lines changed

3 files changed

+57
-244
lines changed

xml/System.Text.RegularExpressions/CaptureCollection.xml

Lines changed: 24 additions & 93 deletions
Original file line numberDiff line numberDiff line change
@@ -575,7 +575,7 @@ A collection that is read-only does not allow the addition or removal of element
575575
</ReturnValue>
576576
<Parameters />
577577
<Docs>
578-
<summary>Removes all items from the collection.</summary>
578+
<summary>Calling this method always throws <see cref="T:System.NotSupportedException" />.</summary>
579579
<exception cref="T:System.NotSupportedException">The collection is read-only.</exception>
580580
<remarks>To be added.</remarks>
581581
</Docs>
@@ -652,19 +652,10 @@ A collection that is read-only does not allow the addition or removal of element
652652
</Parameters>
653653
<Docs>
654654
<param name="item">The object to remove from the collection.</param>
655-
<summary>Removes the first occurrence of a specific object from the collection.</summary>
655+
<summary>Calling this method always throws <see cref="T:System.NotSupportedException" />.</summary>
656656
<exception cref="T:System.NotSupportedException">The collection is read-only.</exception>
657-
<returns>
658-
<see langword="true" /> if <paramref name="item" /> was successfully removed from the collection; otherwise, <see langword="false" />. This method also returns <see langword="false" /> if <paramref name="item" /> is not found in the original collection.</returns>
659-
<remarks>
660-
<format type="text/markdown"><![CDATA[
661-
662-
## Remarks
663-
664-
This method is not supported. This is a read-only collection.
665-
666-
]]></format>
667-
</remarks>
657+
<returns>Calling this method always throws <see cref="T:System.NotSupportedException" />.</returns>
658+
<remarks>To be added.</remarks>
668659
</Docs>
669660
</Member>
670661
<Member MemberName="System.Collections.Generic.IEnumerable&lt;System.Text.RegularExpressions.Capture&gt;.GetEnumerator">
@@ -796,17 +787,9 @@ If an object occurs multiple times in the list, the <xref:System.Collections.Gen
796787
<Docs>
797788
<param name="index">The zero-based index at which <paramref name="item" /> should be inserted.</param>
798789
<param name="item">The object to insert into the collection.</param>
799-
<summary>Inserts an item to the collection at the specified index.</summary>
790+
<summary>Calling this method always throws <see cref="T:System.NotSupportedException" />.</summary>
800791
<exception cref="T:System.NotSupportedException">The collection is read-only.</exception>
801-
<remarks>
802-
<format type="text/markdown"><![CDATA[
803-
804-
## Remarks
805-
806-
This method is not supported. This is a read-only collection.
807-
808-
]]></format>
809-
</remarks>
792+
<remarks>To be added.</remarks>
810793
</Docs>
811794
</Member>
812795
<Member MemberName="System.Collections.Generic.IList&lt;System.Text.RegularExpressions.Capture&gt;.Item">
@@ -842,7 +825,7 @@ This method is not supported. This is a read-only collection.
842825
</Parameters>
843826
<Docs>
844827
<param name="index">The zero-based index of the element to get or set.</param>
845-
<summary>Gets or sets the element at the specified index.</summary>
828+
<summary>Gets the element at the specified index.</summary>
846829
<value>The element at the specified index.</value>
847830
<remarks>
848831
<format type="text/markdown"><![CDATA[
@@ -889,17 +872,9 @@ This property provides the ability to access a specific element in the collectio
889872
</Parameters>
890873
<Docs>
891874
<param name="index">The zero-based index of the item to remove.</param>
892-
<summary>Removes the collection item at the specified index.</summary>
875+
<summary>Calling this method always throws <see cref="T:System.NotSupportedException" />.</summary>
893876
<exception cref="T:System.NotSupportedException">The collection is read-only.</exception>
894-
<remarks>
895-
<format type="text/markdown"><![CDATA[
896-
897-
## Remarks
898-
899-
This method is not supported. This is a read-only collection.
900-
901-
]]></format>
902-
</remarks>
877+
<remarks>To be added.</remarks>
903878
</Docs>
904879
</Member>
905880
<Member MemberName="System.Collections.ICollection.CopyTo">
@@ -973,21 +948,15 @@ This method is not supported. This is a read-only collection.
973948
</ReturnValue>
974949
<Docs>
975950
<summary>Gets a value that indicates whether access to the collection is synchronized (thread-safe).</summary>
976-
<value>false in all cases.</value>
951+
<value><see langword='false' /> in all cases.</value>
977952
<remarks>
978953
<format type="text/markdown"><![CDATA[
979954
980955
## Remarks
981956
982957
This member is an explicit interface member implementation. It can be used only when the <xref:System.Text.RegularExpressions.CaptureCollection> instance is cast to an <xref:System.Collections.ICollection> interface.
983958
984-
985-
986-
<xref:System.Collections.ICollection.SyncRoot%2A> returns an object, which can be used to synchronize access to the <xref:System.Collections.ICollection>.
987-
Most collection classes in the <xref:System.Collections?displayProperty=nameWithType> namespace also implement a Synchronized method, which provides a synchronized wrapper around the underlying collection.
988-
Enumerating through a collection is intrinsically not a thread-safe procedure. Even when a collection is synchronized, other threads can still modify the collection, which causes the enumerator to throw an exception. To guarantee thread safety during enumeration, you can either lock the collection during the entire enumeration or catch the exceptions resulting from changes made by other threads.
989-
990-
]]></format>
959+
]]></format>
991960
</remarks>
992961
</Docs>
993962
</Member>
@@ -1028,12 +997,6 @@ This member is an explicit interface member implementation. It can be used only
1028997
1029998
This member is an explicit interface member implementation. It can be used only when the <xref:System.Text.RegularExpressions.CaptureCollection> instance is cast to an <xref:System.Collections.ICollection> interface.
1030999
1031-
1032-
1033-
For collections whose underlying store is not publicly available, the expected implementation is to return the current instance. Note that the pointer to the current instance might not be sufficient for collections that wrap other collections; those should return the underlying collection's `SyncRoot` property.
1034-
Most collection classes in the <xref:System.Collections?displayProperty=nameWithType> namespace also implement a `Synchronized` method, which provides a synchronized wrapper around the underlying collection. However, derived classes can provide their own synchronized version of the collection using the <xref:System.Collections.ICollection.SyncRoot%2A> property. The synchronizing code must perform operations on the <xref:System.Collections.ICollection.SyncRoot%2A> property of the collection, not directly on the collection. This ensures proper operation of collections that are derived from other objects. Specifically, it maintains proper synchronization with other threads that might be simultaneously modifying the collection instance.
1035-
Enumerating through a collection is intrinsically not a thread-safe procedure. Even when a collection is synchronized, other threads can still modify the collection, which causes the enumerator to throw an exception. To guarantee thread safety during enumeration, you can either lock the collection during the entire enumeration or catch the exceptions resulting from changes made by other threads.
1036-
10371000
]]></format>
10381001
</remarks>
10391002
</Docs>
@@ -1071,8 +1034,8 @@ This member is an explicit interface member implementation. It can be used only
10711034
</Parameters>
10721035
<Docs>
10731036
<param name="value">The object to add to the collection.</param>
1074-
<summary>Adds an item to the collection.</summary>
1075-
<returns>The position into which the new element was inserted, or -1 to indicate that the item was not inserted into the collection.</returns>
1037+
<summary>Calling this method always throws <see cref="T:System.NotSupportedException" />.</summary>
1038+
<returns>Calling this method always throws <see cref="T:System.NotSupportedException" />.</returns>
10761039
<exception cref="T:System.NotSupportedException">The collection is read-only.</exception>
10771040
<remarks>To be added.</remarks>
10781041
</Docs>
@@ -1107,18 +1070,10 @@ This member is an explicit interface member implementation. It can be used only
11071070
</ReturnValue>
11081071
<Parameters />
11091072
<Docs>
1110-
<summary>Removes all items from the collection.</summary>
1073+
<summary>Calling this method always throws <see cref="T:System.NotSupportedException" />.</summary>
11111074
<exception cref="T:System.NotSupportedException">The collection is read-only.</exception>
1112-
<remarks>
1113-
<format type="text/markdown"><![CDATA[
1114-
1115-
## Remarks
1116-
1117-
This method is not supported. This is a read-only collection.
1118-
1119-
]]></format>
1120-
</remarks>
1121-
</Docs>
1075+
<remarks>To be added.</remarks>
1076+
</Docs>
11221077
</Member>
11231078
<Member MemberName="System.Collections.IList.Contains">
11241079
<MemberSignature Language="C#" Value="bool IList.Contains (object value);" />
@@ -1248,18 +1203,10 @@ Starting with the .NET Framework 2.0, this method uses the collection's objects'
12481203
<Docs>
12491204
<param name="index">The zero-based index at which <paramref name="value" /> should be inserted.</param>
12501205
<param name="value">The object to insert into the collection.</param>
1251-
<summary>Inserts an item to the collection at the specified index.</summary>
1206+
<summary>Calling this method always throws <see cref="T:System.NotSupportedException" />.</summary>
12521207
<exception cref="T:System.NotSupportedException">The collection is read-only.</exception>
1253-
<remarks>
1254-
<format type="text/markdown"><![CDATA[
1255-
1256-
## Remarks
1257-
1258-
This method is not supported. This is a read-only collection.
1259-
1260-
]]></format>
1261-
</remarks>
1262-
</Docs>
1208+
<remarks>To be added.</remarks>
1209+
</Docs>
12631210
</Member>
12641211
<Member MemberName="System.Collections.IList.IsFixedSize">
12651212
<MemberSignature Language="C#" Value="bool System.Collections.IList.IsFixedSize { get; }" />
@@ -1292,7 +1239,7 @@ This method is not supported. This is a read-only collection.
12921239
<Docs>
12931240
<summary>Gets a value indicating whether the collection has a fixed size.</summary>
12941241
<value>
1295-
<see langword="true" /> if the collection has a fixed size; otherwise, <see langword="false" />.</value>
1242+
<see langword="true" />, since the collection has a fixed size.</value>
12961243
<remarks>
12971244
<format type="text/markdown"><![CDATA[
12981245
@@ -1388,17 +1335,9 @@ This property provides the ability to access a specific element in the collectio
13881335
</Parameters>
13891336
<Docs>
13901337
<param name="value">The object to remove from the collection.</param>
1391-
<summary>Removes the first occurrence of a specific object from the collection.</summary>
1392-
<remarks>
1393-
<format type="text/markdown"><![CDATA[
1394-
1395-
## Remarks
1396-
1397-
This method is not supported. This is a read-only collection.
1398-
1399-
]]></format>
1400-
</remarks>
1338+
<summary>Calling this method always throws <see cref="T:System.NotSupportedException" />.</summary>
14011339
<exception cref="T:System.NotSupportedException">The collection is read-only.</exception>
1340+
<remarks>To be added.</remarks>
14021341
</Docs>
14031342
</Member>
14041343
<Member MemberName="System.Collections.IList.RemoveAt">
@@ -1434,17 +1373,9 @@ This method is not supported. This is a read-only collection.
14341373
</Parameters>
14351374
<Docs>
14361375
<param name="index">The zero-based index of the item to remove.</param>
1437-
<summary>Removes the collection item at the specified index.</summary>
1376+
<summary>Calling this method always throws <see cref="T:System.NotSupportedException" />.</summary>
14381377
<exception cref="T:System.NotSupportedException">The collection is read-only.</exception>
1439-
<remarks>
1440-
<format type="text/markdown"><![CDATA[
1441-
1442-
## Remarks
1443-
1444-
This method is not supported. This is a read-only collection.
1445-
1446-
]]></format>
1447-
</remarks>
1378+
<remarks>To be added.</remarks>
14481379
</Docs>
14491380
</Member>
14501381
</Members>

0 commit comments

Comments
 (0)