Universe.Template.Base.Common 0.35.0-beta

This is a prerelease version of Universe.Template.Base.Common.
dotnet add package Universe.Template.Base.Common --version 0.35.0-beta
NuGet\Install-Package Universe.Template.Base.Common -Version 0.35.0-beta
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Universe.Template.Base.Common" Version="0.35.0-beta" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add Universe.Template.Base.Common --version 0.35.0-beta
#r "nuget: Universe.Template.Base.Common, 0.35.0-beta"
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
// Install Universe.Template.Base.Common as a Cake Addin
#addin nuget:?package=Universe.Template.Base.Common&version=0.35.0-beta&prerelease

// Install Universe.Template.Base.Common as a Cake Tool
#tool nuget:?package=Universe.Template.Base.Common&version=0.35.0-beta&prerelease

Universe.Template.Base.Common

Tester App에서 사용할 UI와 헬퍼 클래스 정의

AppBase : Application

  • WPF <see cref="Application"/>의 공통 기능 구현
  • 안잡힌 예외 처리
  • <see cref="IHost"/> 생성, 설정 및 로거 등록

ViewContext

  • View와 ViewModel을 동시에 DI에 등록하고
  • 뷰의 DataContext를 뷰모델로 설정한다.

IPRogressDelegater

  • IProgress<(string cat, object msg)> : UI 메시지 출력 기능 정의
    • UI(View)이외의 클래스에서 주입받아 사용
    • UI는 이 인터페이스를 직접 구현하지 않는다 ~ 순환참조 방지!
    • 약어: using UIR = IProgress<(string cat, object msg)>
  • IProgressDelegater : UIR 중계자 ~ IProgress.Report() 구현자와 사용자 중계
    • UI는 이 인터페이스를 주입받아 PostAction에 실구현 메소드를 주입한다.

TesterMainWindow

  • MainWindow의 베이스 클래스
    • Mvvm.ObservableObject 구현
    • IList<ReportItem> LogItems : 로그 메시지 표시용 DataGrid의 바인딩 소스
    • Progress<T>를 통해 UIR 구현하여 IProgressDelegater.PostAction에 주입
  • UI 단축키 설정
    • Escape : 진행중인 테스트 메소드 취소
    • Ctrl + Delete : 로그 메시지 모두 지우기
    • 나머지는 상속 클래스에서 구현

HostExtensions

  • 확장메소드 IHostApplicationBuilder.UseProgressDelegater() 구현
Product Compatible and additional computed target framework versions.
.NET net8.0-windows7.0 is compatible. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last updated
0.35.0-beta 46 6/11/2024
0.34.0-beta 50 6/4/2024
0.31.0-beta 126 5/26/2024