随笔分类 -  .NET

.NET系列(其他技术与.NET相关联)
摘要:创建 01-netplan.yam 文件 network: version: 2 renderer: networkd ethernets: ens33: dhcp4: no addresses: [192.168.44.11/24] gateway4: 192.168.44.255 nameser 阅读全文
posted @ 2022-01-24 12:55 以沫浅夏 阅读(74) 评论(0) 推荐(0)
摘要:VS自动按日期生成版本号,修改解决方案文件 <PropertyGroup> <TargetFramework>netstandard2.1</TargetFramework> <Revision>$([System.DateTime]::Now.ToString("yyyy.MM.dd.HHmm") 阅读全文
posted @ 2020-07-18 20:27 以沫浅夏 阅读(1008) 评论(1) 推荐(0)
只有注册用户登录后才能阅读该文。
posted @ 2019-10-11 21:14 以沫浅夏
摘要:/// /// 计算文本的宽度 /// /// /// public static int GetStringLength(string str, int AddLength = 0) { Font f = new Font("微软雅黑", 12F, S... 阅读全文
posted @ 2018-12-14 16:26 以沫浅夏 阅读(832) 评论(0) 推荐(0)
摘要:ORACLE的SQL Developer工具默认的日期格式DD-MON-RR,在SQL查询中往往你看不到时间信息,此时你必须修改日期格式。具体如下所示 工具->首选项->数据库->NLS->日期格式: DD-MON-RR 修改为: YYYY-MM-DD HH24:MI:SS转载:https://www.cnblogs.com/kerrycode/p/4983085.html 阅读全文
posted @ 2018-11-24 10:20 以沫浅夏 阅读(1745) 评论(0) 推荐(0)
摘要:原文连接: https://documentation.devexpress.com/WindowsForms/DevExpress.XtraEditors.LabelControl.class https://documentation.devexpress.com/WindowsForms/De 阅读全文
posted @ 2018-11-20 10:38 以沫浅夏 阅读(1102) 评论(0) 推荐(0)
摘要:https://7gx64iks.mirror.aliyuncs.com 阅读全文
posted @ 2018-08-25 10:20 以沫浅夏 阅读(207) 评论(0) 推荐(0)
摘要:public ActionResult GetLargeJsonResult() { return new ContentResult { Content = new JavaScriptSerializer { MaxJsonLength = Int32.MaxValue }.Serialize(myBigdata), ContentType = "... 阅读全文
posted @ 2018-07-24 15:10 以沫浅夏 阅读(287) 评论(0) 推荐(0)
摘要:var val = new Int32Converter().IsValid(str) ? int.Parse(str) : default(int?); 阅读全文
posted @ 2018-07-12 09:54 以沫浅夏 阅读(135) 评论(0) 推荐(0)
摘要:var types = AppDomain.CurrentDomain.GetAssemblies() .SelectMany(a => a.GetTypes().Where(t => t.GetInterfaces().Contains(typeof(ISecurity)))) .ToArray(); 阅读全文
posted @ 2018-01-24 13:22 以沫浅夏 阅读(642) 评论(0) 推荐(0)
摘要:docker run \ --detach \ --publish 20443:443 \ --publish 20080:80 \ --name gitlab \ --restart unless-stopped \ --volume ~/gitlabdata/etc:/etc/gitlab \ --volume ~/gitlabdata... 阅读全文
posted @ 2018-01-02 13:24 以沫浅夏 阅读(4800) 评论(1) 推荐(0)
摘要:docker run -d -v ~/leanotedata:/leanotedata -p 80:9000 leanote/leanote 阅读全文
posted @ 2017-12-25 14:30 以沫浅夏 阅读(698) 评论(0) 推荐(0)
摘要:class Program { static void Main(string[] args) { Console.WriteLine(ActionExtension.Profiler(a, 10)); } static void a() { } } //... 阅读全文
posted @ 2017-11-28 12:41 以沫浅夏 阅读(2205) 评论(0) 推荐(0)
摘要:发送消息: static ConnectionFactory factory = new ConnectionFactory(); //static IConnection connection = factory.CreateConnection(); //static IModel channel = connection.CreateMo... 阅读全文
posted @ 2017-11-23 17:06 以沫浅夏 阅读(328) 评论(0) 推荐(0)
摘要:但是这样没有在后台启动;因此sh那一行代码需要修改: 前边加上nohup 后边加上& nohup dotnet helloword.dll & 然后,进程启动之后,按任意键进入输入状态,输入exit正常退出用户,再关闭Xshell(切不可强制关闭窗口来退出用户!!!) 阅读全文
posted @ 2017-09-13 17:45 以沫浅夏 阅读(2306) 评论(0) 推荐(0)
摘要:转自:https://topshelf.readthedocs.io/en/latest/overview/commandline.html Topshelf Command-Line Reference Once a service has been created using Topshelf, 阅读全文
posted @ 2017-07-28 10:13 以沫浅夏 阅读(1711) 评论(0) 推荐(0)
摘要:class Program { static void Main(string[] args) { HostFactory.Run(x => //1 { x.RunAsLocalSystem(); ... 阅读全文
posted @ 2017-07-28 09:56 以沫浅夏 阅读(283) 评论(0) 推荐(0)
摘要:string path = AppDomain.CurrentDomain.BaseDirectory; string startPath = @"c:\Client"; string zipPath = @"c:\Client.zip"; string extractPath = @"c:\Clie... 阅读全文
posted @ 2017-07-23 21:02 以沫浅夏 阅读(540) 评论(0) 推荐(0)
摘要:一、Actor简介 actor模型是一种并行计算的数学模型。 响应于收到的消息,演员可以:做出决定,创建更多Actor,发送更多消息,并确定如何响应接收到的下一条消息。 演员可以修改自己的状态,但只能通过消息相互影响(避免需要任何锁)。 actor是一个计算实体,当其收到消息时,可以并发执行如下操作 阅读全文
posted @ 2017-06-26 23:21 以沫浅夏 阅读(2052) 评论(0) 推荐(1)
摘要:基于NeqMq 4.0.0-rc5版本发布端: using (var publisher = new PublisherSocket()) { publisher.Bind("tcp://*:5556"); var rng = new Random(); while (t... 阅读全文
posted @ 2016-12-14 14:08 以沫浅夏 阅读(932) 评论(0) 推荐(0)