Skip to content

Commit fb91a9c

Browse files
Merge pull request #10512 from dotnet/main
Merge main into live
2 parents e691a8c + f1c3d27 commit fb91a9c

File tree

2 files changed

+38
-13
lines changed

2 files changed

+38
-13
lines changed

xml/System.ComponentModel/EnumConverter.xml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -62,10 +62,8 @@
6262
For more information about type converters, see the <xref:System.ComponentModel.TypeConverter> base class and [How to: Implement a Type Converter](https://learn.microsoft.com/previous-versions/visualstudio/visual-studio-2013/ayybcxe5(v=vs.120)).
6363
6464
> [!NOTE]
65-
> You should never create an instance of an <xref:System.ComponentModel.EnumConverter>. Instead, call the <xref:System.ComponentModel.TypeDescriptor.GetConverter%2A> method of the <xref:System.ComponentModel.TypeDescriptor> class. For more information, see the examples in the <xref:System.ComponentModel.TypeConverter> base class.
66-
67-
68-
65+
> You should never create an instance of an <xref:System.ComponentModel.EnumConverter>. Instead, call the <xref:System.ComponentModel.TypeDescriptor.GetConverter%2A> method of the <xref:System.ComponentModel.TypeDescriptor> class. For more information, see the examples in the <xref:System.ComponentModel.TypeConverter> base class.
66+
6967
## Examples
7068
The following code example converts a variable of type <xref:System.Enum> to a string, and vice versa. The example requires that you have declared an <xref:System.Enum> called `Servers` and that it has the following members:
7169
@@ -140,6 +138,8 @@ Windows=1, Exchange=2, BizTalk=3
140138
<param name="type">A <see cref="T:System.Type" /> that represents the type of enumeration to associate with this enumeration converter.</param>
141139
<summary>Initializes a new instance of the <see cref="T:System.ComponentModel.EnumConverter" /> class for the given type.</summary>
142140
<remarks>To be added.</remarks>
141+
<exception cref="T:System.ArgumentException">.NET 9 and later versions: <paramref name="type" /> is not of an enum type.
142+
</exception>
143143
</Docs>
144144
</Member>
145145
<Member MemberName="CanConvertFrom">

xml/System.ComponentModel/ICustomTypeDescriptor.xml

Lines changed: 34 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -332,9 +332,16 @@
332332
</ReturnValue>
333333
<Parameters />
334334
<Docs>
335-
<summary>Gets a type converter for this object that may be registered.</summary>
336-
<returns>To be added.</returns>
337-
<remarks>To be added.</remarks>
335+
<summary>Returns a type converter for this instance of a component that might be registered.</summary>
336+
<returns>A <see cref="T:System.ComponentModel.TypeConverter" /> that is the converter for this object, or <see langword="null" /> if there is no <see cref="T:System.ComponentModel.TypeConverter" /> for this object.</returns>
337+
<remarks>
338+
<format type="text/markdown"><![CDATA[
339+
340+
## Remarks
341+
If `null` is returned, use the default <xref:System.ComponentModel.TypeConverter>.
342+
343+
]]></format>
344+
</remarks>
338345
</Docs>
339346
</Member>
340347
<Member MemberName="GetDefaultEvent">
@@ -678,9 +685,18 @@
678685
</ReturnValue>
679686
<Parameters />
680687
<Docs>
681-
<summary>Gets the events for this instance of a component that may be registered.</summary>
682-
<returns>To be added.</returns>
683-
<remarks>To be added.</remarks>
688+
<summary>Returns the events for this instance of a component that might be registered.</summary>
689+
<returns>An <see cref="T:System.ComponentModel.EventDescriptorCollection" /> that represents the events for this component instance.</returns>
690+
<remarks>
691+
<format type="text/markdown"><![CDATA[
692+
693+
## Remarks
694+
The events for this instance can differ from the set of events that the class provides. For example, if the component is site-based, the site can add or remove additional events.
695+
696+
Implementors can return <xref:System.ComponentModel.EventDescriptorCollection.Empty?displayProperty=nameWithType> if no properties are specified. This method should never return `null`.
697+
698+
]]></format>
699+
</remarks>
684700
</Docs>
685701
</Member>
686702
<MemberGroup MemberName="GetProperties">
@@ -856,9 +872,18 @@
856872
</ReturnValue>
857873
<Parameters />
858874
<Docs>
859-
<summary>Gets the properties for this instance of a component that may be registered.</summary>
860-
<returns>To be added.</returns>
861-
<remarks>To be added.</remarks>
875+
<summary>Returns the properties for this instance of a component that might be registered.</summary>
876+
<returns>A <see cref="T:System.ComponentModel.PropertyDescriptorCollection" /> that represents the properties for this component instance.</returns>
877+
<remarks>
878+
<format type="text/markdown"><![CDATA[
879+
880+
## Remarks
881+
The properties for this instance can differ from the set of properties that the class provides. For example, if the component is sited, the site can add or remove additional properties.
882+
883+
Implementers can return <xref:System.ComponentModel.PropertyDescriptorCollection.Empty?displayProperty=nameWithType> if no properties are specified. This method should never return `null`.
884+
885+
]]></format>
886+
</remarks>
862887
</Docs>
863888
</Member>
864889
<Member MemberName="GetPropertyOwner">

0 commit comments

Comments
 (0)