Dreamine.MVVM.Core 1.0.13
중요: 자동 등록된 타입은 기본적으로 Singleton으로 등록됩니다. 따라서 자동 발견된 ViewModel, Model, Event, Manager는 애플리케이션이 별도 수명으로 명시 등록하지 않는 한 반복 해석 시 동일 인스턴스를 유지합니다.
로딩중...
검색중...
일치하는것 없음
ServiceDescriptor.cs
이 파일의 문서화 페이지로 가기
1using System;
2
4{
13 public sealed class ServiceDescriptor
14 {
72 Type serviceType,
73 Type? implementationType,
74 Func<object>? factory,
75 object? instance,
76 ServiceLifetime lifetime)
77 {
78 ServiceType = serviceType ?? throw new ArgumentNullException(nameof(serviceType));
79 ImplementationType = implementationType;
80 Factory = factory;
81 Instance = instance;
82 Lifetime = lifetime;
83 }
84
93 public Type ServiceType { get; }
94
103 public Type? ImplementationType { get; }
104
113 public Func<object>? Factory { get; }
114
123 public object? Instance { get; }
124
133 public ServiceLifetime Lifetime { get; }
134 }
135}
ServiceDescriptor(Type serviceType, Type? implementationType, Func< object >? factory, object? instance, ServiceLifetime lifetime)