generated from Avanade/avanade-template
-
Notifications
You must be signed in to change notification settings - Fork 4
/
IPropertyRule.cs
32 lines (27 loc) · 912 Bytes
/
IPropertyRule.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
// Copyright (c) Avanade. Licensed under the MIT License. See https://github.com/Avanade/CoreEx
using CoreEx.Localization;
namespace CoreEx.Validation
{
/// <summary>
/// Enables a validation rule for an entity property.
/// </summary>
public interface IPropertyRule
{
/// <summary>
/// Gets the property name.
/// </summary>
public string Name { get; }
/// <summary>
/// Gets the JSON property name.
/// </summary>
public string JsonName { get; }
/// <summary>
/// Gets or sets the friendly text name used in validation messages.
/// </summary>
public LText Text { get; set; }
/// <summary>
/// Gets or sets the error message format text (overrides the default) used for all validation errors.
/// </summary>
public LText? ErrorText { get; set; }
}
}