ExternalService.cs
1.4 KB
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
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
namespace NCC.Dependency
{
/// <summary>
/// 外部注册类型模型
/// </summary>
[SuppressSniffer]
public sealed class ExternalService
{
/// <summary>
/// 接口类型,格式:"程序集名称;接口完整名称"
/// </summary>
public string Interface { get; set; }
/// <summary>
/// 实例类型,格式:"程序集名称;接口完整名称"
/// </summary>
public string Service { get; set; }
/// <summary>
/// 注册类型
/// </summary>
public RegisterType RegisterType { get; set; }
/// <summary>
/// 添加服务方式,存在不添加,或继续添加
/// </summary>
public InjectionActions Action { get; set; } = InjectionActions.Add;
/// <summary>
/// 注册选项
/// </summary>
public InjectionPatterns Pattern { get; set; } = InjectionPatterns.All;
/// <summary>
/// 注册别名
/// </summary>
/// <remarks>多服务时使用</remarks>
public string Named { get; set; }
/// <summary>
/// 排序,排序越大,则在后面注册
/// </summary>
public int Order { get; set; }
/// <summary>
/// 代理类型,格式:"程序集名称;接口完整名称"
/// </summary>
public string Proxy { get; set; }
}
}