TypeScript learning notes
Advantages of TypeScript
Support ES6 specificationPowerful IDE supportAngular2 development language
IDE advantages
Type check
Typescript online complier
http://www.typescriptlang.org/play/index.html
Typescript local complier
Install node.js, npm
npm install typescripttsc --version
New string features
Multiline string``
...
Posted by quicknb on Mon, 29 Nov 2021 02:53:56 -0800
Android event distribution mechanism - handling sliding conflicts
Before reading this article, it is recommended to read it first Android event distribution mechanism (1) - source code analysis_ z936689039 blog - CSDN blog
1. Case 1
We have to use the ps summary found in ViewGroup:
1. When ACTION_MOVE and action_ When the up event arrives, if no child element handles the event (mFirstTouchTarget==null), ...
Posted by clueless_rob on Mon, 29 Nov 2021 02:30:10 -0800
redis cluster and sentinel mode -- 03
192.168.80.51Main db01192.168.80.11From web04192.168.80.9From web03
1. Cluster preparation
To realize master-slave, please back up the data first
First, a single node redis has been installed Single node installation https://blog.csdn.net/ncnhhm/article/details/121443981 Master node profile
daemonize yes
bind 192.168.80.51
port ...
Posted by Grunt on Mon, 29 Nov 2021 02:17:48 -0800
Kafka transaction getting started example
kafka supports transactions from version 0.2.11. This document gives a brief description of kafka transactions, java code examples, some simple descriptions of the code, and relevant precautions. I hope it can be helpful to friends who need to use kafka transactions.On June 28, 2017, Kafka officially released version 0.11.0.0. From this version ...
Posted by evanesq on Mon, 29 Nov 2021 02:12:45 -0800
iOS pixel reading of pictures
Picture decodingThe common image compression formats are mainly PNG and JPEG. In iOS program development, it is generally not necessary to obtain the decoded data of a picture, but if you need to operate on pixels, you may need to know how to obtain relevant pixel values.Bitmap image (bitmap) is composed of multiple pixel arrays. When we decode ...
Posted by agrant on Mon, 29 Nov 2021 02:10:17 -0800
Java Foundation (Application of interface: creative design pattern factory design pattern Proxy)
Application of interface: factory mode
Factory mode: it realizes the separation of creator and caller, that is, the specific process of creating objects is shielded and isolated, so as to improve flexibility.In fact, both design patterns and object-oriented design principles are to make the development project easier to expand and maintain. The ...
Posted by Sinemacula on Mon, 29 Nov 2021 01:57:46 -0800
Go + or shit-- Run a simple Grpc
Run a simple Grpc
Previously, we successfully installed the Go + running environment. Next, we run a simple Grpc to learn how to reference packages.
Dependent package installation
For references to dependent libraries, Go + has made many optimizations to make the code easier to write. Just like when printing, Go needs to import "f ...
Posted by dennissanche on Mon, 29 Nov 2021 01:34:10 -0800
java bubble sorting (from simple to complex, from death to life)
For example: int []arr= {25,69,80,57,13,};
Basic idea of bubble sorting (from small to large): compare a[0] with a[1]. If the former is greater than the latter, exchange it before and after, otherwise no operation will be done. After this step, the larger value will be in the latter, that is, a[1]. Now we need to continue to compare to the bac ...
Posted by gaz_hayes on Mon, 29 Nov 2021 01:32:14 -0800
MongoDB vs MySQL, which is more efficient?
This article mainly introduces the use of MongoDB's bulkWrite() method by comparing batch and non batch operations. Incidentally, it is compared with relational database MySQL to compare the efficiency of these two different types of databases. If you just want to learn how to use bulkWrite(), just look at the first part.Test environment: win7 ...
Posted by chadtimothy23 on Mon, 29 Nov 2021 01:26:36 -0800
Standard library flag in golang
The flag package built in Go language realizes the analysis of command line parameters. The flag package makes it easier to develop command line tools.
os.Args
If you simply want to get command line parameters, you can use os.Args to get command line parameters like the following code example.
func main() {
// Get command line parameters
// o ...
Posted by turboprop on Mon, 29 Nov 2021 01:09:34 -0800