05 2020 档案

摘要:class Program { // 使用BeginXXX/EndXXX和IAsyncResult对象的方式被称为异步编程模型(APM模式) delegate string RunOnThreadPool(out int threadId); static void Main(string[] ar 阅读全文
posted @ 2020-05-30 16:50 石shi 阅读(404) 评论(0) 推荐(0) 编辑
摘要:暂停线程: static void Main(string[] args) { Thread thread = new Thread(Common.PrintNumbersWithDelay); thread.Start(); Common.PrintNumbers(); Console.ReadK 阅读全文
posted @ 2020-05-30 14:56 石shi 阅读(289) 评论(0) 推荐(0) 编辑
摘要:原子操作类: public abstract class CounterBase { public abstract void Increase(); public abstract void Decrease(); } public class CounterNoInterlocked : Cou 阅读全文
posted @ 2020-05-30 14:41 石shi 阅读(306) 评论(0) 推荐(0) 编辑
摘要:public static class SortingHelper<T> where T : IComparable { #region 1.1 直接插入排序 /// <summary> /// 普通版直接插入排序 /// </summary> /// <param name="arr">待排序数组 阅读全文
posted @ 2020-05-30 13:31 石shi 阅读(228) 评论(0) 推荐(0) 编辑
摘要:Ip: \b(([01]?\d?\d|2[0-4]\d|25[0-5])\.){2}[012]+[-\*\d]*\b 端口:80,433,53 1-65535 ^([0-9]|[1-9]\d|[1-9]\d{2}|[1-9]\d{3}|[1-5]\d{4}|6[0-4]\d{3}|65[0-4]\d 阅读全文
posted @ 2020-05-29 10:12 石shi 阅读(1323) 评论(0) 推荐(0) 编辑
摘要://基于数组的队列实现 public class MyArrayQueue<T> { private T[] items; private int size; private int head; private int tail; public MyArrayQueue(int capacity) 阅读全文
posted @ 2020-05-29 08:55 石shi 阅读(864) 评论(0) 推荐(1) 编辑
摘要:using org.apache.rocketmq.client.consumer; using org.apache.rocketmq.client.consumer.listener; using org.apache.rocketmq.client.producer; using org.ap 阅读全文
posted @ 2020-05-24 22:34 石shi 阅读(1520) 评论(1) 推荐(0) 编辑
摘要:/// <summary> /// 树结构帮助类 /// </summary> public class TreeHelper { #region 外部接口 /// <summary> /// 建造树结构 /// </summary> /// <param name="allNodes">所有的节点 阅读全文
posted @ 2020-05-24 16:38 石shi 阅读(481) 评论(0) 推荐(0) 编辑
摘要:import java.util.Arrays; import java.util.PriorityQueue; import java.util.Queue; public class LeafNode { // 堆方法(优先队列) // 1.堆的性质是每次可以找出最大或最小的元素 // 快排变形 阅读全文
posted @ 2020-05-24 13:39 石shi 阅读(589) 评论(0) 推荐(0) 编辑
摘要:#region 单线程 单例 public class Singleton { private static Singleton uniqueInstance; //定义私有构造函数,外界不能创建该实例 private Singleton() { } //定义一个公有方法,提供一个全局访问点 pub 阅读全文
posted @ 2020-05-17 13:42 石shi 阅读(166) 评论(0) 推荐(0) 编辑
摘要:测试方法: private static void Main(string[] args) { var list = new List<Person>(); for (int i = 0; i < 1000000; i++) { list.Add(new Person() { Age = 18, N 阅读全文
posted @ 2020-05-17 13:40 石shi 阅读(760) 评论(0) 推荐(0) 编辑
摘要:<script> export default { data () { return { loginForm: { username: 'admin', password: '123456' }, // 表单验证 loginFormRules: { username: [ { required: t 阅读全文
posted @ 2020-05-05 22:23 石shi 阅读(2033) 评论(0) 推荐(0) 编辑
摘要:查看git工作区,是否干净. git status */- 建立一个分支: git checkout -b login 查看当前的分支: git branch 添加到暂存区: git add . 提交: git commit -m “日志” 切换分支: git checkout master 合并分 阅读全文
posted @ 2020-05-04 22:45 石shi 阅读(132) 评论(0) 推荐(0) 编辑

点击右上角即可分享
微信分享提示