generated from Avanade/avanade-template
-
Notifications
You must be signed in to change notification settings - Fork 7
/
Copy pathValidationValue.cs
34 lines (30 loc) · 974 Bytes
/
ValidationValue.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
// Copyright (c) Avanade. Licensed under the MIT License. See https://github.com/Avanade/CoreEx
using System;
namespace CoreEx.Validation
{
/// <summary>
/// Represents a validation value.
/// </summary>
/// <typeparam name="T">The value <see cref="Type"/>.</typeparam>
public class ValidationValue<T>
{
/// <summary>
/// Initializes a new instance of the <see cref="ValidationValue{T}"/> class.
/// </summary>
/// <param name="entity">The parent entity value.</param>
/// <param name="value">The value.</param>
internal ValidationValue(object? entity, T? value)
{
Entity = entity;
Value = value;
}
/// <summary>
/// Gets or sets the entity value.
/// </summary>
public object? Entity { get; }
/// <summary>
/// Gets the entity property value.
/// </summary>
public T? Value { get; }
}
}