Skip to content

Commit fa435f0

Browse files
committed
System.ComponentModel.DataAnnotations docs
1 parent 818afd4 commit fa435f0

File tree

2 files changed

+18
-6
lines changed

2 files changed

+18
-6
lines changed

xml/System.ComponentModel.DataAnnotations/ValidationContext.xml

Lines changed: 17 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -304,12 +304,23 @@
304304
</Parameter>
305305
</Parameters>
306306
<Docs>
307-
<param name="instance">To be added.</param>
308-
<param name="displayName">To be added.</param>
309-
<param name="serviceProvider">To be added.</param>
310-
<param name="items">To be added.</param>
311-
<summary>To be added.</summary>
312-
<remarks>To be added.</remarks>
307+
<param name="instance">The object instance being validated. It cannot be <see langword="null" />.</param>
308+
<param name="displayName">The display name associated with the object instance.</param>
309+
<param name="serviceProvider">
310+
<para>Optional <see cref="T:System.IServiceProvider" /> to use when <see cref="M:System.ComponentModel.DataAnnotations.ValidationContext.GetService(System.Type)" /> is called.</para>
311+
<para>If it is <see langword="null" />, <see cref="M:System.ComponentModel.DataAnnotations.ValidationContext.GetService(System.Type)" /> will always return <see langword="null" />.</para>
312+
</param>
313+
<param name="items">
314+
<para>Optional set of key/value pairs to make available to consumers via <see cref="P:System.ComponentModel.DataAnnotations.ValidationContext.Items" />.</para>
315+
<para>If <see langword="null" />, an empty dictionary will be created. If not <see langword="null" />, the set of key/value pairs will be copied into a new dictionary, preventing consumers from modifying the original dictionary.</para>
316+
</param>
317+
<summary>
318+
<para>Construct a <see cref="T:System.ComponentModel.DataAnnotations.ValidationContext" /> for a given object instance with a <paramref name="displayName" />, an optional <paramref name="serviceProvider" />, and an optional property bag of <paramref name="items" />.</para>
319+
</summary>
320+
<remarks>
321+
<para>This constructor is trim-safe because it does not use reflection to resolve the Type of the <paramref name="instance" /> to support setting the DisplayName.</para>
322+
</remarks>
323+
<exception cref="T:System.ArgumentNullException">When <paramref name="instance" /> is <see langword="null" /></exception>
313324
</Docs>
314325
</Member>
315326
<Member MemberName="DisplayName">

xml/System.ComponentModel.DataAnnotations/ValidationResult.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,7 @@
4141
<Docs>
4242
<summary>Represents a container for the results of a validation request.</summary>
4343
<remarks>To be added.</remarks>
44+
<seealso cref="M:System.ComponentModel.DataAnnotations.ValidationAttribute.GetValidationResult(System.Object,System.ComponentModel.DataAnnotations.ValidationContext)" />
4445
</Docs>
4546
<Members>
4647
<MemberGroup MemberName=".ctor">

0 commit comments

Comments
 (0)