Lock free concurrency of JUC (leguan lock)

1. Quote There are the following requirements to ensure account Thread safety of withdraw withdrawal method interface Account { /** * Get balance * * @return Integer balance */ Integer getBalance(); /** * withdraw money * * @param amount Withdrawal amount */ void withdraw(Integ ...

Added by volomike on Sun, 13 Feb 2022 14:10:52 +0200

ConcurrentHashMap of thread safety class

1. Overview As shown in the figure, thread safe collection classes can be divided into three categories Legacy thread safe collections such as Hashtable and Vector Thread safe Collections decorated with Collections, such as: Collections.synchronizedCollection Collections.synchronizedList Collections.synchronizedMap Collecti ...

Added by RobM on Sun, 13 Feb 2022 13:53:02 +0200

Buffer stream & conversion stream & sequence commutation

preface Java - IO stream Foundation Buffer stream Byte buffer stream: BufferedInputStream, BufferedOutputStreamCharacter buffer stream: BufferedReader, BufferedWriter The basic principle of buffered stream is that when creating stream objects, a built-in buffer array of default size will be created to reduce the number of system IO thro ...

Added by dnice on Sun, 13 Feb 2022 13:05:39 +0200

day04--java Advanced Programming: API common classes, IO streams

1 API 1.1 Api document download 1.API (Application Programming Interface) is the basic programming interface provided by Java. Everything that can be called is API. 2.Java language provides a large number of basic classes, so Oracle also provides corresponding API documents for these basic classes to tell developers how to use these classes ...

Added by newb110508 on Sun, 13 Feb 2022 10:38:32 +0200

Function overloading of C + + Introduction (basic syntax)

Write in front For those who don't understand the compilation and linking of C language, you can look at the following articles and review the previous knowledge first. Explain the compilation and link of C language in detail 1 concept of function overloading Function overloading: it is a special case of functions. C + + allows to dec ...

Added by jmgrhm on Sun, 13 Feb 2022 09:40:10 +0200

Mybatis learning notes summary

1. Dynamic SQL 1.1 what is dynamic SQL? What is dynamic SQL? Dynamic SQL refers to generating different SQL statements according to different conditions. Usually, we operate some different SQL statements, which are directly changed in the code, which is very troublesome. It is very convenient to use dynamic SQL of Mybatis. Using t ...

Added by darkwolf on Sun, 13 Feb 2022 09:29:44 +0200

Java IO byte stream

1. IO flow 1.1 IO flow overview and classification 1. Introduction to IO flow IO: input / outputStream: it is an abstract concept, which is the general name of data transmission. In other words, the transmission of data between devices is called stream, and the essence of stream is data transmissionIO stream is used to deal with data tra ...

Added by qt4u on Sun, 13 Feb 2022 09:11:31 +0200

C++11_lambda expression, wrapper, bind binding

1.lambda expression [capture list] (parameter list) mutable - > return value type {function body} mutable: by default, lambda expressions have const attribute by default. mutable can cancel its const attribute. Note: when using this modifier, the parameter list cannot be omitted even if it is empty When there is no mutable in the para ...

Added by slyte33 on Sun, 13 Feb 2022 07:54:48 +0200

[C language] address book - dynamic and static implementation

preface: I believe everyone knows the address book Its functions include: adding, deleting, checking and modifying This issue is to realize an address book implemented in C language Continue what we talked about last time-- Dynamic memory allocation Then I will implement it in the two ways given in the title I Implementation of st ...

Added by jkewlo on Sun, 13 Feb 2022 07:47:27 +0200

It's so beautiful. Output nice tables. You must learn this library of Python

Relevant documents Little buddy who wants to learn Python can pay attention to the official account of Xiaobian [Python journal]. There are many resources for whoring for nothing, ha. I will update the little knowledge of Python from time to time!! preface Recently, I was writing a small tool in Python, which is mainly used to manage the inf ...

Added by s2j1j1b0 on Sun, 13 Feb 2022 05:20:16 +0200