JFinal automatic routing registration saves development time

1. Implementation of Route Registration Route auto-registration is easy to implement, just get all the Controller configuration to route, the code is as follows package com.nmtx.route; import java.util.ArrayList; import java.util.List; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import com.jfinal.config.Routes; import com.jfinal ...

Added by Boo-urns on Fri, 04 Oct 2019 20:08:31 +0300

Java Double Loop Printing Patterns

Links to the original text: https://blog.csdn.net/yajing8/article/details/73548896 Using Java double loop to print various pattern summaries: the outer loop controls the number of rows, which is fixed, and the inner loop controls the output ...

Added by doofystyle on Fri, 04 Oct 2019 18:37:15 +0300

SpringBook integrates Jwt to generate token tokens (session can be replaced when front and back ends are separated)

Overview of token tokens generated by Jwt 1. Stateful landing and stateless landing Stateful service, that is, the server needs to record the client information of each session to identify the identity of the client and process requests according to the identity of the user, such as session in tomcat ...

Added by mrodrigues on Fri, 04 Oct 2019 17:04:39 +0300

Use of Collections Tool Classes

/* reverse(List): Reverse the order of elements in a List * shuffle(List): Random sorting of List set elements * sort(List): Sort the elements of a specified List collection in ascending order according to the natural order of the elements * sort(List,Comparator): List collection elements are generated ...

Added by wilhud on Fri, 04 Oct 2019 16:13:20 +0300

Leetcode brush Title java 349. intersection of two arrays

Implementation results: adopt Display details Execution time: 8 ms, beating 66.35% of all Java submissions Memory consumption: 37.6 MB, beating 29.53% of all Java submissions Title: Given two arrays, write a function to compute their intersection. Example 1: Input: nums1 = [1,2,2,1], nums2 = ...

Added by Rhysyngsun on Fri, 04 Oct 2019 11:52:13 +0300

Java Operating Redis -- Jedis's API

Let's first look at how java links redis Maven: <dependency> <groupId>redis.clients</groupId> <artifactId>jedis</artifactId> <version>3.0.1</version> </dependency> Java: public static void ma ...

Added by watsmyname on Fri, 04 Oct 2019 07:22:14 +0300

Spring 5 Source Resolution 2-register Method Register Configuration Class

The last time I talked about this() method, let's look at register (annotated Classes); method. // New Annotation Config Application Context (AppConfig. class); source code public AnnotationConfigApplicationContext(Class<?>... annotatedClasses) { //Call the default parameterless constructor, which has a lot of initialization logic ...

Added by harsh00008 on Fri, 04 Oct 2019 04:21:47 +0300

Kafka Initial Learning--Kafka Transaction Support

1. Implementing kafka transaction by spring annotation 1. Add Configuration to the Configuration Class in the previous article /** * The following three methods are used for management * Configure Kafka Transaction Manager, which is the transaction management class provided by Kafka to us. We need t ...

Added by jaimitoc30 on Fri, 04 Oct 2019 03:06:45 +0300

HUAWEI 2019 school written examination - logical calculation

<!-- TOC --> HUAWEI 2019 school written examination - logical calculation Title Description Input description For example: Example 1 input output Example 2 input output Sample code <!-- /TOC --> HUAWEI 2019 school written examination - logical calculation Title Description Commonly used logical operations are And (expres ...

Added by trufla on Thu, 03 Oct 2019 23:34:26 +0300

Execution results in JdbcTemplate contain embedded entities

Execution results in JdbcTemplate contain embedded entities One way Mode two Mode three When using JDBCTemplate, you will encounter situations where other entities are embedded in the entity, so that fields in the entity will not be assigned. There are three ways to solve this problem, each of whi ...

Added by crazykid on Thu, 03 Oct 2019 22:49:39 +0300