The purpose of writing this article is simply to have a place to collect the commands I often use. (Old, bad memory, good memories as bad pen)
The text screenshots and the introduction of the project address may not be consistent, because most of
http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=4415733http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=4244499
A long-standing bug, but Sun doesn't seem to be in a hurry to change it, but it's hard for us to eat in Java.Fortunately there are
Get some files after the filename is just number, also a txt description
Hey, who let us be programmers, make a small program change is old
Import Java.io.BufferedReader;
Import Java.io.File;
Import Java.io.FileReader;
Import java.io.IOException;
Java Multi-thread interrupt () method is associated with sleep (), join (), wait ()
About Java multithreading knowledge can see "Thinking in Java" in the multithreaded part and "Java Network Programming" 5th chapter of the Multithreading section
Because Java.util.zip.ZipOutputStream has the Chinese garbled problem, therefore uses the Org.apache.tools.zip.ZipOutputStream.
Here's the code:
Import Java.io.BufferedInputStream;
Import Java.io.File;
Import Java.io.FileInputStream;
Import
First Stage
Technical name
Technical Content
J2se(Java Base section)
The Prelude to Java development
Computer fundamentals, a brief History of Java language development and development environment, experience Java program
Java PermGen Space OutOfMemory summary 2008-05-28 17:47
The above three article on JVM Performance tuning is summarized as follows:
The JVM heap is divided into three parts(1) New domain: Storing all New Chengshen objects(2) Old domain: The object
Write a uncompressed class with the following code: Mport java.io. * ;Import Java.util.zip. * ;public class Unzipae ... {static final int BUFFER = 2048;Zipinputstream zis = null;String outputdirectory = new string ();public void Openzipfile (String
The results of the output are referenced as follows:
List of programs:
1. Produce random number
Generate random number public
class Randomcharacter {public
static char getrandomcharacter (char Ch1,char CH2) {return
( Char) (Ch1+math.random () * (
Methods and steps to analyze the high CPU usage of Java threads:
1) To view the CPU occupancy rate TOP10 PID
[Root@qipsuit1 ~]# Ps-aux | Sort-k3nr | head-10
Warning:bad syntax, perhaps a bogus '-'? See/usr/share/doc/procps-3.2.8/faq
root 30428 1
This morning, 64-bit eclipse was used to create a Web project, but when creating a JSP, "the superclass" Javax.servlet.http.HttpServlet "was" and "the" is not found on the Java Build Path, as shown in the following figure:
How to solve it.
1,
Public classQualityfactor {/** * Because no matter how the number of primes can be computed by multiplication in 1 9, except that 1 and 2 only need to continue to be divisible by 2-9. * This argument uses the extraction of the minimum polynomials to
This learning is to use Java to generate XML format files
The jar pack Jdom.jar used in the demo
I wrote a demo for easy understanding.
This article is from Http://blog.csdn.net/manymore13
Import Java.io.FileOutputStream;
Import
There is a bit more problem with the code for a zip compressed file on the Web. Now refactor. The main changes are as follows: Add private constructor System.out.println output log to Logger.info output remove Run-time exception more than 3
The following content is translated from the mat help document.
Mat Download Address http://www.eclipse.org/mat/One, Class histogram
Class histogram shows the classes found in the snapshot, the number of objects to each class, the heap memory
Package utils.sort;
/**
* Quick sort, requiring that the array to be sorted must implement the comparable interface
*/
public class QuickSort implements Sortstrategy
{
private static final int CUTOFF = 3; Use fast sorting when the number of
Multi-Threaded synchronization: Multiple threads work together to perform tasks correctly.
We often see the multithread synchronization keyword synchronized, then it is the use of Who do sync lock.
To achieve multithreaded synchronization, you must
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