Spring property Injection Method
Spring has three types of property injection:
1. setter Injection
2. constructor Injection
3. annotation injection:
① Java annotation ② spring annitation
Java annotation in the third type is the recommended
Optimization of Singleton mode analysis codeThe Singleton mode is one of the 23 design patterns and is a relatively simple design pattern. It aims to return the same object no matter how many calls, it features privatization of constructors. It can
Method Search in rubyMethod calls in ruby are in the form of objects. Methods. How can an object find this method? First, you must understand the concept of the ancestor chain. The ancestor chain starts from a class to its parent class, and then to
Design Mode-adapter ModeThe adapter mode defines two incompatible classes to be used together. It is a structural mode and requires Adapee and Adaptor ). why do we often encounter the problem of combining two unrelated classes? The first solution is
Fuzzy search of stored procedures and sorting by matching rateThere is a search function in the recent project. In this case, you can simply do the search, and you can simply like the percent sign. But after thinking about it, I had to do something
Configure maven and spring
This blog is mainly about maven and spring configuration management. maven is used to manage spring dependency packages.
This article is original, reproduced please indicate to:
Servlet Learning (1)
1. Servlet is a technology provided by sun for developing dynamic web resources.
2. Servlet location in web applications:
3. Create a Servlet in three ways:(1) Implement the servlet Interface
(2) InheritanceGenericServlet,
Design Pattern bridgingBridge Pattern) It is also called the bridge mode. Separate the abstract part from its implementation part so that they can all change independently. In home life, everyone has used electric lights. switches and electric
Netty source code simple analysis 1
I briefly read the source code of netty5 over the weekend. I only understood the rough idea and recorded the results so that I can recall it next time.
Server code:
public void run() throws Exception {
Tree and binary treeA tree is an important non-linear data structure defined by the hierarchy defined by the branch relationship: the tree is a finite set T of n (n> = 0) nodes, where: when n = 0 is null tree n> 0, there is only one specific node,
Send an HTTP request and obtain an HTTP response.
The process of sending an HTTP request and obtaining an HTTP response is as follows:
(1) define HTTP requests such as HttpPut (HttpPost/HttpGet/HttpDelete;
(2) define various headers and add them to
Configure solr for jetty
1. Download jetty8 from the jetty official website.
2. decompress the file and copy the solr directory (index file and configuration) in the solr4.8 directory to the jetty8 root directory.
3. Decompress solr. war under
Design Mode Reading Notes (5)-Comparison of Three factory Modes
First look at the main code of the three factory models (the complete code is in the first three blogs ):
Simple factory mode:
public class SampleFactory{public static Animal
Common Regular Expressions
Verification number: ^ [0-9] * $ verify the n-digit number: ^ \ d {n} $ verify the number of at least n digits: ^ \ d {n ,} $ verify m-n digits: ^ \ d {m, n} $ verify digits starting with zero or zero: ^ (0 | [1-9] [0-9] *)
Spring Source code reading: Design and Implementation of IOC containers (2) -- ApplicationContextWhy is ApplicationContext recommended in Spring reference documents? What benefits does it bring to our applications? As one of BeanFactory
Simple addition, deletion, modification, and query using JDBC (take MySQL as an example), jdbcmysql
Directory
JDBC
I. Preparations (I): MySQL installation configuration and basic learning
2. Preparation (2): Download and import the jar package
Sort (select, Hill, binary insert), and Hill binary insert
Select sorting method
1st times, pending sorting records r [1] ~ Select the smallest record from r [n] and exchange it with r [1]. For example, 2nd rows, in the record to be sorted, r [2] ~
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.