wpf 状态切换
调用 # 调用 // 切换状态,指定模拟的状态时使用 VisualStateManager.GoToState, 现在指定了控件的状态,使用 VisualStateManager.GoToElementState VisualStateManager.GoToElementState(this.ColorBorder, name, true); x…
|
52
|
|
110 字
|
6 分钟
wpf 右下角提示弹窗口
<Window x:Class="WpfDemoApp.PromptPopupBoxCtrls.PopupBoxWindow" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://s…
|
45
|
|
59 字
|
3 分钟
贝塞尔曲线公式
计算公式 二次曲线 三次曲线 https://www.bilibili.com/video/BV16v4y1Q7PD https://juejin.cn/post/7082701281969569829
|
50
|
|
26 字
|
几秒读完
.net 断言库
Ardalis.GuardClauses https://www.nuget.org/packages/Ardalis.GuardClauses https://github.com/ardalis/guardclauses
|
88
|
|
14 字
|
几秒读完
.net 支持插件系统的 类库
https://github.com/natemcmaster/DotNetCorePlugins
|
125
|
|
5 字
|
几秒读完
.net 程序集扫描类 Scrutor
https://github.com/khellang/Scrutor 可扫描 实现了一个装饰器 扫描 var collection = new ServiceCollection(); collection.Scan(scan => scan // 从 ITransientService 接口所在的程序集开始扫描 .FromAssembly…
|
127
|
|
79 字
|
3 分钟
AutoFixture 简单介绍
- 在单元测试中自动生成随机的测试数据 Fixture fixture = new(); var items = fixture.Build<ListItem>() .With(it => it.Idx, Random.Shared.Next()) // 配置为所有实例都使用该值 .Without(it => it.Desc…
|
244
|
|
33 字
|
1 分钟内
Redis 一些资料
【GeekHour】一小时Redis教程 https://www.bilibili.com/video/BV1Jj411D7oG 一些应用场景 https://juejin.cn/post/7325132133168971813 StackExchange.Redis 中文文档目录 https://www.cnblogs.com/liang24/t…
|
231
|
|
50 字
|
几秒读完
Swagger 配置
# 进行参数修改 builder.Services.AddSwaggerGen(opt => {}); 修改标题 opt.SwaggerDoc("v1", new OpenApiInfo { Title = "Test01", Version = "v1", }); 在 header…
|
305
|
|
178 字
|
5 分钟
设置 task 为 STA 模式
因为要运行窗口代码,必须使用 STA 模式,而有一些代码又需要 async/await 方式 一 推荐,因为可以传入一个异步函数,并可以扩展为带返回值 # 调用 await this.RunWithStaTaskAsync(this.AppRun); private async Task RunWithStaTaskAsync(Func<Ta…
|
281
|
|
159 字
|
3 分钟