Java learning journey -- String

This blog will explain the String class in java in detail. Create string Common ways to construct String //Mode 1 String str = "hello"; //Mode 2 String str1 = new String("Hello"); //Mode 3 char[] array = {'a', 'b', 'c'}; String str2 = new String(array); be careful: String literal constants such as "hello" are also of type s ...

Added by o3d on Mon, 07 Mar 2022 09:43:18 +0200

Quickly understand the commonly used asymmetric encryption algorithms, and no longer have to worry about the thorough inquiry of the interviewer

Interviewer: what are your commonly used encryption algorithms? Encryption algorithms are usually divided into two kinds: symmetric encryption algorithm and asymmetric encryption algorithm. The symmetric encryption algorithm uses the same key in encryption and decryption; Asymmetric encryption algorithm uses different keys in encryption and ...

Added by Xadian on Mon, 07 Mar 2022 09:25:38 +0200

Describe the prototype chain

Describe the prototype chainbackgroundJavaScript is dynamic and does not provide an implementation of class itself. Even if the class keyword is introduced in ES2015/ES6, it is only a syntax sugar, and JavaScript is still based on the prototypeWhen it comes to inheritance, JavaScript has only one structure: objects. Each instance object has a p ...

Added by raymedia on Mon, 07 Mar 2022 09:17:55 +0200

Random talk: how does the log portal slf4j integrate the log framework

I preface This article discusses some simple things, mainly to understand what log portal is and how it is integrated II Log portal The Java Development Manual published by Ali has such a mandatory specification: The API in the logging system (Log4j, Logback) can not be directly used in the application, but the API in the logging framework ...

Added by Gregghawes on Mon, 07 Mar 2022 09:11:55 +0200

Petite Vue source code analysis - the working principle of v-if and v-for

Delve into how v-if works <div v-scope="App"></div> <script type="module"> import { createApp } from 'https://unpkg.com/petite-vue?module' createApp({ App: { $template: ` <span v-if="status === 'offline'"> OFFLINE </span> <span v-else-if="status === 'UNKOWN'"> UNKOWN </span> ...

Added by insanityonline on Mon, 07 Mar 2022 09:09:25 +0200

Jaro Winkler distance java code implementation version

Interface:public interface StringDistance { public float getDistance(String s1, String s2) ; }Method class: public class JaroWinklerDistance implements StringDistance { private float threshold = 0.7f; private int[] matches(String s1, String s2) { String max, min; if (s1.length() > s2.length()) { max = s1; min = s2; } ...

Added by PHPfolife on Mon, 07 Mar 2022 09:04:05 +0200

The underlying implementation principle of synchronize bias lock

1. Meaning of bias lockUnnecessary multi-path lock execution reduces the number of threads competing unnecessarily. In most cases, the lock not only does not have multi-threaded competition, but also the same thread always obtains the lock multiple times. In order to make the thread obtain the lock with lower performance cost, biased lock is in ...

Added by lobobr on Mon, 07 Mar 2022 09:00:23 +0200

November 8, 2014 Android learning ------ implementation case of Android drawer effect ------ Animation learning chapter

I study Android in combination with the source code, which is more intuitive and very clear to see the effect. I think it's very good. Today's learning source code is the source code found online. Baidu search knows many places to download. The name of the online source code is Android drawer effect zip my blog is messy. If I don't understand t ...

Added by lynwell07 on Mon, 07 Mar 2022 08:57:32 +0200

Relearning the basic part of android -- AIDL

AIDL is similar to other IDL languages. You need to do some work. It allows you to define the program interface agreed between the client and the server, and use interprocess communication to communicate with each other. On Android, one process cannot normally access the memory of another process. Therefore, they need to decompose their object ...

Added by patelp7 on Mon, 07 Mar 2022 08:54:28 +0200

MM32F0020 UART1 interrupt reception

catalog: 1. Introduction to mm32f0020 2. Initialize MM32F0020 UART1 and NVIC interrupts 3. Write MM32F0020 UART1 interrupt receiving function 4. Write MM32F0020 UART1 sending byte and ASCII character function 5. Write the data function received by MM32F0020 UART1 processing interrupt 6.MM32F0020 UART1 sends the data received by UART1 interrupt ...

Added by Fatboy on Mon, 07 Mar 2022 08:45:36 +0200