eagleboost Blog

梦想做大侠

# 0.01粗糙版数字永生

——一ChatGPT功用乱想

0.01粗糙版数字永生   最近ChatGPT开放了API,最新的定价也出来了,据说比以前的版本便宜了挺多。于是写了几段代码试着调用一下。跟网页版类似,提出一个问题(写一段话)就会得到一个回答。然而如果只是这样的话可以说毫无意义,用网页版就得了还写代码干啥?   ChatGPT作为大语言模型,最擅长的是自然语言处理。很多人使用ChatGPT已有的知识来帮助写文章,然后自己修改,或者自己写...

浅谈Mediator/MediatR

Avoid abusing the Mediator pattern

I’ve been interviewing candidates in the past several months. The candidates are from different sources, both internal and external. In general candidates from Investment Banking industr...

避免使用枚举类型 (2) TypeSafeEnum

TypeSafeEnum

1. Benchmark Let’s create some benchmark test codes to compare traditional Enum, EnumBox/EnumParser helper class and TypeSafeEnum from 3 aspect: parsing from string, converting to strin...

避免使用枚举类型 (1) No more Enums

No more Enums

1. The problem As one of the basic data types in a lot of programming language, Enum provides Alias capability for a set of integers with limited number of values, it’s very easy to use...

M-V-VM视图交互简述

Interactions between the View and ViewModel

1. The problem Displaying dialogs/windows is a common scenario in desktop applications. Modal dialogs are used most often, like MessageBox, or more complex ones like Login Dialog that r...

Implicit boxing in System.Array.IndexOf

1. The Problem I was fixing some performance issues for our project last week, and interestingly the profiler shows boxing operation (allocation of char) happened inside a method that c...

Wordpress博客备份

——一个新旧交替的时期

想起来在Wordpress.com还开过一个博客,时间很短,只持续了3个月不到,三篇而已。 回顾了一下时间线,适逢酝酿从旧公司离开,几个月后换了个城市开始新工作的时期。新工作开始后迎来一段全新并极为忙碌的旅程,说好的博客也没有再继续下去。 彼时各方面有些停滞,心境的变化流于表面的大约体现在这几句话了。 以前在CSDN有个Blog,前后两年多写了不少技术文章,至今也有四年多没有更新...

Unity Container (3) Property Container

Advanced Unity Container usages

1. The Problem In the previous post we talked about Reflection.Emit being the best option to implicitly implement the INotifyPropertyChanged interface, with several points that can be i...

Unity Container (2) Implementing the INotifyPropertyChanged Interface

Advanced Unity Container usages

1. The problem The INotifyPropertyChanged interface is probably one of the most famous interfaces in the interface oriented programing history. It has been used extensively almost every...

Unity Container (1) Injecting type aware ILogger

Advanced Unity Container usages

Many large scale applications adopt the concept of IoC, it’s especially useful in terms of component de-coupling and writing reusable codes. Among all of the IoC containers on the mar...