Dreamine.Logging.Wpf 1.0.2
Dreamine.Logging.Wpf 사용자 인터페이스 기능과 구성 요소를 제공합니다.
로딩중...
검색중...
일치하는것 없음
Dreamine.Logging.Wpf.Registration.DreamineLoggingWpfRegistration 클래스 참조

더 자세히 ...

정적 Public 멤버 함수

static void Register (Action< DreamineLoggingOptions >? configure=null)
static void Reset ()

정적 Private 멤버 함수

static void RegisterShutdownHandler (IAsyncDisposable shutdownHandle)

정적 Private 속성

static readonly object SyncRoot = new()
static bool _isExitHandlerRegistered

상세한 설명

Dreamine WPF 로깅 서비스 등록 도우미를 제공합니다.

DreamineLoggingWpfRegistration.cs 파일의 19 번째 라인에서 정의되었습니다.

멤버 함수 문서화

◆ Register()

void Dreamine.Logging.Wpf.Registration.DreamineLoggingWpfRegistration.Register ( Action< DreamineLoggingOptions >? configure = null)
inlinestatic

Dreamine 핵심 로깅 및 WPF UI 로깅 서비스를 등록합니다.

매개변수
configure선택적 로깅 구성 작업입니다.

DreamineLoggingWpfRegistration.cs 파일의 56 번째 라인에서 정의되었습니다.

57 {
58 var options = new DreamineLoggingOptions();
59 configure?.Invoke(options);
60
61 IAsyncDisposable shutdownHandle = DreamineLoggingRegistration.Register(options);
62
63 DMContainer.RegisterSingleton<WpfLogUiDispatcher>(
64 new WpfLogUiDispatcher());
65 DMContainer.RegisterSingleton<ILogUiDispatcher>(
66 DMContainer.Resolve<WpfLogUiDispatcher>());
67
68 DMContainer.Register<DreamineLogPanelViewModel>(() =>
69 new DreamineLogPanelViewModel(
70 DMContainer.Resolve<Dreamine.Logging.Interfaces.IDreamineLogStore>(),
71 DMContainer.Resolve<ILogUiDispatcher>()));
72
73 RegisterShutdownHandler(shutdownHandle);
74 }

다음을 참조함 : RegisterShutdownHandler().

이 함수 내부에서 호출하는 함수들에 대한 그래프입니다.:

◆ RegisterShutdownHandler()

void Dreamine.Logging.Wpf.Registration.DreamineLoggingWpfRegistration.RegisterShutdownHandler ( IAsyncDisposable shutdownHandle)
inlinestaticprivate

WPF 애플리케이션 종료 시 로그 파이프라인을 해제하는 처리기를 한 번 등록합니다.

매개변수
shutdownHandle종료할 로깅 핸들입니다.

DreamineLoggingWpfRegistration.cs 파일의 108 번째 라인에서 정의되었습니다.

109 {
110 var app = Application.Current;
111 if (app is null)
112 {
113 return;
114 }
115
116 lock (SyncRoot)
117 {
118 if (_isExitHandlerRegistered)
119 {
120 return;
121 }
122
123 _isExitHandlerRegistered = true;
124 }
125
126 app.Exit += (_, _) =>
127 {
128 try
129 {
130 shutdownHandle.DisposeAsync().AsTask().GetAwaiter().GetResult();
131 }
132 catch
133 {
134 // Shutdown errors must not prevent process exit.
135 }
136 };
137 }

다음을 참조함 : _isExitHandlerRegistered, SyncRoot.

다음에 의해서 참조됨 : Register().

이 함수를 호출하는 함수들에 대한 그래프입니다.:

◆ Reset()

void Dreamine.Logging.Wpf.Registration.DreamineLoggingWpfRegistration.Reset ( )
inlinestatic

테스트를 위해 정적 등록 상태를 초기화합니다.

DreamineLoggingWpfRegistration.cs 파일의 84 번째 라인에서 정의되었습니다.

85 {
86 lock (SyncRoot)
87 {
88 _isExitHandlerRegistered = false;
89 }
90 }

다음을 참조함 : _isExitHandlerRegistered, SyncRoot.

멤버 데이터 문서화

◆ _isExitHandlerRegistered

bool Dreamine.Logging.Wpf.Registration.DreamineLoggingWpfRegistration._isExitHandlerRegistered
staticprivate

is Exit Handler Registered 값을 보관합니다.

DreamineLoggingWpfRegistration.cs 파일의 38 번째 라인에서 정의되었습니다.

다음에 의해서 참조됨 : RegisterShutdownHandler(), Reset().

◆ SyncRoot

readonly object Dreamine.Logging.Wpf.Registration.DreamineLoggingWpfRegistration.SyncRoot = new()
staticprivate

Sync Root 값을 보관합니다.

DreamineLoggingWpfRegistration.cs 파일의 29 번째 라인에서 정의되었습니다.

다음에 의해서 참조됨 : RegisterShutdownHandler(), Reset().


이 클래스에 대한 문서화 페이지는 다음의 파일로부터 생성되었습니다.: