原创 Linux tutorial 1 - 安裝centos 7 in hyper-v step by step

1.下載centos 2. 創建hyper-v virtual switch(虛擬交換機,我們後面的虛擬機要連接到該交換機) 2.1 打開hyper-v管理器,右側點“虛擬交換機管理器” 2.2 創建 外部 虛擬交換機 2.3 創建

原创 C#多線程整理

1. 通過Delegate使用線程 1.1 通過delegate.BeginInvoke方法啓動線程,通過delegate.EndInvoke(IAsyncResult)等待線程執行結束,並獲取線程函數的返回值。 1.2 通過回調函

原创 spring mvc - tutorial 2: spring + swagger

1. Spring mvc + springfox swagger1 2. Spring mvc + springfox swagger2 2.1 新建一個簡單的spring mvc restful web app 2.2 添加sp

原创 Rabbit MQ - tutorial 7, Spring RabbitMQ

基本概念 tutorial 7 Spring RabbitMQ (1) 項目依賴 (2) applicationContext.xml & spring-mvc.xml (3) 配置web.xml 並確認是否配置成功 (4) 添加s

原创 Linux tutorial 3 - centos Shell

1. Shell的基本知識 1.1 Shell具有如下功能 1.2 Shell的元字符: 1.3 Shell命令一般格式 1.4 目錄和文件名的命名規則 1.5 通配符 2 Linux下的文件類型 2.1 硬鏈接(ln file

原创 C#新特性

C#7.1 C#7 1.out variables //以前必須先定義,再使用,不在同一行上,而且有可能沒有賦值就使用 int numericResult; if (int.TryParse(input, out numericResul

原创 spring mvc - tutorial 1:實現簡單的GET、POST接口並使用Postman測試

1. intellij IDEA創建一個maven web app 1.1 POM添加依賴 1.2 添加spring和spring mvc配置文件 1.3 配置web.xml 2. 添加controller和model 3. 配

原创 WPF DateTimePicker

WPF沒有DateTimePicker,自身的DatePicker不能選擇時間。所以要自己實現。 <DatePicker Height="25" Width="250" Text="2011/10/11 15:16:17"/> 使用Wi

原创 Rabbit MQ - tutorial 4 Routing, receiving messages selectively

本例在前一例的基礎上,通過Routing過濾消息,只接收感興趣的message。 基本概念 Tutorial 4 - 消息路由routing (1) Producer (2) Consumer (3) 運行結果 基本概念

原创 Autofac tutorial 1

Autofac,它的本質是根據你註冊的類型,自動爲你創建相應的對象。 使用方法 1).在程序啓動時,創建ContainerBuilder, 2).用創建的builder註冊組件(component) 3).調用builder的Buil

原创 spring mvc - tutorial 3: utf-8編碼

修改intellij IDEA的啓動配置 安裝目錄的idea64.exe.vmoptions配置文件最後加上:-Dfile.encoding=UTF-8 修改intellij IDEA編輯器的文件編碼配置 打開intelli

原创 WPF command

1. 基本知識 微軟預定義了5類100多個常用命令: ApplicationCommands, NavigationCommands, MediaCommands, EditingCommands and ComponentComman

原创 AutoMapper

AutoMapper用於兩個對象間的映射,通常用於完成DTO(Data Transfer Object)和Model之間的轉換。AutoMapper 1.創建 Mapper.Initialize(cfg => { cfg.Crea