Before the habit of writing notes, now slowly found in time to sum up is how important, hehe. Although only sophomore, but also near graduation, to refuel.This article is mainly about Java multithreading, mainly driven by examples. Because of the
The system is DEBIAN8, Jessie, and the default Java version is: OpenJDK 1.7
1. Check the current system's Java version
leung@phychion:~$ java-versionJava Version "1.7.0_65"OpenJDK Runtime Environment (IcedTea 2.5.2) (7u65-2.5.2-4)OpenJDK 64-bit
java resolves byte 2 of an exception 2-byte UTF-8 sequence Invalid problem
Recently done the project, encountered an exception 2 bytes of the UTF-8 sequence of bytes 2 invalid problem, the Internet to find the next data, here to record the solution,
Free to do nothing, the recent project needs to write a user login home to send cash red envelopes, there is no limit. I calculated myself a little bit if there was a limit to how to write. Think this is similar to the micro-letter red envelopes.
What is an enumeration?
Enumerations are new features introduced by JDK5. In some cases, the objects of a class are fixed and can be defined as enumerations. In practice, enumeration types can also be used as a specification to guarantee the safety
1, Java filter out letters, numbers and Chinese regular expressions
(1) filter out the regular expression of the letter
[^ (a-za-z)]
(2) Regular expressions that filter out numbers
[^ (0-9)]
(3) Filtering out regular expressions in Chinese
[^ (
Java Get File size
Today, when writing code to achieve the function of getting file size, there are two implementations, one is using the length () method of file, and the other is using the FileInputStream available () method, when InputStream
First, the preface
DOM4J is a very good Java open source API, mainly used to read and write XML documents, with excellent performance, powerful, and very convenient to use the characteristics. In addition, XML is often used for data exchange
JDK, JVM, JRE in the Java environment
Recently underestimated Android, a bunch of concepts jdk, JVM, JRE, SDK, NDK, ADT. The JDK, the JVM, the JRE are things in the Java environment, and the SDK, NDK, and ADT are the things that Android develops.
The use of methods for objects and properties in Java, simple to write a case
Import Java.util.Scanner;
Class Calculste {int A;//define two integer int b; String option; Defines the receive operator string public void count () {//To
Summary of Java list loop and map loop
Do a list and map of the summary, there is no technical content, all the review of the API.
The test environment is under JUNIT4, and it is the same without writing a main method yourself.
First, there are
This article introduces the avatar cutting upload function, the technology used has JQUERY,SPRINGMVC, the cutting plug-in uses is Jcrop (in the middle encounters many pits, finally crosses).
Picture upload step:
1. User Select picture
2. The
It is only a matter of efficiency that a friend who has developed experience can achieve such a function. We generally in the face of such problems, always tile the direct sequence of association, mister into an array, and then add a random number
1. About Java.lang.string.split
The Xxx.split () method splits a string into substrings and then returns the result as an array of strings.
2. Array of string-turn characters
String str = "Aa.png,a2.png,a3.png";
String[] Arraystr =new
When we learn spring, we know that spring has two main ideas, one is the IOC, the other is AOP, and for IOC, dependency injection doesn't have to be said, and for spring's core AOP, we not only need to know how to satisfy our function through AOP,
The last time we used a byte stream, there was a character stream, the last time we talked about how to tell which stream to use, and if Notepad could read it, use a character stream, or use a byte stream. Using a character stream involves coding
Common Java packages and common Java packages
Java. lang: This package contains the core classes of the Java language, such as String, Math, Sytem, and Thread. You do not need to use the import Statement to import the package, the system
(1) public Date ()The date and time of the created date class object are set to the date and time corresponding to the creation time.Example:Java code1. Date today = new Date (); // today is set to the Date time corresponding to the creation time.(2)
After the jdk is installed on the computer, we can set it so that the java environment can be used. Right-click my computer. Open properties. Then select "environment variables" in "advanced". In the new open interface, you must set three attributes:
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