HashMap and HashSet are two important members of the Java Collection Framework, where HashMap is a common implementation class for the Map interface, and HashSet is a common implementation class for the Set interface. Although the interface
Design mode (Patterns)--the basis of reusable object-oriented softwareDesign pattern is a set of reusable, most known, categorized purposes, code design experience Summary. Design patterns are used in order to reuse code, make code easier to
Transferred from: http://zochen.iteye.com/blog/616151Simple implementation of the use of the JDK class Java.util.logging.Logger to record the log. The main reason is to use configuration files to configure the output of the log in the log4j manner.
Http://www.cnblogs.com/shenliang123/archive/2011/10/27/2226892.htmlResponse.sendredirect ("http://www.foo.com/path/error.html");Redirection and forwarding have an important difference: When forwarding is used, the JSP container uses an internal
original link Jakob JenkovTranslator: palanisamy proofreading: Dingin Java, deadlocks can be avoided in some cases. This article shows three techniques for avoiding deadlocks:Lock orderDeadlocks can easily occur when multiple threads require the
Original link Jakob Jenkov Translator: Gao song proofreading: DingIn Java, when multiple threads access the same resource at the same time, and one or more of the threads writes to the resource, it producesrace Condition。 Multiple threads reading
Java's garbage collection has a variety of strategies, and the default policy is often changed.-for example, serial, parallel, CMS; How about the concrete to Minor, old?
Command java-xx:+printflagsfinal-version, providing help:
BOOL
Local to read a file on another computer, the two hosts on the same LAN, copying each other time consuming effort. You can read the file from other hosts on your LAN by simply setting the resource you want to access to a resource share.First, set
1). There are two ways to convert a simple type of data: Auto-conversion and casting , which typically occurs in an expression or when a method's arguments are passed.Automatic conversionWhen a smaller data is calculated with a larger data, the
Reprint Please specify source: http://blog.csdn.net/l1028386804/article/details/45600505I. Overviewcaptures the internal state of an object without compromising encapsulation, and saves the state outside that object. The object can then be restored
Static represents the meaning of "global" or "static", which modifies member variables and member methods, and can also form statically static blocks of code, but there is no concept of global variables in the Java language .member variables and
1:switch Statement (master)(1) Format: switch (expression) {case value 1: statement body 1; Break Case Value 2: statement body 2; Break ... default: statement body n+1; Break Format Explanation: Switch: Description This is a switch
Eclipse Common shortcut keysEclipse's editing capabilities are powerful, and mastering the Eclipse shortcut key capabilities can greatly improve development efficiency. There are several shortcut keys related to editing in Eclipse.1. "Alt+/"This
1.DRY (Don't repeat yourself)This means not writing duplicate code, instead of using abstract commonalities. If you use hard-coded more than once, consider exposing it as a final-modified invariant, and if you have the same block of code in more
1. Reading XML2. Writing XML3. Create a new XML4. Creating the Construction XMLTo create a new XML document:1/constructs an XML parser and creates a new document/21 Document document =NULL;32 Documentbuilderfactory factory
Simple Factory pattern is the innovative model of the class, also called the Static Factory method pattern, which is responsible for creating instances of other classes by specifically defining a class that is instances that are created typically
Design Mode note Template Method mode Template Method
// TemplateMethod template method mode ---- class behavior mode
/*
1: Intention:
Defines the skeleton of an algorithm in an operation, and delays some steps to the subclass. TemplateMethod
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.
A Free Trial That Lets You Build Big!
Start building with 50+ products and up to 12 months usage for Elastic Compute Service