Introduction to Java -- array
catalogue
1. Array
1.1 concept
1.2 creation of array
1.3 array creation process
1.4 length of array
1.5 array variables
2. Tools
2.1 Arrays
1.Arrays.toString
2.Arrays.sort
3.Arrays.copyOf
1. Array
1.1 concept
Array, marked with "[]", is used to store the aggregation of multiple data of the same type. If you wan ...
Posted by Dude0 on Sat, 20 Nov 2021 22:22:51 -0800
Interpretation of HashMap & concurrent HashMap source code of jdk1.7+1.8
catalogue
preface
HashMap
Base 1.7
Base 1.8
Traversal mode
ConcurrentHashMap
Base 1.7
Base 1.8
summary
preface
Like Map Key Value It is a very classic structure in software development, which is often used to store data in memory.
This article mainly wants to discuss a concurrent container such as ConcurrentHashMap. B ...
Posted by webing on Sat, 20 Nov 2021 20:17:44 -0800
[docker compose] from building an image to running a Java project with one click
Let's start with a question. How many steps does it take for a new machine to run a regular spring boot project?
1. Download and configure java environment, mysql environment and redis environment (step 6)
2. Initialize mysql database and import sql files (step 2)
3. Download the jar package and start (step 2)
As like as two peas Ling Wan ...
Posted by ryochiji on Wed, 17 Nov 2021 20:19:44 -0800
Reflection of [JavaSE basic review] (including practice Demo)
reflex
1. Class loader
1.1 loading of class
When a program wants to use a class, if the class has not been loaded into memory, the system will initialize the class through three steps: loading, connecting and initialization.
load This is to read the class file into memory and create a class object for it. When any Class is used, the sy ...
Posted by Rederick on Thu, 11 Nov 2021 10:05:08 -0800
You must not know the usage of Unsafe
What is Unsafe
First of all, we say that the unsafe class is located under the sun.misc package in rt.jar. Unsafe translation is unsafe. This does not mean that this class is unsafe, but that it is unsafe for developers to use unsafe, that is, it is not recommended for developers to use unsafe directly. And there is no unsafe source code in th ...
Posted by Nightslyr on Fri, 29 Oct 2021 01:30:32 -0700
hibernate Association
1, One to many association configuration
Database: master table, slave table, associated by foreign key
Class:
class A{
B b;
}
class B{
}
Example: order and orderItem
order entity class
package com.sjy.entity;
import java.util.HashSet;
import java.util.Set;
public class Order {
// create table t_hibernate_order
// (
// order_id i ...
Posted by dale282 on Mon, 18 Oct 2021 10:38:11 -0700
The spring boot project is packaged into a jar package, and the encrypted deployment service allows the server to start automatically
The last article talked about the use of remote tools to remotely deploy the service, which allows it to run in the background without hanging up. This can basically meet the needs of normal projects, but we can continue to optimize the operation on this basis and do better.
&nbs ...
Posted by NoBullMan on Fri, 15 Oct 2021 12:49:13 -0700